Css3 multi-row ellipsis, css3 multi-row
-Webkit-line-clamp Overview:
-Webkit-line-clamp is an unsupported WebKit property that does not appear in the CSS specification draft.
Limit the number of lines of text displayed on a block element. To achieve this effect, it needs to combine other external WebKit attributes. Common attributes:
display: -webkit-box;
Attributes that must be combinedTo display objects as auto scaling box models.
-webkit-box-orient
Attributes that must be combined, Set or retrieve the arrangement of child elements of the telescopic box object.
- Text-overflow, where multiple lines of text can be used, use the ellipsis "..." to hide text beyond the range.
Syntax:
-Webkit-line-clamp: <Number>
Default Value:? ? Unclear;
Applicable: Block Element
Inheritance: None
Animation: No
Calculated value: Specified value
Valid value:
-
<Number>:
-
The number of lines of text displayed by the block element.
* Descriptions of newly added attributes in CSS3 may be incorrect and changed. This attribute is for reference only and is continuously updated.
Compatibility:
Supported versions/types |
IE |
Firefox |
Safari |
Chrome |
Opera |
Desktop |
No |
No |
Yes |
Yes |
Yes (webkit) |
Mobile Terminal |
No |
No |
Yes |
Yes |
? |
<! Doctype html>