diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-02-18 12:45:46 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-02-18 12:45:46 +0300 |
commit | a7b3560714b4d9cc4ab32dffcd1f74a284b93580 (patch) | |
tree | 7452bd5c3545c2fa67a28aa013835fb4fa071baf /app/helpers/nav/top_nav_helper.rb | |
parent | ee9173579ae56a3dbfe5afe9f9410c65bb327ca7 (diff) |
Add latest changes from gitlab-org/gitlab@14-8-stable-eev14.8.0-rc42
Diffstat (limited to 'app/helpers/nav/top_nav_helper.rb')
-rw-r--r-- | app/helpers/nav/top_nav_helper.rb | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/app/helpers/nav/top_nav_helper.rb b/app/helpers/nav/top_nav_helper.rb index 24102a90a3b..9420c95c9ce 100644 --- a/app/helpers/nav/top_nav_helper.rb +++ b/app/helpers/nav/top_nav_helper.rb @@ -253,14 +253,18 @@ module Nav end def projects_submenu - # These project links come from `app/views/layouts/nav/projects_dropdown/_show.html.haml` builder = ::Gitlab::Nav::TopNavMenuBuilder.new + projects_submenu_items(builder: builder) + builder.build + end + + def projects_submenu_items(builder:) + # These project links come from `app/views/layouts/nav/projects_dropdown/_show.html.haml` builder.add_primary_menu_item(id: 'your', title: _('Your projects'), href: dashboard_projects_path) builder.add_primary_menu_item(id: 'starred', title: _('Starred projects'), href: starred_dashboard_projects_path) builder.add_primary_menu_item(id: 'explore', title: _('Explore projects'), href: explore_root_path) builder.add_primary_menu_item(id: 'topics', title: _('Explore topics'), href: topics_explore_projects_path) builder.add_secondary_menu_item(id: 'create', title: _('Create new project'), href: new_project_path) - builder.build end def groups_submenu |