WebKit Bugzilla
Attachment 341744 Details for
Bug 186129
: REGRESSION (r232186): Hardware-accelerated CSS animations using steps() timing function no longer work
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
Testcase
186129.html (text/html), 1.55 KB, created by
Frédéric Wang (:fredw)
on 2018-06-01 01:02:17 PDT
(
hide
)
Description:
Testcase
Filename:
MIME Type:
Creator:
Frédéric Wang (:fredw)
Created:
2018-06-01 01:02:17 PDT
Size:
1.55 KB
patch
obsolete
><!DOCTYPE html> ><html> > <head> > <meta charset="utf-8"> > <title>animation steps timing function</title> > <style> > #container { > position: absolute; > left: 0; > top: 3em; > } > #squareLinear, #squareSteps { > width: 100px; > height: 100px; > background: blue; > position: absolute; > left: -50px; > } > #squareLinear { > top: 0px; > animation: move 2s linear infinite; > } > #squareSteps { > top: 150px; > animation: move 2s steps(4) infinite; > } > @keyframes move > { > 100% { > transform: translate(500px); > } > } > </style> > <script> > var start = null, index; > var animationDuration = 2000; > var stepCount = 4; > function logTransformMatrix(id) { > console.log(`${id}:`, window.getComputedStyle(document.getElementById(id)).getPropertyValue("transform")); > } > function step(timestamp) { > if (!start) { > start = timestamp; > index = 1; > } > var progress = timestamp - start; > if (progress > animationDuration * index / stepCount) { > console.log(`progress: ${progress}`); > logTransformMatrix("squareLinear"); > logTransformMatrix("squareSteps"); > index++; > } > window.requestAnimationFrame(step); > } > function runTest() { > window.requestAnimationFrame(step); > } > </script> > </head> > <body onload="runTest()"> > <div id="container"> > <div id="squareLinear"></div> > <div id="squareSteps"></div> > </div> > </body> ></html>
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>animation steps timing function</title> <style> #container { position: absolute; left: 0; top: 3em; } #squareLinear, #squareSteps { width: 100px; height: 100px; background: blue; position: absolute; left: -50px; } #squareLinear { top: 0px; animation: move 2s linear infinite; } #squareSteps { top: 150px; animation: move 2s steps(4) infinite; } @keyframes move { 100% { transform: translate(500px); } } </style> <script> var start = null, index; var animationDuration = 2000; var stepCount = 4; function logTransformMatrix(id) { console.log(`${id}:`, window.getComputedStyle(document.getElementById(id)).getPropertyValue("transform")); } function step(timestamp) { if (!start) { start = timestamp; index = 1; } var progress = timestamp - start; if (progress > animationDuration * index / stepCount) { console.log(`progress: ${progress}`); logTransformMatrix("squareLinear"); logTransformMatrix("squareSteps"); index++; } window.requestAnimationFrame(step); } function runTest() { window.requestAnimationFrame(step); } </script> </head> <body onload="runTest()"> <div id="container"> <div id="squareLinear"></div> <div id="squareSteps"></div> </div> </body> </html>
View Attachment As Raw
Actions:
View
Attachments on
bug 186129
:
341648
|
341744
|
342943
|
344178
|
344186