diff options
28 files changed, 8 insertions, 25 deletions
diff --git a/app/helpers/page_layout_helper.rb b/app/helpers/page_layout_helper.rb index 3286a92a8a7..c9f5166d0a4 100644 --- a/app/helpers/page_layout_helper.rb +++ b/app/helpers/page_layout_helper.rb @@ -4,6 +4,10 @@ module PageLayoutHelper @page_title.push(*titles.compact) if titles.any? + if show_new_nav? && titles.any? && !defined?(@breadcrumb_title) + @breadcrumb_title = @page_title.first + end + # Segments are seperated by middot @page_title.join(" \u00b7 ") end diff --git a/app/views/admin/appearances/show.html.haml b/app/views/admin/appearances/show.html.haml index 3d1929a8b70..454b779842c 100644 --- a/app/views/admin/appearances/show.html.haml +++ b/app/views/admin/appearances/show.html.haml @@ -1,4 +1,3 @@ -- @breadcrumb_title = "Appearance" - page_title "Appearance" %h3.page-title diff --git a/app/views/admin/application_settings/show.html.haml b/app/views/admin/application_settings/show.html.haml index 2e7f47e261a..ecc46d86afe 100644 --- a/app/views/admin/application_settings/show.html.haml +++ b/app/views/admin/application_settings/show.html.haml @@ -1,4 +1,3 @@ -- @breadcrumb_title = "Settings" - page_title "Settings" %h3.page-title Settings diff --git a/app/views/admin/applications/edit.html.haml b/app/views/admin/applications/edit.html.haml index c596866bde2..c9ad44be1e9 100644 --- a/app/views/admin/applications/edit.html.haml +++ b/app/views/admin/applications/edit.html.haml @@ -1,4 +1,6 @@ - page_title "Edit", @application.name, "Applications" +- @breadcrumb_title = "Applications" + %h3.page-title Edit application - @url = admin_application_path(@application) = render 'form', application: @application diff --git a/app/views/admin/applications/new.html.haml b/app/views/admin/applications/new.html.haml index 6310d89bd6b..a5d89ed9857 100644 --- a/app/views/admin/applications/new.html.haml +++ b/app/views/admin/applications/new.html.haml @@ -1,4 +1,6 @@ - page_title "New Application" +- @breadcrumb_title = "Applications" + %h3.page-title New application - @url = admin_applications_path = render 'form', application: @application diff --git a/app/views/admin/hooks/index.html.haml b/app/views/admin/hooks/index.html.haml index 89592d4464e..e92b8bc39f4 100644 --- a/app/views/admin/hooks/index.html.haml +++ b/app/views/admin/hooks/index.html.haml @@ -1,4 +1,3 @@ -- @breadcrumb_title = "System Hooks" - page_title 'System Hooks' %h3.page-title System hooks diff --git a/app/views/admin/services/index.html.haml b/app/views/admin/services/index.html.haml index 4b5147b9cac..50132572096 100644 --- a/app/views/admin/services/index.html.haml +++ b/app/views/admin/services/index.html.haml @@ -1,4 +1,3 @@ -- @breadcrumb_title = "Service Templates" - page_title "Service Templates" %h3.page-title Service templates %p.light Service template allows you to set default values for project services diff --git a/app/views/dashboard/activity.html.haml b/app/views/dashboard/activity.html.haml index 60dfa75351b..ad35d05c29a 100644 --- a/app/views/dashboard/activity.html.haml +++ b/app/views/dashboard/activity.html.haml @@ -1,4 +1,3 @@ -- @breadcrumb_title = "Activity" - @hide_top_links = true - @no_container = true diff --git a/app/views/dashboard/issues.html.haml b/app/views/dashboard/issues.html.haml index d2fb4ab101e..52e0012fd7d 100644 --- a/app/views/dashboard/issues.html.haml +++ b/app/views/dashboard/issues.html.haml @@ -1,4 +1,3 @@ -- @breadcrumb_title = "Issues" - @hide_top_links = true - page_title "Issues" - header_title "Issues", issues_dashboard_path(assignee_id: current_user.id) diff --git a/app/views/dashboard/merge_requests.html.haml b/app/views/dashboard/merge_requests.html.haml index df2470a0118..c3fe14da2b2 100644 --- a/app/views/dashboard/merge_requests.html.haml +++ b/app/views/dashboard/merge_requests.html.haml @@ -1,4 +1,3 @@ -- @breadcrumb_title = "Merge Requests" - @hide_top_links = true - page_title "Merge Requests" - header_title "Merge Requests", merge_requests_dashboard_path(assignee_id: current_user.id) diff --git a/app/views/dashboard/projects/index.html.haml b/app/views/dashboard/projects/index.html.haml index 7ac6cf06fb9..ec6cb1a9624 100644 --- a/app/views/dashboard/projects/index.html.haml +++ b/app/views/dashboard/projects/index.html.haml @@ -1,6 +1,5 @@ - @no_container = true - @hide_top_links = true -- @breadcrumb_title = "Projects" = content_for :meta_tags do = auto_discovery_link_tag(:atom, dashboard_projects_url(rss_url_options), title: "All activity") diff --git a/app/views/groups/activity.html.haml b/app/views/groups/activity.html.haml index adc379e11d4..3969e56f937 100644 --- a/app/views/groups/activity.html.haml +++ b/app/views/groups/activity.html.haml @@ -1,4 +1,3 @@ -- @breadcrumb_title = "Activity" = content_for :meta_tags do = auto_discovery_link_tag(:atom, group_url(@group, rss_url_options), title: "#{@group.name} activity") diff --git a/app/views/groups/edit.html.haml b/app/views/groups/edit.html.haml index 5cb4d05960d..9ebb3894c55 100644 --- a/app/views/groups/edit.html.haml +++ b/app/views/groups/edit.html.haml @@ -1,4 +1,3 @@ -- @breadcrumb_title = "Settings" = render "groups/settings_head" .panel.panel-default.prepend-top-default .panel-heading diff --git a/app/views/groups/group_members/index.html.haml b/app/views/groups/group_members/index.html.haml index 9e6c0b27834..ad9d5562ded 100644 --- a/app/views/groups/group_members/index.html.haml +++ b/app/views/groups/group_members/index.html.haml @@ -1,4 +1,3 @@ -- @breadcrumb_title = "Members" - page_title "Members" .project-members-page.prepend-top-default diff --git a/app/views/groups/issues.html.haml b/app/views/groups/issues.html.haml index a7003f6cd33..735d9390699 100644 --- a/app/views/groups/issues.html.haml +++ b/app/views/groups/issues.html.haml @@ -1,4 +1,3 @@ -- @breadcrumb_title = "Issues" - page_title "Issues" - group_issues_exists = group_issues(@group).exists? = render "head_issues" diff --git a/app/views/groups/merge_requests.html.haml b/app/views/groups/merge_requests.html.haml index a43061dacfc..997c82c77d9 100644 --- a/app/views/groups/merge_requests.html.haml +++ b/app/views/groups/merge_requests.html.haml @@ -1,4 +1,3 @@ -- @breadcrumb_title = "Merge Requests" - page_title "Merge Requests" - if show_new_nav? && current_user diff --git a/app/views/profiles/accounts/show.html.haml b/app/views/profiles/accounts/show.html.haml index c5917ae5aeb..ed079ed7dfb 100644 --- a/app/views/profiles/accounts/show.html.haml +++ b/app/views/profiles/accounts/show.html.haml @@ -1,4 +1,3 @@ -- @breadcrumb_title = "Account" - page_title "Account" - @content_class = "limit-container-width" unless fluid_layout = render 'profiles/head' diff --git a/app/views/profiles/audit_log.html.haml b/app/views/profiles/audit_log.html.haml index 00d61e5b925..1a392e29e2a 100644 --- a/app/views/profiles/audit_log.html.haml +++ b/app/views/profiles/audit_log.html.haml @@ -1,4 +1,3 @@ -- @breadcrumb_title = "Authentication log" - page_title "Authentication log" - @content_class = "limit-container-width" unless fluid_layout = render 'profiles/head' diff --git a/app/views/profiles/two_factor_auths/show.html.haml b/app/views/profiles/two_factor_auths/show.html.haml index 326a87f579f..037cb30efb9 100644 --- a/app/views/profiles/two_factor_auths/show.html.haml +++ b/app/views/profiles/two_factor_auths/show.html.haml @@ -3,7 +3,6 @@ - add_to_breadcrumbs("Account", profile_account_path) - else - header_title "Two-Factor Authentication", profile_two_factor_auth_path -- @breadcrumb_title = "Two-Factor Authentication" - @content_class = "limit-container-width" unless fluid_layout = render 'profiles/head' diff --git a/app/views/projects/activity.html.haml b/app/views/projects/activity.html.haml index dc79be269c6..9e2688e492e 100644 --- a/app/views/projects/activity.html.haml +++ b/app/views/projects/activity.html.haml @@ -1,5 +1,4 @@ - @no_container = true -- @breadcrumb_title = "Activity" - if show_new_nav? - add_to_breadcrumbs("Project", project_path(@project)) diff --git a/app/views/projects/boards/_show.html.haml b/app/views/projects/boards/_show.html.haml index 49a92240f91..2076e46fde8 100644 --- a/app/views/projects/boards/_show.html.haml +++ b/app/views/projects/boards/_show.html.haml @@ -1,6 +1,5 @@ - @no_container = true - @content_class = "issue-boards-content" -- @breadcrumb_title = "Board" - page_title "Boards" - if show_new_nav? diff --git a/app/views/projects/edit.html.haml b/app/views/projects/edit.html.haml index 9f4d0faf3a2..087cb804449 100644 --- a/app/views/projects/edit.html.haml +++ b/app/views/projects/edit.html.haml @@ -1,5 +1,4 @@ - @content_class = "limit-container-width" unless fluid_layout -- @breadcrumb_title = "Settings" = render "projects/settings/head" .project-edit-container diff --git a/app/views/projects/graphs/charts.html.haml b/app/views/projects/graphs/charts.html.haml index 36920260ae8..249b9d82ad9 100644 --- a/app/views/projects/graphs/charts.html.haml +++ b/app/views/projects/graphs/charts.html.haml @@ -1,5 +1,4 @@ - @no_container = true -- @breadcrumb_title = "Charts" - page_title "Charts" - if show_new_nav? - add_to_breadcrumbs("Repository", project_tree_path(@project)) diff --git a/app/views/projects/graphs/show.html.haml b/app/views/projects/graphs/show.html.haml index 2d37963fb7d..4256a8c4d7e 100644 --- a/app/views/projects/graphs/show.html.haml +++ b/app/views/projects/graphs/show.html.haml @@ -1,5 +1,4 @@ - @no_container = true -- @breadcrumb_title = "Contributors" - page_title "Contributors" - content_for :page_specific_javascripts do = page_specific_javascript_bundle_tag('common_d3') diff --git a/app/views/projects/network/show.html.haml b/app/views/projects/network/show.html.haml index 314914fd7b2..f660c156297 100644 --- a/app/views/projects/network/show.html.haml +++ b/app/views/projects/network/show.html.haml @@ -1,4 +1,3 @@ -- @breadcrumb_title = "Graph" - page_title "Graph", @ref - content_for :page_specific_javascripts do = page_specific_javascript_bundle_tag('network') diff --git a/app/views/projects/pipelines/charts.html.haml b/app/views/projects/pipelines/charts.html.haml index 7cc43501497..fd3ad69d85d 100644 --- a/app/views/projects/pipelines/charts.html.haml +++ b/app/views/projects/pipelines/charts.html.haml @@ -1,5 +1,4 @@ - @no_container = true -- @breadcrumb_title = "Charts" - page_title _("Charts"), _("Pipelines") - if show_new_nav? - add_to_breadcrumbs("Pipelines", project_pipelines_path(@project)) diff --git a/app/views/projects/project_members/index.html.haml b/app/views/projects/project_members/index.html.haml index 74b10574da0..9f7c5a315eb 100644 --- a/app/views/projects/project_members/index.html.haml +++ b/app/views/projects/project_members/index.html.haml @@ -1,4 +1,3 @@ -- @breadcrumb_title = "Members" - page_title "Members" - if show_new_nav? diff --git a/app/views/projects/settings/ci_cd/show.html.haml b/app/views/projects/settings/ci_cd/show.html.haml index 3f118f8933d..0c4130857da 100644 --- a/app/views/projects/settings/ci_cd/show.html.haml +++ b/app/views/projects/settings/ci_cd/show.html.haml @@ -1,5 +1,4 @@ - @content_class = "limit-container-width" unless fluid_layout -- @breadcrumb_title = "Pipelines" - page_title "Pipelines" - if show_new_nav? |