diff --git a/app/assets/javascripts/issue.js b/app/assets/javascripts/issue.js index f1b37525a6dfbc3f0de80045edb274d225c5ff95..ad0147bdca2a470456bf9a11e5fba80d3abb46ab 100644 --- a/app/assets/javascripts/issue.js +++ b/app/assets/javascripts/issue.js @@ -173,11 +173,15 @@ export default class Issue { } initIssueWarningBtnEventListener() { - return $(document).on('click', '.js-close-blocked-issue-warning button.btn-secondary', e => { - e.preventDefault(); - e.stopImmediatePropagation(); - this.toggleWarningAndCloseButton(); - }); + return $(document).on( + 'click', + '.js-close-blocked-issue-warning .js-cancel-blocked-issue-warning', + e => { + e.preventDefault(); + e.stopImmediatePropagation(); + this.toggleWarningAndCloseButton(); + }, + ); } initIssueMovedFromServiceDeskDismissHandler() { diff --git a/app/views/shared/_no_ssh.html.haml b/app/views/shared/_no_ssh.html.haml index abf39fdc6442f6bc3c33fa58375ab0b5523fe80f..a083a772233a2093ecafb38f65abf0d3ba9a60df 100644 --- a/app/views/shared/_no_ssh.html.haml +++ b/app/views/shared/_no_ssh.html.haml @@ -7,4 +7,4 @@ = s_("MissingSSHKeyWarningLink|You won't be able to pull or push project code via SSH until you add an SSH key to your profile").html_safe .gl-alert-actions = link_to s_('MissingSSHKeyWarningLink|Add SSH key'), profile_keys_path, class: "btn gl-alert-action btn-warning btn-md new-gl-button" - = link_to s_("MissingSSHKeyWarningLink|Don't show again"), profile_path(user: {hide_no_ssh_key: true}), method: :put, role: 'button', class: 'btn gl-alert-action btn-md btn-warning btn-secondary new-gl-button' + = link_to s_("MissingSSHKeyWarningLink|Don't show again"), profile_path(user: {hide_no_ssh_key: true}), method: :put, role: 'button', class: 'btn gl-alert-action btn-md btn-warning gl-button btn-warning-secondary' diff --git a/ee/app/assets/javascripts/vue_shared/security_reports/components/dast_modal.vue b/ee/app/assets/javascripts/vue_shared/security_reports/components/dast_modal.vue index 4f5e8ca708bcc6c664fa1caf997485e66ebbbd60..a4f38f9105cb96edc0ee5adf5810c78d87a87bc0 100644 --- a/ee/app/assets/javascripts/vue_shared/security_reports/components/dast_modal.vue +++ b/ee/app/assets/javascripts/vue_shared/security_reports/components/dast_modal.vue @@ -38,7 +38,7 @@ export default { text: __('Download as CSV'), attributes: { variant: 'success', - class: 'btn-secondary gl-button', + class: 'gl-button btn-success-secondary', href: this.downloadLink, download: '', 'data-testid': 'download-button', diff --git a/ee/app/views/layouts/header/_licensed_user_count_threshold.html.haml b/ee/app/views/layouts/header/_licensed_user_count_threshold.html.haml index 5783a04ac7449b2a5c7fb589841665c777d75668..3d5c5a48d5e7680a806b683cd051baa173553eaf 100644 --- a/ee/app/views/layouts/header/_licensed_user_count_threshold.html.haml +++ b/ee/app/views/layouts/header/_licensed_user_count_threshold.html.haml @@ -9,4 +9,4 @@ = _('Your instance has %{remaining_user_count} users remaining of the %{total_user_count} included in your subscription. You can add more users than the number included in your license, and we will include the overage in your next bill.') % { remaining_user_count: remaining_user_count, total_user_count: total_user_count } .gl-alert-actions = link_to _('View users statistics'), admin_users_path, class: 'btn gl-alert-action btn-info btn-md gl-button' - = link_to _('Contact support'), EE::CUSTOMER_LICENSE_SUPPORT_URL, rel: 'nofollow', class: 'btn gl-alert-action btn-info btn-md btn-secondary gl-button' + = link_to _('Contact support'), EE::CUSTOMER_LICENSE_SUPPORT_URL, rel: 'nofollow', class: 'btn gl-alert-action btn-info btn-md gl-button btn-info-secondary' diff --git a/ee/app/views/projects/issues/_alert_blocked.html.haml b/ee/app/views/projects/issues/_alert_blocked.html.haml index 018f2326b5e983665965c384b0e3c53cd3428280..49ed85f603e2e3e9b1170c1bc5eda6ddd9d8a669 100644 --- a/ee/app/views/projects/issues/_alert_blocked.html.haml +++ b/ee/app/views/projects/issues/_alert_blocked.html.haml @@ -11,5 +11,5 @@ .gl-alert-actions %button{ class: "btn btn-close-anyway gl-alert-action btn-warning btn-md gl-button", data: { endpoint: close_issuable_path(@issue) } } = _("Yes, close issue") - %button.btn.gl-alert-action.btn-warning.btn-md.gl-button.btn-secondary + %button.btn.gl-alert-action.btn-warning.btn-md.gl-button.btn-warning-secondary.js-cancel-blocked-issue-warning = s_('Cancel') diff --git a/ee/spec/frontend/issue_spec.js b/ee/spec/frontend/issue_spec.js index 62fc19218725367718198d2dcbe4af50454a0c23..6a87120484a4e2c56b65b383733c7a8316fb297d 100644 --- a/ee/spec/frontend/issue_spec.js +++ b/ee/spec/frontend/issue_spec.js @@ -78,7 +78,7 @@ describe('Issue', () => { setImmediate(() => { expect($alert).not.toHaveClass('hidden'); - const $cancelbtn = $('.js-close-blocked-issue-warning .btn-secondary'); + const $cancelbtn = $('.js-close-blocked-issue-warning .js-cancel-blocked-issue-warning'); $cancelbtn.trigger('click'); expect($alert).toHaveClass('hidden'); diff --git a/ee/spec/frontend/notes/components/comment_form_spec.js b/ee/spec/frontend/notes/components/comment_form_spec.js index c75e1ea2a658559a5aeb4f7b1e92241fe5f5a2e4..8dd3878196c819d91e0e3341f14b0cb62103c8ba 100644 --- a/ee/spec/frontend/notes/components/comment_form_spec.js +++ b/ee/spec/frontend/notes/components/comment_form_spec.js @@ -133,7 +133,7 @@ describe('issue_comment_form component', () => { wrapper.vm.$nextTick(() => { const warning = wrapper.find('.gl-alert-warning'); - const secondaryButton = warning.find('.gl-alert-actions .btn-secondary'); + const secondaryButton = warning.find('.gl-alert-actions .btn-default'); expect(secondaryButton.text()).toEqual('Cancel'); secondaryButton.trigger('click'); wrapper.vm.$nextTick(() => { diff --git a/package.json b/package.json index 8c3f27849e5a177c219fd39679a7f730f5adb179..2d80fb258e0b6165734174e0fa9e400ce4946119 100644 --- a/package.json +++ b/package.json @@ -43,7 +43,7 @@ "@babel/preset-env": "^7.10.1", "@gitlab/at.js": "1.5.5", "@gitlab/svgs": "1.158.0", - "@gitlab/ui": "20.4.0", + "@gitlab/ui": "20.4.1", "@gitlab/visual-review-tools": "1.6.1", "@rails/actioncable": "^6.0.3-1", "@sentry/browser": "^5.10.2", diff --git a/spec/frontend/vue_shared/components/__snapshots__/expand_button_spec.js.snap b/spec/frontend/vue_shared/components/__snapshots__/expand_button_spec.js.snap index cd4728baeaa6b68f9921b178b9d1f716329076ee..c2b97f1e7f9607b08fc2b2f8655f06f0f9cdcdb2 100644 --- a/spec/frontend/vue_shared/components/__snapshots__/expand_button_spec.js.snap +++ b/spec/frontend/vue_shared/components/__snapshots__/expand_button_spec.js.snap @@ -4,7 +4,7 @@ exports[`Expand button on click when short text is provided renders button after <span> <button aria-label="Click to expand text" - class="btn js-text-expander-prepend text-expander btn-blank btn-default btn-md btn-icon button-ellipsis-horizontal gl-button" + class="btn js-text-expander-prepend text-expander btn-blank btn-default btn-md gl-button btn-icon button-ellipsis-horizontal" style="display: none;" type="button" > @@ -32,7 +32,7 @@ exports[`Expand button on click when short text is provided renders button after <button aria-label="Click to expand text" - class="btn js-text-expander-append text-expander btn-blank btn-default btn-md btn-icon button-ellipsis-horizontal gl-button" + class="btn js-text-expander-append text-expander btn-blank btn-default btn-md gl-button btn-icon button-ellipsis-horizontal" style="" type="button" > @@ -56,7 +56,7 @@ exports[`Expand button when short text is provided renders button before text 1` <span> <button aria-label="Click to expand text" - class="btn js-text-expander-prepend text-expander btn-blank btn-default btn-md btn-icon button-ellipsis-horizontal gl-button" + class="btn js-text-expander-prepend text-expander btn-blank btn-default btn-md gl-button btn-icon button-ellipsis-horizontal" type="button" > <!----> @@ -83,7 +83,7 @@ exports[`Expand button when short text is provided renders button before text 1` <button aria-label="Click to expand text" - class="btn js-text-expander-append text-expander btn-blank btn-default btn-md btn-icon button-ellipsis-horizontal gl-button" + class="btn js-text-expander-append text-expander btn-blank btn-default btn-md gl-button btn-icon button-ellipsis-horizontal" style="display: none;" type="button" > diff --git a/yarn.lock b/yarn.lock index fd2ecde5850044523ae6cbd671b2b89cd236c248..c6517512cfb846626b7b227bbd4036da9d1088d4 100644 --- a/yarn.lock +++ b/yarn.lock @@ -848,10 +848,10 @@ resolved "https://registry.yarnpkg.com/@gitlab/svgs/-/svgs-1.158.0.tgz#300d416184a2b0e05f15a96547f726e1825b08a1" integrity sha512-5OJl+7TsXN9PJhY6/uwi+mTwmDZa9n/6119rf77orQ/joFYUypaYhBmy/1TcKVPsy5Zs6KCxE1kmGsfoXc1TYA== -"@gitlab/ui@20.4.0": - version "20.4.0" - resolved "https://registry.yarnpkg.com/@gitlab/ui/-/ui-20.4.0.tgz#ea5195b181f56312ede55e89c444805594adedbb" - integrity sha512-QLxj0a2iRDuSvAdvgZf8KtpUg8Bt8jSQbupCdiiohSp73LidRB4aZv0b/TTb6sxpmhKRaKSx9uqHrpHXtymGyw== +"@gitlab/ui@20.4.1": + version "20.4.1" + resolved "https://registry.yarnpkg.com/@gitlab/ui/-/ui-20.4.1.tgz#a57f5f898971976077fcc3898a33a870651e62dd" + integrity sha512-HFBiT7KNNKcNdYEze87d8n8G7rC1ZGWgbLcrxxBO3ojjqQsEab7tfufors7a7TOnCvbnWLlABYlX3uDkvOX6cg== dependencies: "@babel/standalone" "^7.0.0" "@gitlab/vue-toasted" "^1.3.0"