diff options
author | Joas Schilling <213943+nickvergessen@users.noreply.github.com> | 2023-08-11 04:42:57 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-11 04:42:57 +0200 |
commit | 529171e446844d1daeb77f23928cd08decc013b7 (patch) | |
tree | 3a4e60e8dfaa4763982afcbce947169db09b5392 | |
parent | d826e780a49b3012eea5078dd9e66f78df9c7475 (diff) | |
parent | 255078243c18f53ab903666126586531fe1d2d2f (diff) |
Merge pull request #10176 from nextcloud/backport/10164/stable27
-rw-r--r-- | lib/Controller/PageController.php | 6 | ||||
-rw-r--r-- | src/components/LeftSidebar/LeftSidebar.vue | 10 | ||||
-rw-r--r-- | src/components/LeftSidebar/SearchBox/SearchBox.vue | 18 |
3 files changed, 10 insertions, 24 deletions
diff --git a/lib/Controller/PageController.php b/lib/Controller/PageController.php index caad0ae60..5c2fb7539 100644 --- a/lib/Controller/PageController.php +++ b/lib/Controller/PageController.php @@ -277,7 +277,7 @@ class PageController extends Controller { $response = new TemplateResponse($this->appName, 'index', [ 'app' => Application::APP_ID, - 'id-app-content' => '#app-content-vue', + 'id-app-content' => '#content-vue', 'id-app-navigation' => '#app-navigation-vue', ]); @@ -328,7 +328,7 @@ class PageController extends Controller { $this->eventDispatcher->dispatchTyped(new RenderReferenceEvent()); $response = new PublicTemplateResponse($this->appName, 'recording', [ - 'id-app-content' => '#app-content-vue', + 'id-app-content' => '#content-vue', 'id-app-navigation' => null, ]); @@ -403,7 +403,7 @@ class PageController extends Controller { $this->eventDispatcher->dispatchTyped(new RenderReferenceEvent()); $response = new PublicTemplateResponse($this->appName, 'index', [ - 'id-app-content' => '#app-content-vue', + 'id-app-content' => '#content-vue', 'id-app-navigation' => null, ]); diff --git a/src/components/LeftSidebar/LeftSidebar.vue b/src/components/LeftSidebar/LeftSidebar.vue index 19ecabaca..966511a51 100644 --- a/src/components/LeftSidebar/LeftSidebar.vue +++ b/src/components/LeftSidebar/LeftSidebar.vue @@ -37,7 +37,10 @@ <TransitionGroup name="radial-reveal"> <!-- Filters --> - <div v-show="!isFocused" key="filters" class="filters"> + <div v-show="searchText === ''" + key="filters" + class="filters" + :class="{'hidden-visually': isFocused}"> <NcActions class="filter-actions" :primary="isFiltered !== null"> <template #icon> @@ -76,9 +79,10 @@ </div> <!-- Actions --> - <div v-show="!isFocused" + <div v-show="searchText === ''" key="actions" - class="actions"> + class="actions" + :class="{'hidden-visually': isFocused}"> <NcActions class="conversations-actions"> <template #icon> <DotsVertical :size="20" /> diff --git a/src/components/LeftSidebar/SearchBox/SearchBox.vue b/src/components/LeftSidebar/SearchBox/SearchBox.vue index c78e34309..d13fab303 100644 --- a/src/components/LeftSidebar/SearchBox/SearchBox.vue +++ b/src/components/LeftSidebar/SearchBox/SearchBox.vue @@ -39,8 +39,6 @@ import Magnify from 'vue-material-design-icons/Magnify.vue' import NcTextField from '@nextcloud/vue/dist/Components/NcTextField.js' -import { EventBus } from '../../../services/EventBus.js' - export default { name: 'SearchBox', components: { @@ -87,16 +85,6 @@ export default { }, }, - mounted() { - this.focusInputIfRoot() - /** - * Listen to routeChange global events and focus on the input - */ - EventBus.$on('route-change', this.focusInputIfRoot) - }, - beforeDestroy() { - EventBus.$off('route-change', this.focusInputIfRoot) - }, methods: { updateValue(value) { this.$emit('update:value', value) @@ -106,12 +94,6 @@ export default { focus() { this.$refs.searchConversations.focus() }, - // Focuses the input if the current route is root. - focusInputIfRoot() { - if (this.$route.name === 'root') { - this.focus() - } - }, /** * Emits the abort-search event and re-focuses the input */ |