InputText
The InputText component is a text input field used for collecting single-line text data from users.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
placeholder | string | - | Placeholder text for the input field. |
disabled | boolean | false | When present, it specifies that the input is disabled. |
invalid | boolean | false | When present, it specifies that the input is invalid. |
Example component
html
<InputText placeholder="Enter text" />States
Default
The default state of the input text field.
html
<InputText placeholder="Enter your name" />Disabled
The disabled state prevents user interaction with the input field.
html
<InputText placeholder="John" disabled />Invalid
The invalid state indicates validation errors.
html
<InputText placeholder="John" invalid />