if have following, how can hide lines don't fit? in example, first 2 lines fit fully, default font, 3rd line fits partially. i'd line disappear (something similar text-overflow, height).
<div style="position: absolute; top: 85%; bottom: 10%; overflow: hidden;"> lorem ipsum dolor sit amet, consectetur adipiscing elit. nullam ac condimentum est. nunc sit amet arcu ut turpis pulvinar fringilla. mauris et quam bibendum, euismod enim sit amet, tempor ante. praesent vel consequat sapien, non tristique massa. </div> this looks me, , i'd rid of line after "mauris et":

the thing know of -webkit-line-clamp. there may other solutions other browsers. can take at: http://css-tricks.com/line-clampin/
i avoid , set height 2 lines of text if can. if line-height 15px, set height 30px 2 lines, provided there isn't other margins or padding.
Comments
Post a Comment