Closed Bug 1821450 Opened 3 months ago Closed 3 days ago

Simplify the contain keyword for ray function

Categories

(Core :: Layout, enhancement)

enhancement

Tracking

()

RESOLVED FIXED
115 Branch
Tracking Status
firefox115 --- fixed

People

(Reporter: boris, Assigned: boris)

References

(Blocks 2 open bugs, )

Details

(Keywords: dev-doc-needed)

Attachments

(1 file, 1 obsolete file)

Per spec issue: https://github.com/w3c/fxtf-drafts/issues/363, there is a update for contain keyword. Basically it simplify the math calculation and has some impact on the behavior of animations. We should update the implementation once this spec issue gets resolved.

Blocks: 1598151
Keywords: dev-doc-needed
Assignee: nobody → boris.chiou

Per the spec change, when using contain keyword, the path’s length is reduced
by half the width or half the height of the element’s border box, whichever is
larger, and floored at zero.

Tests are in WPT: css/motion/offset-path-ray-contain-00*.html.

Note that these tests are failed because we haven't synced with WPT repo.
After our WPT gets synced, all tests will be passed.

For motion ray() with contain keyword, we are always using
the width and height of the border-box. So this patch makes us easier to
get the border-box dimension from TransformReferenceBox no matter what
transform-box we set.

Attachment #9332940 - Attachment is obsolete: true
Pushed by bchiou@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/29fa69db2655
Update the calculation of contain keyword in ray(). r=emilio
Status: NEW → RESOLVED
Closed: 3 days ago
Resolution: --- → FIXED
Target Milestone: --- → 115 Branch
You need to log in before you can comment on or make changes to this bug.