Commit 91e1701b authored by Alex Braha Stoll's avatar Alex Braha Stoll

Remove root directory name from the sidebar of wikis

parent c7294dde
...@@ -13,13 +13,15 @@ ...@@ -13,13 +13,15 @@
.block.block-first .block.block-first
%ul.wiki-pages %ul.wiki-pages
- @sidebar_wiki_directories.each do |wiki_directory, wiki_pages| - @sidebar_wiki_directories.each do |wiki_directory, wiki_pages|
- if wiki_directory == '/'
= render 'sidebar_wiki_pages', wiki_pages: wiki_pages
- else
%li %li
= wiki_directory = wiki_directory
%ul %ul
- wiki_pages.each do |wiki_page| = render 'sidebar_wiki_pages', wiki_pages: wiki_pages
%li{ class: params[:id] == wiki_page.slug ? 'active' : '' }
= link_to namespace_project_wiki_path(@project.namespace, @project, wiki_page) do
= wiki_page.title.capitalize
.block .block
= link_to namespace_project_wikis_pages_path(@project.namespace, @project), class: 'btn btn-block' do = link_to namespace_project_wikis_pages_path(@project.namespace, @project), class: 'btn btn-block' do
More Pages More Pages
......
- wiki_pages.each do |wiki_page|
%li{ class: params[:id] == wiki_page.slug ? 'active' : '' }
= link_to namespace_project_wiki_path(@project.namespace, @project, wiki_page) do
= wiki_page.title.capitalize
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment