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
This commit is contained in:
4 files changed
+194
-43
No files matched your search
@@ -11,6 +11,7 @@
|
||||
"dev:ultra-restore": "bash ./scripts/dev-ultra-restore.sh",
|
||||
"dev:ultra-reset": "bash ./scripts/dev-ultra-restore.sh --no-start",
|
||||
"dev:ultra-full-reset": "bash ./scripts/dev-ultra-restore.sh --full --no-start",
|
||||
"dev:reset-last-view": "bash ./scripts/dev-reset-last-view.sh",
|
||||
"dev:tauri": "./scripts/dev-with-env.sh",
|
||||
"build": "vite build",
|
||||
"preview": "vite preview",
|
||||
|
||||
Reference in new issue
Block a user