import { type ButtonHTMLAttributes } from 'react'; import { type VariantProps } from 'class-variance-authority'; declare const buttonVariants: (props?: ({ intent?: "link" | "primary" | "secondary" | "outline" | "ghost" | "destructive" | "destructiveOutline" | "tonal" | "soft" | null | undefined; size?: "sm" | "md" | "lg" | null | undefined; hideLabel?: boolean | null | undefined; background?: "transparent" | "surface" | null | undefined; } & import("class-variance-authority/types").ClassProp) | undefined) => string; export interface ButtonProps extends ButtonHTMLAttributes, VariantProps { /** * Native button type. Defaults to `'button'` (since 1.51.0), so a kit * Button never submits a surrounding `
` by accident. Pass * `type="submit"` for a form's submit action (or `"reset"`). With * `asChild` no default is added: the slotted child keeps its own `type`. */ type?: 'button' | 'submit' | 'reset'; asChild?: boolean; /** * Shows a spinner and ignores activation, without taking the button * out of the tab order: keyboard focus stays on it. It is marked * `aria-busy` and `aria-disabled`; a submit button does not send its * form and a link does not navigate. Changed in 1.72.0: before, it set * native `disabled`, which dropped focus to the page. */ loading?: boolean; startIcon?: React.ReactNode; endIcon?: React.ReactNode; /** * Mirror directional icons (arrows, chevrons) horizontally when the * interface renders in RTL. Default `false` — most icons (trash, calendar, * plus) must NOT flip. Opt in per call-site for arrow / chevron glyphs. */ flipIconInRtl?: boolean; /** * Visually hide the label, leaving the icon(s) and a square footprint. * The children stay in the DOM screen-reader-only, so the accessible * name is preserved. With `asChild` the slotted element's own children * become the hidden label, so a link folds to its icon too. */ hideLabel?: boolean; /** * Backing paint behind `intent="outline"` / `"destructiveOutline"`. * `'transparent'` (default) shows the surface behind the button — * correct on toolbars and tinted shells (app header, coloured bars). * `'surface'` paints `--background` behind the outline — for host * pages and split-button segments where a see-through outline reads * grey on grey. Ignored by the other intents. */ background?: 'transparent' | 'surface'; } /** * The kit's text action. Renders a native `