WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
147275
Web Inspector: device-pixel-ratio and orientation media queries are red in CodeMirror
https://bugs.webkit.org/show_bug.cgi?id=147275
Summary
Web Inspector: device-pixel-ratio and orientation media queries are red in Co...
Timothy Hatcher
Reported
2015-07-24 14:29:59 PDT
The following CSS has red syntax highlights for device-pixel-ratio and orientation. /* iPhone, iPhone 3G/3GS portrait */ @media only screen and (min-device-width: 320px) and (max-device-width: 480px) and (-webkit-device-pixel-ratio: 1) and (device-aspect-ratio: 2/3) and (orientation: portrait) { } /* iPhone, iPhone 3G/3GS landscape */ @media only screen and (min-device-width: 320px) and (max-device-width: 480px) and (-webkit-device-pixel-ratio: 1) and (device-aspect-ratio: 2/3) and (orientation: landscape) { }
Attachments
Screenshot
(91.22 KB, image/png)
2015-07-24 14:30 PDT
,
Timothy Hatcher
no flags
Details
View All
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2015-07-24 14:30:23 PDT
<
rdar://problem/21989475
>
Timothy Hatcher
Comment 2
2015-07-24 14:30:37 PDT
Created
attachment 257480
[details]
Screenshot
Joseph Pecoraro
Comment 3
2015-07-27 18:44:16 PDT
This seems like a CodeMirror insufficiency. CodeMirror's css.js includes a list of supported @media features: var mediaFeatures_ = [ "width", "min-width", "max-width", "height", "min-height", "max-height", "device-width", "min-device-width", "max-device-width", "device-height", ... ], mediaFeatures = keySet(mediaFeatures_); Even trunk doesn't have these. I think, for standard features like this we should propose CodeMirror update. I'll file a CodeMirror issue and see what other standard features we may want to propose.
Joseph Pecoraro
Comment 4
2015-07-27 19:28:29 PDT
Filed a CodeMirror issue:
https://github.com/codemirror/CodeMirror/issues/3417
Depending on what the CodeMirror developers want to put into main stream, we may need to add WebKit specific media query features like: "-webkit-video-playable-inline"
Joseph Pecoraro
Comment 5
2015-08-27 15:44:15 PDT
CodeMirror added common / legacy media-query features in:
https://github.com/codemirror/CodeMirror/commit/3ef42f71dc1a7c50ab73c39516a0563430eb11e3
We recently updated CodeMirror and that seems to have fixed this. We haven't customized to include support for new / vendor specific media query features that WebKit supports. We can file a new bug to track that. Note the CodeMirror issue page has some decent analysis about new media query features.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug