From f959bf7d939add6a9c065247a9df880698d4dc0f Mon Sep 17 00:00:00 2001
From: Jeff Atwood <jatwood@codinghorror.com>
Date: Thu, 23 Oct 2014 10:53:27 -0700
Subject: [PATCH] make sure categories don't wrap in email digests

---
 app/helpers/user_notifications_helper.rb | 4 ++--
 lib/email/styles.rb                      | 2 --
 2 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/app/helpers/user_notifications_helper.rb b/app/helpers/user_notifications_helper.rb
index a6a7efac48e..a86871ba5b2 100644
--- a/app/helpers/user_notifications_helper.rb
+++ b/app/helpers/user_notifications_helper.rb
@@ -83,9 +83,9 @@ module UserNotificationsHelper
 
     result = ""
     if category.parent_category.present?
-      result << "<span style='background-color: ##{category.parent_category.color}; font-size: 12px; padding: 4px 2px; font-weight: bold; margin: 0; width: 2px;'>&nbsp;</span>"
+      result << "<span style='background-color: ##{category.parent_category.color}; font-size: 12px; padding: 4px 2px; font-weight: bold; margin: 0; width: 2px; white-space:nowrap;'>&nbsp;</span>"
     end
-    result << "<span style='background-color: ##{category.color}; color: ##{category.text_color}; font-size: 12px; padding: 4px 6px; font-weight: bold; margin: 0;'>#{category.name}</span>"
+    result << "<span style='background-color: ##{category.color}; color: ##{category.text_color}; font-size: 12px; padding: 4px 6px; font-weight: bold; margin: 0; white-space:nowrap;'>#{category.name}</span>"
     result.html_safe
   end
 end
diff --git a/lib/email/styles.rb b/lib/email/styles.rb
index a333afa1d8c..4e99c6f63fb 100644
--- a/lib/email/styles.rb
+++ b/lib/email/styles.rb
@@ -62,8 +62,6 @@ module Email
       style('.user-avatar img', nil, width: '45', height: '45')
       style('hr', 'background-color: #ddd; height: 1px; border: 1px;')
       style('.rtl', 'direction: rtl;')
-      # we can do this but it does not look right
-      # style('#main', 'font-family:"Helvetica Neue", Helvetica, Arial, sans-serif')
       style('td.body', 'padding-top:5px;', colspan: "2")
       correct_first_body_margin
       correct_footer_style