Design System

Icon reference ​

Sizes, prefixes and the component API. For what these mean, see Overview. For how to choose between them, see Usage.

Sizes ​

ClassSizeFor
noneinherits, 1emAn icon sitting beside text. The usual case
icon-marker12pxA glyph inside a dense marker, a tag or a badge
icon-message32pxA glyph that is the subject of a message: an empty state, a card, a footer notice, a confirmation

Both rungs are in pixels and do not move with the interface text setting. An inline icon does move with it, because it inherits. 12px is also the caption type step, so a marker glyph sits at the size of caption text.

There is no rung between 12 and 32, and no class that names one. A glyph that fits neither, such as the one centred in the 48px circle on an onboarding card, is measured against the shape around it.

The two sizes ship as --icon-marker and --icon-message. Each class is a utility declared from its variable in the app stylesheet, so a surface wiring its own stylesheet declares them again or the class name resolves to nothing.

Prefixes ​

PrefixUsed for
fasThe solid weight. Everything but the two cases below
farThe regular weight. One place only: the entry that clears a row highlight, so its hollow circle reads as unfilled beside the solid circles that carry a colour
fa-brandsBrand marks, which are a different family rather than a different weight

Only the glyph name is rewritten. Every alias is keyed on a glyph name, so a prefix and any other class on the icon reach the stylesheet exactly as written.

Glyph names ​

Sixty older glyph names resolve to their current ones automatically, so a name that moved upstream, and a second spelling of one that did not, both still render. The resolution happens inside the component, so it applies to the icon prop and not to a class written directly on an element.

The component ​

PropTypeMeaning
iconstringThe glyph, such as fas fa-bug
labelstring, optionalThe accessible name. Pass it only when the icon stands alone
sizemarker or message, optionalFor a glyph with no text to inherit from

What the component does with label:

labelResult
Passedrole="img" and an accessible name
Omittedaria-hidden, so the icon is skipped by assistive technology

An icon-only control ​

NeedsWhy
An accessible nameWithout it the control does not exist for a screen reader
A tooltipWithout it a sighted person cannot learn what the glyph means
A pointer target of at least 24 by 24 CSS pixelsNothing checks it, so it needs checking

A tooltip does not provide an accessible name. The tooltip directive names its own container and sets nothing on the control but a data attribute.

The vocabulary ​

The glyphs the interface has settled on, grouped by the job they do. Reuse one of these before reaching for a new glyph, because a second drawing of a meaning that already exists is drift.

Acting on something ​

  • fa-plus
  • fa-minus
  • fa-trash
  • fa-copy
  • fa-paste
  • fa-pencil
  • fa-pen-to-square
  • fa-floppy-disk
  • fa-download
  • fa-file-import
  • fa-rotate-left
  • fa-arrows-rotate
  • fa-paper-plane
  • fa-play
  • fa-pause
  • fa-check
  • fa-xmark

Saying how something went ​

  • fa-circle-check
  • fa-circle-xmark
  • fa-triangle-exclamation
  • fa-circle-info
  • fa-circle-question
  • fa-spinner
  • fa-lock
  • fa-circle

Moving and arranging ​

  • fa-chevron-right
  • fa-chevron-down
  • fa-chevron-left
  • fa-caret-down
  • fa-arrow-right
  • fa-arrow-left
  • fa-arrow-up
  • fa-arrow-down
  • fa-arrow-right-arrow-left
  • fa-up-right-from-square
  • fa-ellipsis
  • fa-grip-vertical
  • fa-layer-group

Things in Caido ​

  • fa-bug
  • fa-sitemap
  • fa-puzzle-piece
  • fa-globe
  • fa-folder
  • fa-folder-open
  • fa-file
  • fa-file-lines
  • fa-magnifying-glass
  • fa-filter
  • fa-gear
  • fa-sliders
  • fa-user
  • fa-eye
  • fa-eye-slash
  • fa-hard-drive
  • fa-code
  • fa-bolt-lightning
  • fa-inbox
  • fa-bookmark
  • fa-comments
  • fa-book
  • fa-medal
  • fa-rocket

Those cover most of what the interface draws. The full set is Font Awesome Free solid, so a meaning that genuinely has no glyph here can take one from there, as long as it is not a second drawing of something above.

What not to write ​

AvoidInstead
A size on an icon beside textNothing. It inherits
A size between the two rungsOne of the two rungs
A glyph written as a class on a controlThe component's icon prop, so resolution and labelling apply
A second glyph for a meaning that already has oneThe glyph that meaning already uses