2016-12-30 21:41:28 +08:00
|
|
|
@import "../../style/themes/default";
|
|
|
|
@import "../../style/mixins/index";
|
|
|
|
|
|
|
|
@layout-prefix-cls: ~"@{ant-prefix}-layout";
|
|
|
|
|
|
|
|
.@{layout-prefix-cls} {
|
|
|
|
display: flex;
|
2017-01-08 17:03:47 +08:00
|
|
|
flex-direction: column;
|
2016-12-30 21:41:28 +08:00
|
|
|
flex: auto;
|
|
|
|
background: @layout-body-background;
|
|
|
|
|
2017-01-08 17:03:47 +08:00
|
|
|
&&-has-sider {
|
|
|
|
flex-direction: row;
|
2017-08-08 13:38:10 +08:00
|
|
|
> .@{layout-prefix-cls},
|
|
|
|
> .@{layout-prefix-cls}-content {
|
|
|
|
overflow-x: hidden;
|
|
|
|
}
|
2017-01-08 17:03:47 +08:00
|
|
|
}
|
|
|
|
|
2016-12-30 21:41:28 +08:00
|
|
|
&-header,
|
|
|
|
&-footer {
|
2017-01-08 17:03:47 +08:00
|
|
|
flex: 0 0 auto;
|
2016-12-30 21:41:28 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
&-header {
|
|
|
|
background: @layout-header-background;
|
|
|
|
padding: @layout-header-padding;
|
|
|
|
height: @layout-header-height;
|
|
|
|
line-height: @layout-header-height;
|
|
|
|
}
|
|
|
|
|
|
|
|
&-footer {
|
|
|
|
padding: @layout-footer-padding;
|
|
|
|
color: @text-color;
|
|
|
|
font-size: @font-size-base;
|
|
|
|
}
|
|
|
|
|
|
|
|
&-content {
|
|
|
|
flex: auto;
|
|
|
|
}
|
|
|
|
|
|
|
|
&-sider {
|
2017-09-06 13:46:45 +08:00
|
|
|
transition: all .2s;
|
2016-12-30 21:41:28 +08:00
|
|
|
position: relative;
|
|
|
|
background: @layout-sider-background;
|
2017-08-04 17:58:32 +08:00
|
|
|
|
|
|
|
/* fix firefox can't set width smaller than content on flex item */
|
2017-04-22 10:38:44 +08:00
|
|
|
min-width: 0;
|
2016-12-30 21:41:28 +08:00
|
|
|
|
2017-09-23 18:33:26 +08:00
|
|
|
&-children {
|
|
|
|
height: 100%;
|
|
|
|
}
|
|
|
|
|
2016-12-30 21:41:28 +08:00
|
|
|
&-has-trigger {
|
|
|
|
padding-bottom: @layout-trigger-height;
|
|
|
|
}
|
|
|
|
|
|
|
|
&-right {
|
|
|
|
order: 1;
|
|
|
|
}
|
|
|
|
|
|
|
|
&-trigger {
|
2017-08-11 16:00:25 +08:00
|
|
|
position: fixed;
|
2016-12-30 21:41:28 +08:00
|
|
|
text-align: center;
|
|
|
|
bottom: 0;
|
|
|
|
cursor: pointer;
|
|
|
|
height: @layout-trigger-height;
|
|
|
|
line-height: @layout-trigger-height;
|
2017-07-22 02:21:31 +08:00
|
|
|
color: @layout-trigger-color;
|
2017-08-11 16:00:25 +08:00
|
|
|
background: fade(@layout-trigger-background, 100);
|
|
|
|
z-index: 1;
|
2017-08-16 21:38:16 +08:00
|
|
|
transition: all .15s @ease-in-out;
|
2016-12-30 21:41:28 +08:00
|
|
|
}
|
2017-03-05 21:10:34 +08:00
|
|
|
|
|
|
|
&-zero-width {
|
|
|
|
& > * {
|
|
|
|
overflow: hidden;
|
|
|
|
}
|
|
|
|
|
|
|
|
&-trigger {
|
|
|
|
position: absolute;
|
|
|
|
top: @layout-header-height;
|
|
|
|
right: -@layout-zero-trigger-width;
|
|
|
|
text-align: center;
|
|
|
|
width: @layout-zero-trigger-width;
|
|
|
|
height: @layout-zero-trigger-height;
|
|
|
|
line-height: @layout-zero-trigger-height;
|
|
|
|
background: @layout-sider-background;
|
|
|
|
color: #fff;
|
|
|
|
font-size: @layout-zero-trigger-width / 2;
|
|
|
|
border-radius: 0 @border-radius-base @border-radius-base 0;
|
|
|
|
cursor: pointer;
|
|
|
|
transition: background .3s ease;
|
|
|
|
|
|
|
|
&:hover {
|
|
|
|
background: tint(@layout-sider-background, 10%);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2016-12-30 21:41:28 +08:00
|
|
|
}
|
|
|
|
}
|