Skip to content

Badge ​

Simple badge component.

Usage ​

vue
<script setup>
import { Badge } from 'gurunkit';
</script>

<template>
  <Badge>Text</Badge>
</template>
Text

Color ​

Set badge color using color props. Supported values: primary, light, error, warning, success.

It's also supports dark mode, enable it by adding dark class to html tag.

vue
<script setup>
import { Badge } from 'gurunkit';
</script>

<template>
  <Badge color="primary">Primary Badge</Badge>
  <Badge color="warning">Warning Badge</Badge>
  <Badge color="error">Error Badge</Badge>
  <Badge color="light">Light Badge</Badge>
  <Badge color="success">Success Badge</Badge>
</template>
Primary BadgeWarning BadgeError BadgeLight BadgeSuccess Badge

API ​

Props ​

NameTypeRequiredDefaultDescription
colorprimary, light, success, warning, error❌primaryBadge color

Released under the MIT License.