Skip to content

[web-animations-2][css-animations-2] How should unspecified trigger range boundaries be resolved? #11932

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
DavMila opened this issue Mar 13, 2025 · 15 comments

Comments

@DavMila
Copy link
Contributor

DavMila commented Mar 13, 2025

In the web animations spec, animation-trigger-range-start, animation-trigger-range-end, animation-trigger-exit-range-start and animation-trigger-exit-range-end specify the boundaries of the ranges in which an AnimationTrigger will play, pause, reverse, etc. an associated animation. Valid values for these properties are similar to animation-range, e.g. “contain 10%”, “cover 100%”, etc.
How should these properties be resolved when not specified?

Some options we can consider are:

  1. Using the boundaries of the named range (which defaults to “cover” for view timelines). E.g. “contain 10%” resolves to “contain 10% contain 100%”. This is what’s done for animation-range.

  2. Using the boundaries of the scroll range (instead of the view timeline range). E.g. “contain 10%” resolves to “contain 10% scroll 100%”

Option 2 is useful for scenarios in which an author essentially wants a single point beyond which scrolling would trigger an animation. The author could just write, e.g., “contain 0%”. OTOH if they want to match the “contain” boundary then they have to set “contain 0% contain 100%".

With option 1, the tradeoff is the converse: they can simply specify “contain 0%” to mean “contain 0% contain 100%” and if they mean to refer to the entire scroll range then they have to use the scroll keyword, e.g. “contain 0% scroll 100%”.

I suggest going with option 1 which aligns with animation-range so developers don’t have to remember that the named ranges keywords expand one way for animation-range and a different way for animation-trigger-*range.

@ydaniv
Copy link
Contributor

ydaniv commented Mar 13, 2025

I think option 1 is what authors would more likely expect when using view timelines. Also, like you said, it's nice if we can have a consistent resolving for ranges across different properties.

Also notice that exit range properties allow an auto value as default which falls back to the corresponding value of the default range, and not to normal.

I suppose if you set only contain 10% for animation-trigger-exit-range-start it will resolve the end similar to option 1 above.

@DavMila
Copy link
Contributor Author

DavMila commented Mar 13, 2025

Also notice that exit range properties allow an auto value as default which falls back to the corresponding value of the default range, and not to normal.

Ah yes, perhaps another issue worth resolving on: I agree that it would be nice to have a default value for the exit range boundaries that says "match the default range" but I know there's been some concern (example) in the past about specifying auto in a way that doesn't mean "user agent should do what makes sense". This doesn't mean that user agents can't treat auto this way, but maybe is a reason to instead consider using normal to mean "match the default range."

This would mean normal for animation-trigger-exit-range is different from normal for animation-range but I think this wouldn't be too problematic a difference for developers and may even be the more meaningful option if we establish some relationship between the default and exit ranges like 11910 discusses.

It would also mean that an author that means to specify "cover" range (which "normal" would have meant) as the exit range but not as the default range in the shorthand (animation-trigger) would need to specify the first 2 longhands, animation-trigger-range-start and animation-trigger-range-end, and "cover", i.e. they couldn't write animation-trigger: contain 0% or animation-trigger: contain 0% contain 100%. They would have to write animation-trigger: contain 0% contain 100% cover... but this would be the same with auto if the exit-range properties default to auto.

@ydaniv
Copy link
Contributor

ydaniv commented Mar 17, 2025

Ah yes, perhaps another issue worth resolving on: I agree that it would be nice to have a default value for the exit range boundaries that says "match the default range" but I know there's been some concern (w3ctag/design-reviews#1011 (comment)) in the past about specifying auto in a way that doesn't mean "user agent should do what makes sense". This doesn't mean that user agents can't treat auto this way, but maybe is a reason to instead consider using normal to mean "match the default range."

That is why I added the auto value, since normal is already specified to have a specific meaning and I did not want to overload that meaning depending on the context. So instead I figured that auto in this context means exactly that: "the UA should do what makes sense, which is match the corresponding value from the default range".

You think it's less appropriate here?

This would mean normal for animation-trigger-exit-range is different from normal for animation-range but I think this wouldn't be too problematic a difference for developers and may even be the more meaningful option if we establish some relationship between the default and exit ranges

In this case I'd prefer not having to parse normal based on the context. OTOH, I think auto is a value that can be parsed differently based on context, so would prefer that value to do a lookup on another property's value. But I'm open to hear otherwise.

It would also mean that an author that means to specify "cover" range (which "normal" would have meant) as the exit range but not as the default range in the shorthand (animation-trigger) would need to specify the first 2 longhands, animation-trigger-range-start and animation-trigger-range-end, and "cover", i.e. they couldn't write animation-trigger-range: contain 0% or animation-trigger-range: contain 0% contain 100%. They would have to write animation-trigger-range: contain 0% contain 100% cover... but this would be the same with auto if the exit-range properties default to auto.

That is a separate issue I briefly raised here.
I think I'll open a separate issue for that.

@ydaniv
Copy link
Contributor

ydaniv commented Mar 17, 2025

@DavMila please see #11948

@bramus
Copy link
Contributor

bramus commented Mar 25, 2025

While re-reading the thread that sparked scroll-triggered animations, I noticed this question was also covered in that thread.

See #8942 (comment) and the next few comments.

My first interpretation was that animation-trigger: view() alternate entry 100%; would resolve to animation-trigger: view() alternate entry 100% contain 100%;.

But then @flackr clarified that my interpretation was incorrect and that we should expand to “infinite” behavior instead of contain 100%.

So using scroll 100% here comes closest to this. As this is for the default trigger range, I would assume an omitted -end value for the exit trigger range would be scroll 0%

@ydaniv
Copy link
Contributor

ydaniv commented Mar 25, 2025

That is only if you specifically want the single triggering behavior, like the comment says:

If we want to support a single trigger point that is active for any position after it we need to have different behavior from the default animation range single value.

In that case you need that infinite behavior. So if you want a repeating/alternating triggering with a single point you need to specify something like: entry 100% scroll 100%.

But omitting a range boundary is not the same as trying to specify a single boundary.
Currently the spec says that default ranges are resolved similar animation-range, and omitted exit range boundaries default to their corresponding default range boundaries - being auto.

@DavMila
Copy link
Contributor Author

DavMila commented Mar 26, 2025

But omitting a range boundary is not the same as trying to specify a single boundary.

I guess this comes down to something like bikeshedding because both approaches (expanding similar to animation-range or expanding to scroll 100%) give authors the same capabilities. I'm nudged towards having the default range expand to scroll 100% because that lets an author who wants to specify a single point specify a single value :)

@ydaniv
Copy link
Contributor

ydaniv commented Mar 26, 2025

I guess this comes down to something like bikeshedding because both approaches (expanding similar to animation-range or expanding to scroll 100%) give authors the same capabilities. I'm nudged towards having the default range expand to scroll 100% because that lets an author who wants to specify a single point specify a single value :)

So what you're saying is not really bikeshedding, but rather resolve on a different default value for animation-trigger-range-end, right? Or otherwise have normal resolve to scroll 100% instead of cover 100%?

Well we should also take into account not specifying anything, keeping both start and end as normal would result as scroll 0% 100%, right? IMO having these as defaults kind of defeats the purpose, right?
Also, I'd prefer to keep it consistent with animation-range-end and normal resolving as well, being cover 100%.

@DavMila
Copy link
Contributor Author

DavMila commented Mar 27, 2025

Thinking about this a bit more: since the capabilities are the same either way, making it necessary for an author to have to specify, for example, entry 100% scroll 100% for the single point case really doesn't seem so bad, especially since it means we can stay consistent with animation-range by defaulting to normal and also preserve the meaning of normal.

I think the alternate example in @flackr 's demo demonstrates a common pattern where the element slides in and out at the bottom and top of the viewport, corresponding (roughly) to the cover range. I think it makes sense for the default setting, where a view() timeline has been declared, to cater to this use case (all the author needs write is contain or cover). If we default to scroll 100% for the end of the default range, the author has to write contain 0% contain 100%, otherwise the slide out at the top of the viewport won't happen.

I guess one other option is to make the default range dependent on the type of trigger, e.g. once defaults to scroll 0% scroll 100%, alternate, repeat and state default to cover 0% cover 100%. In which case maybe an auto keyword for the default range might make sense. But this, or a similar scheme, seems a bit developer-unfriendly to me as they'd have to keep track of which type maps to which default range.

Also, for the exit range I think using auto as the default and having it mean "match the default range" sounds good. That way the meaning of normal is fully preserved.

@ydaniv
Copy link
Contributor

ydaniv commented Mar 27, 2025

Great, so IIUC this means close as no change for now?

@DavMila
Copy link
Contributor Author

DavMila commented Mar 28, 2025

Great, so IIUC this means close as no change for now?

I thought this, along with other issues #11971, 11915, 11914, would be good to put on the WG's agenda so we can come to a formal resolution on the expected behavior. Maybe agenda+?

@ydaniv ydaniv added the Agenda+ label Mar 28, 2025
@DavMila
Copy link
Contributor Author

DavMila commented Apr 2, 2025

Thought I'd post one detail that occurred to me about this:

animation-trigger-exit-range: auto normal should mean the same as animation-trigger-exit-range: auto auto which means "match the trigger range."

and

animation-trigger-exit-range: normal auto should mean the same as animation-trigger-exit-range: normal normal which refers to the cover range.

The first case represents a slight expansion of the meaning of normal so that normal is defined in the newly introduced context of auto.

@ydaniv
Copy link
Contributor

ydaniv commented Apr 6, 2025

animation-trigger-exit-range: auto normal should mean the same as animation-trigger-exit-range: auto auto which means "match the trigger range."

I don't think I understood this. auto is always resolved to match the corresponding value of the default range, and normal is resolved to match the corresponding edge of the full range.
So for: animation-trigger-range-start: entry 20%; animation-trigger-exit-range-start: auto
You'll get: animation-trigger-range-start: entry 20%; animation-trigger-exit-range-start: entry 20%.

And for: animation-trigger-range-start: entry 20%; animation-trigger-exit-range-start: normal
You'll get: animation-trigger-range-start: entry 20%; animation-trigger-exit-range-start: cover 0%.

The point is that in the same range -start and -end don't affect each other in case of having the auto value. They're always resolved against the default range, as in animation-trigger-range.

@DavMila
Copy link
Contributor Author

DavMila commented Apr 8, 2025

And for: animation-trigger-range-start: entry 20%; animation-trigger-exit-range-start: normal You'll get: animation-trigger-range-start: entry 20%; animation-trigger-exit-range-start: cover 0%.

Right, I was mistaken about the meaning of normal. I thought contain normal in the animation-range context was contain contain but it is contain cover, matching your example.

So for: animation-trigger-range-start: entry 20%; animation-trigger-exit-range-start: auto
You'll get: animation-trigger-range-start: entry 20%; animation-trigger-exit-range-start: entry 20%.

Because of the way I thought normal worked, I thought auto should try to do something like that too. But since that isn't the case, I think it makes sense that auto simply resolves as the default range. Though now I wonder if this simpler definition calls for a more precise keyword than auto since the behavior is always the same. Maybe default.. match?

@ydaniv
Copy link
Contributor

ydaniv commented Apr 8, 2025

Because of the way I thought normal worked, I thought auto should try to do something like that too. But since that isn't the case, I think it makes sense that auto simply resolves as the default range. Though now I wonder if this simpler definition calls for a more precise keyword than auto since the behavior is always the same. Maybe default.. match?

Sure, I'm open to suggestions if we wish to bikeshed the auto value.


I'll agenda+ this issue with issue:
Q: how shall we name the value for exit range which resolves to matching the corresponding default range?
Proposal: auto

aarongable pushed a commit to chromium/chromium that referenced this issue Apr 9, 2025
animation-trigger is a shorthand that specifies, among other
properties, 4 points that represent the boundaries at which the trigger
will act on its animation(s). The 4 points correspond to the CSS
properties:

 * animation-trigger-range-start
 * animation-trigger-range-end
 * animation-trigger-exit-range-start
 * animation-trigger-exit-range-end

The first 2 properties define the "trigger range" and the last two
define the "exit range." animation-trigger-exit-range is the shorthand
for the last two properties. The default value for the exit range
boundaries is "auto" which can mean one of two things:

1. Primarily,the meaning of auto is "match the trigger range."
2. In the case of animation-trigger-exit-range-end, if a named range,
   e.g. "contain" has been specified for
   animation-trigger-exit-range-start, then auto should be interpreted
   as the end of that named range, similar to normal for
   animation-range.

The slightly expands the meaning of normal so that the case of
"auto normal" has the same meaning as "auto auto", i.e. "match the
trigger range."

Note: This has not yet been resolved on by the CSS working group but it
is being discussed[2] and is how we're thinking about how it all should
work.

[1] https://drafts.csswg.org/css-animations-2/#animation-trigger-exit-range-start
[2] w3c/csswg-drafts#11932

Bug: 390314945
Change-Id: I3a76401e0bf40bebe2960b96d11ba96bb010e705
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6426886
Reviewed-by: Anders Hartvoll Ruud <[email protected]>
Commit-Queue: David Awogbemila <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1444687}
chromium-wpt-export-bot pushed a commit to web-platform-tests/wpt that referenced this issue Apr 9, 2025
animation-trigger is a shorthand that specifies, among other
properties, 4 points that represent the boundaries at which the trigger
will act on its animation(s). The 4 points correspond to the CSS
properties:

 * animation-trigger-range-start
 * animation-trigger-range-end
 * animation-trigger-exit-range-start
 * animation-trigger-exit-range-end

The first 2 properties define the "trigger range" and the last two
define the "exit range." animation-trigger-exit-range is the shorthand
for the last two properties. The default value for the exit range
boundaries is "auto" which can mean one of two things:

1. Primarily,the meaning of auto is "match the trigger range."
2. In the case of animation-trigger-exit-range-end, if a named range,
   e.g. "contain" has been specified for
   animation-trigger-exit-range-start, then auto should be interpreted
   as the end of that named range, similar to normal for
   animation-range.

The slightly expands the meaning of normal so that the case of
"auto normal" has the same meaning as "auto auto", i.e. "match the
trigger range."

Note: This has not yet been resolved on by the CSS working group but it
is being discussed[2] and is how we're thinking about how it all should
work.

[1] https://drafts.csswg.org/css-animations-2/#animation-trigger-exit-range-start
[2] w3c/csswg-drafts#11932

Bug: 390314945
Change-Id: I3a76401e0bf40bebe2960b96d11ba96bb010e705
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6426886
Reviewed-by: Anders Hartvoll Ruud <[email protected]>
Commit-Queue: David Awogbemila <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1444687}
chromium-wpt-export-bot pushed a commit to web-platform-tests/wpt that referenced this issue Apr 9, 2025
animation-trigger is a shorthand that specifies, among other
properties, 4 points that represent the boundaries at which the trigger
will act on its animation(s). The 4 points correspond to the CSS
properties:

 * animation-trigger-range-start
 * animation-trigger-range-end
 * animation-trigger-exit-range-start
 * animation-trigger-exit-range-end

The first 2 properties define the "trigger range" and the last two
define the "exit range." animation-trigger-exit-range is the shorthand
for the last two properties. The default value for the exit range
boundaries is "auto" which can mean one of two things:

1. Primarily,the meaning of auto is "match the trigger range."
2. In the case of animation-trigger-exit-range-end, if a named range,
   e.g. "contain" has been specified for
   animation-trigger-exit-range-start, then auto should be interpreted
   as the end of that named range, similar to normal for
   animation-range.

The slightly expands the meaning of normal so that the case of
"auto normal" has the same meaning as "auto auto", i.e. "match the
trigger range."

Note: This has not yet been resolved on by the CSS working group but it
is being discussed[2] and is how we're thinking about how it all should
work.

[1] https://drafts.csswg.org/css-animations-2/#animation-trigger-exit-range-start
[2] w3c/csswg-drafts#11932

Bug: 390314945
Change-Id: I3a76401e0bf40bebe2960b96d11ba96bb010e705
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6426886
Reviewed-by: Anders Hartvoll Ruud <[email protected]>
Commit-Queue: David Awogbemila <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1444687}
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this issue Apr 11, 2025
…mation-trigger-exit-range, a=testonly

Automatic update from web-platform-tests
[animation-trigger] Support auto for animation-trigger-exit-range

animation-trigger is a shorthand that specifies, among other
properties, 4 points that represent the boundaries at which the trigger
will act on its animation(s). The 4 points correspond to the CSS
properties:

 * animation-trigger-range-start
 * animation-trigger-range-end
 * animation-trigger-exit-range-start
 * animation-trigger-exit-range-end

The first 2 properties define the "trigger range" and the last two
define the "exit range." animation-trigger-exit-range is the shorthand
for the last two properties. The default value for the exit range
boundaries is "auto" which can mean one of two things:

1. Primarily,the meaning of auto is "match the trigger range."
2. In the case of animation-trigger-exit-range-end, if a named range,
   e.g. "contain" has been specified for
   animation-trigger-exit-range-start, then auto should be interpreted
   as the end of that named range, similar to normal for
   animation-range.

The slightly expands the meaning of normal so that the case of
"auto normal" has the same meaning as "auto auto", i.e. "match the
trigger range."

Note: This has not yet been resolved on by the CSS working group but it
is being discussed[2] and is how we're thinking about how it all should
work.

[1] https://drafts.csswg.org/css-animations-2/#animation-trigger-exit-range-start
[2] w3c/csswg-drafts#11932

Bug: 390314945
Change-Id: I3a76401e0bf40bebe2960b96d11ba96bb010e705
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6426886
Reviewed-by: Anders Hartvoll Ruud <[email protected]>
Commit-Queue: David Awogbemila <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1444687}

--

wpt-commits: c4a6052734703e2e17d99722e6486475d443c18f
wpt-pr: 51916
i3roly pushed a commit to i3roly/firefox-dynasty that referenced this issue Apr 11, 2025
…mation-trigger-exit-range, a=testonly

Automatic update from web-platform-tests
[animation-trigger] Support auto for animation-trigger-exit-range

animation-trigger is a shorthand that specifies, among other
properties, 4 points that represent the boundaries at which the trigger
will act on its animation(s). The 4 points correspond to the CSS
properties:

 * animation-trigger-range-start
 * animation-trigger-range-end
 * animation-trigger-exit-range-start
 * animation-trigger-exit-range-end

The first 2 properties define the "trigger range" and the last two
define the "exit range." animation-trigger-exit-range is the shorthand
for the last two properties. The default value for the exit range
boundaries is "auto" which can mean one of two things:

1. Primarily,the meaning of auto is "match the trigger range."
2. In the case of animation-trigger-exit-range-end, if a named range,
   e.g. "contain" has been specified for
   animation-trigger-exit-range-start, then auto should be interpreted
   as the end of that named range, similar to normal for
   animation-range.

The slightly expands the meaning of normal so that the case of
"auto normal" has the same meaning as "auto auto", i.e. "match the
trigger range."

Note: This has not yet been resolved on by the CSS working group but it
is being discussed[2] and is how we're thinking about how it all should
work.

[1] https://drafts.csswg.org/css-animations-2/#animation-trigger-exit-range-start
[2] w3c/csswg-drafts#11932

Bug: 390314945
Change-Id: I3a76401e0bf40bebe2960b96d11ba96bb010e705
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6426886
Reviewed-by: Anders Hartvoll Ruud <[email protected]>
Commit-Queue: David Awogbemila <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1444687}

--

wpt-commits: c4a6052734703e2e17d99722e6486475d443c18f
wpt-pr: 51916
aarongable pushed a commit to chromium/chromium that referenced this issue Apr 14, 2025
In crrev.com/c/6426886 we added support for parsing "auto" for the
animation-trigger-exit-range longhands, but didn't actually use use the
auto value in computing the exit range for the trigger. This cl does
that.

The auto keyword means that the exit range should match the
default/trigger range.

Note: This has not yet been resolved on by the CSS working group but it
is being discussed[2] and is how we're thinking about how it all should
work.

[1] https://drafts.csswg.org/css-animations-2/#animation-trigger-exit-range-start
[2] w3c/csswg-drafts#11932

Bug: 390314945
Change-Id: Ic397947bd40c1ae22df2339ae75c64e60787a0d9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6438242
Commit-Queue: David Awogbemila <[email protected]>
Reviewed-by: Kevin Ellis <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1446557}
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this issue Apr 16, 2025
…mation-trigger-exit-range, a=testonly

Automatic update from web-platform-tests
[animation-trigger] Support auto for animation-trigger-exit-range

animation-trigger is a shorthand that specifies, among other
properties, 4 points that represent the boundaries at which the trigger
will act on its animation(s). The 4 points correspond to the CSS
properties:

 * animation-trigger-range-start
 * animation-trigger-range-end
 * animation-trigger-exit-range-start
 * animation-trigger-exit-range-end

The first 2 properties define the "trigger range" and the last two
define the "exit range." animation-trigger-exit-range is the shorthand
for the last two properties. The default value for the exit range
boundaries is "auto" which can mean one of two things:

1. Primarily,the meaning of auto is "match the trigger range."
2. In the case of animation-trigger-exit-range-end, if a named range,
   e.g. "contain" has been specified for
   animation-trigger-exit-range-start, then auto should be interpreted
   as the end of that named range, similar to normal for
   animation-range.

The slightly expands the meaning of normal so that the case of
"auto normal" has the same meaning as "auto auto", i.e. "match the
trigger range."

Note: This has not yet been resolved on by the CSS working group but it
is being discussed[2] and is how we're thinking about how it all should
work.

[1] https://drafts.csswg.org/css-animations-2/#animation-trigger-exit-range-start
[2] w3c/csswg-drafts#11932

Bug: 390314945
Change-Id: I3a76401e0bf40bebe2960b96d11ba96bb010e705
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6426886
Reviewed-by: Anders Hartvoll Ruud <andruudchromium.org>
Commit-Queue: David Awogbemila <awogbemilachromium.org>
Cr-Commit-Position: refs/heads/main{#1444687}

--

wpt-commits: c4a6052734703e2e17d99722e6486475d443c18f
wpt-pr: 51916

UltraBlame original commit: b11cbb083e2b4c71390d19c19137baec901618f4
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this issue Apr 16, 2025
…mation-trigger-exit-range, a=testonly

Automatic update from web-platform-tests
[animation-trigger] Support auto for animation-trigger-exit-range

animation-trigger is a shorthand that specifies, among other
properties, 4 points that represent the boundaries at which the trigger
will act on its animation(s). The 4 points correspond to the CSS
properties:

 * animation-trigger-range-start
 * animation-trigger-range-end
 * animation-trigger-exit-range-start
 * animation-trigger-exit-range-end

The first 2 properties define the "trigger range" and the last two
define the "exit range." animation-trigger-exit-range is the shorthand
for the last two properties. The default value for the exit range
boundaries is "auto" which can mean one of two things:

1. Primarily,the meaning of auto is "match the trigger range."
2. In the case of animation-trigger-exit-range-end, if a named range,
   e.g. "contain" has been specified for
   animation-trigger-exit-range-start, then auto should be interpreted
   as the end of that named range, similar to normal for
   animation-range.

The slightly expands the meaning of normal so that the case of
"auto normal" has the same meaning as "auto auto", i.e. "match the
trigger range."

Note: This has not yet been resolved on by the CSS working group but it
is being discussed[2] and is how we're thinking about how it all should
work.

[1] https://drafts.csswg.org/css-animations-2/#animation-trigger-exit-range-start
[2] w3c/csswg-drafts#11932

Bug: 390314945
Change-Id: I3a76401e0bf40bebe2960b96d11ba96bb010e705
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6426886
Reviewed-by: Anders Hartvoll Ruud <andruudchromium.org>
Commit-Queue: David Awogbemila <awogbemilachromium.org>
Cr-Commit-Position: refs/heads/main{#1444687}

--

wpt-commits: c4a6052734703e2e17d99722e6486475d443c18f
wpt-pr: 51916

UltraBlame original commit: b11cbb083e2b4c71390d19c19137baec901618f4
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this issue Apr 16, 2025
…mation-trigger-exit-range, a=testonly

Automatic update from web-platform-tests
[animation-trigger] Support auto for animation-trigger-exit-range

animation-trigger is a shorthand that specifies, among other
properties, 4 points that represent the boundaries at which the trigger
will act on its animation(s). The 4 points correspond to the CSS
properties:

 * animation-trigger-range-start
 * animation-trigger-range-end
 * animation-trigger-exit-range-start
 * animation-trigger-exit-range-end

The first 2 properties define the "trigger range" and the last two
define the "exit range." animation-trigger-exit-range is the shorthand
for the last two properties. The default value for the exit range
boundaries is "auto" which can mean one of two things:

1. Primarily,the meaning of auto is "match the trigger range."
2. In the case of animation-trigger-exit-range-end, if a named range,
   e.g. "contain" has been specified for
   animation-trigger-exit-range-start, then auto should be interpreted
   as the end of that named range, similar to normal for
   animation-range.

The slightly expands the meaning of normal so that the case of
"auto normal" has the same meaning as "auto auto", i.e. "match the
trigger range."

Note: This has not yet been resolved on by the CSS working group but it
is being discussed[2] and is how we're thinking about how it all should
work.

[1] https://drafts.csswg.org/css-animations-2/#animation-trigger-exit-range-start
[2] w3c/csswg-drafts#11932

Bug: 390314945
Change-Id: I3a76401e0bf40bebe2960b96d11ba96bb010e705
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6426886
Reviewed-by: Anders Hartvoll Ruud <andruudchromium.org>
Commit-Queue: David Awogbemila <awogbemilachromium.org>
Cr-Commit-Position: refs/heads/main{#1444687}

--

wpt-commits: c4a6052734703e2e17d99722e6486475d443c18f
wpt-pr: 51916

UltraBlame original commit: b11cbb083e2b4c71390d19c19137baec901618f4
jamienicol pushed a commit to jamienicol/gecko that referenced this issue Apr 23, 2025
…mation-trigger-exit-range, a=testonly

Automatic update from web-platform-tests
[animation-trigger] Support auto for animation-trigger-exit-range

animation-trigger is a shorthand that specifies, among other
properties, 4 points that represent the boundaries at which the trigger
will act on its animation(s). The 4 points correspond to the CSS
properties:

 * animation-trigger-range-start
 * animation-trigger-range-end
 * animation-trigger-exit-range-start
 * animation-trigger-exit-range-end

The first 2 properties define the "trigger range" and the last two
define the "exit range." animation-trigger-exit-range is the shorthand
for the last two properties. The default value for the exit range
boundaries is "auto" which can mean one of two things:

1. Primarily,the meaning of auto is "match the trigger range."
2. In the case of animation-trigger-exit-range-end, if a named range,
   e.g. "contain" has been specified for
   animation-trigger-exit-range-start, then auto should be interpreted
   as the end of that named range, similar to normal for
   animation-range.

The slightly expands the meaning of normal so that the case of
"auto normal" has the same meaning as "auto auto", i.e. "match the
trigger range."

Note: This has not yet been resolved on by the CSS working group but it
is being discussed[2] and is how we're thinking about how it all should
work.

[1] https://drafts.csswg.org/css-animations-2/#animation-trigger-exit-range-start
[2] w3c/csswg-drafts#11932

Bug: 390314945
Change-Id: I3a76401e0bf40bebe2960b96d11ba96bb010e705
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6426886
Reviewed-by: Anders Hartvoll Ruud <[email protected]>
Commit-Queue: David Awogbemila <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1444687}

--

wpt-commits: c4a6052734703e2e17d99722e6486475d443c18f
wpt-pr: 51916
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants