summaryrefslogtreecommitdiff
path: root/app/helpers
diff options
context:
space:
mode:
authorPhil Hughes <me@iamphill.com>2017-08-17 10:42:04 +0100
committerPhil Hughes <me@iamphill.com>2017-08-18 11:07:05 +0100
commitdae629e5e9a75ef0594399b46191306dcbaab90b (patch)
tree153bc29edb3732c87cfa40faf4ed591b560d4e74 /app/helpers
parenta10cc2202dffcf8b4a7bc7db22757ac83bf95eb4 (diff)
downloadgitlab-ce-dae629e5e9a75ef0594399b46191306dcbaab90b.tar.gz
fix some inconsistencies with the breadcrumbs
Diffstat (limited to 'app/helpers')
-rw-r--r--app/helpers/groups_helper.rb2
-rw-r--r--app/helpers/issuables_helper.rb19
-rw-r--r--app/helpers/projects_helper.rb2
3 files changed, 16 insertions, 7 deletions
diff --git a/app/helpers/groups_helper.rb b/app/helpers/groups_helper.rb
index 51acd557ea7..7f43e4106fc 100644
--- a/app/helpers/groups_helper.rb
+++ b/app/helpers/groups_helper.rb
@@ -22,7 +22,7 @@ module GroupsHelper
full_title += if show_new_nav?
breadcrumb_list_item group_title_link(parent, hidable: false)
else
- group_title_link(parent, hidable: true)
+ "#{group_title_link(parent, hidable: true)} <span class='hidable'> / </span>".html_safe
end
end
end
diff --git a/app/helpers/issuables_helper.rb b/app/helpers/issuables_helper.rb
index 197c90c4081..eba8aed05d3 100644
--- a/app/helpers/issuables_helper.rb
+++ b/app/helpers/issuables_helper.rb
@@ -126,12 +126,21 @@ module IssuablesHelper
end
def issuable_meta(issuable, project, text)
- output = content_tag(:strong, class: "identifier") do
- concat("#{text} ")
- concat(to_url_reference(issuable))
+ output = ""
+
+ unless show_new_nav?
+ output << content_tag(:strong, class: "identifier") do
+ concat("#{text} ")
+ concat(to_url_reference(issuable))
+ end
end
- output << " opened #{time_ago_with_tooltip(issuable.created_at)} by ".html_safe
+ opened_text = if show_new_nav?
+ "Opened"
+ else
+ " opened"
+ end
+ output << "#{opened_text} #{time_ago_with_tooltip(issuable.created_at)} by ".html_safe
output << content_tag(:strong) do
author_output = link_to_member(project, issuable.author, size: 24, mobile_classes: "hidden-xs", tooltip: true)
author_output << link_to_member(project, issuable.author, size: 24, by_username: true, avatar: false, mobile_classes: "hidden-sm hidden-md hidden-lg")
@@ -141,7 +150,7 @@ module IssuablesHelper
output << content_tag(:span, (issuable.task_status if issuable.tasks?), id: "task_status", class: "hidden-xs hidden-sm")
output << content_tag(:span, (issuable.task_status_short if issuable.tasks?), id: "task_status_short", class: "hidden-md hidden-lg")
- output
+ output.html_safe
end
def issuable_todo(issuable)
diff --git a/app/helpers/projects_helper.rb b/app/helpers/projects_helper.rb
index cd62835fd29..867f3fadfb9 100644
--- a/app/helpers/projects_helper.rb
+++ b/app/helpers/projects_helper.rb
@@ -81,7 +81,7 @@ module ProjectsHelper
end
end
- "#{namespace_link} #{project_link}".html_safe
+ "#{namespace_link} #{('/' unless show_new_nav?)} #{project_link}".html_safe
end
def remove_project_message(project)