import type { DrawerSnapPoint } from './DrawerRootContext'; export interface ResolvedDrawerSnapPoint { value: DrawerSnapPoint; /** * How much of the popup is visible at this snap point, in pixels. */ height: number; /** * How far the popup is pushed off the edge at this snap point, in pixels. * This is what the consumer translates by. */ offset: number; } /** * Damps the swipe once the drag overshoots the fully-open edge (`nextOffset < 0`), * so the popup resists travelling past it instead of tearing off the screen. * Ported from upstream verbatim. */ export declare function getSnapPointSwipeMovement(baseOffset: number, movementValue: number): number; /** * Turns a snap point into a visible height: a number `<= 1` is a fraction of the * viewport, anything larger is a pixel value. * * **Diverges from upstream:** it accepts `'148px'`/`'30rem'` strings too. React * Native styles are unitless numbers and it has no root font size, so a string * form would have nothing to resolve against — zest takes numbers only. */ export declare function resolveSnapPointHeight(snapPoint: DrawerSnapPoint, viewportHeight: number): number | null; /** The index of the value closest to `target`, or `-1` when there are none. */ export declare function closestSnapPointIndex(values: number[], target: number): number; export declare function resolveSnapPoints(snapPoints: readonly DrawerSnapPoint[] | undefined, popupHeight: number, viewportHeight: number): ResolvedDrawerSnapPoint[]; /** * Resolves the drawer's snap points against the measured popup and the window. * * Upstream measures the viewport element and watches it with a `ResizeObserver`. * React Native has `useWindowDimensions`, which already re-renders on rotation — * and a drawer's Modal is full-screen (`statusBarTranslucent`), so the window * *is* the viewport. */ export declare function useDrawerSnapPoints(): { snapPoints: readonly number[] | undefined; snapToSequentialPoints: boolean; activeSnapPoint: number | null | undefined; setActiveSnapPoint: (snapPoint: DrawerSnapPoint | null, eventDetails: import("./DrawerRoot").DrawerRoot.SnapPointChangeEventDetails) => void; resolvedSnapPoints: ResolvedDrawerSnapPoint[]; activeSnapPointOffset: number | null; hasSnapPoints: boolean; }; //# sourceMappingURL=useDrawerSnapPoints.d.ts.map