type- Type
string- Default
"text"- Description
- HTML input type — text, email, password, number, tel, etc.
Search for a command to run...
Components / Inputs
உள்ளீடு
The Input component is a single-line text field. It wraps the native HTML input element with Tamil DS styling, focus states, and error state support.
உள்ளீடு கூறு ஒற்றை வரி உரை புலம். HTML input அலகை Tamil DS வடிவமைப்புடன் மூடுகிறது.
4 parts documented for implementation and review.
<input>Native HTML input element with Tamil DS styling. Height is 40px (h-10), border uses rounded-md. On focus, shows a 2px brand ring (focus-visible:ring-ring/25). On hover, border subtly darkens (border-foreground/20). Error state triggered via aria-invalid='true' switches border to destructive red.
Hint text shown when the field is empty, rendered at 60% opacity of muted-foreground. Should be an example value, not instructions — use 'முத்துக்குமார்' not 'Enter your name'. For bilingual, show both: 'முத்துக்குமார் / Muthukumar'.
User-entered text inheriting the font stack — Inter for Latin characters, Noto Sans Tamil for Tamil script. Size is 14px (text-sm). The input supports all HTML types: text, email, password, number, tel, url. Use inputMode='numeric' for Aadhaar/pin fields.
svgAn absolutely-positioned icon inside a relative wrapper div. Requires pl-9 on the input to prevent text overlap. Sized at 16×16px. Positioned via left-3 top-1/2 -translate-y-1/2 for perfect vertical centering. Common icons: Search, Mail, Lock, User.
typestring"text"placeholderstringdisabledbooleanfalsereadOnlybooleanfalsearia-invalid"true" | "false"| Prop | Type | Default | Description |
|---|---|---|---|
type | string | "text" | HTML input type — text, email, password, number, tel, etc. |
placeholder | string | - | Hint text. Use Tamil examples for Tamil-primary UIs. |
disabled | boolean | false | Disables the field. |
readOnly | boolean | false | Makes the field non-editable but focusable. |
aria-invalid | "true" | "false" | - | Set to true when the field has a validation error. |
Help users understand the expected format by showing a realistic example value.
யதார்த்தமான உதாரண மதிப்பைக் காட்டுவதன் மூலம் எதிர்பார்க்கப்படும் வடிவமைப்பு மற்றும் தகவலை பயனர்கள் புரிந்துகொள்ள உதவவும்.
Placeholders disappear on typing. Never use them for critical instructions like 'Enter your name here'.
டைப் செய்யும்போது இடப்பிடிப்பான்கள் மறைந்துவிடும். எனவே 'உங்கள் மொபைல் எண்ணை இங்கே உள்ளிடவும்' போன்ற முக்கியமான அறிவுறுத்தல்களுக்கு இவற்றை ஒருபோதும் பயன்படுத்த வேண்டாம்.
maxLength=12, numeric keyboard on mobile via inputMode="numeric".