[英]Bootstrap 3 left close bar 100% height with container-fluid
我想你想要这样的东西。
body {margin:0;} .side { position: fixed; background: blue; top: 0; left: 0; bottom: 0; width: 100px; } .content { padding-left: 100px; width: 100%; height: 100vh; box-sizing: border-box; } .top { height: 100px; width: 100%; background: orange; float: left; } .left, .right { width: 50%; height: 200px; float: left; } .left { background: green; } .right { background: magenta; }
<div class="side"></div> <div class="content"> <div class="top"></div> <div class="left"></div> <div class="right"></div> </div>
如果您想使侧边栏全高,可以使用
.sidebar{
height:100vh;
}
然后你可以给position:fixed;
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.