mirror of
https://github.com/SerenityOS/serenity.git
synced 2025-01-26 19:32:06 -05:00
7bc5949e35
This matches if the element has a placeholder, and that placeholder is currently visible. This applies to `<input>` and `<textarea>` elements, but our `<textarea>` is very limited so does not support placeholders.
9 lines
256 B
HTML
9 lines
256 B
HTML
<style>
|
|
.placeholder-shown {
|
|
background-color: yellow;
|
|
}
|
|
</style>
|
|
<input type="text" placeholder="hi" class="placeholder-shown">
|
|
<input type="text" placeholder="hi" value="I like turtles">
|
|
<input type="text">
|
|
<input type="text" value="I like turtles">
|