From 5a9e28f85e37793da229944432a75daa9d2b91c9 Mon Sep 17 00:00:00 2001 From: axolotle Date: Tue, 29 Jun 2021 16:09:49 +0200 Subject: [PATCH] give more control over options display --- src/pages/_partials/MainHeader.vue | 28 ++++++++++++++++++---------- src/pages/library/LibraryOptions.vue | 8 ++------ src/store/modules/library.js | 9 +++++++++ src/store/nodes.js | 10 +++++++--- 4 files changed, 36 insertions(+), 19 deletions(-) diff --git a/src/pages/_partials/MainHeader.vue b/src/pages/_partials/MainHeader.vue index 369afc5..464350f 100644 --- a/src/pages/_partials/MainHeader.vue +++ b/src/pages/_partials/MainHeader.vue @@ -67,8 +67,16 @@ export default { { to: 'kit', variant: 'kit' }, { to: 'gallery', variant: 'creation' } ], - subRoutes: ['home', 'introduction', 'blog', 'contact'], - optionsVisible: window.innerWidth >= 768 + subRoutes: ['home', 'introduction', 'blog', 'contact'] + } + }, + + computed: { + optionsVisible: { + get () { return this.$store.state.optionsVisible }, + set (value) { + this.$store.commit('UPDATE_OPTIONS_VISIBILITY', value) + } } } } @@ -224,12 +232,12 @@ export default { } } -#collapse-options { - @include media-breakpoint-down(sm) { - position: absolute; - z-index: 11; - width: 100%; - border-bottom: $line; - } -} +// #collapse-options { +// @include media-breakpoint-down(sm) { +// position: absolute; +// z-index: 11; +// width: 100%; +// border-bottom: $line; +// } +// } diff --git a/src/pages/library/LibraryOptions.vue b/src/pages/library/LibraryOptions.vue index 7aa9ff6..d3ca204 100644 --- a/src/pages/library/LibraryOptions.vue +++ b/src/pages/library/LibraryOptions.vue @@ -1,5 +1,5 @@