Navigation: Fix bookmarks when Grafana is running under subpath (#102679)

* Navigation: Append subpath when searching for bookmarks menu item

* Navigation: Find bookmark item by id
pull/102956/head
Matej Kubinec 4 months ago committed by GitHub
parent f43d39f8ad
commit 1a87f8e5bf
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 2
      public/app/core/components/AppChrome/MegaMenu/MegaMenu.tsx

@ -43,7 +43,7 @@ export const MegaMenu = memo(
.map((item) => enrichWithInteractionTracking(item, state.megaMenuDocked));
if (config.featureToggles.pinNavItems) {
const bookmarksItem = findByUrl(navItems, '/bookmarks');
const bookmarksItem = navItems.find((item) => item.id === 'bookmarks');
if (bookmarksItem) {
// Add children to the bookmarks section
bookmarksItem.children = pinnedItems.reduce((acc: NavModelItem[], url) => {

Loading…
Cancel
Save