import { ComponentPropsWithoutRef, MouseEvent } from 'react'; import { LayoutUtilProps } from '../Flex'; /** * Props for the Overflow component * @extends ComponentPropsWithoutRef<"div"> * @extends Omit */ export type OverflowProps = ComponentPropsWithoutRef<"div"> & Omit & { /** * The direction of the overflow container * @default column */ direction?: LayoutUtilProps["flexDirection"]; /** * The height of the overflow container * @remarks "inherit" is not supported when truncate is enabled */ height?: number | string | "inherit"; /** * The width of the overflow container */ width?: number | string; } & ({ /** * Whether to truncate content with expand/collapse functionality * @default false */ truncate?: false; } | { /** * Direction must be column when truncate is enabled */ direction: "column"; /** * Truncation configuration with expand/collapse functionality */ truncate: boolean | { /** * Text to display on the expand button * @default "Show more..." */ expandText?: string; /** * Text to display on the collapse button * @default "Show less..." */ collapseText?: string; /** * Callback fired when content is expanded */ onExpand?: (e: MouseEvent) => void; /** * Callback fired when content is collapsed */ onCollapse?: (e: MouseEvent) => void; }; }); /** * Overflow component for handling content that exceeds container boundaries. * * Features: * - Supports both horizontal and vertical overflow * - Automatic shadow indicators for scrollable content * - Truncation with expand/collapse functionality * - Keyboard navigation support for focusable elements * - Automatic height and width management * - Layout utility props support * - Resize observer for dynamic content changes * - Accessibility features with proper focus management * - Scroll event handling with shadow updates * * @example * * {items.map((item, i) => ( * * {item.content} * * ))} * */ export declare const Overflow: import('react').ForwardRefExoticComponent> & { /** * OverflowText component for text content with line truncation and expansion. * * Features: * - Configurable line limit with row-based truncation * - Expandable content with custom expand/collapse text * - Automatic height calculation and overflow detection * - Keyboard navigation support for focusable elements * - Resize observer for dynamic content changes * - Accessibility features with proper focus management * - Support for unlimited rows or specific row limits * - Callback support for expand/collapse events * * @example * * * This is a long text that will be truncated to 3 rows * and can be expanded to show the full content. * * */ Text: import('react').ForwardRefExoticComponent>; };