OLD | NEW |
| (Empty) |
1 <!DOCTYPE html> | |
2 <script src="../responsive/resources/responsive-test.js"></script> | |
3 <script> | |
4 assertSVGResponsive({ | |
5 targetTag: 'path', | |
6 property: 'd', | |
7 getter(target) { | |
8 return target.getAttribute('d'); | |
9 }, | |
10 from: 'm 10 10 h 100', | |
11 to: neutralKeyframe, | |
12 configurations: [{ | |
13 state: {underlying: 'M 30 30 H 250'}, | |
14 expect: [ | |
15 {at: 0.25, is: 'M 15 15 H 145'}, | |
16 {at: 0.75, is: 'M 25 25 H 215'}, | |
17 ], | |
18 }, { | |
19 state: {underlying: 'm 30 30 h 200'}, | |
20 expect: [ | |
21 {at: 0.25, is: 'm 15 15 h 125'}, | |
22 {at: 0.75, is: 'm 25 25 h 175'}, | |
23 ], | |
24 }, { | |
25 state: {underlying: 'M 30 30 L 100 100'}, | |
26 expect: [ | |
27 {at: 0.25, is: 'm 10 10 h 100'}, | |
28 {at: 0.75, is: 'M 30 30 L 100 100'}, | |
29 ], | |
30 }], | |
31 }); | |
32 | |
33 assertSVGResponsive({ | |
34 targetTag: 'path', | |
35 property: 'd', | |
36 getter(target) { | |
37 return target.getAttribute('d'); | |
38 }, | |
39 from: '', | |
40 to: neutralKeyframe, | |
41 configurations: [{ | |
42 state: {underlying: 'm 10 10 h 100'}, | |
43 expect: [ | |
44 {at: 0.25, is: ''}, | |
45 {at: 0.75, is: 'm 10 10 h 100'}, | |
46 ], | |
47 }], | |
48 }); | |
49 </script> | |
OLD | NEW |