Components

Badge

<Badge />

Component representing a badge.

Usage

import { Badge } from '@admin-bro/design-system'

const MyComponent = () => (
  <Badge>My badge</Badge>
)

Props

The Badge Component takes 3 custom props:

  • variant
  • outline
  • size

Apart from them you can also pass ColorProps, SpaceProps and TypographyProps. See BadgeProps below.

Examples

Check out the following examples.

  1. Mixed versions

  1. Outline

  1. Different sizes

  1. Color variants

  1. Mixed with other elements

See:

View Source admin-bro-design-system/src/atoms/badge/badge.tsx, line 43

Type Definitions

object

# BadgeProps

Prop Types of a Badge component. Apart from those defined below it extends all ColorProps, SpaceProps and TypographyProps

Usage

import { BadgeProps } from '@admin-bro/design-system'
Properties:
Name Type Attributes Description
... string <optional>

Other props from ColorProps, SpaceProps and TypographyProps

variant VariantType <optional>

Color variant

outline boolean <optional>

Outline version

size 'sm' | 'lg' | 'default' <optional>

Size variant

View Source admin-bro-design-system/src/atoms/badge/badge.tsx, line 73

SoftwareBrothers

Proudly built and maintained by SoftwareBrothers

Software House with a passion for both JavaScript and TypeScript.

See what we do See what we believe in

Proudly built and maintained by

SoftwareBrothers