2022-08-24 16:52:01 +08:00
|
|
|
import { ref } from "vue"
|
2022-04-22 01:16:02 +08:00
|
|
|
import { defineStore } from "pinia"
|
|
|
|
import layoutSettings from "@/config/layout"
|
2022-04-21 18:20:39 +08:00
|
|
|
|
2022-08-24 16:52:01 +08:00
|
|
|
export const useSettingsStore = defineStore("settings", () => {
|
|
|
|
const fixedHeader = ref<boolean>(layoutSettings.fixedHeader)
|
|
|
|
const showSettings = ref<boolean>(layoutSettings.showSettings)
|
|
|
|
const showTagsView = ref<boolean>(layoutSettings.showTagsView)
|
|
|
|
const showSidebarLogo = ref<boolean>(layoutSettings.showSidebarLogo)
|
2022-10-31 15:35:51 +08:00
|
|
|
const showNotify = ref<boolean>(layoutSettings.showNotify)
|
2022-08-24 16:52:01 +08:00
|
|
|
const showThemeSwitch = ref<boolean>(layoutSettings.showThemeSwitch)
|
|
|
|
const showScreenfull = ref<boolean>(layoutSettings.showScreenfull)
|
2022-04-21 18:20:39 +08:00
|
|
|
|
2022-10-31 15:35:51 +08:00
|
|
|
return { fixedHeader, showSettings, showTagsView, showSidebarLogo, showNotify, showThemeSwitch, showScreenfull }
|
2022-04-21 18:20:39 +08:00
|
|
|
})
|