/** * Resize the browser and **wait until the page agrees**. * * `page.viewport()` resolves when the driver has asked for the * resize, not when the tester frame has been laid out at the new * size. On the first resize in a file that gap is real: the * assertion runs against the *previous* width, so a * horizontal-scroll test at 390px silently measures a 1440px page * and reports a number nobody can explain. It is a race, so it * fails intermittently — which is the worst possible property for * the one gate that says the shell does not scroll sideways. * * Polling `innerWidth`/`innerHeight` is the honest wait: they are the * same numbers the media queries and the layout resolved against, so * when they match, the thing under test really is at the size the * test claims. * * **Height counts too**, and it did not used to. A panel row's size * steps down under `(height <= 40rem)` (`usePanelItemSize`), so a test * that shrinks only the height would have raced the resize with * nothing to wait on and measured the tall rows about half the time. */ export declare const setViewport: ({ height, width, }: { height: number; width: number; }) => Promise; /** A phone in portrait — the width plex-channels scrolls at. */ export declare const PHONE: { height: number; width: number; }; export declare const DESKTOP: { height: number; width: number; }; /** * A window short enough to trip `usePanelItemSize`'s first step-down * (`height <= 40rem`, so 640px) and wide enough that nothing else * about the layout changes with it. */ export declare const SHORT_WINDOW: { height: number; width: number; }; //# sourceMappingURL=viewport.testHelpers.d.ts.map