Badges

Use it for a number of functions, but mostly to demonstrate status and progress to the customer.

Basically it is positioned in a context with a text.


Versions#

  • There are different versions of the badge: standard and addon.
StandardAddon
Use it in conjunction with text.Used in the user-navigation of the header.

Recommendations#

  • If you decide to use a badge, never use more than a maximum of 2 variations.
  • Keep the text in a badge as short as possible.

Overall styling#

  • The text-style or font-size depends on the selected component size.
  • The line-height is 120%.
  • The text-color always is basic-white.
  • The border is in basic-white with a 1px thickness.
  • It always has rounded corners of 50% of its height.

Standard#

  • This badge is called standard and should be used in conjunction with text.
  • It comes in different sizes depending of the corresponding text-styles.
  • Please use the badge corresponding to the breakpoint since there are different sizes.
  • The badge these colored variations: primary and info.
TypesAttributesPreview
Primarytext-style: small, basic, large
background-color: brand-primary-base
 primary: LG
Infotext-style: small, basic, large
background-color: info-base
info: LG

States#

  • A badge can also be given as a link.
  • The only thing that changes is the background-color.
TypesAttributesPreview
Defaultbackground-color: brand-primary-base, info-basestate: default
Hover / focus and activebackground-color: brand-secondary-base, info-darkerstate: hover

Addon#

  • This badge is called addon and is only used in the user-navigation section of the header.
  • It comes in 3 different sizes depending on the breakpoints.
BreakpointsAttributesPreview
LGfont-size: 12px
line-height: 100%
background-color: brand-primary-base
pill: LG
MD-XSfont-size: 10px
line-height: 100%
background-color: brand-primary-base
pill: MD-XS

Usage#

  • Stick to the following examples to implement a badge-standard in combination with a text.

Headlines#

Text styleAttributes Preview
Headline 1text-style: headline 1
badge: large
example: headline 1
Headline 2text-style: headline 2
badge: basic
example: headline 3
Headline 3text-style: headline 3
badge: basic
example: headline 3
Headline 4text-style: headline 4
badge: basic
example: headline 4
Headline 5text-style: headline 5
badge: small
example: headline 5

Text#

Text styleAttributes Preview
Smalltext-style: small(-bold)
badge: small
example: headline 1
Basictext-style: basic(-bold)
badge: basic
example: headline 1
Largetext-style: large(-bold)
badge: large
example: headline 1

Spacing & measurements#

  • Note that the badge element has a 1px basic-white border.

Standard#

TypesAttributes Preview
Horizontal spacingpadding: 16pxhorizontal-spacing
Vertical spacingtext optically, vertically centered
LG-XS padding: 4px
vertical-spacing
Distancesmargin: 8pxdistance

Addon#

TypesAttributes Preview
Horizontal spacingpadding: 4pxhorizontal-spacing
HeightLG: 20px
MD-XS: 16px
vertical-spacing
PositionOverlaps an icon by 50% to the right
Text expands the element to the left
position

What can be modified?#

  • Override the text.
  • Adjust the width according to the text.
  • Modify badges to your project needs by changing colors of background, outline and text.

Change following#

Changed#

  • Doc: "Badge" | Clean up the documentation for the right structure and sentence case
  • Doc: "Badge" | Changed vertical spacing method

Fixed#

  • Doc: "Badge" | Fixed links for small, basic and large text styles

Changed#

  • "Badge" | Changed symbols: with layer-style settings

Added#

  • "Badge" | Added description: height