UNPKG

436 BTypeScriptView Raw
1/**
2 * Simple utility for getting the bounds of the browser viewport.
3 * TODO: internal
4 */
5export declare class ViewportRuler {
6 /** Gets a ClientRect for the viewport's bounds. */
7 getViewportRect(): ClientRect;
8 /**
9 * Gets the (top, left) scroll position of the viewport.
10 * @param documentRect
11 */
12 getViewportScrollPosition(documentRect?: ClientRect): {
13 top: number;
14 left: number;
15 };
16}