From e8870a11dafd5482f276483f6042eda5f9a7e6f3 Mon Sep 17 00:00:00 2001 From: root Date: Mon, 6 Apr 2026 15:51:06 +0500 Subject: [PATCH] feat(player): redesign ListeningMode UI MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Full-bleed cover fills top ~52% of screen with top+bottom gradient overlays for header and track info legibility; eliminates the large dead space between cover and seek bar - Chapter number shown as brand-coloured label above the chapter title - Remaining time (−m:ss) displayed in the centre of the seek bar row - Transport row uses justify-between; chapter-skip buttons are smaller (w-5, muted/60 opacity) vs time-skip (w-7, full muted) to clearly distinguish secondary from primary seek controls - Speed / Auto-next / Sleep now sit on a single tidy row — no more wrapping or mixed visual styles between the segmented speed control and the two pill buttons - Header buttons use frosted-glass style (bg-black/25 backdrop-blur) so they remain legible over the cover image --- ui/src/lib/components/ListeningMode.svelte | 530 ++++++++++----------- 1 file changed, 251 insertions(+), 279 deletions(-) diff --git a/ui/src/lib/components/ListeningMode.svelte b/ui/src/lib/components/ListeningMode.svelte index eb016ea..8863cff 100644 --- a/ui/src/lib/components/ListeningMode.svelte +++ b/ui/src/lib/components/ListeningMode.svelte @@ -187,68 +187,101 @@ -
- - {#if audioStore.cover} +
+ + +
+ {#if audioStore.cover} + + + {:else} + +
+ + + +
+ {/if} + + + - {/if} - -
- - Now Playing -
- - {#if audioStore.chapters.length > 0} - - {/if} - + +
+ Now Playing +
+ + {#if audioStore.chapters.length > 0} + + {/if} + + +
+
+ + +
+ {#if audioStore.chapter > 0} +

+ Chapter {audioStore.chapter} +

+ {/if} +

+ {audioStore.chapterTitle || (audioStore.chapter > 0 ? `Chapter ${audioStore.chapter}` : '')} +

+

{audioStore.bookTitle}

@@ -273,7 +306,6 @@ Select Voice
-
@@ -288,7 +320,6 @@ />
-
{#each ([['Kokoro', filteredKokoro], ['Pocket TTS', filteredPocket], ['CF AI', filteredCfai]] as [string, Voice[]][]) as [label, group]} @@ -298,45 +329,24 @@
- - -
-
@@ -392,35 +397,24 @@ />
-
- {#each filteredChapters as ch (ch.number)} - {/each} @@ -431,195 +425,173 @@
{/if} - -
+ +
- -
- {#if audioStore.cover} - - {:else} -
- - - -
- {/if} - -

- {audioStore.chapterTitle || (audioStore.chapter > 0 ? `Chapter ${audioStore.chapter}` : '')} -

-

{audioStore.bookTitle}

+ +
+ +
+ {formatTime(audioStore.currentTime)} + + {#if audioStore.duration > 0} + −{formatTime(Math.max(0, audioStore.duration - audioStore.currentTime))} + {/if} + {formatTime(audioStore.duration)} +
- -
- - -
- -
- {formatTime(audioStore.currentTime)} - {formatTime(audioStore.duration)} -
-
- - -
- - {#if audioStore.chapter > 1 && audioStore.slug} - - - - - - {:else} -
- {/if} - - - + + {:else} +
+ {/if} - - + + - -
+ - -
- -
- {#each SPEED_OPTIONS as s} - - {/each} -
+ + - - + + {:else} +
+ {/if} +
- - + +
+ +
+ {#each SPEED_OPTIONS as s} + + {/each}
+ + + + +