Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(colorScheme): make light scheme default on all browsers #1668

Merged
merged 1 commit into from
Apr 7, 2020

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
@@ -215,6 +215,7 @@ Indicates that the browser is connected.
- `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
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