---
title: "ProseBadge"
description: "Версии, метки статуса и теги прямо в содержимом страницы."
canonical_url: "https://b24-ui.bx-shef.by/docs/typography/badge"
---
# ProseBadge

> Версии, метки статуса и теги прямо в содержимом страницы.

## Использование

Markdown в слоте по умолчанию компонента `badge` показывает [Badge](https://b24-ui.bx-shef.by/raw/docs/components/badge.md) в содержимом.

```vue
<template>
  <code />
  <template v-slot:code=>
  <pre className=language-mdc shiki shiki-themes material-theme-lighter material-theme material-theme-palenight code=::badge
  **v4.0.0**
     language=mdc meta= style=>
  <code __ignoreMap=>
  <span class=line>
  <span class=sMK4o>
  ::</span>
  <span class=swJcz>
  badge
  </span></span>
  <span class=line>
  <span class=sHepR>
  **</span>
  <span class=so75L>
  v4.0.0</span>
  <span class=sHepR>
  **
  </span></span>
  <span class=line>
  <span class=sMK4o>
    </span></span></code></pre></template>
</template>
```

## API

### Пропсы

```ts
/**
 * Props for the ProseProseBadge component
 */
interface ProseProseBadgeProps {
  /**
   * The element or component this component should render as.
   * @default 'span'
   */
  as?: any;
  label?: string | number | undefined;
  /**
   * @default 'air-primary'
   */
  color?: "air-primary" | "air-primary-success" | "air-primary-alert" | "air-primary-warning" | "air-primary-copilot" | "air-secondary" | "air-secondary-alert" | "air-secondary-accent" | "air-secondary-accent-1" | "air-secondary-accent-2" | "air-tertiary" | "air-selection";
  /**
   * If set to `true` the color is inverted.
   * Used for 'air-primary', 'air-primary-success', 'air-primary-alert', 'air-primary-copilot' and 'air-primary-warning' colors.
   * @default false
   */
  inverted?: boolean | undefined;
  /**
   * @default 'md'
   */
  size?: "xss" | "xs" | "sm" | "md" | "lg" | "xl" | undefined;
  /**
   * Render the badge with equal padding on all sides.
   */
  square?: boolean | undefined;
  /**
   * Shows 'underline' on hover
   * @default false
   */
  useLink?: boolean | undefined;
  /**
   * Shows a close cross on the right side, from the dictionary's `close`
   * role, so an `app.config` override reaches it.
   * @default false
   */
  useClose?: boolean | undefined;
  onCloseClick?: (event: MouseEvent): void | ((event: MouseEvent) => void)[] | undefined;
  b24ui?: { base?: SlotClass; wrapper?: SlotClass; label?: SlotClass; leadingIcon?: SlotClass; leadingAvatar?: SlotClass; leadingAvatarSize?: SlotClass; trailingIcon?: SlotClass; } | undefined;
  /**
   * Display an icon on the left side.
   */
  icon?: (props: HTMLAttributes & VNodeProps & {}, ctx: Omit<{ attrs: Attrs; slots: Readonly<InternalSlots>; emit: (event: string, ...args: any[]) => void; expose: <Exposed extends Record<string, any> = Record<...>>(exposed?: Exposed | undefined) => void; }, "expose">): any | undefined;
  /**
   * Display an avatar on the left side.
   */
  avatar?: AvatarProps | undefined;
  /**
   * When `true`, the icon will be displayed on the right side.
   */
  trailing?: boolean | undefined;
  /**
   * Display an icon on the right side.
   */
  trailingIcon?: (props: HTMLAttributes & VNodeProps & {}, ctx: Omit<{ attrs: Attrs; slots: Readonly<InternalSlots>; emit: (event: string, ...args: any[]) => void; expose: <Exposed extends Record<string, any> = Record<...>>(exposed?: Exposed | undefined) => void; }, "expose">): any | undefined;
}
```

### Слоты

```ts
/**
 * Slots for the ProseBadge component
 */
interface ProseBadgeSlots {
  leading(): any;
  default(): any;
  trailing(): any;
}
```

## Тема

```ts [app.config.ts]
export default defineAppConfig({
  b24ui: {
    prose: {}
  }
})
```

## Sitemap

See the full [sitemap](/sitemap.md) for all pages.
