Left aligning absolutely positioned div while maintaining fluidity - HTML CSS CSS Layout

HTML CSS examples for CSS Layout:Absolute Position

Description

Left aligning absolutely positioned div while maintaining fluidity

Demo Code

ResultView the demo in separate window

<html>
 <head> 
  <style>
#outer {<!--   w  w w.  j  a v  a2s.c  o m-->
   overflow:hidden;
}

#left {
   float:left;
   min-width:67%;
   background-color:Chartreuse;
}

#right {
   min-width:35%;
   display:flex;
   flex-direction:row;
   flex-wrap:wrap;
   justify-content:flex-end;
   align-items:stretch;
}

.item {
   display:inline-block;
}
</style> 
 </head> 
 <body> 
  <div id="outer"> 
   <div id="left"> 
    <div id="leftContainer"> 
     <span>Lor</span> 
     <span>Lor</span> 
     <span>Lor</span> 
     <span>Lor</span> 
    </div> 
   </div> 
   <div id="right"> 
    <div class="item"> 
     <span>Lorem ipsum</span> 
    </div> 
    <div class="item"> 
     <span>Lorem ipsum</span> 
    </div> 
    <div class="item"> 
     <span>Lorem ipsum</span> 
    </div> 
    <div class="item"> 
     <span>Lorem ipsum</span> 
    </div> 
    <div class="item"> 
     <span>Lorem ipsum</span> 
    </div> 
    <div class="item"> 
     <span>Lorem ipsum</span> 
    </div> 
   </div> 
  </div>  
 </body>
</html>

Related Tutorials