main pages/styles

This commit is contained in:
2025-06-02 16:03:54 +02:00
parent 9246f80857
commit 2ffd64da98
16 changed files with 301 additions and 87 deletions

View File

@ -7,6 +7,7 @@ export const useStore = defineStore("store", () => {
const pb = usePB();
const { $i18n } = useNuxtApp();
const menuStore = useMenuStore()
const colorMode = useColorMode()
const components = ref({} as PBPageItem[]);
const getSections = async (id: string) => {
@ -60,9 +61,19 @@ export const useStore = defineStore("store", () => {
return [];
}
const isDark = computed({
get() {
return colorMode.value === "dark";
},
set(_isDark) {
colorMode.preference = _isDark ? "dark" : "light";
},
});
return {
currentPageID,
components,
isDark,
getComponents,
getSections,
};