Add changeset descriptions

Signed-off-by: Joon Park <joonp@spotify.com>
This commit is contained in:
Joon Park
2022-01-31 15:21:35 +00:00
parent ba59832aed
commit 86b1c46bd5
2 changed files with 20 additions and 0 deletions
+2
View File
@@ -3,3 +3,5 @@
---
Add catalogEntityCreatePermission
The `catalogEntityCreatePermission` can be imported and used when authoring a permission policy to restrict/grant a user's access to the catalog import plugin. (And the "Register Existing Component" button which navigates there).
+18
View File
@@ -3,3 +3,21 @@
---
Permission the catalog-import route
Use the `PermissionedRoute` for `CatalogImportPage` instead of the normal `Route`:
```diff
// app/src/App.tsx
...
+ import { PermissionedRoute } from '@backstage/plugin-permission-react';
+ import { catalogEntityCreatePermission } from '@backstage/plugin-catalog-common';
...
- <Route path="/catalog-import" element={<CatalogImportPage />} />
+ <PermissionedRoute
+ path="/catalog-import"
+ permission={catalogEntityCreatePermission}
+ element={<CatalogImportPage />}
+ />
```