HTML CSS examples for CSS Widget:Menu Hover
Adding dot above navigation list elements on hover
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> ul li { display:inline-block; position:relative; } ul li:hover:before { content:"";<!-- ww w . j a v a 2s . co m--> position:absolute; top:-16px; background:red; width:16px; height:16px; border-radius:100%; left:calc(51% - 9px); } </style> </head> <body> <div class="navbar"> <ul> <li class="active"> <a href="#">link 1></a> </li> <li> <a href="#">link 2></a> </li> <li> <a href="#">link 2223></a> </li> <li> <a href="#">link 4></a> </li> </ul> </div> </body> </html>