- Notifications
You must be signed in to change notification settings - Fork 3.3k
/
Copy patherror.https.html
49 lines (43 loc) · 1.14 KB
/
error.https.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
<!DOCTYPE html>
<htmlclass=reftest-wait>
<linkrel="help" href="https://drafts.css-houdini.org/css-layout-api/#invoke-an-intrinsic-sizes-callback">
<linkrel="match" href="fallback-ref.html">
<metaname="assert" content="This test checks that a layout() class with a throwing intrinsicSizes function will fallback to block layout." />
<style>
.test {
background: red;
border: solid 2px;
width: min-content;
}
.float {
float: left;
height:100px;
width:50%;
}
.fc {
display: flow-root;
height:100px;
}
@supports (display:layout(throwing-intrinsic-sizes)) {
.test {
display:layout(throwing-intrinsic-sizes);
background: green;
}
}
</style>
<scriptsrc="/common/reftest-wait.js"></script>
<scriptsrc="/common/worklet-reftest.js"></script>
<divclass="test">
<divclass="float"></div>
<divclass="fc"></div>
</div>
<scriptid="code" type="text/worklet">
registerLayout('throwing-intrinsic-sizes',class{
asyncintrinsicSizes(){throwError('fail!');}
asynclayout(){}
});
</script>
<script>
importWorkletAndTerminateTestAfterAsyncPaint(CSS.layoutWorklet,document.getElementById('code').textContent);
</script>
</html>