Truncated text
A minor little web experiment: truncated text. Resize the window and it wraps the text in a div so that only the first line shows.
A minor little web experiment: truncated text. Resize the window and it wraps the text in a div so that only the first line shows.
Erm - it doesn’t work until you refresh the window (in FF at least). If you resize then the boxes get bigger, but then if you hit Refresh they go back to 1 line.
25 minutes later
mrben: WFM in both Linux and Windows FF?
66 minutes later
WFM in Galeon.
last.fm do something similar in their lists: see http://www.last.fm/user/wjt , for instance. They appear to use tables (ick!), but it might be worth studying that.
105 minutes later
resiak: I believe in this case it would make sense for those tables to, well, use table tags.
4 hours later
jepp: agreed.
resiak: their technique doesn’t rely on tableness, and it’s pure CSS. Neat, and I’ve linked it from the truncated-text article; it relies on you being prepared to specify the line height, though.
5 hours later
Cool stuff! How about adding a control to “untruncate” the text? I developed an interesting method to do so: http://barelyfitz.com/projects/truncate/
7 hours later
Nice one. But to finish it off you really need an ellipsis at the end of the truncated text.
26 hours later
It seems to make resizing the browser (in my case Mozilla 1.7.12) slow and somewhat jerky. The extra text doesn’t appear straight away either.
DG
2 days later
I can confirm mrben’s problem in FF1.0 on Mac.
4 days later