import { type Insets, type LayoutChangeEvent, type LayoutRectangle } from "react-native"; import { type Slop } from "./touch-seam.js"; /** * The slop a clipping node of `size` must carry so each child keeps its own: per side, the * furthest any child's slop rectangle reaches past the node's edge. `frame` is the child's * layout inside the node (onLayout's x and y are measured from the node's own corner). A * child not yet measured adds nothing. Undefined when no slop reaches past. */ export declare function clipSlop(size: { width: number; height: number; } | undefined, children: ReadonlyArray<{ frame: LayoutRectangle | undefined; slop: Slop; }>): Insets | undefined; /** * The slop a child at `frame` inside a node of `size` needs to reach `outer` past the node's * edges, the inverse of clipSlop: a child that answers for its parent's whole touch target * (the tappable body of a removable Chip, reaching the pill's minimum). Physical sides, with * `frame` measured from the node's own corner as onLayout reports it. */ export declare function reachSlop(size: { width: number; height: number; }, frame: LayoutRectangle, outer: Slop): Insets; /** * Measure a clipping node and the slop-bearing pressables directly inside it, and return * the slop the node must carry. `enabled` is whether anything is measured (a node that does * not clip cuts nothing, so it needs no measurement unless a child reaches its target). Spread * `measure()` on the node and `measure(key)` on each pressable, then pass * `slop({ key: theirSlop })` as the node's hitSlop; `frame(key)` is a measured frame (the * node's own without a key), undefined until its first layout. */ export declare function useClipSlop(enabled: boolean): { measure: (key?: string) => { onLayout?: (event: LayoutChangeEvent) => void; }; slop: (children: Record) => Insets | undefined; frame: (key?: string) => LayoutRectangle | undefined; }; //# sourceMappingURL=clip-slop.d.ts.map