Commit Graph
1238 Commits
Author SHA1 Message Date
vicrodh 916b4c145a debug: add aggressive logging to home loading flow (#43)
Log every decision point in loadHome():
- totalVisibleSections count
- mlPromise invoke/resolve/reject with seed counts
- fetchDiscoverData invoke/result with container keys
- checkAllSectionsReady transition with hasContent/error state
- catch block entry (which blocks all content rendering)

Backend: reco_get_home_ml logs call, success with counts, and
explicit error when RecoState.db is None.
2026-02-06 08:25:21 -06:00
vicrodh 2bff1290a3 fix: add catch handlers to all home section promise chains (#43)
Missing .catch() on 9 .then() chains in HomeView meant any rejected
promise (e.g. 404 from a deleted track) would prevent markSectionFinished()
from being called, leaving the loading overlay permanently visible.

Each catch now logs the error, clears the loading flag, and calls
markSectionFinished() so the overlay always dismisses.
2026-02-06 08:17:38 -06:00
vicrodh 1fce799674 fix: use gold hi-res badge with drop-shadow for legibility
Switch from hi-res-gray.svg back to the gold hi-res.svg. Add a
sub-pixel drop-shadow filter to reinforce thin text strokes against
the gold gradient, fixing chromatic anti-aliasing blur at 24px.
2026-02-06 06:26:01 -06:00
vicrodh 25dda16191 add defensive empty tracks check in AlbumDetailView
Show a user-friendly i18n message with back button when an album loads
without tracks, instead of displaying a blank track list. Uses
album.loadError key in both en.json and es.json.
2026-02-06 03:18:37 -06:00
vicrodh 1dc61b50c5 add DEBUG-43 diagnostic logging to frontend views
Add console.warn logging with [DEBUG-43] prefix to:
- handleAlbumClick: album ID, API response, converted data, tracks count
- AlbumDetailView onMount: album state and track availability
- HomeView fetchFeaturedAlbumsSingle: genre ID and result count

Uses console.warn for better WebKitGTK log visibility.
2026-02-06 03:17:13 -06:00
vicrodh 71bbc42bcf fix: validate genre filter to prevent empty home sections
Add validateAndCleanStoredGenreIds() to detect and remove stale genre IDs
from localStorage that do not exist in the loaded genre list. This prevents
the Qobuz API from returning empty results when localStorage contains
outdated genre IDs from previous sessions.

The validation runs after loading genres from both cache and API paths.
2026-02-06 03:14:05 -06:00
vicrodh b38bac7833 fix PostCSS crash: rename t variable inside $derived()
PlaylistDetailView used t as a callback variable inside $derived(),
which shadows the i18n t store and breaks Svelte CSS extraction
globally. Renamed to track.
2026-02-06 00:44:41 -06:00
vicrodh b6d2e10471 persist last user_id for session restore across app restarts
Saves the active user_id to a flat-path file on activate_user_session
and clears it on deactivate_user_session (explicit logout). On startup,
if saved credentials and a last_user_id both exist, the per-user session
is restored before loading ToS acceptance or attempting auto-login.

This fixes the chicken-and-egg problem where ToS acceptance lived in the
per-user DB but was needed before login to allow auto-login.
2026-02-06 00:37:52 -06:00
vicrodh 88fe564802 move Fetch Artist Images into Offline Playback section
The "Library" section had a single lonely setting. Moved it into the
Offline Playback section and removed the now-empty Library section
along with its nav entry.
2026-02-06 00:28:43 -06:00
vicrodh 435e7760ad restore show-in-library toggle, rename section to Offline Playback
The toggle for showing offline cached tracks in the Local Library view
was removed from the UI but the backend logic remained. Re-added it to
the Offline Playback settings section. Also renamed the section from
"Offline Library" to "Offline Playback" in both EN and ES locales.
2026-02-06 00:27:43 -06:00
vicrodh 9503ad9d49 defer per-user store init to post-login, reduce pre-login console noise
Moved initOfflineCacheStates, initPlaybackPreferences, initBlacklistStore
from onMount (before login) to handleLoginSuccess (after session active).
Downgraded pre-login "No active session" errors to debug level for
qobuzLegalStore, TitleBar tray settings, and offlineStore.
2026-02-05 23:53:28 -06:00
vicrodh c237ccee50 replace localStorage with per-user scoped storage in stores and views
Swap localStorage.getItem/setItem/removeItem for getUserItem/setUserItem/
removeUserItem from userStorage.ts across all stores, services, and view
components that use qbz- prefixed keys.

Global keys (theme, zoom-level, locale) remain as direct localStorage
since they're read before login during bootstrap.
2026-02-05 23:30:45 -06:00
vicrodh 8b3047b8fc add frontend per-user session lifecycle
- userStorage.ts: per-user localStorage scoping utility with migration
- authStore: add userId to UserInfo interface
- LoginView: extract user_id from login/auto_login responses
- +page.svelte: call activate_user_session after login,
  deactivate_user_session before logout, set up per-user localStorage
2026-02-05 23:22:43 -06:00
vicrodh a8004f1a92 fix(immersive): increase menu opacity and auto-close on mouse leave
Bump window menu background from 0.7 to 0.8. Add 2-second auto-close
timer when mouse leaves the menu area; re-entering cancels the timer.
2026-02-05 17:40:07 -06:00
vicrodh fe10c0514b fix(immersive): adjust window menu opacity and alignment
Increase background opacity from 0.5 to 0.7 and open menu to the
right (left-aligned) instead of right-aligned.
2026-02-05 17:24:26 -06:00
vicrodh 95d5eba026 feat(immersive): add window controls dropdown to player bar
Replace the non-functional '...' button with a dropdown menu
containing Fullscreen, Maximize/Restore, Minimize, and Exit
Immersive options. Menu uses the same glassmorphism style as the
player bar for visual consistency.
2026-02-05 17:22:05 -06:00
vicrodh 1256a15a5a feat(i18n): add window control translation keys for immersive player
Add fullScreen, exitFullScreen, maximize, restore, minimize, and
exitImmersive keys to the player section in all 4 locale files.
2026-02-05 17:22:00 -06:00
vicrodh 59bcbe9dd7 feat(immersive): persist and restore view preference (#51)
On open, restore the preferred view from localStorage. When set to
'remember', save the current view on every view/tab switch via header
or keyboard. When set to a specific view, always open to that view.
2026-02-05 17:05:46 -06:00
vicrodh 27763582a0 feat(settings): add immersive default view dropdown (#51)
Add dropdown in Settings > Appearance to choose which view immersive
mode opens with. Options: Remember last used (default), 6 focus views,
and 4 split-mode combinations. Persisted via localStorage.
2026-02-05 17:05:42 -06:00
vicrodh 62c0810a67 feat(i18n): add immersive default view translation keys
Add immersiveDefaultView label and immersiveViews object with all 11
view options to en.json, es.json, fr.json, and de.json under
settings.appearance.
2026-02-05 17:05:37 -06:00
vicrodh cbfb91ad2f fix: show favorite state for popular tracks on artist page
Subscribe to favoritesStore in ArtistDetailView to display filled
heart icon when a track is already favorited. The button now toggles
(add/remove) instead of only adding, with proper loading state.
2026-02-05 11:25:12 -06:00
vicrodh a70a33577c fix(player): resume playback from queue after stop (#46)
When user presses STOP then PLAY, playback now resumes the current
queue track instead of doing nothing. Added onResumeFromStop callback
in playerStore that queries the backend queue state and re-plays the
current track. The audio cache ensures instant playback within the
same session.
2026-02-05 11:11:48 -06:00
vicrodh af0e235bb2 fix(immersive): close lyrics sidebar when entering immersive (#47)
Lyrics sidebar was staying open behind the immersive player, causing
duplicate CPU usage for synced lyrics rendering. Now hideLyricsSidebar
is called alongside closeAllMenus when opening fullscreen or focus mode.
2026-02-05 08:37:52 -06:00
vicrodh 2f5f5ff8a6 fix(volume): restore pre-mute volume on unmute (#48)
Mute now saves the current volume before setting to 0, and unmute
restores it. Pre-mute volume persists in localStorage across sessions.
Centralized toggleMute in playerStore so all UI components (NowPlayingBar,
immersive VolumeSlider) behave consistently. Also moved session volume
persistence into setVolume to avoid duplication.
2026-02-05 08:36:56 -06:00
vicrodh 348d57e84f fix(immersive): close popups and raise z-index on open (#47)
Dropdowns and popups with z-index 10000 were appearing over the
immersive player (z-index 100). Raise immersive to 10001 and call
closeAll() on the floating menu store when entering immersive mode.
2026-02-05 08:34:13 -06:00
vicrodh c87f8f982e fix(audio): disable limit-quality-to-device feature (#45)
The device capability detection was unreliable, causing incorrect
downgrades to 16b/44.1kHz on some PipeWire+DAC setups. Disconnect
the quality limiting logic in play_track and prefetch_track, hide
the toggle from settings UI, and default to off. Code preserved
for future fix.
2026-02-05 08:32:13 -06:00
vicrodh ed1bd31554 fix(suggestions): improve pool management and artist identity validation
- Increase pool sizes (INITIAL_POOL 18->30, EXPANDED_POOL 60->100, MAX_POOL 120->200)
- Add auto-refresh when available tracks fall below threshold (MIN_AVAILABLE_THRESHOLD=12)
- Add artist identity validation to filter incompatible genres (prevents merengue in metal playlists)
- Log when artists are skipped due to incompatible disambiguation
- Increase backend defaults (max_artists 20->30, tracks_per_artist 5->6, max_pool_size 100->150)
2026-02-04 19:34:52 -06:00
vicrodh 1bb9fc8382 fix(collage): add size constraints to prevent image overflow 2026-02-04 19:17:03 -06:00
vicrodh 31df685e08 fix: lower jump-nav z-index to prevent overlap with dropdown menus
Reduced z-index from 4 to 1 to ensure dropdown menus appear above
the sticky navigation bar.

cc
2026-02-04 17:25:16 -06:00
vicrodh 4dec2df315 chore: temporarily disable remote control setup guide button
Content not ready for release.

cc
2026-02-04 16:51:50 -06:00
vicrodh eaed5b3c9e refactor(artist): improve hide artist button
- Hide button only shows when content filtering is enabled
- Use custom blind-eye.svg icon
- Remove border for cleaner look
- Banner also conditional on filtering being enabled

cc
2026-02-04 14:58:06 -06:00
vicrodh 7e8e79c025 refactor(artist): replace blacklist button with hide dropdown
- Replaced prominent blacklist button with smaller tertiary button
- Button now opens dropdown with descriptive help text:
  "Hide this artist - Don't show in searches, playlists, discover, etc."
- Updated terminology from "blacklist" to "hide/show"
- Updated banner and toast messages for consistency
- Uses EyeOff icon instead of Ban for softer visual

cc
2026-02-04 14:35:21 -06:00
vicrodh 0877213625 feat: add warning toast type
The 'warning' type was being used but not defined in ToastType.

cc
2026-02-04 14:20:07 -06:00
vicrodh a044017c3b fix: more $t() and store access issues in $derived() blocks
- PlaylistModal: convert $derived with get(t) to regular function
- LocalLibraryTagEditorModal: rename 't' to 'track' in map to avoid
  shadowing the t store

cc
2026-02-04 14:18:36 -06:00
vicrodh 73e7d799df i18n: add download.* keys to French and German locales
cc
2026-02-04 14:05:45 -06:00
vicrodh c9b26eb4db fix: remove $t() calls from $derived() blocks to fix PostCSS errors
vite-plugin-svelte CSS extraction fails when $t() is used inside $derived().
This causes "[postcss] Unknown word <script" errors that appear to be cache
issues but are actually a known Svelte 5 / vite-plugin-svelte incompatibility.

Files fixed:
- DownloadButton.svelte: use titleKey pattern with function resolver
- DACSetupWizard.svelte: use labelKey pattern resolved in WizardStepper
- RemoteControlSetupGuide.svelte: use labelKey pattern
- WizardStepper.svelte: support optional labelKey with $t() in template

Also added download.* translation keys to en.json and es.json.

cc
2026-02-04 14:05:18 -06:00
vicrodh 4cfde680aa chore: remove debug logging from HomeView
cc
2026-02-04 08:14:45 -06:00
vicrodh deaffa183d feat(home): add Qobuz discover playlists section with tag filter
- Add backend endpoint for /discover/playlists API
- Add PlaylistTagFilter dropdown component for filtering by genre
- Add QobuzPlaylistCard with CSS blur background effect (color-thief style)
- Add HorizontalScrollRow header snippet for custom headers with scroll controls
- Add session cache store for caching API responses
- Add i18n keys for playlist filter and discover section

cc
2026-02-03 21:37:26 -06:00
vicrodh 001cadcbe7 refactor(settings): move Remote Control to end, make collapsible
- Move Remote Control section to end of Settings (after Updates)
- Make section collapsible, closed by default
- Keep Experimental badge visible when collapsed
- Update nav sidebar order to reflect new position
- Remove unused .section-title-row CSS selectors
2026-02-03 11:17:40 -06:00
vicrodh 477258d94a feat(remote): sync shuffle/repeat between desktop and PWA
- Add shuffle/repeat fields to PlaybackEvent struct
- Emit queue:state event when shuffle/repeat changes via API
- Add queue event listener in desktop frontend
- Include shuffle/repeat in WebSocket broadcasts
- PWA updates shuffle/repeat from WebSocket messages

This enables bidirectional sync: changes from PWA update desktop UI,
and changes from desktop update PWA via WebSocket.
2026-02-03 09:22:55 -06:00
vicrodh 6b85086b0a fix(player): sync volume from backend playback events
Update the local volume state when receiving playback events from the
backend. This ensures the volume slider reflects changes made via
remote control or other external sources.
2026-02-03 09:14:52 -06:00
vicrodh 21054b9f22 fix(player): update player state immediately on external track change
Call notifyListeners() right after setting currentTrack when track
changes from remote control. Also update isPlaying and currentTime
from the event to ensure player UI reflects correct state.

Added debug logging for queue track mismatches.
2026-02-03 08:39:09 -06:00
vicrodh d1347bc425 fix(player): sync queue when track changes from remote control
When a track change is detected from an external source (e.g., PWA
remote control), also sync the full queue state. This fixes the issue
where desktop UI showed empty queue after PWA started playback.
2026-02-03 08:28:39 -06:00
vicrodh da93c746cf feat(remote-control): add setup guide wizard and experimental badge
- Add RemoteControlSetupGuide component with step-by-step instructions
- Include certificate installation guides for iOS, macOS, Windows, Android
- Mark remote control section as "Experimental" with red badge
- Add Setup Guide button to open the wizard
- Add translations for wizard (en/es)
2026-02-03 05:38:20 -06:00
vicrodh 53b9031c36 fix(player): sync track changes from remote control
When tracks are changed externally (via PWA remote control), the desktop
player now detects the track_id mismatch and fetches the new track info
from the backend queue. This fixes bidirectional sync where skipping
tracks on the PWA wasn't reflected in the QBZ desktop UI.
2026-02-03 05:16:17 -06:00
vicrodh 229d24f891 feat(remote-control): add HTTPS mode and cert flow
cx
2026-02-03 04:48:23 -06:00
vicrodh b906f747fa Merge feature/internal/qbz-control: Remote Control API
Features:
- Axum REST API server for remote control
- WebSocket real-time playback updates
- Token-based authentication with QR pairing
- LAN-only security middleware
- Settings UI for enabling/configuring remote control
2026-02-03 03:52:06 -06:00
vicrodh 363ca4c264 feat(remote-control): add LAN API server, settings UI, and QR pairing\n\n- add axum API server with LAN-only + token auth + CORS allowlist\n- expose playback and search endpoints plus WS updates\n- persist remote control settings (enabled/port/token)\n- add settings UI with QR/token controls and i18n\n\ncx 2026-02-03 03:47:48 -06:00
vicrodh 2f85129547 feat(dac-wizard): apply ChatGPT micro-adjustments
Step 1 (Precheck):
- Add inactive warning: "If any service is inactive, stop here..."

Step 2 (Other distro):
- Change to "Ensure these packages (or equivalents) are installed"

Step 3 (Detect DAC):
- Add input warning: "This must match exactly..."

Step 4 (Backup):
- Update hint about user responsibility for keeping backup

Step 6 (Pulse):
- Change "browsers" to "browsers and apps"

Step 7 (WirePlumber):
- Add rules note: "These rules apply only to the detected DAC"

All translations updated for EN/ES/FR/DE
2026-02-03 03:15:59 -06:00
vicrodh dbe70e774c style(dac-wizard): make tooltip text friendlier and nerdier
- Reference "The Hi-Fi Wizard/Mage" for the gandalf icon
- Add "if you haven't already" to acknowledge power users
- Keep it playful without being patronizing
2026-02-03 03:07:15 -06:00