aboutsummaryrefslogtreecommitdiffstats
path: root/core/src
diff options
context:
space:
mode:
authorFerdinand Thiessen <opensource@fthiessen.de>2024-04-17 14:06:29 +0200
committerFerdinand Thiessen <opensource@fthiessen.de>2024-04-17 14:06:29 +0200
commit16eebd37430caec90c3df7a5c447d660ad0e2eda (patch)
tree2cfd2695d384d80a081657912fd2a242f6d5fa5c /core/src
parenta86c1131d7092b4abb1abac8a55f2e71f7a2bbaa (diff)
downloadnextcloud-server-16eebd37430caec90c3df7a5c447d660ad0e2eda.tar.gz
nextcloud-server-16eebd37430caec90c3df7a5c447d660ad0e2eda.zip
fix(files): Ensure search query is cleared when changing view or directory
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
Diffstat (limited to 'core/src')
-rw-r--r--core/src/views/UnifiedSearchModal.vue10
1 files changed, 6 insertions, 4 deletions
diff --git a/core/src/views/UnifiedSearchModal.vue b/core/src/views/UnifiedSearchModal.vue
index b33cebed8e2..365a7818509 100644
--- a/core/src/views/UnifiedSearchModal.vue
+++ b/core/src/views/UnifiedSearchModal.vue
@@ -13,12 +13,13 @@
<div class="unified-search-modal__header">
<h2>{{ t('core', 'Unified search') }}</h2>
<NcInputField ref="searchInput"
+ data-cy-unified-search-input
:value.sync="searchQuery"
type="text"
:label="t('core', 'Search apps, files, tags, messages') + '...'"
@update:value="debouncedFind" />
- <div class="unified-search-modal__filters">
- <NcActions :menu-name="t('core', 'Places')" :open.sync="providerActionMenuIsOpen">
+ <div class="unified-search-modal__filters" data-cy-unified-search-filters>
+ <NcActions :menu-name="t('core', 'Places')" :open.sync="providerActionMenuIsOpen" data-cy-unified-search-filter="places">
<template #icon>
<ListBox :size="20" />
</template>
@@ -33,7 +34,7 @@
{{ provider.name }}
</NcActionButton>
</NcActions>
- <NcActions :menu-name="t('core', 'Date')" :open.sync="dateActionMenuIsOpen">
+ <NcActions :menu-name="t('core', 'Date')" :open.sync="dateActionMenuIsOpen" data-cy-unified-search-filter="date">
<template #icon>
<CalendarRangeIcon :size="20" />
</template>
@@ -59,6 +60,7 @@
<SearchableList :label-text="t('core', 'Search people')"
:search-list="userContacts"
:empty-content-text="t('core', 'Not found')"
+ data-cy-unified-search-filter="people"
@search-term-change="debouncedFilterContacts"
@item-selected="applyPersonFilter">
<template #trigger>
@@ -70,7 +72,7 @@
</NcButton>
</template>
</SearchableList>
- <NcButton v-if="supportFiltering" @click="closeModal">
+ <NcButton v-if="supportFiltering" data-cy-unified-search-filter="current-view" @click="closeModal">
{{ t('core', 'Filter in current view') }}
<template #icon>
<FilterIcon :size="20" />