@backstage-community/plugin-newrelic-dashboard 0.10.0 → 0.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/dist/alpha/plugin.esm.js +46 -0
- package/dist/alpha/plugin.esm.js.map +1 -0
- package/dist/alpha.d.ts +82 -0
- package/dist/alpha.esm.js +2 -0
- package/dist/alpha.esm.js.map +1 -0
- package/package.json +36 -16
package/CHANGELOG.md
CHANGED
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
|
+
import { ApiBlueprint, createApiFactory, discoveryApiRef, fetchApiRef, createFrontendPlugin } from '@backstage/frontend-plugin-api';
|
|
3
|
+
import { compatWrapper } from '@backstage/core-compat-api';
|
|
4
|
+
import { EntityContentBlueprint, EntityCardBlueprint } from '@backstage/plugin-catalog-react/alpha';
|
|
5
|
+
import { newRelicDashboardApiRef } from '../api/NewRelicDashboardApi.esm.js';
|
|
6
|
+
import { NewRelicDashboardClient } from '../api/NewRelicDashboardClient.esm.js';
|
|
7
|
+
|
|
8
|
+
const newRelicApi = ApiBlueprint.make({
|
|
9
|
+
params: {
|
|
10
|
+
factory: createApiFactory({
|
|
11
|
+
api: newRelicDashboardApiRef,
|
|
12
|
+
deps: {
|
|
13
|
+
discoveryApi: discoveryApiRef,
|
|
14
|
+
fetchApi: fetchApiRef
|
|
15
|
+
},
|
|
16
|
+
factory: ({ discoveryApi, fetchApi }) => new NewRelicDashboardClient({ discoveryApi, fetchApi })
|
|
17
|
+
})
|
|
18
|
+
}
|
|
19
|
+
});
|
|
20
|
+
const newRelicDashboardEntityContent = EntityContentBlueprint.make({
|
|
21
|
+
name: "EntityNewRelicDashboardContent",
|
|
22
|
+
params: {
|
|
23
|
+
defaultPath: "/pull-requests",
|
|
24
|
+
defaultTitle: "Pull Requests",
|
|
25
|
+
loader: () => import('../Router.esm.js').then((m) => compatWrapper(/* @__PURE__ */ jsx(m.Router, {})))
|
|
26
|
+
}
|
|
27
|
+
});
|
|
28
|
+
const newRelicDashboardCard = EntityCardBlueprint.make({
|
|
29
|
+
name: "EntityNewRelicDashboardCard",
|
|
30
|
+
params: {
|
|
31
|
+
loader: async () => import('../components/NewRelicDashboard/DashboardEntityList.esm.js').then(
|
|
32
|
+
(m) => compatWrapper(/* @__PURE__ */ jsx(m.DashboardEntityList, {}))
|
|
33
|
+
)
|
|
34
|
+
}
|
|
35
|
+
});
|
|
36
|
+
var plugin = createFrontendPlugin({
|
|
37
|
+
pluginId: "newrelic",
|
|
38
|
+
extensions: [
|
|
39
|
+
newRelicApi,
|
|
40
|
+
newRelicDashboardEntityContent,
|
|
41
|
+
newRelicDashboardCard
|
|
42
|
+
]
|
|
43
|
+
});
|
|
44
|
+
|
|
45
|
+
export { plugin as default, newRelicApi, newRelicDashboardCard, newRelicDashboardEntityContent };
|
|
46
|
+
//# sourceMappingURL=plugin.esm.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"plugin.esm.js","sources":["../../src/alpha/plugin.tsx"],"sourcesContent":["/*\n * Copyright 2025 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport {\n ApiBlueprint,\n createApiFactory,\n createFrontendPlugin,\n discoveryApiRef,\n fetchApiRef,\n} from '@backstage/frontend-plugin-api';\nimport { compatWrapper } from '@backstage/core-compat-api';\nimport {\n EntityCardBlueprint,\n EntityContentBlueprint,\n} from '@backstage/plugin-catalog-react/alpha';\nimport { newRelicDashboardApiRef, NewRelicDashboardClient } from '../api';\n\n/** @alpha */\nexport const newRelicApi = ApiBlueprint.make({\n params: {\n factory: createApiFactory({\n api: newRelicDashboardApiRef,\n deps: {\n discoveryApi: discoveryApiRef,\n fetchApi: fetchApiRef,\n },\n factory: ({ discoveryApi, fetchApi }) =>\n new NewRelicDashboardClient({ discoveryApi, fetchApi }),\n }),\n },\n});\n\n/** @alpha */\nexport const newRelicDashboardEntityContent = EntityContentBlueprint.make({\n name: 'EntityNewRelicDashboardContent',\n params: {\n defaultPath: '/pull-requests',\n defaultTitle: 'Pull Requests',\n loader: () => import('../Router').then(m => compatWrapper(<m.Router />)),\n },\n});\n\n/** @alpha */\nexport const newRelicDashboardCard = EntityCardBlueprint.make({\n name: 'EntityNewRelicDashboardCard',\n params: {\n loader: async () =>\n import('../components/NewRelicDashboard/DashboardEntityList').then(m =>\n compatWrapper(<m.DashboardEntityList />),\n ),\n },\n});\n\n/** @alpha */\nexport default createFrontendPlugin({\n pluginId: 'newrelic',\n extensions: [\n newRelicApi,\n newRelicDashboardEntityContent,\n newRelicDashboardCard,\n ],\n});\n"],"names":[],"mappings":";;;;;;;AA+Ba,MAAA,WAAA,GAAc,aAAa,IAAK,CAAA;AAAA,EAC3C,MAAQ,EAAA;AAAA,IACN,SAAS,gBAAiB,CAAA;AAAA,MACxB,GAAK,EAAA,uBAAA;AAAA,MACL,IAAM,EAAA;AAAA,QACJ,YAAc,EAAA,eAAA;AAAA,QACd,QAAU,EAAA;AAAA,OACZ;AAAA,MACA,OAAA,EAAS,CAAC,EAAE,YAAc,EAAA,QAAA,EACxB,KAAA,IAAI,uBAAwB,CAAA,EAAE,YAAc,EAAA,QAAA,EAAU;AAAA,KACzD;AAAA;AAEL,CAAC;AAGY,MAAA,8BAAA,GAAiC,uBAAuB,IAAK,CAAA;AAAA,EACxE,IAAM,EAAA,gCAAA;AAAA,EACN,MAAQ,EAAA;AAAA,IACN,WAAa,EAAA,gBAAA;AAAA,IACb,YAAc,EAAA,eAAA;AAAA,IACd,MAAQ,EAAA,MAAM,OAAO,kBAAW,CAAE,CAAA,IAAA,CAAK,CAAK,CAAA,KAAA,aAAA,iBAAe,GAAA,CAAA,CAAA,CAAE,MAAF,EAAA,EAAS,CAAE,CAAC;AAAA;AAE3E,CAAC;AAGY,MAAA,qBAAA,GAAwB,oBAAoB,IAAK,CAAA;AAAA,EAC5D,IAAM,EAAA,6BAAA;AAAA,EACN,MAAQ,EAAA;AAAA,IACN,MAAQ,EAAA,YACN,OAAO,4DAAqD,CAAE,CAAA,IAAA;AAAA,MAAK,OACjE,aAAc,iBAAA,GAAA,CAAC,CAAE,CAAA,mBAAA,EAAF,EAAsB,CAAE;AAAA;AACzC;AAEN,CAAC;AAGD,aAAe,oBAAqB,CAAA;AAAA,EAClC,QAAU,EAAA,UAAA;AAAA,EACV,UAAY,EAAA;AAAA,IACV,WAAA;AAAA,IACA,8BAAA;AAAA,IACA;AAAA;AAEJ,CAAC,CAAA;;;;"}
|
package/dist/alpha.d.ts
ADDED
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import * as _backstage_catalog_model from '@backstage/catalog-model';
|
|
3
|
+
import * as react from 'react';
|
|
4
|
+
import * as _backstage_plugin_catalog_react_alpha from '@backstage/plugin-catalog-react/alpha';
|
|
5
|
+
import * as _backstage_frontend_plugin_api from '@backstage/frontend-plugin-api';
|
|
6
|
+
import * as _backstage_core_plugin_api from '@backstage/core-plugin-api';
|
|
7
|
+
|
|
8
|
+
/** @alpha */
|
|
9
|
+
declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{}, {}, {
|
|
10
|
+
"api:newrelic": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
11
|
+
kind: "api";
|
|
12
|
+
name: undefined;
|
|
13
|
+
config: {};
|
|
14
|
+
configInput: {};
|
|
15
|
+
output: _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<_backstage_core_plugin_api.AnyApiFactory, "core.api.factory", {}>;
|
|
16
|
+
inputs: {};
|
|
17
|
+
params: {
|
|
18
|
+
factory: _backstage_core_plugin_api.AnyApiFactory;
|
|
19
|
+
};
|
|
20
|
+
}>;
|
|
21
|
+
"entity-card:newrelic/EntityNewRelicDashboardCard": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
22
|
+
kind: "entity-card";
|
|
23
|
+
name: "EntityNewRelicDashboardCard";
|
|
24
|
+
config: {
|
|
25
|
+
filter: _backstage_plugin_catalog_react_alpha.EntityPredicate | undefined;
|
|
26
|
+
type: "content" | "summary" | "info" | undefined;
|
|
27
|
+
};
|
|
28
|
+
configInput: {
|
|
29
|
+
filter?: _backstage_plugin_catalog_react_alpha.EntityPredicate | undefined;
|
|
30
|
+
type?: "content" | "summary" | "info" | undefined;
|
|
31
|
+
};
|
|
32
|
+
output: _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<react.JSX.Element, "core.reactElement", {}> | _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<(entity: _backstage_catalog_model.Entity) => boolean, "catalog.entity-filter-function", {
|
|
33
|
+
optional: true;
|
|
34
|
+
}> | _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<string, "catalog.entity-filter-expression", {
|
|
35
|
+
optional: true;
|
|
36
|
+
}> | _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<_backstage_plugin_catalog_react_alpha.EntityCardType, "catalog.entity-card-type", {
|
|
37
|
+
optional: true;
|
|
38
|
+
}>;
|
|
39
|
+
inputs: {};
|
|
40
|
+
params: {
|
|
41
|
+
loader: () => Promise<JSX.Element>;
|
|
42
|
+
filter?: _backstage_plugin_catalog_react_alpha.EntityPredicate | ((entity: _backstage_catalog_model.Entity) => boolean) | undefined;
|
|
43
|
+
type?: _backstage_plugin_catalog_react_alpha.EntityCardType | undefined;
|
|
44
|
+
};
|
|
45
|
+
}>;
|
|
46
|
+
"entity-content:newrelic/EntityNewRelicDashboardContent": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
47
|
+
kind: "entity-content";
|
|
48
|
+
name: "EntityNewRelicDashboardContent";
|
|
49
|
+
config: {
|
|
50
|
+
path: string | undefined;
|
|
51
|
+
title: string | undefined;
|
|
52
|
+
filter: _backstage_plugin_catalog_react_alpha.EntityPredicate | undefined;
|
|
53
|
+
group: string | false | undefined;
|
|
54
|
+
};
|
|
55
|
+
configInput: {
|
|
56
|
+
filter?: _backstage_plugin_catalog_react_alpha.EntityPredicate | undefined;
|
|
57
|
+
title?: string | undefined;
|
|
58
|
+
path?: string | undefined;
|
|
59
|
+
group?: string | false | undefined;
|
|
60
|
+
};
|
|
61
|
+
output: _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<react.JSX.Element, "core.reactElement", {}> | _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<string, "core.routing.path", {}> | _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<_backstage_frontend_plugin_api.RouteRef<_backstage_frontend_plugin_api.AnyRouteRefParams>, "core.routing.ref", {
|
|
62
|
+
optional: true;
|
|
63
|
+
}> | _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<string, "catalog.entity-content-title", {}> | _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<(entity: _backstage_catalog_model.Entity) => boolean, "catalog.entity-filter-function", {
|
|
64
|
+
optional: true;
|
|
65
|
+
}> | _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<string, "catalog.entity-filter-expression", {
|
|
66
|
+
optional: true;
|
|
67
|
+
}> | _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<string, "catalog.entity-content-group", {
|
|
68
|
+
optional: true;
|
|
69
|
+
}>;
|
|
70
|
+
inputs: {};
|
|
71
|
+
params: {
|
|
72
|
+
loader: () => Promise<JSX.Element>;
|
|
73
|
+
defaultPath: string;
|
|
74
|
+
defaultTitle: string;
|
|
75
|
+
defaultGroup?: (string & {}) | "operation" | "development" | "deployment" | "overview" | "documentation" | "observability" | undefined;
|
|
76
|
+
routeRef?: _backstage_frontend_plugin_api.RouteRef<_backstage_frontend_plugin_api.AnyRouteRefParams> | undefined;
|
|
77
|
+
filter?: _backstage_plugin_catalog_react_alpha.EntityPredicate | ((entity: _backstage_catalog_model.Entity) => boolean) | undefined;
|
|
78
|
+
};
|
|
79
|
+
}>;
|
|
80
|
+
}>;
|
|
81
|
+
|
|
82
|
+
export { _default as default };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"alpha.esm.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
package/package.json
CHANGED
|
@@ -1,17 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@backstage-community/plugin-newrelic-dashboard",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.11.0",
|
|
4
4
|
"backstage": {
|
|
5
5
|
"role": "frontend-plugin",
|
|
6
6
|
"pluginId": "newrelic-dashboard",
|
|
7
7
|
"pluginPackages": [
|
|
8
8
|
"@backstage-community/plugin-newrelic-dashboard"
|
|
9
|
-
]
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
"main": "dist/index.esm.js",
|
|
14
|
-
"types": "dist/index.d.ts"
|
|
9
|
+
],
|
|
10
|
+
"features": {
|
|
11
|
+
"./alpha": "@backstage/FrontendPlugin"
|
|
12
|
+
}
|
|
15
13
|
},
|
|
16
14
|
"homepage": "https://backstage.io",
|
|
17
15
|
"repository": {
|
|
@@ -21,8 +19,35 @@
|
|
|
21
19
|
},
|
|
22
20
|
"license": "Apache-2.0",
|
|
23
21
|
"sideEffects": false,
|
|
24
|
-
"
|
|
25
|
-
|
|
22
|
+
"publishConfig": {
|
|
23
|
+
"access": "public"
|
|
24
|
+
},
|
|
25
|
+
"exports": {
|
|
26
|
+
".": {
|
|
27
|
+
"import": "./dist/index.esm.js",
|
|
28
|
+
"types": "./dist/index.d.ts",
|
|
29
|
+
"default": "./dist/index.esm.js"
|
|
30
|
+
},
|
|
31
|
+
"./alpha": {
|
|
32
|
+
"backstage": "@backstage/FrontendPlugin",
|
|
33
|
+
"import": "./dist/alpha.esm.js",
|
|
34
|
+
"types": "./dist/alpha.d.ts",
|
|
35
|
+
"default": "./dist/alpha.esm.js"
|
|
36
|
+
},
|
|
37
|
+
"./package.json": "./package.json"
|
|
38
|
+
},
|
|
39
|
+
"typesVersions": {
|
|
40
|
+
"*": {
|
|
41
|
+
"alpha": [
|
|
42
|
+
"dist/alpha.d.ts"
|
|
43
|
+
],
|
|
44
|
+
"package.json": [
|
|
45
|
+
"package.json"
|
|
46
|
+
]
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
"main": "./dist/index.esm.js",
|
|
50
|
+
"types": "./dist/index.d.ts",
|
|
26
51
|
"files": [
|
|
27
52
|
"dist"
|
|
28
53
|
],
|
|
@@ -37,9 +62,11 @@
|
|
|
37
62
|
},
|
|
38
63
|
"dependencies": {
|
|
39
64
|
"@backstage/catalog-model": "^1.7.4",
|
|
65
|
+
"@backstage/core-compat-api": "^0.4.3",
|
|
40
66
|
"@backstage/core-components": "^0.17.3",
|
|
41
67
|
"@backstage/core-plugin-api": "^1.10.8",
|
|
42
68
|
"@backstage/errors": "^1.2.7",
|
|
69
|
+
"@backstage/frontend-plugin-api": "^0.10.3",
|
|
43
70
|
"@backstage/plugin-catalog-react": "^1.19.0",
|
|
44
71
|
"@material-ui/core": "^4.12.2",
|
|
45
72
|
"@material-ui/icons": "^4.9.1",
|
|
@@ -63,12 +90,5 @@
|
|
|
63
90
|
"react-dom": "^16.13.1 || ^17.0.0 || ^18.0.0",
|
|
64
91
|
"react-router-dom": "6.0.0-beta.0 || ^6.3.0"
|
|
65
92
|
},
|
|
66
|
-
"typesVersions": {
|
|
67
|
-
"*": {
|
|
68
|
-
"package.json": [
|
|
69
|
-
"package.json"
|
|
70
|
-
]
|
|
71
|
-
}
|
|
72
|
-
},
|
|
73
93
|
"module": "./dist/index.esm.js"
|
|
74
94
|
}
|