SearchBar

SearchBar UI Component

Installation

npm i @synerise/ds-search-bar
or
yarn add @synerise/ds-search-bar

Usage

import SearchBar from '@synerise/ds-search-bar'
<SearchBar />

Demo

API

PropertyDescriptionTypeDefault
autofocusWhether the input is focusedbooleanfalse
classNameOptional class for the componentstring-
clearTooltipTooltip description above clear buttonstring / React.ReactNode-
disabledWhether the input is disabled.boolean-
iconLeftPlace for optional icon on the left sideReact.ReactNode-
onSearchChangeCallback when user input() => void-
onClearInputCallback when user press clear button() => void-
placeholderPlaceholderstring / React.ReactNode-
valueThe input content valuestring-
autofocusDelayDelay (ms) of the focus on search inputnumber0