OLD | NEW |
(Empty) | |
| 1 <!DOCTYPE html> |
| 2 <meta charset="UTF-8"> |
| 3 <style> |
| 4 .container { |
| 5 font-size: 10px; |
| 6 } |
| 7 .target { |
| 8 display: inline-block; |
| 9 font: 100px sans-serif; |
| 10 } |
| 11 .replica { |
| 12 color: green; |
| 13 margin-right: 30px; |
| 14 } |
| 15 </style> |
| 16 <body> |
| 17 <template id="target-template"> |
| 18 <span class="container"> |
| 19 <div class="target">TT</div> |
| 20 </span> |
| 21 </template> |
| 22 <script src="../testharness/testharness.js"></script> |
| 23 <script src="../testharness/testharnessreport.js"></script> |
| 24 <script src="resources/interpolation-test.js"></script> |
| 25 <script> |
| 26 assertInterpolation({ |
| 27 property: 'font-size', |
| 28 from: '4px', |
| 29 to: '14px' |
| 30 }, [ |
| 31 {at: -2, is: '0px'}, // CSS font-size can't be negative. |
| 32 {at: -0.3, is: '1px'}, |
| 33 {at: 0, is: '4px'}, |
| 34 {at: 0.3, is: '7px'}, |
| 35 {at: 0.6, is: '10px'}, |
| 36 {at: 1, is: '14px'}, |
| 37 {at: 1.5, is: '19px'}, |
| 38 ]); |
| 39 |
| 40 // The minifill does not support inherit. |
| 41 // assertInterpolation({ |
| 42 // property: 'font-size', |
| 43 // from: 'inherit', |
| 44 // to: '20px' |
| 45 // }, [ |
| 46 // {at: -2, is: '0px'}, // CSS font-size can't be negative. |
| 47 // {at: -0.3, is: '7px'}, |
| 48 // {at: 0, is: '10px'}, |
| 49 // {at: 0.3, is: '13px'}, |
| 50 // {at: 0.6, is: '16px'}, |
| 51 // {at: 1, is: '20px'}, |
| 52 // {at: 1.5, is: '25px'}, |
| 53 // ]); |
| 54 </script> |
| 55 </body> |
OLD | NEW |