Source code

Revision control

Copy as Markdown

Other Tools

Test Info:

<!DOCTYPE html>
<title>CSS Test: ::first-letter stops applying to element becoming inline.</title>
<link rel="author" title="Rune Lillesveen" href="mailto:futhark@chromium.org">
<link rel="match" href="first-letter-block-to-inline-ref.html">
<style>
#outer.block::first-letter { color: red }
#outer.block { display: block }
</style>
<span id="outer" class="block">
<span id="inner">This text should be green.</span>
</span>
<script>
outer.offsetTop;
outer.className = "";
inner.style.color = "green";
</script>