Skip to content

Conversation

pavelfeldman
Copy link
Member

@pavelfeldman pavelfeldman commented Apr 4, 2020

Fixes #1499

@pavelfeldman pavelfeldman force-pushed the colorScheme branch 2 times, most recently from f14c4f5 to 2ce745c Compare April 6, 2020 03:26
docs/api.md Outdated
- `httpCredentials` <[Object]> Credentials for [HTTP authentication](https://developer.mozilla.org/en-US/docs/Web/HTTP/Authentication).
- `username` <[string]>
- `password` <[string]>
- `colorScheme` <"dark"|"light"|"no-preference"> Emulates `'prefers-colors-scheme'` media feature, supported values are `'light'`, `'dark'`, `'no-preference'`. See [page.emulateMedia(options)](#pageemulatemediaoptions) for more details.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Defaults to light?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

it('should work in cross-process iframe', async({browser, server}) => {
const page = await browser.newPage({ colorScheme: 'dark' });
await page.goto(server.EMPTY_PAGE);
await
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

whoopsy

@pavelfeldman pavelfeldman merged commit 3dc14ed into microsoft:master Apr 7, 2020
@pavelfeldman pavelfeldman deleted the colorScheme branch April 17, 2020 21:12
debs-obrien pushed a commit to debs-obrien/playwright that referenced this pull request Jun 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Chromium headless doesn't have a default prefers-color-scheme

2 participants