@backstage/plugin-devtools-react 0.1.2-next.0 → 0.2.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 CHANGED
@@ -1,5 +1,25 @@
1
1
  # @backstage/plugin-devtools-react
2
2
 
3
+ ## 0.2.0
4
+
5
+ ### Minor Changes
6
+
7
+ - f4a1edd: Removed the deprecated `DevToolsContentBlueprint` from `@backstage/plugin-devtools-react`. DevTools pages in the new frontend system now use `SubPageBlueprint` tabs instead, and the catalog unprocessed entities alpha extension now attaches to DevTools as a subpage.
8
+
9
+ ### Patch Changes
10
+
11
+ - Updated dependencies
12
+ - @backstage/core-plugin-api@1.12.4
13
+ - @backstage/frontend-plugin-api@0.15.0
14
+
15
+ ## 0.1.2-next.1
16
+
17
+ ### Patch Changes
18
+
19
+ - Updated dependencies
20
+ - @backstage/frontend-plugin-api@0.15.0-next.1
21
+ - @backstage/core-plugin-api@1.12.4-next.1
22
+
3
23
  ## 0.1.2-next.0
4
24
 
5
25
  ### Patch Changes
package/dist/index.d.ts CHANGED
@@ -1,54 +1,2 @@
1
- import * as _backstage_frontend_plugin_api from '@backstage/frontend-plugin-api';
2
- import { RouteRef } from '@backstage/frontend-plugin-api';
3
- import { JSX } from 'react';
4
1
 
5
- /**
6
- * Parameters for creating a DevTools route extension
7
- * @public
8
- */
9
- interface DevToolsContentBlueprintParams {
10
- path: string;
11
- title: string;
12
- loader: () => Promise<JSX.Element>;
13
- routeRef?: RouteRef;
14
- }
15
- /**
16
- * Extension blueprint for creating DevTools content pages (appearing as tabs)
17
- *
18
- * @example
19
- * ```tsx
20
- * const myDevToolsContent = DevToolsContentBlueprint.make({
21
- * {
22
- * params: {
23
- * path: 'my-dev-tools',
24
- * title: 'My DevTools',
25
- * loader: () =>
26
- * import('../components/MyDevTools').then(m =>
27
- * compatWrapper(<m.MyDevTools />),
28
- * ),
29
- * },
30
- * },
31
- * });
32
- * ```
33
- * @public
34
- */
35
- declare const DevToolsContentBlueprint: _backstage_frontend_plugin_api.ExtensionBlueprint<{
36
- kind: "devtools-content";
37
- params: DevToolsContentBlueprintParams;
38
- output: _backstage_frontend_plugin_api.ExtensionDataRef<string, "core.routing.path", {}> | _backstage_frontend_plugin_api.ExtensionDataRef<RouteRef<_backstage_frontend_plugin_api.AnyRouteRefParams>, "core.routing.ref", {
39
- optional: true;
40
- }> | _backstage_frontend_plugin_api.ExtensionDataRef<JSX.Element, "core.reactElement", {}> | _backstage_frontend_plugin_api.ExtensionDataRef<string, "core.title", {}>;
41
- inputs: {};
42
- config: {
43
- path: string | undefined;
44
- title: string | undefined;
45
- };
46
- configInput: {
47
- title?: string | undefined;
48
- path?: string | undefined;
49
- };
50
- dataRefs: never;
51
- }>;
52
-
53
- export { DevToolsContentBlueprint };
54
- export type { DevToolsContentBlueprintParams };
2
+ export { };
package/dist/index.esm.js CHANGED
@@ -1,2 +1,2 @@
1
- export { DevToolsContentBlueprint } from './devToolsContentBlueprint.esm.js';
1
+
2
2
  //# sourceMappingURL=index.esm.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@backstage/plugin-devtools-react",
3
- "version": "0.1.2-next.0",
3
+ "version": "0.2.0",
4
4
  "description": "Web library for the devtools plugin",
5
5
  "backstage": {
6
6
  "role": "web-library",
@@ -39,13 +39,13 @@
39
39
  "test": "backstage-cli package test"
40
40
  },
41
41
  "dependencies": {
42
- "@backstage/core-plugin-api": "1.12.4-next.0",
43
- "@backstage/frontend-plugin-api": "0.14.2-next.0",
42
+ "@backstage/core-plugin-api": "^1.12.4",
43
+ "@backstage/frontend-plugin-api": "^0.15.0",
44
44
  "@material-ui/core": "^4.9.13"
45
45
  },
46
46
  "devDependencies": {
47
- "@backstage/cli": "0.35.5-next.0",
48
- "@backstage/test-utils": "1.7.16-next.0",
47
+ "@backstage/cli": "^0.36.0",
48
+ "@backstage/test-utils": "^1.7.16",
49
49
  "@testing-library/jest-dom": "^6.0.0",
50
50
  "@testing-library/react": "^16.0.0",
51
51
  "@types/react": "^18.0.0",
@@ -1,33 +0,0 @@
1
- import { createExtensionBlueprint, coreExtensionData, ExtensionBoundary } from '@backstage/frontend-plugin-api';
2
-
3
- const DevToolsContentBlueprint = createExtensionBlueprint({
4
- kind: "devtools-content",
5
- attachTo: { id: "page:devtools", input: "contents" },
6
- output: [
7
- coreExtensionData.reactElement,
8
- coreExtensionData.routePath,
9
- coreExtensionData.routeRef.optional(),
10
- coreExtensionData.title
11
- ],
12
- config: {
13
- schema: {
14
- path: (z) => z.string().optional(),
15
- title: (z) => z.string().optional()
16
- }
17
- },
18
- *factory(params, { node, config }) {
19
- const path = config.path ?? params.path;
20
- const title = config.title ?? params.title;
21
- yield coreExtensionData.reactElement(
22
- ExtensionBoundary.lazy(node, params.loader)
23
- );
24
- yield coreExtensionData.routePath(path);
25
- yield coreExtensionData.title(title);
26
- if (params.routeRef) {
27
- yield coreExtensionData.routeRef(params.routeRef);
28
- }
29
- }
30
- });
31
-
32
- export { DevToolsContentBlueprint };
33
- //# sourceMappingURL=devToolsContentBlueprint.esm.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"devToolsContentBlueprint.esm.js","sources":["../src/devToolsContentBlueprint.tsx"],"sourcesContent":["/*\n * Copyright 2024 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 coreExtensionData,\n createExtensionBlueprint,\n ExtensionBoundary,\n RouteRef,\n} from '@backstage/frontend-plugin-api';\nimport { JSX } from 'react';\n\n/**\n * Parameters for creating a DevTools route extension\n * @public\n */\nexport interface DevToolsContentBlueprintParams {\n path: string;\n title: string;\n loader: () => Promise<JSX.Element>;\n routeRef?: RouteRef;\n}\n\n/**\n * Extension blueprint for creating DevTools content pages (appearing as tabs)\n *\n * @example\n * ```tsx\n * const myDevToolsContent = DevToolsContentBlueprint.make({\n * {\n * params: {\n * path: 'my-dev-tools',\n * title: 'My DevTools',\n * loader: () =>\n * import('../components/MyDevTools').then(m =>\n * compatWrapper(<m.MyDevTools />),\n * ),\n * },\n * },\n * });\n * ```\n * @public\n */\nexport const DevToolsContentBlueprint = createExtensionBlueprint({\n kind: 'devtools-content',\n attachTo: { id: 'page:devtools', input: 'contents' },\n output: [\n coreExtensionData.reactElement,\n coreExtensionData.routePath,\n coreExtensionData.routeRef.optional(),\n coreExtensionData.title,\n ],\n config: {\n schema: {\n path: z => z.string().optional(),\n title: z => z.string().optional(),\n },\n },\n *factory(params: DevToolsContentBlueprintParams, { node, config }) {\n const path = config.path ?? params.path;\n const title = config.title ?? params.title;\n\n yield coreExtensionData.reactElement(\n ExtensionBoundary.lazy(node, params.loader),\n );\n\n yield coreExtensionData.routePath(path);\n\n yield coreExtensionData.title(title);\n\n if (params.routeRef) {\n yield coreExtensionData.routeRef(params.routeRef);\n }\n },\n});\n"],"names":[],"mappings":";;AAuDO,MAAM,2BAA2B,wBAAA,CAAyB;AAAA,EAC/D,IAAA,EAAM,kBAAA;AAAA,EACN,QAAA,EAAU,EAAE,EAAA,EAAI,eAAA,EAAiB,OAAO,UAAA,EAAW;AAAA,EACnD,MAAA,EAAQ;AAAA,IACN,iBAAA,CAAkB,YAAA;AAAA,IAClB,iBAAA,CAAkB,SAAA;AAAA,IAClB,iBAAA,CAAkB,SAAS,QAAA,EAAS;AAAA,IACpC,iBAAA,CAAkB;AAAA,GACpB;AAAA,EACA,MAAA,EAAQ;AAAA,IACN,MAAA,EAAQ;AAAA,MACN,IAAA,EAAM,CAAA,CAAA,KAAK,CAAA,CAAE,MAAA,GAAS,QAAA,EAAS;AAAA,MAC/B,KAAA,EAAO,CAAA,CAAA,KAAK,CAAA,CAAE,MAAA,GAAS,QAAA;AAAS;AAClC,GACF;AAAA,EACA,CAAC,OAAA,CAAQ,MAAA,EAAwC,EAAE,IAAA,EAAM,QAAO,EAAG;AACjE,IAAA,MAAM,IAAA,GAAO,MAAA,CAAO,IAAA,IAAQ,MAAA,CAAO,IAAA;AACnC,IAAA,MAAM,KAAA,GAAQ,MAAA,CAAO,KAAA,IAAS,MAAA,CAAO,KAAA;AAErC,IAAA,MAAM,iBAAA,CAAkB,YAAA;AAAA,MACtB,iBAAA,CAAkB,IAAA,CAAK,IAAA,EAAM,MAAA,CAAO,MAAM;AAAA,KAC5C;AAEA,IAAA,MAAM,iBAAA,CAAkB,UAAU,IAAI,CAAA;AAEtC,IAAA,MAAM,iBAAA,CAAkB,MAAM,KAAK,CAAA;AAEnC,IAAA,IAAI,OAAO,QAAA,EAAU;AACnB,MAAA,MAAM,iBAAA,CAAkB,QAAA,CAAS,MAAA,CAAO,QAAQ,CAAA;AAAA,IAClD;AAAA,EACF;AACF,CAAC;;;;"}