Skip to content

Commit 60639c5

Browse files
committed
[css-view-transitions-2] Allow auto as a keyword
`auto` resolves to either the element's ID, or to a unique identifier that is stable for the duration of the transition and is not web-observable. Resolution: w3c#8320 (comment) Closes w3c#8320
1 parent c6b1b11 commit 60639c5

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

css-view-transitions-2/Overview.bs

+16-1
Original file line numberDiff line numberDiff line change
@@ -755,7 +755,20 @@ div.box {
755755

756756
# Nested view-transitions # {#nested-view-transitions}
757757

758-
## Overview ## {#nested-overview}
758+
## Overview ## {#auto-name-overview}
759+
760+
## Additions to 'view-transition-name'
761+
762+
In addition to the existing values, the 'view-transition-name' also accepts an <dfn for=view-transition-name type=value>auto</dfn> keyword.
763+
To resolve the [=used value=] of 'view-transition-name' for |element|:
764+
1. Let |computed| be the [=computed value=] of 'view-transition-name'.
765+
1. If |computed| is <css>none</css>, return null.
766+
1. If |computed| is a <<custom-ident>>, return |computed|.
767+
1. Assert: |computed| is <css>auto</css>.
768+
1. If |element| has an associated [=Element/id=], then return |element|'s [=Element/id=].
769+
1. Return a unique string, which is not a <<custom-ident>>. This string should remain consistent at least for the lifetime of |element|'s [=node document=]'s [=active view transition=].
770+
771+
Note: this string is not web-observable, and is used for addressing the element in internal algorithms.
759772

760773
*This section is non-normative.*
761774

@@ -1170,6 +1183,8 @@ When [[css-view-transitions-1#style-transition-pseudo-elements-algorithm|updatin
11701183
1. [=Multiply=] |transform| by the inverse matrix of |groupContainerElement|'s [=transform from snapshot containing block=].
11711184
</div>
11721185

1186+
1187+
11731188
<h2 id="priv" class="no-num">Privacy Considerations</h2>
11741189

11751190
This specification introduces no new privacy considerations.

0 commit comments

Comments
 (0)