Skip to content

[cssom-view-1] Added definition of getBoxQuads() #10538

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

jogibear9988
Copy link

@jogibear9988 jogibear9988 commented Jul 8, 2024

Fixes #10537

A linked issue:
#10514

A firefox issue with a little bit of description:
https://bugzilla.mozilla.org/show_bug.cgi?id=1107559

A polyfill for the API
https://github.com/jogibear9988/getBoxQuadsPolyfill

@svgeesus svgeesus changed the title [css-spec-shortname-1] https://github.com/w3c/csswg-drafts/issues/10537 [cssom-view-1] https://github.com/w3c/csswg-drafts/issues/10537 Jul 8, 2024
@jogibear9988
Copy link
Author

One issues atm:
My polyfill only works for 2D transformations, 3D with perspective do not work (yet). Have to figure out how to do this. Cause of that, also my spec only works for 2D. I've found some spect for the 3D matrix, wich then also could maybe reused: https://drafts.csswg.org/css-transforms-2/#accumulated-3d-transformation-matrix-computation

@SebastianZ SebastianZ changed the title [cssom-view-1] https://github.com/w3c/csswg-drafts/issues/10537 [cssom-view-1] Added definition of getBoxQuads() May 12, 2025
@SebastianZ
Copy link
Contributor

I think it makes more sense to add another option to getBoxQuads() to consider the transformed coordinates instead of introducing a separate function getCompleteTransform() for that.

I imagine something like getBoxQuads({considerTransformations: true}).

Sebastian

@jogibear9988
Copy link
Author

One issues atm: My polyfill only works for 2D transformations, 3D with perspective do not work (yet). Have to figure out how to do this. Cause of that, also my spec only works for 2D. I've found some spect for the 3D matrix, wich then also could maybe reused: https://drafts.csswg.org/css-transforms-2/#accumulated-3d-transformation-matrix-computation

should be fixed in current polyfill

@jogibear9988
Copy link
Author

jogibear9988 commented May 12, 2025

I think it makes more sense to add another option to getBoxQuads() to consider the transformed coordinates instead of introducing a separate function getCompleteTransform() for that.

I imagine something like getBoxQuads({considerTransformations: true}).

Sebastian

it's in a extra method, cause it is used from other functions in the spec (like convertPointFromNode). And convertPointFromNode use it multiple times

@gsnedders gsnedders added Agenda+ and removed Agenda+ labels May 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[css-omview] update description of getBoxQuads API
4 participants