Add watch status indicators to title cards on Explore page

Title cards now show the user's existing watch status (watchlist,
watching, completed) with a color-coded badge on the poster and a
status-aware quick-add button that prevents re-adding tracked titles.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-05 10:17:29 -05:00
co-authored by Claude Opus 4.6
parent fa01a0d4a0
commit 843bf35513
7 changed files with 184 additions and 5 deletions
+8 -1
View File
@@ -22,6 +22,7 @@ interface TitleRowProps {
heading: string;
icon: React.ReactNode;
items: TitleRowItem[];
userStatuses?: Record<string, "watchlist" | "in_progress" | "completed">;
}
const staggerContainer = {
@@ -39,7 +40,12 @@ const staggerItem = {
},
};
export function TitleRow({ heading, icon, items }: TitleRowProps) {
export function TitleRow({
heading,
icon,
items,
userStatuses,
}: TitleRowProps) {
if (items.length === 0) return null;
return (
@@ -74,6 +80,7 @@ export function TitleRow({ heading, icon, items }: TitleRowProps) {
voteAverage={item.voteAverage}
href={`/titles/tmdb-${item.tmdbId}-${item.type}`}
showQuickAdd
userStatus={userStatuses?.[`${item.tmdbId}-${item.type}`]}
/>
</motion.div>
</CarouselItem>