Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions components.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,9 @@ declare module 'vue' {
AppNamedSwitch: typeof import('./src/components/ui/AppNamedSwitch.vue')['default']
AppNamedTextField: typeof import('./src/components/ui/AppNamedTextField.vue')['default']
AppNavDrawer: typeof import('./src/components/layout/AppNavDrawer.vue')['default']
AppNavExternalItem: typeof import('./src/components/ui/AppNavExternalItem.vue')['default']
AppNavItem: typeof import('./src/components/ui/AppNavItem.vue')['default']
AppNavLinkIcon: typeof import('./src/components/ui/AppNavLinkIcon.vue')['default']
AppNotificationMenu: typeof import('./src/components/layout/AppNotificationMenu.vue')['default']
AppObservedColumn: typeof import('./src/components/layout/AppObservedColumn.vue')['default']
AppQrCode: typeof import('./src/components/ui/AppQrCode.vue')['default']
Expand Down Expand Up @@ -79,6 +81,7 @@ declare module 'vue' {
VAlert: typeof import('vuetify/lib')['VAlert']
VApp: typeof import('vuetify/lib')['VApp']
VAppBar: typeof import('vuetify/lib')['VAppBar']
VAutocomplete: typeof import('vuetify/lib')['VAutocomplete']
VBadge: typeof import('vuetify/lib')['VBadge']
VBtn: typeof import('vuetify/lib')['VBtn']
VBtnToggle: typeof import('vuetify/lib')['VBtnToggle']
Expand Down
267 changes: 239 additions & 28 deletions public/config.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/logo_eva.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion public/logo_ratrig.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion public/logo_z-bolt.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
273 changes: 246 additions & 27 deletions server/config.json

Large diffs are not rendered by default.

22 changes: 21 additions & 1 deletion src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,10 @@
:class="{ 'no-pointer-events': dragState }"
>
<app-tools-drawer v-model="toolsdrawer" />
<app-nav-drawer v-model="navdrawer" />
<app-nav-drawer
v-model="navdrawer"
:sidebar-expanded.sync="sidebarExpanded"
/>

<inline-svg
v-if="showBackgroundLogo && !isMobileViewport"
Expand All @@ -15,6 +18,7 @@
<app-bar
@toolsdrawer="handleToolsDrawerChange"
@navdrawer="handleNavDrawerChange"
@sidebarExpand="handleSidebarExpandToggle"
/>

<flash-message
Expand Down Expand Up @@ -380,6 +384,22 @@ export default class App extends Mixins(StateMixin, FilesMixin, BrowserMixin) {
this.navdrawer = !this.navdrawer
}

get sidebarExpanded (): boolean {
return this.$typedState.config.uiSettings.navigation?.sidebarExpanded ?? false
}

set sidebarExpanded (value: boolean) {
this.$typedDispatch('config/saveByPath', {
path: 'uiSettings.navigation.sidebarExpanded',
value,
server: true
})
}

handleSidebarExpandToggle () {
this.sidebarExpanded = !this.sidebarExpanded
}

handleDragOver (event: DragEvent) {
if (
this.socketConnected &&
Expand Down
7 changes: 4 additions & 3 deletions src/components/layout/AppBar.vue
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,14 @@
:color="$vuetify.theme.currentTheme.appbar"
:height="$globals.HEADER_HEIGHT"
>
<router-link
<div
v-if="!isMobileViewport"
:to="{ name: 'home' }"
class="toolbar-logo"
style="cursor: pointer;"
@click="$emit('sidebarExpand')"
>
<app-icon />
</router-link>
</div>

<div class="toolbar-title">
<app-btn
Expand Down
Loading