Skip to content
Snippets Groups Projects
Commit b6d10e58 authored by Fred Chasen's avatar Fred Chasen
Browse files

Use emulateMediaType

parent 2a9850b3
No related branches found
No related tags found
1 merge request!34Emulate print media
Pipeline #35878 passed with stages
in 3 minutes and 36 seconds
...@@ -74,7 +74,7 @@ class Printer extends EventEmitter { ...@@ -74,7 +74,7 @@ class Printer extends EventEmitter {
const page = await this.browser.newPage(); const page = await this.browser.newPage();
page.setDefaultTimeout(this.timeout); page.setDefaultTimeout(this.timeout);
await page.emulateMedia(this.emulateMedia); await page.emulateMediaType(this.emulateMedia);
if (this.overrideDefaultBackgroundColor) { if (this.overrideDefaultBackgroundColor) {
page._client.send("Emulation.setDefaultBackgroundColorOverride", { color: this.overrideDefaultBackgroundColor }); page._client.send("Emulation.setDefaultBackgroundColorOverride", { color: this.overrideDefaultBackgroundColor });
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment