@backstage/plugin-catalog 0.7.12 → 0.8.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.
Files changed (49) hide show
  1. package/CHANGELOG.md +35 -0
  2. package/dist/esm/{index-f38c05cb.esm.js → index-14286170.esm.js} +5 -4
  3. package/dist/esm/index-14286170.esm.js.map +1 -0
  4. package/dist/esm/{index-5f548c06.esm.js → index-172990ed.esm.js} +2 -2
  5. package/dist/esm/index-172990ed.esm.js.map +1 -0
  6. package/dist/esm/{index-76b6bb58.esm.js → index-2a9d68c3.esm.js} +5 -7
  7. package/dist/esm/index-2a9d68c3.esm.js.map +1 -0
  8. package/dist/esm/index-3467aa13.esm.js +12 -0
  9. package/dist/esm/{index-7b0e3438.esm.js.map → index-3467aa13.esm.js.map} +1 -1
  10. package/dist/esm/{index-bb9f1736.esm.js → index-36e4660a.esm.js} +2 -4
  11. package/dist/esm/index-36e4660a.esm.js.map +1 -0
  12. package/dist/esm/{index-ce51b527.esm.js → index-52271589.esm.js} +12 -13
  13. package/dist/esm/index-52271589.esm.js.map +1 -0
  14. package/dist/esm/{index-1d9c4228.esm.js → index-583e6f94.esm.js} +5 -4
  15. package/dist/esm/index-583e6f94.esm.js.map +1 -0
  16. package/dist/esm/index-5c367aca.esm.js +55 -0
  17. package/dist/esm/index-5c367aca.esm.js.map +1 -0
  18. package/dist/esm/{index-dd3d0aa1.esm.js → index-69fcf315.esm.js} +5 -4
  19. package/dist/esm/index-69fcf315.esm.js.map +1 -0
  20. package/dist/esm/{index-acc2d5cf.esm.js → index-bb5ef8ab.esm.js} +5 -4
  21. package/dist/esm/{index-acc2d5cf.esm.js.map → index-bb5ef8ab.esm.js.map} +1 -1
  22. package/dist/esm/{index-e48f93af.esm.js → index-be138931.esm.js} +5 -7
  23. package/dist/esm/index-be138931.esm.js.map +1 -0
  24. package/dist/esm/{index-da7631a3.esm.js → index-de01f9dd.esm.js} +200 -547
  25. package/dist/esm/index-de01f9dd.esm.js.map +1 -0
  26. package/dist/esm/{index-ae83ecd3.esm.js → index-df3c8250.esm.js} +5 -4
  27. package/dist/esm/index-df3c8250.esm.js.map +1 -0
  28. package/dist/esm/{presets-711f07f8.esm.js → presets-8488ee8e.esm.js} +3 -3
  29. package/dist/esm/{presets-711f07f8.esm.js.map → presets-8488ee8e.esm.js.map} +1 -1
  30. package/dist/index.d.ts +247 -198
  31. package/dist/index.esm.js +1 -3
  32. package/dist/index.esm.js.map +1 -1
  33. package/package.json +28 -24
  34. package/dist/components/EntityNotFound/Illo/illo.svg +0 -1
  35. package/dist/esm/index-1d9c4228.esm.js.map +0 -1
  36. package/dist/esm/index-5f548c06.esm.js.map +0 -1
  37. package/dist/esm/index-76b6bb58.esm.js.map +0 -1
  38. package/dist/esm/index-7b0e3438.esm.js +0 -10
  39. package/dist/esm/index-943d86e0.esm.js +0 -27
  40. package/dist/esm/index-943d86e0.esm.js.map +0 -1
  41. package/dist/esm/index-ae83ecd3.esm.js.map +0 -1
  42. package/dist/esm/index-bb9f1736.esm.js.map +0 -1
  43. package/dist/esm/index-ce51b527.esm.js.map +0 -1
  44. package/dist/esm/index-d363820f.esm.js +0 -182
  45. package/dist/esm/index-d363820f.esm.js.map +0 -1
  46. package/dist/esm/index-da7631a3.esm.js.map +0 -1
  47. package/dist/esm/index-dd3d0aa1.esm.js.map +0 -1
  48. package/dist/esm/index-e48f93af.esm.js.map +0 -1
  49. package/dist/esm/index-f38c05cb.esm.js.map +0 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,40 @@
1
1
  # @backstage/plugin-catalog
2
2
 
3
+ ## 0.8.0
4
+
5
+ ### Minor Changes
6
+
7
+ - ae7edbea45: Removed `CatalogClientWrapper` as usage have been replaced by the `fetchApiRef`.
8
+ - 37092662cb: **BREAKING** Completely removed the `EntitySystemDiagramCard` component which was deprecated in a previous release. Any remaining references to this component are now broken and should be replaced with `EntityCatalogGraphCard`, which can be imported from package `@backstage/plugin-catalog-graph`.
9
+ - 7657eeae22: Removed deprecated `Router` and `EntityPageLayout` exports.
10
+ `Router` is replaced by plugin extensions and `EntityPageLayout` is replaced by `CatalogEntityPage`.
11
+ - 0a033351be: **BREAKING**:
12
+
13
+ - The `CatalogResultListItem` `result` prop is now of the more narrow and correct type `IndexableDocument`, rather than `any`.
14
+ - The individual table column factories (e.g. `createNameColumn`) are now no longer available directly, but only through `CatalogTable.columns`.
15
+
16
+ ### Patch Changes
17
+
18
+ - 1ed305728b: Bump `node-fetch` to version 2.6.7 and `cross-fetch` to version 3.1.5
19
+ - c77c5c7eb6: Added `backstage.role` to `package.json`
20
+ - 538ca90790: Use updated type names from `@backstage/catalog-client`
21
+ - 0d03e42a89: Replaced use of deprecated `compareEntityToRef` utility.
22
+ - 244d24ebc4: Import `Location` from the `@backstage/catalog-client` package.
23
+ - deaf6065db: Adapt to the new `CatalogApi.getLocationByRef`
24
+ - 27eccab216: Replaces use of deprecated catalog-model constants.
25
+ - 7aeb491394: Replace use of deprecated `ENTITY_DEFAULT_NAMESPACE` constant with `DEFAULT_NAMESPACE`.
26
+ - Updated dependencies
27
+ - @backstage/catalog-client@0.7.0
28
+ - @backstage/core-components@0.8.9
29
+ - @backstage/core-plugin-api@0.6.1
30
+ - @backstage/errors@0.2.1
31
+ - @backstage/integration-react@0.1.22
32
+ - @backstage/plugin-catalog-react@0.6.15
33
+ - @backstage/catalog-model@0.10.0
34
+ - @backstage/search-common@0.2.3
35
+ - @backstage/theme@0.2.15
36
+ - @backstage/plugin-catalog-common@0.1.3
37
+
3
38
  ## 0.7.12
4
39
 
5
40
  ### Patch Changes
@@ -1,11 +1,12 @@
1
1
  import { RELATION_HAS_PART } from '@backstage/catalog-model';
2
2
  import React from 'react';
3
- import { R as RelatedEntitiesCard, c as componentEntityColumns, d as componentEntityHelpLink, e as asComponentEntities } from './presets-711f07f8.esm.js';
3
+ import { R as RelatedEntitiesCard, c as componentEntityColumns, d as componentEntityHelpLink, e as asComponentEntities } from './presets-8488ee8e.esm.js';
4
4
  import '@material-ui/core';
5
5
  import '@backstage/plugin-catalog-react';
6
6
  import '@backstage/core-components';
7
7
 
8
- const HasComponentsCard = ({ variant = "gridItem" }) => {
8
+ function HasComponentsCard(props) {
9
+ const { variant = "gridItem" } = props;
9
10
  return /* @__PURE__ */ React.createElement(RelatedEntitiesCard, {
10
11
  variant,
11
12
  title: "Has components",
@@ -16,7 +17,7 @@ const HasComponentsCard = ({ variant = "gridItem" }) => {
16
17
  emptyHelpLink: componentEntityHelpLink,
17
18
  asRenderableEntities: asComponentEntities
18
19
  });
19
- };
20
+ }
20
21
 
21
22
  export { HasComponentsCard };
22
- //# sourceMappingURL=index-f38c05cb.esm.js.map
23
+ //# sourceMappingURL=index-14286170.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-14286170.esm.js","sources":["../../src/components/HasComponentsCard/HasComponentsCard.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 { RELATION_HAS_PART } from '@backstage/catalog-model';\nimport React from 'react';\nimport {\n asComponentEntities,\n componentEntityColumns,\n componentEntityHelpLink,\n RelatedEntitiesCard,\n} from '../RelatedEntitiesCard';\n\n/** @public */\nexport interface HasComponentsCardProps {\n variant?: 'gridItem';\n}\n\nexport function HasComponentsCard(props: HasComponentsCardProps) {\n const { variant = 'gridItem' } = props;\n return (\n <RelatedEntitiesCard\n variant={variant}\n title=\"Has components\"\n entityKind=\"Component\"\n relationType={RELATION_HAS_PART}\n columns={componentEntityColumns}\n emptyMessage=\"No component is part of this system\"\n emptyHelpLink={componentEntityHelpLink}\n asRenderableEntities={asComponentEntities}\n />\n );\n}\n"],"names":[],"mappings":";;;;;;;2BA8BkC,OAA+B;AAC/D,QAAM,EAAE,UAAU,eAAe;AACjC,6CACG,qBAAD;AAAA,IACE;AAAA,IACA,OAAM;AAAA,IACN,YAAW;AAAA,IACX,cAAc;AAAA,IACd,SAAS;AAAA,IACT,cAAa;AAAA,IACb,eAAe;AAAA,IACf,sBAAsB;AAAA;AAAA;;;;"}
@@ -1,6 +1,6 @@
1
- export { R as RelatedEntitiesCard, e as asComponentEntities, f as asResourceEntities, a as asSystemEntities, c as componentEntityColumns, d as componentEntityHelpLink, r as resourceEntityColumns, g as resourceEntityHelpLink, s as systemEntityColumns, b as systemEntityHelpLink } from './presets-711f07f8.esm.js';
1
+ export { R as RelatedEntitiesCard, e as asComponentEntities, f as asResourceEntities, a as asSystemEntities, c as componentEntityColumns, d as componentEntityHelpLink, r as resourceEntityColumns, g as resourceEntityHelpLink, s as systemEntityColumns, b as systemEntityHelpLink } from './presets-8488ee8e.esm.js';
2
2
  import '@material-ui/core';
3
3
  import '@backstage/plugin-catalog-react';
4
4
  import 'react';
5
5
  import '@backstage/core-components';
6
- //# sourceMappingURL=index-5f548c06.esm.js.map
6
+ //# sourceMappingURL=index-172990ed.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-172990ed.esm.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
@@ -1,14 +1,12 @@
1
1
  import { RELATION_DEPENDENCY_OF } from '@backstage/catalog-model';
2
2
  import React from 'react';
3
- import { R as RelatedEntitiesCard, c as componentEntityColumns, d as componentEntityHelpLink, e as asComponentEntities } from './presets-711f07f8.esm.js';
3
+ import { R as RelatedEntitiesCard, c as componentEntityColumns, d as componentEntityHelpLink, e as asComponentEntities } from './presets-8488ee8e.esm.js';
4
4
  import '@material-ui/core';
5
5
  import '@backstage/plugin-catalog-react';
6
6
  import '@backstage/core-components';
7
7
 
8
- const DependencyOfComponentsCard = ({
9
- variant = "gridItem",
10
- title = "Dependency of components"
11
- }) => {
8
+ function DependencyOfComponentsCard(props) {
9
+ const { variant = "gridItem", title = "Dependency of components" } = props;
12
10
  return /* @__PURE__ */ React.createElement(RelatedEntitiesCard, {
13
11
  variant,
14
12
  title,
@@ -19,7 +17,7 @@ const DependencyOfComponentsCard = ({
19
17
  emptyHelpLink: componentEntityHelpLink,
20
18
  asRenderableEntities: asComponentEntities
21
19
  });
22
- };
20
+ }
23
21
 
24
22
  export { DependencyOfComponentsCard };
25
- //# sourceMappingURL=index-76b6bb58.esm.js.map
23
+ //# sourceMappingURL=index-2a9d68c3.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-2a9d68c3.esm.js","sources":["../../src/components/DependencyOfComponentsCard/DependencyOfComponentsCard.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 { RELATION_DEPENDENCY_OF } from '@backstage/catalog-model';\nimport React from 'react';\nimport {\n asComponentEntities,\n componentEntityColumns,\n componentEntityHelpLink,\n RelatedEntitiesCard,\n} from '../RelatedEntitiesCard';\n\n/** @public */\nexport interface DependencyOfComponentsCardProps {\n variant?: 'gridItem';\n title?: string;\n}\n\nexport function DependencyOfComponentsCard(\n props: DependencyOfComponentsCardProps,\n) {\n const { variant = 'gridItem', title = 'Dependency of components' } = props;\n return (\n <RelatedEntitiesCard\n variant={variant}\n title={title}\n entityKind=\"Component\"\n relationType={RELATION_DEPENDENCY_OF}\n columns={componentEntityColumns}\n emptyMessage=\"No component depends on this component\"\n emptyHelpLink={componentEntityHelpLink}\n asRenderableEntities={asComponentEntities}\n />\n );\n}\n"],"names":[],"mappings":";;;;;;;oCAgCE,OACA;AACA,QAAM,EAAE,UAAU,YAAY,QAAQ,+BAA+B;AACrE,6CACG,qBAAD;AAAA,IACE;AAAA,IACA;AAAA,IACA,YAAW;AAAA,IACX,cAAc;AAAA,IACd,SAAS;AAAA,IACT,cAAa;AAAA,IACb,eAAe;AAAA,IACf,sBAAsB;AAAA;AAAA;;;;"}
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { Outlet } from 'react-router';
3
+ import { AsyncEntityProvider, useEntityFromUrl } from '@backstage/plugin-catalog-react';
4
+
5
+ function CatalogEntityPage() {
6
+ return /* @__PURE__ */ React.createElement(AsyncEntityProvider, {
7
+ ...useEntityFromUrl()
8
+ }, /* @__PURE__ */ React.createElement(Outlet, null));
9
+ }
10
+
11
+ export { CatalogEntityPage };
12
+ //# sourceMappingURL=index-3467aa13.esm.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index-7b0e3438.esm.js","sources":["../../src/components/CatalogEntityPage/CatalogEntityPage.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 React from 'react';\nimport { Outlet } from 'react-router';\nimport {\n useEntityFromUrl,\n AsyncEntityProvider,\n} from '@backstage/plugin-catalog-react';\n\nexport const CatalogEntityPage = () => (\n <AsyncEntityProvider {...useEntityFromUrl()}>\n <Outlet />\n </AsyncEntityProvider>\n);\n"],"names":[],"mappings":";;;;MAuBa,oBAAoB,0CAC9B,qBAAD;AAAA,KAAyB;AAAA,uCACtB,QAAD;;;;"}
1
+ {"version":3,"file":"index-3467aa13.esm.js","sources":["../../src/components/CatalogEntityPage/CatalogEntityPage.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 React from 'react';\nimport { Outlet } from 'react-router';\nimport {\n useEntityFromUrl,\n AsyncEntityProvider,\n} from '@backstage/plugin-catalog-react';\n\n/** @public */\nexport function CatalogEntityPage() {\n return (\n <AsyncEntityProvider {...useEntityFromUrl()}>\n <Outlet />\n </AsyncEntityProvider>\n );\n}\n"],"names":[],"mappings":";;;;6BAwBoC;AAClC,6CACG,qBAAD;AAAA,OAAyB;AAAA,yCACtB,QAAD;AAAA;;;;"}
@@ -1,4 +1,4 @@
1
- export { C as CatalogPage, D as DefaultCatalogPage } from './index-da7631a3.esm.js';
1
+ export { A as AboutCard, d as AboutContent, e as AboutField } from './index-de01f9dd.esm.js';
2
2
  import '@backstage/catalog-model';
3
3
  import '@backstage/core-components';
4
4
  import '@backstage/core-plugin-api';
@@ -21,7 +21,5 @@ import '@backstage/plugin-catalog-common';
21
21
  import '@backstage/errors';
22
22
  import '@backstage/catalog-client';
23
23
  import 'react-use/lib/useAsync';
24
- import 'react-helmet';
25
24
  import '@material-ui/icons/FilterList';
26
- import '../components/EntityNotFound/Illo/illo.svg';
27
- //# sourceMappingURL=index-bb9f1736.esm.js.map
25
+ //# sourceMappingURL=index-36e4660a.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-36e4660a.esm.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;"}
@@ -18,7 +18,7 @@ const useStyles$1 = makeStyles((theme) => ({
18
18
  background: theme.palette.type === "dark" ? "#444" : "#fff"
19
19
  }
20
20
  }), { name: "PluginCatalogEntityLinksEmptyState" });
21
- const EntityLinksEmptyState = () => {
21
+ function EntityLinksEmptyState() {
22
22
  const classes = useStyles$1();
23
23
  return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(Typography, {
24
24
  variant: "body1"
@@ -36,7 +36,7 @@ const EntityLinksEmptyState = () => {
36
36
  target: "_blank",
37
37
  href: "https://backstage.io/docs/features/software-catalog/descriptor-format#links-optional"
38
38
  }, "Read more"));
39
- };
39
+ }
40
40
 
41
41
  const useStyles = makeStyles({
42
42
  svgIcon: {
@@ -48,11 +48,8 @@ const useStyles = makeStyles({
48
48
  }
49
49
  }
50
50
  });
51
- const IconLink = ({
52
- href,
53
- text,
54
- Icon
55
- }) => {
51
+ function IconLink(props) {
52
+ const { href, text, Icon } = props;
56
53
  const classes = useStyles();
57
54
  return /* @__PURE__ */ React.createElement(Box, {
58
55
  display: "flex"
@@ -68,7 +65,7 @@ const IconLink = ({
68
65
  target: "_blank",
69
66
  rel: "noopener"
70
67
  }, text || href)));
71
- };
68
+ }
72
69
 
73
70
  const colDefaults = {
74
71
  xs: 1,
@@ -96,7 +93,8 @@ function useDynamicColumns(cols) {
96
93
  return numOfCols;
97
94
  }
98
95
 
99
- const LinksGridList = ({ items, cols = void 0 }) => {
96
+ function LinksGridList(props) {
97
+ const { items, cols = void 0 } = props;
100
98
  const numOfCols = useDynamicColumns(cols);
101
99
  return /* @__PURE__ */ React.createElement(ImageList, {
102
100
  rowHeight: "auto",
@@ -108,10 +106,11 @@ const LinksGridList = ({ items, cols = void 0 }) => {
108
106
  text: text != null ? text : href,
109
107
  Icon
110
108
  }))));
111
- };
109
+ }
112
110
 
113
- const EntityLinksCard = ({ cols = void 0, variant }) => {
111
+ function EntityLinksCard(props) {
114
112
  var _a;
113
+ const { cols = void 0, variant } = props;
115
114
  const { entity } = useEntity();
116
115
  const app = useApp();
117
116
  const iconResolver = (key) => {
@@ -130,7 +129,7 @@ const EntityLinksCard = ({ cols = void 0, variant }) => {
130
129
  Icon: iconResolver(icon)
131
130
  }))
132
131
  }));
133
- };
132
+ }
134
133
 
135
134
  export { EntityLinksCard };
136
- //# sourceMappingURL=index-ce51b527.esm.js.map
135
+ //# sourceMappingURL=index-52271589.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-52271589.esm.js","sources":["../../src/components/EntityLinksCard/EntityLinksEmptyState.tsx","../../src/components/EntityLinksCard/IconLink.tsx","../../src/components/EntityLinksCard/useDynamicColumns.tsx","../../src/components/EntityLinksCard/LinksGridList.tsx","../../src/components/EntityLinksCard/EntityLinksCard.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 { BackstageTheme } from '@backstage/theme';\nimport { Button, makeStyles, Typography } from '@material-ui/core';\nimport React from 'react';\nimport { CodeSnippet } from '@backstage/core-components';\n\nconst ENTITY_YAML = `metadata:\n name: example\n links:\n - url: https://dashboard.example.com\n title: My Dashboard\n icon: dashboard`;\n\n/** @public */\nexport type EntityLinksEmptyStateClassKey = 'code';\n\nconst useStyles = makeStyles<BackstageTheme>(\n theme => ({\n code: {\n borderRadius: 6,\n margin: `${theme.spacing(2)}px 0px`,\n background: theme.palette.type === 'dark' ? '#444' : '#fff',\n },\n }),\n { name: 'PluginCatalogEntityLinksEmptyState' },\n);\n\nexport function EntityLinksEmptyState() {\n const classes = useStyles();\n\n return (\n <>\n <Typography variant=\"body1\">\n No links defined for this entity. You can add links to your entity YAML\n as shown in the highlighted example below:\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#links-optional\"\n >\n Read more\n </Button>\n </>\n );\n}\n","/*\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 { makeStyles, Box, Typography } from '@material-ui/core';\nimport LanguageIcon from '@material-ui/icons/Language';\nimport React from 'react';\nimport { Link } from '@backstage/core-components';\nimport { IconComponent } from '@backstage/core-plugin-api';\n\nconst useStyles = makeStyles({\n svgIcon: {\n display: 'inline-block',\n '& svg': {\n display: 'inline-block',\n fontSize: 'inherit',\n verticalAlign: 'baseline',\n },\n },\n});\n\nexport function IconLink(props: {\n href: string;\n text?: string;\n Icon?: IconComponent;\n}) {\n const { href, text, Icon } = props;\n const classes = useStyles();\n\n return (\n <Box display=\"flex\">\n <Box mr={1} className={classes.svgIcon}>\n <Typography component=\"div\">\n {Icon ? <Icon /> : <LanguageIcon />}\n </Typography>\n </Box>\n <Box flexGrow=\"1\">\n <Link to={href} target=\"_blank\" rel=\"noopener\">\n {text || href}\n </Link>\n </Box>\n </Box>\n );\n}\n","/*\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 { Theme, useMediaQuery } from '@material-ui/core';\nimport { Breakpoint, ColumnBreakpoints } from './types';\n\nconst colDefaults: ColumnBreakpoints = {\n xs: 1,\n sm: 1,\n md: 1,\n lg: 2,\n xl: 3,\n};\n\nexport function useDynamicColumns(\n cols: ColumnBreakpoints | number | undefined,\n): number {\n const matches: (Breakpoint | null)[] = [\n useMediaQuery((theme: Theme) => theme.breakpoints.up('xl')) ? 'xl' : null,\n useMediaQuery((theme: Theme) => theme.breakpoints.up('lg')) ? 'lg' : null,\n useMediaQuery((theme: Theme) => theme.breakpoints.up('md')) ? 'md' : null,\n useMediaQuery((theme: Theme) => theme.breakpoints.up('sm')) ? 'sm' : null,\n useMediaQuery((theme: Theme) => theme.breakpoints.up('xs')) ? 'xs' : null,\n ];\n\n let numOfCols = 1;\n\n if (typeof cols === 'number') {\n numOfCols = cols;\n } else {\n const breakpoint = matches.find(k => k !== null) ?? 'xs';\n numOfCols = cols?.[breakpoint] ?? colDefaults[breakpoint];\n }\n\n return numOfCols;\n}\n","/*\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 { ImageList, ImageListItem } from '@material-ui/core';\nimport React from 'react';\nimport { IconLink } from './IconLink';\nimport { ColumnBreakpoints } from './types';\nimport { useDynamicColumns } from './useDynamicColumns';\nimport { IconComponent } from '@backstage/core-plugin-api';\n\nexport interface LinksGridListItem {\n href: string;\n text?: string;\n Icon?: IconComponent;\n}\n\ninterface LinksGridListProps {\n items: LinksGridListItem[];\n cols?: ColumnBreakpoints | number;\n}\n\nexport function LinksGridList(props: LinksGridListProps) {\n const { items, cols = undefined } = props;\n const numOfCols = useDynamicColumns(cols);\n\n return (\n <ImageList rowHeight=\"auto\" cols={numOfCols}>\n {items.map(({ text, href, Icon }, i) => (\n <ImageListItem key={i}>\n <IconLink href={href} text={text ?? href} Icon={Icon} />\n </ImageListItem>\n ))}\n </ImageList>\n );\n}\n","/*\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 { useEntity } from '@backstage/plugin-catalog-react';\nimport LanguageIcon from '@material-ui/icons/Language';\nimport React from 'react';\nimport { EntityLinksEmptyState } from './EntityLinksEmptyState';\nimport { LinksGridList } from './LinksGridList';\nimport { ColumnBreakpoints } from './types';\nimport { IconComponent, useApp } from '@backstage/core-plugin-api';\nimport { InfoCard } from '@backstage/core-components';\n\n/** @public */\nexport interface EntityLinksCardProps {\n /** @deprecated The entity is now grabbed from context instead */\n entity?: Entity;\n cols?: ColumnBreakpoints | number;\n variant?: 'gridItem';\n}\n\nexport function EntityLinksCard(props: EntityLinksCardProps) {\n const { cols = undefined, variant } = props;\n const { entity } = useEntity();\n const app = useApp();\n\n const iconResolver = (key?: string): IconComponent =>\n key ? app.getSystemIcon(key) ?? LanguageIcon : LanguageIcon;\n\n const links = entity?.metadata?.links;\n\n return (\n <InfoCard title=\"Links\" variant={variant}>\n {!links || links.length === 0 ? (\n <EntityLinksEmptyState />\n ) : (\n <LinksGridList\n cols={cols}\n items={links.map(({ url, title, icon }) => ({\n text: title ?? url,\n href: url,\n Icon: iconResolver(icon),\n }))}\n />\n )}\n </InfoCard>\n );\n}\n"],"names":["useStyles"],"mappings":"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"}
@@ -1,11 +1,12 @@
1
1
  import { RELATION_DEPENDS_ON } from '@backstage/catalog-model';
2
2
  import React from 'react';
3
- import { R as RelatedEntitiesCard, r as resourceEntityColumns, d as componentEntityHelpLink, f as asResourceEntities } from './presets-711f07f8.esm.js';
3
+ import { R as RelatedEntitiesCard, r as resourceEntityColumns, d as componentEntityHelpLink, f as asResourceEntities } from './presets-8488ee8e.esm.js';
4
4
  import '@material-ui/core';
5
5
  import '@backstage/plugin-catalog-react';
6
6
  import '@backstage/core-components';
7
7
 
8
- const DependsOnResourcesCard = ({ variant = "gridItem" }) => {
8
+ function DependsOnResourcesCard(props) {
9
+ const { variant = "gridItem" } = props;
9
10
  return /* @__PURE__ */ React.createElement(RelatedEntitiesCard, {
10
11
  variant,
11
12
  title: "Depends on resources",
@@ -16,7 +17,7 @@ const DependsOnResourcesCard = ({ variant = "gridItem" }) => {
16
17
  emptyHelpLink: componentEntityHelpLink,
17
18
  asRenderableEntities: asResourceEntities
18
19
  });
19
- };
20
+ }
20
21
 
21
22
  export { DependsOnResourcesCard };
22
- //# sourceMappingURL=index-1d9c4228.esm.js.map
23
+ //# sourceMappingURL=index-583e6f94.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-583e6f94.esm.js","sources":["../../src/components/DependsOnResourcesCard/DependsOnResourcesCard.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 { RELATION_DEPENDS_ON } from '@backstage/catalog-model';\nimport React from 'react';\nimport {\n asResourceEntities,\n componentEntityHelpLink,\n RelatedEntitiesCard,\n resourceEntityColumns,\n} from '../RelatedEntitiesCard';\n\n/** @public */\nexport interface DependsOnResourcesCardProps {\n variant?: 'gridItem';\n}\n\nexport function DependsOnResourcesCard(props: DependsOnResourcesCardProps) {\n const { variant = 'gridItem' } = props;\n return (\n <RelatedEntitiesCard\n variant={variant}\n title=\"Depends on resources\"\n entityKind=\"Resource\"\n relationType={RELATION_DEPENDS_ON}\n columns={resourceEntityColumns}\n emptyMessage=\"No resource is a dependency of this component\"\n emptyHelpLink={componentEntityHelpLink}\n asRenderableEntities={asResourceEntities}\n />\n );\n}\n"],"names":[],"mappings":";;;;;;;gCA8BuC,OAAoC;AACzE,QAAM,EAAE,UAAU,eAAe;AACjC,6CACG,qBAAD;AAAA,IACE;AAAA,IACA,OAAM;AAAA,IACN,YAAW;AAAA,IACX,cAAc;AAAA,IACd,SAAS;AAAA,IACT,cAAa;AAAA,IACb,eAAe;AAAA,IACf,sBAAsB;AAAA;AAAA;;;;"}
@@ -0,0 +1,55 @@
1
+ import React from 'react';
2
+ import { useOutlet } from 'react-router';
3
+ import { PageWithHeader, Content, ContentHeader, CreateButton, SupportButton } from '@backstage/core-components';
4
+ import { useApi, configApiRef, useRouteRef } from '@backstage/core-plugin-api';
5
+ import { EntityListProvider, EntityTypePicker, UserListPicker, EntityOwnerPicker, EntityLifecyclePicker, EntityTagPicker } from '@backstage/plugin-catalog-react';
6
+ import { c as createComponentRouteRef, C as CatalogKindHeader, F as FilteredEntityLayout, a as FilterContainer, E as EntityListContainer, b as CatalogTable } from './index-de01f9dd.esm.js';
7
+ import '@backstage/catalog-model';
8
+ import '@backstage/integration-react';
9
+ import '@material-ui/core';
10
+ import '@material-ui/icons/Cached';
11
+ import '@material-ui/icons/Description';
12
+ import '@material-ui/icons/Edit';
13
+ import '@material-ui/icons/OpenInNew';
14
+ import 'lodash';
15
+ import '@material-ui/lab';
16
+ import '@material-ui/core/styles';
17
+ import '@material-ui/icons/Cancel';
18
+ import '@material-ui/icons/BugReport';
19
+ import '@material-ui/icons/MoreVert';
20
+ import '@backstage/plugin-catalog-common';
21
+ import '@backstage/errors';
22
+ import '@backstage/catalog-client';
23
+ import 'react-use/lib/useAsync';
24
+ import '@material-ui/icons/FilterList';
25
+
26
+ function DefaultCatalogPage(props) {
27
+ var _a;
28
+ const { columns, actions, initiallySelectedFilter = "owned" } = props;
29
+ const orgName = (_a = useApi(configApiRef).getOptionalString("organization.name")) != null ? _a : "Backstage";
30
+ const createComponentLink = useRouteRef(createComponentRouteRef);
31
+ return /* @__PURE__ */ React.createElement(PageWithHeader, {
32
+ title: `${orgName} Catalog`,
33
+ themeId: "home"
34
+ }, /* @__PURE__ */ React.createElement(EntityListProvider, null, /* @__PURE__ */ React.createElement(Content, null, /* @__PURE__ */ React.createElement(ContentHeader, {
35
+ titleComponent: /* @__PURE__ */ React.createElement(CatalogKindHeader, null)
36
+ }, /* @__PURE__ */ React.createElement(CreateButton, {
37
+ title: "Create Component",
38
+ to: createComponentLink && createComponentLink()
39
+ }), /* @__PURE__ */ React.createElement(SupportButton, null, "All your software catalog entities")), /* @__PURE__ */ React.createElement(FilteredEntityLayout, null, /* @__PURE__ */ React.createElement(FilterContainer, null, /* @__PURE__ */ React.createElement(EntityTypePicker, null), /* @__PURE__ */ React.createElement(UserListPicker, {
40
+ initialFilter: initiallySelectedFilter
41
+ }), /* @__PURE__ */ React.createElement(EntityOwnerPicker, null), /* @__PURE__ */ React.createElement(EntityLifecyclePicker, null), /* @__PURE__ */ React.createElement(EntityTagPicker, null)), /* @__PURE__ */ React.createElement(EntityListContainer, null, /* @__PURE__ */ React.createElement(CatalogTable, {
42
+ columns,
43
+ actions
44
+ }))))));
45
+ }
46
+
47
+ function CatalogPage(props) {
48
+ const outlet = useOutlet();
49
+ return outlet || /* @__PURE__ */ React.createElement(DefaultCatalogPage, {
50
+ ...props
51
+ });
52
+ }
53
+
54
+ export { CatalogPage, DefaultCatalogPage };
55
+ //# sourceMappingURL=index-5c367aca.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-5c367aca.esm.js","sources":["../../src/components/CatalogPage/DefaultCatalogPage.tsx","../../src/components/CatalogPage/CatalogPage.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 {\n Content,\n ContentHeader,\n CreateButton,\n PageWithHeader,\n SupportButton,\n TableColumn,\n TableProps,\n} from '@backstage/core-components';\nimport { configApiRef, useApi, useRouteRef } from '@backstage/core-plugin-api';\nimport {\n EntityLifecyclePicker,\n EntityListProvider,\n EntityOwnerPicker,\n EntityTagPicker,\n EntityTypePicker,\n UserListFilterKind,\n UserListPicker,\n} from '@backstage/plugin-catalog-react';\nimport React from 'react';\nimport { createComponentRouteRef } from '../../routes';\nimport { CatalogTable, CatalogTableRow } from '../CatalogTable';\nimport {\n FilteredEntityLayout,\n EntityListContainer,\n FilterContainer,\n} from '../FilteredEntityLayout';\nimport { CatalogKindHeader } from '../CatalogKindHeader';\n\n/**\n * Props for root catalog pages.\n *\n * @public\n */\nexport interface DefaultCatalogPageProps {\n initiallySelectedFilter?: UserListFilterKind;\n columns?: TableColumn<CatalogTableRow>[];\n actions?: TableProps<CatalogTableRow>['actions'];\n}\n\nexport function DefaultCatalogPage(props: DefaultCatalogPageProps) {\n const { columns, actions, initiallySelectedFilter = 'owned' } = props;\n const orgName =\n useApi(configApiRef).getOptionalString('organization.name') ?? 'Backstage';\n const createComponentLink = useRouteRef(createComponentRouteRef);\n\n return (\n <PageWithHeader title={`${orgName} Catalog`} themeId=\"home\">\n <EntityListProvider>\n <Content>\n <ContentHeader titleComponent={<CatalogKindHeader />}>\n <CreateButton\n title=\"Create Component\"\n to={createComponentLink && createComponentLink()}\n />\n <SupportButton>All your software catalog entities</SupportButton>\n </ContentHeader>\n <FilteredEntityLayout>\n <FilterContainer>\n <EntityTypePicker />\n <UserListPicker initialFilter={initiallySelectedFilter} />\n <EntityOwnerPicker />\n <EntityLifecyclePicker />\n <EntityTagPicker />\n </FilterContainer>\n <EntityListContainer>\n <CatalogTable columns={columns} actions={actions} />\n </EntityListContainer>\n </FilteredEntityLayout>\n </Content>\n </EntityListProvider>\n </PageWithHeader>\n );\n}\n","/*\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 from 'react';\nimport { useOutlet } from 'react-router';\nimport {\n DefaultCatalogPage,\n DefaultCatalogPageProps,\n} from './DefaultCatalogPage';\n\nexport function CatalogPage(props: DefaultCatalogPageProps) {\n const outlet = useOutlet();\n\n return outlet || <DefaultCatalogPage {...props} />;\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;4BAwDmC,OAAgC;AAxDnE;AAyDE,QAAM,EAAE,SAAS,SAAS,0BAA0B,YAAY;AAChE,QAAM,UACJ,aAAO,cAAc,kBAAkB,yBAAvC,YAA+D;AACjE,QAAM,sBAAsB,YAAY;AAExC,6CACG,gBAAD;AAAA,IAAgB,OAAO,GAAG;AAAA,IAAmB,SAAQ;AAAA,yCAClD,oBAAD,0CACG,SAAD,0CACG,eAAD;AAAA,IAAe,oDAAiB,mBAAD;AAAA,yCAC5B,cAAD;AAAA,IACE,OAAM;AAAA,IACN,IAAI,uBAAuB;AAAA,0CAE5B,eAAD,MAAe,4EAEhB,sBAAD,0CACG,iBAAD,0CACG,kBAAD,2CACC,gBAAD;AAAA,IAAgB,eAAe;AAAA,0CAC9B,mBAAD,2CACC,uBAAD,2CACC,iBAAD,4CAED,qBAAD,0CACG,cAAD;AAAA,IAAc;AAAA,IAAkB;AAAA;AAAA;;qBC3DlB,OAAgC;AAC1D,QAAM,SAAS;AAEf,SAAO,8CAAW,oBAAD;AAAA,OAAwB;AAAA;AAAA;;;;"}
@@ -1,11 +1,12 @@
1
1
  import { RELATION_HAS_PART } from '@backstage/catalog-model';
2
2
  import React from 'react';
3
- import { R as RelatedEntitiesCard, c as componentEntityColumns, e as asComponentEntities } from './presets-711f07f8.esm.js';
3
+ import { R as RelatedEntitiesCard, c as componentEntityColumns, e as asComponentEntities } from './presets-8488ee8e.esm.js';
4
4
  import '@material-ui/core';
5
5
  import '@backstage/plugin-catalog-react';
6
6
  import '@backstage/core-components';
7
7
 
8
- const HasSubcomponentsCard = ({ variant = "gridItem" }) => {
8
+ function HasSubcomponentsCard(props) {
9
+ const { variant = "gridItem" } = props;
9
10
  return /* @__PURE__ */ React.createElement(RelatedEntitiesCard, {
10
11
  variant,
11
12
  title: "Has subcomponents",
@@ -16,7 +17,7 @@ const HasSubcomponentsCard = ({ variant = "gridItem" }) => {
16
17
  emptyMessage: "No subcomponent is part of this component",
17
18
  emptyHelpLink: "https://backstage.io/docs/features/software-catalog/descriptor-format#specsubcomponentof-optional"
18
19
  });
19
- };
20
+ }
20
21
 
21
22
  export { HasSubcomponentsCard };
22
- //# sourceMappingURL=index-dd3d0aa1.esm.js.map
23
+ //# sourceMappingURL=index-69fcf315.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-69fcf315.esm.js","sources":["../../src/components/HasSubcomponentsCard/HasSubcomponentsCard.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 { RELATION_HAS_PART } from '@backstage/catalog-model';\nimport React from 'react';\nimport {\n asComponentEntities,\n componentEntityColumns,\n RelatedEntitiesCard,\n} from '../RelatedEntitiesCard';\n\n/** @public */\nexport interface HasSubcomponentsCardProps {\n variant?: 'gridItem';\n}\n\nexport function HasSubcomponentsCard(props: HasSubcomponentsCardProps) {\n const { variant = 'gridItem' } = props;\n return (\n <RelatedEntitiesCard\n variant={variant}\n title=\"Has subcomponents\"\n entityKind=\"Component\"\n relationType={RELATION_HAS_PART}\n columns={componentEntityColumns}\n asRenderableEntities={asComponentEntities}\n emptyMessage=\"No subcomponent is part of this component\"\n emptyHelpLink=\"https://backstage.io/docs/features/software-catalog/descriptor-format#specsubcomponentof-optional\"\n />\n );\n}\n"],"names":[],"mappings":";;;;;;;8BA6BqC,OAAkC;AACrE,QAAM,EAAE,UAAU,eAAe;AACjC,6CACG,qBAAD;AAAA,IACE;AAAA,IACA,OAAM;AAAA,IACN,YAAW;AAAA,IACX,cAAc;AAAA,IACd,SAAS;AAAA,IACT,sBAAsB;AAAA,IACtB,cAAa;AAAA,IACb,eAAc;AAAA;AAAA;;;;"}
@@ -1,11 +1,12 @@
1
1
  import { RELATION_HAS_PART } from '@backstage/catalog-model';
2
2
  import React from 'react';
3
- import { R as RelatedEntitiesCard, s as systemEntityColumns, a as asSystemEntities, b as systemEntityHelpLink } from './presets-711f07f8.esm.js';
3
+ import { R as RelatedEntitiesCard, s as systemEntityColumns, a as asSystemEntities, b as systemEntityHelpLink } from './presets-8488ee8e.esm.js';
4
4
  import '@material-ui/core';
5
5
  import '@backstage/plugin-catalog-react';
6
6
  import '@backstage/core-components';
7
7
 
8
- const HasSystemsCard = ({ variant = "gridItem" }) => {
8
+ function HasSystemsCard(props) {
9
+ const { variant = "gridItem" } = props;
9
10
  return /* @__PURE__ */ React.createElement(RelatedEntitiesCard, {
10
11
  variant,
11
12
  title: "Has systems",
@@ -16,7 +17,7 @@ const HasSystemsCard = ({ variant = "gridItem" }) => {
16
17
  emptyMessage: "No system is part of this domain",
17
18
  emptyHelpLink: systemEntityHelpLink
18
19
  });
19
- };
20
+ }
20
21
 
21
22
  export { HasSystemsCard };
22
- //# sourceMappingURL=index-acc2d5cf.esm.js.map
23
+ //# sourceMappingURL=index-bb5ef8ab.esm.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index-acc2d5cf.esm.js","sources":["../../src/components/HasSystemsCard/HasSystemsCard.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 { RELATION_HAS_PART } from '@backstage/catalog-model';\nimport React from 'react';\nimport {\n asSystemEntities,\n RelatedEntitiesCard,\n systemEntityColumns,\n systemEntityHelpLink,\n} from '../RelatedEntitiesCard';\n\ntype Props = {\n variant?: 'gridItem';\n};\n\nexport const HasSystemsCard = ({ variant = 'gridItem' }: Props) => {\n return (\n <RelatedEntitiesCard\n variant={variant}\n title=\"Has systems\"\n entityKind=\"System\"\n relationType={RELATION_HAS_PART}\n columns={systemEntityColumns}\n asRenderableEntities={asSystemEntities}\n emptyMessage=\"No system is part of this domain\"\n emptyHelpLink={systemEntityHelpLink}\n />\n );\n};\n"],"names":[],"mappings":";;;;;;;MA6Ba,iBAAiB,CAAC,EAAE,UAAU,iBAAwB;AACjE,6CACG,qBAAD;AAAA,IACE;AAAA,IACA,OAAM;AAAA,IACN,YAAW;AAAA,IACX,cAAc;AAAA,IACd,SAAS;AAAA,IACT,sBAAsB;AAAA,IACtB,cAAa;AAAA,IACb,eAAe;AAAA;AAAA;;;;"}
1
+ {"version":3,"file":"index-bb5ef8ab.esm.js","sources":["../../src/components/HasSystemsCard/HasSystemsCard.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 { RELATION_HAS_PART } from '@backstage/catalog-model';\nimport React from 'react';\nimport {\n asSystemEntities,\n RelatedEntitiesCard,\n systemEntityColumns,\n systemEntityHelpLink,\n} from '../RelatedEntitiesCard';\n\n/** @public */\nexport interface HasSystemsCardProps {\n variant?: 'gridItem';\n}\n\nexport function HasSystemsCard(props: HasSystemsCardProps) {\n const { variant = 'gridItem' } = props;\n return (\n <RelatedEntitiesCard\n variant={variant}\n title=\"Has systems\"\n entityKind=\"System\"\n relationType={RELATION_HAS_PART}\n columns={systemEntityColumns}\n asRenderableEntities={asSystemEntities}\n emptyMessage=\"No system is part of this domain\"\n emptyHelpLink={systemEntityHelpLink}\n />\n );\n}\n"],"names":[],"mappings":";;;;;;;wBA8B+B,OAA4B;AACzD,QAAM,EAAE,UAAU,eAAe;AACjC,6CACG,qBAAD;AAAA,IACE;AAAA,IACA,OAAM;AAAA,IACN,YAAW;AAAA,IACX,cAAc;AAAA,IACd,SAAS;AAAA,IACT,sBAAsB;AAAA,IACtB,cAAa;AAAA,IACb,eAAe;AAAA;AAAA;;;;"}
@@ -1,14 +1,12 @@
1
1
  import { RELATION_DEPENDS_ON } from '@backstage/catalog-model';
2
2
  import React from 'react';
3
- import { R as RelatedEntitiesCard, c as componentEntityColumns, d as componentEntityHelpLink, e as asComponentEntities } from './presets-711f07f8.esm.js';
3
+ import { R as RelatedEntitiesCard, c as componentEntityColumns, d as componentEntityHelpLink, e as asComponentEntities } from './presets-8488ee8e.esm.js';
4
4
  import '@material-ui/core';
5
5
  import '@backstage/plugin-catalog-react';
6
6
  import '@backstage/core-components';
7
7
 
8
- const DependsOnComponentsCard = ({
9
- variant = "gridItem",
10
- title = "Depends on components"
11
- }) => {
8
+ function DependsOnComponentsCard(props) {
9
+ const { variant = "gridItem", title = "Depends on components" } = props;
12
10
  return /* @__PURE__ */ React.createElement(RelatedEntitiesCard, {
13
11
  variant,
14
12
  title,
@@ -19,7 +17,7 @@ const DependsOnComponentsCard = ({
19
17
  emptyHelpLink: componentEntityHelpLink,
20
18
  asRenderableEntities: asComponentEntities
21
19
  });
22
- };
20
+ }
23
21
 
24
22
  export { DependsOnComponentsCard };
25
- //# sourceMappingURL=index-e48f93af.esm.js.map
23
+ //# sourceMappingURL=index-be138931.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-be138931.esm.js","sources":["../../src/components/DependsOnComponentsCard/DependsOnComponentsCard.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 { RELATION_DEPENDS_ON } from '@backstage/catalog-model';\nimport React from 'react';\nimport {\n asComponentEntities,\n componentEntityColumns,\n componentEntityHelpLink,\n RelatedEntitiesCard,\n} from '../RelatedEntitiesCard';\n\n/** @public */\nexport interface DependsOnComponentsCardProps {\n variant?: 'gridItem';\n title?: string;\n}\n\nexport function DependsOnComponentsCard(props: DependsOnComponentsCardProps) {\n const { variant = 'gridItem', title = 'Depends on components' } = props;\n return (\n <RelatedEntitiesCard\n variant={variant}\n title={title}\n entityKind=\"Component\"\n relationType={RELATION_DEPENDS_ON}\n columns={componentEntityColumns}\n emptyMessage=\"No component is a dependency of this component\"\n emptyHelpLink={componentEntityHelpLink}\n asRenderableEntities={asComponentEntities}\n />\n );\n}\n"],"names":[],"mappings":";;;;;;;iCA+BwC,OAAqC;AAC3E,QAAM,EAAE,UAAU,YAAY,QAAQ,4BAA4B;AAClE,6CACG,qBAAD;AAAA,IACE;AAAA,IACA;AAAA,IACA,YAAW;AAAA,IACX,cAAc;AAAA,IACd,SAAS;AAAA,IACT,cAAa;AAAA,IACb,eAAe;AAAA,IACf,sBAAsB;AAAA;AAAA;;;;"}