bpk-component-badge

6.0.1 • Public • Published

bpk-component-badge

Backpack badge component.

Installation

npm install bpk-component-badge --save-dev

Usage

import React from 'react';
import BpkBadge, { BADGE_TYPES } from 'bpk-component-badge';

export default () => (
  <BpkBadge
    type={BADGE_TYPES.warning}
  >
    My Badge
  </BpkBadge>
);

Props

Property PropType Required Default Value
centered bool false null
className string false null
docked oneOf('left', 'right') false null
type oneOf(BADGE_TYPES.warning, BADGE_TYPES.success, BADGE_TYPES.destructive, BADGE_TYPES.light, BADGE_TYPES.inverse, BADGE_TYPES.outline, BADGE_TYPES.strong) false BADGE_TYPES.warning

Theme props

  • badgeBackgroundColor
  • badgeSuccessBackgroundColor
  • badgeDestructiveBackgroundColor

Readme

Keywords

none

Package Sidebar

Install

npm i bpk-component-badge

Weekly Downloads

267

Version

6.0.1

License

Apache-2.0

Unpacked Size

28.9 kB

Total Files

12

Last publish

Collaborators

  • mungodewar
  • anambl
  • skyscanner-koalasquad
  • gert-jan.vercauteren
  • frugoman
  • marianeumayer-skyscanner
  • ojcurt
  • mattface