Text input
A text input takes one line of typed text, such as the name or the email address on the contact form. Value says whether it holds one — off shows the empty field, on shows Value text — and Validation=Error marks a value the form rejected.
- Design
- Finished
- Level
- Draft
- Audit
- 1 open findingat the audit of
- Last changed
- Resources
- Figma Propose a change
Preview


Usage
Do
- Set the label, the required marker and the description on the nested
_Label— "Email", required; "Name", optional - Choose
ValidationandValuefirst, thenDisabled, and leaveStateto code - Write the error message as what to change, not what went wrong
Don't
- Use for more than one line: use
Text area - Use for a search query: use
Search input - Use for picking from a fixed list: use
Dropdown input - Show
Validation=Errorwith no message
Behaviour
Validation=Erroradds_Error messagebeneath the field- Interactive states (
Focus,Hover) andDisabledare managed by code and not applied in static designs
Composition
- Contains
_Label, which carries the field's label, itsRequiredmarker and an optional description - Contains
_Error message, revealed byValidation=Error
Dependencies in Figma
Built from
Used by
Level checks
Draft · next level blocked by Errors open
| Check | Level | Result |
|---|---|---|
| Audited | Ready | Passes |
| No errors open | Ready | 1 error open |
| Has a description | Ready | Passes |
| Usage and Don't written | Ready | Checked at the next audit |
| Every layer named | Ready | Passes |
| In code | Ready | Passes |
| No warnings open | Stable | Passes |
| Code gen notes written | Stable | Checked at the next audit |
| Auto layout throughout | Stable | Checked at the next audit |
| Matches the design | Stable | Passes |
Anatomy
| # | Part | Shown | Component |
|---|---|---|---|
| 1 | Label | Always | _Label |
| 2 | Value | By Value | – |
Properties
| Property | Type | Values | Default |
|---|---|---|---|
| Disabled | Variant | FalseTrue | False |
| Validation | Variant | NoneError | None |
| State | Variant | RestFocusHover | Rest |
| Value text | Text | any text | Value |
| Value | Boolean | true, false | false |
States
| State | Set by |
|---|---|
| Focus | Interaction |
| Hover | Interaction |
| Disabled | The Disabled property |
Implementation
| Figma | Code | Why |
|---|---|---|
| Input, inside stroke | border with box-sizing: border-box and padding less the stroke, or box-shadow: inset 0 0 0 <width> | Figma's inside stroke takes no space; a border does. |
| Focus ring, a layer 4px outside the box | outline on :focus-visible, outline-offset 4px less the ring's width | Figma has no focus state, so it draws the ring as a layer; in code it is not an element. |
Disabled | disabled, or aria-disabled where it must stay focusable | The element's own state: the browser keeps it out of the tab order and out of form submission. |
Validation | aria-invalid, the message tied by aria-describedby | The error is announced, not only drawn. |
State: Focus, Hover | :focus-visible, :hover | Pseudo-classes the browser sets, so a template cannot claim a state the control is not in. |
| Change | Type | Figma files | Code | Details |
|---|---|---|---|---|
| Content: height | Restyled | Breaking | Minor | |
| Label: height | Restyled | Breaking | Minor | |
| *: height | Restyled | Breaking | Minor | |
| Input: position | Restyled | Breaking | Minor | |
| Text input: height · 2 variants | Restyled | Breaking | Minor | |
| _Error message: height | Restyled | Breaking | Minor | |
| _Error message: position | Restyled | Breaking | Minor | |
| circle-alert: position | Restyled | Breaking | Minor | |
| Label: position | Restyled | Breaking | Minor | |
| Value: height | Restyled | Breaking | Minor | |
| Value: position | Restyled | Breaking | Minor | |
| Label: text style | Restyled | Minor | Minor | |
| *: text style | Restyled | Minor | Minor | |
| Value: text style | Restyled | Minor | Minor | |
| Label: line height | Restyled | Minor | Minor | |
| Label: letter spacing | Restyled | Minor | Minor | |
| *: line height | Restyled | Minor | Minor | |
| *: letter spacing | Restyled | Minor | Minor | |
| Value: line height | Restyled | Minor | Minor | |
| Value: letter spacing | Restyled | Minor | Minor |
| Change | Type | Figma files | Code | Details |
|---|---|---|---|---|
| Description | Docs | Patch | Patch |
| Change | Type | Figma files | Code | Details |
|---|---|---|---|---|
| Label: props | Restyled | Minor | Minor |
| Change | Type | Figma files | Code | Details |
|---|---|---|---|---|
| Input: stroke | Restyled | Minor | Minor |
| Change | Type | Figma files | Code | Details |
|---|---|---|---|---|
| Value: fill | Restyled | Minor | Minor |
| Change | Type | Figma files | Code | Details |
|---|---|---|---|---|
| Layer circle-alert | Added | Minor | Patch | |
| Layer Label | Added | Minor | Patch | |
| Content: height | Restyled | Breaking | Minor | |
| Label: height | Restyled | Breaking | Minor | |
| *: height | Restyled | Breaking | Minor | |
| Input: position | Restyled | Breaking | Minor | |
| Text input: height · 2 variants | Restyled | Breaking | Minor | |
| _Error message: height | Restyled | Breaking | Minor | |
| _Error message: position | Restyled | Breaking | Minor | |
| Value: height | Restyled | Breaking | Minor | |
| Value: position | Restyled | Breaking | Minor | |
| circle-alert: position | Restyled | Breaking | Minor | |
| Label: position | Restyled | Breaking | Minor | |
| Label: line height | Restyled | Minor | Minor | |
| *: line height | Restyled | Minor | Minor | |
| _Error message: overrides | Restyled | Minor | Minor | |
| Value: line height | Restyled | Minor | Minor | |
| Instances re-pointed (14 layers) | Changed | Breaking | Minor | |
| Label: props | Restyled | Minor | Minor | |
| Component | Added | Minor | Minor |