Bug 311766
| Summary: | REGRESSION (310465@main): prefers-color-scheme in an iframe ignores system preference when the main page does not set a explicit color-scheme. | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Carlos Alberto Lopez Perez <clopez> |
| Component: | Layout and Rendering | Assignee: | Carlos Alberto Lopez Perez <clopez> |
| Status: | RESOLVED FIXED | ||
| Severity: | Normal | CC: | bfulgham, kiet.ho, simon.fraser, webkit-bug-importer, zalan |
| Priority: | P2 | Keywords: | InRadar |
| Version: | WebKit Nightly Build | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| See Also: |
https://bugs.webkit.org/show_bug.cgi?id=284973 https://bugs.webkit.org/show_bug.cgi?id=309611 https://bugs.webkit.org/show_bug.cgi?id=311812 |
||
Carlos Alberto Lopez Perez
310465@main changed prefersColorSchemeFeatureSchema so that subframes derive their prefers-color-scheme value from the CSS color-scheme property of their parent element.
However, it accidentally broke the case where the main page has no explicit color-scheme set.
This happens because 310465@main looks at the color-scheme property of the iframe and if finds nothing then looks at the one on the parent page page, but when that parent page has no explicit color-scheme, then the iframe tag has nothing to inherit, defaulting to to light instead to the defined system preference.
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Radar WebKit Bug Importer
<rdar://problem/174359110>
Carlos Alberto Lopez Perez
Pull request: https://github.com/WebKit/WebKit/pull/62312
EWS
Committed 310874@main (f89a7480911d): <https://commits.webkit.org/310874@main>
Reviewed commits have been landed. Closing PR #62312 and removing active labels.