UNPKG

@cerberus-design/react

Version:

The Cerberus Design React component library.

28 lines (27 loc) 865 B
import { IconButtonRootProps } from './primitives'; /** * This module contains the Icon Button component. * @module */ type NonClipboardIconButtonProps = { /** * The aria-label attribute for the icon button. */ ariaLabel: string; clipboard?: never; }; type ClipboardIconButtonProps = { ariaLabel?: never; /** * If true, the icon button is used as a clipboard trigger. * In this case, the aria-label defaults to "Copy to clipboard". */ clipboard: true; }; export type IconButtonProps = IconButtonRootProps & (NonClipboardIconButtonProps | ClipboardIconButtonProps); /** * A component that allows the user to perform actions using an icon * @see https://cerberus.digitalu.design/react/icon-button */ export declare function IconButton(props: IconButtonProps): import("react/jsx-runtime").JSX.Element; export {};