nicely truncate HTML content