当前位置:网站首页>深度选择器
深度选择器
2022-04-23 09:54:00 【YoungMan_09】
项目开发过程中,经常会使用到第三方组件库的组件,以便快捷的构建功能模块。
例如;使用 Element UI 的走马灯(轮播图)组件
<el-carousel height="150px">
<el-carousel-item v-for="item in 4" :key="item">
<h3 class="small">{
{ item }}</h3>
</el-carousel-item>
</el-carousel>
这个时候想修改左右箭头指示器的样式或者偏移位置

查看自带的样式代码

无论是直接使用 button 标签选择器 还是其 类名 都无法选到来修改样式
这是因为在style中使用了 less(scss) 和 scoped
这个时候就需要用到 深度选择器了
例如,修改button大小和位置,使用::v-deep
::v-deep .el-carousel__arrow--left {
width: 50px;
height: 50px;
left: 100px;
background-image: url('~@/assets/images/indeximg/left.png');
}
::v-deep .el-carousel__arrow--right {
right: 100px;
width: 50px;
height: 50px;
background-image: url('~@/assets/images/indeximg/right.png');
}
还有其它写法如 >>> 或者是 /deep/,但是这里都不起作用,所以用::v-deep
简单记录一下
版权声明
本文为[YoungMan_09]所创,转载请带上原文链接,感谢
https://blog.csdn.net/YoungMan_09/article/details/124183560
边栏推荐
- Computer network security experiment II DNS protocol vulnerability utilization experiment
- Comparison of overloading, rewriting and hiding
- Redis expired key cleaning and deletion policy summary
- Solving Lucas number and combination theorem
- Golang force buckle leetcode 396 Rotation function
- Go语言实践模式 - 函数选项模式(Functional Options Pattern)
- Redis 异常 read error on connection 解决方案
- Construire neuf capacités de fabrication agile à l'ère métacosmique
- Custom login failure handling
- Easy to understand subset DP
猜你喜欢

实践六 Windows操作系统安全攻防

Custom login failure handling

正大国际讲解道琼斯工业指数到底是什么?

Leetcode0587. Install fence

SAP salv14 background output salv data can directly save files and send emails (with sorting, hyperlink and filtering format)

Epidemic prevention registration applet

Yarn资源调度器

Leetcode question bank 78 Subset (recursive C implementation)

Construire neuf capacités de fabrication agile à l'ère métacosmique

Random neurons and random depth of dropout Technology
随机推荐
JS scope, scope chain, global variables and local variables
JS DOM event
SAP pi / PO soap2proxy consumption external WS example
Solving Lucas number and combination theorem
Odoo 服务器搭建备忘
SAP pi / PO function operation status monitoring and inspection
JS what is an event? Event three elements and operation elements
第二章 In-Memory 体系结构 (IM-2.2)
杰理之通常程序异常情况有哪些?【篇】
kernel-pwn学习(3)--ret2user&&kernel ROP&&QWB2018-core
Code source daily question div1 (701-707)
理解作用域
Mobius inversion
P1390 sum of common divisor (Mobius inversion)
Amazon cloud technology entry Resource Center, easy access to the cloud from 0 to 1
Setnx command execution failed due to full redis memory
(Extended) bsgs and higher order congruence equation
通过流式数据集成实现数据价值(4)-流数据管道
SAP CR transmission request sequence and dependency check
Three ways to create objects in JS