mirror of
https://github.com/jakejarvis/sofa.git
synced 2026-08-29 01:35:39 -04:00
UX overhaul: motion animations, command palette, warm cinema theme
Add premium "Late Night Screening Room" experience with warm indigo/amber palette, framer-motion spring animations, Cmd+K command palette with TMDB search, keyboard shortcuts (G H, G S, ?, W, M, 1-5), sonner toasts with optimistic updates, skeleton loading states, stats dashboard, search autocomplete with filter tabs, cinematic backdrop with film grain, season progress bars, and staggered card reveal animations throughout. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -25,6 +25,8 @@ export interface ContinueWatchingItem {
|
||||
name: string | null;
|
||||
} | null;
|
||||
lastWatchedAt: Date | null;
|
||||
totalEpisodes: number;
|
||||
watchedEpisodes: number;
|
||||
}
|
||||
|
||||
export function getContinueWatchingFeed(
|
||||
@@ -67,6 +69,8 @@ export function getContinueWatchingFeed(
|
||||
// Find first unwatched episode
|
||||
let nextEpisode: ContinueWatchingItem["nextEpisode"] = null;
|
||||
let lastWatchedAt: Date | null = null;
|
||||
let totalEpisodes = 0;
|
||||
let watchedEpisodes = 0;
|
||||
|
||||
// Get most recent watch for this show
|
||||
for (const s of titleSeasons) {
|
||||
@@ -77,6 +81,8 @@ export function getContinueWatchingFeed(
|
||||
.orderBy(episodes.episodeNumber)
|
||||
.all();
|
||||
|
||||
totalEpisodes += eps.length;
|
||||
|
||||
for (const ep of eps) {
|
||||
const watch = db
|
||||
.select()
|
||||
@@ -90,6 +96,7 @@ export function getContinueWatchingFeed(
|
||||
.get();
|
||||
|
||||
if (watch) {
|
||||
watchedEpisodes++;
|
||||
if (!lastWatchedAt || watch.watchedAt > lastWatchedAt) {
|
||||
lastWatchedAt = watch.watchedAt;
|
||||
}
|
||||
@@ -116,6 +123,8 @@ export function getContinueWatchingFeed(
|
||||
},
|
||||
nextEpisode,
|
||||
lastWatchedAt,
|
||||
totalEpisodes,
|
||||
watchedEpisodes,
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user