| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <meta charset="UTF-8"> | 2 <meta charset="UTF-8"> |
| 3 <style> | 3 <style> |
| 4 .parent { | 4 .parent { |
| 5 max-width: 100px; | 5 max-width: 100px; |
| 6 } | 6 } |
| 7 .target { | 7 .target { |
| 8 width: 200px; | 8 width: 200px; |
| 9 height: 10px; | 9 height: 10px; |
| 10 background-color: black; | 10 background-color: black; |
| 11 max-width: 10px; | 11 max-width: 10px; |
| 12 } | 12 } |
| 13 .expected { | 13 .expected { |
| 14 background-color: green; | 14 background-color: green; |
| 15 margin-bottom: 10px; | 15 margin-bottom: 10px; |
| 16 } | 16 } |
| 17 </style> | 17 </style> |
| 18 <body> | 18 <body> |
| 19 <script src="resources/interpolation-test.js"></script> | 19 <script src="resources/interpolation-test.js"></script> |
| 20 <script> | 20 <script> |
| 21 assertInterpolation({ | 21 assertInterpolation({ |
| 22 property: 'max-width', | 22 property: 'max-width', |
| 23 from: '', | 23 from: neutralKeyframe, |
| 24 to: '20px', | 24 to: '20px', |
| 25 }, [ | 25 }, [ |
| 26 {at: -0.5, is: '5px'}, | 26 {at: -0.5, is: '5px'}, |
| 27 {at: 0, is: '10px'}, | 27 {at: 0, is: '10px'}, |
| 28 {at: 0.3, is: '13px'}, | 28 {at: 0.3, is: '13px'}, |
| 29 {at: 0.6, is: '16px'}, | 29 {at: 0.6, is: '16px'}, |
| 30 {at: 1, is: '20px'}, | 30 {at: 1, is: '20px'}, |
| 31 {at: 1.5, is: '25px'}, | 31 {at: 1.5, is: '25px'}, |
| 32 ]); | 32 ]); |
| 33 | 33 |
| (...skipping 30 matching lines...) Expand all Loading... |
| 64 }, [ | 64 }, [ |
| 65 {at: -0.5, is: '0'}, // CSS max-width can't be negative. | 65 {at: -0.5, is: '0'}, // CSS max-width can't be negative. |
| 66 {at: 0, is: '0'}, | 66 {at: 0, is: '0'}, |
| 67 {at: 0.3, is: '30px'}, | 67 {at: 0.3, is: '30px'}, |
| 68 {at: 0.6, is: '60px'}, | 68 {at: 0.6, is: '60px'}, |
| 69 {at: 1, is: '100px'}, | 69 {at: 1, is: '100px'}, |
| 70 {at: 1.5, is: '150px'} | 70 {at: 1.5, is: '150px'} |
| 71 ]); | 71 ]); |
| 72 </script> | 72 </script> |
| 73 </body> | 73 </body> |
| OLD | NEW |