Input Component
Description
The Input
component is a reusable text input field supporting:
- Multiple variants: outlined
, filled
, and standard
- Error handling and helper text
- Start and end adornments
- Multiline text area support
- Clear button functionality
Props
Prop | Type | Default | Description |
---|---|---|---|
id |
string |
- |
Unique identifier for the input. |
label |
string |
- |
The label for the input field. |
variant |
"outlined" , "filled" , "standard" |
"outlined" |
Defines the input style. |
fullWidth |
boolean |
false |
Expands input width to 100%. |
error |
boolean |
false |
Highlights input as an error. |
helperText |
string |
- |
Additional message under the input. |
disabled |
boolean |
false |
Disables the input. |
multiline |
boolean |
false |
Enables textarea mode. |
rows |
number |
1 |
Number of rows for multiline. |
startAdornment |
ReactNode |
- |
Component before the input. |
endAdornment |
ReactNode |
- |
Component after the input. |
onClear |
() => void |
- |
Callback when clear button is clicked. |
showClearButton |
boolean |
false |
Shows clear button if input has value. |
Example Usage
Useful Links
🔗 GitHub Repository (Core): Liberty Core
🔗 GitHub Repository (Test Project): Liberty Test
📖 Live Documentation: Liberty Core Docs
💖 Sponsor & Support: Sponsor Liberty Core