vue豎向步驟條方式
更新時(shí)間:2023年12月02日 17:07:36 作者:性野喜悲
這篇文章主要介紹了vue豎向步驟條方式,具有很好的參考價(jià)值,希望對(duì)大家有所幫助,
效果圖

彈框組件代碼
<template>
<el-dialog
:visible.sync="dialogVisible"
:append-to-body="true"
:close-on-click-modal="false"
:close-on-press-escape="false"
title
width="8.2rem"
custom-class="assistance-dialog"
center
>
<div class="assistance-cont flex-top-start">
<div class="assistance-code-box">左邊</div>
<div class="assistance-steps flex-column-between">
<div class="assistance-steps-box">
<div class="assistance-steps-title">助力步驟</div>
<div class="assistance-steps-cont">
<div class="assistance-steps-line"></div>
<div class="assistance-steps-item-cont">
<div
class="assistance-steps-item flex-start"
v-for="(item, index) in stepsCont"
:key="index"
>
<div class="assistance-steps-item-idx">{{ index + 1 }}</div>
<div class="assistance-steps-item-name">{{ item }}</div>
</div>
</div>
</div>
</div>
<div class="flex-end">
<el-button type="primary">保存海報(bào)</el-button>
</div>
</div>
</div>
</el-dialog>
</template><script>
export default {
name: "assistance-dialog",
props: {
value: {
type: Boolean,
default: false,
},
},
components: {},
data() {
return {
stepsCont: [
"保存海報(bào)",
"發(fā)送海報(bào)給好友",
"好友掃碼登錄小程序",
"助力成功",
],
};
},
computed: {
dialogVisible: {
get() {
return this.value;
},
set(val) {
this.$emit("input", val);
},
},
},
watch: {},
methods: {},
created() {},
mounted() {},
beforeCreate() {},
beforeMount() {},
beforeUpdate() {},
updated() {},
beforeDestroy() {},
destroyed() {},
activated() {},
};
</script>
<style lang='scss' scoped>
.assistance-dialog {
.assistance-code-box {
width: 3.45rem;
height: 5.07rem;
background: #f4f6f9;
border-radius: 0.08rem;
margin-right: 0.32rem;
}
.assistance-steps {
height: 5.07rem;
flex: 1;
}
.assistance-steps-box {
width: 100%;
.assistance-steps-title {
font-size: 0.21rem;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #242e42;
line-height: 0.29rem;
margin-bottom: 0.24rem;
}
.assistance-steps-cont {
width: 100%;
position: relative;
}
.assistance-steps-line {
position: absolute;
width: 0.32rem;
height: 3.32rem;
border-left: 1px dashed rgba(0, 101, 255, 1);
top: 0.3rem;
left: 0.16rem;
z-index: 1;
}
.assistance-steps-item-cont {
width: 100%;
height: 4rem;
position: absolute;
z-index: 2;
}
.assistance-steps-item:not(:last-child) {
margin-bottom: 0.8rem;
}
.assistance-steps-item-idx {
width: 0.32rem;
height: 0.32rem;
line-height: 0.32rem;
text-align: center;
background: #0065ff;
border-radius: 0.08rem;
font-size: 0.18rem;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #ffffff;
margin-right: 0.16rem;
}
.assistance-steps-item-name {
font-size: 0.18rem;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #242e42;
line-height: 0.25rem;
}
}
}
</style>頁(yè)面引用
<template>
<div id="index">
<!-- 助力 -->
<assistance-dialog v-model="showAssistance"></assistance-dialog>
</div>
</template><script>
export default {
name: "index",
layout: "default",
components: {
"assistance-dialog": () =>
import("@/components/coupon/assistance-dialog.vue"), //助力
},
data() {
return {
showAssistance: true, //助力
};
},
mounted() {
},
methods: {
},
};
</script>總結(jié)
以上為個(gè)人經(jīng)驗(yàn),希望能給大家一個(gè)參考,也希望大家多多支持腳本之家。
相關(guān)文章
vue開(kāi)發(fā)調(diào)試神器vue-devtools使用詳解
這篇文章主要為大家詳細(xì)介紹了vue開(kāi)發(fā)調(diào)試神器vue-devtools的使用方法,具有一定的參考價(jià)值,感興趣的小伙伴們可以參考一下2017-07-07
一次vue項(xiàng)目?jī)?yōu)化的實(shí)際操作記錄
用vue開(kāi)發(fā)項(xiàng)目上線以后,發(fā)現(xiàn)首頁(yè)加載速度非常慢,如果項(xiàng)目比較大,甚至可能出現(xiàn)10s以上的等待,下面這篇文章主要給大家介紹了關(guān)于vue項(xiàng)目?jī)?yōu)化的相關(guān)資料,需要的朋友可以參考下2022-09-09
Vuex中如何getters動(dòng)態(tài)獲取state的值
這篇文章主要介紹了Vuex中如何getters動(dòng)態(tài)獲取state的值,具有很好的參考價(jià)值,希望對(duì)大家有所幫助。如有錯(cuò)誤或未考慮完全的地方,望不吝賜教2022-08-08
Vue屏幕自適應(yīng)三種實(shí)現(xiàn)方法詳解
在實(shí)際業(yè)務(wù)中,我們常用圖表來(lái)做數(shù)據(jù)統(tǒng)計(jì),數(shù)據(jù)展示,數(shù)據(jù)可視化等比較直觀的方式來(lái)達(dá)到一目了然的數(shù)據(jù)查看,但在大屏開(kāi)發(fā)過(guò)程中,常會(huì)因?yàn)檫m配不同屏幕而感到困擾,下面我們來(lái)解決一下這個(gè)不算難題的難題2022-11-11
vue el-form-item如何添加icon和tooltip
這篇文章主要介紹了vue el-form-item如何添加icon和tooltip問(wèn)題,具有很好的參考價(jià)值,希望對(duì)大家有所幫助,如有錯(cuò)誤或未考慮完全的地方,望不吝賜教2023-10-10
vue keep-alive的簡(jiǎn)單總結(jié)
這篇文章主要介紹了vue中的keep-alive的相關(guān)資料,幫助大家更好的理解和使用vue框架,感興趣的朋友可以了解下2021-01-01
vue封裝一個(gè)右鍵菜單組件詳解(復(fù)制粘貼即可使用)
關(guān)于vue項(xiàng)目中會(huì)出現(xiàn)一些需求,就是右鍵菜單項(xiàng)的功能實(shí)現(xiàn),下面這篇文章主要給大家介紹了關(guān)于vue封裝一個(gè)右鍵菜單組件(復(fù)制粘貼即可使用)的相關(guān)資料,需要的朋友可以參考下2022-12-12

