ladybird/Tests/LibWeb/Ref/expected/font-face-descriptor-relative-length-iframe-ref.html
Callum Law 3708fc6aa7 LibWeb: Resolve relative lengths in @font-face using correct viewport
As with everywhere else we should be using the document rather than the
window's viewports.

Fixes #6467
2025-10-16 10:27:32 +01:00

35 lines
993 B
HTML

<!DOCTYPE html>
<html class="reftest-wait">
<body>
<iframe
id="iframe"
width="500"
srcdoc="
<!DOCTYPE html>
<html>
<style>
@font-face {
font-family: test;
src: url(../data/pass.woff) format(woff);
}
#foo {
font-family: test;
}
</style>
<body>
<p>Test passes if the word PASS appears below.</p>
<p id='foo'>P</p>
</body>
</html>"
onload="waitForFonts()"
></iframe>
<script>
function waitForFonts() {
iframe.contentDocument.fonts.ready.then(() => {
document.documentElement.classList = "";
});
}
</script>
</body>
</html>