Frontend: UI improvements, dashboard fixes, and settings cleanup
- EntrySeenDialog: native date input, merged date+accuracy row
- EpisodeSeenEditDialog: merged date+accuracy row
- LibraryGrowthChart: use createdAt only, include all entries
- SeasonPage/EpisodePage: max-w-4xl, improved breadcrumbs ("Title / Season x / Episode x"), fixed season number display
- SettingsPage: added Cleanup section for orphan files/media records
- Added maintenance API client
- Updated docs-vault and project documentation
This commit is contained in:
1 parent
cd695ef4cf
commit
3c4958df50
7 files changed
+245
-100
No files matched your search
@@ -2,13 +2,13 @@ import { useState } from 'react';
|
||||
import { useParams, Link } from 'react-router-dom';
|
||||
import { useSeason, useSeasonEpisodes } from '@/hooks/useSeasons';
|
||||
import { useCreateEpisodeSeen } from '@/hooks/useEpisodeSeen';
|
||||
import { useLibraryStore } from '@/stores/useLibraryStore';
|
||||
import { EpisodeSeenEditDialog } from '@/components/dialogs/EpisodeSeenEditDialog';
|
||||
import { ConfirmDialog } from '@/components/dialogs/ConfirmDialog';
|
||||
import { Skeleton } from '@/components/ui/skeleton';
|
||||
import { Progress } from '@/components/ui/progress';
|
||||
import { Badge } from '@/components/ui/badge';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Eye, CheckCircle2, ListChecks, ArrowLeft } from 'lucide-react';
|
||||
import { Eye, CheckCircle2, ListChecks } from 'lucide-react';
|
||||
import { getTmdbPosterUrl, getYear, formatDate } from '@/lib/media-utils';
|
||||
import type { Episode } from '@/types';
|
||||
import type { SeenAccuracy } from '@/types';
|
||||
@@ -21,6 +21,7 @@ export function SeasonPage() {
|
||||
const { data: season, isLoading } = useSeason(parseInt(seasonId!, 10));
|
||||
const { data: episodes = [] } = useSeasonEpisodes(parseInt(seasonId!, 10));
|
||||
const createEpisodeSeen = useCreateEpisodeSeen();
|
||||
const entryTitle = useLibraryStore((s) => s.entries.get(parseInt(entryId!, 10))?.title);
|
||||
const [dialogEpisode, setDialogEpisode] = useState<Episode | null>(null);
|
||||
const [markingAll, setMarkingAll] = useState(false);
|
||||
const [showMarkAllDialog, setShowMarkAllDialog] = useState(false);
|
||||
@@ -53,15 +54,18 @@ export function SeasonPage() {
|
||||
const progress = totalEpisodes > 0 ? (watchedCount / totalEpisodes) * 100 : 0;
|
||||
|
||||
return (
|
||||
<div className="space-y-8 animate-page-enter">
|
||||
{/* Back to entry */}
|
||||
<Link
|
||||
to={`/entry/${entryId}`}
|
||||
className="inline-flex items-center gap-1.5 text-sm text-muted-foreground hover:text-foreground transition-colors"
|
||||
>
|
||||
<ArrowLeft className="h-4 w-4" />
|
||||
Back to entry
|
||||
</Link>
|
||||
<div className="space-y-8 animate-page-enter mx-auto max-w-4xl">
|
||||
{/* Breadcrumb: Title / Season x */}
|
||||
<div className="flex items-center gap-1.5 text-sm text-muted-foreground">
|
||||
<Link
|
||||
to={`/entry/${entryId}`}
|
||||
className="hover:text-foreground transition-colors truncate max-w-50"
|
||||
>
|
||||
{entryTitle || 'Entry'}
|
||||
</Link>
|
||||
<span>/</span>
|
||||
<span className="text-foreground font-medium">Season {season.season_number}</span>
|
||||
</div>
|
||||
|
||||
{/* Header */}
|
||||
<div className="flex gap-6">
|
||||
|
||||
Reference in new issue
Block a user