/** * Ref-counted scroll lock, scoped to a given `Document` (defaults to the * caller's own top-level `document`) so it also works for content rendered * inside an iframe or any other document the caller explicitly passes. * Compensates for the removed scrollbar's width with inline-end padding on * the root element, so locking scroll doesn't shift page content * horizontally the instant the scrollbar disappears — restored to its prior * value once the last outstanding lock releases. Safe when a lock is * acquired and released more than once concurrently (e.g. a fast * open/close/open sequence). */ export declare function lockScroll(doc?:Document):()=>void;