@backstage/plugin-catalog 1.23.0-next.2 → 1.24.0-next.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 +58 -0
- package/alpha/package.json +1 -1
- package/dist/alpha/translation.esm.js +1 -1
- package/dist/alpha/translation.esm.js.map +1 -1
- package/dist/alpha.d.ts +97 -28
- package/dist/components/CatalogSearchResultListItem/CatalogSearchResultListItem.esm.js.map +1 -1
- package/dist/components/CatalogTable/CatalogTableToolbar.esm.js +1 -1
- package/dist/components/CatalogTable/CatalogTableToolbar.esm.js.map +1 -1
- package/dist/components/CatalogTable/CursorPaginatedCatalogTable.esm.js +1 -0
- package/dist/components/CatalogTable/CursorPaginatedCatalogTable.esm.js.map +1 -1
- package/dist/components/CatalogTable/OffsetPaginatedCatalogTable.esm.js +3 -2
- package/dist/components/CatalogTable/OffsetPaginatedCatalogTable.esm.js.map +1 -1
- package/dist/components/CatalogTable/defaultCatalogTableColumnsFunc.esm.js +14 -7
- package/dist/components/CatalogTable/defaultCatalogTableColumnsFunc.esm.js.map +1 -1
- package/dist/components/EntityLabelsCard/EntityLabelsEmptyState.esm.js.map +1 -1
- package/dist/components/RelatedEntitiesCard/RelatedEntitiesCard.esm.js +1 -1
- package/dist/components/RelatedEntitiesCard/RelatedEntitiesCard.esm.js.map +1 -1
- package/dist/index.d.ts +38 -27
- package/dist/index.esm.js +1 -0
- package/dist/index.esm.js.map +1 -1
- package/package.json +19 -18
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,63 @@
|
|
|
1
1
|
# @backstage/plugin-catalog
|
|
2
2
|
|
|
3
|
+
## 1.24.0-next.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 71f9f0c: Updated default columns for location entities to remove description and tags from the catalog table view.
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- 46b5a20: Empty states updated with external link icon for learn more links
|
|
12
|
+
- Updated dependencies
|
|
13
|
+
- @backstage/frontend-plugin-api@0.9.0-next.0
|
|
14
|
+
- @backstage/core-compat-api@0.3.1-next.0
|
|
15
|
+
- @backstage/core-components@0.15.1-next.0
|
|
16
|
+
- @backstage/core-plugin-api@1.10.0-next.0
|
|
17
|
+
- @backstage/plugin-catalog-react@1.13.1-next.0
|
|
18
|
+
- @backstage/plugin-search-react@1.8.1-next.0
|
|
19
|
+
- @backstage/catalog-client@1.7.0
|
|
20
|
+
- @backstage/catalog-model@1.7.0
|
|
21
|
+
- @backstage/errors@1.2.4
|
|
22
|
+
- @backstage/integration-react@1.1.32-next.0
|
|
23
|
+
- @backstage/types@1.1.1
|
|
24
|
+
- @backstage/plugin-catalog-common@1.1.0
|
|
25
|
+
- @backstage/plugin-permission-react@0.4.27-next.0
|
|
26
|
+
- @backstage/plugin-scaffolder-common@1.5.6
|
|
27
|
+
- @backstage/plugin-search-common@1.2.14
|
|
28
|
+
|
|
29
|
+
## 1.23.0
|
|
30
|
+
|
|
31
|
+
### Minor Changes
|
|
32
|
+
|
|
33
|
+
- 78475c3: Allow offset mode paging in entity list provider
|
|
34
|
+
|
|
35
|
+
### Patch Changes
|
|
36
|
+
|
|
37
|
+
- c891b69: Add `FavoriteToggle` in `core-components` to standardise favorite marking
|
|
38
|
+
- fec8b57: Updated exports to use the new type parameters for extensions and extension blueprints.
|
|
39
|
+
- 836127c: Updated dependency `@testing-library/react` to `^16.0.0`.
|
|
40
|
+
- 5446061: The `/alpha` export no longer export extension creators for the new frontend system, existing usage should be switched to use the equivalent extension blueprint instead. For more information see the [new frontend system 1.30 migration documentation](https://backstage.io/docs/frontend-system/architecture/migrations#130).
|
|
41
|
+
- 0ff53c8: Enable loading state for paginated catalog tables by passing `isLoading` prop
|
|
42
|
+
- 180a45f: Entity presentation api now only fetches fields that are required to display entity title
|
|
43
|
+
- a159180: Added missing items to `overridableComponents`
|
|
44
|
+
- Updated dependencies
|
|
45
|
+
- @backstage/core-components@0.15.0
|
|
46
|
+
- @backstage/plugin-catalog-react@1.13.0
|
|
47
|
+
- @backstage/frontend-plugin-api@0.8.0
|
|
48
|
+
- @backstage/core-compat-api@0.3.0
|
|
49
|
+
- @backstage/plugin-search-react@1.8.0
|
|
50
|
+
- @backstage/integration-react@1.1.31
|
|
51
|
+
- @backstage/catalog-model@1.7.0
|
|
52
|
+
- @backstage/catalog-client@1.7.0
|
|
53
|
+
- @backstage/plugin-catalog-common@1.1.0
|
|
54
|
+
- @backstage/core-plugin-api@1.9.4
|
|
55
|
+
- @backstage/plugin-permission-react@0.4.26
|
|
56
|
+
- @backstage/errors@1.2.4
|
|
57
|
+
- @backstage/types@1.1.1
|
|
58
|
+
- @backstage/plugin-scaffolder-common@1.5.6
|
|
59
|
+
- @backstage/plugin-search-common@1.2.14
|
|
60
|
+
|
|
3
61
|
## 1.23.0-next.2
|
|
4
62
|
|
|
5
63
|
### Minor Changes
|
package/alpha/package.json
CHANGED
|
@@ -130,7 +130,7 @@ const catalogTranslationRef = createTranslationRef({
|
|
|
130
130
|
emptyMessage: "No system is part of this domain"
|
|
131
131
|
},
|
|
132
132
|
relatedEntitiesCard: {
|
|
133
|
-
emptyHelpLinkTitle: "Learn how to change this
|
|
133
|
+
emptyHelpLinkTitle: "Learn how to change this"
|
|
134
134
|
},
|
|
135
135
|
systemDiagramCard: {
|
|
136
136
|
title: "System Diagram",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"translation.esm.js","sources":["../../src/alpha/translation.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 */\n\nimport { createTranslationRef } from '@backstage/core-plugin-api/alpha';\n\n/** @alpha */\nexport const catalogTranslationRef = createTranslationRef({\n id: 'catalog',\n messages: {\n indexPage: {\n title: `{{orgName}} Catalog`,\n createButtonTitle: 'Create',\n supportButtonContent: 'All your software catalog entities',\n },\n aboutCard: {\n title: 'About',\n refreshButtonTitle: 'Schedule entity refresh',\n editButtonTitle: 'Edit Metadata',\n createSimilarButtonTitle: 'Create something similar',\n refreshScheduledMessage: 'Refresh scheduled',\n launchTemplate: 'Launch Template',\n viewTechdocs: 'View TechDocs',\n viewSource: 'View Source',\n descriptionField: {\n label: 'Description',\n value: 'No description',\n },\n ownerField: {\n label: 'Owner',\n value: 'No Owner',\n },\n domainField: {\n label: 'Domain',\n value: 'No Domain',\n },\n systemField: {\n label: 'System',\n value: 'No System',\n },\n parentComponentField: {\n label: 'Parent Component',\n value: 'No Parent Component',\n },\n typeField: {\n label: 'Type',\n },\n lifecycleField: {\n label: 'Lifecycle',\n },\n tagsField: {\n label: 'Tags',\n value: 'No Tags',\n },\n targetsField: {\n label: 'Targets',\n },\n },\n searchResultItem: {\n lifecycle: 'Lifecycle',\n Owner: 'Owner',\n },\n catalogTable: {\n warningPanelTitle: 'Could not fetch catalog entities.',\n viewActionTitle: 'View',\n editActionTitle: 'Edit',\n starActionTitle: 'Add to favorites',\n unStarActionTitle: 'Remove from favorites',\n },\n dependencyOfComponentsCard: {\n title: 'Dependency of components',\n emptyMessage: 'No component depends on this component',\n },\n dependsOnComponentsCard: {\n title: 'Depends on components',\n emptyMessage: 'No component is a dependency of this component',\n },\n dependsOnResourcesCard: {\n title: 'Depends on resources',\n emptyMessage: 'No resource is a dependency of this component',\n },\n entityContextMenu: {\n copiedMessage: 'Copied!',\n moreButtonTitle: 'More',\n inspectMenuTitle: 'Inspect entity',\n copyURLMenuTitle: 'Copy entity URL',\n unregisterMenuTitle: 'Unregister entity',\n },\n entityLabelsCard: {\n title: 'Labels',\n emptyDescription:\n 'No labels defined for this entity. You can add labels to your entity YAML as shown in the highlighted example below:',\n readMoreButtonTitle: 'Read more',\n },\n entityLabels: {\n warningPanelTitle: 'Entity not found',\n ownerLabel: 'Owner',\n lifecycleLabel: 'Lifecycle',\n },\n entityLinksCard: {\n title: 'Links',\n emptyDescription:\n 'No links defined for this entity. You can add links to your entity YAML as shown in the highlighted example below:',\n readMoreButtonTitle: 'Read more',\n },\n entityNotFound: {\n title: 'Entity was not found',\n description:\n 'Want to help us build this? Check out our Getting Started documentation.',\n docButtonTitle: 'DOCS',\n },\n deleteEntity: {\n dialogTitle: 'Are you sure you want to delete this entity?',\n deleteButtonTitle: 'Delete',\n cancelButtonTitle: 'Cancel',\n description:\n 'This entity is not referenced by any location and is therefore not receiving updates. Click here to delete.',\n },\n entityProcessingErrorsDescription: 'The error below originates from',\n entityRelationWarningDescription:\n \"This entity has relations to other entities, which can't be found in the catalog.\\n Entities not found are: \",\n hasComponentsCard: {\n title: 'Has components',\n emptyMessage: 'No component is part of this system',\n },\n hasResourcesCard: {\n title: 'Has resources',\n emptyMessage: 'No resource is part of this system',\n },\n hasSubcomponentsCard: {\n title: 'Has subcomponents',\n emptyMessage: 'No subcomponent is part of this component',\n },\n hasSubdomainsCard: {\n title: 'Has subdomains',\n emptyMessage: 'No subdomain is part of this domain',\n },\n hasSystemsCard: {\n title: 'Has systems',\n emptyMessage: 'No system is part of this domain',\n },\n relatedEntitiesCard: {\n emptyHelpLinkTitle: 'Learn how to change this
|
|
1
|
+
{"version":3,"file":"translation.esm.js","sources":["../../src/alpha/translation.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 */\n\nimport { createTranslationRef } from '@backstage/core-plugin-api/alpha';\n\n/** @alpha */\nexport const catalogTranslationRef = createTranslationRef({\n id: 'catalog',\n messages: {\n indexPage: {\n title: `{{orgName}} Catalog`,\n createButtonTitle: 'Create',\n supportButtonContent: 'All your software catalog entities',\n },\n aboutCard: {\n title: 'About',\n refreshButtonTitle: 'Schedule entity refresh',\n editButtonTitle: 'Edit Metadata',\n createSimilarButtonTitle: 'Create something similar',\n refreshScheduledMessage: 'Refresh scheduled',\n launchTemplate: 'Launch Template',\n viewTechdocs: 'View TechDocs',\n viewSource: 'View Source',\n descriptionField: {\n label: 'Description',\n value: 'No description',\n },\n ownerField: {\n label: 'Owner',\n value: 'No Owner',\n },\n domainField: {\n label: 'Domain',\n value: 'No Domain',\n },\n systemField: {\n label: 'System',\n value: 'No System',\n },\n parentComponentField: {\n label: 'Parent Component',\n value: 'No Parent Component',\n },\n typeField: {\n label: 'Type',\n },\n lifecycleField: {\n label: 'Lifecycle',\n },\n tagsField: {\n label: 'Tags',\n value: 'No Tags',\n },\n targetsField: {\n label: 'Targets',\n },\n },\n searchResultItem: {\n lifecycle: 'Lifecycle',\n Owner: 'Owner',\n },\n catalogTable: {\n warningPanelTitle: 'Could not fetch catalog entities.',\n viewActionTitle: 'View',\n editActionTitle: 'Edit',\n starActionTitle: 'Add to favorites',\n unStarActionTitle: 'Remove from favorites',\n },\n dependencyOfComponentsCard: {\n title: 'Dependency of components',\n emptyMessage: 'No component depends on this component',\n },\n dependsOnComponentsCard: {\n title: 'Depends on components',\n emptyMessage: 'No component is a dependency of this component',\n },\n dependsOnResourcesCard: {\n title: 'Depends on resources',\n emptyMessage: 'No resource is a dependency of this component',\n },\n entityContextMenu: {\n copiedMessage: 'Copied!',\n moreButtonTitle: 'More',\n inspectMenuTitle: 'Inspect entity',\n copyURLMenuTitle: 'Copy entity URL',\n unregisterMenuTitle: 'Unregister entity',\n },\n entityLabelsCard: {\n title: 'Labels',\n emptyDescription:\n 'No labels defined for this entity. You can add labels to your entity YAML as shown in the highlighted example below:',\n readMoreButtonTitle: 'Read more',\n },\n entityLabels: {\n warningPanelTitle: 'Entity not found',\n ownerLabel: 'Owner',\n lifecycleLabel: 'Lifecycle',\n },\n entityLinksCard: {\n title: 'Links',\n emptyDescription:\n 'No links defined for this entity. You can add links to your entity YAML as shown in the highlighted example below:',\n readMoreButtonTitle: 'Read more',\n },\n entityNotFound: {\n title: 'Entity was not found',\n description:\n 'Want to help us build this? Check out our Getting Started documentation.',\n docButtonTitle: 'DOCS',\n },\n deleteEntity: {\n dialogTitle: 'Are you sure you want to delete this entity?',\n deleteButtonTitle: 'Delete',\n cancelButtonTitle: 'Cancel',\n description:\n 'This entity is not referenced by any location and is therefore not receiving updates. Click here to delete.',\n },\n entityProcessingErrorsDescription: 'The error below originates from',\n entityRelationWarningDescription:\n \"This entity has relations to other entities, which can't be found in the catalog.\\n Entities not found are: \",\n hasComponentsCard: {\n title: 'Has components',\n emptyMessage: 'No component is part of this system',\n },\n hasResourcesCard: {\n title: 'Has resources',\n emptyMessage: 'No resource is part of this system',\n },\n hasSubcomponentsCard: {\n title: 'Has subcomponents',\n emptyMessage: 'No subcomponent is part of this component',\n },\n hasSubdomainsCard: {\n title: 'Has subdomains',\n emptyMessage: 'No subdomain is part of this domain',\n },\n hasSystemsCard: {\n title: 'Has systems',\n emptyMessage: 'No system is part of this domain',\n },\n relatedEntitiesCard: {\n emptyHelpLinkTitle: 'Learn how to change this',\n },\n systemDiagramCard: {\n title: 'System Diagram',\n description: 'Use pinch & zoo to move around the diagram.',\n edgeLabels: {\n partOf: 'part of',\n provides: 'provides',\n dependsOn: 'depends on',\n },\n },\n },\n});\n"],"names":[],"mappings":";;AAmBO,MAAM,wBAAwB,oBAAqB,CAAA;AAAA,EACxD,EAAI,EAAA,SAAA;AAAA,EACJ,QAAU,EAAA;AAAA,IACR,SAAW,EAAA;AAAA,MACT,KAAO,EAAA,CAAA,mBAAA,CAAA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AA;AAAA,MACb,iBAAmB,EAAA,QAAA;AAAA,MACnB,iBAAmB,EAAA,QAAA;AAAA,MACnB,WACE,EAAA,6GAAA;AAAA,KACJ;AAAA,IACA,iCAAmC,EAAA,iCAAA;AAAA,IACnC,gCACE,EAAA,8GAAA;AAAA,IACF,iBAAmB,EAAA;AAAA,MACjB,KAAO,EAAA,gBAAA;AAAA,MACP,YAAc,EAAA,qCAAA;AAAA,KAChB;AAAA,IACA,gBAAkB,EAAA;AAAA,MAChB,KAAO,EAAA,eAAA;AAAA,MACP,YAAc,EAAA,oCAAA;AAAA,KAChB;AAAA,IACA,oBAAsB,EAAA;AAAA,MACpB,KAAO,EAAA,mBAAA;AAAA,MACP,YAAc,EAAA,2CAAA;AAAA,KAChB;AAAA,IACA,iBAAmB,EAAA;AAAA,MACjB,KAAO,EAAA,gBAAA;AAAA,MACP,YAAc,EAAA,qCAAA;AAAA,KAChB;AAAA,IACA,cAAgB,EAAA;AAAA,MACd,KAAO,EAAA,aAAA;AAAA,MACP,YAAc,EAAA,kCAAA;AAAA,KAChB;AAAA,IACA,mBAAqB,EAAA;AAAA,MACnB,kBAAoB,EAAA,0BAAA;AAAA,KACtB;AAAA,IACA,iBAAmB,EAAA;AAAA,MACjB,KAAO,EAAA,gBAAA;AAAA,MACP,WAAa,EAAA,6CAAA;AAAA,MACb,UAAY,EAAA;AAAA,QACV,MAAQ,EAAA,SAAA;AAAA,QACR,QAAU,EAAA,UAAA;AAAA,QACV,SAAW,EAAA,YAAA;AAAA,OACb;AAAA,KACF;AAAA,GACF;AACF,CAAC;;;;"}
|
package/dist/alpha.d.ts
CHANGED
|
@@ -29,16 +29,17 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
29
29
|
}, {
|
|
30
30
|
"api:catalog": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
31
31
|
kind: "api";
|
|
32
|
-
namespace: undefined;
|
|
33
32
|
name: undefined;
|
|
34
33
|
config: {};
|
|
35
34
|
configInput: {};
|
|
36
35
|
output: _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<_backstage_frontend_plugin_api.AnyApiFactory, "core.api.factory", {}>;
|
|
37
36
|
inputs: {};
|
|
37
|
+
params: {
|
|
38
|
+
factory: _backstage_frontend_plugin_api.AnyApiFactory;
|
|
39
|
+
};
|
|
38
40
|
}>;
|
|
39
41
|
"nav-item:catalog": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
40
42
|
kind: "nav-item";
|
|
41
|
-
namespace: undefined;
|
|
42
43
|
name: undefined;
|
|
43
44
|
config: {};
|
|
44
45
|
configInput: {};
|
|
@@ -48,28 +49,36 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
48
49
|
routeRef: _backstage_frontend_plugin_api.RouteRef<undefined>;
|
|
49
50
|
}, "core.nav-item.target", {}>;
|
|
50
51
|
inputs: {};
|
|
52
|
+
params: {
|
|
53
|
+
title: string;
|
|
54
|
+
icon: _backstage_core_plugin_api.IconComponent;
|
|
55
|
+
routeRef: _backstage_frontend_plugin_api.RouteRef<undefined>;
|
|
56
|
+
};
|
|
51
57
|
}>;
|
|
52
58
|
"api:catalog/starred-entities": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
53
59
|
kind: "api";
|
|
54
|
-
namespace: undefined;
|
|
55
60
|
name: "starred-entities";
|
|
56
61
|
config: {};
|
|
57
62
|
configInput: {};
|
|
58
63
|
output: _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<_backstage_frontend_plugin_api.AnyApiFactory, "core.api.factory", {}>;
|
|
59
64
|
inputs: {};
|
|
65
|
+
params: {
|
|
66
|
+
factory: _backstage_frontend_plugin_api.AnyApiFactory;
|
|
67
|
+
};
|
|
60
68
|
}>;
|
|
61
69
|
"api:catalog/entity-presentation": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
62
70
|
kind: "api";
|
|
63
|
-
namespace: undefined;
|
|
64
71
|
name: "entity-presentation";
|
|
65
72
|
config: {};
|
|
66
73
|
configInput: {};
|
|
67
74
|
output: _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<_backstage_frontend_plugin_api.AnyApiFactory, "core.api.factory", {}>;
|
|
68
75
|
inputs: {};
|
|
76
|
+
params: {
|
|
77
|
+
factory: _backstage_frontend_plugin_api.AnyApiFactory;
|
|
78
|
+
};
|
|
69
79
|
}>;
|
|
70
80
|
"entity-card:catalog/about": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
71
81
|
kind: "entity-card";
|
|
72
|
-
namespace: undefined;
|
|
73
82
|
name: "about";
|
|
74
83
|
config: {
|
|
75
84
|
filter: string | undefined;
|
|
@@ -83,10 +92,13 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
83
92
|
optional: true;
|
|
84
93
|
}>;
|
|
85
94
|
inputs: {};
|
|
95
|
+
params: {
|
|
96
|
+
loader: () => Promise<JSX.Element>;
|
|
97
|
+
filter?: string | ((entity: _backstage_catalog_model.Entity) => boolean) | undefined;
|
|
98
|
+
};
|
|
86
99
|
}>;
|
|
87
100
|
"entity-card:catalog/links": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
88
101
|
kind: "entity-card";
|
|
89
|
-
namespace: undefined;
|
|
90
102
|
name: "links";
|
|
91
103
|
config: {
|
|
92
104
|
filter: string | undefined;
|
|
@@ -100,10 +112,13 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
100
112
|
optional: true;
|
|
101
113
|
}>;
|
|
102
114
|
inputs: {};
|
|
115
|
+
params: {
|
|
116
|
+
loader: () => Promise<JSX.Element>;
|
|
117
|
+
filter?: string | ((entity: _backstage_catalog_model.Entity) => boolean) | undefined;
|
|
118
|
+
};
|
|
103
119
|
}>;
|
|
104
120
|
"entity-card:catalog/labels": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
105
121
|
kind: "entity-card";
|
|
106
|
-
namespace: undefined;
|
|
107
122
|
name: "labels";
|
|
108
123
|
config: {
|
|
109
124
|
filter: string | undefined;
|
|
@@ -117,10 +132,13 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
117
132
|
optional: true;
|
|
118
133
|
}>;
|
|
119
134
|
inputs: {};
|
|
135
|
+
params: {
|
|
136
|
+
loader: () => Promise<JSX.Element>;
|
|
137
|
+
filter?: string | ((entity: _backstage_catalog_model.Entity) => boolean) | undefined;
|
|
138
|
+
};
|
|
120
139
|
}>;
|
|
121
140
|
"entity-card:catalog/depends-on-components": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
122
141
|
kind: "entity-card";
|
|
123
|
-
namespace: undefined;
|
|
124
142
|
name: "depends-on-components";
|
|
125
143
|
config: {
|
|
126
144
|
filter: string | undefined;
|
|
@@ -134,10 +152,13 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
134
152
|
optional: true;
|
|
135
153
|
}>;
|
|
136
154
|
inputs: {};
|
|
155
|
+
params: {
|
|
156
|
+
loader: () => Promise<JSX.Element>;
|
|
157
|
+
filter?: string | ((entity: _backstage_catalog_model.Entity) => boolean) | undefined;
|
|
158
|
+
};
|
|
137
159
|
}>;
|
|
138
160
|
"entity-card:catalog/depends-on-resources": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
139
161
|
kind: "entity-card";
|
|
140
|
-
namespace: undefined;
|
|
141
162
|
name: "depends-on-resources";
|
|
142
163
|
config: {
|
|
143
164
|
filter: string | undefined;
|
|
@@ -151,10 +172,13 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
151
172
|
optional: true;
|
|
152
173
|
}>;
|
|
153
174
|
inputs: {};
|
|
175
|
+
params: {
|
|
176
|
+
loader: () => Promise<JSX.Element>;
|
|
177
|
+
filter?: string | ((entity: _backstage_catalog_model.Entity) => boolean) | undefined;
|
|
178
|
+
};
|
|
154
179
|
}>;
|
|
155
180
|
"entity-card:catalog/has-components": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
156
181
|
kind: "entity-card";
|
|
157
|
-
namespace: undefined;
|
|
158
182
|
name: "has-components";
|
|
159
183
|
config: {
|
|
160
184
|
filter: string | undefined;
|
|
@@ -168,10 +192,13 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
168
192
|
optional: true;
|
|
169
193
|
}>;
|
|
170
194
|
inputs: {};
|
|
195
|
+
params: {
|
|
196
|
+
loader: () => Promise<JSX.Element>;
|
|
197
|
+
filter?: string | ((entity: _backstage_catalog_model.Entity) => boolean) | undefined;
|
|
198
|
+
};
|
|
171
199
|
}>;
|
|
172
200
|
"entity-card:catalog/has-resources": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
173
201
|
kind: "entity-card";
|
|
174
|
-
namespace: undefined;
|
|
175
202
|
name: "has-resources";
|
|
176
203
|
config: {
|
|
177
204
|
filter: string | undefined;
|
|
@@ -185,10 +212,13 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
185
212
|
optional: true;
|
|
186
213
|
}>;
|
|
187
214
|
inputs: {};
|
|
215
|
+
params: {
|
|
216
|
+
loader: () => Promise<JSX.Element>;
|
|
217
|
+
filter?: string | ((entity: _backstage_catalog_model.Entity) => boolean) | undefined;
|
|
218
|
+
};
|
|
188
219
|
}>;
|
|
189
220
|
"entity-card:catalog/has-subcomponents": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
190
221
|
kind: "entity-card";
|
|
191
|
-
namespace: undefined;
|
|
192
222
|
name: "has-subcomponents";
|
|
193
223
|
config: {
|
|
194
224
|
filter: string | undefined;
|
|
@@ -202,10 +232,13 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
202
232
|
optional: true;
|
|
203
233
|
}>;
|
|
204
234
|
inputs: {};
|
|
235
|
+
params: {
|
|
236
|
+
loader: () => Promise<JSX.Element>;
|
|
237
|
+
filter?: string | ((entity: _backstage_catalog_model.Entity) => boolean) | undefined;
|
|
238
|
+
};
|
|
205
239
|
}>;
|
|
206
240
|
"entity-card:catalog/has-subdomains": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
207
241
|
kind: "entity-card";
|
|
208
|
-
namespace: undefined;
|
|
209
242
|
name: "has-subdomains";
|
|
210
243
|
config: {
|
|
211
244
|
filter: string | undefined;
|
|
@@ -219,10 +252,13 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
219
252
|
optional: true;
|
|
220
253
|
}>;
|
|
221
254
|
inputs: {};
|
|
255
|
+
params: {
|
|
256
|
+
loader: () => Promise<JSX.Element>;
|
|
257
|
+
filter?: string | ((entity: _backstage_catalog_model.Entity) => boolean) | undefined;
|
|
258
|
+
};
|
|
222
259
|
}>;
|
|
223
260
|
"entity-card:catalog/has-systems": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
224
261
|
kind: "entity-card";
|
|
225
|
-
namespace: undefined;
|
|
226
262
|
name: "has-systems";
|
|
227
263
|
config: {
|
|
228
264
|
filter: string | undefined;
|
|
@@ -236,6 +272,10 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
236
272
|
optional: true;
|
|
237
273
|
}>;
|
|
238
274
|
inputs: {};
|
|
275
|
+
params: {
|
|
276
|
+
loader: () => Promise<JSX.Element>;
|
|
277
|
+
filter?: string | ((entity: _backstage_catalog_model.Entity) => boolean) | undefined;
|
|
278
|
+
};
|
|
239
279
|
}>;
|
|
240
280
|
"entity-content:catalog/overview": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
241
281
|
config: {
|
|
@@ -266,17 +306,25 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
266
306
|
}>;
|
|
267
307
|
};
|
|
268
308
|
kind: "entity-content";
|
|
269
|
-
namespace: undefined;
|
|
270
309
|
name: "overview";
|
|
310
|
+
params: {
|
|
311
|
+
loader: () => Promise<JSX.Element>;
|
|
312
|
+
defaultPath: string;
|
|
313
|
+
defaultTitle: string;
|
|
314
|
+
routeRef?: _backstage_frontend_plugin_api.RouteRef<_backstage_frontend_plugin_api.AnyRouteRefParams> | undefined;
|
|
315
|
+
filter?: string | ((entity: _backstage_catalog_model.Entity) => boolean) | undefined;
|
|
316
|
+
};
|
|
271
317
|
}>;
|
|
272
318
|
"catalog-filter:catalog/tag": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
273
319
|
kind: "catalog-filter";
|
|
274
|
-
namespace: undefined;
|
|
275
320
|
name: "tag";
|
|
276
321
|
config: {};
|
|
277
322
|
configInput: {};
|
|
278
323
|
output: _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<React.JSX.Element, "core.reactElement", {}>;
|
|
279
324
|
inputs: {};
|
|
325
|
+
params: {
|
|
326
|
+
loader: () => Promise<JSX.Element>;
|
|
327
|
+
};
|
|
280
328
|
}>;
|
|
281
329
|
"catalog-filter:catalog/kind": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
282
330
|
config: {
|
|
@@ -293,17 +341,21 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
293
341
|
}>;
|
|
294
342
|
};
|
|
295
343
|
kind: "catalog-filter";
|
|
296
|
-
namespace: undefined;
|
|
297
344
|
name: "kind";
|
|
345
|
+
params: {
|
|
346
|
+
loader: () => Promise<JSX.Element>;
|
|
347
|
+
};
|
|
298
348
|
}>;
|
|
299
349
|
"catalog-filter:catalog/type": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
300
350
|
kind: "catalog-filter";
|
|
301
|
-
namespace: undefined;
|
|
302
351
|
name: "type";
|
|
303
352
|
config: {};
|
|
304
353
|
configInput: {};
|
|
305
354
|
output: _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<React.JSX.Element, "core.reactElement", {}>;
|
|
306
355
|
inputs: {};
|
|
356
|
+
params: {
|
|
357
|
+
loader: () => Promise<JSX.Element>;
|
|
358
|
+
};
|
|
307
359
|
}>;
|
|
308
360
|
"catalog-filter:catalog/mode": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
309
361
|
config: {
|
|
@@ -320,35 +372,43 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
320
372
|
}>;
|
|
321
373
|
};
|
|
322
374
|
kind: "catalog-filter";
|
|
323
|
-
namespace: undefined;
|
|
324
375
|
name: "mode";
|
|
376
|
+
params: {
|
|
377
|
+
loader: () => Promise<JSX.Element>;
|
|
378
|
+
};
|
|
325
379
|
}>;
|
|
326
380
|
"catalog-filter:catalog/namespace": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
327
381
|
kind: "catalog-filter";
|
|
328
|
-
namespace: undefined;
|
|
329
382
|
name: "namespace";
|
|
330
383
|
config: {};
|
|
331
384
|
configInput: {};
|
|
332
385
|
output: _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<React.JSX.Element, "core.reactElement", {}>;
|
|
333
386
|
inputs: {};
|
|
387
|
+
params: {
|
|
388
|
+
loader: () => Promise<JSX.Element>;
|
|
389
|
+
};
|
|
334
390
|
}>;
|
|
335
391
|
"catalog-filter:catalog/lifecycle": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
336
392
|
kind: "catalog-filter";
|
|
337
|
-
namespace: undefined;
|
|
338
393
|
name: "lifecycle";
|
|
339
394
|
config: {};
|
|
340
395
|
configInput: {};
|
|
341
396
|
output: _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<React.JSX.Element, "core.reactElement", {}>;
|
|
342
397
|
inputs: {};
|
|
398
|
+
params: {
|
|
399
|
+
loader: () => Promise<JSX.Element>;
|
|
400
|
+
};
|
|
343
401
|
}>;
|
|
344
402
|
"catalog-filter:catalog/processing-status": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
345
403
|
kind: "catalog-filter";
|
|
346
|
-
namespace: undefined;
|
|
347
404
|
name: "processing-status";
|
|
348
405
|
config: {};
|
|
349
406
|
configInput: {};
|
|
350
407
|
output: _backstage_frontend_plugin_api.ConfigurableExtensionDataRef<React.JSX.Element, "core.reactElement", {}>;
|
|
351
408
|
inputs: {};
|
|
409
|
+
params: {
|
|
410
|
+
loader: () => Promise<JSX.Element>;
|
|
411
|
+
};
|
|
352
412
|
}>;
|
|
353
413
|
"catalog-filter:catalog/list": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
354
414
|
config: {
|
|
@@ -365,8 +425,10 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
365
425
|
}>;
|
|
366
426
|
};
|
|
367
427
|
kind: "catalog-filter";
|
|
368
|
-
namespace: undefined;
|
|
369
428
|
name: "list";
|
|
429
|
+
params: {
|
|
430
|
+
loader: () => Promise<JSX.Element>;
|
|
431
|
+
};
|
|
370
432
|
}>;
|
|
371
433
|
"page:catalog": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
372
434
|
config: {
|
|
@@ -385,8 +447,12 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
385
447
|
}>;
|
|
386
448
|
};
|
|
387
449
|
kind: "page";
|
|
388
|
-
namespace: undefined;
|
|
389
450
|
name: undefined;
|
|
451
|
+
params: {
|
|
452
|
+
defaultPath: string;
|
|
453
|
+
loader: () => Promise<JSX.Element>;
|
|
454
|
+
routeRef?: _backstage_frontend_plugin_api.RouteRef<_backstage_frontend_plugin_api.AnyRouteRefParams> | undefined;
|
|
455
|
+
};
|
|
390
456
|
}>;
|
|
391
457
|
"page:catalog/entity": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
392
458
|
config: {
|
|
@@ -411,12 +477,15 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
411
477
|
}>;
|
|
412
478
|
};
|
|
413
479
|
kind: "page";
|
|
414
|
-
namespace: undefined;
|
|
415
480
|
name: "entity";
|
|
481
|
+
params: {
|
|
482
|
+
defaultPath: string;
|
|
483
|
+
loader: () => Promise<JSX.Element>;
|
|
484
|
+
routeRef?: _backstage_frontend_plugin_api.RouteRef<_backstage_frontend_plugin_api.AnyRouteRefParams> | undefined;
|
|
485
|
+
};
|
|
416
486
|
}>;
|
|
417
487
|
"search-result-list-item:catalog": _backstage_frontend_plugin_api.ExtensionDefinition<{
|
|
418
488
|
kind: "search-result-list-item";
|
|
419
|
-
namespace: undefined;
|
|
420
489
|
name: undefined;
|
|
421
490
|
config: {
|
|
422
491
|
noTrack: boolean;
|
|
@@ -429,6 +498,7 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
429
498
|
component: _backstage_plugin_search_react_alpha.SearchResultItemExtensionComponent;
|
|
430
499
|
}, "search.search-result-list-item.item", {}>;
|
|
431
500
|
inputs: {};
|
|
501
|
+
params: _backstage_plugin_search_react_alpha.SearchResultListItemBlueprintParams;
|
|
432
502
|
}>;
|
|
433
503
|
}>;
|
|
434
504
|
|
|
@@ -438,7 +508,6 @@ declare const _default: _backstage_frontend_plugin_api.FrontendPlugin<{
|
|
|
438
508
|
*/
|
|
439
509
|
declare const CatalogFilterBlueprint: _backstage_frontend_plugin_api.ExtensionBlueprint<{
|
|
440
510
|
kind: "catalog-filter";
|
|
441
|
-
namespace: undefined;
|
|
442
511
|
name: undefined;
|
|
443
512
|
params: {
|
|
444
513
|
loader: () => Promise<JSX.Element>;
|
|
@@ -524,7 +593,7 @@ declare const catalogTranslationRef: _backstage_core_plugin_api_alpha.Translatio
|
|
|
524
593
|
readonly "hasSubdomainsCard.emptyMessage": "No subdomain is part of this domain";
|
|
525
594
|
readonly "hasSystemsCard.title": "Has systems";
|
|
526
595
|
readonly "hasSystemsCard.emptyMessage": "No system is part of this domain";
|
|
527
|
-
readonly "relatedEntitiesCard.emptyHelpLinkTitle": "Learn how to change this
|
|
596
|
+
readonly "relatedEntitiesCard.emptyHelpLinkTitle": "Learn how to change this";
|
|
528
597
|
readonly "systemDiagramCard.title": "System Diagram";
|
|
529
598
|
readonly "systemDiagramCard.description": "Use pinch & zoo to move around the diagram.";
|
|
530
599
|
readonly "systemDiagramCard.edgeLabels.dependsOn": "depends on";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CatalogSearchResultListItem.esm.js","sources":["../../../src/components/CatalogSearchResultListItem/CatalogSearchResultListItem.tsx"],"sourcesContent":["/*\n * Copyright 2021 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 React, { ReactNode } from 'react';\nimport Box from '@material-ui/core/Box';\nimport Chip from '@material-ui/core/Chip';\nimport ListItemIcon from '@material-ui/core/ListItemIcon';\nimport ListItemText from '@material-ui/core/ListItemText';\nimport Typography from '@material-ui/core/Typography';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { Link } from '@backstage/core-components';\nimport {\n IndexableDocument,\n ResultHighlight,\n} from '@backstage/plugin-search-common';\nimport { HighlightedSearchResultText } from '@backstage/plugin-search-react';\nimport { catalogTranslationRef } from '../../alpha/translation';\nimport { useTranslationRef } from '@backstage/frontend-plugin-api';\n\nconst useStyles = makeStyles(\n {\n item: {\n display: 'flex',\n },\n flexContainer: {\n flexWrap: 'wrap',\n },\n itemText: {\n width: '100%',\n wordBreak: 'break-all',\n marginBottom: '1rem',\n },\n },\n { name: 'CatalogSearchResultListItem' },\n);\n\n/**\n * Props for {@link CatalogSearchResultListItem}.\n *\n * @public\n */\nexport interface CatalogSearchResultListItemProps {\n icon?: ReactNode | ((result: IndexableDocument) => ReactNode);\n result?: IndexableDocument;\n highlight?: ResultHighlight;\n rank?: number;\n lineClamp?: number;\n}\n\n/** @public */\nexport function CatalogSearchResultListItem(\n props: CatalogSearchResultListItemProps,\n) {\n const result = props.result as any;\n const highlight = props.highlight as ResultHighlight;\n\n const classes = useStyles();\n const { t } = useTranslationRef(catalogTranslationRef);\n\n if (!result) return null;\n\n return (\n <div className={classes.item}>\n {props.icon && (\n <ListItemIcon>\n {typeof props.icon === 'function' ? props.icon(result) : props.icon}\n </ListItemIcon>\n )}\n <div className={classes.flexContainer}>\n <ListItemText\n className={classes.itemText}\n primaryTypographyProps={{ variant: 'h6' }}\n primary={\n <Link noTrack to={result.location}>\n {highlight?.fields.title ? (\n <HighlightedSearchResultText\n text={highlight.fields.title}\n preTag={highlight.preTag}\n postTag={highlight.postTag}\n />\n ) : (\n result.title\n )}\n </Link>\n }\n secondary={\n <Typography\n component=\"span\"\n style={{\n display: '-webkit-box',\n WebkitBoxOrient: 'vertical',\n WebkitLineClamp: props.lineClamp,\n overflow: 'hidden',\n }}\n color=\"textSecondary\"\n variant=\"body2\"\n >\n {highlight?.fields.text ? (\n <HighlightedSearchResultText\n text={highlight.fields.text}\n preTag={highlight.preTag}\n postTag={highlight.postTag}\n />\n ) : (\n result.text\n )}\n </Typography>\n }\n />\n <Box>\n {result.kind && <Chip label={`Kind: ${result.kind}`} size=\"small\" />}\n {result.type && <Chip label={`Type: ${result.type}`} size=\"small\" />}\n {result.lifecycle && (\n <Chip\n label={`${t('searchResultItem.lifecycle')}: ${result.lifecycle}`}\n size=\"small\"\n />\n )}\n {result.owner && (\n <Chip\n label={`${t('searchResultItem.Owner')}: ${result.owner}`}\n size=\"small\"\n />\n )}\n </Box>\n </div>\n </div>\n );\n}\n"],"names":[],"mappings":";;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"CatalogSearchResultListItem.esm.js","sources":["../../../src/components/CatalogSearchResultListItem/CatalogSearchResultListItem.tsx"],"sourcesContent":["/*\n * Copyright 2021 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 React, { ReactNode } from 'react';\nimport Box from '@material-ui/core/Box';\nimport Chip from '@material-ui/core/Chip';\nimport ListItemIcon from '@material-ui/core/ListItemIcon';\nimport ListItemText from '@material-ui/core/ListItemText';\nimport Typography from '@material-ui/core/Typography';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { Link } from '@backstage/core-components';\nimport {\n IndexableDocument,\n ResultHighlight,\n} from '@backstage/plugin-search-common';\nimport { HighlightedSearchResultText } from '@backstage/plugin-search-react';\nimport { catalogTranslationRef } from '../../alpha/translation';\nimport { useTranslationRef } from '@backstage/frontend-plugin-api';\n\n/** @public */\nexport type CatalogSearchResultListItemClassKey =\n | 'item'\n | 'flexContainer'\n | 'itemText';\n\nconst useStyles = makeStyles(\n {\n item: {\n display: 'flex',\n },\n flexContainer: {\n flexWrap: 'wrap',\n },\n itemText: {\n width: '100%',\n wordBreak: 'break-all',\n marginBottom: '1rem',\n },\n },\n { name: 'CatalogSearchResultListItem' },\n);\n\n/**\n * Props for {@link CatalogSearchResultListItem}.\n *\n * @public\n */\nexport interface CatalogSearchResultListItemProps {\n icon?: ReactNode | ((result: IndexableDocument) => ReactNode);\n result?: IndexableDocument;\n highlight?: ResultHighlight;\n rank?: number;\n lineClamp?: number;\n}\n\n/** @public */\nexport function CatalogSearchResultListItem(\n props: CatalogSearchResultListItemProps,\n) {\n const result = props.result as any;\n const highlight = props.highlight as ResultHighlight;\n\n const classes = useStyles();\n const { t } = useTranslationRef(catalogTranslationRef);\n\n if (!result) return null;\n\n return (\n <div className={classes.item}>\n {props.icon && (\n <ListItemIcon>\n {typeof props.icon === 'function' ? props.icon(result) : props.icon}\n </ListItemIcon>\n )}\n <div className={classes.flexContainer}>\n <ListItemText\n className={classes.itemText}\n primaryTypographyProps={{ variant: 'h6' }}\n primary={\n <Link noTrack to={result.location}>\n {highlight?.fields.title ? (\n <HighlightedSearchResultText\n text={highlight.fields.title}\n preTag={highlight.preTag}\n postTag={highlight.postTag}\n />\n ) : (\n result.title\n )}\n </Link>\n }\n secondary={\n <Typography\n component=\"span\"\n style={{\n display: '-webkit-box',\n WebkitBoxOrient: 'vertical',\n WebkitLineClamp: props.lineClamp,\n overflow: 'hidden',\n }}\n color=\"textSecondary\"\n variant=\"body2\"\n >\n {highlight?.fields.text ? (\n <HighlightedSearchResultText\n text={highlight.fields.text}\n preTag={highlight.preTag}\n postTag={highlight.postTag}\n />\n ) : (\n result.text\n )}\n </Typography>\n }\n />\n <Box>\n {result.kind && <Chip label={`Kind: ${result.kind}`} size=\"small\" />}\n {result.type && <Chip label={`Type: ${result.type}`} size=\"small\" />}\n {result.lifecycle && (\n <Chip\n label={`${t('searchResultItem.lifecycle')}: ${result.lifecycle}`}\n size=\"small\"\n />\n )}\n {result.owner && (\n <Chip\n label={`${t('searchResultItem.Owner')}: ${result.owner}`}\n size=\"small\"\n />\n )}\n </Box>\n </div>\n </div>\n );\n}\n"],"names":[],"mappings":";;;;;;;;;;;;AAsCA,MAAM,SAAY,GAAA,UAAA;AAAA,EAChB;AAAA,IACE,IAAM,EAAA;AAAA,MACJ,OAAS,EAAA,MAAA;AAAA,KACX;AAAA,IACA,aAAe,EAAA;AAAA,MACb,QAAU,EAAA,MAAA;AAAA,KACZ;AAAA,IACA,QAAU,EAAA;AAAA,MACR,KAAO,EAAA,MAAA;AAAA,MACP,SAAW,EAAA,WAAA;AAAA,MACX,YAAc,EAAA,MAAA;AAAA,KAChB;AAAA,GACF;AAAA,EACA,EAAE,MAAM,6BAA8B,EAAA;AACxC,CAAA,CAAA;AAgBO,SAAS,4BACd,KACA,EAAA;AACA,EAAA,MAAM,SAAS,KAAM,CAAA,MAAA,CAAA;AACrB,EAAA,MAAM,YAAY,KAAM,CAAA,SAAA,CAAA;AAExB,EAAA,MAAM,UAAU,SAAU,EAAA,CAAA;AAC1B,EAAA,MAAM,EAAE,CAAA,EAAM,GAAA,iBAAA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}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CatalogTableToolbar.esm.js","sources":["../../../src/components/CatalogTable/CatalogTableToolbar.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 React from 'react';\nimport { EntitySearchBar } from '@backstage/plugin-catalog-react';\nimport Toolbar from '@material-ui/core/Toolbar';\nimport Typography from '@material-ui/core/Typography';\nimport { makeStyles } from '@material-ui/core/styles';\n\nconst useToolbarStyles = makeStyles(\n theme => ({\n root: {\n paddingTop: theme.spacing(1.25),\n paddingLeft: theme.spacing(2.5),\n paddingBottom: theme.spacing(0.75),\n display: 'flex',\n justifyContent: 'space-between',\n },\n text: {\n whiteSpace: 'nowrap',\n overflow: 'hidden',\n textOverflow: 'ellipsis',\n },\n }),\n { name: '
|
|
1
|
+
{"version":3,"file":"CatalogTableToolbar.esm.js","sources":["../../../src/components/CatalogTable/CatalogTableToolbar.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 React from 'react';\nimport { EntitySearchBar } from '@backstage/plugin-catalog-react';\nimport Toolbar from '@material-ui/core/Toolbar';\nimport Typography from '@material-ui/core/Typography';\nimport { makeStyles } from '@material-ui/core/styles';\n\n/** @public */\nexport type CatalogTableToolbarClassKey = 'root' | 'text';\n\nconst useToolbarStyles = makeStyles(\n theme => ({\n root: {\n paddingTop: theme.spacing(1.25),\n paddingLeft: theme.spacing(2.5),\n paddingBottom: theme.spacing(0.75),\n display: 'flex',\n justifyContent: 'space-between',\n },\n text: {\n whiteSpace: 'nowrap',\n overflow: 'hidden',\n textOverflow: 'ellipsis',\n },\n }),\n { name: 'PluginCatalogTableToolbar' },\n);\n\nexport function CatalogTableToolbar(props: {\n title?: string | React.ReactElement<any>;\n}) {\n const styles = useToolbarStyles();\n return (\n <Toolbar className={styles.root}>\n <Typography variant=\"h5\" className={styles.text}>\n {props.title}\n </Typography>\n <EntitySearchBar />\n </Toolbar>\n );\n}\n"],"names":[],"mappings":";;;;;;AAwBA,MAAM,gBAAmB,GAAA,UAAA;AAAA,EACvB,CAAU,KAAA,MAAA;AAAA,IACR,IAAM,EAAA;AAAA,MACJ,UAAA,EAAY,KAAM,CAAA,OAAA,CAAQ,IAAI,CAAA;AAAA,MAC9B,WAAA,EAAa,KAAM,CAAA,OAAA,CAAQ,GAAG,CAAA;AAAA,MAC9B,aAAA,EAAe,KAAM,CAAA,OAAA,CAAQ,IAAI,CAAA;AAAA,MACjC,OAAS,EAAA,MAAA;AAAA,MACT,cAAgB,EAAA,eAAA;AAAA,KAClB;AAAA,IACA,IAAM,EAAA;AAAA,MACJ,UAAY,EAAA,QAAA;AAAA,MACZ,QAAU,EAAA,QAAA;AAAA,MACV,YAAc,EAAA,UAAA;AAAA,KAChB;AAAA,GACF,CAAA;AAAA,EACA,EAAE,MAAM,2BAA4B,EAAA;AACtC,CAAA,CAAA;AAEO,SAAS,oBAAoB,KAEjC,EAAA;AACD,EAAA,MAAM,SAAS,gBAAiB,EAAA,CAAA;AAChC,EAAA,2CACG,OAAQ,EAAA,EAAA,SAAA,EAAW,MAAO,CAAA,IAAA,EAAA,sCACxB,UAAW,EAAA,EAAA,OAAA,EAAQ,IAAK,EAAA,SAAA,EAAW,OAAO,IACxC,EAAA,EAAA,KAAA,CAAM,KACT,CACA,kBAAA,KAAA,CAAA,aAAA,CAAC,qBAAgB,CACnB,CAAA,CAAA;AAEJ;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CursorPaginatedCatalogTable.esm.js","sources":["../../../src/components/CatalogTable/CursorPaginatedCatalogTable.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 React from 'react';\n\nimport { Table, TableProps } from '@backstage/core-components';\nimport { CatalogTableRow } from './types';\nimport { CatalogTableToolbar } from './CatalogTableToolbar';\n\ntype PaginatedCatalogTableProps = {\n prev?(): void;\n next?(): void;\n} & TableProps<CatalogTableRow>;\n\n/**\n * @internal\n */\n\nexport function CursorPaginatedCatalogTable(props: PaginatedCatalogTableProps) {\n const { columns, data, next, prev, title, isLoading, options, ...restProps } =\n props;\n\n return (\n <Table\n title={isLoading ? '' : title}\n columns={columns}\n data={data}\n options={{\n ...options,\n // These settings are configured to force server side pagination\n paginationPosition: 'both',\n pageSizeOptions: [],\n showFirstLastPageButtons: false,\n pageSize: Number.MAX_SAFE_INTEGER,\n emptyRowsWhenPaging: false,\n }}\n onPageChange={page => {\n if (page > 0) {\n next?.();\n } else {\n prev?.();\n }\n }}\n components={{\n Toolbar: CatalogTableToolbar,\n }}\n /* this will enable the prev button accordingly */\n page={prev ? 1 : 0}\n /* this will enable the next button accordingly */\n totalCount={next ? Number.MAX_VALUE : Number.MAX_SAFE_INTEGER}\n localization={{ pagination: { labelDisplayedRows: '' } }}\n {...restProps}\n />\n );\n}\n"],"names":[],"mappings":";;;;AA+BO,SAAS,4BAA4B,KAAmC,EAAA;AAC7E,EAAM,MAAA,EAAE,OAAS,EAAA,IAAA,EAAM,IAAM,EAAA,IAAA,EAAM,OAAO,SAAW,EAAA,OAAA,EAAS,GAAG,SAAA,EAC/D,GAAA,KAAA,CAAA;AAEF,EACE,uBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,KAAA,EAAO,YAAY,EAAK,GAAA,KAAA;AAAA,MACxB,OAAA;AAAA,MACA,IAAA;AAAA,MACA,OAAS,EAAA;AAAA,QACP,GAAG,OAAA;AAAA;AAAA,QAEH,kBAAoB,EAAA,MAAA;AAAA,QACpB,iBAAiB,EAAC;AAAA,QAClB,wBAA0B,EAAA,KAAA;AAAA,QAC1B,UAAU,MAAO,CAAA,gBAAA;AAAA,QACjB,mBAAqB,EAAA,KAAA;AAAA,OACvB;AAAA,MACA,cAAc,CAAQ,IAAA,KAAA;AACpB,QAAA,IAAI,OAAO,CAAG,EAAA;AACZ,UAAO,IAAA,IAAA,CAAA;AAAA,SACF,MAAA;AACL,UAAO,IAAA,IAAA,CAAA;AAAA,SACT;AAAA,OACF;AAAA,MACA,UAAY,EAAA;AAAA,QACV,OAAS,EAAA,mBAAA;AAAA,OACX;AAAA,MAEA,IAAA,EAAM,OAAO,CAAI,GAAA,CAAA;AAAA,MAEjB,UAAY,EAAA,IAAA,GAAO,MAAO,CAAA,SAAA,GAAY,MAAO,CAAA,gBAAA;AAAA,MAC7C,cAAc,EAAE,UAAA,EAAY,EAAE,kBAAA,EAAoB,IAAK,EAAA;AAAA,
|
|
1
|
+
{"version":3,"file":"CursorPaginatedCatalogTable.esm.js","sources":["../../../src/components/CatalogTable/CursorPaginatedCatalogTable.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 React from 'react';\n\nimport { Table, TableProps } from '@backstage/core-components';\nimport { CatalogTableRow } from './types';\nimport { CatalogTableToolbar } from './CatalogTableToolbar';\n\ntype PaginatedCatalogTableProps = {\n prev?(): void;\n next?(): void;\n} & TableProps<CatalogTableRow>;\n\n/**\n * @internal\n */\n\nexport function CursorPaginatedCatalogTable(props: PaginatedCatalogTableProps) {\n const { columns, data, next, prev, title, isLoading, options, ...restProps } =\n props;\n\n return (\n <Table\n title={isLoading ? '' : title}\n columns={columns}\n data={data}\n options={{\n ...options,\n // These settings are configured to force server side pagination\n paginationPosition: 'both',\n pageSizeOptions: [],\n showFirstLastPageButtons: false,\n pageSize: Number.MAX_SAFE_INTEGER,\n emptyRowsWhenPaging: false,\n }}\n onPageChange={page => {\n if (page > 0) {\n next?.();\n } else {\n prev?.();\n }\n }}\n components={{\n Toolbar: CatalogTableToolbar,\n }}\n /* this will enable the prev button accordingly */\n page={prev ? 1 : 0}\n /* this will enable the next button accordingly */\n totalCount={next ? Number.MAX_VALUE : Number.MAX_SAFE_INTEGER}\n localization={{ pagination: { labelDisplayedRows: '' } }}\n isLoading={isLoading}\n {...restProps}\n />\n );\n}\n"],"names":[],"mappings":";;;;AA+BO,SAAS,4BAA4B,KAAmC,EAAA;AAC7E,EAAM,MAAA,EAAE,OAAS,EAAA,IAAA,EAAM,IAAM,EAAA,IAAA,EAAM,OAAO,SAAW,EAAA,OAAA,EAAS,GAAG,SAAA,EAC/D,GAAA,KAAA,CAAA;AAEF,EACE,uBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,KAAA,EAAO,YAAY,EAAK,GAAA,KAAA;AAAA,MACxB,OAAA;AAAA,MACA,IAAA;AAAA,MACA,OAAS,EAAA;AAAA,QACP,GAAG,OAAA;AAAA;AAAA,QAEH,kBAAoB,EAAA,MAAA;AAAA,QACpB,iBAAiB,EAAC;AAAA,QAClB,wBAA0B,EAAA,KAAA;AAAA,QAC1B,UAAU,MAAO,CAAA,gBAAA;AAAA,QACjB,mBAAqB,EAAA,KAAA;AAAA,OACvB;AAAA,MACA,cAAc,CAAQ,IAAA,KAAA;AACpB,QAAA,IAAI,OAAO,CAAG,EAAA;AACZ,UAAO,IAAA,IAAA,CAAA;AAAA,SACF,MAAA;AACL,UAAO,IAAA,IAAA,CAAA;AAAA,SACT;AAAA,OACF;AAAA,MACA,UAAY,EAAA;AAAA,QACV,OAAS,EAAA,mBAAA;AAAA,OACX;AAAA,MAEA,IAAA,EAAM,OAAO,CAAI,GAAA,CAAA;AAAA,MAEjB,UAAY,EAAA,IAAA,GAAO,MAAO,CAAA,SAAA,GAAY,MAAO,CAAA,gBAAA;AAAA,MAC7C,cAAc,EAAE,UAAA,EAAY,EAAE,kBAAA,EAAoB,IAAK,EAAA;AAAA,MACvD,SAAA;AAAA,MACC,GAAG,SAAA;AAAA,KAAA;AAAA,GACN,CAAA;AAEJ;;;;"}
|
|
@@ -3,7 +3,7 @@ import { Table } from '@backstage/core-components';
|
|
|
3
3
|
import { useEntityList, EntityTextFilter } from '@backstage/plugin-catalog-react';
|
|
4
4
|
|
|
5
5
|
function OffsetPaginatedCatalogTable(props) {
|
|
6
|
-
const { columns, data } = props;
|
|
6
|
+
const { columns, data, isLoading } = props;
|
|
7
7
|
const { updateFilters, setLimit, setOffset, limit, totalItems, offset } = useEntityList();
|
|
8
8
|
const [page, setPage] = React.useState(
|
|
9
9
|
offset && limit ? Math.floor(offset / limit) : 0
|
|
@@ -37,7 +37,8 @@ function OffsetPaginatedCatalogTable(props) {
|
|
|
37
37
|
setLimit(pageSize);
|
|
38
38
|
},
|
|
39
39
|
totalCount: totalItems,
|
|
40
|
-
localization: { pagination: { labelDisplayedRows: "" } }
|
|
40
|
+
localization: { pagination: { labelDisplayedRows: "" } },
|
|
41
|
+
isLoading
|
|
41
42
|
}
|
|
42
43
|
);
|
|
43
44
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OffsetPaginatedCatalogTable.esm.js","sources":["../../../src/components/CatalogTable/OffsetPaginatedCatalogTable.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 React, { useEffect } from 'react';\n\nimport { Table, TableProps } from '@backstage/core-components';\nimport { CatalogTableRow } from './types';\nimport {\n EntityTextFilter,\n useEntityList,\n} from '@backstage/plugin-catalog-react';\n\n/**\n * @internal\n */\nexport function OffsetPaginatedCatalogTable(\n props: TableProps<CatalogTableRow>,\n) {\n const { columns, data } = props;\n const { updateFilters, setLimit, setOffset, limit, totalItems, offset } =\n useEntityList();\n const [page, setPage] = React.useState(\n offset && limit ? Math.floor(offset / limit) : 0,\n );\n\n useEffect(() => {\n if (totalItems && page * limit >= totalItems) {\n setOffset!(Math.max(0, totalItems - limit));\n } else {\n setOffset!(Math.max(0, page * limit));\n }\n }, [setOffset, page, limit, totalItems]);\n\n return (\n <Table\n columns={columns}\n data={data}\n options={{\n paginationPosition: 'both',\n pageSizeOptions: [5, 10, 20, 50, 100],\n pageSize: limit,\n emptyRowsWhenPaging: false,\n }}\n onSearchChange={(searchText: string) =>\n updateFilters({\n text: searchText ? new EntityTextFilter(searchText) : undefined,\n })\n }\n page={page}\n onPageChange={newPage => {\n setPage(newPage);\n }}\n onRowsPerPageChange={pageSize => {\n setLimit(pageSize);\n }}\n totalCount={totalItems}\n localization={{ pagination: { labelDisplayedRows: '' } }}\n />\n );\n}\n"],"names":[],"mappings":";;;;AA4BO,SAAS,4BACd,KACA,EAAA;AACA,
|
|
1
|
+
{"version":3,"file":"OffsetPaginatedCatalogTable.esm.js","sources":["../../../src/components/CatalogTable/OffsetPaginatedCatalogTable.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 React, { useEffect } from 'react';\n\nimport { Table, TableProps } from '@backstage/core-components';\nimport { CatalogTableRow } from './types';\nimport {\n EntityTextFilter,\n useEntityList,\n} from '@backstage/plugin-catalog-react';\n\n/**\n * @internal\n */\nexport function OffsetPaginatedCatalogTable(\n props: TableProps<CatalogTableRow>,\n) {\n const { columns, data, isLoading } = props;\n const { updateFilters, setLimit, setOffset, limit, totalItems, offset } =\n useEntityList();\n const [page, setPage] = React.useState(\n offset && limit ? Math.floor(offset / limit) : 0,\n );\n\n useEffect(() => {\n if (totalItems && page * limit >= totalItems) {\n setOffset!(Math.max(0, totalItems - limit));\n } else {\n setOffset!(Math.max(0, page * limit));\n }\n }, [setOffset, page, limit, totalItems]);\n\n return (\n <Table\n columns={columns}\n data={data}\n options={{\n paginationPosition: 'both',\n pageSizeOptions: [5, 10, 20, 50, 100],\n pageSize: limit,\n emptyRowsWhenPaging: false,\n }}\n onSearchChange={(searchText: string) =>\n updateFilters({\n text: searchText ? new EntityTextFilter(searchText) : undefined,\n })\n }\n page={page}\n onPageChange={newPage => {\n setPage(newPage);\n }}\n onRowsPerPageChange={pageSize => {\n setLimit(pageSize);\n }}\n totalCount={totalItems}\n localization={{ pagination: { labelDisplayedRows: '' } }}\n isLoading={isLoading}\n />\n );\n}\n"],"names":[],"mappings":";;;;AA4BO,SAAS,4BACd,KACA,EAAA;AACA,EAAA,MAAM,EAAE,OAAA,EAAS,IAAM,EAAA,SAAA,EAAc,GAAA,KAAA,CAAA;AACrC,EAAM,MAAA,EAAE,eAAe,QAAU,EAAA,SAAA,EAAW,OAAO,UAAY,EAAA,MAAA,KAC7D,aAAc,EAAA,CAAA;AAChB,EAAA,MAAM,CAAC,IAAA,EAAM,OAAO,CAAA,GAAI,KAAM,CAAA,QAAA;AAAA,IAC5B,UAAU,KAAQ,GAAA,IAAA,CAAK,KAAM,CAAA,MAAA,GAAS,KAAK,CAAI,GAAA,CAAA;AAAA,GACjD,CAAA;AAEA,EAAA,SAAA,CAAU,MAAM;AACd,IAAI,IAAA,UAAA,IAAc,IAAO,GAAA,KAAA,IAAS,UAAY,EAAA;AAC5C,MAAA,SAAA,CAAW,IAAK,CAAA,GAAA,CAAI,CAAG,EAAA,UAAA,GAAa,KAAK,CAAC,CAAA,CAAA;AAAA,KACrC,MAAA;AACL,MAAA,SAAA,CAAW,IAAK,CAAA,GAAA,CAAI,CAAG,EAAA,IAAA,GAAO,KAAK,CAAC,CAAA,CAAA;AAAA,KACtC;AAAA,KACC,CAAC,SAAA,EAAW,IAAM,EAAA,KAAA,EAAO,UAAU,CAAC,CAAA,CAAA;AAEvC,EACE,uBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,OAAA;AAAA,MACA,IAAA;AAAA,MACA,OAAS,EAAA;AAAA,QACP,kBAAoB,EAAA,MAAA;AAAA,QACpB,iBAAiB,CAAC,CAAA,EAAG,EAAI,EAAA,EAAA,EAAI,IAAI,GAAG,CAAA;AAAA,QACpC,QAAU,EAAA,KAAA;AAAA,QACV,mBAAqB,EAAA,KAAA;AAAA,OACvB;AAAA,MACA,cAAA,EAAgB,CAAC,UAAA,KACf,aAAc,CAAA;AAAA,QACZ,IAAM,EAAA,UAAA,GAAa,IAAI,gBAAA,CAAiB,UAAU,CAAI,GAAA,KAAA,CAAA;AAAA,OACvD,CAAA;AAAA,MAEH,IAAA;AAAA,MACA,cAAc,CAAW,OAAA,KAAA;AACvB,QAAA,OAAA,CAAQ,OAAO,CAAA,CAAA;AAAA,OACjB;AAAA,MACA,qBAAqB,CAAY,QAAA,KAAA;AAC/B,QAAA,QAAA,CAAS,QAAQ,CAAA,CAAA;AAAA,OACnB;AAAA,MACA,UAAY,EAAA,UAAA;AAAA,MACZ,cAAc,EAAE,UAAA,EAAY,EAAE,kBAAA,EAAoB,IAAK,EAAA;AAAA,MACvD,SAAA;AAAA,KAAA;AAAA,GACF,CAAA;AAEJ;;;;"}
|
|
@@ -8,11 +8,13 @@ const defaultCatalogTableColumnsFunc = ({
|
|
|
8
8
|
return [
|
|
9
9
|
columnFactories.createTitleColumn({ hidden: true }),
|
|
10
10
|
columnFactories.createNameColumn({ defaultKind: filters.kind?.value }),
|
|
11
|
-
...createEntitySpecificColumns()
|
|
12
|
-
columnFactories.createMetadataDescriptionColumn(),
|
|
13
|
-
columnFactories.createTagsColumn()
|
|
11
|
+
...createEntitySpecificColumns()
|
|
14
12
|
];
|
|
15
13
|
function createEntitySpecificColumns() {
|
|
14
|
+
const descriptionTagColumns = [
|
|
15
|
+
columnFactories.createMetadataDescriptionColumn(),
|
|
16
|
+
columnFactories.createTagsColumn()
|
|
17
|
+
];
|
|
16
18
|
const baseColumns = [
|
|
17
19
|
columnFactories.createSystemColumn(),
|
|
18
20
|
columnFactories.createOwnerColumn(),
|
|
@@ -21,14 +23,15 @@ const defaultCatalogTableColumnsFunc = ({
|
|
|
21
23
|
];
|
|
22
24
|
switch (filters.kind?.value) {
|
|
23
25
|
case "user":
|
|
24
|
-
return [];
|
|
26
|
+
return [...descriptionTagColumns];
|
|
25
27
|
case "domain":
|
|
26
28
|
case "system":
|
|
27
|
-
return [columnFactories.createOwnerColumn()];
|
|
29
|
+
return [columnFactories.createOwnerColumn(), ...descriptionTagColumns];
|
|
28
30
|
case "group":
|
|
29
31
|
case "template":
|
|
30
32
|
return [
|
|
31
|
-
columnFactories.createSpecTypeColumn({ hidden: !showTypeColumn })
|
|
33
|
+
columnFactories.createSpecTypeColumn({ hidden: !showTypeColumn }),
|
|
34
|
+
...descriptionTagColumns
|
|
32
35
|
];
|
|
33
36
|
case "location":
|
|
34
37
|
return [
|
|
@@ -36,7 +39,11 @@ const defaultCatalogTableColumnsFunc = ({
|
|
|
36
39
|
columnFactories.createSpecTargetsColumn()
|
|
37
40
|
];
|
|
38
41
|
default:
|
|
39
|
-
return entities.every((entity) => entity.metadata.namespace === "default") ?
|
|
42
|
+
return entities.every((entity) => entity.metadata.namespace === "default") ? [...baseColumns, ...descriptionTagColumns] : [
|
|
43
|
+
...baseColumns,
|
|
44
|
+
columnFactories.createNamespaceColumn(),
|
|
45
|
+
...descriptionTagColumns
|
|
46
|
+
];
|
|
40
47
|
}
|
|
41
48
|
}
|
|
42
49
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"defaultCatalogTableColumnsFunc.esm.js","sources":["../../../src/components/CatalogTable/defaultCatalogTableColumnsFunc.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 { TableColumn } from '@backstage/core-components';\nimport { columnFactories } from './columns';\nimport { CatalogTableColumnsFunc, CatalogTableRow } from './types';\n\n// The defaultCatalogTableColumnsFunc symbol is not directly exported, but through the\n// CatalogTable.defaultColumnsFunc field.\n/** @public */\nexport const defaultCatalogTableColumnsFunc: CatalogTableColumnsFunc = ({\n filters,\n entities,\n}) => {\n const showTypeColumn = filters.type === undefined;\n\n return [\n columnFactories.createTitleColumn({ hidden: true }),\n columnFactories.createNameColumn({ defaultKind: filters.kind?.value }),\n ...createEntitySpecificColumns(),\n
|
|
1
|
+
{"version":3,"file":"defaultCatalogTableColumnsFunc.esm.js","sources":["../../../src/components/CatalogTable/defaultCatalogTableColumnsFunc.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 { TableColumn } from '@backstage/core-components';\nimport { columnFactories } from './columns';\nimport { CatalogTableColumnsFunc, CatalogTableRow } from './types';\n\n// The defaultCatalogTableColumnsFunc symbol is not directly exported, but through the\n// CatalogTable.defaultColumnsFunc field.\n/** @public */\nexport const defaultCatalogTableColumnsFunc: CatalogTableColumnsFunc = ({\n filters,\n entities,\n}) => {\n const showTypeColumn = filters.type === undefined;\n\n return [\n columnFactories.createTitleColumn({ hidden: true }),\n columnFactories.createNameColumn({ defaultKind: filters.kind?.value }),\n ...createEntitySpecificColumns(),\n ];\n\n function createEntitySpecificColumns(): TableColumn<CatalogTableRow>[] {\n const descriptionTagColumns = [\n columnFactories.createMetadataDescriptionColumn(),\n columnFactories.createTagsColumn(),\n ];\n const baseColumns = [\n columnFactories.createSystemColumn(),\n columnFactories.createOwnerColumn(),\n columnFactories.createSpecTypeColumn({ hidden: !showTypeColumn }),\n columnFactories.createSpecLifecycleColumn(),\n ];\n switch (filters.kind?.value) {\n case 'user':\n return [...descriptionTagColumns];\n case 'domain':\n case 'system':\n return [columnFactories.createOwnerColumn(), ...descriptionTagColumns];\n case 'group':\n case 'template':\n return [\n columnFactories.createSpecTypeColumn({ hidden: !showTypeColumn }),\n ...descriptionTagColumns,\n ];\n case 'location':\n return [\n columnFactories.createSpecTypeColumn({ hidden: !showTypeColumn }),\n columnFactories.createSpecTargetsColumn(),\n ];\n default:\n return entities.every(entity => entity.metadata.namespace === 'default')\n ? [...baseColumns, ...descriptionTagColumns]\n : [\n ...baseColumns,\n columnFactories.createNamespaceColumn(),\n ...descriptionTagColumns,\n ];\n }\n }\n};\n"],"names":[],"mappings":";;AAuBO,MAAM,iCAA0D,CAAC;AAAA,EACtE,OAAA;AAAA,EACA,QAAA;AACF,CAAM,KAAA;AACJ,EAAM,MAAA,cAAA,GAAiB,QAAQ,IAAS,KAAA,KAAA,CAAA,CAAA;AAExC,EAAO,OAAA;AAAA,IACL,eAAgB,CAAA,iBAAA,CAAkB,EAAE,MAAA,EAAQ,MAAM,CAAA;AAAA,IAClD,gBAAgB,gBAAiB,CAAA,EAAE,aAAa,OAAQ,CAAA,IAAA,EAAM,OAAO,CAAA;AAAA,IACrE,GAAG,2BAA4B,EAAA;AAAA,GACjC,CAAA;AAEA,EAAA,SAAS,2BAA8D,GAAA;AACrE,IAAA,MAAM,qBAAwB,GAAA;AAAA,MAC5B,gBAAgB,+BAAgC,EAAA;AAAA,MAChD,gBAAgB,gBAAiB,EAAA;AAAA,KACnC,CAAA;AACA,IAAA,MAAM,WAAc,GAAA;AAAA,MAClB,gBAAgB,kBAAmB,EAAA;AAAA,MACnC,gBAAgB,iBAAkB,EAAA;AAAA,MAClC,gBAAgB,oBAAqB,CAAA,EAAE,MAAQ,EAAA,CAAC,gBAAgB,CAAA;AAAA,MAChE,gBAAgB,yBAA0B,EAAA;AAAA,KAC5C,CAAA;AACA,IAAQ,QAAA,OAAA,CAAQ,MAAM,KAAO;AAAA,MAC3B,KAAK,MAAA;AACH,QAAO,OAAA,CAAC,GAAG,qBAAqB,CAAA,CAAA;AAAA,MAClC,KAAK,QAAA,CAAA;AAAA,MACL,KAAK,QAAA;AACH,QAAA,OAAO,CAAC,eAAA,CAAgB,iBAAkB,EAAA,EAAG,GAAG,qBAAqB,CAAA,CAAA;AAAA,MACvE,KAAK,OAAA,CAAA;AAAA,MACL,KAAK,UAAA;AACH,QAAO,OAAA;AAAA,UACL,gBAAgB,oBAAqB,CAAA,EAAE,MAAQ,EAAA,CAAC,gBAAgB,CAAA;AAAA,UAChE,GAAG,qBAAA;AAAA,SACL,CAAA;AAAA,MACF,KAAK,UAAA;AACH,QAAO,OAAA;AAAA,UACL,gBAAgB,oBAAqB,CAAA,EAAE,MAAQ,EAAA,CAAC,gBAAgB,CAAA;AAAA,UAChE,gBAAgB,uBAAwB,EAAA;AAAA,SAC1C,CAAA;AAAA,MACF;AACE,QAAA,OAAO,QAAS,CAAA,KAAA,CAAM,CAAU,MAAA,KAAA,MAAA,CAAO,QAAS,CAAA,SAAA,KAAc,SAAS,CAAA,GACnE,CAAC,GAAG,WAAa,EAAA,GAAG,qBAAqB,CACzC,GAAA;AAAA,UACE,GAAG,WAAA;AAAA,UACH,gBAAgB,qBAAsB,EAAA;AAAA,UACtC,GAAG,qBAAA;AAAA,SACL,CAAA;AAAA,KACR;AAAA,GACF;AACF;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EntityLabelsEmptyState.esm.js","sources":["../../../src/components/EntityLabelsCard/EntityLabelsEmptyState.tsx"],"sourcesContent":["/*\n * Copyright 2020 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 Button from '@material-ui/core/Button';\nimport Typography from '@material-ui/core/Typography';\nimport { makeStyles } from '@material-ui/core/styles';\nimport React from 'react';\nimport { CodeSnippet } from '@backstage/core-components';\nimport { catalogTranslationRef } from '../../alpha/translation';\nimport { useTranslationRef } from '@backstage/core-plugin-api/alpha';\n\nconst ENTITY_YAML = `metadata:\n name: example\n labels:\n javaVersion: 1.2.3`;\n\nconst useStyles = makeStyles(\n theme => ({\n code: {\n borderRadius: 6,\n margin: theme.spacing(2, 0),\n background:\n theme.palette.type === 'dark' ? '#444' : theme.palette.common.white,\n },\n }),\n { name: 'PluginCatalogEntityLabelsEmptyState' },\n);\n\nexport function EntityLabelsEmptyState() {\n const classes = useStyles();\n const { t } = useTranslationRef(catalogTranslationRef);\n\n return (\n <>\n <Typography variant=\"body1\">\n {t('entityLabelsCard.emptyDescription')}\n </Typography>\n <div className={classes.code}>\n <CodeSnippet\n text={ENTITY_YAML}\n language=\"yaml\"\n showLineNumbers\n highlightedNumbers={[3, 4, 5, 6]}\n customStyle={{ background: 'inherit', fontSize: '115%' }}\n />\n </div>\n <Button\n variant=\"contained\"\n color=\"primary\"\n target=\"_blank\"\n href=\"https://backstage.io/docs/features/software-catalog/descriptor-format#labels-optional\"\n >\n {t('entityLabelsCard.readMoreButtonTitle')}\n </Button>\n </>\n );\n}\n"],"names":[],"mappings":";;;;;;;;AAwBA,MAAM,WAAc,GAAA,CAAA;AAAA;AAAA;AAAA,sBAAA,CAAA,CAAA;
|
|
1
|
+
{"version":3,"file":"EntityLabelsEmptyState.esm.js","sources":["../../../src/components/EntityLabelsCard/EntityLabelsEmptyState.tsx"],"sourcesContent":["/*\n * Copyright 2020 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 Button from '@material-ui/core/Button';\nimport Typography from '@material-ui/core/Typography';\nimport { makeStyles } from '@material-ui/core/styles';\nimport React from 'react';\nimport { CodeSnippet } from '@backstage/core-components';\nimport { catalogTranslationRef } from '../../alpha/translation';\nimport { useTranslationRef } from '@backstage/core-plugin-api/alpha';\n\nconst ENTITY_YAML = `metadata:\n name: example\n labels:\n javaVersion: 1.2.3`;\n\n/** @public */\nexport type EntityLabelsEmptyStateClassKey = 'code';\n\nconst useStyles = makeStyles(\n theme => ({\n code: {\n borderRadius: 6,\n margin: theme.spacing(2, 0),\n background:\n theme.palette.type === 'dark' ? '#444' : theme.palette.common.white,\n },\n }),\n { name: 'PluginCatalogEntityLabelsEmptyState' },\n);\n\nexport function EntityLabelsEmptyState() {\n const classes = useStyles();\n const { t } = useTranslationRef(catalogTranslationRef);\n\n return (\n <>\n <Typography variant=\"body1\">\n {t('entityLabelsCard.emptyDescription')}\n </Typography>\n <div className={classes.code}>\n <CodeSnippet\n text={ENTITY_YAML}\n language=\"yaml\"\n showLineNumbers\n highlightedNumbers={[3, 4, 5, 6]}\n customStyle={{ background: 'inherit', fontSize: '115%' }}\n />\n </div>\n <Button\n variant=\"contained\"\n color=\"primary\"\n target=\"_blank\"\n href=\"https://backstage.io/docs/features/software-catalog/descriptor-format#labels-optional\"\n >\n {t('entityLabelsCard.readMoreButtonTitle')}\n </Button>\n </>\n );\n}\n"],"names":[],"mappings":";;;;;;;;AAwBA,MAAM,WAAc,GAAA,CAAA;AAAA;AAAA;AAAA,sBAAA,CAAA,CAAA;AAQpB,MAAM,SAAY,GAAA,UAAA;AAAA,EAChB,CAAU,KAAA,MAAA;AAAA,IACR,IAAM,EAAA;AAAA,MACJ,YAAc,EAAA,CAAA;AAAA,MACd,MAAQ,EAAA,KAAA,CAAM,OAAQ,CAAA,CAAA,EAAG,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esCard = (props) => {
|
|
|
35
35
|
{
|
|
36
36
|
title,
|
|
37
37
|
variant,
|
|
38
|
-
emptyContent: /* @__PURE__ */ React.createElement("div", { style: { textAlign: "center" } }, /* @__PURE__ */ React.createElement(Typography, { variant: "body1" }, emptyMessage), /* @__PURE__ */ React.createElement(Typography, { variant: "body2" }, /* @__PURE__ */ React.createElement(Link, { to: emptyHelpLink }, t("relatedEntitiesCard.emptyHelpLinkTitle")))),
|
|
38
|
+
emptyContent: /* @__PURE__ */ React.createElement("div", { style: { textAlign: "center" } }, /* @__PURE__ */ React.createElement(Typography, { variant: "body1" }, emptyMessage), /* @__PURE__ */ React.createElement(Typography, { variant: "body2" }, /* @__PURE__ */ React.createElement(Link, { to: emptyHelpLink, externalLinkIcon: true }, t("relatedEntitiesCard.emptyHelpLinkTitle")))),
|
|
39
39
|
columns,
|
|
40
40
|
entities: asRenderableEntities(entities || []),
|
|
41
41
|
tableOptions
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RelatedEntitiesCard.esm.js","sources":["../../../src/components/RelatedEntitiesCard/RelatedEntitiesCard.tsx"],"sourcesContent":["/*\n * Copyright 2020 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 { Entity } from '@backstage/catalog-model';\nimport Typography from '@material-ui/core/Typography';\nimport {\n EntityTable,\n useEntity,\n useRelatedEntities,\n} from '@backstage/plugin-catalog-react';\nimport React from 'react';\nimport {\n InfoCard,\n InfoCardVariants,\n Link,\n Progress,\n ResponseErrorPanel,\n TableColumn,\n TableOptions,\n} from '@backstage/core-components';\nimport {\n asComponentEntities,\n asResourceEntities,\n asSystemEntities,\n componentEntityColumns,\n componentEntityHelpLink,\n resourceEntityColumns,\n resourceEntityHelpLink,\n systemEntityColumns,\n systemEntityHelpLink,\n} from './presets';\nimport { catalogTranslationRef } from '../../alpha/translation';\nimport { useTranslationRef } from '@backstage/core-plugin-api/alpha';\n\n/** @public */\nexport type RelatedEntitiesCardProps<T extends Entity> = {\n variant?: InfoCardVariants;\n title: string;\n columns: TableColumn<T>[];\n entityKind?: string;\n relationType: string;\n emptyMessage: string;\n emptyHelpLink: string;\n asRenderableEntities: (entities: Entity[]) => T[];\n tableOptions?: TableOptions;\n};\n\n/**\n * A low level card component that can be used as a building block for more\n * specific cards.\n *\n * @remarks\n *\n * You probably want to make a dedicated component for your needs, which renders\n * this card as its implementation with some of the props set to the appropriate\n * values.\n *\n * @public\n */\nexport const RelatedEntitiesCard = <T extends Entity>(\n props: RelatedEntitiesCardProps<T>,\n) => {\n const {\n variant = 'gridItem',\n title,\n columns,\n entityKind,\n relationType,\n emptyMessage,\n emptyHelpLink,\n asRenderableEntities,\n tableOptions = {},\n } = props;\n
|
|
1
|
+
{"version":3,"file":"RelatedEntitiesCard.esm.js","sources":["../../../src/components/RelatedEntitiesCard/RelatedEntitiesCard.tsx"],"sourcesContent":["/*\n * Copyright 2020 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 { Entity } from '@backstage/catalog-model';\nimport Typography from '@material-ui/core/Typography';\nimport {\n EntityTable,\n useEntity,\n useRelatedEntities,\n} from '@backstage/plugin-catalog-react';\nimport React from 'react';\nimport {\n InfoCard,\n InfoCardVariants,\n Link,\n Progress,\n ResponseErrorPanel,\n TableColumn,\n TableOptions,\n} from '@backstage/core-components';\nimport {\n asComponentEntities,\n asResourceEntities,\n asSystemEntities,\n componentEntityColumns,\n componentEntityHelpLink,\n resourceEntityColumns,\n resourceEntityHelpLink,\n systemEntityColumns,\n systemEntityHelpLink,\n} from './presets';\nimport { catalogTranslationRef } from '../../alpha/translation';\nimport { useTranslationRef } from '@backstage/core-plugin-api/alpha';\n\n/** @public */\nexport type RelatedEntitiesCardProps<T extends Entity> = {\n variant?: InfoCardVariants;\n title: string;\n columns: TableColumn<T>[];\n entityKind?: string;\n relationType: string;\n emptyMessage: string;\n emptyHelpLink: string;\n asRenderableEntities: (entities: Entity[]) => T[];\n tableOptions?: TableOptions;\n};\n\n/**\n * A low level card component that can be used as a building block for more\n * specific cards.\n *\n * @remarks\n *\n * You probably want to make a dedicated component for your needs, which renders\n * this card as its implementation with some of the props set to the appropriate\n * values.\n *\n * @public\n */\nexport const RelatedEntitiesCard = <T extends Entity>(\n props: RelatedEntitiesCardProps<T>,\n) => {\n const {\n variant = 'gridItem',\n title,\n columns,\n entityKind,\n relationType,\n emptyMessage,\n emptyHelpLink,\n asRenderableEntities,\n tableOptions = {},\n } = props;\n const { t } = useTranslationRef(catalogTranslationRef);\n const { entity } = useEntity();\n const { entities, loading, error } = useRelatedEntities(entity, {\n type: relationType,\n kind: entityKind,\n });\n\n if (loading) {\n return (\n <InfoCard variant={variant} title={title}>\n <Progress />\n </InfoCard>\n );\n }\n\n if (error) {\n return (\n <InfoCard variant={variant} title={title}>\n <ResponseErrorPanel error={error} />\n </InfoCard>\n );\n }\n\n return (\n <EntityTable\n title={title}\n variant={variant}\n emptyContent={\n <div style={{ textAlign: 'center' }}>\n <Typography variant=\"body1\">{emptyMessage}</Typography>\n <Typography variant=\"body2\">\n <Link to={emptyHelpLink} externalLinkIcon>\n {t('relatedEntitiesCard.emptyHelpLinkTitle')}\n </Link>\n </Typography>\n </div>\n }\n columns={columns}\n entities={asRenderableEntities(entities || [])}\n tableOptions={tableOptions}\n />\n );\n};\n\nRelatedEntitiesCard.componentEntityColumns = componentEntityColumns;\nRelatedEntitiesCard.componentEntityHelpLink = componentEntityHelpLink;\nRelatedEntitiesCard.asComponentEntities = asComponentEntities;\nRelatedEntitiesCard.resourceEntityColumns = resourceEntityColumns;\nRelatedEntitiesCard.resourceEntityHelpLink = resourceEntityHelpLink;\nRelatedEntitiesCard.asResourceEntities = asResourceEntities;\nRelatedEntitiesCard.systemEntityColumns = systemEntityColumns;\nRelatedEntitiesCard.systemEntityHelpLink = systemEntityHelpLink;\nRelatedEntitiesCard.asSystemEntities = asSystemEntities;\n"],"names":[],"mappings":";;;;;;;;AAwEa,MAAA,mBAAA,GAAsB,CACjC,KACG,KAAA;AACH,EAAM,MAAA;AAAA,IACJ,OAAU,GAAA,UAAA;AAAA,IACV,KAAA;AAAA,IACA,OAAA;AAAA,IACA,UAAA;AAAA,IACA,YAAA;AAAA,IACA,YAAA;AAAA,IACA,aAAA;AAAA,IACA,oBAAA;AAAA,IACA,eAAe,EAAC;AAAA,GACd,GAAA,KAAA,CAAA;AACJ,EAAA,MAAM,EAAE,CAAA,EAAM,GAAA,iBAAA,CAAkB,qBAAqB,CAAA,CAAA;AACrD,EAAM,MAAA,EAAE,MAAO,EAAA,GAAI,SAAU,EAAA,CAAA;AAC7B,EAAA,MAAM,EAAE,QAAU,EAAA,OAAA,EAAS,KAAM,EAAA,GAAI,mBAAmB,MAAQ,EAAA;AAAA,IAC9D,IAAM,EAAA,YAAA;AAAA,IACN,IAAM,EAAA,UAAA;AAAA,GACP,CAAA,CAAA;AAED,EAAA,IAAI,OAAS,EAAA;AACX,IAAA,2CACG,QAAS,EAAA,EAAA,OAAA,EAAkB,KAC1B,EAAA,kBAAA,KAAA,CAAA,aAAA,CAAC,cAAS,CACZ,CAAA,CAAA;AAAA,GAEJ;AAEA,EAAA,IAAI,KAAO,EAAA;AACT,IAAA,2CACG,QAAS,EAAA,EAAA,OAAA,EAAkB,yBACz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8 +10,8 @@ import React__default, { ReactNode } from 'react';
|
|
|
10
10
|
import { TabProps } from '@material-ui/core/Tab';
|
|
11
11
|
import { Overrides } from '@material-ui/core/styles/overrides';
|
|
12
12
|
import { StyleRules } from '@material-ui/core/styles/withStyles';
|
|
13
|
-
import { SearchResultListItemExtensionProps } from '@backstage/plugin-search-react';
|
|
14
13
|
import { IndexableDocument, ResultHighlight } from '@backstage/plugin-search-common';
|
|
14
|
+
import { SearchResultListItemExtensionProps } from '@backstage/plugin-search-react';
|
|
15
15
|
|
|
16
16
|
/**
|
|
17
17
|
* A custom renderer for the {@link DefaultEntityPresentationApi}.
|
|
@@ -271,6 +271,9 @@ declare const CatalogTable: {
|
|
|
271
271
|
defaultColumnsFunc: CatalogTableColumnsFunc;
|
|
272
272
|
};
|
|
273
273
|
|
|
274
|
+
/** @public */
|
|
275
|
+
type CatalogTableToolbarClassKey = 'root' | 'text';
|
|
276
|
+
|
|
274
277
|
/** @public */
|
|
275
278
|
type EntityLayoutRouteProps = {
|
|
276
279
|
path: string;
|
|
@@ -470,18 +473,18 @@ type SystemDiagramCardClassKey = 'domainNode' | 'systemNode' | 'componentNode' |
|
|
|
470
473
|
type EntityContextMenuClassKey = 'button';
|
|
471
474
|
|
|
472
475
|
/** @public */
|
|
473
|
-
type
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
476
|
+
type CatalogSearchResultListItemClassKey = 'item' | 'flexContainer' | 'itemText';
|
|
477
|
+
/**
|
|
478
|
+
* Props for {@link CatalogSearchResultListItem}.
|
|
479
|
+
*
|
|
480
|
+
* @public
|
|
481
|
+
*/
|
|
482
|
+
interface CatalogSearchResultListItemProps {
|
|
483
|
+
icon?: ReactNode | ((result: IndexableDocument) => ReactNode);
|
|
484
|
+
result?: IndexableDocument;
|
|
485
|
+
highlight?: ResultHighlight;
|
|
486
|
+
rank?: number;
|
|
487
|
+
lineClamp?: number;
|
|
485
488
|
}
|
|
486
489
|
|
|
487
490
|
/** @public */
|
|
@@ -498,6 +501,27 @@ interface EntityLabelsCardProps {
|
|
|
498
501
|
*/
|
|
499
502
|
declare function hasLabels(entity: Entity): boolean;
|
|
500
503
|
|
|
504
|
+
/** @public */
|
|
505
|
+
type EntityLabelsEmptyStateClassKey = 'code';
|
|
506
|
+
|
|
507
|
+
/** @public */
|
|
508
|
+
type PluginCatalogComponentsNameToClassKey = {
|
|
509
|
+
PluginCatalogEntityLinksEmptyState: EntityLinksEmptyStateClassKey;
|
|
510
|
+
PluginCatalogSystemDiagramCard: SystemDiagramCardClassKey;
|
|
511
|
+
PluginCatalogEntityContextMenu: EntityContextMenuClassKey;
|
|
512
|
+
PluginCatalogSearchResultListItem: CatalogSearchResultListItemClassKey;
|
|
513
|
+
PluginCatalogTableToolbar: CatalogTableToolbarClassKey;
|
|
514
|
+
PluginCatalogEntityLabelsEmptyState: EntityLabelsEmptyStateClassKey;
|
|
515
|
+
};
|
|
516
|
+
/** @public */
|
|
517
|
+
type BackstageOverrides = Overrides & {
|
|
518
|
+
[Name in keyof PluginCatalogComponentsNameToClassKey]?: Partial<StyleRules<PluginCatalogComponentsNameToClassKey[Name]>>;
|
|
519
|
+
};
|
|
520
|
+
declare module '@backstage/theme' {
|
|
521
|
+
interface OverrideComponentNameToClassKeys extends PluginCatalogComponentsNameToClassKey {
|
|
522
|
+
}
|
|
523
|
+
}
|
|
524
|
+
|
|
501
525
|
/**
|
|
502
526
|
* Props for root catalog pages.
|
|
503
527
|
*
|
|
@@ -592,19 +616,6 @@ type RelatedEntitiesCardProps<T extends Entity> = {
|
|
|
592
616
|
tableOptions?: TableOptions;
|
|
593
617
|
};
|
|
594
618
|
|
|
595
|
-
/**
|
|
596
|
-
* Props for {@link CatalogSearchResultListItem}.
|
|
597
|
-
*
|
|
598
|
-
* @public
|
|
599
|
-
*/
|
|
600
|
-
interface CatalogSearchResultListItemProps {
|
|
601
|
-
icon?: ReactNode | ((result: IndexableDocument) => ReactNode);
|
|
602
|
-
result?: IndexableDocument;
|
|
603
|
-
highlight?: ResultHighlight;
|
|
604
|
-
rank?: number;
|
|
605
|
-
lineClamp?: number;
|
|
606
|
-
}
|
|
607
|
-
|
|
608
619
|
/** @public */
|
|
609
620
|
declare const catalogPlugin: _backstage_core_plugin_api.BackstagePlugin<{
|
|
610
621
|
catalogIndex: _backstage_core_plugin_api.RouteRef<undefined>;
|
|
@@ -668,4 +679,4 @@ declare const RelatedEntitiesCard: <T extends Entity>(props: RelatedEntitiesCard
|
|
|
668
679
|
/** @public */
|
|
669
680
|
declare const CatalogSearchResultListItem: (props: SearchResultListItemExtensionProps<CatalogSearchResultListItemProps>) => JSX.Element | null;
|
|
670
681
|
|
|
671
|
-
export { type AboutCardProps, AboutContent, type AboutContentProps, AboutField, type AboutFieldProps, type BackstageOverrides, type Breakpoint, CatalogEntityPage, CatalogIndexPage, CatalogKindHeader, type CatalogKindHeaderProps, CatalogSearchResultListItem, type CatalogSearchResultListItemProps, CatalogTable, type CatalogTableColumnsFunc, type CatalogTableProps, type CatalogTableRow, type ColumnBreakpoints, type DefaultCatalogPageProps, DefaultEntityPresentationApi, type DefaultEntityPresentationApiOptions, type DefaultEntityPresentationApiRenderer, DefaultStarredEntitiesApi, type DependencyOfComponentsCardProps, type DependsOnComponentsCardProps, type DependsOnResourcesCardProps, EntityAboutCard, type EntityContextMenuClassKey, EntityDependencyOfComponentsCard, EntityDependsOnComponentsCard, EntityDependsOnResourcesCard, EntityHasComponentsCard, EntityHasResourcesCard, EntityHasSubcomponentsCard, EntityHasSubdomainsCard, EntityHasSystemsCard, EntityLabelsCard, type EntityLabelsCardProps, EntityLayout, type EntityLayoutProps, type EntityLayoutRouteProps, EntityLinksCard, type EntityLinksCardProps, type EntityLinksEmptyStateClassKey, EntityListContainer, EntityOrphanWarning, type EntityPredicates, EntityProcessingErrorsPanel, EntityRelationWarning, EntitySwitch, type EntitySwitchCaseProps, type EntitySwitchProps, FilterContainer, FilteredEntityLayout, type HasComponentsCardProps, type HasResourcesCardProps, type HasSubcomponentsCardProps, type HasSubdomainsCardProps, type HasSystemsCardProps, type PluginCatalogComponentsNameToClassKey, RelatedEntitiesCard, type RelatedEntitiesCardProps, type SystemDiagramCardClassKey, catalogPlugin, hasCatalogProcessingErrors, hasLabels, hasRelationWarnings, isApiType, isComponentType, isEntityWith, isKind, isNamespace, isOrphan, isResourceType };
|
|
682
|
+
export { type AboutCardProps, AboutContent, type AboutContentProps, AboutField, type AboutFieldProps, type BackstageOverrides, type Breakpoint, CatalogEntityPage, CatalogIndexPage, CatalogKindHeader, type CatalogKindHeaderProps, CatalogSearchResultListItem, type CatalogSearchResultListItemClassKey, type CatalogSearchResultListItemProps, CatalogTable, type CatalogTableColumnsFunc, type CatalogTableProps, type CatalogTableRow, type CatalogTableToolbarClassKey, type ColumnBreakpoints, type DefaultCatalogPageProps, DefaultEntityPresentationApi, type DefaultEntityPresentationApiOptions, type DefaultEntityPresentationApiRenderer, DefaultStarredEntitiesApi, type DependencyOfComponentsCardProps, type DependsOnComponentsCardProps, type DependsOnResourcesCardProps, EntityAboutCard, type EntityContextMenuClassKey, EntityDependencyOfComponentsCard, EntityDependsOnComponentsCard, EntityDependsOnResourcesCard, EntityHasComponentsCard, EntityHasResourcesCard, EntityHasSubcomponentsCard, EntityHasSubdomainsCard, EntityHasSystemsCard, EntityLabelsCard, type EntityLabelsCardProps, type EntityLabelsEmptyStateClassKey, EntityLayout, type EntityLayoutProps, type EntityLayoutRouteProps, EntityLinksCard, type EntityLinksCardProps, type EntityLinksEmptyStateClassKey, EntityListContainer, EntityOrphanWarning, type EntityPredicates, EntityProcessingErrorsPanel, EntityRelationWarning, EntitySwitch, type EntitySwitchCaseProps, type EntitySwitchProps, FilterContainer, FilteredEntityLayout, type HasComponentsCardProps, type HasResourcesCardProps, type HasSubcomponentsCardProps, type HasSubdomainsCardProps, type HasSystemsCardProps, type PluginCatalogComponentsNameToClassKey, RelatedEntitiesCard, type RelatedEntitiesCardProps, type SystemDiagramCardClassKey, catalogPlugin, hasCatalogProcessingErrors, hasLabels, hasRelationWarnings, isApiType, isComponentType, isEntityWith, isKind, isNamespace, isOrphan, isResourceType };
|
package/dist/index.esm.js
CHANGED
|
@@ -14,5 +14,6 @@ export { isApiType, isComponentType, isEntityWith, isKind, isNamespace, isResour
|
|
|
14
14
|
export { EntityListContainer, FilterContainer, FilteredEntityLayout } from './components/FilteredEntityLayout/index.esm.js';
|
|
15
15
|
import './components/EntityLabelsCard/EntityLabelsCard.esm.js';
|
|
16
16
|
export { hasLabels } from './components/EntityLabelsCard/conditions.esm.js';
|
|
17
|
+
import './components/CatalogSearchResultListItem/CatalogSearchResultListItem.esm.js';
|
|
17
18
|
export { CatalogEntityPage, CatalogIndexPage, CatalogSearchResultListItem, EntityAboutCard, EntityDependencyOfComponentsCard, EntityDependsOnComponentsCard, EntityDependsOnResourcesCard, EntityHasComponentsCard, EntityHasResourcesCard, EntityHasSubcomponentsCard, EntityHasSubdomainsCard, EntityHasSystemsCard, EntityLabelsCard, EntityLinksCard, RelatedEntitiesCard, catalogPlugin } from './plugin.esm.js';
|
|
18
19
|
//# sourceMappingURL=index.esm.js.map
|
package/dist/index.esm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.esm.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.esm.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@backstage/plugin-catalog",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.24.0-next.0",
|
|
4
4
|
"description": "The Backstage plugin for browsing the Backstage catalog",
|
|
5
5
|
"backstage": {
|
|
6
6
|
"role": "frontend-plugin",
|
|
@@ -34,6 +34,7 @@
|
|
|
34
34
|
"default": "./dist/index.esm.js"
|
|
35
35
|
},
|
|
36
36
|
"./alpha": {
|
|
37
|
+
"backstage": "@backstage/FrontendPlugin",
|
|
37
38
|
"import": "./dist/alpha.esm.js",
|
|
38
39
|
"types": "./dist/alpha.d.ts",
|
|
39
40
|
"default": "./dist/alpha.esm.js"
|
|
@@ -57,20 +58,20 @@
|
|
|
57
58
|
"test": "backstage-cli package test"
|
|
58
59
|
},
|
|
59
60
|
"dependencies": {
|
|
60
|
-
"@backstage/catalog-client": "^1.7.0
|
|
61
|
-
"@backstage/catalog-model": "^1.
|
|
62
|
-
"@backstage/core-compat-api": "^0.3.
|
|
63
|
-
"@backstage/core-components": "^0.
|
|
64
|
-
"@backstage/core-plugin-api": "^1.
|
|
61
|
+
"@backstage/catalog-client": "^1.7.0",
|
|
62
|
+
"@backstage/catalog-model": "^1.7.0",
|
|
63
|
+
"@backstage/core-compat-api": "^0.3.1-next.0",
|
|
64
|
+
"@backstage/core-components": "^0.15.1-next.0",
|
|
65
|
+
"@backstage/core-plugin-api": "^1.10.0-next.0",
|
|
65
66
|
"@backstage/errors": "^1.2.4",
|
|
66
|
-
"@backstage/frontend-plugin-api": "^0.
|
|
67
|
-
"@backstage/integration-react": "^1.1.
|
|
68
|
-
"@backstage/plugin-catalog-common": "^1.0
|
|
69
|
-
"@backstage/plugin-catalog-react": "^1.13.
|
|
70
|
-
"@backstage/plugin-permission-react": "^0.4.
|
|
71
|
-
"@backstage/plugin-scaffolder-common": "^1.5.
|
|
67
|
+
"@backstage/frontend-plugin-api": "^0.9.0-next.0",
|
|
68
|
+
"@backstage/integration-react": "^1.1.32-next.0",
|
|
69
|
+
"@backstage/plugin-catalog-common": "^1.1.0",
|
|
70
|
+
"@backstage/plugin-catalog-react": "^1.13.1-next.0",
|
|
71
|
+
"@backstage/plugin-permission-react": "^0.4.27-next.0",
|
|
72
|
+
"@backstage/plugin-scaffolder-common": "^1.5.6",
|
|
72
73
|
"@backstage/plugin-search-common": "^1.2.14",
|
|
73
|
-
"@backstage/plugin-search-react": "^1.8.
|
|
74
|
+
"@backstage/plugin-search-react": "^1.8.1-next.0",
|
|
74
75
|
"@backstage/types": "^1.1.1",
|
|
75
76
|
"@material-ui/core": "^4.12.2",
|
|
76
77
|
"@material-ui/icons": "^4.9.1",
|
|
@@ -86,12 +87,12 @@
|
|
|
86
87
|
"zen-observable": "^0.10.0"
|
|
87
88
|
},
|
|
88
89
|
"devDependencies": {
|
|
89
|
-
"@backstage/cli": "^0.
|
|
90
|
-
"@backstage/core-app-api": "^1.
|
|
91
|
-
"@backstage/dev-utils": "^1.1.
|
|
92
|
-
"@backstage/frontend-test-utils": "^0.2.
|
|
90
|
+
"@backstage/cli": "^0.28.0-next.0",
|
|
91
|
+
"@backstage/core-app-api": "^1.15.1-next.0",
|
|
92
|
+
"@backstage/dev-utils": "^1.1.1-next.0",
|
|
93
|
+
"@backstage/frontend-test-utils": "^0.2.1-next.0",
|
|
93
94
|
"@backstage/plugin-permission-common": "^0.8.1",
|
|
94
|
-
"@backstage/test-utils": "^1.6.
|
|
95
|
+
"@backstage/test-utils": "^1.6.1-next.0",
|
|
95
96
|
"@testing-library/dom": "^10.0.0",
|
|
96
97
|
"@testing-library/jest-dom": "^6.0.0",
|
|
97
98
|
"@testing-library/react": "^16.0.0",
|