feat: add file upload and management features; enhance pagination and permissions handling
Some checks failed
Workflow / ʦ TypeScript (push) Failing after 5m43s
Workflow / ⚫️ Test (push) Has been skipped

This commit is contained in:
T. Zehetbauer
2026-04-01 20:13:15 +02:00
parent db4e19c3af
commit bbb33aa63d
39 changed files with 2858 additions and 99 deletions

View File

@@ -5,6 +5,7 @@ import { useCallback } from 'react';
import { useRouter, useSearchParams, usePathname } from 'next/navigation';
import { Search } from 'lucide-react';
import { useTranslations } from 'next-intl';
import { Button } from '../shadcn/button';
import { Input } from '../shadcn/input';
@@ -40,11 +41,13 @@ interface ListToolbarProps {
* Resets to page 1 on any filter/search change.
*/
export function ListToolbar({
searchPlaceholder = 'Suchen...',
searchPlaceholder,
searchParam = 'q',
filters = [],
showSearch = true,
}: ListToolbarProps) {
const t = useTranslations('common');
const resolvedPlaceholder = searchPlaceholder ?? t('searchPlaceholder');
const router = useRouter();
const pathname = usePathname();
const searchParams = useSearchParams();
@@ -84,12 +87,12 @@ export function ListToolbar({
name="search"
type="search"
defaultValue={currentSearch}
placeholder={searchPlaceholder}
placeholder={resolvedPlaceholder}
className="w-64"
/>
<Button type="submit" variant="outline" size="sm">
<Search className="mr-1 h-4 w-4" />
Suchen
{t('search')}
</Button>
</form>
)}