ComboInput
Campo de texto con lista de sugerencias asociada.
import { ComboInput } from '#LibComponents/react/atomic/comboinput/comboinput.component';N/A
- 1
- 2
- 3
<ComboInput name="origen" items={items} onSelect={fn} />Props del tipo del componente
| Prop | Tipo | Obligatorio | Default | Descripción |
|---|---|---|---|---|
onSelectChange | (inputValue: StaticFields) => void | sí | — | |
onChange | (inputValue: StaticFields) => void | sí | — | |
onFocus | (name: string) => void | no | — | |
onFormError | (error: ErrorOnField) => void | no | — | |
autocomplete | 'on' | 'off' | no | — | |
className | string | no | — | |
classOpts | {
classInput?: string;
classNameFocused?: string;
classBody?: string;
classBodyOpen?: string;
classItem?: string;
classError?: string;
} | no | — | |
comboName | string | sí | — | |
defaultSelected | T | no | — | |
disabled | boolean | no | — | |
forceUpdate | boolean | no | — | |
hasToggle | boolean | no | — | |
hasError | boolean | no | — | |
i18n | {
placeholder?: string;
noresults?: string;
resultlist?: string;
customErrMesg?: string;
} | no | — | |
label | string | sí | — | |
lazyloading | boolean | no | — | |
errorMark | boolean | no | — | |
name | string | sí | — | |
required | boolean | no | — | |
selectItems | Array<T> | sí | — | |
value | string | sí | — | |
validPatterns | RegExp[] | no | — | |
renderHeader | (option: T | undefined) => JSX.Element | null | no | — | |
renderOption | (option: T | undefined) => JSX.Element | null | no | — | |
mapOption | (option: T | undefined) => string | sí | — | |
round | 'none' | 'sm' | 'md' | 'lg' | no | — | |
labelFloating | boolean | no | — |