diff --git a/frontend/src/components/PlexSidebar.tsx b/frontend/src/components/PlexSidebar.tsx index 744f5b42..824bfa61 100644 --- a/frontend/src/components/PlexSidebar.tsx +++ b/frontend/src/components/PlexSidebar.tsx @@ -33,6 +33,43 @@ const DURATION_BUCKETS: { key: string; min: number | null; max: number | null }[ { key: "long", min: 120 * 60, max: null }, ]; +// The any/all combine toggle for a multi-value filter (genres, actors). Same segmented-pill look as +// the feed rail's tag MATCH toggle (rounded-full track + inset active pill), not a boxed button row. +function MatchToggle({ + mode, + onChange, +}: { + mode: "any" | "all"; + onChange: (m: "any" | "all") => void; +}) { + const { t } = useTranslation(); + return ( +
+ + {t("plex.filter.matchLabel")} + +
+ {(["any", "all"] as const).map((m) => ( + + ))} +
+
+ ); +} + export default function PlexSidebar({ layout, setLayout, @@ -212,20 +249,11 @@ export default function PlexSidebar({ /> ))} {filters.actors.length > 1 && ( -
- {(["any", "all"] as const).map((m) => ( - - ))} +
+ patch({ actorMode: m })} + />
)} {filters.actors.map((a) => ( @@ -312,21 +340,10 @@ export default function PlexSidebar({ body: ( <> {filters.genres.length > 1 && ( -
- {(["any", "all"] as const).map((m) => ( - - ))} -
+ patch({ genreMode: m })} + /> )} {facets.genres.map((g) => ( diff --git a/frontend/src/i18n/locales/en/plex.json b/frontend/src/i18n/locales/en/plex.json index 9f016131..6c06b02a 100644 --- a/frontend/src/i18n/locales/en/plex.json +++ b/frontend/src/i18n/locales/en/plex.json @@ -57,7 +57,8 @@ }, "collection": "Collection", "collectionSearch": "Search collections…", - "collectionEmpty": "No collections" + "collectionEmpty": "No collections", + "matchLabel": "Match" }, "count": "{{count}} titles", "searchCount": "{{count}} matches", diff --git a/frontend/src/i18n/locales/hu/plex.json b/frontend/src/i18n/locales/hu/plex.json index c91be3a0..92809e5e 100644 --- a/frontend/src/i18n/locales/hu/plex.json +++ b/frontend/src/i18n/locales/hu/plex.json @@ -57,7 +57,8 @@ }, "collection": "Kollekció", "collectionSearch": "Kollekciók keresése…", - "collectionEmpty": "Nincs kollekció" + "collectionEmpty": "Nincs kollekció", + "matchLabel": "Egyezés" }, "count": "{{count}} cím", "searchCount": "{{count}} találat",