better impl of header hiding?

This commit is contained in:
Henry Jameson 2025-11-20 21:17:44 +02:00
commit 8b8af2889b
3 changed files with 22 additions and 16 deletions

View file

@ -76,7 +76,7 @@ const SettingsModalContent = {
data () {
return {
navCollapsed: false,
childCollapsed: false
navHideHeader: false
}
},
methods: {
@ -97,15 +97,15 @@ const SettingsModalContent = {
},
nestedTooBig () {
this.navCollapsed = false
this.childCollapsed = this.$refs.generalTab.getNavMode()
console.log(this.navCollapsed, this.childCollapsed)
this.$refs.tabSwitcher.showNav()
},
nestedTooSmall () {
this.navCollapsed = true
this.childCollapsed = this.$refs.generalTab.getNavMode()
console.log(this.navCollapsed, this.childCollapsed)
this.$refs.tabSwitcher.hideNav()
},
nestedNavSide (side) {
console.log('SWITCH')
this.navHideHeader = side === 'content'
}
},
mounted () {

View file

@ -5,6 +5,7 @@
:scrollable-tabs="true"
:child-collapsed="childCollapsed"
:body-scroll-lock="bodyLock"
:hide-header="navHideHeader"
>
<div
:full-width="true"
@ -16,6 +17,7 @@
class="inner-tab -middle"
ref="generalTab"
:parent-collapsed="navCollapsed"
@side-switch="(side) => nestedNavSide(side)"
@too-small="() => nestedTooSmall()"
@too-big="() => nestedTooBig()"
/>