mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Inspect: Hide Actions tab when it is empty (#55272)
This commit is contained in:
@@ -65,7 +65,7 @@ export const useInspectTabs = (
|
|||||||
// This is a quick internal hack to allow custom actions in inspect
|
// This is a quick internal hack to allow custom actions in inspect
|
||||||
// For 8.1, something like this should be exposed through grafana/runtime
|
// For 8.1, something like this should be exposed through grafana/runtime
|
||||||
const supplier = (window as any).grafanaPanelInspectActionSupplier as PanelInspectActionSupplier;
|
const supplier = (window as any).grafanaPanelInspectActionSupplier as PanelInspectActionSupplier;
|
||||||
if (supplier && supplier.getActions(panel)) {
|
if (supplier && supplier.getActions(panel)?.length) {
|
||||||
tabs.push({
|
tabs.push({
|
||||||
label: t({ id: 'dashboard.inspect.actions-tab', message: 'Actions' }),
|
label: t({ id: 'dashboard.inspect.actions-tab', message: 'Actions' }),
|
||||||
value: InspectTab.Actions,
|
value: InspectTab.Actions,
|
||||||
|
|||||||
Reference in New Issue
Block a user