Merge pull request #9397 from mufaddal7/feature/export-dashboard-component

export DashboardSnapshotComponent from new-relic-dashboard plugin
This commit is contained in:
Ben Lambert
2022-02-08 10:06:06 +01:00
committed by GitHub
4 changed files with 38 additions and 0 deletions
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/plugin-newrelic-dashboard': patch
---
Export DashboardSnapshotComponent from new-relic-dashboard-plugin
+13
View File
@@ -9,6 +9,19 @@ import { BackstagePlugin } from '@backstage/core-plugin-api';
import { Entity } from '@backstage/catalog-model';
import { RouteRef } from '@backstage/core-plugin-api';
// @public
export const DashboardSnapshotComponent: ({
guid,
name,
permalink,
duration,
}: {
guid: string;
name: string;
permalink: string;
duration: number;
}) => JSX.Element;
// Warning: (ae-missing-release-tag) "EntityNewRelicDashboardCard" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
//
// @public (undocumented)
+1
View File
@@ -17,5 +17,6 @@ export {
newRelicDashboardPlugin,
EntityNewRelicDashboardCard,
EntityNewRelicDashboardContent,
DashboardSnapshotComponent,
} from './plugin';
export { isNewRelicDashboardAvailable } from './Router';
+19
View File
@@ -60,3 +60,22 @@ export const EntityNewRelicDashboardCard = newRelicDashboardPlugin.provide(
},
}),
);
/**
* Render dashboard snapshots from Newrelic in backstage. Use dashboards which have the tag `isDashboardPage: true`
*
* @remarks
* This can be helpful for rendering dashboards outside of Entity Catalog.
*
* @public
*/
export const DashboardSnapshotComponent = newRelicDashboardPlugin.provide(
createComponentExtension({
name: 'DashboardSnapshotComponent',
component: {
lazy: () =>
import(
'./components/NewRelicDashboard/DashboardSnapshotList/DashboardSnapshot'
).then(m => m.DashboardSnapshot),
},
}),
);