@manta-eu/react/filter-bar
Reference for @manta-eu/react/filter-bar as it is on main.
Type Aliases
ClearFiltersProps
ClearFiltersProps =
object
Properties
label?
optionallabel?:string
onClick
onClick: () =>
void
Returns
void
FilterBarProps
FilterBarProps =
object
Properties
children?
optionalchildren?:ReactNode
className?
optionalclassName?:string
search?
optionalsearch?:ReactNode
FilterBarSearchProps
FilterBarSearchProps =
object
Properties
label
label:
string
maxLength?
optionalmaxLength?:number
onValueChange
onValueChange: (
value) =>void
Parameters
value
string
Returns
void
placeholder?
optionalplaceholder?:string
value
value:
string
FilterDropdownProps
FilterDropdownProps<
T> =object
Type Parameters
T
T
Properties
fullWidth?
optionalfullWidth?:boolean
label
label:
string
name?
optionalname?:string
Shown while the first option is picked (“Status”); otherwise the pick shows.
onChange
onChange: (
value) =>void
Parameters
value
T
Returns
void
options
options: readonly
FilterOption<T>[]
value
value:
T
FilterFoldProps
FilterFoldProps =
object
Properties
at
at:
FilterFoldWidth
Container width from which wide shows.
folded?
optionalfolded?:ReactNode
wide
wide:
ReactNode
FilterFoldWidth
FilterFoldWidth =
"48rem"|"63rem"
FilterOption
FilterOption<
T> =object
Type Parameters
T
T
Properties
count?
optionalcount?:number
id
id:
T
label
label:
string
ListFiltersProps
ListFiltersProps =
object
Properties
activeCount
activeCount:
number
children
children:
ReactNode
label?
optionallabel?:string
mobileSort?
optionalmobileSort?:ReactNode
onReset
onReset: () =>
void
Returns
void
resetLabel?
optionalresetLabel?:string
MoreFiltersProps
MoreFiltersProps =
object
Properties
activeCount
activeCount:
number
children
children:
ReactNode
label?
optionallabel?:string
TableSortChoice
TableSortChoice =
object
Properties
onChange
onChange: (
value) =>void
Parameters
value
string
Returns
void
options
options:
FilterOption<string>[]
value
value:
string
TableSortWords
TableSortWords =
object
Properties
columnLabels?
optionalcolumnLabels?:Record<string,string>
defaultOrderLabel?
optionaldefaultOrderLabel?:string
sortLabel?
optionalsortLabel?: (column,desc) =>string
One sort option’s words; “Name, ascending” by default.
Parameters
column
string
desc
boolean
Returns
string
Variables
filterBarContainer
constfilterBarContainer:"@container/filters"="@container/filters"
Put on the list’s container; folds read its width, not the window’s.
Functions
ClearFilters()
ClearFilters(
props):Element
Parameters
props
Returns
Element
FilterBar()
FilterBar(
props):Element
Parameters
props
Returns
Element
FilterBarSearch()
FilterBarSearch(
props):Element
Parameters
props
Returns
Element
FilterDropdown()
FilterDropdown<
T>(props):Element
A single-choice filter; the first option means no filter.
Type Parameters
T
T extends string | number
Parameters
props
Returns
Element
FilterFold()
FilterFold(
props):Element
Parameters
props
Returns
Element
ListFilters()
ListFilters(
props):Element
Parameters
props
Returns
Element
MoreFilters()
MoreFilters(
props):Element
Parameters
props
Returns
Element
tableSortChoice()
tableSortChoice<
TData>(table,words?):TableSortChoice
Type Parameters
TData
TData
Parameters
table
Table<TData>
words?
TableSortWords = {}