Address the first beta's bugs and requested changes

Startup now uses the Android iris animation, and playback can continue
in a corner miniplayer while browsing (the video is drawn into a corner
rectangle beneath a matching hole in the page). The player keeps the
window controls, hides its chrome when the pointer leaves, and gains
audio/subtitle tracks, audio sync, source bitrate and playback details
in its options. Subtitles can be styled in Settings with a live preview.
Categories replace Collections, the A–Z rail magnifies, descriptions
expand in place, downloads can be removed in bulk, and search keeps its
results while typing.

Fixes scroll jank from per-card and scrolling backdrop blurs, the hidden
colour wash, the cubic volume curve, loud theme music, the search focus
ring, a stray nav indicator, Continue Watching previews and the TV Shows
header overlap. Removes the star rating, the duplicate Settings menu
entry and the server settings' Show advanced switch.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Elijah 2026-10-30 18:06:54 -07:00
parent be865fa992
commit 43c168da95
35 changed files with 1771 additions and 327 deletions

View file

@ -14,8 +14,8 @@ interface Layer {
/**
* Artwork-led page background. The image sits top-right and fades into the
* page toward its left and bottom edges; the UltraBlur colour wash tints the
* page beneath. Changes crossfade; the outgoing layer stays until the new
* image has decoded.
* page beneath it and carries on down behind the rows. Changes crossfade; the
* outgoing layer stays until the new image has decoded.
*/
export function Backdrop({ item, className = '', width = 1600, height = 900, wash: forceWash }: { item: Item | null | undefined; className?: string; width?: number; height?: number; wash?: Item['ultraBlur'] }) {
const server = useServer();
@ -44,19 +44,25 @@ export function Backdrop({ item, className = '', width = 1600, height = 900, was
if (idx < 0) return prev;
const next = prev.map((l) => (l.key === key ? { ...l, ready: true } : l));
// Drop older layers once the newest is visible (after its fade).
setTimeout(() => setLayers((p) => (p.length > 1 && p[p.length - 1].key === key ? p.slice(-1) : p)), 700);
setTimeout(() => setLayers((p) => (p.length > 1 && p[p.length - 1].key === key ? p.slice(-1) : p)), 500);
return next;
});
return (
<div className={`backdrop ${className}`} aria-hidden="true">
{layers.map((l) => (
<div key={l.key} className={`backdrop-layer${l.ready ? ' ready' : ''}`}>
{l.wash && <div className="backdrop-wash" style={{ background: l.wash }} />}
{l.src && <img className="backdrop-art" src={l.src} alt="" draggable={false} decoding="async" onLoad={() => onReady(l.key)} onError={() => onReady(l.key)} />}
<>
{colorWash && (
<div className={`backdrop-tint ${className}`} aria-hidden="true">
{layers.map((l) => l.wash && <div key={l.key} className={`backdrop-wash${l.ready ? ' ready' : ''}`} style={{ background: l.wash }} />)}
</div>
))}
<div className="backdrop-scrim" />
</div>
)}
<div className={`backdrop ${className}${colorWash ? ' washed' : ''}`} aria-hidden="true">
{layers.map((l) => (
<div key={l.key} className={`backdrop-layer${l.ready ? ' ready' : ''}`}>
{l.src && <img className="backdrop-art" src={l.src} alt="" draggable={false} decoding="async" onLoad={() => onReady(l.key)} onError={() => onReady(l.key)} />}
</div>
))}
<div className="backdrop-scrim" />
</div>
</>
);
}

View file

@ -6,7 +6,11 @@ import { Backdrop } from './Backdrop';
import { Facts, TitleArt } from './media';
import { Button, IconButton } from './primitives';
import { openMenu } from './overlays';
import { episodeLabel } from '../app/format';
import { art, episodeLabel } from '../app/format';
import { useServer } from '../app/session';
/** How long each feature shows; the dot progress animation matches it. */
const ROTATE_MS = 8000;
export interface Feature {
item: Item;
@ -15,7 +19,7 @@ export interface Feature {
/**
* The cinematic feature at the top of Home and the Discover pages. Features
* rotate every 12 seconds while the pointer is away, crossfading artwork
* rotate every 8 seconds while the pointer is away, crossfading artwork
* while the copy lifts out and rises into place.
*/
export function Hero({ features, variant = 'home' }: { features: Feature[]; variant?: 'home' | 'section' }) {
@ -27,10 +31,22 @@ export function Hero({ features, variant = 'home' }: { features: Feature[]; vari
const root = useRef<HTMLElement>(null);
const count = features.length;
const feature = features[Math.min(index, count - 1)];
const server = useServer();
// Decode the next feature's artwork ahead of time so the swap is immediate.
const upcoming = count > 1 ? features[(index + 1) % count]?.item : undefined;
useEffect(() => {
const path = upcoming ? art.backdrop(upcoming) : '';
if (!path) return;
const img = new Image();
img.decoding = 'async';
img.src = server.image(path, 1600, 900);
img.decode?.().catch(() => {});
}, [upcoming?.id]);
useEffect(() => {
if (!rotate || reduced || count < 2 || hover) return;
const t = setTimeout(() => go(index + 1), 12000);
const t = setTimeout(() => go(index + 1), ROTATE_MS);
return () => clearTimeout(t);
}, [index, rotate, reduced, count, hover]);

View file

@ -11,12 +11,13 @@ import { Ratings } from './media';
* A quiet preview shown after the pointer rests on a poster: artwork, facts
* and synopsis, without opening the title. It never captures the pointer.
*/
const usePreview = create<{ item: Item | null; rect: DOMRect | null; anchor: HTMLElement | null; show(item: Item, anchor: HTMLElement): void; hide(): void }>((set) => ({
const usePreview = create<{ item: Item | null; rect: DOMRect | null; anchor: HTMLElement | null; show(item: Item, anchor: HTMLElement): void; hide(): void }>((set, get) => ({
item: null,
rect: null,
anchor: null,
show: (item, anchor) => set({ item, anchor, rect: anchor.getBoundingClientRect() }),
hide: () => set({ item: null, rect: null, anchor: null }),
// Called on every wheel event; only notify when something was showing.
hide: () => get().item && set({ item: null, rect: null, anchor: null }),
}));
let timer: ReturnType<typeof setTimeout> | null = null;

View file

@ -242,7 +242,7 @@ export const LandscapeCard = memo(function LandscapeCard({ item, continueWatchin
? remaining(item)
: [item.year, duration(item.duration)].filter(Boolean).join(' · ');
return (
<article className="card landscape" role="button" tabIndex={0} aria-label={title} {...handlers}>
<article className="card landscape" role="button" tabIndex={0} aria-label={title} {...handlers} {...previewHandlers(item)}>
<div className="card-cover">
<Artwork src={server.image(path, 400, 225)} alt="" fallback={<span className="cover-fallback">{title}</span>} />
{!isEp && item.logo && continueWatching && (
@ -293,7 +293,10 @@ export function Shelf({ title, subtitle, onViewAll, children, className = '', ki
const update = () => {
const el = row.current;
if (!el) return;
setEdges({ start: el.scrollLeft < 8, end: el.scrollLeft + el.clientWidth >= el.scrollWidth - 8 });
const start = el.scrollLeft < 8;
const end = el.scrollLeft + el.clientWidth >= el.scrollWidth - 8;
// Runs on every scroll event; re-render only when an edge changes.
setEdges((prev) => (prev.start === start && prev.end === end ? prev : { start, end }));
};
useEffect(() => {
update();