{"version":3,"file":"Ds6DN8-J.js","sources":["../../../../components/SideNav.vue","../../../../store/dialog.ts","../../../../components/Dialog.vue","../../../../components/LoaderOverlay.vue","../../../../composables/useResize.ts","../../../../components/Main.vue"],"sourcesContent":["\n\n\n\n\n","import { defineStore } from 'pinia';\nimport type { ShallowRef } from 'vue';\n\ninterface Dialog {\n title: string;\n message: string;\n component?: ShallowRef;\n cancel?: () => void;\n execute: (_arg?: unknown) => void;\n}\n\n// Use options store for better dev tools integration\nexport const useDialogStore = defineStore('Dialog', {\n state: () => ({\n $visible: false as boolean,\n $title: '',\n $message: '',\n $component: null as ShallowRef | null,\n $cancel: () => {},\n $execute: (_arg?: unknown) => {},\n }),\n\n getters: {\n isVisible: (state) => state.$visible,\n title: (state) => state.$title,\n message: (state) => state.$message,\n component: (state) => state.$component,\n },\n\n actions: {\n setVisibility(visible: boolean) {\n this.$visible = visible;\n },\n\n showDialog(dialog: Dialog) {\n this.$visible = true;\n this.$title = dialog.title;\n\n this.$message = dialog.message;\n this.$execute = dialog.execute;\n\n if (dialog.component) this.$component = dialog.component;\n if (dialog.cancel) this.$cancel = dialog.cancel;\n },\n\n execute(arg?: unknown) {\n this.$execute(arg);\n this.resetState();\n },\n\n cancel() {\n this.$cancel();\n this.resetState();\n },\n\n resetState() {\n this.$title = '';\n this.$message = '';\n\n this.$component = null;\n\n this.$cancel = () => {};\n this.$execute = () => {};\n\n this.$visible = false;\n },\n },\n});\n","\n\n\n\n\n","\n\n\n\n\n","import { onMounted, onUnmounted, ref } from 'vue';\n\nexport function useWindowResize(\n shrinkHeightBy: number = 0,\n shrinkWidthBy: number = 0\n) {\n const height = ref(\n (window.visualViewport?.height ?? window.innerHeight) - shrinkHeightBy\n );\n const width = ref(\n (window.visualViewport?.width ?? window.innerWidth) - shrinkWidthBy\n );\n\n function handler() {\n height.value =\n (window.visualViewport?.height ?? window.innerHeight) - shrinkHeightBy;\n width.value =\n (window.visualViewport?.width ?? window.innerWidth) - shrinkWidthBy;\n }\n\n onMounted(() => window.addEventListener('resize', handler));\n onUnmounted(() => window.removeEventListener('resize', handler));\n\n return {\n height,\n heightpx: `${height.value}px`,\n width,\n widthpx: `${width.value}px`,\n };\n}\n","\n\n\n\n\n"],"names":["authStore","useAuthStore","isLoggedIn","computed","isAdmin","_a","useDialogStore","defineStore","_arg","state","visible","dialog","arg","theme","useTheme","color","ref","dialogStore","loaderStore","useLoaderStore","useWindowResize","shrinkHeightBy","shrinkWidthBy","height","width","_b","handler","onMounted","onUnmounted","props","__props","xs","useDisplay","themeClass"],"mappings":"mzBAGA,MAAMA,EAAYC,IAEZC,EAAaC,EAAS,IACnBH,EAAU,SAAW,IAC7B,EACKI,EAAUD,EAAS,IAAM,OAC7B,OAAOE,EAAAL,EAAU,UAAV,YAAAK,EAAmB,OAAA,CAC3B,itCCEYC,GAAiBC,EAAY,SAAU,CAClD,MAAO,KAAO,CACZ,SAAU,GACV,OAAQ,GACR,SAAU,GACV,WAAY,KACZ,QAAS,IAAM,CAAC,EAChB,SAAWC,GAAmB,CAAC,CAAA,GAGjC,QAAS,CACP,UAAYC,GAAUA,EAAM,SAC5B,MAAQA,GAAUA,EAAM,OACxB,QAAUA,GAAUA,EAAM,SAC1B,UAAYA,GAAUA,EAAM,UAC9B,EAEA,QAAS,CACP,cAAcC,EAAkB,CAC9B,KAAK,SAAWA,CAClB,EAEA,WAAWC,EAAgB,CACzB,KAAK,SAAW,GAChB,KAAK,OAASA,EAAO,MAErB,KAAK,SAAWA,EAAO,QACvB,KAAK,SAAWA,EAAO,QAEnBA,EAAO,YAAW,KAAK,WAAaA,EAAO,WAC3CA,EAAO,SAAQ,KAAK,QAAUA,EAAO,OAC3C,EAEA,QAAQC,EAAe,CACrB,KAAK,SAASA,CAAG,EACjB,KAAK,WAAW,CAClB,EAEA,QAAS,CACP,KAAK,QAAQ,EACb,KAAK,WAAW,CAClB,EAEA,YAAa,CACX,KAAK,OAAS,GACd,KAAK,SAAW,GAEhB,KAAK,WAAa,KAElB,KA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