diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2016-04-01 18:24:03 +0200 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2016-04-01 18:24:03 +0200 |
commit | dbc96f05d0c7dd6118a0deeea97650417e42917f (patch) | |
tree | 062cae89a699dde449d9fb55bf0aed5df2082cc5 /app/views/layouts/_page.html.haml | |
parent | 18dd525d0f163b65893fd3df7d09185e72fc7a1e (diff) | |
download | gitlab-ce-dbc96f05d0c7dd6118a0deeea97650417e42917f.tar.gz |
Refactor left navigation sidebar to use 2 levels
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'app/views/layouts/_page.html.haml')
-rw-r--r-- | app/views/layouts/_page.html.haml | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/app/views/layouts/_page.html.haml b/app/views/layouts/_page.html.haml index c799e9c588d..fcf61094a25 100644 --- a/app/views/layouts/_page.html.haml +++ b/app/views/layouts/_page.html.haml @@ -8,12 +8,16 @@ .gitlab-text-container %h3 GitLab - - if defined?(sidebar) && sidebar - = render "layouts/nav/#{sidebar}" - - elsif current_user - = render 'layouts/nav/dashboard' + - primary_sidebar = current_user ? 'dashboard' : 'explore' + + - if defined?(sidebar) && sidebar && sidebar != primary_sidebar + .complex-sidebar + .nav-primary + = render "layouts/nav/#{primary_sidebar}" + .nav-secondary + = render "layouts/nav/#{sidebar}" - else - = render 'layouts/nav/explore' + = render "layouts/nav/#{primary_sidebar}" .collapse-nav = render partial: 'layouts/collapse_button' |