CSS wrap method

1. English word-wrap

.css{

word-wrap: break-word;
word-break: normal; }

2.Force English word breaks

.css{word-break:break-all; }

< strong>3. A line of text is exceeded and an ellipsis appears

css{

overflow:hidden; text-overflow:ellipsis; white-space:nowrap;< /span>

}

4. Three lines of text exceed, ellipsis appears

css{

display:-webkit-box; -webkit-box-orient:vertical; -webkit-line-clamp: 3; overflow:hidden; span> 

}

Leave a Comment

Your email address will not be published.