From 1cfdb63c35e0860993557881ce50414593d89026 Mon Sep 17 00:00:00 2001 From: neverland Date: Fri, 15 Mar 2019 22:30:28 +0800 Subject: [PATCH] [bugfix] Steps: incorrect active style in vertical direction (#2981) --- packages/step/index.less | 47 ++++++++++++++++++++-------------------- 1 file changed, 24 insertions(+), 23 deletions(-) diff --git a/packages/step/index.less b/packages/step/index.less index 840ff3fd1..240067007 100644 --- a/packages/step/index.less +++ b/packages/step/index.less @@ -6,6 +6,14 @@ position: relative; color: @gray-dark; + &__circle { + display: block; + width: 5px; + height: 5px; + border-radius: 50%; + background-color: @gray-dark; + } + &--horizontal { float: left; @@ -30,10 +38,6 @@ left: auto; right: -9px; } - - .van-step__line { - width: 0; - } } .van-step__circle-container { @@ -61,15 +65,6 @@ background-color: @border-color; } - &.van-step--finish { - color: @text-color; - - .van-step__circle, - .van-step__line { - background-color: @green; - } - } - &.van-step--process { color: @text-color; @@ -85,14 +80,6 @@ } } - .van-step__circle { - display: block; - width: 5px; - height: 5px; - border-radius: 50%; - background-color: @gray-dark; - } - &--vertical { float: none; display: block; @@ -129,13 +116,13 @@ .van-step__line { position: absolute; - top: 0; + top: 16px; left: -15px; width: 1px; height: 100%; background-color: @border-color; } - + &.van-step--process { .van-icon-checked { top: 12px; @@ -144,6 +131,20 @@ font-size: 12px; } } + } + &:last-child { + .van-step__line { + width: 0; + } + } + + &--finish { + color: @text-color; + + .van-step__circle, + .van-step__line { + background-color: @green; + } } }