import { ComponentPropsWithoutRef, ElementType, ReactNode, Ref } from 'react'; import { Color } from '../types.js'; import { SurfaceVariant } from './Surface.js'; export type ShortcutSize = '2xs' | 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '2xl'; interface ShortcutOwnProps { /** Extra classes for the shortcut root container. */ className?: string; /** Extra classes for keyboard icon glyphs (cmd, shift, arrows, etc.). */ iconClassName?: string; /** Render an outline ring on each key surface. Default `true`. */ outline?: boolean; /** Surface variant for each key. Default `'gradient'`. */ variant?: SurfaceVariant; /** Extra classes for each individual key surface. */ keyClassName?: string; /** Extra classes for the inner content of each key. */ keyContentClassName?: string; /** * Surface level for each key. Default `'+2'`. * * Accepts the same absolute / relative (`"+1"`/`"-1"`) syntax as `Surface.level`. */ surfaceLevel?: string | number; /** Accent color token applied to each key surface. */ color?: Color; /** * Shortcut content. Strings are split on whitespace into individual keys. * * Recognized tokens (`cmd`, `ctrl`, `alt`, `shift`, `enter`, `tab`, `space`, `up`, `down`, `left`, `right`, `backspace`, `delete`, `esc`, etc.) render as glyphs - others render as uppercase text. * * Non-string children are rendered as-is in their own key. */ children?: ReactNode; /** Key dimension. Default `'md'`. Drives height, font size, icon size, and corner radius. */ size?: ShortcutSize; /** * Polymorphic root element. Defaults to `'div'`. Use `'span'` when rendering inline (e.g. inside a `

`) to keep valid HTML. */ as?: C; /** Forwarded to the polymorphic root element. */ ref?: Ref; } export type ShortcutProps = ShortcutOwnProps & Omit, keyof ShortcutOwnProps>; /** Shape of `Shortcut` defaults that can be supplied via `CladdProvider`'s `defaults` prop. */ export type ShortcutDefaultProps = Partial>; export declare const Shortcut: (props: ShortcutProps) => import("react/jsx-runtime").JSX.Element; export {}; //# sourceMappingURL=Shortcut.d.ts.map