Skip to content
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

How to set a nested strategy #3

Open
jasonwilliams opened this issue Aug 29, 2024 · 1 comment
Open

How to set a nested strategy #3

jasonwilliams opened this issue Aug 29, 2024 · 1 comment

Comments

@jasonwilliams
Copy link
Member

jasonwilliams commented Aug 29, 2024

Currently there's no straight forward way to set a nested strategy for ContainerTiming as the PerformanceObserver doesn't accept options. This may need to be a new field on PerformanceObserverInit

@jdapena
Copy link
Contributor

jdapena commented Feb 13, 2025

The proposal with PerformanceObserverInit has two problems:

  • It requires to change PerformanceObserverInit to add the new fields. This is shared with other timing events and would get a new field that is only usable for ContainerTiming.
  • We cannot know the nesting policy when the events are happening. So, when painting happens, and the information is stored, we need to store all the information for the 3 nesting modes.

As a solution I am proposing (and implementing) a new approach that consist of defining a new attribute, containertiming-nesting for specifying the policy. This attribute gets the same values discussed before (ignore, transparent, shadowed). This way, when a paint needs to be processed, we already know the propagation rules, so we can immediately register the paint in all the roots that expect the value.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants