Closed Bug 1116638 Opened 10 years ago Closed 6 years ago

expose logical property values on computed style objects

Categories

(Core :: CSS Parsing and Computation, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla63
Tracking Status
firefox63 --- fixed

People

(Reporter: heycam, Assigned: emilio)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

It probably makes sense to expose logical properties on computed style objects with values according to the direction/text-orientation/writing-mode on the same object. http://lists.w3.org/Archives/Public/www-style/2014Dec/0385.html
When we do this, we should be able to remove logical_box_prop_get_computed from property_database.js. This should have the happy side effect of testing the presence of CSS_PROPERTY_GETCS_NEEDS_LAYOUT_FLUSH on any logical properties that need it.
Igalia is working on implementing logical properties on Blink, and is adding tests for this in https://github.com/web-platform-tests/wpt/pull/11324. This is still not terribly urgent, but maybe Nazim or some of the other folks that are getting started with style / layout may want to get familiar with nsComputedDOMStyle and poke at this?
I can work on that but I have some other things on my plate right now. If someone else wants to work, please take it :) I'll work on it if it's not taken by then.
Assignee: nobody → emilio
Comment on attachment 8988472 [details] Bug 1116638: Expose logical props in computed style. r=xidorn Xidorn Quan [:xidorn] UTC+10 (less responsive until July 7) has approved the revision. https://phabricator.services.mozilla.com/D1862
Attachment #8988472 - Flags: review+
Pushed by emilio@crisal.io: https://hg.mozilla.org/integration/autoland/rev/90de187124a9 Expose logical props in computed style. r=xidorn
Pushed by emilio@crisal.io: https://hg.mozilla.org/integration/autoland/rev/a192866f4936 Update more expectations for new tests added. r=me
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla63
I guess it's worth a intent to ship as well.
Flags: needinfo?(emilio)
Good point, just did :)
Flags: needinfo?(emilio)
For clarity: does this affect web developers in a meaningful way? Does it make a web-exposed API behave differently (even if by fixing an error in its results)? I can't easily tell from the bug or the code without a deeper dive than the usual quick flip through I try to stick to while deciding if bugs should be added to the docs schedule.
Flags: needinfo?(emilio)
Yes, getComputedStyle(element).getPropertyValue('margin-block-start') didn't use to work before this patch, for example.
Flags: needinfo?(emilio)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: