@backstage/plugin-catalog-react 1.12.3-next.0 → 1.12.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,25 @@
|
|
|
1
1
|
# @backstage/plugin-catalog-react
|
|
2
2
|
|
|
3
|
+
## 1.12.3-next.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 7ca331c: Correct `EntityDisplayName`'s icon alignment with the text.
|
|
8
|
+
- 6349099: Added config input type to the extensions
|
|
9
|
+
- Updated dependencies
|
|
10
|
+
- @backstage/plugin-permission-common@0.8.1-next.0
|
|
11
|
+
- @backstage/frontend-plugin-api@0.6.8-next.1
|
|
12
|
+
- @backstage/plugin-catalog-common@1.0.26-next.0
|
|
13
|
+
- @backstage/plugin-permission-react@0.4.25-next.0
|
|
14
|
+
- @backstage/catalog-client@1.6.5
|
|
15
|
+
- @backstage/catalog-model@1.5.0
|
|
16
|
+
- @backstage/core-components@0.14.10-next.0
|
|
17
|
+
- @backstage/core-plugin-api@1.9.3
|
|
18
|
+
- @backstage/errors@1.2.4
|
|
19
|
+
- @backstage/integration-react@1.1.30-next.0
|
|
20
|
+
- @backstage/types@1.1.1
|
|
21
|
+
- @backstage/version-bridge@1.0.8
|
|
22
|
+
|
|
3
23
|
## 1.12.3-next.0
|
|
4
24
|
|
|
5
25
|
### Patch Changes
|
package/alpha/package.json
CHANGED
package/dist/alpha.d.ts
CHANGED
|
@@ -98,9 +98,9 @@ declare const catalogReactTranslationRef: _backstage_core_plugin_api_alpha.Trans
|
|
|
98
98
|
|
|
99
99
|
/** @alpha */
|
|
100
100
|
declare const catalogExtensionData: {
|
|
101
|
-
entityContentTitle: _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<"catalog.entity-content-title",
|
|
102
|
-
entityFilterFunction: _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<
|
|
103
|
-
entityFilterExpression: _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<"catalog.entity-filter-expression",
|
|
101
|
+
entityContentTitle: _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<string, "catalog.entity-content-title", {}>;
|
|
102
|
+
entityFilterFunction: _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<(entity: Entity) => boolean, "catalog.entity-filter-function", {}>;
|
|
103
|
+
entityFilterExpression: _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<string, "catalog.entity-filter-expression", {}>;
|
|
104
104
|
};
|
|
105
105
|
/** @alpha */
|
|
106
106
|
declare function createEntityCardExtension<TConfig extends {
|
|
@@ -120,7 +120,7 @@ declare function createEntityCardExtension<TConfig extends {
|
|
|
120
120
|
config: TConfig;
|
|
121
121
|
inputs: Expand<ResolvedExtensionInputs<TInputs>>;
|
|
122
122
|
}) => Promise<JSX.Element>;
|
|
123
|
-
}): _backstage_frontend_plugin_api.ExtensionDefinition<TConfig>;
|
|
123
|
+
}): _backstage_frontend_plugin_api.ExtensionDefinition<TConfig & {}, TConfig & {}>;
|
|
124
124
|
/** @alpha */
|
|
125
125
|
declare function createEntityContentExtension<TInputs extends AnyExtensionInputMap>(options: {
|
|
126
126
|
namespace?: string;
|
|
@@ -142,6 +142,10 @@ declare function createEntityContentExtension<TInputs extends AnyExtensionInputM
|
|
|
142
142
|
title: string;
|
|
143
143
|
path: string;
|
|
144
144
|
filter?: string | undefined;
|
|
145
|
+
}, {
|
|
146
|
+
filter?: string | undefined;
|
|
147
|
+
title?: string | undefined;
|
|
148
|
+
path?: string | undefined;
|
|
145
149
|
}>;
|
|
146
150
|
|
|
147
151
|
export { catalogExtensionData, catalogReactTranslationRef, createEntityCardExtension, createEntityContentExtension, isOwnerOf, useEntityPermission };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EntityDisplayName.esm.js","sources":["../../../src/components/EntityDisplayName/EntityDisplayName.tsx"],"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 */\n\nimport { CompoundEntityRef, Entity } from '@backstage/catalog-model';\nimport Box from '@material-ui/core/Box';\nimport Tooltip from '@material-ui/core/Tooltip';\nimport { Theme, makeStyles } from '@material-ui/core/styles';\nimport React from 'react';\nimport { useEntityPresentation } from '../../apis';\n\n/**\n * The available style class keys for {@link EntityDisplayName}, under the name\n * \"CatalogReactEntityDisplayName\".\n *\n * @public\n */\nexport type CatalogReactEntityDisplayNameClassKey = 'root' | 'icon';\n\nconst useStyles = makeStyles(\n (theme: Theme) => ({\n root: {\n display: 'inline-flex',\n alignItems: 'center',\n },\n icon: {\n marginRight: theme.spacing(0.5),\n color: theme.palette.text.secondary,\n
|
|
1
|
+
{"version":3,"file":"EntityDisplayName.esm.js","sources":["../../../src/components/EntityDisplayName/EntityDisplayName.tsx"],"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 */\n\nimport { CompoundEntityRef, Entity } from '@backstage/catalog-model';\nimport Box from '@material-ui/core/Box';\nimport Tooltip from '@material-ui/core/Tooltip';\nimport { Theme, makeStyles } from '@material-ui/core/styles';\nimport React from 'react';\nimport { useEntityPresentation } from '../../apis';\n\n/**\n * The available style class keys for {@link EntityDisplayName}, under the name\n * \"CatalogReactEntityDisplayName\".\n *\n * @public\n */\nexport type CatalogReactEntityDisplayNameClassKey = 'root' | 'icon';\n\nconst useStyles = makeStyles(\n (theme: Theme) => ({\n root: {\n display: 'inline-flex',\n alignItems: 'center',\n },\n icon: {\n marginRight: theme.spacing(0.5),\n color: theme.palette.text.secondary,\n '& svg': {\n verticalAlign: 'middle',\n },\n },\n }),\n { name: 'CatalogReactEntityDisplayName' },\n);\n\n/**\n * Props for {@link EntityDisplayName}.\n *\n * @public\n */\nexport type EntityDisplayNameProps = {\n entityRef: Entity | CompoundEntityRef | string;\n hideIcon?: boolean;\n disableTooltip?: boolean;\n defaultKind?: string;\n defaultNamespace?: string;\n};\n\n/**\n * Shows a nice representation of a reference to an entity.\n *\n * @public\n */\nexport const EntityDisplayName = (\n props: EntityDisplayNameProps,\n): JSX.Element => {\n const { entityRef, hideIcon, disableTooltip, defaultKind, defaultNamespace } =\n props;\n\n const classes = useStyles();\n const { primaryTitle, secondaryTitle, Icon } = useEntityPresentation(\n entityRef,\n { defaultKind, defaultNamespace },\n );\n\n // The innermost \"body\" content\n let content = <>{primaryTitle}</>;\n\n // Optionally an icon, and wrapper around them both\n content = (\n <Box component=\"span\" className={classes.root}>\n {Icon && !hideIcon ? (\n <Box component=\"span\" className={classes.icon}>\n <Icon fontSize=\"inherit\" />\n </Box>\n ) : null}\n {content}\n </Box>\n );\n\n // Optionally, a tooltip as the outermost layer\n if (secondaryTitle && !disableTooltip) {\n content = (\n <Tooltip enterDelay={1500} title={secondaryTitle}>\n {content}\n </Tooltip>\n );\n }\n\n return content;\n};\n"],"names":[],"mappings":";;;;;;;;;;;AA+BA,MAAM,SAAY,GAAA,UAAA;AAAA,EAChB,CAAC,KAAkB,MAAA;AAAA,IACjB,IAAM,EAAA;AAAA,MACJ,OAAS,EAAA,aAAA;AAAA,MACT,UAAY,EAAA,QAAA;AAAA,KACd;AAAA,IACA,IAAM,EAAA;AAAA,MACJ,WAAA,EAA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package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@backstage/plugin-catalog-react",
|
|
3
|
-
"version": "1.12.3-next.
|
|
3
|
+
"version": "1.12.3-next.1",
|
|
4
4
|
"description": "A frontend library that helps other Backstage plugins interact with the catalog",
|
|
5
5
|
"backstage": {
|
|
6
6
|
"role": "web-library",
|
|
@@ -61,11 +61,11 @@
|
|
|
61
61
|
"@backstage/core-components": "^0.14.10-next.0",
|
|
62
62
|
"@backstage/core-plugin-api": "^1.9.3",
|
|
63
63
|
"@backstage/errors": "^1.2.4",
|
|
64
|
-
"@backstage/frontend-plugin-api": "^0.6.8-next.
|
|
64
|
+
"@backstage/frontend-plugin-api": "^0.6.8-next.1",
|
|
65
65
|
"@backstage/integration-react": "^1.1.30-next.0",
|
|
66
|
-
"@backstage/plugin-catalog-common": "^1.0.
|
|
67
|
-
"@backstage/plugin-permission-common": "^0.8.0",
|
|
68
|
-
"@backstage/plugin-permission-react": "^0.4.
|
|
66
|
+
"@backstage/plugin-catalog-common": "^1.0.26-next.0",
|
|
67
|
+
"@backstage/plugin-permission-common": "^0.8.1-next.0",
|
|
68
|
+
"@backstage/plugin-permission-react": "^0.4.25-next.0",
|
|
69
69
|
"@backstage/types": "^1.1.1",
|
|
70
70
|
"@backstage/version-bridge": "^1.0.8",
|
|
71
71
|
"@material-ui/core": "^4.12.2",
|
|
@@ -82,11 +82,11 @@
|
|
|
82
82
|
"zen-observable": "^0.10.0"
|
|
83
83
|
},
|
|
84
84
|
"devDependencies": {
|
|
85
|
-
"@backstage/cli": "^0.27.0-next.
|
|
86
|
-
"@backstage/core-app-api": "^1.14.
|
|
87
|
-
"@backstage/plugin-catalog-common": "^1.0.
|
|
88
|
-
"@backstage/plugin-scaffolder-common": "^1.5.
|
|
89
|
-
"@backstage/test-utils": "^1.5.
|
|
85
|
+
"@backstage/cli": "^0.27.0-next.1",
|
|
86
|
+
"@backstage/core-app-api": "^1.14.2-next.0",
|
|
87
|
+
"@backstage/plugin-catalog-common": "^1.0.26-next.0",
|
|
88
|
+
"@backstage/plugin-scaffolder-common": "^1.5.5-next.0",
|
|
89
|
+
"@backstage/test-utils": "^1.5.10-next.1",
|
|
90
90
|
"@testing-library/dom": "^10.0.0",
|
|
91
91
|
"@testing-library/jest-dom": "^6.0.0",
|
|
92
92
|
"@testing-library/react": "^15.0.0",
|