diff --git a/frontend/src/pages/Home.tsx b/frontend/src/pages/Home.tsx index 350e3ef..c409b23 100644 --- a/frontend/src/pages/Home.tsx +++ b/frontend/src/pages/Home.tsx @@ -3,7 +3,6 @@ import { Link, useSearchParams } from 'react-router-dom'; import { Project, PaginatedResponse } from '../types'; import { listProjects, createProject } from '../api'; import { Badge } from '../components/Badge'; -import { SearchInput } from '../components/SearchInput'; import { SortDropdown, SortOption } from '../components/SortDropdown'; import { FilterDropdown, FilterOption } from '../components/FilterDropdown'; import { FilterChip, FilterChipGroup } from '../components/FilterChip'; @@ -34,7 +33,6 @@ function Home() { // Get params from URL const page = parseInt(searchParams.get('page') || '1', 10); - const search = searchParams.get('search') || ''; const sort = searchParams.get('sort') || 'name'; const order = (searchParams.get('order') || 'asc') as 'asc' | 'desc'; const visibility = searchParams.get('visibility') || ''; @@ -59,7 +57,6 @@ function Home() { setLoading(true); const data = await listProjects({ page, - search, sort, order, visibility: visibility as 'public' | 'private' | undefined || undefined, @@ -71,7 +68,7 @@ function Home() { } finally { setLoading(false); } - }, [page, search, sort, order, visibility]); + }, [page, sort, order, visibility]); useEffect(() => { loadProjects(); @@ -92,10 +89,6 @@ function Home() { } } - const handleSearchChange = (value: string) => { - updateParams({ search: value, page: '1' }); - }; - const handleSortChange = (newSort: string, newOrder: 'asc' | 'desc') => { updateParams({ sort: newSort, order: newOrder, page: '1' }); }; @@ -112,7 +105,7 @@ function Home() { setSearchParams({}); }; - const hasActiveFilters = search !== '' || visibility !== ''; + const hasActiveFilters = visibility !== ''; const projects = projectsData?.items || []; const pagination = projectsData?.pagination; @@ -172,12 +165,6 @@ function Home() { )}
- - {search && handleSearchChange('')} />} {visibility && ( @@ -333,7 +333,7 @@ function PackagePage() { {hasActiveFilters && ( - {search && handleSearchChange('')} />} + {search && handleSearchChange('')} />} )} diff --git a/frontend/src/pages/ProjectPage.tsx b/frontend/src/pages/ProjectPage.tsx index 43e2d6f..c04bb2b 100644 --- a/frontend/src/pages/ProjectPage.tsx +++ b/frontend/src/pages/ProjectPage.tsx @@ -226,7 +226,7 @@ function ProjectPage() {