UI LibraryUI Library
Guide
Components
Styling
Repo
Guide
Components
Styling
Repo
  • Guide

    • Introduction
    • Getting Started
  • Components

    • CataUiAccordion
    • CataUiAccordionItem
    • CataUiAlert
    • CataUiAnchorMenu
    • CataUiBadge
    • CataUiButton
    • CataUiCollapse
    • CataUiDraggable
    • CataUiDropdown
    • CataUiDropover
    • CataUiFileTree
    • CataUiIcon
    • CataUiIconSwitch
    • CataUiInput
    • CataUiInputCheckbox
    • CataUiInputColor
    • CataUiInputDate
    • CataUiInputGroup
    • CataUiInputRadio
    • CataUiInputSearch
    • CataUiInputSelect
    • CataUiMasonry
    • CataUiMasonryTile
    • CataUiLogo
    • CataUiModal
    • CataUiPaginate
    • CataUiProgress
    • CataUiSpinner
    • CataUiStatusLabel
    • CataUiSwitch
    • CataUiTable
    • CataUiTableAG
    • CataUiTableFooter
    • CataUiTabs
    • CataUiTabSwitch
    • CataUiTooltip
  • Styling

    • Colors
    • Icons
    • Typography
    • Utils

CataUiBadge

A lightweight, versatile badge component that can display labels with optional icons and close buttons. Badges are useful for highlighting statuses, categories, tags, or displaying metadata in a compact format.

UserRoleFilter
<!-- Basic badge -->
<CataUiBadge label="Role" />

<!-- Badge with an icon -->
<CataUiBadge label="User" icon="bi-person-fill" />

<!-- Badge with custom color -->
<CataUiBadge label="Custom" color="255, 0, 0" />

<!-- Closeable badge -->
<CataUiBadge label="Filter" closeable @close="handleClose" />

<!-- Badge with all properties -->
<CataUiBadge label="Complete" icon="bi-check-circle" color="0, 140, 171" closeable />

Props

PropDescriptionTypeDefaultRequired
closeableWhen true, displays a close button that emits a 'close' event when clickedBooleanfalsefalse
colorRGB color value used for the border and background (e.g. '0, 140, 171')String'var(--color-primary-100-rgb)'false
iconBootstrap icon class with bi- prefix (see Icons)String''false
labelText content displayed within the badgeString''false

Emits

EmitDescription
closeTriggered when the close button is clicked (only when closeable=true)
Prev
CataUiAnchorMenu
Next
CataUiButton