@backstage/plugin-scaffolder-react 1.14.2 → 1.14.3-next.1
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,34 @@
|
|
|
1
1
|
# @backstage/plugin-scaffolder-react
|
|
2
2
|
|
|
3
|
+
## 1.14.3-next.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- d8f9079: Updated dependency `@rjsf/utils` to `5.23.2`.
|
|
8
|
+
Updated dependency `@rjsf/core` to `5.23.2`.
|
|
9
|
+
Updated dependency `@rjsf/material-ui` to `5.23.2`.
|
|
10
|
+
Updated dependency `@rjsf/validator-ajv8` to `5.23.2`.
|
|
11
|
+
- Updated dependencies
|
|
12
|
+
- @backstage/plugin-catalog-react@1.15.1-next.0
|
|
13
|
+
|
|
14
|
+
## 1.14.3-next.0
|
|
15
|
+
|
|
16
|
+
### Patch Changes
|
|
17
|
+
|
|
18
|
+
- 37421bc: Fixed scaffolder form fields not resolving correctly in the `useCustomFieldExtensions` hook.
|
|
19
|
+
- Updated dependencies
|
|
20
|
+
- @backstage/catalog-client@1.9.0
|
|
21
|
+
- @backstage/catalog-model@1.7.2
|
|
22
|
+
- @backstage/core-components@0.16.2
|
|
23
|
+
- @backstage/core-plugin-api@1.10.2
|
|
24
|
+
- @backstage/frontend-plugin-api@0.9.3
|
|
25
|
+
- @backstage/theme@0.6.3
|
|
26
|
+
- @backstage/types@1.2.0
|
|
27
|
+
- @backstage/version-bridge@1.0.10
|
|
28
|
+
- @backstage/plugin-catalog-react@1.15.0
|
|
29
|
+
- @backstage/plugin-permission-react@0.4.29
|
|
30
|
+
- @backstage/plugin-scaffolder-common@1.5.8
|
|
31
|
+
|
|
3
32
|
## 1.14.2
|
|
4
33
|
|
|
5
34
|
### Patch Changes
|
|
@@ -45,11 +45,11 @@ import { FIELD_EXTENSION_WRAPPER_KEY, FIELD_EXTENSION_KEY } from '../extensions/
|
|
|
45
45
|
|
|
46
46
|
const useCustomFieldExtensions = (outlet) => {
|
|
47
47
|
const formFieldsApi = useApi(formFieldsApiRef);
|
|
48
|
-
const [{ result: blueprintFields },
|
|
49
|
-
formFieldsApi.getFormFields,
|
|
48
|
+
const [{ result: blueprintFields }, { execute }] = useAsync(
|
|
49
|
+
() => formFieldsApi.getFormFields(),
|
|
50
50
|
[]
|
|
51
51
|
);
|
|
52
|
-
useMountEffect(
|
|
52
|
+
useMountEffect(execute);
|
|
53
53
|
const outletFields = useElementFilter(
|
|
54
54
|
outlet,
|
|
55
55
|
(elements) => elements.selectByComponentData({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useCustomFieldExtensions.esm.js","sources":["../../src/hooks/useCustomFieldExtensions.ts"],"sourcesContent":["/*\n * Copyright 2023 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 */\nimport { useAsync, useMountEffect } from '@react-hookz/web';\nimport { useApi, useElementFilter } from '@backstage/core-plugin-api';\nimport { formFieldsApiRef } from '../next';\nimport { FieldExtensionOptions } from '../extensions';\nimport {\n FIELD_EXTENSION_KEY,\n FIELD_EXTENSION_WRAPPER_KEY,\n} from '../extensions/keys';\n\n/**\n * Hook that returns all custom field extensions from the current outlet.\n * @public\n */\nexport const useCustomFieldExtensions = <\n // todo(blam): this shouldn't be here, should remove this, but this is a breaking change to remove the generic.\n TComponentDataType = FieldExtensionOptions,\n>(\n outlet: React.ReactNode,\n) => {\n // Get custom fields created with FormFieldBlueprint\n const formFieldsApi = useApi(formFieldsApiRef);\n const [{ result: blueprintFields },
|
|
1
|
+
{"version":3,"file":"useCustomFieldExtensions.esm.js","sources":["../../src/hooks/useCustomFieldExtensions.ts"],"sourcesContent":["/*\n * Copyright 2023 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 */\nimport { useAsync, useMountEffect } from '@react-hookz/web';\nimport { useApi, useElementFilter } from '@backstage/core-plugin-api';\nimport { formFieldsApiRef } from '../next';\nimport { FieldExtensionOptions } from '../extensions';\nimport {\n FIELD_EXTENSION_KEY,\n FIELD_EXTENSION_WRAPPER_KEY,\n} from '../extensions/keys';\n\n/**\n * Hook that returns all custom field extensions from the current outlet.\n * @public\n */\nexport const useCustomFieldExtensions = <\n // todo(blam): this shouldn't be here, should remove this, but this is a breaking change to remove the generic.\n TComponentDataType = FieldExtensionOptions,\n>(\n outlet: React.ReactNode,\n) => {\n // Get custom fields created with FormFieldBlueprint\n const formFieldsApi = useApi(formFieldsApiRef);\n const [{ result: blueprintFields }, { execute }] = useAsync(\n () => formFieldsApi.getFormFields(),\n [],\n );\n useMountEffect(execute);\n\n // Get custom fields created with ScaffolderFieldExtensions\n const outletFields = useElementFilter(outlet, elements =>\n elements\n .selectByComponentData({\n key: FIELD_EXTENSION_WRAPPER_KEY,\n })\n .findComponentData<TComponentDataType>({\n key: FIELD_EXTENSION_KEY,\n }),\n );\n\n // This should really be a different type moving foward, but we do this to keep type compatibility.\n // should probably also move the defaults into the API eventually too, but that will come with the move\n // to the new frontend system.\n const blueprintsToLegacy: FieldExtensionOptions[] = blueprintFields?.map(\n field => ({\n component: field.component,\n name: field.name,\n validation: field.validation,\n schema: field.schema?.schema,\n }),\n );\n\n return [...blueprintsToLegacy, ...outletFields] as TComponentDataType[];\n};\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA4Ba,MAAA,wBAAA,GAA2B,CAItC,MACG,KAAA;AAEH,EAAM,MAAA,aAAA,GAAgB,OAAO,gBAAgB,CAAA;AAC7C,EAAM,MAAA,CAAC,EAAE,MAAQ,EAAA,eAAA,IAAmB,EAAE,OAAA,EAAS,CAAI,GAAA,QAAA;AAAA,IACjD,MAAM,cAAc,aAAc,EAAA;AAAA,IAClC;AAAC,GACH;AACA,EAAA,cAAA,CAAe,OAAO,CAAA;AAGtB,EAAA,MAAM,YAAe,GAAA,gBAAA;AAAA,IAAiB,MAAA;AAAA,IAAQ,CAAA,QAAA,KAC5C,SACG,qBAAsB,CAAA;AAAA,MACrB,GAAK,EAAA;AAAA,KACN,EACA,iBAAsC,CAAA;AAAA,MACrC,GAAK,EAAA;AAAA,KACN;AAAA,GACL;AAKA,EAAA,MAAM,qBAA8C,eAAiB,EAAA,GAAA;AAAA,IACnE,CAAU,KAAA,MAAA;AAAA,MACR,WAAW,KAAM,CAAA,SAAA;AAAA,MACjB,MAAM,KAAM,CAAA,IAAA;AAAA,MACZ,YAAY,KAAM,CAAA,UAAA;AAAA,MAClB,MAAA,EAAQ,MAAM,MAAQ,EAAA;AAAA,KACxB;AAAA,GACF;AAEA,EAAA,OAAO,CAAC,GAAG,kBAAoB,EAAA,GAAG,YAAY,CAAA;AAChD;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@backstage/plugin-scaffolder-react",
|
|
3
|
-
"version": "1.14.
|
|
3
|
+
"version": "1.14.3-next.1",
|
|
4
4
|
"description": "A frontend library that helps other Backstage plugins interact with the Scaffolder",
|
|
5
5
|
"backstage": {
|
|
6
6
|
"role": "web-library",
|
|
@@ -66,25 +66,25 @@
|
|
|
66
66
|
"test": "backstage-cli package test"
|
|
67
67
|
},
|
|
68
68
|
"dependencies": {
|
|
69
|
-
"@backstage/catalog-client": "
|
|
70
|
-
"@backstage/catalog-model": "
|
|
71
|
-
"@backstage/core-components": "
|
|
72
|
-
"@backstage/core-plugin-api": "
|
|
73
|
-
"@backstage/frontend-plugin-api": "
|
|
74
|
-
"@backstage/plugin-catalog-react": "
|
|
75
|
-
"@backstage/plugin-permission-react": "
|
|
76
|
-
"@backstage/plugin-scaffolder-common": "
|
|
77
|
-
"@backstage/theme": "
|
|
78
|
-
"@backstage/types": "
|
|
79
|
-
"@backstage/version-bridge": "
|
|
69
|
+
"@backstage/catalog-client": "1.9.0",
|
|
70
|
+
"@backstage/catalog-model": "1.7.2",
|
|
71
|
+
"@backstage/core-components": "0.16.2",
|
|
72
|
+
"@backstage/core-plugin-api": "1.10.2",
|
|
73
|
+
"@backstage/frontend-plugin-api": "0.9.3",
|
|
74
|
+
"@backstage/plugin-catalog-react": "1.15.1-next.0",
|
|
75
|
+
"@backstage/plugin-permission-react": "0.4.29",
|
|
76
|
+
"@backstage/plugin-scaffolder-common": "1.5.8",
|
|
77
|
+
"@backstage/theme": "0.6.3",
|
|
78
|
+
"@backstage/types": "1.2.0",
|
|
79
|
+
"@backstage/version-bridge": "1.0.10",
|
|
80
80
|
"@material-ui/core": "^4.12.2",
|
|
81
81
|
"@material-ui/icons": "^4.9.1",
|
|
82
82
|
"@material-ui/lab": "4.0.0-alpha.61",
|
|
83
83
|
"@react-hookz/web": "^24.0.0",
|
|
84
|
-
"@rjsf/core": "5.23.
|
|
85
|
-
"@rjsf/material-ui": "5.23.
|
|
86
|
-
"@rjsf/utils": "5.23.
|
|
87
|
-
"@rjsf/validator-ajv8": "5.23.
|
|
84
|
+
"@rjsf/core": "5.23.2",
|
|
85
|
+
"@rjsf/material-ui": "5.23.2",
|
|
86
|
+
"@rjsf/utils": "5.23.2",
|
|
87
|
+
"@rjsf/validator-ajv8": "5.23.2",
|
|
88
88
|
"@types/json-schema": "^7.0.9",
|
|
89
89
|
"ajv-errors": "^3.0.0",
|
|
90
90
|
"classnames": "^2.2.6",
|
|
@@ -102,12 +102,12 @@
|
|
|
102
102
|
"zod-to-json-schema": "^3.20.4"
|
|
103
103
|
},
|
|
104
104
|
"devDependencies": {
|
|
105
|
-
"@backstage/cli": "
|
|
106
|
-
"@backstage/core-app-api": "
|
|
107
|
-
"@backstage/plugin-catalog": "
|
|
108
|
-
"@backstage/plugin-catalog-common": "
|
|
109
|
-
"@backstage/plugin-permission-common": "
|
|
110
|
-
"@backstage/test-utils": "
|
|
105
|
+
"@backstage/cli": "0.29.5-next.0",
|
|
106
|
+
"@backstage/core-app-api": "1.15.3",
|
|
107
|
+
"@backstage/plugin-catalog": "1.26.1-next.0",
|
|
108
|
+
"@backstage/plugin-catalog-common": "1.1.2",
|
|
109
|
+
"@backstage/plugin-permission-common": "0.8.3",
|
|
110
|
+
"@backstage/test-utils": "1.7.3",
|
|
111
111
|
"@testing-library/dom": "^10.0.0",
|
|
112
112
|
"@testing-library/jest-dom": "^6.0.0",
|
|
113
113
|
"@testing-library/react": "^16.0.0",
|