diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-08-18 08:17:02 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-08-18 08:17:02 +0000 |
commit | b39512ed755239198a9c294b6a45e65c05900235 (patch) | |
tree | d234a3efade1de67c46b9e5a38ce813627726aa7 /app/views/admin | |
parent | d31474cf3b17ece37939d20082b07f6657cc79a9 (diff) | |
download | gitlab-ce-b39512ed755239198a9c294b6a45e65c05900235.tar.gz |
Add latest changes from gitlab-org/gitlab@15-3-stable-eev15.3.0-rc42
Diffstat (limited to 'app/views/admin')
19 files changed, 55 insertions, 50 deletions
diff --git a/app/views/admin/application_settings/_ci_cd.html.haml b/app/views/admin/application_settings/_ci_cd.html.haml index ba2a2f34d63..77170761448 100644 --- a/app/views/admin/application_settings/_ci_cd.html.haml +++ b/app/views/admin/application_settings/_ci_cd.html.haml @@ -22,7 +22,7 @@ .form-group = f.label :shared_runners_text, _('Shared runners details'), class: 'label-bold' = f.text_area :shared_runners_text, class: 'form-control gl-form-input', rows: 4 - .form-text.text-muted= _("Add a custom message with details about the instance's shared runners. The message is visible in group and project CI/CD settings, in the Runners section. Markdown is supported.") + .form-text.text-muted= _("Add a custom message with details about the instance's shared runners. The message is visible when you view runners for projects and groups. Markdown is supported.") .form-group = f.label :max_artifacts_size, _('Maximum artifacts size (MB)'), class: 'label-bold' = f.number_field :max_artifacts_size, class: 'form-control gl-form-input' diff --git a/app/views/admin/application_settings/_default_branch.html.haml b/app/views/admin/application_settings/_default_branch.html.haml index 4a06dcbc031..f9b1aa22b7a 100644 --- a/app/views/admin/application_settings/_default_branch.html.haml +++ b/app/views/admin/application_settings/_default_branch.html.haml @@ -14,4 +14,4 @@ = render_if_exists 'admin/application_settings/group_owners_can_manage_default_branch_protection_setting', form: f - = f.submit _('Save changes'), class: 'gl-button btn-confirm' + = f.submit _('Save changes'), pajamas_button: true diff --git a/app/views/admin/application_settings/_diff_limits.html.haml b/app/views/admin/application_settings/_diff_limits.html.haml index 1af4d294c1b..30165139711 100644 --- a/app/views/admin/application_settings/_diff_limits.html.haml +++ b/app/views/admin/application_settings/_diff_limits.html.haml @@ -1,4 +1,4 @@ -= form_for @application_setting, url: general_admin_application_settings_path(anchor: 'js-merge-request-settings'), html: { class: 'fieldset-form', id: 'merge-request-settings' } do |f| += gitlab_ui_form_for @application_setting, url: general_admin_application_settings_path(anchor: 'js-merge-request-settings'), html: { class: 'fieldset-form', id: 'merge-request-settings' } do |f| = form_errors(@application_setting, pajamas_alert: true) %fieldset @@ -29,4 +29,4 @@ = link_to sprite_icon('question-o'), help_page_path('user/admin_area/diff_limits', anchor: 'diff-limits-administration') - = f.submit _('Save changes'), class: 'gl-button btn btn-confirm' + = f.submit _('Save changes'), pajamas_button: true diff --git a/app/views/admin/application_settings/_repository_storage.html.haml b/app/views/admin/application_settings/_repository_storage.html.haml index 5dc2d322bb3..ff10e4a8f77 100644 --- a/app/views/admin/application_settings/_repository_storage.html.haml +++ b/app/views/admin/application_settings/_repository_storage.html.haml @@ -23,7 +23,7 @@ = link_to s_('Learn more.'), help_page_path('administration/repository_storage_paths.md'), target: '_blank', rel: 'noopener noreferrer' .form-check = f.fields_for :repository_storages_weighted, storage_weights do |storage_form| - - Gitlab.config.repositories.storages.keys.each do |storage| + - Gitlab.config.repositories.storages.each_key do |storage| = storage_form.text_field storage, class: 'form-text-input' = storage_form.label storage, storage, class: 'label-bold form-check-label' %br diff --git a/app/views/admin/application_settings/_runner_registrars_form.html.haml b/app/views/admin/application_settings/_runner_registrars_form.html.haml index 1d6051a06ea..7781db29bab 100644 --- a/app/views/admin/application_settings/_runner_registrars_form.html.haml +++ b/app/views/admin/application_settings/_runner_registrars_form.html.haml @@ -1,5 +1,5 @@ = gitlab_ui_form_for @application_setting, url: ci_cd_admin_application_settings_path(anchor: 'js-runner-settings'), html: { class: 'fieldset-form' } do |f| - = form_errors(@application_setting) + = form_errors(@application_setting, pajamas_alert: true) %fieldset .gl-form-group diff --git a/app/views/admin/application_settings/_snowplow.html.haml b/app/views/admin/application_settings/_snowplow.html.haml index 8684b909853..d500194b742 100644 --- a/app/views/admin/application_settings/_snowplow.html.haml +++ b/app/views/admin/application_settings/_snowplow.html.haml @@ -10,7 +10,7 @@ = html_escape(_('Configure %{link} to track events. %{link_start}Learn more.%{link_end}')) % { link: link_to('Snowplow', 'https://snowplowanalytics.com/', target: '_blank', rel: 'noopener noreferrer').html_safe, link_start: link_start, link_end: '</a>'.html_safe } .settings-content = gitlab_ui_form_for @application_setting, url: general_admin_application_settings_path(anchor: 'js-snowplow-settings'), html: { class: 'fieldset-form', id: 'snowplow-settings' } do |f| - = form_errors(@application_setting) if expanded + = form_errors(@application_setting, pajamas_alert: true) if expanded %fieldset .form-group diff --git a/app/views/admin/application_settings/_usage.html.haml b/app/views/admin/application_settings/_usage.html.haml index c9ed2309cec..7326a63f8c2 100644 --- a/app/views/admin/application_settings/_usage.html.haml +++ b/app/views/admin/application_settings/_usage.html.haml @@ -3,7 +3,7 @@ - link_end = '</a>'.html_safe = gitlab_ui_form_for @application_setting, url: metrics_and_profiling_admin_application_settings_path(anchor: 'js-usage-settings'), html: { class: 'fieldset-form' } do |f| - = form_errors(@application_setting) + = form_errors(@application_setting, pajamas_alert: true) %fieldset .form-group @@ -38,7 +38,7 @@ %p.gl-mb-3= s_('AdminSettings|Registration Features include:') - email_from_gitlab_path = help_page_path('user/admin_area/email_from_gitlab') - repo_size_limit_path = help_page_path('user/admin_area/settings/account_and_limit_settings', anchor: 'repository-size-limit') - - restrict_ip_path = help_page_path('user/group/index', anchor: 'restrict-group-access-by-ip-address') + - restrict_ip_path = help_page_path('user/group/access_and_permissions', anchor: 'restrict-group-access-by-ip-address') - email_from_gitlab_link = link_start % { url: email_from_gitlab_path } - repo_size_limit_link = link_start % { url: repo_size_limit_path } - restrict_ip_link = link_start % { url: restrict_ip_path } diff --git a/app/views/admin/application_settings/_whats_new.html.haml b/app/views/admin/application_settings/_whats_new.html.haml index 8ae912d24b7..d82bb1c94e4 100644 --- a/app/views/admin/application_settings/_whats_new.html.haml +++ b/app/views/admin/application_settings/_whats_new.html.haml @@ -1,7 +1,7 @@ = gitlab_ui_form_for @application_setting, url: preferences_admin_application_settings_path(anchor: 'js-whats-new-settings'), html: { class: 'fieldset-form whats-new-settings' } do |f| = form_errors(@application_setting, pajamas_alert: true) - - whats_new_variants.keys.each do |variant| + - whats_new_variants.each_key do |variant| .gl-mb-4 = f.gitlab_ui_radio_component :whats_new_variant, variant, whats_new_variants_label(variant), help_text: whats_new_variants_description(variant) diff --git a/app/views/admin/application_settings/appearances/_form.html.haml b/app/views/admin/application_settings/appearances/_form.html.haml index 224d9fbe953..349e1dfde5d 100644 --- a/app/views/admin/application_settings/appearances/_form.html.haml +++ b/app/views/admin/application_settings/appearances/_form.html.haml @@ -40,7 +40,7 @@ = f.hidden_field :favicon_cache = f.file_field :favicon, class: '', accept: 'image/*' .form-text.text-muted - = _("Maximum file size is 1 MB. Image size must be 32 x 32 pixels. Allowed image formats are %{favicon_extension_whitelist}.") % { favicon_extension_whitelist: favicon_extension_whitelist } + = _("Maximum file size is 1 MB. Image size must be 32 x 32 pixels. Allowed image formats are %{favicon_extension_allowlist}.") % { favicon_extension_allowlist: favicon_extension_allowlist } %br = _("Images with incorrect dimensions are not resized automatically, and may result in unexpected behavior.") diff --git a/app/views/admin/applications/index.html.haml b/app/views/admin/applications/index.html.haml index 180871e48dd..b603c7e5f49 100644 --- a/app/views/admin/applications/index.html.haml +++ b/app/views/admin/applications/index.html.haml @@ -29,8 +29,6 @@ %th = _('Callback URL') %th - = _('Clients') - %th = _('Trusted') %th = _('Confidential') @@ -41,7 +39,6 @@ %tr{ id: "application_#{application.id}" } %td= link_to application.name, admin_application_path(application) %td= application.redirect_uri - %td= @application_counts[application.id].to_i %td= application.trusted? ? _('Yes'): _('No') %td= application.confidential? ? _('Yes'): _('No') %td= link_to 'Edit', edit_admin_application_path(application), class: 'gl-button btn btn-link' diff --git a/app/views/admin/dashboard/index.html.haml b/app/views/admin/dashboard/index.html.haml index 88fbbb28201..271f89a6b08 100644 --- a/app/views/admin/dashboard/index.html.haml +++ b/app/views/admin/dashboard/index.html.haml @@ -58,7 +58,7 @@ = link_to(s_('AdminArea|New user'), new_admin_user_path, class: "btn gl-button btn-default") = c.footer do .d-flex.align-items-center - = link_to(s_('AdminArea|View latest users'), admin_users_path) + = link_to(s_('AdminArea|View latest users'), admin_users_path({ sort: 'created_desc' })) = sprite_icon('chevron-right', size: 12, css_class: 'gl-text-gray-700 gl-ml-2') .col-md-4.gl-mb-6 = render Pajamas::CardComponent.new(**component_params) do |c| diff --git a/app/views/admin/groups/_form.html.haml b/app/views/admin/groups/_form.html.haml index 7bcc97914e5..a254690de72 100644 --- a/app/views/admin/groups/_form.html.haml +++ b/app/views/admin/groups/_form.html.haml @@ -9,7 +9,7 @@ = _('Update your group name, description, avatar, and visibility.') = link_to _('Learn more about groups.'), help_page_path('user/group/index') .col-lg-8 - = render 'shared/group_form', f: f + = render 'shared/groups/group_name_and_path_fields', f: f = render 'shared/group_form_description', f: f .form-group.gl-form-group{ role: 'group' } = f.label :avatar, _("Group avatar"), class: 'gl-display-block col-form-label' diff --git a/app/views/admin/hook_logs/_index.html.haml b/app/views/admin/hook_logs/_index.html.haml deleted file mode 100644 index 6a46b0b3510..00000000000 --- a/app/views/admin/hook_logs/_index.html.haml +++ /dev/null @@ -1,11 +0,0 @@ -- docs_link_url = help_page_path('user/project/integrations/webhooks', anchor: 'troubleshoot-webhooks') -- link_start = '<a href="%{url}" target="_blank" rel="noopener noreferrer">'.html_safe % { url: docs_link_url } -- link_end = '</a>'.html_safe - -.row.gl-mt-3.gl-mb-3 - .col-lg-3 - %h4.gl-mt-0 - = _('Recent events') - %p= _('GitLab events trigger webhooks. Use the request details of a webhook to help troubleshoot problems. %{link_start}How do I troubleshoot?%{link_end}').html_safe % { link_start: link_start, link_end: link_end } - .col-lg-9 - = render partial: 'shared/hook_logs/recent_deliveries_table', locals: { hook: hook, hook_logs: hook_logs } diff --git a/app/views/admin/hooks/edit.html.haml b/app/views/admin/hooks/edit.html.haml index e8176e9f8bb..224afbff39a 100644 --- a/app/views/admin/hooks/edit.html.haml +++ b/app/views/admin/hooks/edit.html.haml @@ -15,6 +15,6 @@ = render 'shared/web_hooks/test_button', hook: @hook = link_to _('Delete'), admin_hook_path(@hook), method: :delete, class: 'btn gl-button btn-danger float-right', aria: { label: s_('Webhooks|Delete webhook') }, data: { confirm: s_('Webhooks|Are you sure you want to delete this webhook?'), confirm_btn_variant: 'danger' } - %hr +%hr - = render partial: 'admin/hook_logs/index', locals: { hook: @hook, hook_logs: @hook_logs } += render partial: 'shared/hook_logs/index', locals: { hook: @hook, hook_logs: @hook_logs } diff --git a/app/views/admin/identities/_identity.html.haml b/app/views/admin/identities/_identity.html.haml index d852e4a2463..3121cd2ae59 100644 --- a/app/views/admin/identities/_identity.html.haml +++ b/app/views/admin/identities/_identity.html.haml @@ -1,12 +1,24 @@ %tr %td - #{Gitlab::Auth::OAuth::Provider.label_for(identity.provider)} (#{identity.provider}) #{identity.saml_provider_id.present? ? "for #{link_to identity.saml_provider.group.path, identity.saml_provider.group} ID: #{identity.saml_provider_id}".html_safe : ""} + = label_for_identity_provider(identity) + %td{ data: { testid: provider_id_cell_testid(identity) } } + = provider_id(identity) + %td{ data: { testid: saml_group_cell_testid(identity) } } + = saml_group_link(identity) %td = identity.extern_uid - %td - = link_to edit_admin_user_identity_path(@user, identity), class: 'gl-button btn btn-sm btn-grouped' do - = _("Edit") - = link_to [:admin, @user, identity], method: :delete, - class: 'gl-button btn btn-sm btn-danger', - data: { confirm: _("Are you sure you want to remove this identity?") } do - = _('Delete') + %td{ class: 'gl-py-0!' } + - button_classes = 'has-tooltip gl-my-3' + = render Pajamas::ButtonComponent.new(category: :tertiary, + href: edit_admin_user_identity_path(@user, identity), + icon: 'pencil', + button_options: { title: _('Edit'), + 'aria-label' => _('Edit'), + class: button_classes } ) + = render Pajamas::ButtonComponent.new(category: :tertiary, + href: url_for([:admin, @user, identity]), + icon: 'remove', + button_options: { title: _('Delete'), + 'aria-label' => _('Delete identity'), + class: button_classes, + data: { method: :delete, confirm: _("Are you sure you want to remove this identity?") } } ) diff --git a/app/views/admin/identities/index.html.haml b/app/views/admin/identities/index.html.haml index 2bab802b2c1..1bb14969939 100644 --- a/app/views/admin/identities/index.html.haml +++ b/app/views/admin/identities/index.html.haml @@ -3,14 +3,20 @@ - page_title _("Identities"), @user.name, _("Users") = render 'admin/users/head' -- if @identities.present? - .table-holder - %table.table - %thead - %tr - %th= _('Provider') - %th= _('Identifier') - %th - = render @identities -- else - %h4= _('This user has no identities') +%table.table.gl-table + %thead + %tr + %th{ class: 'gl-border-t-0!' }= _('Provider') + %th{ class: 'gl-border-t-0!' }= s_('Identity|Provider ID') + %th{ class: 'gl-border-t-0!' }= _('Group') + %th{ class: 'gl-border-t-0!' }= _('Identifier') + %th{ class: 'gl-border-t-0!' }= _('Actions') + - if identity_cells_to_render?(@identities, @user) + = render_if_exists partial: 'admin/identities/scim_identity', collection: scim_identities_collection(@user) + = render @identities + - else + %tbody + %tr + %td{ colspan: '5' } + .text-center.my-2 + = _('This user has no identities') diff --git a/app/views/admin/labels/_label.html.haml b/app/views/admin/labels/_label.html.haml index ae8fed8964f..333c865629f 100644 --- a/app/views/admin/labels/_label.html.haml +++ b/app/views/admin/labels/_label.html.haml @@ -1,7 +1,7 @@ %li.label-list-item{ id: dom_id(label) } = render "shared/label_row", label: label.present(issuable_subject: nil) .label-actions-list - = link_to edit_admin_label_path(label), class: 'btn btn-default gl-button btn-default-tertiary label-action has-tooltip', title: _('Edit'), data: { placement: 'bottom' }, aria_label: _('Edit') do + = link_to edit_admin_label_path(label), class: 'btn btn-default gl-button btn-default-tertiary label-action has-tooltip', title: _('Edit'), data: { placement: 'bottom' }, aria: { label: _('Edit') } do = sprite_icon('pencil') = link_to admin_label_path(label), class: 'btn btn-default gl-button btn-default-tertiary hover-red js-remove-label label-action has-tooltip', title: _('Delete'), data: { placement: 'bottom', confirm: _('Are you sure you want to delete this label?'), confirm_btn_variant: 'danger' }, aria: { label: _('Delete label') }, method: :delete, remote: true do = sprite_icon('remove') diff --git a/app/views/admin/runners/show.html.haml b/app/views/admin/runners/show.html.haml index 22351397b9a..a9dbcf4a6a5 100644 --- a/app/views/admin/runners/show.html.haml +++ b/app/views/admin/runners/show.html.haml @@ -1,4 +1,5 @@ - add_page_specific_style 'page_bundles/ci_status' +- add_page_specific_style 'page_bundles/runner_details' - title = "##{@runner.id} (#{@runner.short_sha})" - breadcrumb_title title diff --git a/app/views/admin/users/_head.html.haml b/app/views/admin/users/_head.html.haml index ed453b42725..0ceff211806 100644 --- a/app/views/admin/users/_head.html.haml +++ b/app/views/admin/users/_head.html.haml @@ -45,5 +45,5 @@ = gl_tab_link_to _("SSH keys"), keys_admin_user_path(@user) = gl_tab_link_to _("Identities"), admin_user_identities_path(@user) - if impersonation_enabled? - = gl_tab_link_to _("Impersonation Tokens"), admin_user_impersonation_tokens_path(@user) + = gl_tab_link_to _("Impersonation Tokens"), admin_user_impersonation_tokens_path(@user), data: { qa_selector: 'impersonation_tokens_tab' } .gl-mb-3 |