JSFiddle - React, Tailwind, and code Playground

by techappetite

HTML

<!-- Experiment with css positioning -->
<div id="wrapper">
    <div id="content">
        <div id="sidebar">
            <div class="sidebarTitle">
                Sidebar
            </div>
        </div>
        <div id="mainContent">
            <div class="sidebarTitle">
                Main Content
            </div>
        </div>
    </div>
</div>

CSS

body{
    font-family:Calibri;
}
#wrapper{
    margin:0 auto;
    width:90%px;
    border:1px solid red;
    border-radius:6px;
    overflow:auto;
    min-height:100px;
}
#content{
    position:relative;
    padding:10px;
}
#sidebar {
    border-radius:6px;
    background-color:grey;
    padding:10px;
    
    position:absolute;
    left:10px;
    
    min-height:50px;
    width:100px;
}
#mainContent{
    border-radius:6px;
    background-color:grey;
    padding:10px;
    
    position:absolute;
    right:10px;
    top:10px;
    bottom:10px;
    left:140px;
   
    
    min-height:50px;
}
.sidebarTitle{
    color:white;
    font-weight:bold;
    text-align:center;
    padding:3px;
    background-color:blue;
    margin:-10px;
    margin-bottom:10px;
    border-radius:6px 6px 0px 0px;
}