Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(214)

Unified Diff: LayoutTests/animations/interpolation/clip-interpolation.html

Issue 22799020: Web Animations CSS: Support Animation of StyleImage and LengthBox (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebased Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « LayoutTests/TestExpectations ('k') | LayoutTests/animations/interpolation/clip-interpolation-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/animations/interpolation/clip-interpolation.html
diff --git a/LayoutTests/animations/interpolation/clip-interpolation.html b/LayoutTests/animations/interpolation/clip-interpolation.html
new file mode 100644
index 0000000000000000000000000000000000000000..8e25f7b9a05cfa7b75c5cd4bf6fddb33e0105b76
--- /dev/null
+++ b/LayoutTests/animations/interpolation/clip-interpolation.html
@@ -0,0 +1,79 @@
+<!DOCTYPE html>
+<body>
+<style>
+.target {
+ width: 80px;
+ height: 80px;
+ display: inline-block;
+ position: absolute;
+ /* FIXME: Remove when interpolation of clip is fixed: http://crbug.com/279684 */
+ clip: rect(auto, auto, auto, auto);
+ top: 300px;
+}
+.active { background: red; }
+.replica { background: black; }
+.test-1-1 { left: 0px; }
+.test-1-2 { left: 100px; }
+.test-1-3 { left: 200px; }
+.test-1-4 { left: 300px; }
+.test-1-5 { left: 400px; }
+
+.test-2-1 { left: 510px; }
+.test-2-2 { left: 610px; }
+
+.test-3-1 { left: 720px; }
+.test-3-2 { left: 820px; }
+.test-3-3 { left: 920px; }
+.test-3-4 { left: 1020px; }
+
+.test-4-1, .test-4-2, .test-4-3, .test-4-4 { clip: auto; }
+.test-4-1 { left: 1130px; }
+.test-4-2 { left: 1230px; }
+.test-4-3 { left: 1130px; }
+.test-4-4 { left: 1230px; }
+</style>
+<script src="resources/interpolation-test.js"></script>
+<script>
+assertInterpolation({
+ property: 'clip',
+ from: 'rect(0px, 75px, 80px, 10px)',
+ to: 'rect(0px, 100px, 90px, 5px)'
+}, [
+ {at: -1, is: 'rect(0px, 50px, 70px, 15px)'},
+ {at: 0, is: 'rect(0px, 75px, 80px, 10px)'},
+ {at: 0.5, is: 'rect(0px, 87.5px, 85px, 7.5px)'},
+ {at: 1, is: 'rect(0px, 100px, 90px, 5px)'},
+ {at: 1.5, is: 'rect(0px, 112.5px, 95px, 2.5px)'},
+]);
+
+assertInterpolation({
+ property: 'clip',
+ from: 'rect(auto, auto, auto, 10px)',
+ to: 'rect(20px, 50px, 50px, auto)'
+}, [
+ {at: 0.4, is: 'rect(0px, 0px, 0px, 10px)'},
+ {at: 0.6, is: 'rect(20px, 50px, 50px, 0px)'}
+]);
+
+assertInterpolation({
+ property: 'clip',
+ from: 'rect(auto, 0px, auto, 10px)',
+ to: 'rect(auto, 50px, 50px, auto)'
+}, [
+ {at: -1, is: 'rect(0px, -50px, 0px, 10px)'},
+ {at: 0.4, is: 'rect(0px, 20px, 0px, 10px)'},
+ {at: 0.6, is: 'rect(0px, 30px, 50px, 0px)'},
+ {at: 2, is: 'rect(0px, 100px, 50px, 0px)'}
+]);
+
+assertInterpolation({
+ property: 'clip',
+ from: 'auto',
+ to: 'rect(0px, 50px, 50px, 0px)'
+}, [
+ {at: -1, is: 'auto'},
+ {at: 0.25, is: 'auto'},
+ {at: 0.75, is: 'rect(0px, 50px, 50px, 0px)'},
+ {at: 2, is: 'rect(0px, 50px, 50px, 0px)'}
+]);
+</script>
« no previous file with comments | « LayoutTests/TestExpectations ('k') | LayoutTests/animations/interpolation/clip-interpolation-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698