I\'m trying to create a word-wrap in JavaScript using CSS, and the condition is:
If DIV contains one very long word, such as \"asdasfljashglajksgkjasghk
Hope this answers your question
@mixin multilineEllipsis(
$lines-to-show: 2,
$width: 100%,
$font-size: $fontSize-base,
$line-height: 1.6) {
display: block; /* Fallback for non-webkit */
display: -webkit-box;
max-width: $width;
height: $font-size * $line-height * $lines-to-show; /* Fallback for non-webkit */
font-size: $font-size;
-webkit-line-clamp: $lines-to-show;
-webkit-box-orient: vertical;
overflow: hidden;
text-overflow: ellipsis;
}
http://codepen.io/martinwolf/pen/qlFdp http://caniuse.com/#search=-webkit-line-clamp