servo/tests/wpt/css-tests/mediaqueries-3_dev/html/relative-units-004.htm
Ms2ger 296fa2512b Update web-platform-tests and CSS tests.
- Update CSS tests to revision e05bfd5e30ed662c2f8a353577003f8eed230180.
- Update web-platform-tests to revision a052787dd5c069a340031011196b73affbd68cd9.
2017-02-06 22:38:29 +01:00

32 lines
No EOL
934 B
HTML

<!DOCTYPE html>
<html><head>
<meta charset="utf-8">
<title>CSS Test: Font-relative length units (ch) in width media queries</title>
<link href="http://chrisrebert.com" rel="author" title="Chris Rebert">
<link href="https://www.w3.org/TR/css3-mediaqueries/#units" rel="help">
<link href="https://www.w3.org/TR/mediaqueries-4/#units" rel="help">
<link href="reference/ref-green-body.htm" rel="match">
<meta content="" name="flags">
<meta content="Font-relative length units (such as 'ch') in media queries should be calculated based on the initial value of 'font-size', not based on author style declarations, such as: html { font-size: 200%; }" name="assert">
<style>
:root {
font-size: 100000px;/* ~87ft */
}
body {
background: red;
}
@media (min-width: 1ch) {
body {
background: green;
}
}
p {
font-size: 24px;
}
</style>
</head>
<body>
<p>This should have a green background.</p>
</body></html>