Source code
Revision control
Copy as Markdown
Other Tools
Test Info:
- This WPT test may be referenced by the following Test IDs:
- /css/css-text-decor/text-decoration-thickness-linethrough-001.html - WPT Dashboard Interop Dashboard
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Test case for text-decoration-thickness</title>
<meta name="assert" content="text-decoration-thickness; the width of the decoration line is increased">
<link rel="author" title="Charlie Marlow" href="mailto:cmarlow@mozilla.com">
<link rel="match" href="reference/text-decoration-thickness-green-rect-ref.html">
<link rel="stylesheet" type="text/css" href="/fonts/ahem.css">
<style>
div{
overflow: hidden;
height: 1em;
width: 4em;
background-color: red;
font: 20px/1 Ahem;
color: transparent;
text-decoration: green line-through;
text-decoration-skip-ink: none;
/* We make the text decoration just a bit thicker than the div's height, so that
* it will entirely cover the div's content-box (making it fully green) as long
* as the line-through is approximately centered, vertically.
*/
text-decoration-thickness: 1.1em;
}
</style>
</head>
<body>
<p>Test passes if there is a wide green block, fails if there is any red visible</p>
<div>XXXXXXXXXXXXXXXXXXXX</div>
</body>
</html>