fix banner and chart color

This commit is contained in:
2026-06-24 11:52:09 +03:30
parent 6c89375370
commit d083469710
6 changed files with 31 additions and 15 deletions
@@ -1,5 +1,6 @@
import { ref } from 'vue'
import { getConstByKey } from '@/api/const'
import { useSettingsStore } from '@/store/settingsStore'
function parseJsonArray(raw: unknown): unknown[] {
if (raw == null || raw === '') {
@@ -30,6 +31,13 @@ let bannersPromise: Promise<void> | null = null
let bannersLoaded = false
async function fetchBanners(force = false) {
const settingsStore = useSettingsStore()
if (!settingsStore.isSettingTruthy('banner_enabled')) {
banners.value = []
bannersLoaded = true
return
}
if (!force && bannersLoaded) {
return
}