diff --git a/core/src/views/GlobalSearch.vue b/core/src/views/GlobalSearch.vue
index 2bca15ec905b4..24547fd627089 100644
--- a/core/src/views/GlobalSearch.vue
+++ b/core/src/views/GlobalSearch.vue
@@ -26,7 +26,7 @@
-
+
@@ -54,6 +54,9 @@ export default {
toggleGlobalSearch() {
this.showGlobalSearch = !this.showGlobalSearch
},
+ handleModalVisibilityChange(newVisibilityVal) {
+ this.showGlobalSearch = newVisibilityVal
+ },
},
}
diff --git a/core/src/views/GlobalSearchModal.vue b/core/src/views/GlobalSearchModal.vue
index 9058776780f4a..d598b496b1d0e 100644
--- a/core/src/views/GlobalSearchModal.vue
+++ b/core/src/views/GlobalSearchModal.vue
@@ -2,7 +2,7 @@
@@ -201,6 +201,7 @@ export default {
contacts: [],
debouncedFind: debounce(this.find, 300),
showDateRangeModal: false,
+ internalIsVisible: false,
}
},
@@ -225,12 +226,17 @@ export default {
},
watch: {
isVisible(value) {
+ this.internalIsVisible = value
+ },
+ internalIsVisible(value) {
+ this.$emit('update:isVisible', value)
this.$nextTick(() => {
if (value) {
this.focusInput()
}
})
},
+
},
mounted() {
getProviders().then((providers) => {
@@ -517,7 +523,7 @@ export default {
this.$refs.searchInput.$el.children[0].children[0].focus()
},
closeModal() {
- this.$refs.globalSearchModal.close()
+ this.internalIsVisible = false
this.searchQuery = ''
},
supportFiltering() {