Skip to content

Commit

Permalink
Navbar is less stupid now
Browse files Browse the repository at this point in the history
  • Loading branch information
Zeanon committed Jul 30, 2023
1 parent 88409b9 commit 6feb529
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "mainsail",
"version": "2.6.9",
"version": "2.6.10",
"private": true,
"decription": "a klipper web interface",
"author": {
Expand Down
4 changes: 2 additions & 2 deletions src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,8 @@ export default class App extends Mixins(BaseMixin) {
}
// overwrite padding left for the sidebar
if (this.naviDrawer && this.navigationStyle === 'iconsAndText') style.paddingLeft = '220px'
if (this.naviDrawer && this.navigationStyle === 'iconsOnly') style.paddingLeft = '56px'
if (!this.isMobile && this.naviDrawer && this.navigationStyle === 'iconsAndText') style.paddingLeft = '220px'
if (!this.isMobile && this.naviDrawer && this.navigationStyle === 'iconsOnly') style.paddingLeft = '56px'
return style
}
Expand Down
6 changes: 5 additions & 1 deletion src/components/TheSidebar.vue
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<template>
<v-navigation-drawer
:key="navigationStyle"
:value="naviDrawer"
v-model="naviDrawer"
:src="sidebarBackground"
:mini-variant="navigationStyle === 'iconsOnly'"
:width="navigationWidth"
Expand Down Expand Up @@ -70,6 +70,10 @@ export default class TheSidebar extends Mixins(NavigationMixin, BaseMixin) {
return this.$store.state.naviDrawer
}
set naviDrawer(newVal) {
this.$store.dispatch('setNaviDrawer', newVal)
}
get navigationStyle() {
return this.$store.state.gui.uiSettings.navigationStyle
}
Expand Down

0 comments on commit 6feb529

Please sign in to comment.