Commit Graph
11 Commits
Author SHA1 Message Date
vicrodh 9d6c2f7eba fix: harden session restore/persist to prevent ghost CSS errors
When last_view pointed to a view with incomplete context (e.g.
album without selectedAlbum data), the Svelte CSS extraction
pipeline would corrupt and produce PostCSS "Unknown word" errors
that survived cache cleans and npm ci.

- Add isSessionRestoreSafeView() whitelist for context-free views
- Add getSessionFallbackView() for graceful degradation
- Centralize persist logic in getPersistedSessionViewState()
- Only persist views that have valid context data
- Add purchase-album to restore path
- Add dev:reset-last-view script to reset session.db
- Fix AlbumCreditsModal.svelte event handler typing
2026-03-11 17:02:29 -06:00
vicrodh 067264e7ec chore(scripts): add ghost-doctor and ultra-restore dev tooling
Add dev-ghost-doctor.sh (t-shadow check + runtime clean + restart) and
dev-ultra-restore.sh (deep clean with --full/--no-start/--check flags).
Improve check-no-t-shadow.sh patterns for broader t-variable detection.
Clean-dev-runtime now runs guardrail check automatically. Remove --force
from vite dev. Add npm script shortcuts for all new tools.
2026-02-26 02:44:06 -06:00
vicrodh 835fd19934 feat(oauth): persist session token for automatic re-auth on restart
- Save user_auth_token after successful OAuth login
- On bootstrap, restore session via saved token if no email/password creds
- If token is expired, clear it so user sees login screen normally
- Clear OAuth token on v2_clear_saved_credentials (logout)
- Add login_with_token() to api client (reuses OAuth /user/login step)

Also rename t->translateStore in NowPlayingBar.svelte (ADR-001 fix from Codex)
and improve clean-dev-runtime.sh to kill all stale processes and ports
2026-02-23 15:30:43 -06:00
vicrodh e843cb736f fix(svelte): remove hidden t shadow and harden checker
cx
2026-02-23 10:09:41 -06:00
vicrodh 2508ea9e55 chore(dev): improve dev scripts and runtime cleanup
Add svelte-kit sync + --force to dev script, add clean-runtime script,
bind vite to 127.0.0.1 explicitly.

cc
2026-02-19 16:18:53 -06:00
vicrodh 11b3486c63 fix(v2): close frontend/backend command audit gaps
- add/register missing v2 commands surfaced by audit
- migrate frontend invokes to v2 equivalents
- eliminate legacy invoke callsites in audit report
- harden invoke audit parser for generic/multiline invoke usage

cx
2026-02-18 12:59:28 -06:00
vicrodh d4b5dedc90 chore(v2): add migration guardrails for backend purity and invoke audit
cx
2026-02-16 03:29:02 -06:00
vicrodh 8b7a2dd6e6 fix(i18n): catch and remove remaining t-shadow reduce callback
cx
2026-02-09 02:34:40 -06:00
vicrodh ff15efde39 chore(i18n): add checker for t shadowing in svelte files
cx
2026-02-09 02:15:24 -06:00
vicrodh 6e21b3ed1f docs(dev): add script and docs for local API key loading
- Create dev-with-env.sh script to load .env before build
- Add npm run dev:tauri command that uses the script
- Document why .env must be loaded before compilation
- Explain compile-time vs runtime environment variables

The issue: option_env!() reads vars at compile time, but .env
loads at runtime. Solution: source .env before cargo build.

cp
2026-01-14 19:43:18 -06:00
vicrodh 3e8fe0771a perf: add adaptive polling and fix lyrics interval leak
- Playback state polling: 1000ms when paused, 250ms when playing
- Audio thread timeout: 500ms when idle, 100ms when playing
- Lyrics interval: self-check to auto-stop when conditions not met
- Add cleanup return to lyrics  in +page.svelte
- Add build-and-run.sh and monitor-resources.sh scripts
- Add OPTIMIZATION_PLAN.md documentation
2026-01-12 20:38:48 -06:00