Re: [csswg-drafts] [css-shared-element-transitions-1] Define how rendering is suppressed between DOM changes (#7784)

The CSS Working Group just discussed `[css-shared-element-transitions-1] Define how rendering is suppressed between DOM changes`, and agreed to the following:

* `RESOLVED: Rendering suppression uses render blocking to pause update the rendering loop during a view transition`

<details><summary>The full IRC log of that discussion</summary>
&lt;dael> Topic: [css-shared-element-transitions-1] Define how rendering is suppressed between DOM changes<br>
&lt;dael> github: https://github.com/w3c/csswg-drafts/issues/7784<br>
&lt;dael> khush: This issue was about one aspect of feature where when switching doc state a to b we allow dev to async update dom w/o presenting to user.<br>
&lt;dael> khush: We had these use cases in wild where you have a frame that you render and flips back to snapshot state. You get intermediate frames before animation<br>
&lt;dael> khush: Question on how to suppress. One is render blocking that draws on HTML. BRowser suppresses rendering opportunities<br>
&lt;dael> khush: When you call script API to start, we snapshot and then suppress rendering opportunities<br>
&lt;dael> khush: Other is we keep running lifecycle but browser doesn't present them. Tha could be confusing so prop blocking<br>
&lt;dael> khush: We are planning scoped transitions where it runs on a dom subtree and then we can't do render blocking. I've linked to a prop there for how we want to manage the rendering with scoped transitions. It's using a cached snapshot but keep running the process and retuning the cach<br>
&lt;dael> khush: Would cause a difference between transition types<br>
&lt;smfr> q+<br>
&lt;dael> khush: Prop is go with render blocking behavior for same document and cross document cases<br>
&lt;astearns> ack smfr<br>
&lt;dael> smfr: Would render blocking, is all JS paused?<br>
&lt;dael> khush: No, not at all. Just the update rendering lop is paused<br>
&lt;dael> smfr: Would set timeout fire?<br>
&lt;dael> khush: Yes. Request animation won't<br>
&lt;dael> smfr: Seems weird to turn off some callbacks but not others<br>
&lt;dael> khush: Steps that are part of update rendering loop are paused. Similar to if document is not visible<br>
&lt;TabAtkins> +1, this seems reasonable to me<br>
&lt;dael> smfr: If you did call request animation frame you'd get the callback after render blocking is off<br>
&lt;dael> khush: Correct. Similar to render blocking for a new page doc. Whole loop doesn't run until resources fetched<br>
&lt;dael> astearns: Is there a definition of what does and does not work when document is not visible? I'm wondering if it's similar or exactly like<br>
&lt;dael> khush: Best would be render blocking in the HTML spec. Poitns to rendering opptys and says browser pauses<br>
&lt;vmpstr> update the rendering, for reference: https://html.spec.whatwg.org/multipage/webappapis.html#update-the-rendering<br>
&lt;dael> khush:  clear definition of what is meant to be fired in render loop so gives precise definition<br>
&lt;dael> smfr: Remind me what triggers unblocking?<br>
&lt;dael> khush: script api you call a function with a callback. async callback where dev does all dom mutations. Promise from that unblocks<br>
&lt;dael> smfr: Are tehre other transitions/animations that can run?<br>
&lt;dael> khush: All animations pause<br>
&lt;dael> smfr: Completion doesn't require an animation to render<br>
&lt;dael> khush: Aim of this callback is for you to do min network work you have to do<br>
&lt;ydaniv> will that freeze video playback as well?<br>
&lt;dael> khush: There is no risk of deadlock b/c dev callback should be waiting on anything dispatched during this<br>
&lt;dael> khush: video playback will freeze<br>
&lt;dael> khush: One of the main reasons is the one frame that runs if you don't pause you get a weird flick where you draw more frames but then anything animated flips back to cahced state<br>
&lt;dael> smfr: Pausing video might be tricky for WK<br>
&lt;dael> khush: I think we impl by the parts of stack running animations not giving them resync<br>
&lt;dael> smfr: We oofload some to OS. You're in the middle of a transform...what happens to timeline of animations for render blocking?<br>
&lt;dael> khush: Time proceeds. Timeline will progress forward. Similar to visiblity where itab is backgrounded you don't draw but when you come back animation draws at current time<br>
&lt;dael> khush: I can see impl tough. Motivating factor is this weird flick where you go forward a bit and then back in time when you move to cached snapshots<br>
&lt;dael> astearns: Sounds like you have concerns smfr. You okay resolving to use render blocking and then open issues as you impl?<br>
&lt;dael> smfr: Yeah, I think so<br>
&lt;dael> astearns: Other opinions on using render blocking?<br>
&lt;dael> astearns: ydaniv is the freezing video what you were looking for?<br>
&lt;dael> ydaniv: Just look weird, same as animations stopping. I guess it will be necessary<br>
&lt;dbaron> s/oofload/offload/<br>
&lt;dael> khush: Prop: Rendering suppression uses render blocking to pause update the rendering loop during a view transition<br>
&lt;dael> astearns: Objections?<br>
&lt;dael> RESOLVED: Rendering suppression uses render blocking to pause update the rendering loop during a view transition<br>
</details>


-- 
GitHub Notification of comment by css-meeting-bot
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/7784#issuecomment-1269123478 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Wednesday, 5 October 2022 23:59:16 UTC