From 984768fcee2332ffb78a46d72f9ab8c649e33dbf Mon Sep 17 00:00:00 2001 From: evazion Date: Thu, 27 Feb 2020 20:02:00 -0600 Subject: [PATCH] aliases/implications: share secondary links with tags index. --- app/helpers/application_helper.rb | 8 +------- app/views/tag_aliases/_secondary_links.html.erb | 5 ----- app/views/tag_aliases/index.html.erb | 2 +- app/views/tag_aliases/show.html.erb | 2 +- app/views/tag_implications/_secondary_links.html.erb | 5 ----- app/views/tag_implications/index.html.erb | 2 +- app/views/tag_implications/show.html.erb | 2 +- app/views/tags/_secondary_links.html.erb | 3 ++- 8 files changed, 7 insertions(+), 22 deletions(-) delete mode 100644 app/views/tag_aliases/_secondary_links.html.erb delete mode 100644 app/views/tag_implications/_secondary_links.html.erb diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 8cb799535..3a18abad1 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -356,7 +356,7 @@ module ApplicationHelper when "artists", "artist_versions" /^\/artist/ - when "tags" + when "tags", "tag_aliases", "tag_implications" /^\/tags/ when "pools", "pool_versions" @@ -365,12 +365,6 @@ module ApplicationHelper when "moderator/dashboards" /^\/moderator/ - when "tag_aliases" - /^\/tag_aliases/ - - when "tag_implications", - /^\/tag_implications/ - when "wiki_pages", "wiki_page_versions" /^\/wiki_pages/ diff --git a/app/views/tag_aliases/_secondary_links.html.erb b/app/views/tag_aliases/_secondary_links.html.erb deleted file mode 100644 index 65906f78a..000000000 --- a/app/views/tag_aliases/_secondary_links.html.erb +++ /dev/null @@ -1,5 +0,0 @@ -<% content_for(:secondary_links) do %> - <%= subnav_link_to "Listing", tag_aliases_path %> - <%= subnav_link_to "Request alias", new_bulk_update_request_path %> - <%= subnav_link_to "Help", wiki_page_path("help:tag_aliases") %> -<% end %> diff --git a/app/views/tag_aliases/index.html.erb b/app/views/tag_aliases/index.html.erb index 53a7c784a..3d8fdfe58 100644 --- a/app/views/tag_aliases/index.html.erb +++ b/app/views/tag_aliases/index.html.erb @@ -7,4 +7,4 @@ -<%= render "secondary_links" %> +<%= render "tags/secondary_links" %> diff --git a/app/views/tag_aliases/show.html.erb b/app/views/tag_aliases/show.html.erb index 531d1d9e7..2c4f194d3 100644 --- a/app/views/tag_aliases/show.html.erb +++ b/app/views/tag_aliases/show.html.erb @@ -23,4 +23,4 @@ -<%= render "secondary_links" %> +<%= render "tags/secondary_links" %> diff --git a/app/views/tag_implications/_secondary_links.html.erb b/app/views/tag_implications/_secondary_links.html.erb deleted file mode 100644 index 932cc9e3a..000000000 --- a/app/views/tag_implications/_secondary_links.html.erb +++ /dev/null @@ -1,5 +0,0 @@ -<% content_for(:secondary_links) do %> - <%= subnav_link_to "Listing", tag_implications_path %> - <%= subnav_link_to "Request implication", new_bulk_update_request_path %> - <%= subnav_link_to "Help", wiki_page_path("help:tag_implications") %> -<% end %> diff --git a/app/views/tag_implications/index.html.erb b/app/views/tag_implications/index.html.erb index 2b1a82fc0..108375f92 100644 --- a/app/views/tag_implications/index.html.erb +++ b/app/views/tag_implications/index.html.erb @@ -7,4 +7,4 @@ -<%= render "secondary_links" %> +<%= render "tags/secondary_links" %> diff --git a/app/views/tag_implications/show.html.erb b/app/views/tag_implications/show.html.erb index f4717d050..bcd28565f 100644 --- a/app/views/tag_implications/show.html.erb +++ b/app/views/tag_implications/show.html.erb @@ -23,4 +23,4 @@ -<%= render "secondary_links" %> +<%= render "tags/secondary_links" %> diff --git a/app/views/tags/_secondary_links.html.erb b/app/views/tags/_secondary_links.html.erb index d0565a47b..a4bd9c13e 100644 --- a/app/views/tags/_secondary_links.html.erb +++ b/app/views/tags/_secondary_links.html.erb @@ -1,8 +1,9 @@ <% content_for(:secondary_links) do %> <%= quick_search_form_for(:name_matches, tags_path, "tags", autocomplete: "tag") %> - <%= subnav_link_to "Listing", tags_path %> + <%= subnav_link_to "Tags", tags_path %> <%= subnav_link_to("Aliases", tag_aliases_path) %> <%= subnav_link_to("Implications", tag_implications_path) %> + <%= subnav_link_to "Request alias/implication", new_bulk_update_request_path %> <%= subnav_link_to "Related tags", related_tag_path %> <%= subnav_link_to "Help", wiki_page_path("help:tags") %>