mirror of
https://github.com/servo/servo.git
synced 2025-08-02 04:00:32 +01:00
style: Fix timing-function overriding from the keyframe declaration list.
The previous behavior is plain wrong, since that array has always at least one element, so we effectively couldn't specify anything else than "ease" in our animations.
This commit is contained in:
parent
8bbebd0514
commit
8ba676533b
3 changed files with 44 additions and 1 deletions
|
@ -0,0 +1,23 @@
|
|||
<!doctype html>
|
||||
<meta charset="utf-8">
|
||||
<style>
|
||||
@keyframes foo {
|
||||
from { background: white; animation-timing-function: ease; }
|
||||
to { background: black; }
|
||||
}
|
||||
|
||||
@keyframes bar {
|
||||
from { background: white }
|
||||
to { background: black }
|
||||
}
|
||||
|
||||
div {
|
||||
height: 50px;
|
||||
width: 100px;
|
||||
animation: foo 1s infinite steps(4, end);
|
||||
}
|
||||
.bar { animation-name: bar }
|
||||
</style>
|
||||
<p>You should see an eased animation in the first-element, and a stepped one in the second one</p>
|
||||
<div></div>
|
||||
<div class="bar"></div>
|
Loading…
Add table
Add a link
Reference in a new issue