Chore: Fix Zoom & Attempt Theming

This commit is contained in:
Youwes09
2026-05-25 12:31:23 -05:00
parent cbdf9e8be1
commit e9929747d2
6 changed files with 229 additions and 203 deletions
+10
View File
@@ -17,9 +17,19 @@ function save(s: Settings) {
export const settingsState = $state({ settings: load() })
if (typeof document !== 'undefined') {
document.documentElement.style.zoom = String(settingsState.settings.uiZoom ?? 1.0)
}
export function updateSettings(patch: Partial<Settings>) {
Object.assign(settingsState.settings, patch)
save(settingsState.settings)
if (typeof document !== 'undefined') {
if (patch.uiZoom !== undefined) {
document.documentElement.style.zoom = String(patch.uiZoom)
}
}
}
export function resetSettings() {