Input
Click me!
Interfaces
InputProps
Defined in: input.types.ts:8
The Input component properties.
Extends
unknown<JSX.InputHTMLAttributes<HTMLInputElement>>
Properties
disabled?
optionaldisabled:boolean
Defined in: input.types.ts:61
Whether the input is disabled.
Default
false;forceOption?
optionalforceOption:boolean
Defined in: input.types.ts:38
If true, validation will fail if the input value is not in the list of options.
Default
false;icon?
optionalicon:string
Defined in: input.types.ts:16
An optional icon to render as part of the label.
label
label:
string
Defined in: input.types.ts:12
The input label.
onChange()?
optionalonChange: (value,event) =>void
Defined in: input.types.ts:67
Called when the input value changes.
Parameters
value
string
The input value.
event
Event & object
The input event.
Returns
void
onInput()?
optionalonInput: (value,event) =>void
Defined in: input.types.ts:79
Called when a character is being inserted or removed.
Parameters
value
string
The input value.
event
Event & object
The input event.
Returns
void
options?
optionaloptions:SelectOption[]
Defined in: input.types.ts:33
An optional list of options for the input. Will be rendered into a
required?
optionalrequired:boolean
Defined in: input.types.ts:56
Whether the input is required.
Default
false;size?
optionalsize:ControlSize
Defined in: input.types.ts:43
The size of the input.
Default
undefined;type?
optionaltype:InputType
Defined in: input.types.ts:21
The type of the input.
Default
'text';value?
optionalvalue:string
Defined in: input.types.ts:28
The input value. If not provided, the input will be uncontrolled and will manage its own state. If provided, the input will be controlled and will use this value as its current value.
Default
undefined;variant?
optionalvariant:string
Defined in: input.types.ts:51
The input variant.
Default
'contained';Variables
Input
constInput:Component<InputProps>
Defined in: input.component.tsx:12
A flexible input component.
Param
Returns
The input component.