Feeling frustrated with a seemingly commonplace issue. Despite the thousands of times it has been asked before, I can't seem to find an answer on Google.
I wanted to neatly display my text within one of my cards, but so far I've only achieved this:
https://i.stack.imgur.com/JcW2Y.png
My current CSS code is as follows:
overflow: hidden;
white-space: pre;
text-overflow: ellipsis;
This is what I aim to achieve:
- Text wraps to a new line when there's a line break in the text: check
- Text displays 3 points ellipsis when there's vertical overflow: check
- Text shifts to next line when there's horizontal overflow: not quite right (refer to line 2 in the image)
Any suggestions on how to make this happen?