From 874749df46cc291ca61f2f98092ccabfdeffbf16 Mon Sep 17 00:00:00 2001 From: yyamashita Date: Sat, 26 Sep 2026 00:19:53 +0900 Subject: Add passkey login and favorite search terms MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Single-user auth: any registered passkey logs in as the owner. First registration needs a one-time token that the app writes to data/registration-token when no passkey exists yet; once logged in, more passkeys can be added without a token. Logged in, /favorites manages a list of terms (e.g. band names). Events whose title or artist contains a term (NFKC + case-insensitive) get a ★, and the event list gains an "お気に入りのみ" filter. Co-Authored-By: Claude Opus 5.5 --- app/components/EventCard.tsx | 1 + app/components/EventListRow.tsx | 1 + app/components/FilterBar.tsx | 19 +++++++++++++++++-- 3 files changed, 19 insertions(+), 2 deletions(-) (limited to 'app/components') diff --git a/app/components/EventCard.tsx b/app/components/EventCard.tsx index b23742d..ad55a57 100644 --- a/app/components/EventCard.tsx +++ b/app/components/EventCard.tsx @@ -30,6 +30,7 @@ export default function EventCard({ event }: Props) {
{/* Title */}

+ {event.is_favorite ? ★ : null} {event.title}

diff --git a/app/components/EventListRow.tsx b/app/components/EventListRow.tsx index 30800fb..42f3e8b 100644 --- a/app/components/EventListRow.tsx +++ b/app/components/EventListRow.tsx @@ -31,6 +31,7 @@ export default function EventListRow({ event }: Props) { {/* Title + artist */} + {event.is_favorite ? ★ : null} {event.title} {event.artist && ( diff --git a/app/components/FilterBar.tsx b/app/components/FilterBar.tsx index 7a95d2c..f897e67 100644 --- a/app/components/FilterBar.tsx +++ b/app/components/FilterBar.tsx @@ -6,9 +6,11 @@ interface Props { areas?: string[]; defaultDateFrom?: string; defaultDateTo?: string; + /** Show the "favorites only" toggle (logged in only) */ + showFavorites?: boolean; } -export default function FilterBar({ venues, areas, defaultDateFrom, defaultDateTo }: Props) { +export default function FilterBar({ venues, areas, defaultDateFrom, defaultDateTo, showFavorites }: Props) { const [searchParams] = useSearchParams(); return ( @@ -98,6 +100,19 @@ export default function FilterBar({ venues, areas, defaultDateFrom, defaultDateT
+ {showFavorites && ( + + )} +