diff --git a/src/App.vue b/src/App.vue index f84973b..8b31b05 100644 --- a/src/App.vue +++ b/src/App.vue @@ -6,8 +6,11 @@ import { getPlan, savePlan, getDefaultRecordValue, - saveDefaultRecordValue, getStats, saveStats + saveDefaultRecordValue, getStats, saveStats, getThemeColor, saveThemeColor } from "@/utils/profile"; +import { useAppStore } from "@/store/app"; + +const appStore = useAppStore(); onLaunch(() => { if (!getDefaultRecordValue()) { @@ -30,6 +33,10 @@ onLaunch(() => { if (getStats().length === 0) { saveStats(['weight', 'sleep', 'sport', 'bloodPressure', 'bloodSugar', 'temperature']) } + if (!getThemeColor()) { + saveThemeColor('purple') + } + appStore.themeColor = getThemeColor(); console.log("App Launch"); }); onShow(() => { @@ -40,11 +47,3 @@ onHide(() => { }); - diff --git a/src/components/Profile/OverviewPopup.vue b/src/components/Profile/OverviewPopup.vue index d662391..1e92aaa 100644 --- a/src/components/Profile/OverviewPopup.vue +++ b/src/components/Profile/OverviewPopup.vue @@ -31,8 +31,7 @@ diff --git a/src/pages/index/index.vue b/src/pages/index/index.vue index 3d75d92..864db6c 100644 --- a/src/pages/index/index.vue +++ b/src/pages/index/index.vue @@ -1,111 +1,114 @@