/** * @fileoverview Saasflare Badge — status indicator with intent support. * @module packages/ui/components/ui/badge * @layer core * * Fully owned Saasflare implementation. Does NOT import from ui/. * Supports intent system and optional hover animation with reduced-motion. * * @example * import { Badge } from "@saasflare/ui"; * * Default * Active * Error */ import * as React from "react"; import { type VariantProps } from "class-variance-authority"; import { type SaasflareComponentProps } from "../../providers"; import type { Intent } from "./button"; /** * Badge variant definitions. * * Axes: * variant — visual treatment: solid, soft, outline * size — sm, md */ declare const badgeVariants: (props?: ({ variant?: "outline" | "soft" | "solid" | null | undefined; size?: "sm" | "md" | null | undefined; } & import("class-variance-authority/types").ClassProp) | undefined) => string; /** Props for the Saasflare Badge component */ interface BadgeProps extends Omit, "onDrag" | "onDragStart" | "onDragEnd" | "onAnimationStart" | "onAnimationEnd" | keyof SaasflareComponentProps>, Omit, "variant">, SaasflareComponentProps { /** Render as child element (Radix Slot pattern) */ asChild?: boolean; /** Semantic color intent */ intent?: Intent; /** * Visual treatment: `"solid" | "soft" | "outline"`. * @remarks `"default" | "destructive" | "secondary"` are deprecated aliases * (mapped to a solid/soft variant + intent via {@link LEGACY_VARIANT_MAP}); * prefer `variant` + `intent` instead. */ variant?: VariantProps["variant"] | "default" | "destructive" | "secondary"; } /** * Badge for status, labels, and counts with intent-based coloring. * * @component * @layer core * * @param {string} variant - Visual treatment: "solid" | "soft" | "outline" * @param {string} intent - Color intent: "primary" | "neutral" | "success" | "warning" | "danger" | "info" * @param {string} size - Badge size: "sm" | "md" * @param {boolean} asChild - Render as child element (Slot pattern) * * @example * Active * * @example * Error * * @remarks * In `asChild` mode the badge renders via Radix Slot, which cannot receive * motion props — the hover-scale animation is intentionally a no-op there. */ declare function Badge({ className, variant: variantProp, size, intent: intentProp, asChild, surface, radius, animated, iconWeight, ...props }: BadgeProps): import("react/jsx-runtime").JSX.Element; export { Badge, badgeVariants, type BadgeProps };