Skip to content

Commit

Permalink
[css-contain-3] Make content-visibility animatable. (#8737)
Browse files Browse the repository at this point in the history
Allow animating content-visibility as animation type discrete with
special interpolation to avoid hidden values similar to visibility.
Fixes #8627.
  • Loading branch information
flackr authored Apr 20, 2023
1 parent 8c8ca73 commit 64fa7b9
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions css-contain-3/Overview.bs
Original file line number Diff line number Diff line change
Expand Up @@ -1066,8 +1066,30 @@ The <code>CSSContainerRule</code> interface</h3>
Suppressing An Element’s Contents Entirely: the 'content-visibility' property {#content-visibility}
=================

<pre class=propdef>
Name: content-visibility
Value: visible | auto | hidden
Initial: visible
Inherited: no
Applies to: elements for which [=size containment=] can apply
Animation type: see [[#content-visibility-animation]]
</pre>

Issue: [[css-contain-2#content-visibility]]

<h3 id='content-visibility-animation'>
Animating and Interpolating 'content-visibility'</h3>

In general,
the 'content-visibility' property’s [=animation type=] is [=discrete=].
However,
similar to interpolation of 'visibility'
(see [[web-animations-1#animating-visibility]]),
during interpolation between ''content-visibility/hidden''
and any other 'content-visibility' value,
<var>p</var> values between 0 and 1
map to the non-''content-visibility/hidden'' value.

Privacy Considerations {#privacy}
=================================

Expand Down Expand Up @@ -1103,6 +1125,8 @@ Changes since the 18 August 2022 Working Draft</h3>
* Correct typo in 'container-type' syntax, to clarify that ''normal'' cannot
be combined with other values.
(<a href="https://github.com/w3c/csswg-drafts/issues/7669">Issue 7669</a>)
* Make the 'content-visibility' property animatable.
(<a href="https://github.com/w3c/csswg-drafts/issues/8627">Issue 8627</a>)

<h3 id="changes-2021-12">
Changes since the 21 December 2021 First Public Working Draft</h3>
Expand Down

0 comments on commit 64fa7b9

Please sign in to comment.