Skip to content

Commit 7b6bced

Browse files
committed
[css-anchor-position] Add more conditions for forgetting the last remembered @position-try option. #10099
1 parent ec10499 commit 7b6bced

File tree

1 file changed

+14
-5
lines changed

1 file changed

+14
-5
lines changed

css-anchor-position-1/Overview.bs

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1561,11 +1561,20 @@ laying out later elements cannot change this decision.
15611561
Layout does not "go backward", in other words.
15621562
</div>
15631563

1564-
At the time that {{ResizeObserver}} events are determined and delivered,
1565-
if an element has a [=last successful position option=]
1566-
but is not an [=absolutely positioned=] element,
1567-
remove its [=last successful position option=].
1568-
(This is intentionally identical to the treatment of [=last remembered sizes=].)
1564+
<div algorithm="forget the last rememberd @position-try option">
1565+
At the time that {{ResizeObserver}} events are determined and delivered,
1566+
if an element |el| has a [=last successful position option=]
1567+
and if any of the following are true of it,
1568+
remove its [=last successful position option=]:
1569+
1570+
* |el| is not an [=absolutely positioned=] element
1571+
* |el|'s computed value for 'position-try-options' has changed
1572+
* Any of the ''@position-try'' rules referenced by |el|'s 'position-try-options'
1573+
have been added, removed, or mutated.
1574+
1575+
Note: The timing of this removal
1576+
is intentionally identical to the treatment of [=last remembered sizes=].
1577+
</div>
15691578

15701579
Issue: Make sure the snapshotted scroll offset stuff is correct now,
15711580
given interleaving.

0 commit comments

Comments
 (0)