@remotion/renderer 4.0.380 → 4.0.382
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/browser/BrowserPage.d.ts +1 -0
- package/dist/browser/BrowserPage.js +12 -0
- package/dist/browser/devtools-commands.d.ts +14 -0
- package/dist/client.d.ts +15 -0
- package/dist/esm/client.mjs +382 -337
- package/dist/esm/index.mjs +41 -13
- package/dist/get-compositions.js +4 -1
- package/dist/make-page.d.ts +2 -1
- package/dist/make-page.js +2 -1
- package/dist/open-browser.d.ts +1 -0
- package/dist/options/dark-mode.d.ts +15 -0
- package/dist/options/dark-mode.js +36 -0
- package/dist/options/index.d.ts +15 -0
- package/dist/options/index.js +2 -0
- package/dist/render-frames.js +4 -1
- package/dist/render-still.js +2 -0
- package/dist/select-composition.js +3 -1
- package/dist/set-props-and-env.d.ts +1 -0
- package/dist/set-props-and-env.js +5 -1
- package/package.json +15 -15
|
@@ -94,6 +94,7 @@ export declare class Page extends EventEmitter {
|
|
|
94
94
|
};
|
|
95
95
|
}): Promise<HTTPResponse | null>;
|
|
96
96
|
bringToFront(): Promise<void>;
|
|
97
|
+
setAutoDarkModeOverride(): Promise<void>;
|
|
97
98
|
evaluate<T extends EvaluateFn>(pageFunction: T, ...args: SerializableOrJSHandle[]): Promise<UnwrapPromiseLike<EvaluateFnReturnType<T>>>;
|
|
98
99
|
evaluateOnNewDocument(pageFunction: Function | string, ...args: unknown[]): Promise<void>;
|
|
99
100
|
close(options?: {
|
|
@@ -288,6 +288,18 @@ class Page extends EventEmitter_1.EventEmitter {
|
|
|
288
288
|
async bringToFront() {
|
|
289
289
|
await __classPrivateFieldGet(this, _Page_client, "f").send('Page.bringToFront');
|
|
290
290
|
}
|
|
291
|
+
async setAutoDarkModeOverride() {
|
|
292
|
+
const result = await __classPrivateFieldGet(this, _Page_client, "f").send('Emulation.setEmulatedMedia', {
|
|
293
|
+
media: 'screen',
|
|
294
|
+
features: [
|
|
295
|
+
{
|
|
296
|
+
name: 'prefers-color-scheme',
|
|
297
|
+
value: 'dark',
|
|
298
|
+
},
|
|
299
|
+
],
|
|
300
|
+
});
|
|
301
|
+
console.log(result);
|
|
302
|
+
}
|
|
291
303
|
evaluate(pageFunction, ...args) {
|
|
292
304
|
return __classPrivateFieldGet(this, _Page_frameManager, "f").mainFrame().evaluate(pageFunction, ...args);
|
|
293
305
|
}
|
|
@@ -255,6 +255,20 @@ export interface Commands {
|
|
|
255
255
|
paramsType: [];
|
|
256
256
|
returnType: void;
|
|
257
257
|
};
|
|
258
|
+
'Emulation.setEmulatedMedia': {
|
|
259
|
+
paramsType: [
|
|
260
|
+
{
|
|
261
|
+
media: 'screen';
|
|
262
|
+
features: [
|
|
263
|
+
{
|
|
264
|
+
name: 'prefers-color-scheme';
|
|
265
|
+
value: 'dark';
|
|
266
|
+
}
|
|
267
|
+
];
|
|
268
|
+
}
|
|
269
|
+
];
|
|
270
|
+
returnType: void;
|
|
271
|
+
};
|
|
258
272
|
'Emulation.setDeviceMetricsOverride': {
|
|
259
273
|
paramsType: [SetDeviceMetricsOverrideRequest];
|
|
260
274
|
returnType: void;
|
package/dist/client.d.ts
CHANGED
|
@@ -965,6 +965,21 @@ export declare const BrowserSafeApis: {
|
|
|
965
965
|
};
|
|
966
966
|
setConfig: (size: number | null) => void;
|
|
967
967
|
};
|
|
968
|
+
darkModeOption: {
|
|
969
|
+
name: string;
|
|
970
|
+
cliFlag: "dark-mode";
|
|
971
|
+
description: () => import("react/jsx-runtime").JSX.Element;
|
|
972
|
+
ssrName: string;
|
|
973
|
+
docLink: string;
|
|
974
|
+
type: boolean;
|
|
975
|
+
getValue: ({ commandLine }: {
|
|
976
|
+
commandLine: Record<string, unknown>;
|
|
977
|
+
}) => {
|
|
978
|
+
source: string;
|
|
979
|
+
value: boolean;
|
|
980
|
+
};
|
|
981
|
+
setConfig: (value: boolean) => void;
|
|
982
|
+
};
|
|
968
983
|
};
|
|
969
984
|
validColorSpaces: readonly ["default", "bt709", "bt2020-ncl"];
|
|
970
985
|
optionsMap: {
|