8000 Remove pagereveal (#9718) · w3c/csswg-drafts@939ad3d · GitHub
[go: up one dir, main page]

Skip to content

Commit 939ad3d

Browse files
authored
Remove pagereveal (#9718)
1 parent dc8c9a8 commit 939ad3d

File tree

1 file changed

+9
-59
lines changed

1 file changed

+9
-59
lines changed

css-view-transitions-2/Overview.bs

Lines changed: 9 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ spec:html
4040
text: was created via cross-origin redirects; type: dfn;
4141
text: run the animation frame callbacks; type: dfn;
4242
text: unload; type: dfn;
43-
text: update the rendering; type: dfn;
43+
text: pagereveal; type: dfn; for: Window;
4444
spec:infra; type:dfn; text:list
4545
</pre>
4646

@@ -265,7 +265,7 @@ document.startViewTransition({update: updateTheDOMSomehow});
265265

266266
The ''@view-transition'' rule is used by a document to indicate that cross-document navigations
267267
should setup and activate a {{ViewTransition}}. To take effect, it must be present in the old document
268-
when unloading, and in the new document when it is [=reveal=].
268+
when unloading, and in the new document when the [=Window/pagereveal=] is fired.
269269

270270

271271
## @view-transition rule grammar ## {#view-transition-grammar}
@@ -316,23 +316,6 @@ Note: as per default behavior, the ''@view-transition'' rule can be nested insid
316316

317317
# API # {#api}
318318

319-
## The <dfn interface>PageRevealEvent</dfn> ## {#ready-to-render-event}
320-
321-
Note: this should go in the HTML spec. See [Issue 9315](https://github.com/whatwg/html/issues/9315).
322-
323-
<xmp class=idl>
324-
[Exposed=Window]
325-
interface PageRevealEvent : Event {
326-
readonly attribute ViewTransition? viewTransition;
327-
};
328-
</xmp>
329-
330-
A {{PageRevealEvent}} has a null-or-{{ViewTransition}} <dfn for=PageRevealEvent>view transition</dfn>, initially null.
331-
332-
Note: this event is fired when the document is [=reveal=].
333-
334-
The <dfn attribute for=RevealEvent>viewTransition</dfn> [=getter steps=] are to return [=this=]'s [=PageRevealEvent/view transition=].
335-
336319
## Additions to {{Document}} ## {#additions-to-document-api}
337320

338321
<xmp class=idl>
@@ -390,14 +373,6 @@ The {{CSSViewTransitionRule}} represents a ''@view-transition'' rule.
390373
# Algorithms # {#algorithms}
391374
## Data Structures ## {#concepts}
392375

393-
### Additions to {{Document}} ### {#additions-to-document}
394-
395-
A {{Document}} additionally has:
396-
397-
<dl dfn-for=document>
398-
: <dfn>pagereveal fired</dfn>
399-
:: a boolean, initially false.
400-
401376
### Additions to {{ViewTransition}} ### {#view-transitions-extension}
402377

403378
A {{ViewTransition}} additionally has:
@@ -422,35 +397,10 @@ The {{CSSViewTransitionRule}} represents a ''@view-transition'' rule.
422397
Note: This would wait until a transition is captured or skipped before proceeding to unloading the old document and activating the new one.
423398
</div>
424399

425-
<div algorithm="monkey patch to rendering">
426-
Run the following step in [=update the rendering|updating the renedering=], before [=running the animation frame callbacks=]:
427-
428-
1. For each [=fully active=] {{Document}} |doc| in |docs|, run the [=reveal=] steps for |doc|.
429-
</div>
430-
431-
<div algorithm="monkey patch to reactivation">
432-
Run the following step at the end of [=Document/reactivate=]:
433-
434-
1. Set |document|'s [=pagereveal fired=] to false.
435-
</div>
436-
437-
<div algorithm="page reveal">
438-
To <dfn>reveal</dfn> {{Document}} |document|:
439-
1. If |document|'s [=document/page pagereveal fired=] is true, then return.
440-
441-
1. Let |transition| be the result of [=resolving cross-document view-transition=] for |document|.
442-
443-
1. [=Fire an event=] named <code>pagereveal</code> at |document|'s [=relevant global object=],
444-
using {{PageRevealEvent}}, with [=PageRevealEvent/view transition=] initialized to |transition|.
445-
446-
1. If |transition| is not null, then [=activate view transition/activate=] |transition|.
447-
448-
1. Set |document|'s [=document/page pagereveal fired=] to true.
449-
</div>
450400

451401
## Setting up and activating the cross-document view transition ## {#setting-up-and-activating-the-cross-document-view-transition}
452402

453-
### Resolving the ''@view-transition''' rule
403+
### Resolving the ''@view-transition''' rule ### {#resolve-view-transition-rule-algo}
454404

455405
<div algorithm>
456406
To get the <dfn>resolve @view-transition rule</dfn> for a {{Document}} |document|:
@@ -465,12 +415,12 @@ The {{CSSViewTransitionRule}} represents a ''@view-transition'' rule.
465415

466416
1. Let |typesDescriptor| be |matchingRule|'s [=@view-transition/type=] descriptor.
467417

468-
1. If |typesDescriptor|'s [=computed value=] is ''@view-transition/type/none'', then return an [=empty list=].
418+
1. If |typesDescriptor|'s [=computed value=] is ''@view-transition/type/none'', then return a [=/list=] « ».
469419

470420
1. Return a [=list=] of strings corresponding to |typesDescriptor|'s [=computed value=].
471421
</div>
472422

473-
### Setting up the view-transition in the old {{Document}}
423+
### Setting up the view-transition in the old {{Document}} ### {#setup-old-document-vt}
474424

475425
<div algorithm>
476426
To <dfn export>setup cross-document view-transition</dfn> given a {{Document}} |oldDocument|,
@@ -495,7 +445,7 @@ The {{CSSViewTransitionRule}} represents a ''@view-transition'' rule.
495445
1. If |resolvedRule| is "<code>skip transition</code>", then call |onReady| and return.
496446

497447
Note: We don't know yet if |newDocument| has opted in, as it might not be parsed yet.
498-
We check the opt-in for |newDocument| when it is [=reveal=].
448+
We check the opt-in for |newDocument| when we fire the [=Window/pagereveal=] event.
499449

500450
1. If |oldDocument|'s [=active view transition=] is not null,
501451
then [=skip the view transition|skip=] |oldDocument|'s [=active view transition=]
@@ -550,13 +500,13 @@ The {{CSSViewTransitionRule}} represents a ''@view-transition'' rule.
550500
Note: The process continues in [=setup view transition=], via [=perform pending transition operations=].
551501

552502
1. The user agent should display the currently displayed frame until either:
553-
* |newDocument| is [=revealed=]
503+
* The [=Window/pagereveal=] event is fired.
554504
* its [=active view transition=]'s [=ViewTransition/phase=] is "`done`".
555505

556506
Note: this is to ensure that there are no unintended flashes between displaying the old and new state, to keep the transition smooth.
557507
</div>
558508

559-
### Accessing the view-transition in the new {{Document}}
509+
### Accessing the view-transition in the new {{Document}} ### {#access-view-transition-in-new-doc}
560510

561511
<div algorithm>
562512
To <dfn export>resolve cross-document view-transition</dfn> for {{Document}} |document|:
@@ -567,7 +517,7 @@ The {{CSSViewTransitionRule}} represents a ''@view-transition'' rule.
567517
then return null.
568518

569519
Note: |transition|'s [=ViewTransition/is inbound cross-document transition=] would be false if a same-document
570-
transition was started before the page was [=reveal=].
520+
transition was started before the [=Window/pagereveal=] event was fired.
571521

572522
1. [=Resolve @view-transition rule=] for |document| and let |resolvedRule| be the result.
573523

0 commit comments

Comments
 (0)
0