This commit is contained in:
2025-12-29 14:35:17 +08:00
parent b1b59a96f2
commit 005457e13e
6 changed files with 25 additions and 18 deletions

View File

@@ -55,4 +55,10 @@
/* 确保p标签是块级且换行正常 */
display: block;
word-wrap: break-word;
white-space: nowrap;
/* 2. 超出元素宽度的内容隐藏 */
overflow: hidden;
/* 3. 将超出的文本替换为省略号... */
text-overflow: ellipsis;
/* 可选:给元素设置一个固定宽度(确保省略效果生效) */
}