/** Viewport taken from https://github.com/puppeteer/puppeteer/blob/main/docs/api/puppeteer.viewport.md */ interface Viewport { /** * The page width in pixels. */ width: number; /** * The page height in pixels. */ height: number; /** * Specify device scale factor. * See {@link https://developer.mozilla.org/en-US/docs/Web/API/Window/devicePixelRatio | devicePixelRatio} for more info. * @defaultValue 1 */ deviceScaleFactor?: number; /** * Whether the `meta viewport` tag is taken into account. * @defaultValue false */ isMobile?: boolean; /** * Specifies if the viewport is in landscape mode. * @defaultValue false */ isLandscape?: boolean; /** * Specify if the viewport supports touch events. * @defaultValue false */ hasTouch?: boolean; } declare class Chromium { /** * Downloads or symlinks a custom font and returns its basename, patching the environment so that Chromium can find it. * If not running on AWS Lambda nor Google Cloud Functions, `null` is returned instead. */ static font(input: string): Promise; /** * Returns a list of additional Chromium flags recommended for serverless environments. * The canonical list of flags can be found on https://peter.sh/experiments/chromium-command-line-switches/. */ static get args(): string[]; /** * Returns sensible default viewport settings. */ static get defaultViewport(): Required; /** * Inflates the current version of Chromium and returns the path to the binary. * If not running on AWS Lambda nor Google Cloud Functions, `null` is returned instead. */ static executablePath(input?: string): Promise; /** * Returns a boolean indicating if we are running on AWS Lambda or Google Cloud Functions. * True is returned if the NODE_ENV is set to 'test' for easier integration testing. * False is returned if Serverless environment variables `IS_LOCAL` or `IS_OFFLINE` are set. */ static get headless(): boolean; } export = Chromium;