基于vue的列表手风琴

html

2018-05-3011:15:36

 
js
openList: function(e){
let self = this;
if(this.$(this.$(e.currentTarget)[0].parentElement)[0].className.indexOf('fold') == -1){
this.$(this.$(e.currentTarget)[0].parentElement).addClass('fold')
this.$(e.currentTarget).parent().siblings('.plist').removeClass('fold');
}else{
this.$(this.$(e.currentTarget)[0].parentElement).removeClass('fold')
}

this.groupId = parseInt(this.$(e.currentTarget)[0].id);
this.getdata();
},
 
css
//添加滚动条
#scroll-1{
margin-bottom: .1rem;
height: 4.1rem;
overflow: auto;
}
#scroll-1::-webkit-scrollbar {
width: .05rem;
height: .05rem;
}
#scroll-1::-webkit-scrollbar-button {
background-color: #f3f3f3;
}
#scroll-1::-webkit-scrollbar-track {
background:#f3f3f3;
}
#scroll-1::-webkit-scrollbar-thumb{
background:#969696;
border-radius: .05rem;
}
.accountType{
margin: auto;
padding-bottom: .2rem;
li{
width: 80%;
margin-bottom: 1px;
margin: auto;
}
.lis{
width: 70%;
height: .3rem;
line-height: .3rem;
border-bottom: 1px solid #F4F6F5;
color: #ABAFB2;
// background: red;
margin: auto;
.icon-xiayibu{
float: right;
font-size: 12px;
}
}
.clicks{
background: #29B0E7;
.lis{
border-color: #29B0E7;
color: #fff;
}
}
}

猜你喜欢

转载自www.cnblogs.com/liangru/p/9109851.html