Checkbox

Checkboxes are inputs that offer to the user the possibility to select one or more options from a range of attributes.

Specifications

Checkbox design specifications
Checkbox design specifications

States

The following states are defined in the life cycle of the component: unselected enabled, unselected hover, unselected focus, unselected disabled, selected enabled, selected hover, selected focus and selected disabled.

Checkbox states
Checkbox states

Anatomy

Checkbox anatomy
  1. 1.
    Checkbox input
  2. 2.
    Label

Design tokens

Color

Component tokenElementCore tokenValue
backgroundColorCheckedFillcolor-blue-800#0067b3
hoverBackgroundColorCheckedFill:hovercolor-blue-900#003c66
disabledBackgroundColorCheckedFill:disabledcolor-grey-500#999999
readOnlyBackgroundColorCheckedFill:readonlycolor-grey-500#999999
hoverReadOnlyBackgroundColorCheckedFill:readonly:hovercolor-grey-600#808080
borderColorBordercolor-blue-800#0067b3
hoverBorderColorBorder:hovercolor-blue-900#003c66
disabledBorderColorBorder:disabledcolor-grey-500#999999
readOnlyBorderColorBorder:readonlycolor-grey-500#999999
hoverReadOnlyBorderColorBorder:readonly:hovercolor-grey-600#808080
checkColorCheck markcolor-white#ffffff
disabledCheckColorCheck mark:disabledcolor-white#ffffff
readOnlyCheckColorCheck mark:readonlycolor-white#ffffff
fontColorLabelcolor-black#000000
disabledFontColorLabel:disabledcolor-grey-500#999999
focusColorOutline:focuscolor-blue-600#0095ff

Spacing

Component tokenElementCore tokenValue
inputMarginCheckbox inputspacing-80.5rem / 8px

Typography

Component tokenElementCore tokenValue
fontFamilyLabelfont-family-sans'Open Sans', sans-serif
fontSizeLabelfont-scale-020.875rem / 14px
fontWeightLabelfont-weight-regular400

Border

PropertyElementCore tokenValue
border-widthCheckbox inputborder-width-22px
border-styleCheckbox inputborder-style-solidsolid
border-radiusCheckbox inputborder-radius-small0.125rem / 2px
border-widthFocus borderborder-width-22px
border-styleFocus borderborder-style-solidsolid
border-radiusFocus borderborder-radius-medium0.25rem / 4px

Margin

Margin can be set independently for top, right, bottom, left.

MarginValue
xxsmall6px
xsmall16px
small24px
medium36px
large48px
xlarge64px
xxlarge100px

Accessibility

WCAG 2.2

WAI-ARIA 1.2