import { ClassValue, StyledComponentProps, ThemeAlign, ThemeSide } from "../../types/shared.js"; import { TooltipSlots } from "./tooltip-variants.js"; import { TooltipArrowProps, TooltipContentProps, TooltipProps } from "@radix-ui/react-tooltip"; //#region src/components/tooltip/types.d.ts /** * Class names for different slots in the tooltip component. * Allows customizing styles for specific parts (content, arrow, etc.). * * @example * ```tsx * const classNames: TooltipClassNames = { * content: 'custom-tooltip-content', * arrow: 'custom-arrow' * } * ``` */ type TooltipClassNames = Partial>; /** * Props for the tooltip content element. * The container element that displays the tooltip message. */ interface TooltipContentProps$1 extends StyledComponentProps {} /** * Props for the tooltip arrow element. * The small triangular pointer that points to the trigger element. */ interface TooltipArrowProps$1 extends StyledComponentProps {} /** * Props for the Tooltip component. * Provides contextual information when users hover over or focus on an element. * Wraps the trigger element and displays a floating tooltip message. * * @example * ```tsx * * * * ``` */ interface TooltipProps$1 extends StyledComponentProps { /** * Class names for customizing different slots of the tooltip component. */ classNames?: TooltipClassNames; /** * The content to display inside the tooltip. * Can be text, JSX elements, or any React node. */ content: React.ReactNode; /** * Additional props to pass to the tooltip content element. * Useful for customizing positioning, delays, and other behavior. * Note: `children` and `className` are not allowed as they are managed by the component. */ contentProps?: Omit; /** * Whether to display an arrow pointing to the trigger element. * When true, a small triangular pointer is shown at the edge of the tooltip. * Defaults to false. */ showArrow?: boolean; } /** * The side of the trigger element where the tooltip should appear. * Controls the preferred placement direction for the tooltip. * * Possible values include: 'top', 'right', 'bottom', 'left' */ type TooltipSide = ThemeSide; /** * The alignment of the tooltip relative to the trigger element. * Controls how the tooltip is aligned when placed on a side. * * Possible values include: 'start', 'center', 'end' */ type TooltipAlign = ThemeAlign; //#endregion export { TooltipAlign, TooltipArrowProps$1 as TooltipArrowProps, TooltipClassNames, TooltipContentProps$1 as TooltipContentProps, TooltipProps$1 as TooltipProps, TooltipSide };