elementU默认轮播图

<template>
<div class="big">
<el-carousel height="250px" >
<el-carousel-item v-for="item in 4" :key="item">
<h3 class="small">{{ item }}</h3>
</el-carousel-item>
</el-carousel>
</div>
</template>
 
<style scoped>
.big{
background: red;
}

/* .el-carousel { */
.big /deep/ .el-carousel__item:nth-child(2n) {
">#99a9bf;
}
.big /deep/ .el-carousel__item:nth-child(2n+1) {
">#d3dce6;
}
.big /deep/ .el-carousel__indicators {
/* // 指示器 */
left: unset;
transform: unset;
right: 2%;
}
.big /deep/ .el-carousel__button {
/* // 指示器按钮 */
width: 15px;
height: 5px;
border: none;
border-radius: 20%;
">rgba(0, 0, 0, 0.2);
}
.big /deep/ .is-active .el-carousel__button {
/* // 指示器**按钮 */
background: skyblue;
width: 40px;
}
/* } */
</style>
posted on 2021-12-17 23:36  巨星太空易  阅读(123)  评论(0)    收藏  举报