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|
%li - if wiki_directory == '/'
= wiki_directory = render 'sidebar_wiki_pages', wiki_pages: wiki_pages
%ul - else
- wiki_pages.each do |wiki_page| %li
%li{ class: params[:id] == wiki_page.slug ? 'active' : '' } = wiki_directory
= link_to namespace_project_wiki_path(@project.namespace, @project, wiki_page) do %ul
= wiki_page.title.capitalize = render 'sidebar_wiki_pages', wiki_pages: wiki_pages
.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