@antadesign/anta
    Preparing search index...

    Interface TagPropsUnreviewed

    Common props for JSX component wrappers.

    interface TagProps {
        label?: string;
        value?: string;
        tone?:
            | "neutral"
            | "brand"
            | "info"
            | "success"
            | "warning"
            | "critical"
            | string & {};
        priority?: "primary"
        | "secondary"
        | "tertiary";
        size?: "small" | "medium" | "large";
        allcaps?: boolean;
        interactive?: boolean;
        icon?: keyof IconShapes;
        iconTrailing?: keyof IconShapes;
        className?: string;
        style?: CSSProperties;
        children?: ReactNode;
        id?: string;
        title?: string;
        slot?: string;
        tabIndex?: number;
        key?: string | number | null;
        [key: `data-${string}`]: unknown;
        [key: `aria-${string}`]: unknown;
    }

    Hierarchy (View Summary)

    Indexable

    • [key: `data-${string}`]: unknown

      Any data-* attribute is forwarded to the rendered element.

    • [key: `aria-${string}`]: unknown

      Any aria-* attribute is forwarded to the rendered element.

    Index
    label?: string

    Displays a short status or a key before value. A label paired with a value uses a heavier weight; a label on its own uses the default weight.

    value?: string

    Displays the tag's value, such as a count, version, or duration. When space is limited, the value truncates before the label.

    tone?:
        | "neutral"
        | "brand"
        | "info"
        | "success"
        | "warning"
        | "critical"
        | string & {}

    Selects a semantic color. A CSS color defines a custom tone.

    neutral
    
    priority?: "primary" | "secondary" | "tertiary"

    Sets the emphasis: solid fill, subtle fill, or outline.

    secondary
    
    size?: "small" | "medium" | "large"

    Sets the tag's dimensions.

    medium
    
    allcaps?: boolean

    Displays the content in uppercase. The original text remains unchanged.

    interactive?: boolean

    Shows a pointer cursor and a stronger hover border when the whole tag is actionable. Pressing restores the resting border.

    icon?: keyof IconShapes

    Adds a decorative icon before the text.

    iconTrailing?: keyof IconShapes

    Adds a decorative icon after the text.

    className?: string

    Adds CSS classes to the root element and preserves its existing classes.

    style?: CSSProperties

    Inline CSS styles on the root element.

    children?: ReactNode

    Content to render in place of any default content.

    id?: string

    HTML id attribute.

    title?: string

    HTML title attribute, shown as a browser tooltip on hover.

    slot?: string

    Named slot in a parent web component, such as slot="header" in a <Dialog>.

    tabIndex?: number

    Tab order. Set to -1 to skip the element when tabbing.

    key?: string | number | null

    React/Preact reconciliation key when rendered inside a list. Consumed by the JSX runtime (not forwarded as a DOM attribute).