Skip to content

Commit

Permalink
perf: clear key filter after switch database
Browse files Browse the repository at this point in the history
  • Loading branch information
tiny-craft committed Mar 25, 2024
1 parent adf9e43 commit cc696f9
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions frontend/src/components/sidebar/BrowserPane.vue
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ const browserStore = useBrowserStore()
const connectionStore = useConnectionStore()
const render = useRender()
const browserTreeRef = ref(null)
const filterInputRef = ref(null)
const loading = ref(false)
const fullyLoaded = ref(false)
const inCheckState = ref(false)
Expand Down Expand Up @@ -207,6 +208,7 @@ const handleSelectDB = async (db) => {
loading.value = true
browserStore.setKeyFilter(props.server, {})
browserStore.closeDatabase(props.server, props.db)
filterInputRef.value?.reset()
await browserStore.openDatabase(props.server, db)
await nextTick()
await connectionStore.saveLastDB(props.server, db)
Expand Down Expand Up @@ -291,6 +293,7 @@ watch(
<!-- top function bar -->
<div class="flex-box-h nav-pane-func" style="height: 36px">
<content-search-input
ref="filterInputRef"
:debounce-wait="1000"
:full-search-icon="Search"
small
Expand Down

0 comments on commit cc696f9

Please sign in to comment.