2016-04-27 20:44:36 +08:00
|
|
|
@import "../../style/themes/default";
|
|
|
|
@import "../../style/mixins/index";
|
|
|
|
|
2016-09-14 16:18:33 +08:00
|
|
|
@collapse-prefix-cls: ~"@{ant-prefix}-collapse";
|
2015-07-11 10:17:58 +08:00
|
|
|
|
2015-11-26 19:32:55 +08:00
|
|
|
.collapse-close() {
|
2017-02-16 15:35:52 +08:00
|
|
|
.iconfont-size-under-12px(9px, 0);
|
2015-11-26 19:32:55 +08:00
|
|
|
}
|
|
|
|
.collapse-open() {
|
2017-02-16 15:35:52 +08:00
|
|
|
.iconfont-size-under-12px(9px, 90deg);
|
2015-07-11 10:17:58 +08:00
|
|
|
}
|
|
|
|
|
2015-08-20 16:55:42 +08:00
|
|
|
.@{collapse-prefix-cls} {
|
2016-07-21 15:02:24 +08:00
|
|
|
background-color: @background-color-base;
|
2017-02-16 15:35:52 +08:00
|
|
|
border-radius: @border-radius-base;
|
2017-01-31 16:05:10 +08:00
|
|
|
border: @border-width-base @border-style-base @border-color-base;
|
2017-01-09 17:19:26 +08:00
|
|
|
border-bottom: 0;
|
2015-07-11 10:17:58 +08:00
|
|
|
|
2015-07-14 21:09:16 +08:00
|
|
|
& > &-item {
|
2017-01-31 16:05:10 +08:00
|
|
|
border-bottom: @border-width-base @border-style-base @border-color-base;
|
2015-08-20 16:55:42 +08:00
|
|
|
> .@{collapse-prefix-cls}-header {
|
2015-07-14 21:09:16 +08:00
|
|
|
height: 38px;
|
|
|
|
line-height: 38px;
|
2015-08-23 16:27:43 +08:00
|
|
|
padding-left: 32px;
|
2016-11-08 20:50:59 +08:00
|
|
|
color: @text-color;
|
2015-07-24 22:07:59 +08:00
|
|
|
cursor: pointer;
|
2015-08-23 16:27:43 +08:00
|
|
|
position: relative;
|
2017-02-16 15:35:52 +08:00
|
|
|
transition: all .3s;
|
|
|
|
|
|
|
|
&:active {
|
|
|
|
background-color: #eee!important;
|
|
|
|
}
|
2015-08-23 16:27:43 +08:00
|
|
|
|
|
|
|
.arrow {
|
2015-11-26 19:32:55 +08:00
|
|
|
.collapse-close();
|
2015-08-23 16:27:43 +08:00
|
|
|
.iconfont-mixin();
|
|
|
|
position: absolute;
|
2017-02-16 15:35:52 +08:00
|
|
|
color: @text-color-secondary;
|
2015-07-14 21:09:16 +08:00
|
|
|
display: inline-block;
|
2017-02-16 15:35:52 +08:00
|
|
|
font-weight: bold;
|
2015-11-17 16:13:59 +08:00
|
|
|
line-height: 40px;
|
2015-08-17 12:27:03 +08:00
|
|
|
vertical-align: middle;
|
2017-02-16 15:35:52 +08:00
|
|
|
transition: transform 0.24s;
|
2015-11-04 17:54:51 +08:00
|
|
|
top: 0;
|
2015-08-23 16:27:43 +08:00
|
|
|
left: 16px;
|
2017-02-06 12:04:35 +08:00
|
|
|
/* stylelint-disable declaration-block-no-duplicate-properties */
|
|
|
|
top: ~"16px \9";
|
|
|
|
left: ~"0 \9";
|
|
|
|
/* stylelint-enable declaration-block-no-duplicate-properties */
|
2015-08-23 16:27:43 +08:00
|
|
|
&:before {
|
2017-02-16 15:35:52 +08:00
|
|
|
content: "\E61F";
|
2015-08-23 16:27:43 +08:00
|
|
|
}
|
2015-07-14 21:09:16 +08:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2016-04-24 15:29:12 +08:00
|
|
|
&-anim-active {
|
|
|
|
transition: height .2s @ease-out;
|
|
|
|
}
|
|
|
|
|
2015-07-11 10:17:58 +08:00
|
|
|
&-content {
|
|
|
|
overflow: hidden;
|
2015-07-21 15:17:42 +08:00
|
|
|
color: @text-color;
|
2015-07-11 10:17:58 +08:00
|
|
|
padding: 0 16px;
|
2016-11-29 11:56:10 +08:00
|
|
|
background-color: @component-background;
|
2015-07-14 21:09:16 +08:00
|
|
|
|
|
|
|
& > &-box {
|
2015-08-20 15:39:36 +08:00
|
|
|
padding-top: 16px;
|
|
|
|
padding-bottom: 16px;
|
2015-07-11 10:17:58 +08:00
|
|
|
}
|
2015-08-31 16:58:27 +08:00
|
|
|
|
2016-03-30 16:27:14 +08:00
|
|
|
&-inactive {
|
|
|
|
display: none;
|
2015-08-31 16:58:27 +08:00
|
|
|
}
|
2015-07-11 10:17:58 +08:00
|
|
|
}
|
|
|
|
|
2015-07-14 21:09:16 +08:00
|
|
|
&-item:last-child {
|
2015-08-20 16:55:42 +08:00
|
|
|
> .@{collapse-prefix-cls}-content {
|
2017-02-16 15:35:52 +08:00
|
|
|
border-radius: 0 0 @border-radius-base @border-radius-base;
|
2015-07-14 21:09:16 +08:00
|
|
|
}
|
2015-07-11 10:17:58 +08:00
|
|
|
}
|
|
|
|
|
2015-11-04 17:54:51 +08:00
|
|
|
& > &-item > &-header[aria-expanded="true"] {
|
|
|
|
.arrow {
|
2015-11-26 19:32:55 +08:00
|
|
|
.collapse-open();
|
2015-07-11 10:17:58 +08:00
|
|
|
}
|
|
|
|
}
|
2016-11-06 15:06:34 +08:00
|
|
|
|
|
|
|
&-borderless {
|
2016-11-29 11:56:10 +08:00
|
|
|
background-color: @component-background;
|
2016-11-06 15:06:34 +08:00
|
|
|
border: 0;
|
|
|
|
}
|
|
|
|
|
2017-01-09 17:19:26 +08:00
|
|
|
&-borderless > &-item-active {
|
2016-11-06 15:06:34 +08:00
|
|
|
border: 0;
|
|
|
|
}
|
|
|
|
|
2017-01-09 17:19:26 +08:00
|
|
|
&-borderless > &-item > &-content {
|
|
|
|
background-color: transparent;
|
2017-01-31 16:05:10 +08:00
|
|
|
border-top: @border-width-base @border-style-base @border-color-base;
|
2017-01-09 17:19:26 +08:00
|
|
|
}
|
|
|
|
|
2016-11-06 15:06:34 +08:00
|
|
|
&-borderless > &-item > &-header {
|
|
|
|
transition: all .3s;
|
|
|
|
&:hover {
|
2017-01-09 17:19:26 +08:00
|
|
|
background-color: @background-color-base;
|
2016-11-06 15:06:34 +08:00
|
|
|
}
|
|
|
|
}
|
2015-07-11 10:17:58 +08:00
|
|
|
}
|