import { type ReactNode } from 'react'; import type { AriaLabelingProps } from '../../core/types/a11y-props.js'; import type { BehaviorTrackingProps } from '../../core/types/behavior-tracking-props.js'; import type { DataTestId } from '../../core/types/data-props.js'; import type { MaskingProps } from '../../core/types/masking-props.js'; import type { StylingProps } from '../../core/types/styling-props.js'; import type { WithChildren } from '../../core/types/with-children.js'; /** * @public */ export interface ExpandableTextBaseProps extends WithChildren, StylingProps, DataTestId, MaskingProps, AriaLabelingProps, BehaviorTrackingProps { /** * Text shown for expanding the content. * @defaultValue 'Show more' */ expandLabel?: ReactNode; /** * Text shown for collapsing the content. * @defaultValue 'Show less' */ collapseLabel?: ReactNode; } /** * @public */ export interface ExpandableTextUncontrolledProps { /** * Determines whether or not the content is initially expanded in an uncontrolled scenario. * @defaultValue false */ defaultExpanded?: boolean; /** * Determines whether or not the content is expanded in a controlled scenario. */ expanded?: never; /** * Callback fired when the expanded attribute changes in a controlled scenario. */ onExpandChange?: never; } /** * @public */ export interface ExpandableTextControlledProps { /** * Determines whether or not the content is initially expanded in an uncontrolled scenario. */ defaultExpanded?: never; /** * Determines whether or not the content is expanded in a controlled scenario. */ expanded: boolean; /** * Callback fired when the expanded attribute changes in a controlled scenario. */ onExpandChange: (expanded: boolean) => void; } /** * Accepted properties for ExpandableText * @public */ export type ExpandableTextProps = ExpandableTextBaseProps & (ExpandableTextControlledProps | ExpandableTextUncontrolledProps); /** * The `ExpandableText` component provides expand and collapse functionality for inline text. * @public */ export declare const ExpandableText: (props: ExpandableTextProps & import("react").RefAttributes) => import("react").ReactElement | null;