Brand Guide

Components

Chips

Short, label-only answers to a question, where one or several can be chosen.

Single choice

One answer is a string. Pressing the chosen chip again clears it and sends '', so ignore the empty value when the question needs an answer.
What size of company do you want to join?

Multiple choice

Each chip leads with a plus that becomes a tick when chosen, so a chip never changes width.
Which areas do you work in?

Choose all that apply.

Small

chipSize="sm" is 32px tall, for chat. The default is 40px, for forms.

Other reveals an input

A full-width input 8px below the chips.
How did you hear about Dex?

Actions in a chip row

ChipAction sits after the answers and looks like them. Here More opens the rest of the options, and Something else opens a text box for the person's own answer.
Which languages do you work in?

Invalid

Every chip takes the red border, with one message under the group.
Where do you want to work?

Disabled

The chosen chip keeps its fill at 50%, so the answer still reads as chosen.

Quick replies

A row of ChipButtons above the message box. A press sends the reply at once, with nothing to confirm.

Press a reply to send it.

Starters

A starter is marked with a pencil. It fills the message box with the start of a reply for the person to finish.

Have you run Kubernetes in production before?

Best practices

  • Use chips for short answers that need no explanation. An option that needs a sentence of explanation is a choice card.
  • A chip is always a pill, so it never reads as a button.
  • Use the default 40px chip in forms and the small 32px chip in chat.
  • A chip group sits in a FieldSet with its question as the FieldLegend. Pass optional to the legend of a group that can be skipped. Without a visible question, give the group an aria-label.
  • Set invalid on the FieldSet, or aria-invalid on the ChipGroup, and every chip and action in it turns red. One message goes under the group.
  • A chip that does something rather than being an answer is a ChipButton or ChipAction, not a Chip. It is a plain button, so it is never on and a screen reader does not announce it as an unpressed toggle.