2019-05-06 12:04:39 +08:00
|
|
|
@import '../../style/themes/index';
|
2018-12-07 16:17:45 +08:00
|
|
|
@import '../../style/mixins/index';
|
2016-12-30 21:41:28 +08:00
|
|
|
|
2018-12-07 16:17:45 +08:00
|
|
|
@layout-prefix-cls: ~'@{ant-prefix}-layout';
|
2016-12-30 21:41:28 +08:00
|
|
|
|
|
|
|
.@{layout-prefix-cls} {
|
|
|
|
display: flex;
|
|
|
|
flex: auto;
|
2019-02-15 10:48:07 +08:00
|
|
|
flex-direction: column;
|
2018-09-20 22:48:13 +08:00
|
|
|
/* fix firefox can't set height smaller than content on flex item */
|
|
|
|
min-height: 0;
|
2019-02-15 10:48:07 +08:00
|
|
|
background: @layout-body-background;
|
2016-12-30 21:41:28 +08:00
|
|
|
|
2017-09-22 18:33:29 +08:00
|
|
|
&,
|
|
|
|
* {
|
|
|
|
box-sizing: border-box;
|
|
|
|
}
|
|
|
|
|
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 {
|
|
|
|
height: @layout-header-height;
|
2019-02-15 10:48:07 +08:00
|
|
|
padding: @layout-header-padding;
|
2020-01-21 11:24:57 +08:00
|
|
|
color: @layout-header-color;
|
2016-12-30 21:41:28 +08:00
|
|
|
line-height: @layout-header-height;
|
2019-02-15 10:48:07 +08:00
|
|
|
background: @layout-header-background;
|
2016-12-30 21:41:28 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
&-footer {
|
|
|
|
padding: @layout-footer-padding;
|
|
|
|
color: @text-color;
|
|
|
|
font-size: @font-size-base;
|
2019-02-15 10:48:07 +08:00
|
|
|
background: @layout-footer-background;
|
2016-12-30 21:41:28 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
&-content {
|
|
|
|
flex: auto;
|
2018-09-20 22:48:13 +08:00
|
|
|
/* fix firefox can't set height smaller than content on flex item */
|
|
|
|
min-height: 0;
|
2016-12-30 21:41:28 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
&-sider {
|
|
|
|
position: relative;
|
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;
|
2019-02-15 10:48:07 +08:00
|
|
|
background: @layout-sider-background;
|
|
|
|
transition: all 0.2s;
|
2016-12-30 21:41:28 +08:00
|
|
|
|
2017-09-23 18:33:26 +08:00
|
|
|
&-children {
|
|
|
|
height: 100%;
|
2019-02-15 10:48:07 +08:00
|
|
|
margin-top: -0.1px;
|
2017-10-21 15:12:56 +08:00
|
|
|
// Hack for fixing margin collaspe bug
|
|
|
|
// https://github.com/ant-design/ant-design/issues/7967
|
|
|
|
// solution from https://stackoverflow.com/a/33132624/3040605
|
|
|
|
padding-top: 0.1px;
|
2017-09-23 18:33:26 +08:00
|
|
|
}
|
|
|
|
|
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
|
|
|
bottom: 0;
|
2019-02-15 10:48:07 +08:00
|
|
|
z-index: 1;
|
2016-12-30 21:41:28 +08:00
|
|
|
height: @layout-trigger-height;
|
2017-07-22 02:21:31 +08:00
|
|
|
color: @layout-trigger-color;
|
2019-02-15 10:48:07 +08:00
|
|
|
line-height: @layout-trigger-height;
|
|
|
|
text-align: center;
|
2017-09-27 22:32:49 +08:00
|
|
|
background: @layout-trigger-background;
|
2019-02-15 10:48:07 +08:00
|
|
|
cursor: pointer;
|
2018-12-07 16:17:45 +08:00
|
|
|
transition: all 0.2s;
|
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;
|
2019-06-21 17:45:46 +08:00
|
|
|
z-index: 1;
|
2017-03-05 21:10:34 +08:00
|
|
|
width: @layout-zero-trigger-width;
|
|
|
|
height: @layout-zero-trigger-height;
|
2018-03-29 10:50:58 +08:00
|
|
|
color: @layout-trigger-color;
|
2017-03-05 21:10:34 +08:00
|
|
|
font-size: @layout-zero-trigger-width / 2;
|
2019-02-15 10:48:07 +08:00
|
|
|
line-height: @layout-zero-trigger-height;
|
|
|
|
text-align: center;
|
|
|
|
background: @layout-sider-background;
|
2017-03-05 21:10:34 +08:00
|
|
|
border-radius: 0 @border-radius-base @border-radius-base 0;
|
|
|
|
cursor: pointer;
|
2018-12-07 16:17:45 +08:00
|
|
|
transition: background 0.3s ease;
|
2017-03-05 21:10:34 +08:00
|
|
|
|
|
|
|
&:hover {
|
|
|
|
background: tint(@layout-sider-background, 10%);
|
|
|
|
}
|
2019-01-21 12:12:33 +08:00
|
|
|
|
|
|
|
&-right {
|
|
|
|
left: -@layout-zero-trigger-width;
|
2019-08-02 14:05:59 +08:00
|
|
|
border-radius: @border-radius-base 0 0 @border-radius-base;
|
2019-01-21 12:12:33 +08:00
|
|
|
}
|
2017-03-05 21:10:34 +08:00
|
|
|
}
|
|
|
|
}
|
2016-12-30 21:41:28 +08:00
|
|
|
}
|
|
|
|
}
|
2018-05-23 23:46:28 +08:00
|
|
|
|
|
|
|
@import './light';
|