Skip to content

Commit 30e724a

Browse files
dbaronchromium-wpt-export-bot
authored andcommitted
Use interpolation at the endpoints of animations.
Use interpolation at the endpoints of animations (by removing various optimizations to return the endpoint values at the endpoints), since it's needed to get the correct axis for animation of the 'rotate' property, the correct conversion away from a 'none' value at one endpoint for the 'rotate', 'scale', and 'translate' properties, and correct list lengths for list-valued properties that can interpolate between lists of mismatched lengths, whether by repeating to the least common multiple length (stroke-dasharray) or filling the shorter list with no-op or zero values (filter, backdrop-filter, box-shadow, text-shadow, some registered custom properties). The changes to translate-composition.html and scale-composition.html cause Firefox to pass the tests whose expectations are being modified, and thus, like Chrome, pass the entire file (whereas they cause Safari to fail additional tests). The test changes are discussed further in #30377 . The differences between the test expectations for background-image (where the test expects discrete animation, per the spec) and for -webkit-mask-image (where the test expects -webkit-cross-fade()) is rather suspicious, but I've left the difference as-is for now. Fixed: 1026169, 1180834 Change-Id: I6320b74b0aff29989a748fab1bff78b91426701e Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3139948 Reviewed-by: Kevin Ellis <[email protected]> Reviewed-by: Anders Hartvoll Ruud <[email protected]> Commit-Queue: David Baron <[email protected]> Cr-Commit-Position: refs/heads/main@{#923427}
1 parent 44799e1 commit 30e724a

File tree

5 files changed

+17
-15
lines changed

5 files changed

+17
-15
lines changed

css/css-backgrounds/animations/box-shadow-composition.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@
8787
{at: -0.3, expect: 'rgb(0, 0, 0) -4.7px -9.4px 0px -18.8px, rgb(26, 52, 78) 2.6px 5.2px 7.8px 10.4px, rgb(130, 130, 130) 13px 26px 39px 52px'},
8888
{at: 0, expect: 'rgb(10, 20, 30) 1px 2px 3px 4px, rgb(20, 40, 60) 2px 4px 6px 8px, rgb(100, 100, 100) 10px 20px 30px 40px'},
8989
{at: 0.5, expect: 'rgb(105, 110, 115) 10.5px 21px 31.5px 42px, rgba(20, 40, 60, 0.5) 1px 2px 3px 4px, rgba(100, 100, 100, 0.5) 5px 10px 15px 20px'},
90-
{at: 1, expect: 'rgb(200, 200, 200) 20px 40px 60px 80px'},
90+
{at: 1, expect: 'rgb(200, 200, 200) 20px 40px 60px 80px, rgba(0, 0, 0, 0) 0px 0px 0px 0px, rgba(0, 0, 0, 0) 0px 0px 0px 0px'},
9191
{at: 1.5, expect: 'rgb(255, 255, 255) 29.5px 59px 88.5px 118px, rgba(0, 0, 0, 0) -1px -2px 0px -4px, rgba(0, 0, 0, 0) -5px -10px 0px -20px'},
9292
]);
9393
test_composition({
@@ -97,7 +97,7 @@
9797
addTo: 'rgb(200, 200, 200) 20px 40px 60px 80px',
9898
}, [
9999
{at: -0.3, expect: 'rgb(127, 124, 121) 12.7px 25.4px 38.1px 50.8px, rgba(0, 0, 0, 0) -0.6px -1.2px 0px -2.4px, rgba(0, 0, 0, 0) -6px -12px 0px -24px'},
100-
{at: 0, expect: 'rgb(100, 100, 100) 10px 20px 30px 40px'},
100+
{at: 0, expect: 'rgb(100, 100, 100) 10px 20px 30px 40px, rgba(0, 0, 0, 0) 0px 0px 0px 0px, rgba(0, 0, 0, 0) 0px 0px 0px 0px'},
101101
{at: 0.5, expect: 'rgb(55, 60, 65) 5.5px 11px 16.5px 22px, rgba(20, 40, 60, 0.5) 1px 2px 3px 4px, rgba(200, 200, 200, 0.5) 10px 20px 30px 40px'},
102102
{at: 1, expect: 'rgb(10, 20, 30) 1px 2px 3px 4px, rgb(20, 40, 60) 2px 4px 6px 8px, rgb(200, 200, 200) 20px 40px 60px 80px'},
103103
{at: 1.5, expect: 'rgb(0, 0, 0) -3.5px -7px 0px -14px, rgb(30, 60, 90) 3px 6px 9px 12px, rgb(255, 255, 255) 30px 60px 90px 120px'},
@@ -111,7 +111,7 @@
111111
{at: -0.3, expect: 'rgb(0, 0, 0) -4.7px -9.4px 0px -18.8px, rgb(26, 52, 78) 2.6px 5.2px 7.8px 10.4px, rgb(52, 104, 156) 5.2px 10.4px 15.6px 20.8px, rgb(130, 130, 130) 13px 26px 39px 52px, rgb(255, 255, 255) 26px 52px 78px 104px'},
112112
{at: 0, expect: 'rgb(10, 20, 30) 1px 2px 3px 4px, rgb(20, 40, 60) 2px 4px 6px 8px, rgb(40, 80, 120) 4px 8px 12px 16px, rgb(100, 100, 100) 10px 20px 30px 40px, rgb(200, 200, 200) 20px 40px 60px 80px'},
113113
{at: 0.5, expect: 'rgb(105, 110, 115) 10.5px 21px 31.5px 42px, rgba(20, 40, 60, 0.5) 1px 2px 3px 4px, rgba(40, 80, 120, 0.5) 2px 4px 6px 8px, rgba(100, 100, 100, 0.5) 5px 10px 15px 20px, rgba(200, 200, 200, 0.5) 10px 20px 30px 40px'},
114-
{at: 1, expect: 'rgb(200, 200, 200) 20px 40px 60px 80px'},
114+
{at: 1, expect: 'rgb(200, 200, 200) 20px 40px 60px 80px, rgba(0, 0, 0, 0) 0px 0px 0px 0px, rgba(0, 0, 0, 0) 0px 0px 0px 0px, rgba(0, 0, 0, 0) 0px 0px 0px 0px, rgba(0, 0, 0, 0) 0px 0px 0px 0px'},
115115
{at: 1.5, expect: 'rgb(255, 255, 255) 29.5px 59px 88.5px 118px, rgba(0, 0, 0, 0) -1px -2px 0px -4px, rgba(0, 0, 0, 0) -2px -4px 0px -8px, rgba(0, 0, 0, 0) -5px -10px 0px -20px, rgba(0, 0, 0, 0) -10px -20px 0px -40px'},
116116
]);
117117
</script>

css/css-transforms/animation/rotate-composition.html

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,8 @@
125125
comparisonFunction: compareRotations
126126
}, [
127127
{at: -1, expect: '0 -1 0 100deg'},
128-
{at: 0, expect: '0.27 0.53 0.8 360deg'},
128+
// Accept both the SLERP and the common axis solution, which are equivalent.
129+
{at: 0, expect: '0.27 0.53 0.8 360deg', option: '0.27 0.53 0.8 0deg'},
129130
{at: 0.25, expect: 'y 25deg'},
130131
{at: 0.75, expect: 'y 75deg'},
131132
{at: 1, expect: 'y 100deg'},
@@ -141,7 +142,8 @@
141142
comparisonFunction: compareRotations
142143
}, [
143144
{at: -1, expect: '0 -1 0 100deg'},
144-
{at: 0, expect: '0.27 0.53 0.8 360deg'},
145+
// Accept both the SLERP and the common axis solution, which are equivalent.
146+
{at: 0, expect: '0.27 0.53 0.8 360deg', option: '0.27 0.53 0.8 0deg'},
145147
{at: 0.25, expect: 'y 25deg'},
146148
{at: 0.75, expect: 'y 75deg'},
147149
{at: 1, expect: 'y 100deg'},

css/css-transforms/animation/scale-composition.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@
6464
{at: 0, expect: '4 5 6'},
6565
{at: 0.25, expect: '3.25 4 4.75'},
6666
{at: 0.75, expect: '1.75 2 2.25'},
67-
{at: 1, expect: 'none'},
67+
{at: 1, expect: '1'},
6868
{at: 2, expect: '-2 -3 -4'},
6969
]);
7070

@@ -94,7 +94,7 @@
9494
{at: 0.25, expect: '3.25 7.75 13.75'},
9595
{at: 0.5, expect: '2.5 5.5 9.5'},
9696
{at: 0.75, expect: '1.75 3.25 5.25'},
97-
{at: 1, expect: 'none'},
97+
{at: 1, expect: '1'},
9898
{at: 1.5, expect: '-0.5 -3.5 -7.5'},
9999
]);
100100
</script>

css/css-transforms/animation/translate-composition.html

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@
6565
addTo: '100px',
6666
}, [
6767
{at: -1, expect: '-100px'},
68-
{at: 0, expect: 'none'},
68+
{at: 0, expect: '0px'},
6969
{at: 0.25, expect: '25px'},
7070
{at: 0.75, expect: '75px'},
7171
{at: 1, expect: '100px'},
@@ -79,7 +79,7 @@
7979
addTo: '100px',
8080
}, [
8181
{at: -1, expect: '-100px'},
82-
{at: 0, expect: 'none'},
82+
{at: 0, expect: '0px'},
8383
{at: 0.25, expect: '25px'},
8484
{at: 0.75, expect: '75px'},
8585
{at: 1, expect: '100px'},
@@ -96,7 +96,7 @@
9696
{at: 0, expect: '0px 40px 60px'},
9797
{at: 0.25, expect: '0px 30px 45px'},
9898
{at: 0.75, expect: '0px 10px 15px'},
99-
{at: 1, expect: 'none'},
99+
{at: 1, expect: '0px'},
100100
{at: 2, expect: '0px -40px -60px'},
101101
]);
102102

@@ -110,7 +110,7 @@
110110
{at: 0, expect: '0px 40px 60px'},
111111
{at: 0.25, expect: '0px 30px 45px'},
112112
{at: 0.75, expect: '0px 10px 15px'},
113-
{at: 1, expect: 'none'},
113+
{at: 1, expect: '0px'},
114114
{at: 2, expect: '0px -40px -60px'},
115115
]);
116116

@@ -140,7 +140,7 @@
140140
{at: 0.25, expect: '60px 45px 45px'},
141141
{at: 0.5, expect: '40px 30px 30px'},
142142
{at: 0.75, expect: '20px 15px 15px'},
143-
{at: 1, expect: 'none'},
143+
{at: 1, expect: '0px'},
144144
{at: 2, expect: '-80px -60px -60px'},
145145
]);
146146
</script>

css/css-transitions/animations/text-shadow-composition.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@
6868
{at: -0.3, expect: 'rgb(0, 0, 0) -4.7px -9.4px 0px, rgb(26, 52, 78) 2.6px 5.2px 7.8px, rgb(130, 130, 130) 13px 26px 39px'},
6969
{at: 0, expect: 'rgb(10, 20, 30) 1px 2px 3px, rgb(20, 40, 60) 2px 4px 6px, rgb(100, 100, 100) 10px 20px 30px'},
7070
{at: 0.5, expect: 'rgb(105, 110, 115) 10.5px 21px 31.5px, rgba(20, 40, 60, 0.5) 1px 2px 3px, rgba(100, 100, 100, 0.5) 5px 10px 15px'},
71-
{at: 1, expect: 'rgb(200, 200, 200) 20px 40px 60px'},
71+
{at: 1, expect: 'rgb(200, 200, 200) 20px 40px 60px, rgba(0, 0, 0, 0) 0px 0px 0px, rgba(0, 0, 0, 0) 0px 0px 0px'},
7272
{at: 1.5, expect: 'rgb(255, 255, 255) 29.5px 59px 88.5px, rgba(0, 0, 0, 0) -1px -2px 0px, rgba(0, 0, 0, 0) -5px -10px 0px'},
7373
]);
7474

@@ -79,7 +79,7 @@
7979
addTo: 'rgb(200, 200, 200) 20px 40px 60px',
8080
}, [
8181
{at: -0.3, expect: 'rgb(127, 124, 121) 12.7px 25.4px 38.1px, rgba(0, 0, 0, 0) -0.6px -1.2px 0px, rgba(0, 0, 0, 0) -6px -12px 0px'},
82-
{at: 0, expect: 'rgb(100, 100, 100) 10px 20px 30px'},
82+
{at: 0, expect: 'rgb(100, 100, 100) 10px 20px 30px, rgba(0, 0, 0, 0) 0px 0px 0px, rgba(0, 0, 0, 0) 0px 0px 0px'},
8383
{at: 0.5, expect: 'rgb(55, 60, 65) 5.5px 11px 16.5px, rgba(20, 40, 60, 0.5) 1px 2px 3px, rgba(200, 200, 200, 0.5) 10px 20px 30px'},
8484
{at: 1, expect: 'rgb(10, 20, 30) 1px 2px 3px, rgb(20, 40, 60) 2px 4px 6px, rgb(200, 200, 200) 20px 40px 60px'},
8585
{at: 1.5, expect: 'rgb(0, 0, 0) -3.5px -7px 0px, rgb(30, 60, 90) 3px 6px 9px, rgb(255, 255, 255) 30px 60px 90px'},
@@ -94,7 +94,7 @@
9494
{at: -0.3, expect: 'rgb(0, 0, 0) -4.7px -9.4px 0px, rgb(26, 52, 78) 2.6px 5.2px 7.8px, rgb(52, 104, 156) 5.2px 10.4px 15.6px, rgb(130, 130, 130) 13px 26px 39px, rgb(255, 255, 255) 26px 52px 78px'},
9595
{at: 0, expect: 'rgb(10, 20, 30) 1px 2px 3px, rgb(20, 40, 60) 2px 4px 6px, rgb(40, 80, 120) 4px 8px 12px, rgb(100, 100, 100) 10px 20px 30px, rgb(200, 200, 200) 20px 40px 60px'},
9696
{at: 0.5, expect: 'rgb(105, 110, 115) 10.5px 21px 31.5px, rgba(20, 40, 60, 0.5) 1px 2px 3px, rgba(40, 80, 120, 0.5) 2px 4px 6px, rgba(100, 100, 100, 0.5) 5px 10px 15px, rgba(200, 200, 200, 0.5) 10px 20px 30px'},
97-
{at: 1, expect: 'rgb(200, 200, 200) 20px 40px 60px'},
97+
{at: 1, expect: 'rgb(200, 200, 200) 20px 40px 60px, rgba(0, 0, 0, 0) 0px 0px 0px, rgba(0, 0, 0, 0) 0px 0px 0px, rgba(0, 0, 0, 0) 0px 0px 0px, rgba(0, 0, 0, 0) 0px 0px 0px'},
9898
{at: 1.5, expect: 'rgb(255, 255, 255) 29.5px 59px 88.5px, rgba(0, 0, 0, 0) -1px -2px 0px, rgba(0, 0, 0, 0) -2px -4px 0px, rgba(0, 0, 0, 0) -5px -10px 0px, rgba(0, 0, 0, 0) -10px -20px 0px'},
9999
]);
100100
</script>

0 commit comments

Comments
 (0)