Skip to main content
TextFieldText fields allows the user to write or edit text.
Usage ExamplesText fields are used primarily in forms to allow users to enter text. Text fields are normally found within a form but can also be part of a settings screen or an interactive flow.
StructureMarkdown: 1. **Label** Describes the information that the user needs to enter. The label should be short and clear, preferably a noun. 2. **Placeholder** (optional) Placeholders can serve as an assistive text that can provide additional aid or context to the user. Don’t use it to display critical information - as it disappears when the users starts typing. 3. **Helper text** (optional) Use this to provide a hint or a disclaimer about the content of the field. For example, “Passwords must contain at least 8 characters” 4. **Clear button** Lets the user to easily clear the input value. Appears only when value was typed. 5. **Character count** Should be used if there is a character limit. Displays the amount of typed characters out of total allowed. If the limit is reached, the counter will become red and further typing is disabled. 6. **Validation message** Demonstrates that a required input is missing something or the entry was invalid.
States
PropertyComponent
Inactive (default)
Focused
Typing
Inactive Full
Validation Full
Warning
(WIP)
Success Validation
Disabled
Read Only
Styles
PropertyComponent
Outline (Default)
Underline
PropertyComponent
Leading Accessory (Prefix)
Trailing Accessory (Suffix)
Top Trailing Accessory
Characters Limit
Delete Value Icon
SpecMarkdown: **Label** bodySmall, $textNeutralHeavy **Placeholder** body, $textNeutralLight **Value** body, $textDefault **Helper Text** subtext, $textNeutralHeavy **Character Count** bodySmall, $textNeutralHeavy **Validation message** Message - bodySmall, $textDangerLight Icon - exclamationFillSmall, $iconDangerLight **Prefix & Suffix** body, $textNeutral **Clear Button** xFlat, $textNeutralLight **Warning Message** Message - bodySmall, $textDefault Icon - exclamationFillSmall, $iconDefault **Validation Success** Icon - checkmarkFlatSmall, $iconSuccess **Outline - Default/unfocused** 1p, $outlineNeutral **Outline - Focused, typing** 1p, $outlinePrimary **Outline - Validation** 1p, $outlineDanger **Outline - Disabled** 1p, $outlineDisabled **Outline - Read only** fill background- $backgroundNeutralLight