From f1a7b63afc1c277db932805e32345c6fedc726f8 Mon Sep 17 00:00:00 2001 From: Robin Ward <robin.ward@gmail.com> Date: Mon, 16 Dec 2013 14:41:59 -0500 Subject: [PATCH] FIX: Large `pre` blocks in emails were increasing the width. --- lib/email/styles.rb | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/email/styles.rb b/lib/email/styles.rb index 8ab76b2efc6..9b5364b3cc8 100644 --- a/lib/email/styles.rb +++ b/lib/email/styles.rb @@ -59,11 +59,10 @@ module Email style('div.digest-post', 'margin-left: 15px; margin-top: 20px; max-width: 694px;') style('div.digest-post h1', 'font-size: 20px;') style('span.footer-notice', 'color:#666; font-size:80%') - style('span.post-count', 'margin: 0 5px; color: #777;') - style('pre', 'white-space: pre-wrap') + style('pre', 'word-wrap: break-word; max-width: 694px;') style('code', 'background-color: #f1f1ff; padding: 2px 5px;') - style('pre code', 'display: block; background-color: #f1f1ff; padding: 5px') + style('pre code', 'display: block; background-color: #f1f1ff; padding: 5px;') end def to_html