Skip to content
API reference

components/badge

Import
import * as api from "@fungi.computer/caps/components/badge";
Kind Export Description
type alias BadgeTone Supported BadgeTone values.
type alias BadgeSize Supported BadgeSize values.
type alias BadgeVariant quiet is a soft tint with no outline, for labels that sit beside keys.
type alias BadgeProps Props accepted by Badge.
constant Badge A compact status or category label.

BadgeTonetype alias

Section titled “BadgeTone”
Signature
type BadgeTone =
| "neutral"
| "primary"
| "secondary"
| "accent"
| "success"
| "info"
| "warning"
| "error";

Supported BadgeTone values.


BadgeSizetype alias

Section titled “BadgeSize”
Signature
type BadgeSize = "sm" | "default" | "lg";

Supported BadgeSize values.


BadgeVarianttype alias

Section titled “BadgeVariant”
Signature
type BadgeVariant = "solid" | "quiet";

quiet is a soft tint with no outline, for labels that sit beside keys.


BadgePropstype alias

Section titled “BadgeProps”
Signature
type BadgeProps = object & HTMLAttributes<HTMLSpanElement>;

Props accepted by Badge.

Name Type
size? BadgeSize
variant? BadgeVariant
tone? BadgeTone

Badgeconstant

Section titled “Badge”
Signature
const Badge: ForwardRefExoticComponent<
object & HTMLAttributes<HTMLSpanElement> & RefAttributes<HTMLSpanElement>
>;

A compact status or category label.