Input Text

Text inputs are form controls that allow users to enter and edit single lines of text or data

Ref to 134:5172

Resources

Intro & Anatomy

Text inputs are form controls that enable users to enter and edit single lines of text or specific data types.

Use text inputs for collecting user information such as names, addresses, or single-line responses where users need to provide typed input.

Text inputs can be configured for specific data types including passwords, phone numbers, dates and email addresses. Text inputs can also feature an auto complete function.

inputText/anatomy

 


 

Options & Styles

Label & Helpers

Label is always required to provide clear context for expected input.
Hint is optional and provides additional guidance or examples.
Counter is optional and shows character limits or current count.
Icon is optional and should only be used when it provides additional benefit.

inputText/label

Input Values

Input value displays the user's entered text or data.
Placeholder is optional and provides example formatting or expected content.

inputText/values

Validation

Text inputs provide visual feedback during validation processes:

Validating (loading) shows when input is being processed or checked
Success indicates valid input that meets requirements
Error highlights invalid input with specific guidance for correction

inputText/validation

States

Text inputs have multiple interactive states:

Default for standard input appearance
Hover for interactive feedback when users engage with the field
Error for validation failures requiring user attention

inputText/states

Disabled

Disabled text inputs show that a field exists but isn't currently available for input, e.g. when certain conditions haven't been met or the field is temporarily unavailable.

inputText/disabled

 


 

Best Practice & Usage

Text inputs should provide clear context through labels and helpful guidance through hints and validation messages. Use text inputs for single-line data entry with appropriate formatting and validation for the expected content type.

input/usage/do-label
input/usage/don't-noLabel
input/usage/do-oneInputperInput
input/usage/don't-multipleInputinoneinput
input/usage/do-mindfulicon
input/usage/don't-overuseIcon
input/usage/do-informativeHint
input/usage/don't-vagueHint
inputPW/usage/do2
inputPW/usage/don't2
input/usage/do-singleLine
input/usage/don't-longtext

 


 

Theming

You can customise colours, border width and radius, font styles and weights, spacings and sizes to match your design requirements.

When not using MDX icons, a slot is available to use your own icon library or SVG icons.