[css-view-transitions-1] Refactor timings of updateCallbackDone and related#9774
Merged
khushalsagar merged 4 commits intow3c:mainfrom Jan 11, 2024
Merged
[css-view-transitions-1] Refactor timings of updateCallbackDone and related#9774khushalsagar merged 4 commits intow3c:mainfrom
updateCallbackDone and related#9774khushalsagar merged 4 commits intow3c:mainfrom
Conversation
khushalsagar
reviewed
Jan 8, 2024
css-view-transitions-1/Overview.bs
Outdated
| 1. [=Activate view transition|Activate=] |transition|. | ||
|
|
||
| - If the promise was fulfilled, then return undefined. | ||
| 1. If |transition|'s [=ViewTransition/phase=] is "`done`", then [=resolve=] |transition|'s [=ViewTransition/update callback done promise=] with undefined. |
Member
There was a problem hiding this comment.
Resolving multiple times is a no-op right?
Collaborator
Author
There was a problem hiding this comment.
When would we resolve multiple times?
Collaborator
Author
There was a problem hiding this comment.
Oh I guess if setting up the pseudo-elements fail... yea, https://tc39.es/ecma262/multipage/control-abstraction-objects.html#sec-promise-resolve-functions step 5
We might not even need the if, we can simply resolve and rely on that behavior. WDYT?
khushalsagar
approved these changes
Jan 9, 2024
Member
khushalsagar
left a comment
There was a problem hiding this comment.
Thanks for fixing the spec here!
css-view-transitions-1/Overview.bs
Outdated
| 1. [=Skip the view transition=] |transition| with |reason|. | ||
|
|
||
| * If the promise was fulfilled, then [=activate view transition|activate=] |transition|. | ||
| Note: A task is queued here because the texture read back in [=capturing the image=] may be async, |
Member
There was a problem hiding this comment.
Do you mind restoring the position of this note? Nicer to have this next to where we post the task. Otherwise its part of this sub-point which is less clearer.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Note: this change is not a behavior change, but rather a clarification of existing expected behavior.
updateCallbackDoneis always resolved after the new state capture but before thereadypromise. (This is current behavior, but not explicit in the current spec).donephase.Closes #9762