diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-05-02 12:10:46 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-05-02 12:10:46 +0300 |
commit | f3b405856d99583bcd2f27c909abe779a48db512 (patch) | |
tree | 82d3ec2494523fb5b52f3f852be978c6b7263651 /app/assets/javascripts/vue_merge_request_widget | |
parent | 9ecca14b2b3f05673a15399a2d1cc439206f3e0f (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/assets/javascripts/vue_merge_request_widget')
2 files changed, 6 insertions, 7 deletions
diff --git a/app/assets/javascripts/vue_merge_request_widget/components/mr_widget_how_to_merge_modal.vue b/app/assets/javascripts/vue_merge_request_widget/components/mr_widget_how_to_merge_modal.vue index 729782cd7a1..c2a3ae361ca 100644 --- a/app/assets/javascripts/vue_merge_request_widget/components/mr_widget_how_to_merge_modal.vue +++ b/app/assets/javascripts/vue_merge_request_widget/components/mr_widget_how_to_merge_modal.vue @@ -113,8 +113,10 @@ export default { }, }, mounted() { - document.querySelector('.js-check-out-modal-trigger')?.addEventListener('click', () => { - this.$refs.modal.show(); + document.addEventListener('click', (e) => { + if (e.target.closest('.js-check-out-modal-trigger')) { + this.$refs.modal.show(); + } }); }, }; diff --git a/app/assets/javascripts/vue_merge_request_widget/components/states/mr_widget_conflicts.vue b/app/assets/javascripts/vue_merge_request_widget/components/states/mr_widget_conflicts.vue index 7435f578852..def30dacf8a 100644 --- a/app/assets/javascripts/vue_merge_request_widget/components/states/mr_widget_conflicts.vue +++ b/app/assets/javascripts/vue_merge_request_widget/components/states/mr_widget_conflicts.vue @@ -1,5 +1,5 @@ <script> -import { GlButton, GlModalDirective, GlSkeletonLoader } from '@gitlab/ui'; +import { GlButton, GlSkeletonLoader } from '@gitlab/ui'; import glFeatureFlagMixin from '~/vue_shared/mixins/gl_feature_flags_mixin'; import mergeRequestQueryVariablesMixin from '../../mixins/merge_request_query_variables'; import userPermissionsQuery from '../../queries/permissions.query.graphql'; @@ -13,9 +13,6 @@ export default { StatusIcon, GlButton, }, - directives: { - GlModalDirective, - }, mixins: [glFeatureFlagMixin(), mergeRequestQueryVariablesMixin], apollo: { userPermissions: { @@ -131,9 +128,9 @@ export default { </gl-button> <gl-button v-if="canMerge" - v-gl-modal-directive="'modal-merge-info'" :size="glFeatures.restructuredMrWidget ? 'small' : 'medium'" data-testid="merge-locally-button" + class="js-check-out-modal-trigger" > {{ s__('mrWidget|Resolve locally') }} </gl-button> |