DataFilters
packages/ui/src/components/data/DataFilters.tsx
Import
Subpath export:
@marktiderman/genesis-ui/dataimport { DataFilters } from "@marktiderman/genesis-ui/data";Components
Auto-generated from TypeScript source via
react-docgen-typescript.DataFilters
| Prop | Type | Default | Description |
|---|---|---|---|
| onSearchChange* | (value: string) => void | — | |
| onSortChange* | (sort: string) => void | — | |
| search* | string | — | |
| sort* | string | — | |
| sortOptions* | { value: string; label: string; nulls?: "first" | "last" | undefined; }[] | — | `value` is `field:asc` or `field:desc`. `nulls` says where rows with no value go on that sort (server-driven lists). |
| canSaveViews | boolean | false | |
| extra | ReactNode | — | Controls after the filter comboboxes in the filter row: a view's range and text filters. |
| extraActive | boolean | false | The `extra` controls narrow the list, so "Clear all" shows for them too. |
| filters | DataFilterConfig[] | [] | |
| leading | ReactNode | — | A row above the search row: ResourceView's segments (ADR 0017). |
| onClearAll | (() => void) | — | Called when "Clear all" is clicked |
| onDeleteView | ((id: string) => void) | — | |
| onError | ((message: string) => void) | — | Called when an error occurs |
| onLoadView | ((filters: Record<string, unknown>) => void) | — | |
| onSaveView | ((name: string) => void) | — | |
| onViewSaved | ((name: string) => void) | — | Called after a view is saved successfully |
| savedViews | SavedViewItem[] | [] | Saved views |
| searchInputRef | RefObject<HTMLInputElement | null> | — | Expose the search input ref for keyboard nav "/" shortcut |
| searchPlaceholder | string | — | |
| showSearch | boolean | true | Show the search box. Default `true`; turn off when the data source can't search. |
| showSort | boolean | true | Show the sort select. Default `true`; turn off when the data source can't sort. |
| statusChips | { options: (string | StatusChipOption)[]; selected: string[]; onChange: (values: string[]) => void; variant?: StatusChipsVariant; } | — | Status chip toggles |