List Indentation - HTML CSS CSS Widget

HTML CSS examples for CSS Widget:UL Element

Description

List Indentation

Demo Code

ResultView the demo in separate window

<html>
 <head> 
  <title>Lorem ipsum dolor</title> 
  <meta name="viewport" content="width=device-width, initial-scale=1"> 
  <style id="compiled-css" type="text/css">
#menu ul {
   background-color:Chartreuse;
   display:inline-block;
   border-bottom:6px solid yellow;
   list-style-type:none;
   padding-left:0
}

#menu ul li {
   display:inline-block;
   margin:3px 3px 0 3px;
   padding:6px 6px 0 6px;
   background-color:blue;
   transition:background-color 0.6s;
   cursor:pointer;
   color:pink;
}

#menu ul li:hover {
   background-color:OrangeRed;
}
</style> <!--  w  w  w. j  a va 2 s .  co  m-->
 </head> 
 <body> 
  <center> 
   <div id="menu"> 
    <ul> 
     <li>Lore</li> 
     <li>Lorem </li> 
     <li>Lore</li> 
    </ul> 
   </div> 
  </center>  
 </body>
</html>

Related Tutorials