Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhil Hughes <me@iamphill.com>2017-09-06 13:58:24 +0300
committerTim Zallmann <tzallmann@gitlab.com>2017-09-06 13:58:24 +0300
commitddb3692a2218e97dfcc256e21a0fccc97c5d9a56 (patch)
treeaabb5e0b0d6f37ee068a8804ccef46b994d4afba /app/helpers
parentf497f170697c838747bb7cdaca2d1939f843a00c (diff)
Clean up new navigation templates
Diffstat (limited to 'app/helpers')
-rw-r--r--app/helpers/application_helper.rb4
-rw-r--r--app/helpers/groups_helper.rb2
-rw-r--r--app/helpers/nav_helper.rb21
-rw-r--r--app/helpers/page_layout_helper.rb2
-rw-r--r--app/helpers/projects_helper.rb2
5 files changed, 5 insertions, 26 deletions
diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb
index 017df8f6794..8d02d5de5c3 100644
--- a/app/helpers/application_helper.rb
+++ b/app/helpers/application_helper.rb
@@ -302,10 +302,6 @@ module ApplicationHelper
end
end
- def show_new_nav?
- true
- end
-
def collapsed_sidebar?
cookies["sidebar_collapsed"] == "true"
end
diff --git a/app/helpers/groups_helper.rb b/app/helpers/groups_helper.rb
index dd159d12aa0..c4c41eac5db 100644
--- a/app/helpers/groups_helper.rb
+++ b/app/helpers/groups_helper.rb
@@ -68,7 +68,7 @@ module GroupsHelper
def group_title_link(group, hidable: false)
link_to(group_path(group), class: "group-path #{'hidable' if hidable}") do
output =
- if show_new_nav? && !Rails.env.test?
+ if !Rails.env.test?
image_tag(group_icon(group), class: "avatar-tile", width: 16, height: 16)
else
""
diff --git a/app/helpers/nav_helper.rb b/app/helpers/nav_helper.rb
index 73b3386fe9c..a23a43c9f43 100644
--- a/app/helpers/nav_helper.rb
+++ b/app/helpers/nav_helper.rb
@@ -1,8 +1,8 @@
module NavHelper
def page_with_sidebar_class
class_name = page_gutter_class
- class_name << 'page-with-new-sidebar' if defined?(@new_sidebar) && @new_sidebar
- class_name << 'page-with-icon-sidebar' if collapsed_sidebar? && @new_sidebar
+ class_name << 'page-with-new-sidebar' if defined?(@left_sidebar) && @left_sidebar
+ class_name << 'page-with-icon-sidebar' if collapsed_sidebar? && @left_sidebar
class_name
end
@@ -30,23 +30,6 @@ module NavHelper
end
end
- def nav_header_class
- class_names = []
- class_names << 'with-horizontal-nav' if defined?(nav) && nav
-
- class_names
- end
-
- def layout_nav_class
- return 'page-with-new-nav' if show_new_nav?
-
- class_names = []
- class_names << 'page-with-layout-nav' if defined?(nav) && nav
- class_names << 'page-with-sub-nav' if content_for?(:sub_nav)
-
- class_names
- end
-
def nav_control_class
"nav-control" if current_user
end
diff --git a/app/helpers/page_layout_helper.rb b/app/helpers/page_layout_helper.rb
index b30b2eb1d03..d83c7411c9d 100644
--- a/app/helpers/page_layout_helper.rb
+++ b/app/helpers/page_layout_helper.rb
@@ -4,7 +4,7 @@ module PageLayoutHelper
@page_title.push(*titles.compact) if titles.any?
- if show_new_nav? && titles.any? && !defined?(@breadcrumb_title)
+ if titles.any? && !defined?(@breadcrumb_title)
@breadcrumb_title = @page_title.last
end
diff --git a/app/helpers/projects_helper.rb b/app/helpers/projects_helper.rb
index 02fe82ea872..cec7656773c 100644
--- a/app/helpers/projects_helper.rb
+++ b/app/helpers/projects_helper.rb
@@ -62,7 +62,7 @@ module ProjectsHelper
project_link = link_to project_path(project), { class: "project-item-select-holder" } do
output =
- if show_new_nav? && !Rails.env.test?
+ if !Rails.env.test?
project_icon(project, alt: project.name, class: 'avatar-tile', width: 16, height: 16)
else
""