Open Bug 1773791 Opened 4 years ago Updated 1 month ago

[css-images-5] Add support for CSS "object-view-box" property

Categories

(Core :: Layout: Images, Video, and HTML Frames, enhancement)

enhancement

Tracking

()

Size Estimate M

People

(Reporter: dholbert, Unassigned)

References

(Blocks 3 open bugs, )

Details

(Keywords: dev-doc-needed, parity-chrome, web-feature, Whiteboard: [platform-feature])

User Story

web-feature: object-view-box

Filing this bug to cover implementation of the "object-view-box" CSS property.
https://drafts.csswg.org/css-images-4/#the-object-view-box

(mirror: https://andreubotella.com/csswg-auto-build/css-images-4/#the-object-view-box )

See also https://github.com/w3c/csswg-drafts/issues/7143 (and probably several other csswg-drafts issues) where this has been discussed, too.

Blocks: 1773251
Keywords: dev-doc-needed

Supporting view-box would align us with Safari and Chrome by passing the two WPTs where we presently don't align for the css/css-transforms/transform-box tests (cssbox-initial.html and svgbox-initial.html), so it might be worth prioritizing over the other features which Chrome doesn't yet support on the same tests.

No longer blocks: interop-2023-transforms

(In reply to Thomas Wisniewski [:twisniewski] from comment #1)

Supporting view-box would align us with Safari and Chrome by passing the two WPTs where we presently don't align for the css/css-transforms/transform-box tests (cssbox-initial.html and svgbox-initial.html), so it might be worth prioritizing over the other features which Chrome doesn't yet support on the same tests.

I guess you were talking about Bug 1819464. This bug shouldn't be related to css transform.

Indeed that seems to be the case. My mistake, thanks for checking!

This now part of css-images-5: https://drafts.csswg.org/css-images-5/

The object-view-box property specifies a "view box" over an element, which allows zooming or panning over the element’s contents. It maps to the <svg viewBox> attribute in SVG.

So if I use the SVG DOM to set viewBox values, does the CSS property change? That's how other mapped properties such as x, y, r, rx, ry, width and height work FWIW.

User Story: (updated)
Whiteboard: [platform-feature]
Size Estimate: --- → M
Summary: [css-images-4] Add support for CSS "object-view-box" property → [css-images-5] Add support for CSS "object-view-box" property
You need to log in before you can comment on or make changes to this bug.