Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2022-06-30 21:09:30 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2022-06-30 21:09:30 +0300
commit370736438075748c36abd7fd7dd32a8ef98048f9 (patch)
treed74dd4529092edeb7dcb914bf0311f962d89e7bb /app/assets/javascripts/batch_comments
parente7b262a4c5cf70fed6eb25ba7a0eb1336e6eb639 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/assets/javascripts/batch_comments')
-rw-r--r--app/assets/javascripts/batch_comments/components/submit_dropdown.vue20
1 files changed, 19 insertions, 1 deletions
diff --git a/app/assets/javascripts/batch_comments/components/submit_dropdown.vue b/app/assets/javascripts/batch_comments/components/submit_dropdown.vue
index 5f4a1e44ea3..b070848cae9 100644
--- a/app/assets/javascripts/batch_comments/components/submit_dropdown.vue
+++ b/app/assets/javascripts/batch_comments/components/submit_dropdown.vue
@@ -22,6 +22,18 @@ export default {
computed: {
...mapGetters(['getNotesData', 'getNoteableData', 'noteableType', 'getCurrentUserLastNote']),
},
+ mounted() {
+ // We override the Bootstrap Vue click outside behaviour
+ // to allow for clicking in the autocomplete dropdowns
+ // without this override the submit dropdown will close
+ // whenever a item in the autocomplete dropdown is clicked
+ const originalClickOutHandler = this.$refs.dropdown.$refs.dropdown.clickOutHandler;
+ this.$refs.dropdown.$refs.dropdown.clickOutHandler = (e) => {
+ if (!e.target.closest('.atwho-container')) {
+ originalClickOutHandler(e);
+ }
+ };
+ },
methods: {
...mapActions('batchComments', ['publishReview']),
async submitReview() {
@@ -52,7 +64,13 @@ export default {
</script>
<template>
- <gl-dropdown right class="submit-review-dropdown" variant="info" category="secondary">
+ <gl-dropdown
+ ref="dropdown"
+ right
+ class="submit-review-dropdown"
+ variant="info"
+ category="secondary"
+ >
<template #button-content>
{{ __('Finish review') }}
<gl-icon class="dropdown-chevron" name="chevron-up" />