HTML
<view style="margin-top: 80rpx;height: 100vh;" :style="{backgroundColor: bgColor }"></view>
JS
<script>
export defalut{
data(){
retrun {
bgColor:""
}
},
methods:{
changeTabs(){
switch (this.tabsCurrt) {
case 0:
this.bgColor = '#f0f3f8'
break;
case 1:
this.bgColor = '#1d1e23'
break;
case 2:
this.bgColor = '#1d1e23'
break;
}
}
}
}
</script>