You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -23,6 +23,7 @@ import { DataViewToolbar } from '@patternfly/react-data-view/dist/dynamic/DataVi
23
23
import { DataViewTable } from '@patternfly/react-data-view/dist/dynamic/DataViewTable';
24
24
import { DataViewFilters } from '@patternfly/react-data-view/dist/dynamic/DataViewFilters';
25
25
import { DataViewTextFilter } from '@patternfly/react-data-view/dist/dynamic/DataViewTextFilter';
26
+
import { DataViewCheckboxFilter } from '@patternfly/react-data-view/dist/dynamic/DataViewCheckboxFilter';
26
27
27
28
This is a list of functionality you can use to manage data displayed in the **data view**.
28
29
@@ -92,7 +93,7 @@ The `useDataViewSelection` hook manages the selection state of the data view.
92
93
Enables filtering of data records in the data view and displays the applied filter chips.
93
94
94
95
### Toolbar usage
95
-
The data view toolbar can include a set of filters by passing a React node to the `filters` property. You can use predefined components `DataViewFilters`and `DataViewTextFilter` to customize and handle filtering directly in the toolbar. The `DataViewFilters` is a wrapper allowing conditional filtering using multiple attributes. If you need just a single filter, you can use `DataViewTextFilter` or a different filter component alone. Props of these filter components are listed at the bottom of this page.
96
+
The data view toolbar can include a set of filters by passing a React node to the `filters` property. You can use predefined components `DataViewFilters`, `DataViewTextFilter`and `DataViewCheckboxFilter` to customize and handle filtering directly in the toolbar. The `DataViewFilters` is a wrapper allowing conditional filtering using multiple attributes. If you need just a single filter, you can use `DataViewTextFilter`, `DataViewCheckboxFilter` or a different filter component alone. Props of these filter components are listed at the bottom of this page.
96
97
97
98
You can decide between passing `value` and `onChange` event to every filter separately or pass `values` and `onChange` to the `DataViewFilters` wrapper which make them available to its children. Props directly passed to child filters have a higher priority than the "inherited" ones.
98
99
@@ -101,7 +102,7 @@ You can decide between passing `value` and `onChange` event to every filter sepa
101
102
The `useDataViewFilters` hook manages the filter state of the data view. It allows you to define default filter values, synchronize filter state with URL parameters, and handle filter changes efficiently.
102
103
103
104
**Initial values:**
104
-
-`initialFilters` object with default filter values
105
+
-`initialFilters` object with default filter values (if the filter param allows multiple values, pass an array)
105
106
- optional `searchParams` object for managing URL-based filter state
106
107
- optional `setSearchParams` function to update the URL when filters are modified
0 commit comments