Get the App
SLTechnology News&Howtos  ›  Servers  › 

How to realize the display of ellipsis in excess of css

Shulou Source: shulou.com Published: 2022-05-31 11:08:17 10月04日 Update

This article mainly introduces how to achieve css beyond the partial display ellipses, with a certain reference value, interested friends can refer to, I hope you read this article after a great harvest, the following let Xiaobian take you to understand.

Show ellipses for excess

//Single-line text.wrap { overflow:hidden;/* overflow: hidden;*/ text-overflow:ellipsis;/* ellipsis */ white-space:nowrap;/* specifies that text in paragraphs does not wrap */}//multi-line text.wrap { width: 100%; overflow: hidden; display: -webkit-box; //displays objects as Auto Scaling Box models * properties that must be combined * -webkit-box-orientation: vertical;//Sets the arrangement of child elements of the expansion box object * properties that must be combined * -webkit-line-clamp: 3; //used to limit the number of lines of text displayed in a block element word-break: break-all;//Let the browser realize newline at any position *break-all to allow newline within words *} Thank you for reading this article carefully, I hope Xiaobian shared "How to achieve more than part of the ellipsis" This article is helpful to everyone, but also hope that everyone will support, pay attention to the industry information channel, more relevant knowledge waiting for you to learn!

Tags: Parts ellipses text articles elements objects attributes values locations interests words at the same time elasticity ways more friends models paragraphs browsers boxes Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno vpn Xiaomi Redmi Shulou Tech Info OPPO Reno