1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 00:17:46 +00:00

LibHTML: Implement basic :hover pseudo-class support

This is currently very aggressive. Whenever the Document's hovered node
changes, we invalidate all style and do a full relayout.

It does look cool though. So cool that I'm adding it to the default
stylesheet. :^)
This commit is contained in:
Andreas Kling 2019-10-14 17:54:17 +02:00
parent 605a225b53
commit 61ef17b87a
6 changed files with 52 additions and 1 deletions

View file

@ -0,0 +1,13 @@
<html>
<head>
<title>Hover test!</title>
<style>
a:hover {
color: red;
}
</style>
</head>
<body>
<a href="hover.html">this is a link</a>
</body>
</html>

View file

@ -32,6 +32,7 @@ h1 {
<li><a href="link.html">link element</a></li>
<li><a href="blink.html">blink element</a></li>
<li><a href="br.html">br element</a></li>
<li><a href="hover.html">hover element</a></li>
<li><a href="http://www.serenityos.org/">www.serenityos.org</a></li>
</ul>
</body>