Skip to main content

Category filter

Usage

PreviewAngularReactVueJavascript

without categories

PreviewAngularReactVueJavascript

Properties

Props

Name
Description and specifications
categories
Configuration object hash used to populate the dropwdown menu for typeahead and quick selection functionality. Each ID maps to an object with a label and an array of options to select from.
Type:
{ [id: string]: { label: string; options: string[]; }; }
disabled
If true the filter will be in disabled state
Attribute:
disabled
Type:
boolean
Default:
false
filterState
A set of search criteria to populate the component with.
Type:
FilterState
hideIcon
Allows to hide the icon inside the text input. Defaults to false
Attribute:
hide-icon
Type:
boolean
i18nPlainText
i18n
Attribute:
i-1-8n-plain-text
Type:
string
Default:
'Filter by text'
icon
The icon next to the actual text input Defaults to 'search'
Attribute:
icon
Type:
string
Default:
'search'
labelCategories
i18n
Attribute:
label-categories
Type:
string
Default:
'Categories'
nonSelectableCategories
In certain use cases some categories may not be available for selection anymore. To allow proper display of set filters with these categories this ID to label mapping can be populated. Configuration object hash used to supply labels to the filter chips in the input field. Each ID maps to a string representing the label to display.
Type:
{ [id: string]: string; }
Default:
{}
placeholder
Placeholder text to be displayed in an empty input field.
Attribute:
placeholder
Type:
string
readonly
If true the filter will be in readonly mode
Attribute:
readonly
Type:
boolean
Default:
false
repeatCategories
If set to true allows that a single category can be set more than once. An already set category will not appear in the category dropdown if set to false. Defaults to true
Attribute:
repeat-categories
Type:
boolean
Default:
true
staticOperator
Since 2.2.0
If set categories will always be filtered via the respective logical operator. Toggling of the operator will not be available to the user.
Attribute:
static-operator
Type:
LogicalFilterOperator.EQUAL | LogicalFilterOperator.NOT_EQUAL
suggestions
A list of strings that will be supplied as typeahead suggestions not tied to any categories.
Type:
string[]

Events

Name
Description and specifications
categoryChanged
Event dispatched whenever the a category gets selected in the dropdown
Detail:
string
filterChanged
Event dispatched whenever the filter state changes.
Detail:
FilterState
inputChanged
Event dispatched whenever the text input changes.
Detail:
InputState