diff --git a/app/assets/stylesheets/common.css.scss b/app/assets/stylesheets/common.css.scss index b5e7af5dd1..8a848e9ee5 100644 --- a/app/assets/stylesheets/common.css.scss +++ b/app/assets/stylesheets/common.css.scss @@ -309,6 +309,15 @@ h2 { text-decoration: none; } +.count-number { + padding: 2px 5px; + border-radius: 3px; + background: #eee; + margin: 0 2px; + font-size: 11px; + color: #333; +} + /* Rules for greeting bar in the top right corner */ #greeting { diff --git a/app/views/layouts/_inbox.html.erb b/app/views/layouts/_inbox.html.erb index 18716618fa..2af76f9ed2 100644 --- a/app/views/layouts/_inbox.html.erb +++ b/app/views/layouts/_inbox.html.erb @@ -1,7 +1,7 @@ -<% -inbox_attributes = {} -inbox_attributes[:id] = "inboxanchor" -inbox_attributes[:class] = 'greeting-bar-unread' if @user.new_messages.size > 0 -inbox_attributes[:title] = t 'layouts.inbox_tooltip', :count => @user.new_messages.size -%> -<%= link_to t('layouts.inbox', :count => @user.new_messages.size), {:controller => 'message', :action => 'inbox', :display_name => @user.display_name}, inbox_attributes %> +<%= link_to raw(t('layouts.inbox', + :count => @user.new_messages.size > 0 ? "#{@user.new_messages.size}" : '')), + { + :action => 'inbox', + :display_name => @user.display_name, + :controller => 'message' + }, { :id => 'inboxanchor' } %> diff --git a/config/locales/en.yml b/config/locales/en.yml index e89158f2fa..76beb030a0 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -948,7 +948,7 @@ en: welcome_user_link_tooltip: Your user page home: home home_tooltip: Go to home location - inbox: "inbox (%{count})" + inbox: "inbox %{count}" inbox_tooltip: zero: Your inbox contains no unread messages one: Your inbox contains 1 unread message