Interface FiltersOptions<Data>

Type interface for filtering options.

Type Parameters

Hierarchy

Custom Component Properties

DefaultComponent?: FilterComponent<Data>

Default filter component rendered for columns. This overrides the fallback text-input-field. Column specific components will override this component.

hideFiltersActionIndicator?: ReactNode

Indicator/icon used for action/button to hide the Filters Row.

showFiltersActionIndicator?: ReactNode

Indicator/icon used for action/button to show the Filters Row.

Other Properties

alwaysShowFilters?: boolean

Filters are always visible. Removes the button to show/hide filters.

Default

false

autoResetFilters?: boolean

Reset filtering when data is changed.

Default

true

defaultCanFilter?: boolean

Enable filtering for all columns, regardless if they have a valid accessor.

Default

false

disableFilters?: boolean

Disable column filtering for table.

Default

false

filterTypes?: Record<string, FilterType<Data>>

Allows overriding or adding additional filter types for columns to use. If a column's filter type isn't found on this object, it will default to using the built-in filter types. Must be memoised.

initialState?: FiltersState<Data>

Initial settings of filters. List of objects containing column id and value.

Example

{ filters: [{ id: 'columnsId', value: 'filterValue' }], visible: true }
manualFilters?: boolean

Manual filtering with custom logic, eg. server-side.

Default

false

onStateChange?: StateChangeHandler<FiltersState<Data>>

Callback executed when columns are sorted. The function must be wrapped in useCallback hook.

Generated using TypeDoc