Commit 6c958dd9 authored by Mark Florian's avatar Mark Florian

Merge branch...

Merge branch '336690-Migrate-group-access-token-checkbox-to-gitlab_ui_checkbox_component' into 'master'

Migrate project access token creation checkbox to gitlab_ui_checkbox_component

See merge request gitlab-org/gitlab!66698
parents cb05bad5 648f2366
- return unless render_setting_to_allow_project_access_token_creation?(group) - return unless render_setting_to_allow_project_access_token_creation?(group)
.form-group.gl-mb-3 .form-group.gl-mb-3
.gl-form-checkbox.custom-control.custom-checkbox - project_access_tokens_link = help_page_path('user/project/settings/project_access_tokens')
= f.check_box :resource_access_token_creation_allowed, checked: group.namespace_settings.resource_access_token_creation_allowed?, class: 'custom-control-input', data: { qa_selector: 'resource_access_token_creation_allowed_checkbox' } - link_start = '<a href="%{url}" target="_blank" rel="noopener noreferrer">'.html_safe % { url: project_access_tokens_link }
= f.label :resource_access_token_creation_allowed, class: 'custom-control-label' do = f.gitlab_ui_checkbox_component :resource_access_token_creation_allowed,
%span= s_('GroupSettings|Allow project access token creation') s_('GroupSettings|Allow project access token creation'),
- project_access_tokens_link = help_page_path('user/project/settings/project_access_tokens') checkbox_options: { checked: group.namespace_settings.resource_access_token_creation_allowed?, data: { qa_selector: 'resource_access_token_creation_allowed_checkbox' } },
- link_start = '<a href="%{url}" target="_blank" rel="noopener noreferrer">'.html_safe % { url: project_access_tokens_link } help_text: s_('GroupSettings|Users can create %{link_start}project access tokens%{link_end} for projects in this group.').html_safe % { link_start: link_start, link_end: '</a>'.html_safe }
%p.help-text= s_('GroupSettings|Users can create %{link_start}project access tokens%{link_end} for projects in this group.').html_safe % { link_start: link_start, link_end: '</a>'.html_safe }
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