[UI] Show menu drawer if on desktop
This commit is contained in:
		
							parent
							
								
									dad88ec766
								
							
						
					
					
						commit
						2fc411d51d
					
				|  | @ -77,7 +77,7 @@ import EssentialLink from 'src/components/navigation/EssentialLink.vue'; | ||||||
| import ShortcutLink from 'src/components/navigation/ShortcutLink.vue'; | import ShortcutLink from 'src/components/navigation/ShortcutLink.vue'; | ||||||
| import Notification from 'src/components/Notification.vue'; | import Notification from 'src/components/Notification.vue'; | ||||||
| import { defineComponent, ref, inject, computed, onBeforeMount, onBeforeUnmount } from 'vue'; | import { defineComponent, ref, inject, computed, onBeforeMount, onBeforeUnmount } from 'vue'; | ||||||
| import { Screen } from 'quasar'; | import { Screen, Platform } from 'quasar'; | ||||||
| import config from 'src/config'; | import config from 'src/config'; | ||||||
| import { useRouter } from 'vue-router'; | import { useRouter } from 'vue-router'; | ||||||
| import { useMainStore } from '@flaschengeist/api'; | import { useMainStore } from '@flaschengeist/api'; | ||||||
|  | @ -105,7 +105,19 @@ export default defineComponent({ | ||||||
|     const router = useRouter(); |     const router = useRouter(); | ||||||
|     const mainStore = useMainStore(); |     const mainStore = useMainStore(); | ||||||
|     const flaschengeist = inject<FG_Plugin.Flaschengeist>('flaschengeist'); |     const flaschengeist = inject<FG_Plugin.Flaschengeist>('flaschengeist'); | ||||||
|     const leftDrawer = ref(false); |     const _leftDrawer = ref<boolean|undefined>(); | ||||||
|  |     const leftDrawer = computed({ | ||||||
|  |       get: () => { | ||||||
|  |         if (_leftDrawer.value !== undefined) { | ||||||
|  |           return _leftDrawer.value | ||||||
|  |         } | ||||||
|  |         if (Platform.is.mobile) { | ||||||
|  |           return false | ||||||
|  |         } | ||||||
|  |         return true | ||||||
|  |       }, | ||||||
|  |       set: (val) => _leftDrawer.value = val | ||||||
|  |   }) | ||||||
|     const leftDrawerMini = ref(false); |     const leftDrawerMini = ref(false); | ||||||
|     const mainLinks = flaschengeist?.menuLinks || []; |     const mainLinks = flaschengeist?.menuLinks || []; | ||||||
|     const notifications = computed(() => mainStore.notifications.slice().reverse()); |     const notifications = computed(() => mainStore.notifications.slice().reverse()); | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue