diff --git a/assets/components/container/container.vue b/assets/components/container/container.vue index a5d9c1bb..ef97292d 100644 --- a/assets/components/container/container.vue +++ b/assets/components/container/container.vue @@ -10,15 +10,24 @@ -
+
+ + @@ -26,11 +35,17 @@ import Warning from './warning.vue'; import Header from '../header/header.vue'; import Sidebar from '../sidebar/sidebar.vue'; +import Filters from './filters.vue'; function toggleSidebar(state) { this.showSidebar = typeof state === 'boolean' ? state : !this.showSidebar; } +function toggleFilters(state) { + this.showFilters = state; + this.showSidebar = false; +} + async function setConsent(consent) { if (consent) { this.showWarning = false; @@ -61,17 +76,20 @@ export default { Header, Sidebar, Warning, + Filters, }, data() { return { showSidebar: false, showWarning: localStorage.getItem('consent') !== window.env.sessionId, + showFilters: false, }; }, mounted, beforeUnmount, methods: { toggleSidebar, + toggleFilters, setConsent, blur, resize, diff --git a/assets/components/header/filters.vue b/assets/components/container/filters.vue similarity index 100% rename from assets/components/header/filters.vue rename to assets/components/container/filters.vue diff --git a/assets/components/header/header.vue b/assets/components/header/header.vue index d3ea6d4a..3d8a54fd 100644 --- a/assets/components/header/header.vue +++ b/assets/components/header/header.vue @@ -31,7 +31,7 @@ @@ -157,11 +157,6 @@ - - @@ -175,6 +190,7 @@ export default { components: { Search, }, + emits: ['toggleSidebar', 'showFilters'], data() { return { logo, @@ -240,6 +256,12 @@ export default { margin: 0; } +.sidebar-section { + display: flex; + flex-direction: column; + overflow: hidden; +} + .logo-link { display: block; height: 100%; @@ -265,6 +287,11 @@ export default { } } +.nav { + flex-grow: 1; + overflow-x: auto; +} + .nav-item { display: block; } @@ -286,13 +313,13 @@ export default { } .toggles { + flex-shrink: 0; border-top: solid 1px var(--shadow-hint); margin: .5rem 0 0 0; } .toggle { display: flex; - align-self: flex-end; padding: 1rem; color: var(--shadow); font-weight: bold; diff --git a/assets/js/router.js b/assets/js/router.js index 0b3f2924..1ef29b75 100644 --- a/assets/js/router.js +++ b/assets/js/router.js @@ -151,9 +151,9 @@ const routes = [ name: 'actors', }, { - path: '/networks', + path: '/channels', component: Networks, - name: 'networks', + name: 'channels', }, { path: '/movies',