Skip to content

Commit

Permalink
[css-easing-2] Whoops, use the *last* output when multiple points hav…
Browse files Browse the repository at this point in the history
…e the same input, rather than the *largest* output.
  • Loading branch information
tabatkins committed Sep 12, 2024
1 parent 1d5bb67 commit c269215
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions css-easing-2/Overview.bs
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,7 @@ Output</h4>

3. If at least one of |points| has an [=input progress value=]
matching |inputProgress|,
return the largest [=output progress value=] from among them.
return the [=output progress value=] of the last such point.

4. Otherwise, find two [=linear()/control points=],
|A| and |B|,
Expand All @@ -317,11 +317,9 @@ Output</h4>
If |A| and |B| have the same [=input progress value=],
return |B|'s [=output progress value=].

3. Otherwise, let |A| be the [=linear()/control point=]
with the largest [=output progress value=]
3. Otherwise, let |A| be the last [=linear()/control point=]
whose [=input progress value=] is smaller than |inputProgress|,
and let |B| be the [=linear()/control point=]
with the smallest [=output progress value=]
and let |B| be the first [=linear()/control point=]
whose [=input progress value=] is larger than |inputProgress|.

5. Linearly interpolate (or extrapolate) |inputProgress|
Expand Down

0 comments on commit c269215

Please sign in to comment.