mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-16 05:51:55 +00:00
LibWeb/CSS: Correct our scan
media-feature
Despite what the spec suggests, modern displays are not progressive, and WPT expects `@media (scan: progressive)` to fail. So, return `none` here to accurately represent that. I've left a FIXME in case we can detect the display type from the OS somehow in the future. Gets us 4 WPT subtest passes.
This commit is contained in:
parent
9fe8445946
commit
00617884a6
Notes:
github-actions[bot]
2025-05-23 09:19:05 +00:00
Author: https://github.com/AtkinsSJ
Commit: 00617884a6
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4817
2 changed files with 8 additions and 7 deletions
|
@ -406,7 +406,8 @@ Optional<CSS::MediaFeatureValue> Window::query_media_feature(CSS::MediaFeatureID
|
|||
case CSS::MediaFeatureID::Resolution:
|
||||
return CSS::MediaFeatureValue(CSS::Resolution(device_pixel_ratio(), CSS::Resolution::Type::Dppx));
|
||||
case CSS::MediaFeatureID::Scan:
|
||||
return CSS::MediaFeatureValue(CSS::Keyword::Progressive);
|
||||
// FIXME: Detect this from the display, if we can. Most displays aren't scanning and should return None.
|
||||
return CSS::MediaFeatureValue(CSS::Keyword::None);
|
||||
case CSS::MediaFeatureID::Scripting:
|
||||
if (associated_document().is_scripting_enabled())
|
||||
return CSS::MediaFeatureValue(CSS::Keyword::Enabled);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue