import { type Dispatch, type RefObject, type SetStateAction } from 'react'; interface UseBreakpointCollapseArgs { /** Controlled / uncontrolled props for the collapsed state. */ collapsed: { value: boolean | undefined; defaultValue: boolean; onChange: ((value: boolean) => void) | undefined; }; /** Container width below which the panel renders as a drawer. */ breakpoint: number; /** Container element observed for size changes. */ containerRef: RefObject; /** * Fired on the first measurement and whenever the below-breakpoint state * changes afterwards, whether from a resize or a new `breakpoint`. */ onBreakpointTransition?: (belowBreakpoint: boolean) => void; /** * When `true`, an *uncontrolled* panel auto-collapses below the breakpoint * and reopens above it (the Sidebar's responsive default). Details passes * `false`: it never auto-collapses and honors `defaultCollapsed` everywhere. */ autoCollapse: boolean; } interface UseBreakpointCollapseResult { /** Most recent measured container width (`0` until first measurement). */ containerWidth: number; /** Current collapsed state (controlled value if provided). */ collapsed: boolean; /** Setter for the collapsed state. */ setCollapsed: Dispatch>; /** True once measured and the container is narrower than `breakpoint`. */ isBelowBreakpoint: boolean; } /** * Tracks the container width and owns the breakpoint side derived from it. The * breakpoint half of `usePanelState`. `onBreakpointTransition` fires on the * first measurement and on every subsequent change of side, from a resize or * from a new `breakpoint` alike. A change of side never touches a controlled * `collapsed`; with `autoCollapse` (the Sidebar) an uncontrolled panel * additionally auto-collapses below the breakpoint and reopens above it. * * @internal */ export declare function useBreakpointCollapse({ collapsed: collapsedProps, breakpoint, containerRef, onBreakpointTransition, autoCollapse, }: UseBreakpointCollapseArgs): UseBreakpointCollapseResult; export {}; //# sourceMappingURL=useBreakpointCollapse.d.ts.map