mirror of
https://github.com/kilyabin/psysonic.git
synced 2026-07-22 06:25:41 +00:00
feat(changelog): replace auto-modal with sidebar banner + /whats-new page
Removes the giant startup changelog modal. After an update, a compact neutral-palette pill now sits above Now Playing in the sidebar saying "Changelog — vX.Y.Z". Clicking opens a proper /whats-new page in the main content area; X dismisses. Page renders the current version's CHANGELOG entry with inline Markdown (headings, lists, blockquotes, hr, bold/italic/code, and real [label](url) links that open via the Tauri shell plugin). Visual tokens are hardcoded slate/gray/blue so the banner and page look identical across every theme (dark, light, skeuomorphic, whatever) — requested for consistent contrast. Auto-mark-as-seen removed from the page; the banner only goes away on explicit dismiss, so users can re-read as often as they want. Settings → About gains a "Release notes" row with a link that resets the seen-version and opens the page, so the banner can be retriggered manually (also helpful for dev builds ahead of the current tag). The existing "Show changelog on update" toggle now gates the banner instead of the modal; description strings updated in all 8 locales. fix(themes): WCAG contrast audit — mocha + winmedplayer + wista Mocha (Catppuccin dark) .track-size used --ctp-overlay0 directly (3.36:1 on bg-app, 2.57 on bg-card). Swapped to --text-muted → 7.37 / 5.65. Fix also lifts macchiato/frappe/latte which shared the failure. WinMedPlayer (Luna) --text-muted #b8d0f8 (3.87:1 on bg-app) → #e8f0ff (5.28) --border #2a5090 (1.31 on bg-app) → #071027 (3.12, meets 3:1 UI) Wista (Vista Aero) Lyrics pane sits on bg-sidebar #0e1e3e but used --text-primary (#0d1d3c) for active lines — 1.01:1, literally invisible. Added component overrides: .lyrics-line / .lyrics-status / word-synced variants → #aac8f0 (9.60), .lyrics-line.active → #ffffff (16.48). Palette: --warning #c8980c → #735a00 (2.37 → 5.91 on bg-app), --text-muted #4870a8 → #3f6aa0 (4.23 → 4.65 on bg-card). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
+5
-10
@@ -38,6 +38,7 @@ import InternetRadio from './pages/InternetRadio';
|
||||
import FolderBrowser from './pages/FolderBrowser';
|
||||
import DeviceSync from './pages/DeviceSync';
|
||||
import NowPlayingPage from './pages/NowPlaying';
|
||||
import WhatsNew from './pages/WhatsNew';
|
||||
import MiniPlayer from './components/MiniPlayer';
|
||||
import { initMiniPlayerBridgeOnMain } from './utils/miniPlayerBridge';
|
||||
import FullscreenPlayer from './components/FullscreenPlayer';
|
||||
@@ -53,7 +54,6 @@ import OfflineLibrary from './pages/OfflineLibrary';
|
||||
import Genres from './pages/Genres';
|
||||
import GenreDetail from './pages/GenreDetail';
|
||||
import ExportPickerModal from './components/ExportPickerModal';
|
||||
import ChangelogModal from './components/ChangelogModal';
|
||||
import AppUpdater from './components/AppUpdater';
|
||||
import TitleBar from './components/TitleBar';
|
||||
import { IS_LINUX } from './utils/platform';
|
||||
@@ -229,14 +229,9 @@ function AppShell() {
|
||||
fn();
|
||||
}, [currentTrack, isPlaying]);
|
||||
|
||||
const [changelogModalOpen, setChangelogModalOpen] = useState(false);
|
||||
|
||||
useEffect(() => {
|
||||
const { showChangelogOnUpdate, lastSeenChangelogVersion } = useAuthStore.getState();
|
||||
if (showChangelogOnUpdate && lastSeenChangelogVersion !== version) {
|
||||
setChangelogModalOpen(true);
|
||||
}
|
||||
}, []);
|
||||
// Post-update changelog is now surfaced via a dismissible banner in the
|
||||
// sidebar (WhatsNewBanner) that links to the /whats-new page — no auto
|
||||
// modal takeover on startup.
|
||||
|
||||
const [isSidebarCollapsed, setIsSidebarCollapsed] = useState(() => {
|
||||
return localStorage.getItem('psysonic_sidebar_collapsed') === 'true';
|
||||
@@ -402,6 +397,7 @@ function AppShell() {
|
||||
<Route path="/most-played" element={<MostPlayed />} />
|
||||
<Route path="/now-playing" element={isMobile ? <MobilePlayerView /> : <NowPlayingPage />} />
|
||||
<Route path="/settings" element={<Settings />} />
|
||||
<Route path="/whats-new" element={<WhatsNew />} />
|
||||
<Route path="/help" element={<Help />} />
|
||||
<Route path="/offline" element={<OfflineLibrary />} />
|
||||
<Route path="/genres" element={<Genres />} />
|
||||
@@ -436,7 +432,6 @@ function AppShell() {
|
||||
<DownloadFolderModal />
|
||||
<TooltipPortal />
|
||||
<AppUpdater />
|
||||
{changelogModalOpen && <ChangelogModal onClose={() => setChangelogModalOpen(false)} />}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user