Badge

Badges are small status descriptors for UI elements, used to convey concise information about an item or its status.

Design system docs

Examples Default badge
<dap-ds-badge>Default Badge</dap-ds-badge>
Badge types

Different types of badges for different statuses

<dap-ds-stack direction="row">
  <dap-ds-badge type="neutral">
      Neutral Badge
  </dap-ds-badge>
  <dap-ds-badge type="brand">
      Brand Badge
  </dap-ds-badge>
  <dap-ds-badge type="info">
      Info Badge
  </dap-ds-badge>
  <dap-ds-badge type="positive">
      Positive Badge
  </dap-ds-badge>
  <dap-ds-badge type="warning">
      Warning Badge
  </dap-ds-badge>
  <dap-ds-badge type="negative">
      Negative Badge
  </dap-ds-badge>
</dap-ds-stack>
Badge sizes

Badges can be small or large

<dap-ds-stack direction="row">
  <dap-ds-badge size="sm">
      Small Badge
  </dap-ds-badge>
  <dap-ds-badge size="lg">
      Large Badge
  </dap-ds-badge>
</dap-ds-stack>
Importing
import { DapDSBadge } from 'dap-design-system/dist/dds'
Importing React
import { DapDSBadgeReact } from 'dap-design-system/dist/react'
Slots
NameDescription
(default)The content of the badge.
iconThe icon of the badge.
Attributes
PropertyTypeDefaultDescription
typeBadgeType'neutral'The type of the badge. Default is neutral. Can be neutral, brand, info, positive, warning, or negative.
sizeCommonSize'sm'The size of the badge. Default is sm. Can be sm or lg.
iconstring
Events

No custom events available.

CSS Parts

No CSS parts available.