Implement update media query from MQ4
Categories
(Core :: CSS Parsing and Computation, enhancement, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox102 | --- | fixed |
People
(Reporter: florian, Assigned: autumn)
References
(Blocks 1 open bug)
Details
(Keywords: dev-doc-complete)
Attachments
(1 file)
The update media query from Media queries level 4 let people tell apart media that responsively update the screen, from those that cannot, or those that can but only slowly. Authors can use that to style things differently on print vs ebook readers, even though both media are paginated. This kind of nuance was not possible to express just with @media print {...} The specification is over here: https://drafts.csswg.org/mediaqueries-4/#descdef-media-update This should be marked as blocking https://bugzilla.mozilla.org/show_bug.cgi?id=1312621
Updated•6 years ago
|
Updated•6 years ago
|
Updated•6 years ago
|
What's the sticking point for this feature? Deciding how to categorize platforms as "update: fast" and "update: slow"? Lack of interest?
If it's mostly a question of someone coming and writing the code (and docs? given the dev-doc-needed keyword), I'd be prepared to attempt it for my first contribution here.
Comment 2•2 years ago
|
||
(In reply to autumn from comment #1)
What's the sticking point for this feature? Deciding how to categorize platforms as "update: fast" and "update: slow"? Lack of interest?
We work on what we consider more prioritary. P3 means "in the backlog of work".
If it's mostly a question of someone coming and writing the code (and docs? given the dev-doc-needed keyword), I'd be prepared to attempt it for my first contribution here.
That'd be great! I'd be happy to review a patch for this feature. It should be straight-forward to add. You need to add an entry here:
and for that to work you need to add the feature name (update
) around here. Since this media query doesn't need dynamic change handling (presumably we want to match "none" for print documents, and "fast" elsewhere), the only missing piece would be to add tests.
You can extend layout/style/test/test_media_queries.html
for that, and maybe a print reftest like this in somewhere like testing/web-platform/tests/css/printing
:
<!doctype html>
<style>
div { background: red; width: 100px; height: 100px; }
@media (update: none) {
div { background: green; }
}
</style>
<div></div>
Updated•2 years ago
|
Pushed by ealvarez@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/25541cc29e47 implement 'update' media feature r=emilio
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/34065 for changes under testing/web-platform/tests
Comment 7•2 years ago
|
||
bugherder |
Upstream PR merged by moz-wptsync-bot
Updated docs are available here: https://developer.mozilla.org/en-US/docs/Web/CSS/@media/update-frequency
Doc issue tracker: https://github.com/mdn/content/issues/16148
Comment 10•1 year ago
|
||
Hi Dipika, https://developer.mozilla.org/en-US/docs/Web/CSS/@media/update-frequency shows "update" as experimental. I believe that's a mistake since it shipped in Fx102. Can you update the page? Thanks!
Comment 11•1 year ago
•
|
||
Thanks for pointing it out, Maire. I'll update the page.
Update: Sorry, I was a bit hasty in my previous response. That status as Experimental on the page is correct. The reason why it is marked experimental is because it is not supported on any other major browser. You can see from the Browser compatibility table that it is only supported in Firefox. And thats why it gets marked as "Experimental" on MDN
Comment 12•1 year ago
|
||
Clearing needinfo
Updated•1 year ago
|
Description
•