diff --git a/app/pages/Search.tsx b/app/pages/Search.tsx index b357ffe..2d17f0b 100644 --- a/app/pages/Search.tsx +++ b/app/pages/Search.tsx @@ -70,6 +70,15 @@ const TagMapping = { }, }; +const WhereMapping = { + releases: "Релизах", + list: "Списках", + history: "Истории", + favorites: "Избранном", + collections: "Коллекциях", + profiles: "Профилях", +}; + export function SearchPage() { const router = useRouter(); const searchParams = useSearchParams(); @@ -318,8 +327,13 @@ const FiltersModal = (props: { Params.delete("list"); } - Params.set("searchBy", searchBy); - props.setSearchBy(searchBy); + if (!["profiles", "collections"].includes(where)) { + Params.set("searchBy", searchBy); + props.setSearchBy(searchBy); + } else { + Params.delete("searchBy"); + props.setSearchBy("name"); + } const url = new URL(`/search?${Params.toString()}`, window.location.origin); router.push(url.toString()); @@ -332,27 +346,27 @@ const FiltersModal = (props: {
Искать в
-Искать по
-Искать по
+