first-line-line-height-003.html (782B)
1 <!DOCTYPE html> 2 <meta charset="utf-8"> 3 <title>CSS-Pseudo testcase: first-line</title> 4 <link rel="author" title="Minseong Kim" href="jja08111@gmail.com"> 5 <link rel="help" href="https://drafts.csswg.org/css-pseudo/#first-line-styling"> 6 <link rel="match" href="first-line-line-height-003-ref.html"> 7 <meta name="assert" content="The ::first-line pseudo-element’s generated box behaves similar to that of an inline-level element"> 8 <style> 9 div:first-of-type::first-line, span { line-height: 0px; color: purple } 10 div { line-height: 40px; border: 1px solid black; margin-top: 20px; } 11 </style> 12 Test passes if the two blocks look identical. 13 <div> 14 This is a first line.<br> 15 This is a second line. 16 </div> 17 <div> 18 <span>This is a first line.</span><br> 19 This is a second line. 20 </div>