mdb-ui-kit/scss/_layout.scss

51 lines
1.3 KiB
SCSS
Raw Normal View History

// This is a set of flex-based layout containers necessary for components such as the drawer.
// It allows for flex based positioning such as sticky header and footer inside an mdb-layout, with a
// mdb-layout-content that scrolls.
// First element
.mdb-layout-canvas {
position: absolute;
width: 100%;
height: 100%;
}
// Primary layout container, belongs inside a mdb-layout-canvas.
.mdb-layout-container {
position: relative;
display: flex;
width: 100%;
height: 100%;
flex-direction: column; // allows for sticky header and footer
overflow-x: hidden;
overflow-y: auto;
-webkit-overflow-scrolling: touch;
}
// Header layout (fixed top), belongs in a mdb-layout-container
.mdb-layout-header {
// FIXME: it would be nice to stick this directly on a .navbar, but .navbars are not flex ready, so this is relegated to be a container at this time.
2016-01-15 20:38:29 +03:00
z-index: 3;
display: flex;
width: 100%;
max-height: 1000px;
flex-direction: column;
flex-wrap: nowrap;
flex-shrink: 0;
justify-content: flex-start;
}
// Content layout, belongs in a mdb-layout-container
.mdb-layout-content {
position: relative;
z-index: 1; // under a header
display: inline-block;
//-ms-flex: 0 1 auto; // Fix IE10 bug.
overflow-x: hidden;
overflow-y: auto;
flex-grow: 1;
-webkit-overflow-scrolling: touch; // TODO: why?
}