@backstage/frontend-test-utils
Advanced tools
Comparing version 0.0.0-nightly-20240808021919 to 0.0.0-nightly-20240809021939
# @backstage/frontend-test-utils | ||
## 0.0.0-nightly-20240808021919 | ||
## 0.0.0-nightly-20240809021939 | ||
@@ -10,8 +10,38 @@ ### Patch Changes | ||
- 3be9aeb: Added support for v2 extensions, which declare their inputs and outputs without using a data map. | ||
- 2d21599: Added support for being able to override extension definitions. | ||
```tsx | ||
const TestCard = EntityCardBlueprint.make({ | ||
... | ||
}); | ||
TestCard.override({ | ||
// override attachment points | ||
attachTo: { id: 'something-else', input: 'overridden' }, | ||
// extend the config schema | ||
config: { | ||
schema: { | ||
newConfig: z => z.string().optional(), | ||
} | ||
}, | ||
// override factory | ||
*factory(originalFactory, { inputs, config }){ | ||
const originalOutput = originalFactory(); | ||
yield coreExentsionData.reactElement( | ||
<Wrapping> | ||
{originalOutput.get(coreExentsionData.reactElement)} | ||
</Wrapping> | ||
); | ||
} | ||
}); | ||
``` | ||
- 6349099: Added config input type to the extensions | ||
- Updated dependencies | ||
- @backstage/frontend-plugin-api@0.0.0-nightly-20240808021919 | ||
- @backstage/frontend-app-api@0.0.0-nightly-20240808021919 | ||
- @backstage/frontend-plugin-api@0.0.0-nightly-20240809021939 | ||
- @backstage/frontend-app-api@0.0.0-nightly-20240809021939 | ||
- @backstage/config@1.2.0 | ||
- @backstage/test-utils@0.0.0-nightly-20240808021919 | ||
- @backstage/test-utils@0.0.0-nightly-20240809021939 | ||
- @backstage/types@1.1.1 | ||
@@ -18,0 +48,0 @@ |
@@ -18,3 +18,9 @@ import { toInternalExtensionDefinition } from './createExtension.esm.js'; | ||
const internalDefinition = toInternalExtensionDefinition(definition); | ||
const { name, kind, namespace: _, ...rest } = internalDefinition; | ||
const { | ||
name, | ||
kind, | ||
namespace: _skip1, | ||
override: _skip2, | ||
...rest | ||
} = internalDefinition; | ||
const namespace = internalDefinition.namespace ?? context?.namespace; | ||
@@ -21,0 +27,0 @@ const namePart = name && namespace ? `${namespace}/${name}` : namespace || name; |
{ | ||
"name": "@backstage/frontend-test-utils", | ||
"version": "0.0.0-nightly-20240808021919", | ||
"version": "0.0.0-nightly-20240809021939", | ||
"backstage": { | ||
@@ -35,9 +35,9 @@ "role": "web-library" | ||
"@backstage/config": "^1.2.0", | ||
"@backstage/frontend-app-api": "^0.0.0-nightly-20240808021919", | ||
"@backstage/frontend-plugin-api": "^0.0.0-nightly-20240808021919", | ||
"@backstage/test-utils": "^0.0.0-nightly-20240808021919", | ||
"@backstage/frontend-app-api": "^0.0.0-nightly-20240809021939", | ||
"@backstage/frontend-plugin-api": "^0.0.0-nightly-20240809021939", | ||
"@backstage/test-utils": "^0.0.0-nightly-20240809021939", | ||
"@backstage/types": "^1.1.1" | ||
}, | ||
"devDependencies": { | ||
"@backstage/cli": "^0.0.0-nightly-20240808021919", | ||
"@backstage/cli": "^0.0.0-nightly-20240809021939", | ||
"@testing-library/jest-dom": "^6.0.0", | ||
@@ -44,0 +44,0 @@ "@types/react": "*" |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
160447
1069