From 6c8127c41bafa3bb22ab6dd94e0754684e0e48c7 Mon Sep 17 00:00:00 2001 From: AurelioAHeckert Date: Fri, 2 May 2008 14:56:37 +0000 Subject: [PATCH] ActionItem360: Theme Zen3 56% --- app/models/user.rb | 5 +++++ app/views/shared/user_menu.rhtml | 2 +- public/designs/themes/zen3/stylesheets/help.css | 1 + public/designs/themes/zen3/stylesheets/menu.css | 16 ++++++++++++---- 4 files changed, 19 insertions(+), 5 deletions(-) diff --git a/app/models/user.rb b/app/models/user.rb index d6f1c48..0e170ee 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -109,6 +109,11 @@ class User < ActiveRecord::Base def name person.name end + + def first_name + re = '[-+*_\s\'ยด"]' + person.name.gsub(/^#{re}*/,'').split(/#{re}/)[0] + end protected # before filter diff --git a/app/views/shared/user_menu.rhtml b/app/views/shared/user_menu.rhtml index 69d85dd..65f861d 100644 --- a/app/views/shared/user_menu.rhtml +++ b/app/views/shared/user_menu.rhtml @@ -9,7 +9,7 @@ (current_user.person.image)? current_user.person.image.public_filename(:icon) : "/images/icons-bar/photo.png" %>" alt="<%= current_user.name %> Icon-Photo" title="" height="20" border="0"/> - <%= _("%s's Menu") % current_user.name %> + <%= _("%s's Menu") % current_user.first_name %>
diff --git a/public/designs/themes/zen3/stylesheets/help.css b/public/designs/themes/zen3/stylesheets/help.css index b8d8588..d078622 100644 --- a/public/designs/themes/zen3/stylesheets/help.css +++ b/public/designs/themes/zen3/stylesheets/help.css @@ -3,6 +3,7 @@ background: url(../images/helper-question.gif) no-repeat; width: 36px; height: 30px; + top: 0px; } #btShowHelp.help-off { diff --git a/public/designs/themes/zen3/stylesheets/menu.css b/public/designs/themes/zen3/stylesheets/menu.css index 3d83a1b..4c3ed29 100644 --- a/public/designs/themes/zen3/stylesheets/menu.css +++ b/public/designs/themes/zen3/stylesheets/menu.css @@ -58,6 +58,7 @@ top: 4px; right: 350px; width: 150px; + overflow: hidden; padding: 2px 0px; border: 1px solid transparent; } @@ -68,17 +69,24 @@ #user_menu_head { overflow: hidden; - line-height: 20px + line-height: 20px; + padding-left: 4px; +} + +#user_menu_head img { + margin-left: -20px; } -#user_menu_head a { +#user_menu_head span { color: #FFF; + opacity: 0.6; + filter: alpha(opacity=60); } #user_menu a { color: #FFF; - padding-top: 2px; - padding-bottom: 2px; + padding-top: 3px; + padding-bottom: 1px; } #user_menu a:hover { background: #FCAF3E; -- libgit2 0.21.2