|
6 | 6 | <style>
|
7 | 7 | #t1 {
|
8 | 8 | font-size: 20px;
|
9 |
| - cursor: url(cur.ico) calc(7 * sign(1em - 18px)) 0, auto; |
| 9 | + cursor: url(data:image/x-icon,) calc(7 * sign(1em - 18px)) 0, auto; |
10 | 10 | }
|
11 | 11 | #t2 {
|
12 |
| - cursor: url(cur.ico) calc(4 * sibling-index()) 0, auto; |
| 12 | + cursor: url(data:image/x-icon,) calc(4 * sibling-index()) 0, auto; |
| 13 | + } |
| 14 | + #t3 { |
| 15 | + cursor: url(data:image/x-icon,) calc(9) 0, auto; |
| 16 | + } |
| 17 | + #t4 { |
| 18 | + cursor: url(data:image/x-icon,) calc(10 * sign(2px)) 0, auto; |
13 | 19 | }
|
14 | 20 | </style>
|
15 | 21 | <div>
|
16 | 22 | <div id="t1"></div>
|
17 | 23 | <div id="t2"></div>
|
| 24 | + <div id="t3"></div> |
| 25 | + <div id="t4"></div> |
18 | 26 | </div>
|
19 | 27 | <script>
|
20 | 28 | test(() => {
|
21 |
| - assert_equals(getComputedStyle(t1).cursor, "url(cur.ico) 7 0, auto"); |
| 29 | + assert_equals(getComputedStyle(t1).cursor, 'url("data:image/x-icon,") 7 0, auto'); |
22 | 30 | }, "cursor hotspot with sign() depending on font relative units");
|
23 | 31 |
|
24 | 32 | test(() => {
|
25 |
| - assert_equals(getComputedStyle(t2).cursor, "url(cur.ico) 8 0, auto"); |
| 33 | + assert_equals(getComputedStyle(t2).cursor, 'url("data:image/x-icon,") 8 0, auto'); |
26 | 34 | }, "cursor hotspot depending on sibling-index()");
|
| 35 | + |
| 36 | + test(() => { |
| 37 | + assert_equals(getComputedStyle(t3).cursor, 'url("data:image/x-icon,") 9 0, auto'); |
| 38 | + }, "cursor hotspot depending on simplified numeric calc()"); |
| 39 | + |
| 40 | + test(() => { |
| 41 | + assert_equals(getComputedStyle(t4).cursor, 'url("data:image/x-icon,") 10 0, auto'); |
| 42 | + }, "cursor hotspot depending on simplified numeric calc() with sign()"); |
27 | 43 | </script>
|
0 commit comments