mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-03 07:32:00 +00:00
If the attribute value is the empty string `(lang="")`, the language is set to unknown. `lang` attribute higher up in the document tree will no longer be applied to the content of that element.
25 lines
807 B
HTML
25 lines
807 B
HTML
<!DOCTYPE html>
|
|
<html lang="ko">
|
|
<head>
|
|
<style type='text/css'>
|
|
.test div { width: 50px; }
|
|
#box:lang(ko) { width: 100px; }
|
|
</style>
|
|
</head>
|
|
<body>
|
|
<div class="test">
|
|
<div id="box" lang="">Test</div>
|
|
</div>
|
|
</body>
|
|
<script src="../include.js"></script>
|
|
<script>
|
|
asyncTest((done) => {
|
|
if (document.getElementById('box').offsetWidth == 50) {
|
|
println("OK");
|
|
} else {
|
|
println("FAIL. If the meta Content-Language element contains a language declaration but the html element uses an empty lang value, the UA will not recognize the language declared in the meta Content-Language element.");
|
|
}
|
|
done();
|
|
});
|
|
</script>
|
|
</html>
|