feat(notify-bridge): phase 7 - frontend restructuring

Notify Bridge frontend with SvelteKit 2 + Svelte 5 + Tailwind CSS v4:
- Auth: login page, setup page, auth state management with $state runes
- Theme: dark/light toggle with localStorage persistence
- i18n: EN/RU translations with reactive $state-based t() function
- Routes: dashboard, providers, trackers, targets, tracking-configs,
  template-configs, telegram-bots, users (stubs for configs pages)
- Providers page: list with card grid, "Add Provider" button
- API client: JWT auth, auto-redirect on 401, typed request helpers
- Branding: "Notify Bridge" throughout, Observatory theme colors

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-03-19 23:53:37 +03:00
parent 7f99c895a4
commit 9dfd1b79cd
12 changed files with 274 additions and 3 deletions
+15
View File
@@ -37,3 +37,18 @@ PID=$(netstat -ano 2>/dev/null | grep ':5173.*LISTENING' | awk '{print $5}' | he
- **frontend**: SvelteKit 2 + Svelte 5 + Tailwind CSS v4. Static adapter with SPA fallback. Dev proxy to :8420.
- **Environment vars**: `NOTIFY_BRIDGE_DATA_DIR`, `NOTIFY_BRIDGE_SECRET_KEY`, `NOTIFY_BRIDGE_DATABASE_URL`
- Core package includes `jinja2` dependency (template rendering lives in core, not server).
## Entity Relationships (Phase 6)
```
ServiceProvider → type: "immich", config: JSON (url, api_key, external_domain)
Tracker → provider_id, tracking_config_id, target_ids: JSON list, collection_ids: JSON list
TrackingConfig → provider_type (must match provider), event flags, scheduling
TemplateConfig → provider_type (must match provider), Jinja2 slots per event type
NotificationTarget → template_config_id, type: "telegram"/"webhook", config: JSON
```
- TrackingConfig owned by Tracker (what to watch), TemplateConfig owned by Target (how to format)
- `user_id=0` on TemplateConfig = system default (EN/RU seeded on first startup)
- DB: SQLite + async SQLAlchemy via sqlmodel, auto-created on startup
- API: All CRUD routes under `/api/`, auth via JWT Bearer, `NOTIFY_BRIDGE_` env prefix