Search bar
Search bar
Component demo
Interactive example
<ic-search-barlabel="What is your favourite coffee?"></ic-search-bar>
<IcSearchBarlabel="What is your favourite coffee?"options={options}onIcChange={(ev)=>console.log(ev.detail.value)}onIcSubmitSearch={(ev)=>console.log(ev.detail.value)}placeholder="Start typing to search…"/>
Search bar details
Props
All components also accept native properties supported by the DOM, such asclassName
and
style
.
|
|
|
---|---|---|
|
The label for the search bar. |
|
|
The automatic capitalisation of the text value as it is entered/edited by the user. Available options: "off", "none", "on", "sentences", "words", "characters". |
|
|
The state of autocompletion the browser can apply on the text value. |
|
|
The state of autocorrection the browser can apply when the user is entering/editing the text value. |
|
|
If |
|
|
The number of characters until suggestions appear. The submit button will be disabled until the inputted value is equal to or greater than this number. |
|
|
The amount of time, in milliseconds, to wait to trigger the |
|
|
Specify whether to disable the built in filtering. For example, if options will already be filtered from external source.
If |
|
|
If |
|
|
The text displayed when there are no options in the option list. |
|
|
If |
|
|
Specify whether the search bar fills the full width of the container.
If |
|
|
The helper text that will be displayed for additional field guidance. |
|
|
If |
|
|
The hint text for the hidden assistive description element. |
|
|
The custom name for the label field to correspond with the IcMenuOption type. |
|
|
Trigger loading state when fetching options asynchronously |
|
|
Change the message displayed when external loading times out. |
|
|
Change the message displayed whilst the options are being loaded externally. |
|
|