流程步骤(备用)
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv="X-UA-Compatible" content="ie=edge"> <style> body { overflow-x: hidden; } * { margin: 0; padding: 0; } li { list-style: none; float: left; }
/*流程步骤*/
.check-flow2 {
display: inline-block;
width: 100%;
height: auto;
padding-top: 10px;
padding-bottom: 20px;
margin-bottom: 20px;
border: 1px solid #ccc;
}
.check-flow2 li {
width: 20%;
float: left;
margin: 0 auto;
text-align: center;
}
/*圆和线*/
.cirAndArr {
position: relative;
height: 30px;
width: 100%;
padding-bottom: 5px;
text-align: center;
}
/*圆*/
.cirAndArr .circle {
display: inline-block;
position: absolute;
top: -2px;
left: 45%;
width: 30px;
height: 30px;
line-height: 30px;
color: #fff;
margin-left: -56%\0\9;
border-radius: 50%;
background:#c2c2c2;
}
.cirAndArr .flow2-line {
display: inline-block;
width:100%;
height: 4px;
background: #c2c2c2;
}
.check-flow2 li:first-child .flow2-line {
width: 50%;
margin-left: 50%;
}
.check-flow2 li:last-child .flow2-line{
width: 50%;
margin-left: -50%;
margin-left: -50%\0\9;
}
.check-flow2 li:last-child .circle{
/*margin-left: 50%\0\9;*/
left: 100%\0\9;
}
/*当前闪烁*/
.check-flow2 .active {
background-color: #009688;
-webkit-animation: flicker 1.2s infinite linear;
-moz-animation: flicker 1.2s infinite linear;
animation: flicker 1.2s infinite linear;
}
/*已经完成*/
.check-flow2 .alreaded {
background: #009688;
}
@keyframes flicker {
0% {
background: #c2c2c2;
}
100% {
background: #009688;
}
}
</style> <title>Document</title> </head> <body> <ul class="check-flow2"> <li> <!-- 圆和箭头 --> <div class="cirAndArr"> <!-- 线 --> <span class="flow2-line alreaded"></span> <!-- 圆 --> <span class="circle alreaded">1</span> </div> <p>开始</p> </li> <li> <div class="cirAndArr"> <span class="flow2-line alreaded"></span> <span class="circle active">2</span> </div> <p>第一步</p> </li> <li> <div class="cirAndArr"> <span class="flow2-line"></span> <span class="circle">3</span> </div> <p>第二步</p> </li> <li> <div class="cirAndArr"> <span class="flow2-line"></span> <span class="circle ">4</span> </div> <p>第三步我是很长的文字我是很长的文字我是很长的文字我是很长的文字我是很长的文字我是很长的文字第三步我是很长的文字我是很长的文字第三步我是很长的文字我是很长的文字第三步我是很长的文字我是很长的文字第三步我是很长的文字我是很长的文字</p> </li> <li> <div class="cirAndArr"> <span class="flow2-line"></span> <span class="circle ">5</span> </div> <p>结束</p> </li> </ul> </body> </html>