import { type PanelWidth } from './width-utils.js'; /** * Flex space the resize handle track takes from the panel and the content. * Under visual refresh the handle cancels its own width with a negative * margin, so the variable reports 0 there. Reading it from the document * element is synchronous and works before the handle element mounts, so the * first render already sizes against the right value. * * @internal */ export declare function resolveHandleWidth(resizable: boolean): number; /** * Everything a panel and its sibling content are allowed to be. The handle * track is deliberately absent: it is resolved by `resolvePanelSizing`, so no * caller can size against a handle width of its own. * * @internal */ export interface PanelSizingConstraints { minWidth: PanelWidth; maxWidth: PanelWidth; /** Width the sibling content keeps for itself. */ reservedMin: PanelWidth; /** A panel without a resize handle has no handle track to pay for. */ resizable: boolean; } /** * The width a panel asks for, in order of precedence. All three are optional * because a drag asks for a bare pixel value. * * @internal */ export interface PanelSizingRequest { /** Width the consumer controls. */ controlledWidth?: PanelWidth; /** Width the user last dragged to, in px. */ draggedWidth?: number; /** Declared width, used until the panel is controlled or dragged. */ defaultWidth?: PanelWidth; } /** @internal */ export interface PanelSizingValues { /** Resolved width in px. Also what the separator reports as its value. */ width: number; widthCss: string; /** Smallest width the panel may take, in px. */ minPx: number; /** Largest width the panel may take, in px. Never below `minPx`. */ maxPx: number; } /** @internal */ export interface PanelSizing { panel: PanelSizingValues; /** * The sibling content is only painted. Its `aria-controls` names the panel, * so a resize separator reports the panel's bounds, never the content's. */ content: { widthCss: string; }; } /** * Resolves the geometry of one panel and its sibling content: the width the * panel gets, the CSS both columns are painted with, and the bounds the resize * separator reports for the panel it controls. * * This is the only place the handle track width, the requested width and the * clamp are composed. Callers own the declared inputs and the drag gesture, * never the arithmetic, so a width cannot be clamped twice against two * different handle tracks (APPDEV-19606). * * @internal */ export declare function resolvePanelSizing(request: PanelSizingRequest, containerWidth: number, constraints: PanelSizingConstraints): PanelSizing; //# sourceMappingURL=panel-sizing.d.ts.map