Add Svelte web client and service worker
Mobile-first PWA: groups via key-in-fragment links, encrypted outbox and sync over SSE, all split modes, currencies with ECB rate prefill, photos, comments, history and rewind, stats, recurring expenses, CSV and backup, EN/CS, dark/light theme, Web Push decrypted in the service worker. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013FYo6JSV1fDU1fm3LU77iF
This commit is contained in:
parent
f67add3660
commit
8fbbb4933e
53 changed files with 4558 additions and 37 deletions
32
apps/web/src/components/AppSettings.svelte
Normal file
32
apps/web/src/components/AppSettings.svelte
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
<script lang="ts">
|
||||
import { router } from '../lib/router.svelte.ts';
|
||||
import { settings, t } from '../lib/settings.svelte.ts';
|
||||
import Icon from './Icon.svelte';
|
||||
</script>
|
||||
|
||||
<header class="topbar">
|
||||
<button class="icon-btn" onclick={() => router.back('/')} aria-label={t('back')}><Icon name="back" /></button>
|
||||
<h1>{t('app_settings')}</h1>
|
||||
</header>
|
||||
|
||||
<main class="page stack">
|
||||
<div class="section">
|
||||
<h3>{t('language')}</h3>
|
||||
<div class="seg" role="group" aria-label={t('language')}>
|
||||
<button aria-pressed={settings.langPref === 'auto'} onclick={() => settings.setLang('auto')}>{t('lang_auto')}</button>
|
||||
<button aria-pressed={settings.langPref === 'en'} onclick={() => settings.setLang('en')}>English</button>
|
||||
<button aria-pressed={settings.langPref === 'cs'} onclick={() => settings.setLang('cs')}>Čeština</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="section">
|
||||
<h3>{t('theme')}</h3>
|
||||
<div class="seg" role="group" aria-label={t('theme')}>
|
||||
<button aria-pressed={settings.themePref === 'system'} onclick={() => settings.setTheme('system')}>{t('theme_system')}</button>
|
||||
<button aria-pressed={settings.themePref === 'dark'} onclick={() => settings.setTheme('dark')}>{t('theme_dark')}</button>
|
||||
<button aria-pressed={settings.themePref === 'light'} onclick={() => settings.setTheme('light')}>{t('theme_light')}</button>
|
||||
</div>
|
||||
</div>
|
||||
<p class="muted small row" style:align-items="flex-start" style:margin-top="24px">
|
||||
<Icon name="lock" size={16} /> <span>{t('e2e_note')}</span>
|
||||
</p>
|
||||
</main>
|
||||
Loading…
Add table
Add a link
Reference in a new issue