Commit aefd75c0 authored by Clement Ho's avatar Clement Ho

[skip ci] .input-group-btn into .input-group-prepend, .input-group-append

parent c2cbc155
...@@ -182,11 +182,11 @@ ...@@ -182,11 +182,11 @@
:value="ingressExternalIp" :value="ingressExternalIp"
readonly readonly
/> />
<span class="input-group-btn"> <span class="input-group-append">
<clipboard-button <clipboard-button
:text="ingressExternalIp" :text="ingressExternalIp"
:title="s__('ClusterIntegration|Copy Ingress IP Address to clipboard')" :title="s__('ClusterIntegration|Copy Ingress IP Address to clipboard')"
class="js-clipboard-btn" class="input-group-text js-clipboard-btn"
/> />
</span> </span>
</div> </div>
......
...@@ -312,7 +312,8 @@ ...@@ -312,7 +312,8 @@
padding: 0 5px; padding: 0 5px;
} }
.input-group-btn { .input-group-prepend,
.input-group-append {
.btn { .btn {
@include btn-middle; @include btn-middle;
......
...@@ -83,7 +83,8 @@ label { ...@@ -83,7 +83,8 @@ label {
font-family: $monospace_font; font-family: $monospace_font;
} }
.input-group-btn .btn { .input-group-prepend .btn,
.input-group-append .btn {
padding: 3px $gl-btn-padding; padding: 3px $gl-btn-padding;
background-color: $gray-light; background-color: $gray-light;
border: 1px solid $border-color; border: 1px solid $border-color;
......
...@@ -912,7 +912,8 @@ pre.light-well { ...@@ -912,7 +912,8 @@ pre.light-well {
} }
.project-tip-command { .project-tip-command {
> .input-group-btn:first-child { > .input-group-prepend:first-child,
> .input-group-append:first-child {
width: auto; width: auto;
} }
} }
......
...@@ -46,7 +46,8 @@ ...@@ -46,7 +46,8 @@
%td.import-target %td.import-target
%fieldset.row %fieldset.row
.input-group .input-group
.project-path.input-group-btn .project-path.input-group-prepend
.input-group-text
- if current_user.can_select_namespace? - if current_user.can_select_namespace?
- selected = params[:namespace_id] || :current_user - selected = params[:namespace_id] || :current_user
- opts = current_user.can_create_group? ? { extra_group: Group.new(name: repo.owner.login, path: repo.owner.login) } : {} - opts = current_user.can_create_group? ? { extra_group: Group.new(name: repo.owner.login, path: repo.owner.login) } : {}
......
...@@ -54,7 +54,8 @@ ...@@ -54,7 +54,8 @@
%td.import-target %td.import-target
%fieldset.row %fieldset.row
.input-group .input-group
.project-path.input-group-btn .project-path.input-group-prepend
.input-group-text
- if current_user.can_select_namespace? - if current_user.can_select_namespace?
- selected = params[:namespace_id] || :current_user - selected = params[:namespace_id] || :current_user
- opts = current_user.can_create_group? ? { extra_group: Group.new(name: repo.owner, path: repo.owner) } : {} - opts = current_user.can_create_group? ? { extra_group: Group.new(name: repo.owner, path: repo.owner) } : {}
......
...@@ -20,7 +20,8 @@ ...@@ -20,7 +20,8 @@
.form-group .form-group
.input-group .input-group
= text_field_tag 'created-personal-access-token', @new_personal_access_token, readonly: true, class: "form-control js-select-on-focus", 'aria-describedby' => "created-personal-access-token-help-block" = text_field_tag 'created-personal-access-token', @new_personal_access_token, readonly: true, class: "form-control js-select-on-focus", 'aria-describedby' => "created-personal-access-token-help-block"
%span.input-group-btn %span.input-group-append
.input-group-text
= clipboard_button(text: @new_personal_access_token, title: "Copy personal access token to clipboard", placement: "left", class: "btn-default btn-clipboard") = clipboard_button(text: @new_personal_access_token, title: "Copy personal access token to clipboard", placement: "left", class: "btn-default btn-clipboard")
%span#created-personal-access-token-help-block.form-text.text-muted.text-danger Make sure you save it - you won't be able to access it again. %span#created-personal-access-token-help-block.form-text.text-muted.text-danger Make sure you save it - you won't be able to access it again.
......
...@@ -17,7 +17,8 @@ ...@@ -17,7 +17,8 @@
You can create a new #{name} inside this project by sending an email to the following email address: You can create a new #{name} inside this project by sending an email to the following email address:
.email-modal-input-group.input-group .email-modal-input-group.input-group
= text_field_tag :issuable_email, email, class: "monospace js-select-on-focus form-control", readonly: true = text_field_tag :issuable_email, email, class: "monospace js-select-on-focus form-control", readonly: true
.input-group-btn .input-group-append
.input-group-text
= clipboard_button(target: '#issuable_email', class: 'btn btn-clipboard btn-transparent d-none d-sm-block') = clipboard_button(target: '#issuable_email', class: 'btn btn-clipboard btn-transparent d-none d-sm-block')
= mail_to email, class: 'btn btn-clipboard btn-transparent', = mail_to email, class: 'btn btn-clipboard btn-transparent',
subject: _("Enter the #{name} title"), subject: _("Enter the #{name} title"),
......
...@@ -3,9 +3,10 @@ ...@@ -3,9 +3,10 @@
= label_tag(:push_to_create_tip, _("Private projects can be created in your personal namespace with:"), class: "weight-normal") = label_tag(:push_to_create_tip, _("Private projects can be created in your personal namespace with:"), class: "weight-normal")
%p.input-group.project-tip-command %p.input-group.project-tip-command
%span.input-group-btn %span
= text_field_tag :push_to_create_tip, push_to_create_project_command, class: "js-select-on-focus form-control monospace", readonly: true, aria: { label: _("Push project from command line") } = text_field_tag :push_to_create_tip, push_to_create_project_command, class: "js-select-on-focus form-control monospace", readonly: true, aria: { label: _("Push project from command line") }
%span.input-group-btn %span.input-group-append
.input-group-text
= clipboard_button(text: push_to_create_project_command, title: _("Copy command to clipboard"), placement: "right") = clipboard_button(text: push_to_create_project_command, title: _("Copy command to clipboard"), placement: "right")
%p %p
= link_to("What does this command do?", help_page_path("gitlab-basics/create-project", anchor: "push-to-create-a-new-project"), target: "_blank") = link_to("What does this command do?", help_page_path("gitlab-basics/create-project", anchor: "push-to-create-a-new-project"), target: "_blank")
...@@ -3,7 +3,8 @@ ...@@ -3,7 +3,8 @@
= s_('ClusterIntegration|Kubernetes cluster name') = s_('ClusterIntegration|Kubernetes cluster name')
.input-group .input-group
%input.form-control.cluster-name.js-select-on-focus{ value: @cluster.name, readonly: true } %input.form-control.cluster-name.js-select-on-focus{ value: @cluster.name, readonly: true }
%span.input-group-btn %span.input-group-append
.input-group-text
= clipboard_button(text: @cluster.name, title: s_('ClusterIntegration|Copy Kubernetes cluster name'), class: 'btn-secondary') = clipboard_button(text: @cluster.name, title: s_('ClusterIntegration|Copy Kubernetes cluster name'), class: 'btn-secondary')
= form_for @cluster, url: namespace_project_cluster_path(@project.namespace, @project, @cluster), as: :cluster do |field| = form_for @cluster, url: namespace_project_cluster_path(@project.namespace, @project, @cluster), as: :cluster do |field|
...@@ -14,7 +15,8 @@ ...@@ -14,7 +15,8 @@
= platform_kubernetes_field.label :api_url, s_('ClusterIntegration|API URL') = platform_kubernetes_field.label :api_url, s_('ClusterIntegration|API URL')
.input-group .input-group
= platform_kubernetes_field.text_field :api_url, class: 'form-control js-select-on-focus', placeholder: s_('ClusterIntegration|API URL'), readonly: true = platform_kubernetes_field.text_field :api_url, class: 'form-control js-select-on-focus', placeholder: s_('ClusterIntegration|API URL'), readonly: true
%span.input-group-btn %span.input-group-append
.input-group-text
= clipboard_button(text: @cluster.platform_kubernetes.api_url, title: s_('ClusterIntegration|Copy API URL'), class: 'btn-secondary') = clipboard_button(text: @cluster.platform_kubernetes.api_url, title: s_('ClusterIntegration|Copy API URL'), class: 'btn-secondary')
.form-group .form-group
...@@ -29,8 +31,8 @@ ...@@ -29,8 +31,8 @@
= platform_kubernetes_field.label :token, s_('ClusterIntegration|Token') = platform_kubernetes_field.label :token, s_('ClusterIntegration|Token')
.input-group .input-group
= platform_kubernetes_field.text_field :token, class: 'form-control js-cluster-token js-select-on-focus', type: 'password', placeholder: s_('ClusterIntegration|Token'), readonly: true = platform_kubernetes_field.text_field :token, class: 'form-control js-cluster-token js-select-on-focus', type: 'password', placeholder: s_('ClusterIntegration|Token'), readonly: true
%span.input-group-btn %span.input-group-append
%button.btn.btn-secondary.js-show-cluster-token{ type: 'button' } %button.btn.btn-secondary.input-group-text.js-show-cluster-token{ type: 'button' }
= s_('ClusterIntegration|Show') = s_('ClusterIntegration|Show')
= clipboard_button(text: @cluster.platform_kubernetes.token, title: s_('ClusterIntegration|Copy Token'), class: 'btn-secondary') = clipboard_button(text: @cluster.platform_kubernetes.token, title: s_('ClusterIntegration|Copy Token'), class: 'btn-secondary')
......
...@@ -30,7 +30,8 @@ ...@@ -30,7 +30,8 @@
%td %td
.input-group .input-group
= text_field_tag :domain_dns, dns_record , class: "monospace js-select-on-focus form-control", readonly: true = text_field_tag :domain_dns, dns_record , class: "monospace js-select-on-focus form-control", readonly: true
.input-group-btn .input-group-append
.input-group-text
= clipboard_button(target: '#domain_dns', class: 'btn-default d-none d-sm-block') = clipboard_button(target: '#domain_dns', class: 'btn-default d-none d-sm-block')
%p.form-text.text-muted %p.form-text.text-muted
To access this domain create a new DNS record To access this domain create a new DNS record
......
...@@ -21,14 +21,16 @@ ...@@ -21,14 +21,16 @@
= label_tag :display_name, 'Display name', class: 'col-sm-2 col-12 col-form-label' = label_tag :display_name, 'Display name', class: 'col-sm-2 col-12 col-form-label'
.col-sm-10.col-12.input-group .col-sm-10.col-12.input-group
= text_field_tag :display_name, "GitLab / #{@project.full_name}", class: 'form-control form-control-sm', readonly: 'readonly' = text_field_tag :display_name, "GitLab / #{@project.full_name}", class: 'form-control form-control-sm', readonly: 'readonly'
.input-group-btn .input-group-append
.input-group-text
= clipboard_button(target: '#display_name') = clipboard_button(target: '#display_name')
.form-group .form-group
= label_tag :description, 'Description', class: 'col-sm-2 col-12 col-form-label' = label_tag :description, 'Description', class: 'col-sm-2 col-12 col-form-label'
.col-sm-10.col-12.input-group .col-sm-10.col-12.input-group
= text_field_tag :description, run_actions_text, class: 'form-control form-control-sm', readonly: 'readonly' = text_field_tag :description, run_actions_text, class: 'form-control form-control-sm', readonly: 'readonly'
.input-group-btn .input-group-append
.input-group-text
= clipboard_button(target: '#description') = clipboard_button(target: '#description')
.form-group .form-group
...@@ -45,7 +47,8 @@ ...@@ -45,7 +47,8 @@
= label_tag :request_url, 'Request URL', class: 'col-sm-2 col-12 col-form-label' = label_tag :request_url, 'Request URL', class: 'col-sm-2 col-12 col-form-label'
.col-sm-10.col-12.input-group .col-sm-10.col-12.input-group
= text_field_tag :request_url, service_trigger_url(subject), class: 'form-control form-control-sm', readonly: 'readonly' = text_field_tag :request_url, service_trigger_url(subject), class: 'form-control form-control-sm', readonly: 'readonly'
.input-group-btn .input-group-append
.input-group-text
= clipboard_button(target: '#request_url') = clipboard_button(target: '#request_url')
.form-group .form-group
...@@ -56,14 +59,16 @@ ...@@ -56,14 +59,16 @@
= label_tag :response_username, 'Response username', class: 'col-sm-2 col-12 col-form-label' = label_tag :response_username, 'Response username', class: 'col-sm-2 col-12 col-form-label'
.col-sm-10.col-12.input-group .col-sm-10.col-12.input-group
= text_field_tag :response_username, 'GitLab', class: 'form-control form-control-sm', readonly: 'readonly' = text_field_tag :response_username, 'GitLab', class: 'form-control form-control-sm', readonly: 'readonly'
.input-group-btn .input-group-append
.input-group-text
= clipboard_button(target: '#response_username') = clipboard_button(target: '#response_username')
.form-group .form-group
= label_tag :response_icon, 'Response icon', class: 'col-sm-2 col-12 col-form-label' = label_tag :response_icon, 'Response icon', class: 'col-sm-2 col-12 col-form-label'
.col-sm-10.col-12.input-group .col-sm-10.col-12.input-group
= text_field_tag :response_icon, asset_url('gitlab_logo.png'), class: 'form-control form-control-sm', readonly: 'readonly' = text_field_tag :response_icon, asset_url('gitlab_logo.png'), class: 'form-control form-control-sm', readonly: 'readonly'
.input-group-btn .input-group-append
.input-group-text
= clipboard_button(target: '#response_icon') = clipboard_button(target: '#response_icon')
.form-group .form-group
...@@ -74,14 +79,16 @@ ...@@ -74,14 +79,16 @@
= label_tag :autocomplete_hint, 'Autocomplete hint', class: 'col-sm-2 col-12 col-form-label' = label_tag :autocomplete_hint, 'Autocomplete hint', class: 'col-sm-2 col-12 col-form-label'
.col-sm-10.col-12.input-group .col-sm-10.col-12.input-group
= text_field_tag :autocomplete_hint, '[help]', class: 'form-control form-control-sm', readonly: 'readonly' = text_field_tag :autocomplete_hint, '[help]', class: 'form-control form-control-sm', readonly: 'readonly'
.input-group-btn .input-group-append
.input-group-text
= clipboard_button(target: '#autocomplete_hint') = clipboard_button(target: '#autocomplete_hint')
.form-group .form-group
= label_tag :autocomplete_description, 'Autocomplete description', class: 'col-sm-2 col-12 col-form-label' = label_tag :autocomplete_description, 'Autocomplete description', class: 'col-sm-2 col-12 col-form-label'
.col-sm-10.col-12.input-group .col-sm-10.col-12.input-group
= text_field_tag :autocomplete_description, run_actions_text, class: 'form-control form-control-sm', readonly: 'readonly' = text_field_tag :autocomplete_description, run_actions_text, class: 'form-control form-control-sm', readonly: 'readonly'
.input-group-btn .input-group-append
.input-group-text
= clipboard_button(target: '#autocomplete_description') = clipboard_button(target: '#autocomplete_description')
%hr %hr
......
...@@ -39,7 +39,8 @@ ...@@ -39,7 +39,8 @@
= label_tag :url, 'URL', class: 'col-sm-2 col-12 col-form-label' = label_tag :url, 'URL', class: 'col-sm-2 col-12 col-form-label'
.col-sm-10.col-12.input-group .col-sm-10.col-12.input-group
= text_field_tag :url, service_trigger_url(subject), class: 'form-control form-control-sm', readonly: 'readonly' = text_field_tag :url, service_trigger_url(subject), class: 'form-control form-control-sm', readonly: 'readonly'
.input-group-btn .input-group-append
.input-group-text
= clipboard_button(target: '#url') = clipboard_button(target: '#url')
.form-group .form-group
...@@ -50,7 +51,8 @@ ...@@ -50,7 +51,8 @@
= label_tag :customize_name, 'Customize name', class: 'col-sm-2 col-12 col-form-label' = label_tag :customize_name, 'Customize name', class: 'col-sm-2 col-12 col-form-label'
.col-sm-10.col-12.input-group .col-sm-10.col-12.input-group
= text_field_tag :customize_name, 'GitLab', class: 'form-control form-control-sm', readonly: 'readonly' = text_field_tag :customize_name, 'GitLab', class: 'form-control form-control-sm', readonly: 'readonly'
.input-group-btn .input-group-append
.input-group-text
= clipboard_button(target: '#customize_name') = clipboard_button(target: '#customize_name')
.form-group .form-group
...@@ -67,21 +69,24 @@ ...@@ -67,21 +69,24 @@
= label_tag :autocomplete_description, 'Autocomplete description', class: 'col-sm-2 col-12 col-form-label' = label_tag :autocomplete_description, 'Autocomplete description', class: 'col-sm-2 col-12 col-form-label'
.col-sm-10.col-12.input-group .col-sm-10.col-12.input-group
= text_field_tag :autocomplete_description, run_actions_text, class: 'form-control form-control-sm', readonly: 'readonly' = text_field_tag :autocomplete_description, run_actions_text, class: 'form-control form-control-sm', readonly: 'readonly'
.input-group-btn .input-group-append
.input-group-text
= clipboard_button(target: '#autocomplete_description') = clipboard_button(target: '#autocomplete_description')
.form-group .form-group
= label_tag :autocomplete_usage_hint, 'Autocomplete usage hint', class: 'col-sm-2 col-12 col-form-label' = label_tag :autocomplete_usage_hint, 'Autocomplete usage hint', class: 'col-sm-2 col-12 col-form-label'
.col-sm-10.col-12.input-group .col-sm-10.col-12.input-group
= text_field_tag :autocomplete_usage_hint, '[help]', class: 'form-control form-control-sm', readonly: 'readonly' = text_field_tag :autocomplete_usage_hint, '[help]', class: 'form-control form-control-sm', readonly: 'readonly'
.input-group-btn .input-group-append
.input-group-text
= clipboard_button(target: '#autocomplete_usage_hint') = clipboard_button(target: '#autocomplete_usage_hint')
.form-group .form-group
= label_tag :descriptive_label, 'Descriptive label', class: 'col-sm-2 col-12 col-form-label' = label_tag :descriptive_label, 'Descriptive label', class: 'col-sm-2 col-12 col-form-label'
.col-sm-10.col-12.input-group .col-sm-10.col-12.input-group
= text_field_tag :descriptive_label, 'Perform common operations on GitLab project', class: 'form-control form-control-sm', readonly: 'readonly' = text_field_tag :descriptive_label, 'Perform common operations on GitLab project', class: 'form-control form-control-sm', readonly: 'readonly'
.input-group-btn .input-group-append
.input-group-text
= clipboard_button(target: '#descriptive_label') = clipboard_button(target: '#descriptive_label')
%hr %hr
......
- project = project || @project - project = project || @project
.git-clone-holder.input-group .git-clone-holder.input-group
.input-group-btn .input-group-prepend
.input-group-text
- if allowed_protocols_present? - if allowed_protocols_present?
.clone-dropdown-btn.btn .clone-dropdown-btn.btn
%span %span
...@@ -18,5 +19,6 @@ ...@@ -18,5 +19,6 @@
= http_clone_button(project) = http_clone_button(project)
= text_field_tag :project_clone, default_url_to_repo(project), class: "js-select-on-focus form-control", readonly: true, aria: { label: 'Project clone URL' } = text_field_tag :project_clone, default_url_to_repo(project), class: "js-select-on-focus form-control", readonly: true, aria: { label: 'Project clone URL' }
.input-group-btn .input-group-append
.input-group-text
= clipboard_button(target: '#project_clone', title: _("Copy URL to clipboard"), class: "btn-secondary btn-clipboard") = clipboard_button(target: '#project_clone', title: _("Copy URL to clipboard"), class: "btn-secondary btn-clipboard")
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment