PluginPage: Fix finding root section for standalone pages (#56554)

This commit is contained in:
Torkel Ödegaard
2022-10-07 16:33:36 +02:00
committed by GitHub
parent ff41b9544b
commit 754fc37972
4 changed files with 12 additions and 6 deletions

View File

@ -2,6 +2,7 @@ import { Location as HistoryLocation } from 'history';
import { NavIndex, NavModelItem } from '@grafana/data';
import { config } from '@grafana/runtime';
import { HOME_NAV_ID } from 'app/core/reducers/navModel';
import { buildPluginSectionNav } from './utils';
@ -33,6 +34,10 @@ describe('buildPluginSectionNav', () => {
text: 'Admin',
id: 'admin',
children: [],
parentItem: {
id: HOME_NAV_ID,
text: 'Home',
},
};
const standalonePluginPage = {