import { View } from 'react-native'; /** * Shape produced by `measureInWindow` plus the derived values the * dropdown modal layout needs (top-vs-bottom extents, full-screen * flag). */ export interface TriggerPosition { /** True when the dropdown renders as a full-screen modal (landscape / `mode="modal"`). */ isFull: boolean; width: number; /** Y of the top of the open list relative to the screen. */ top: number; /** Y of the bottom of the open list relative to the screen. */ bottom: number; left: number; /** Measured height of the trigger itself. */ height: number; } /** * Encapsulates the trigger-measurement dance both Dropdown and * MultiSelect perform identically: * * - Maintains the `View` ref attached to the trigger. * - Re-measures via `measureInWindow` on demand (open, keyboard, * layout). * - Caches the measurement; drops it on close so reopening waits for * a fresh measurement before mounting the Modal (upstream #198, * #330, #298). * - Applies the `isInsideModal` statusBar offset adjustment * (upstream #362). * - Handles tablet / landscape / `mode="auto"` full-screen rules. * * @param mode - The current `mode` prop. * @param isInsideModal - Whether the dropdown is rendered inside an * RN ``. * @param visible - Whether the list is currently open. When this flips * to `false`, the cached position is dropped. */ export declare function useTriggerMeasurement(mode: 'default' | 'modal' | 'auto', isInsideModal: boolean, visible: boolean): { /** Ref to attach to the trigger's outer ``. */ ref: import("react").RefObject; /** Last measurement (undefined before the first measure or after close). */ position: TriggerPosition | undefined; /** Re-measure the trigger; the callback returned is stable across renders with the same `mode`/`isInsideModal`/orientation. */ measure: () => void; /** Current window width in dp. */ windowWidth: number; /** Current window height in dp. */ windowHeight: number; /** `'PORTRAIT' | 'LANDSCAPE'`. */ orientation: string; }; //# sourceMappingURL=useTriggerMeasurement.d.ts.map