]> source.dussan.org Git - redmine.git/commitdiff
Add additional markup to page_header_title to enable better styling (#21947).
authorJean-Philippe Lang <jp_lang@yahoo.fr>
Sat, 19 Mar 2016 09:12:31 +0000 (09:12 +0000)
committerJean-Philippe Lang <jp_lang@yahoo.fr>
Sat, 19 Mar 2016 09:12:31 +0000 (09:12 +0000)
Patch by Jan Schulz-Hofen.

git-svn-id: http://svn.redmine.org/redmine/trunk@15256 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/helpers/application_helper.rb

index f4ce316d172511df141ee9728f088c96ae80bca2..7ad6caec98b96eeaacf395ad995dbafa6f1b8ae4 100644 (file)
@@ -494,8 +494,13 @@ module ApplicationHelper
         end
         b += ancestors.collect {|p| link_to_project(p, {:jump => current_menu_item}, :class => 'ancestor') }
       end
-      b << h(@project)
-      b.join(" \xc2\xbb ").html_safe
+      b << content_tag(:span, h(@project), class: 'current-project')
+      if b.size > 1
+        separator = content_tag(:span, ' &raquo; '.html_safe, class: 'separator')
+        path = safe_join(b[0..-2], separator) + separator
+        b = [content_tag(:span, path.html_safe, class: 'breadcrumbs'), b[-1]]
+      end
+      safe_join b
     end
   end