ant-design/style/components/steps.less

362 lines
8.6 KiB
Plaintext
Raw Normal View History

@import "../mixins/index";
2015-08-26 18:28:29 +08:00
2015-08-20 16:55:42 +08:00
@steps-prefix-cls: ~"@{css-prefix}steps";
2015-08-26 18:28:29 +08:00
@steps-vertical-prefix-cls: ~"@{css-prefix}steps-vertical";
2015-08-27 13:20:31 +08:00
@steps-vertical-small-prefix-cls: ~"@{css-prefix}steps-vertical-small";
2015-07-08 16:36:08 +08:00
@process-icon-color: @primary-color;
2015-07-08 15:53:51 +08:00
@process-title-color: #666;
@process-description-color: @process-title-color;
2015-07-14 13:43:25 +08:00
@process-tail-color: #e9e9e9;
@wait-icon-color: #ccc;
2015-07-08 15:53:51 +08:00
@wait-title-color: #999;
@wait-description-color: @wait-title-color;
2015-07-14 13:43:25 +08:00
@wait-tail-color: @process-tail-color;
2015-07-08 15:53:51 +08:00
@finish-icon-color: @process-icon-color;
@finish-title-color: @wait-title-color;
@finish-description-color: @finish-title-color;
@finish-tail-color: @process-icon-color;
2015-06-24 14:52:49 +08:00
2015-06-25 16:01:04 +08:00
.transition(@transition) {
transition: @transition;
2015-07-08 15:53:51 +08:00
-webkit-transition: @transition;
-moz-transition: @transition;
2015-06-25 16:01:04 +08:00
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls} {
font-size: 0;
2015-06-25 16:01:04 +08:00
width: 100%;
line-height: 1.5;
2015-06-24 14:52:49 +08:00
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-item {
2015-06-24 14:52:49 +08:00
position: relative;
display: inline-block;
2015-07-08 16:36:08 +08:00
vertical-align: top;
2015-08-20 16:55:42 +08:00
&.@{steps-prefix-cls}-status-wait {
.@{steps-prefix-cls}-head-inner {
2015-07-08 15:53:51 +08:00
border-color: @wait-icon-color;
2015-06-25 16:01:04 +08:00
background-color: #fff;
2015-08-20 16:55:42 +08:00
> .@{steps-prefix-cls}-icon {
2015-07-08 15:53:51 +08:00
color: @wait-icon-color;
2015-06-25 16:01:04 +08:00
}
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-title {
2015-07-08 15:53:51 +08:00
color: @wait-title-color;
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-description {
2015-07-08 15:53:51 +08:00
color: @wait-description-color;
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-tail > i {
2015-07-08 15:53:51 +08:00
background-color: @wait-tail-color;
}
}
2015-08-20 16:55:42 +08:00
&.@{steps-prefix-cls}-status-process {
.@{steps-prefix-cls}-head-inner {
2015-07-08 15:53:51 +08:00
border-color: @process-icon-color;
background-color: @process-icon-color;
2015-08-20 16:55:42 +08:00
> .@{steps-prefix-cls}-icon {
2015-06-25 16:01:04 +08:00
color: #fff;
}
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-title {
2015-07-08 15:53:51 +08:00
color: @process-title-color;
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-description {
2015-07-08 15:53:51 +08:00
color: @process-description-color;
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-tail > i {
2015-07-08 15:53:51 +08:00
background-color: @process-tail-color;
}
}
2015-08-20 16:55:42 +08:00
&.@{steps-prefix-cls}-status-finish {
.@{steps-prefix-cls}-head-inner {
2015-07-08 15:53:51 +08:00
border-color: @finish-icon-color;
2015-06-25 16:01:04 +08:00
background-color: #fff;
2015-08-20 16:55:42 +08:00
> .@{steps-prefix-cls}-icon {
2015-07-08 15:53:51 +08:00
color: @finish-icon-color;
}
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-tail > i {
2015-07-08 15:53:51 +08:00
background-color: @finish-tail-color;
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-title {
2015-07-08 15:53:51 +08:00
color: @finish-title-color;
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-description {
2015-07-08 15:53:51 +08:00
color: @finish-description-color;
}
2015-06-25 18:12:42 +08:00
}
2015-08-20 16:55:42 +08:00
&.@{steps-prefix-cls}-custom {
.@{steps-prefix-cls}-head-inner {
2015-06-25 18:12:42 +08:00
background: none;
border: 0;
2015-07-08 15:53:51 +08:00
width: auto;
height: auto;
2015-08-20 16:55:42 +08:00
> .@{steps-prefix-cls}-icon {
2015-07-09 18:17:15 +08:00
font-size: 20px;
2015-07-14 13:43:25 +08:00
top: 2px;
width: 20px;
height: 20px;
2015-07-08 16:36:08 +08:00
}
2015-06-25 18:12:42 +08:00
}
2015-08-20 16:55:42 +08:00
&.@{steps-prefix-cls}-status-process {
.@{steps-prefix-cls}-head-inner > .@{steps-prefix-cls}-icon {
2015-07-08 15:53:51 +08:00
color: @process-icon-color;
2015-06-25 18:12:42 +08:00
}
}
}
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-head, .@{steps-prefix-cls}-main {
position: relative;
display: inline-block;
vertical-align: top;
2015-06-24 14:52:49 +08:00
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-head {
background: #fff;
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-head-inner {
display: block;
2015-08-26 18:28:29 +08:00
border: 1px solid @wait-icon-color;
2015-07-08 16:36:08 +08:00
width: 26px;
height: 26px;
line-height: 26px;
text-align: center;
2015-07-08 16:36:08 +08:00
border-radius: 26px;
font-size: 14px;
2015-07-08 15:53:51 +08:00
margin-right: 8px;
2015-07-09 20:54:55 +08:00
.transition(background-color 0.3s ease);
.transition(border-color 0.3s ease);
2015-06-25 16:01:04 +08:00
2015-08-20 16:55:42 +08:00
> .@{steps-prefix-cls}-icon {
2015-06-25 18:12:42 +08:00
line-height: 1;
2015-07-09 20:51:05 +08:00
top: -1px;
2015-07-08 15:18:28 +08:00
color: @primary-color;
position: relative;
2015-07-09 18:17:15 +08:00
&.anticon {
font-size: 12px;
2015-07-14 13:43:25 +08:00
position: relative;
top: -2px;
2015-07-09 18:17:15 +08:00
}
}
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-main {
2015-06-25 16:01:04 +08:00
margin-top: 3px;
2015-06-24 14:52:49 +08:00
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-title {
font-size: 14px;
margin-bottom: 4px;
color: #666;
font-weight: bold;
background: #fff;
display: inline-block;
padding-right: 10px;
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-item-last {
.@{steps-prefix-cls}-title {
padding-right: 0;
}
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-description {
font-size: 12px;
color: #999;
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-tail {
position: absolute;
left: 0;
width: 100%;
2015-07-21 09:46:35 +08:00
top: 13px;
2015-08-26 18:28:29 +08:00
padding: 0 10px;
> i {
display: inline-block;
2015-07-21 09:46:35 +08:00
vertical-align: top;
2015-07-08 15:53:51 +08:00
background: @wait-tail-color;
2015-07-14 13:43:25 +08:00
height: 1px;
border-radius: 1px;
width: 100%;
2015-07-09 20:54:55 +08:00
.transition(background 0.3s ease);
}
}
2015-08-20 16:55:42 +08:00
&.@{steps-prefix-cls}-small {
.@{steps-prefix-cls}-head-inner {
2015-08-26 18:28:29 +08:00
border: 1px solid @wait-icon-color;
2015-06-25 16:01:04 +08:00
width: 18px;
height: 18px;
line-height: 18px;
text-align: center;
border-radius: 18px;
font-size: 12px;
2015-06-25 16:01:04 +08:00
margin-right: 10px;
2015-08-20 16:55:42 +08:00
> .@{steps-prefix-cls}-icon.anticon {
.iconfont-size-under-12px(9px);
2015-07-14 13:43:25 +08:00
top: -1px;
2015-07-09 18:17:15 +08:00
}
2015-06-25 16:01:04 +08:00
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-main {
2015-06-25 16:01:04 +08:00
margin-top: 0;
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-title {
2015-06-25 16:01:04 +08:00
font-size: 12px;
margin-bottom: 4px;
color: #666;
font-weight: bold;
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-description {
2015-06-25 16:01:04 +08:00
font-size: 10px;
color: #999;
}
2015-08-20 16:55:42 +08:00
.@{steps-prefix-cls}-tail {
2015-06-25 18:12:42 +08:00
top: 8px;
2015-08-26 18:28:29 +08:00
padding: 0 8px;
2015-06-25 16:01:04 +08:00
> i {
height: 1px;
border-radius: 1px;
width: 100%;
}
}
}
2015-08-20 16:55:42 +08:00
&.@{steps-prefix-cls}-small .@{steps-prefix-cls}-item.@{steps-prefix-cls}-custom .@{steps-prefix-cls}-head-inner, .@{steps-prefix-cls}-item.@{steps-prefix-cls}-custom .@{steps-prefix-cls}-head-inner {
2015-06-25 16:01:04 +08:00
width: inherit;
height: inherit;
line-height: inherit;
border-radius: 0;
border: 0;
background: none;
}
2015-07-08 15:18:28 +08:00
}
2015-08-26 18:28:29 +08:00
.@{steps-prefix-cls} {
.@{steps-prefix-cls}-item.@{steps-vertical-prefix-cls} {
display: block;
}
2015-08-28 11:09:10 +08:00
2015-08-26 18:28:29 +08:00
.@{steps-vertical-prefix-cls}.@{steps-prefix-cls}-tail {
left: 13px;
height: 100%;
width: 1px;
top: 0;
padding: 30px 0 4px 0;
> i {
height: 100%;
width: 1px;
}
}
2015-08-28 11:09:10 +08:00
2015-08-27 13:20:31 +08:00
.@{steps-vertical-prefix-cls}.@{steps-prefix-cls}-main {
min-height: 47px;
}
2015-08-28 11:09:10 +08:00
2015-08-26 18:28:29 +08:00
.@{steps-vertical-prefix-cls}.@{steps-prefix-cls}-head-inner {
margin-right: 16px;
}
2015-08-27 13:20:31 +08:00
.@{steps-prefix-cls}-item.@{steps-vertical-small-prefix-cls} {
display: block;
}
2015-08-28 11:09:10 +08:00
2015-08-27 13:20:31 +08:00
.@{steps-vertical-small-prefix-cls}.@{steps-prefix-cls}-tail {
2015-08-28 11:09:10 +08:00
left: 6px;
2015-08-27 13:20:31 +08:00
height: 100%;
width: 2px;
top: 0;
padding: 0;
> i {
height: 100%;
width: 0px;
}
}
2015-08-28 11:09:10 +08:00
2015-08-27 13:20:31 +08:00
.@{steps-prefix-cls}-item.@{steps-prefix-cls}-status-wait {
.@{steps-vertical-small-prefix-cls}.@{steps-prefix-cls}-tail {
> i {
background-color: #fff;
border-left: 2px dotted @wait-tail-color;
}
}
}
2015-08-28 11:09:10 +08:00
2015-08-27 13:20:31 +08:00
.@{steps-prefix-cls}-item.@{steps-prefix-cls}-status-process {
.@{steps-vertical-small-prefix-cls}.@{steps-prefix-cls}-tail {
> i {
background-color: #fff;
border-left: 2px dotted @process-tail-color;
}
}
}
2015-08-28 11:09:10 +08:00
2015-08-27 13:20:31 +08:00
.@{steps-prefix-cls}-item.@{steps-prefix-cls}-status-finish {
.@{steps-vertical-small-prefix-cls}.@{steps-prefix-cls}-tail {
> i {
background-color: #fff;
border-left: 2px solid @finish-tail-color;
}
}
}
2015-08-28 11:09:10 +08:00
.@{steps-vertical-prefix-cls}.@{steps-prefix-cls}-main {
min-height: 47px;
display: inline;
zoom: 1;
.@{steps-prefix-cls}-description {
margin-left: 42px;
}
}
2015-08-27 13:20:31 +08:00
.@{steps-vertical-small-prefix-cls}.@{steps-prefix-cls}-main {
min-height: 47px;
2015-08-28 11:09:10 +08:00
display: inline;
zoom: 1;
.@{steps-prefix-cls}-description {
margin-left: 22px;
}
2015-08-27 13:20:31 +08:00
}
2015-08-28 11:09:10 +08:00
2015-08-27 13:20:31 +08:00
.@{steps-vertical-small-prefix-cls}.@{steps-prefix-cls}-head-inner {
margin-right: 8px;
background-color: #2db7f5;
}
.@{steps-prefix-cls}-status-wait, .@{steps-prefix-cls}-status-process {
2015-08-28 11:09:10 +08:00
overflow: hidden;
2015-08-27 13:20:31 +08:00
.@{steps-vertical-small-prefix-cls}.@{steps-prefix-cls}-head-inner {
2015-08-28 11:09:10 +08:00
text-indent: 10000px;
2015-08-27 13:20:31 +08:00
display: inline-block;
background-color: #fff;
}
}
.@{steps-vertical-small-prefix-cls}.@{steps-prefix-cls}-head-inner {
2015-08-28 11:09:10 +08:00
width: 14px;
height: 14px;
2015-08-27 13:20:31 +08:00
border-width: 2px;
}
.@{steps-prefix-cls}-status-finish {
.@{steps-vertical-small-prefix-cls}.@{steps-prefix-cls}-head-inner {
background-color: @finish-tail-color;
}
}
2015-08-28 11:09:10 +08:00
2015-08-27 13:20:31 +08:00
.@{steps-prefix-cls}-status-finish {
.@{steps-vertical-small-prefix-cls}.@{steps-prefix-cls}-head-inner {
.@{steps-vertical-small-prefix-cls}.@{steps-prefix-cls}-icon:before {
color: #fff;
font-weight: 700;
2015-08-27 14:36:02 +08:00
position: absolute;
2015-08-28 11:09:10 +08:00
top: -15px;
2015-08-27 14:36:02 +08:00
left: -6px;
2015-08-27 13:20:31 +08:00
}
}
}
2015-08-28 11:09:10 +08:00
.@{steps-vertical-prefix-cls}.@{steps-prefix-cls}-description, .@{steps-vertical-small-prefix-cls}.@{steps-prefix-cls}-description {
padding-bottom: 12px;
}
2015-08-27 14:36:02 +08:00
}