@backstage-community/plugin-rbac 1.49.0 → 1.50.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 +12 -0
- package/dist/alpha/navItems.esm.js +1 -0
- package/dist/alpha/navItems.esm.js.map +1 -1
- package/dist/alpha.d.ts +24 -3
- package/dist/components/Administration.esm.js +4 -1
- package/dist/components/Administration.esm.js.map +1 -1
- package/dist/package.json.esm.js +18 -18
- package/package.json +19 -19
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @backstage-community/plugin-rbac
|
|
2
2
|
|
|
3
|
+
## 1.50.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 843bbe2: Backstage version bump to v1.48.4
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- d22bce2: Updated dependency `start-server-and-test` to `2.1.5`.
|
|
12
|
+
- Updated dependencies [843bbe2]
|
|
13
|
+
- @backstage-community/plugin-rbac-common@1.24.0
|
|
14
|
+
|
|
3
15
|
## 1.49.0
|
|
4
16
|
|
|
5
17
|
### Minor Changes
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"navItems.esm.js","sources":["../../src/alpha/navItems.tsx"],"sourcesContent":["/*\n * Copyright 2026 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 {
|
|
1
|
+
{"version":3,"file":"navItems.esm.js","sources":["../../src/alpha/navItems.tsx"],"sourcesContent":["/*\n * Copyright 2026 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 { NavItemBlueprint } from '@backstage/frontend-plugin-api';\nimport { rootRouteRef } from '../routes';\nimport { RbacIcon } from '..';\n\nexport const rbacNavItem = NavItemBlueprint.make({\n params: {\n title: 'RBAC',\n routeRef: rootRouteRef,\n // FIXME: improve icon type in Backstage 1.49, currently the icon type is deprecated but there is no change in the NavItemBlueprint!?\n icon: RbacIcon as any,\n },\n});\n\nexport default rbacNavItem;\n"],"names":[],"mappings":";;;;AAoBa,MAAA,WAAA,GAAc,iBAAiB,IAAK,CAAA;AAAA,EAC/C,MAAQ,EAAA;AAAA,IACN,KAAO,EAAA,MAAA;AAAA,IACP,QAAU,EAAA,YAAA;AAAA;AAAA,IAEV,IAAM,EAAA;AAAA;AAEV,CAAC;;;;"}
|
package/dist/alpha.d.ts
CHANGED
|
@@ -233,19 +233,40 @@ declare const _default: _backstage_frontend_plugin_api.OverridableFrontendPlugin
|
|
|
233
233
|
name: undefined;
|
|
234
234
|
config: {
|
|
235
235
|
path: string | undefined;
|
|
236
|
+
title: string | undefined;
|
|
236
237
|
};
|
|
237
238
|
configInput: {
|
|
239
|
+
title?: string | undefined;
|
|
238
240
|
path?: string | undefined;
|
|
239
241
|
};
|
|
240
|
-
output: _backstage_frontend_plugin_api.ExtensionDataRef<string, "core.routing.path", {}> | _backstage_frontend_plugin_api.ExtensionDataRef<
|
|
242
|
+
output: _backstage_frontend_plugin_api.ExtensionDataRef<string, "core.routing.path", {}> | _backstage_frontend_plugin_api.ExtensionDataRef<_backstage_frontend_plugin_api.RouteRef<_backstage_frontend_plugin_api.AnyRouteRefParams>, "core.routing.ref", {
|
|
243
|
+
optional: true;
|
|
244
|
+
}> | _backstage_frontend_plugin_api.ExtensionDataRef<react.JSX.Element, "core.reactElement", {}> | _backstage_frontend_plugin_api.ExtensionDataRef<string, "core.title", {
|
|
245
|
+
optional: true;
|
|
246
|
+
}> | _backstage_frontend_plugin_api.ExtensionDataRef<_backstage_frontend_plugin_api.IconElement, "core.icon", {
|
|
241
247
|
optional: true;
|
|
242
248
|
}>;
|
|
243
|
-
inputs: {
|
|
249
|
+
inputs: {
|
|
250
|
+
pages: _backstage_frontend_plugin_api.ExtensionInput<_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", {
|
|
251
|
+
optional: true;
|
|
252
|
+
}> | _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<string, "core.title", {
|
|
253
|
+
optional: true;
|
|
254
|
+
}> | _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<_backstage_frontend_plugin_api.IconElement, "core.icon", {
|
|
255
|
+
optional: true;
|
|
256
|
+
}>, {
|
|
257
|
+
singleton: false;
|
|
258
|
+
optional: false;
|
|
259
|
+
internal: false;
|
|
260
|
+
}>;
|
|
261
|
+
};
|
|
244
262
|
params: {
|
|
245
263
|
defaultPath?: [Error: "Use the 'path' param instead"] | undefined;
|
|
246
264
|
path: string;
|
|
247
|
-
|
|
265
|
+
title?: string | undefined;
|
|
266
|
+
icon?: _backstage_frontend_plugin_api.IconElement | undefined;
|
|
267
|
+
loader?: (() => Promise<react.JSX.Element>) | undefined;
|
|
248
268
|
routeRef?: _backstage_frontend_plugin_api.RouteRef<_backstage_frontend_plugin_api.AnyRouteRefParams> | undefined;
|
|
269
|
+
noHeader?: boolean | undefined;
|
|
249
270
|
};
|
|
250
271
|
}>;
|
|
251
272
|
}>;
|
|
@@ -14,7 +14,10 @@ const Administration = () => {
|
|
|
14
14
|
const config = useApi(configApiRef);
|
|
15
15
|
const isRBACPluginEnabled = config.getOptionalBoolean("permission.enabled");
|
|
16
16
|
if (!isUserLoading && isRBACPluginEnabled) {
|
|
17
|
-
return result?.status === "Authorized" ?
|
|
17
|
+
return result?.status === "Authorized" ? (
|
|
18
|
+
// FIXME: improve icon type in Backstage 1.49, currently the icon type is deprecated but there is no change in the SidebarItem!?
|
|
19
|
+
/* @__PURE__ */ jsx(SidebarItem, { text: "RBAC", to: "rbac", icon: RbacIcon })
|
|
20
|
+
) : null;
|
|
18
21
|
}
|
|
19
22
|
return null;
|
|
20
23
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Administration.esm.js","sources":["../../src/components/Administration.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 */\nimport { useAsync } from 'react-use';\n\nimport { SidebarItem } from '@backstage/core-components';\nimport {
|
|
1
|
+
{"version":3,"file":"Administration.esm.js","sources":["../../src/components/Administration.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 */\nimport { useAsync } from 'react-use';\n\nimport { SidebarItem } from '@backstage/core-components';\nimport { configApiRef, useApi } from '@backstage/core-plugin-api';\n\nimport { default as RbacIcon } from '@mui/icons-material/VpnKeyOutlined';\n\nimport { rbacApiRef } from '../api/RBACBackendClient';\n\nexport const Administration = () => {\n const rbacApi = useApi(rbacApiRef);\n const { loading: isUserLoading, value: result } = useAsync(\n async () => await rbacApi.getUserAuthorization(),\n [],\n );\n\n const config = useApi(configApiRef);\n const isRBACPluginEnabled = config.getOptionalBoolean('permission.enabled');\n\n if (!isUserLoading && isRBACPluginEnabled) {\n return result?.status === 'Authorized' ? (\n // FIXME: improve icon type in Backstage 1.49, currently the icon type is deprecated but there is no change in the SidebarItem!?\n <SidebarItem text=\"RBAC\" to=\"rbac\" icon={RbacIcon as any} />\n ) : null;\n }\n return null;\n};\n"],"names":[],"mappings":";;;;;;;AAwBO,MAAM,iBAAiB,MAAM;AAClC,EAAM,MAAA,OAAA,GAAU,OAAO,UAAU,CAAA;AACjC,EAAA,MAAM,EAAE,OAAA,EAAS,aAAe,EAAA,KAAA,EAAO,QAAW,GAAA,QAAA;AAAA,IAChD,YAAY,MAAM,OAAA,CAAQ,oBAAqB,EAAA;AAAA,IAC/C;AAAC,GACH;AAEA,EAAM,MAAA,MAAA,GAAS,OAAO,YAAY,CAAA;AAClC,EAAM,MAAA,mBAAA,GAAsB,MAAO,CAAA,kBAAA,CAAmB,oBAAoB,CAAA;AAE1E,EAAI,IAAA,CAAC,iBAAiB,mBAAqB,EAAA;AACzC,IAAA,OAAO,QAAQ,MAAW,KAAA,YAAA;AAAA;AAAA,0BAEvB,WAAY,EAAA,EAAA,IAAA,EAAK,QAAO,EAAG,EAAA,MAAA,EAAO,MAAM,QAAiB,EAAA;AAAA,QACxD,IAAA;AAAA;AAEN,EAAO,OAAA,IAAA;AACT;;;;"}
|
package/dist/package.json.esm.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
var name = "@backstage-community/plugin-rbac";
|
|
2
|
-
var version = "1.
|
|
2
|
+
var version = "1.50.0";
|
|
3
3
|
var main = "src/index.ts";
|
|
4
4
|
var types = "src/index.ts";
|
|
5
5
|
var license = "Apache-2.0";
|
|
@@ -51,15 +51,15 @@ var scripts = {
|
|
|
51
51
|
var dependencies = {
|
|
52
52
|
"@backstage-community/plugin-rbac-common": "workspace:^",
|
|
53
53
|
"@backstage/catalog-model": "^1.7.6",
|
|
54
|
-
"@backstage/core-components": "^0.18.
|
|
55
|
-
"@backstage/core-plugin-api": "^1.12.
|
|
56
|
-
"@backstage/frontend-plugin-api": "^0.
|
|
57
|
-
"@backstage/plugin-app-react": "^0.
|
|
58
|
-
"@backstage/plugin-catalog": "^1.
|
|
59
|
-
"@backstage/plugin-catalog-common": "^1.1.
|
|
60
|
-
"@backstage/plugin-permission-common": "^0.9.
|
|
61
|
-
"@backstage/plugin-permission-react": "^0.4.
|
|
62
|
-
"@backstage/theme": "^0.7.
|
|
54
|
+
"@backstage/core-components": "^0.18.7",
|
|
55
|
+
"@backstage/core-plugin-api": "^1.12.3",
|
|
56
|
+
"@backstage/frontend-plugin-api": "^0.14.1",
|
|
57
|
+
"@backstage/plugin-app-react": "^0.2.0",
|
|
58
|
+
"@backstage/plugin-catalog": "^1.33.1",
|
|
59
|
+
"@backstage/plugin-catalog-common": "^1.1.8",
|
|
60
|
+
"@backstage/plugin-permission-common": "^0.9.6",
|
|
61
|
+
"@backstage/plugin-permission-react": "^0.4.40",
|
|
62
|
+
"@backstage/theme": "^0.7.2",
|
|
63
63
|
"@mui/icons-material": "5.18.0",
|
|
64
64
|
"@mui/material": "^5.14.18",
|
|
65
65
|
"@mui/styles": "^6.1.7",
|
|
@@ -74,16 +74,17 @@ var dependencies = {
|
|
|
74
74
|
};
|
|
75
75
|
var peerDependencies = {
|
|
76
76
|
react: "^16.13.1 || ^17.0.0 || ^18.0.0",
|
|
77
|
+
"react-dom": "^16.13.1 || ^17.0.0 || ^18.0.0",
|
|
77
78
|
"react-router-dom": "^6.0.0"
|
|
78
79
|
};
|
|
79
80
|
var devDependencies = {
|
|
80
81
|
"@axe-core/playwright": "^4.11.0",
|
|
81
|
-
"@backstage/cli": "^0.35.
|
|
82
|
-
"@backstage/core-app-api": "^1.19.
|
|
83
|
-
"@backstage/dev-utils": "^1.1.
|
|
84
|
-
"@backstage/frontend-defaults": "^0.
|
|
85
|
-
"@backstage/test-utils": "^1.7.
|
|
86
|
-
"@backstage/ui": "^0.
|
|
82
|
+
"@backstage/cli": "^0.35.4",
|
|
83
|
+
"@backstage/core-app-api": "^1.19.5",
|
|
84
|
+
"@backstage/dev-utils": "^1.1.20",
|
|
85
|
+
"@backstage/frontend-defaults": "^0.4.0",
|
|
86
|
+
"@backstage/test-utils": "^1.7.15",
|
|
87
|
+
"@backstage/ui": "^0.12.0",
|
|
87
88
|
"@playwright/test": "^1.56.1",
|
|
88
89
|
"@testing-library/dom": "^10.0.0",
|
|
89
90
|
"@testing-library/jest-dom": "^6.0.0",
|
|
@@ -95,9 +96,8 @@ var devDependencies = {
|
|
|
95
96
|
"@types/react": "^18.2.58",
|
|
96
97
|
msw: "1.3.5",
|
|
97
98
|
react: "^16.13.1 || ^17.0.0 || ^18.0.0",
|
|
98
|
-
"react-dom": "^16.13.1 || ^17.0.0 || ^18.0.0",
|
|
99
99
|
"react-router-dom": "^6.0.0",
|
|
100
|
-
"start-server-and-test": "2.1.
|
|
100
|
+
"start-server-and-test": "2.1.5"
|
|
101
101
|
};
|
|
102
102
|
var files = [
|
|
103
103
|
"dist"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@backstage-community/plugin-rbac",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.50.0",
|
|
4
4
|
"main": "./dist/index.esm.js",
|
|
5
5
|
"types": "./dist/index.d.ts",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -62,17 +62,17 @@
|
|
|
62
62
|
"ui-test:legacy": "start-server-and-test start:legacy localhost:3000 'playwright test'"
|
|
63
63
|
},
|
|
64
64
|
"dependencies": {
|
|
65
|
-
"@backstage-community/plugin-rbac-common": "^1.
|
|
65
|
+
"@backstage-community/plugin-rbac-common": "^1.24.0",
|
|
66
66
|
"@backstage/catalog-model": "^1.7.6",
|
|
67
|
-
"@backstage/core-components": "^0.18.
|
|
68
|
-
"@backstage/core-plugin-api": "^1.12.
|
|
69
|
-
"@backstage/frontend-plugin-api": "^0.
|
|
70
|
-
"@backstage/plugin-app-react": "^0.
|
|
71
|
-
"@backstage/plugin-catalog": "^1.
|
|
72
|
-
"@backstage/plugin-catalog-common": "^1.1.
|
|
73
|
-
"@backstage/plugin-permission-common": "^0.9.
|
|
74
|
-
"@backstage/plugin-permission-react": "^0.4.
|
|
75
|
-
"@backstage/theme": "^0.7.
|
|
67
|
+
"@backstage/core-components": "^0.18.7",
|
|
68
|
+
"@backstage/core-plugin-api": "^1.12.3",
|
|
69
|
+
"@backstage/frontend-plugin-api": "^0.14.1",
|
|
70
|
+
"@backstage/plugin-app-react": "^0.2.0",
|
|
71
|
+
"@backstage/plugin-catalog": "^1.33.1",
|
|
72
|
+
"@backstage/plugin-catalog-common": "^1.1.8",
|
|
73
|
+
"@backstage/plugin-permission-common": "^0.9.6",
|
|
74
|
+
"@backstage/plugin-permission-react": "^0.4.40",
|
|
75
|
+
"@backstage/theme": "^0.7.2",
|
|
76
76
|
"@mui/icons-material": "5.18.0",
|
|
77
77
|
"@mui/material": "^5.14.18",
|
|
78
78
|
"@mui/styles": "^6.1.7",
|
|
@@ -87,16 +87,17 @@
|
|
|
87
87
|
},
|
|
88
88
|
"peerDependencies": {
|
|
89
89
|
"react": "^16.13.1 || ^17.0.0 || ^18.0.0",
|
|
90
|
+
"react-dom": "^16.13.1 || ^17.0.0 || ^18.0.0",
|
|
90
91
|
"react-router-dom": "^6.0.0"
|
|
91
92
|
},
|
|
92
93
|
"devDependencies": {
|
|
93
94
|
"@axe-core/playwright": "^4.11.0",
|
|
94
|
-
"@backstage/cli": "^0.35.
|
|
95
|
-
"@backstage/core-app-api": "^1.19.
|
|
96
|
-
"@backstage/dev-utils": "^1.1.
|
|
97
|
-
"@backstage/frontend-defaults": "^0.
|
|
98
|
-
"@backstage/test-utils": "^1.7.
|
|
99
|
-
"@backstage/ui": "^0.
|
|
95
|
+
"@backstage/cli": "^0.35.4",
|
|
96
|
+
"@backstage/core-app-api": "^1.19.5",
|
|
97
|
+
"@backstage/dev-utils": "^1.1.20",
|
|
98
|
+
"@backstage/frontend-defaults": "^0.4.0",
|
|
99
|
+
"@backstage/test-utils": "^1.7.15",
|
|
100
|
+
"@backstage/ui": "^0.12.0",
|
|
100
101
|
"@playwright/test": "^1.56.1",
|
|
101
102
|
"@testing-library/dom": "^10.0.0",
|
|
102
103
|
"@testing-library/jest-dom": "^6.0.0",
|
|
@@ -108,9 +109,8 @@
|
|
|
108
109
|
"@types/react": "^18.2.58",
|
|
109
110
|
"msw": "1.3.5",
|
|
110
111
|
"react": "^16.13.1 || ^17.0.0 || ^18.0.0",
|
|
111
|
-
"react-dom": "^16.13.1 || ^17.0.0 || ^18.0.0",
|
|
112
112
|
"react-router-dom": "^6.0.0",
|
|
113
|
-
"start-server-and-test": "2.1.
|
|
113
|
+
"start-server-and-test": "2.1.5"
|
|
114
114
|
},
|
|
115
115
|
"files": [
|
|
116
116
|
"dist"
|