Skip to content

Forms

Form components handle user input. They should be clear, accessible, and provide helpful feedback at every step.

ControlHeightStates
Text input40pxdefault, focus, error, disabled
Textareaauto (min 80px)default, focus, error, disabled
Select40pxdefault, focus, error, disabled
Checkbox20×20pxunchecked, checked, indeterminate, disabled
Radio20×20pxunselected, selected, disabled
Toggle / Switch24×44pxoff, on, disabled
  • Labels sit above the input, use text-sm font-medium
  • Required fields append a red asterisk or “(Required)” hint
  • Helper text sits below the input, text-xs text-gray-500
  • Error messages replace helper text, use text-xs text-red-600
StateBorderDescription
Defaultgray-300Normal resting state
Focusbrand-500 + ringActive, user is typing
Errorred-500 + ringFailed validation, show error
Successgreen-500Validated and accepted
Disabledgray-200, bg gray-50Non-editable
  • Single column for most forms (easier to scan)
  • Two columns only for related short fields (first/last name, city/zip)
  • Group related fields into fieldsets with a legend
  • Submit button aligned to the left (below the last field)