Checkbox

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

Specifications

Component design specifications
Component 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 component states.
Checkbox component states.

Anatomy

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

Design tokens

Color

On-light

Component tokenElementCore tokenValue
selectedBackgroundColorFillcolor-blue-800#0067b3
selectedHoverBackgroundColorFill:hovercolor-blue-900#003c66
selectedDisabledBackgroundColorFill:disabledcolor-grey-500#999999
borderColorBordercolor-blue-800#0067b3
hoverBorderColorBorder:hovercolor-blue-900#003c66
disabledBorderColorBorder:disabledcolor-grey-500#999999
checkColorCheck markcolor-white#ffffff
disabledCheckColorCheck mark:disabledcolor-white#ffffff
fontColorLabelcolor-black#000000
disabledFontColorLabel:disabledcolor-grey-500#999999
focusColorOutline:focuscolor-blue-600#0095ff

On-dark

Component tokenElementCore tokenValue
selectedBackgroundColorOnDarkFillcolor-grey-200#e6e6e6
selectedHoverBackgroundColorOnDarkFill:hovercolor-white#ffffff
selectedDisabledBackgroundColorOnDarkFill:disabledcolor-grey-800#4d4d4d
borderColorOnDarkBordercolor-grey-200#e6e6e6
hoverBorderColorOnDarkBorder:hovercolor-white#ffffff
disabledBorderColorOnDarkBorder:disabledcolor-grey-800#4d4d4d
checkColorOnDarkCheck markcolor-black#000000
disabledCheckOnDarkCheck mark:disabledcolor-grey-500#999999
fontColorOnDarkLabelcolor-white#ffffff
disabledFontColorOnDarkLabel:disabledcolor-grey-500#999999
focusColorOnDarkOutline: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