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

Behaviour of not-rendered elements #170

Closed
jakearchibald opened this issue Jul 27, 2022 · 1 comment
Closed

Behaviour of not-rendered elements #170

jakearchibald opened this issue Jul 27, 2022 · 1 comment

Comments

@jakearchibald
Copy link
Collaborator

jakearchibald commented Jul 27, 2022

When we look for elements to transition, it feels like we should ignore not-rendered elements.

For example, I think creating a transition from:

<div style="page-transition-tag: foo">hello</div>
<div style="page-transition-tag: foo; display: none">world</div>

…to:

<div style="page-transition-tag: foo; display: none">hello</div>
<div style="page-transition-tag: foo">world</div>

…should be valid. As in, it shouldn't fail due to the repeated use of page-transition-tag: foo, since only one of them is renderable.

This also means we wouldn't create transition pseudo-elements for elements that are not-rendered on both sides of the transition.

As in, a transition from:

<div style="page-transition-tag: foo; display: none">hello</div>

…to:

<div style="page-transition-tag: foo; display: none">world</div>

…would not create ::page-transition-container(foo).

This seems to fit in with the model where we don't create CSS animations for not-rendered elements.

@khushalsagar
Copy link
Collaborator

The spec has been updated to ignore such elements, as if they were not tagged. Note that if the not rendered state changes midway through a transition then we still consider the tag on this element.

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