4 <script src=
"/js-test-resources/ahem.js"></script>
6 window
.onload = function() {
7 // fetch offsetTop to force a layout
8 document
.body
.offsetTop
;
10 var el
= document
.querySelector('#add-shape-image-threshold .shape');
11 el
.style
.setProperty('shape-image-threshold', 0.25);
12 el
.className
= 'shape threshold25';
14 el
= document
.querySelector('#change-shape-image-threshold .shape');
15 el
.className
= 'shape threshold75';
17 el
= document
.querySelector('#remove-shape-image-threshold .shape');
18 el
.className
= 'shape';
20 console
.log('accomplished!');
27 overflow-wrap: break-word;
28 border:
2px solid blue;
29 font:
50px/
1 Ahem, sans-serif;
38 shape-outside: url('../resources/svg-shape-
002.svg');
46 background-color: blue;
51 shape-image-threshold:
0.26;
53 .threshold25::before {
58 shape-image-threshold:
0.76;
60 .threshold75::before {
66 <p>When shape-image-threshold is modified dynamically, content affected by the shape's contour should relayout. For each test, you should see green blocks separated by white space, wrapping around a blue rectangle in the upper left. This test requires the Ahem font.
</p>
68 <p>Setting shape-image-threshold with no prior entry
</p>
69 <div id='add-shape-image-threshold' class='container'
><div class='shape'
></div>x x x x x x x x x x
</div>
71 <p>Setting shape-image-threshold with a prior entry
</p>
72 <div id='change-shape-image-threshold' class='container'
><div class='shape threshold25'
></div>x x x x x x x x x x
</div>
74 <p>Removing shape-image-threshold with a prior entry
</p>
75 <div id='remove-shape-image-threshold' class='container'
><div class='shape threshold25'
></div>x x x x x x x x x x
</div>