CSS 文字超出显示滚动条

1、布局结构

html 复制代码
<view class="tes" style="margin-top: 15rpx;">
	<p v-html="conten" class="conten"></p>
</view>

conten 里是内容

2、页面样式

css 复制代码
	.tes::-webkit-scrollbar-track-piece {
		background-color: rgba(0, 0, 0, 0);
		border-left: 1px solid rgba(0, 0, 0, 0);
	}

	.tes::-webkit-scrollbar {
		display: block;
		width: 5px;
		height: 10px;
		-webkit-margin-bottom-collapse: 12px;
		-webkit-border-radius: 5px;
		-moz-border-radius: 5px;
		border-radius: 5px;
	}

	.tes::-webkit-scrollbar-thumb {
		background-color: #b2b2b2;
		background-clip: padding-box;
		-webkit-border-radius: 5px;
		-moz-border-radius: 5px;
		border-radius: 5px;
		min-height: 28px;
	}

	.tes::-webkit-scrollbar-thumb:hover {
		background-color: #e6e6e6;
		-webkit-border-radius: 5px;
		-moz-border-radius: 5px;
		border-radius: 5px;
	}

可以通过改变css 中的颜色,判断代码都是负责哪一部分

相关推荐
Lanwarf-前端开发1 小时前
Vue3 + Canvas/WebGL 雷达扫描可视化实战:PPI、RHI、VOL、SVOL 四种模式原理与实现
前端·javascript·vue.js·webgl
FRing032 小时前
vue3干货总结2(vue3生命周期、父子通信、模版引用、provide和inject)
开发语言·前端·vue.js·vue3
锋行天下3 小时前
langgraph 全栈项目(三)
前端·人工智能·后端
YIAN4 小时前
从 LangChain 到 DeepAgents:手把手拆解 createAgent、Middleware 与复杂 Agent
javascript·langchain·deepseek
锋行天下4 小时前
langgraph 全栈项目(二)
前端·人工智能·后端
冬夜Zis5 小时前
顺着作用域链和 outer 指针,一次性看懂闭包底层逻辑
javascript
Ceelog5 小时前
Mac 上怎么找出并安全清理旧的 node_modules?(实测 304 个占 66.3 GB)
javascript
锋行天下5 小时前
langgraph全栈项目(一)
前端·人工智能·后端
叼烟扛炮6 小时前
[LangChain] 学习笔记(15):为什么你的重试没用——429、抖动、fallback 与熔断
java·服务器·前端