@backstage/plugin-org 0.6.38-next.1 → 0.6.38-next.2
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 +17 -0
- package/dist/alpha.d.ts +5 -5
- package/dist/alpha.esm.js +5 -5
- package/dist/alpha.esm.js.map +1 -1
- package/dist/components/Cards/Group/GroupProfile/GroupProfileCard.esm.js +73 -49
- package/dist/components/Cards/Group/GroupProfile/GroupProfileCard.esm.js.map +1 -1
- package/dist/components/Cards/Group/MembersList/MembersListCard.esm.js +70 -55
- package/dist/components/Cards/Group/MembersList/MembersListCard.esm.js.map +1 -1
- package/dist/components/Cards/Meta/LinksGroup.esm.js +19 -13
- package/dist/components/Cards/Meta/LinksGroup.esm.js.map +1 -1
- package/dist/components/Cards/OwnershipCard/ComponentsGrid.esm.js +26 -24
- package/dist/components/Cards/OwnershipCard/ComponentsGrid.esm.js.map +1 -1
- package/dist/components/Cards/OwnershipCard/OwnershipCard.esm.js +48 -40
- package/dist/components/Cards/OwnershipCard/OwnershipCard.esm.js.map +1 -1
- package/dist/components/Cards/User/UserProfileCard/UserProfileCard.esm.js +34 -18
- package/dist/components/Cards/User/UserProfileCard/UserProfileCard.esm.js.map +1 -1
- package/dist/components/MyGroupsSidebarItem/MyGroupsSidebarItem.esm.js +8 -8
- package/dist/components/MyGroupsSidebarItem/MyGroupsSidebarItem.esm.js.map +1 -1
- package/dist/index.d.ts +10 -11
- package/package.json +15 -15
|
@@ -1,34 +1,40 @@
|
|
|
1
|
+
import { jsxs, Fragment, jsx } from 'react/jsx-runtime';
|
|
1
2
|
import { useApp } from '@backstage/core-plugin-api';
|
|
2
3
|
import LanguageIcon from '@material-ui/icons/Language';
|
|
3
4
|
import ListItem from '@material-ui/core/ListItem';
|
|
4
5
|
import ListItemIcon from '@material-ui/core/ListItemIcon';
|
|
5
6
|
import ListItemText from '@material-ui/core/ListItemText';
|
|
6
7
|
import Divider from '@material-ui/core/Divider';
|
|
7
|
-
import React from 'react';
|
|
8
8
|
import { Link } from '@backstage/core-components';
|
|
9
9
|
|
|
10
10
|
const WebLink = ({
|
|
11
11
|
href,
|
|
12
12
|
Icon,
|
|
13
13
|
text
|
|
14
|
-
}) => /* @__PURE__ */
|
|
14
|
+
}) => /* @__PURE__ */ jsxs(ListItem, { children: [
|
|
15
|
+
/* @__PURE__ */ jsx(ListItemIcon, { children: Icon ? /* @__PURE__ */ jsx(Icon, {}) : /* @__PURE__ */ jsx(LanguageIcon, {}) }),
|
|
16
|
+
/* @__PURE__ */ jsx(ListItemText, { children: /* @__PURE__ */ jsx(Link, { to: href, children: text }) })
|
|
17
|
+
] }, href);
|
|
15
18
|
const LinksGroup = ({ links }) => {
|
|
16
19
|
const app = useApp();
|
|
17
20
|
const iconResolver = (key) => key ? app.getSystemIcon(key) ?? LanguageIcon : LanguageIcon;
|
|
18
21
|
if (links === void 0) {
|
|
19
22
|
return null;
|
|
20
23
|
}
|
|
21
|
-
return /* @__PURE__ */
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
24
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
25
|
+
/* @__PURE__ */ jsx(Divider, {}),
|
|
26
|
+
links.map((link) => {
|
|
27
|
+
return /* @__PURE__ */ jsx(
|
|
28
|
+
WebLink,
|
|
29
|
+
{
|
|
30
|
+
href: link.url,
|
|
31
|
+
text: link.title,
|
|
32
|
+
Icon: iconResolver(link.icon)
|
|
33
|
+
},
|
|
34
|
+
link.url
|
|
35
|
+
);
|
|
36
|
+
})
|
|
37
|
+
] });
|
|
32
38
|
};
|
|
33
39
|
|
|
34
40
|
export { LinksGroup };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LinksGroup.esm.js","sources":["../../../../src/components/Cards/Meta/LinksGroup.tsx"],"sourcesContent":["/*\n * Copyright 2022 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 { EntityLink } from '@backstage/catalog-model';\nimport { IconComponent, useApp } from '@backstage/core-plugin-api';\nimport LanguageIcon from '@material-ui/icons/Language';\nimport ListItem from '@material-ui/core/ListItem';\nimport ListItemIcon from '@material-ui/core/ListItemIcon';\nimport ListItemText from '@material-ui/core/ListItemText';\nimport Divider from '@material-ui/core/Divider';\nimport
|
|
1
|
+
{"version":3,"file":"LinksGroup.esm.js","sources":["../../../../src/components/Cards/Meta/LinksGroup.tsx"],"sourcesContent":["/*\n * Copyright 2022 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 { EntityLink } from '@backstage/catalog-model';\nimport { IconComponent, useApp } from '@backstage/core-plugin-api';\nimport LanguageIcon from '@material-ui/icons/Language';\nimport ListItem from '@material-ui/core/ListItem';\nimport ListItemIcon from '@material-ui/core/ListItemIcon';\nimport ListItemText from '@material-ui/core/ListItemText';\nimport Divider from '@material-ui/core/Divider';\nimport { Link } from '@backstage/core-components';\n\nconst WebLink = ({\n href,\n Icon,\n text,\n}: {\n href: string;\n text?: string;\n Icon?: IconComponent;\n}) => (\n <ListItem key={href}>\n <ListItemIcon>{Icon ? <Icon /> : <LanguageIcon />}</ListItemIcon>\n <ListItemText>\n <Link to={href}>{text}</Link>\n </ListItemText>\n </ListItem>\n);\n\nexport const LinksGroup = ({ links }: { links?: EntityLink[] }) => {\n const app = useApp();\n const iconResolver = (key?: string): IconComponent =>\n key ? app.getSystemIcon(key) ?? LanguageIcon : LanguageIcon;\n\n if (links === undefined) {\n return null;\n }\n\n return (\n <>\n <Divider />\n {links.map(link => {\n return (\n <WebLink\n key={link.url}\n href={link.url}\n text={link.title}\n Icon={iconResolver(link.icon)}\n />\n );\n })}\n </>\n );\n};\n"],"names":[],"mappings":";;;;;;;;;AAwBA,MAAM,UAAU,CAAC;AAAA,EACf,IAAA;AAAA,EACA,IAAA;AAAA,EACA;AACF,CAAA,0BAKG,QACC,EAAA,EAAA,QAAA,EAAA;AAAA,kBAAA,GAAA,CAAC,gBAAc,QAAO,EAAA,IAAA,mBAAA,GAAA,CAAC,QAAK,CAAK,mBAAA,GAAA,CAAC,gBAAa,CAAG,EAAA,CAAA;AAAA,sBACjD,YACC,EAAA,EAAA,QAAA,kBAAA,GAAA,CAAC,QAAK,EAAI,EAAA,IAAA,EAAO,gBAAK,CACxB,EAAA;AAAA,CAAA,EAAA,EAJa,IAKf,CAAA;AAGK,MAAM,UAAa,GAAA,CAAC,EAAE,KAAA,EAAsC,KAAA;AACjE,EAAA,MAAM,MAAM,MAAO,EAAA;AACnB,EAAM,MAAA,YAAA,GAAe,CAAC,GACpB,KAAA,GAAA,GAAM,IAAI,aAAc,CAAA,GAAG,KAAK,YAAe,GAAA,YAAA;AAEjD,EAAA,IAAI,UAAU,KAAW,CAAA,EAAA;AACvB,IAAO,OAAA,IAAA;AAAA;AAGT,EAAA,uBAEI,IAAA,CAAA,QAAA,EAAA,EAAA,QAAA,EAAA;AAAA,oBAAA,GAAA,CAAC,OAAQ,EAAA,EAAA,CAAA;AAAA,IACR,KAAA,CAAM,IAAI,CAAQ,IAAA,KAAA;AACjB,MACE,uBAAA,GAAA;AAAA,QAAC,OAAA;AAAA,QAAA;AAAA,UAEC,MAAM,IAAK,CAAA,GAAA;AAAA,UACX,MAAM,IAAK,CAAA,KAAA;AAAA,UACX,IAAA,EAAM,YAAa,CAAA,IAAA,CAAK,IAAI;AAAA,SAAA;AAAA,QAHvB,IAAK,CAAA;AAAA,OAIZ;AAAA,KAEH;AAAA,GACH,EAAA,CAAA;AAEJ;;;;"}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
+
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
1
2
|
import { Progress, ResponseErrorPanel, OverflowTooltip, Link } from '@backstage/core-components';
|
|
2
3
|
import { useRouteRef } from '@backstage/core-plugin-api';
|
|
3
4
|
import Box from '@material-ui/core/Box';
|
|
4
5
|
import Grid from '@material-ui/core/Grid';
|
|
5
6
|
import Typography from '@material-ui/core/Typography';
|
|
6
7
|
import { makeStyles, createStyles } from '@material-ui/core/styles';
|
|
7
|
-
import React from 'react';
|
|
8
8
|
import pluralize from 'pluralize';
|
|
9
9
|
import { catalogIndexRouteRef } from '../../../routes.esm.js';
|
|
10
10
|
import { useGetEntities } from './useGetEntities.esm.js';
|
|
@@ -43,32 +43,34 @@ const EntityCountTile = ({
|
|
|
43
43
|
const classes = useStyles({ type: type ?? kind });
|
|
44
44
|
const rawTitle = type ?? kind;
|
|
45
45
|
const isLongText = rawTitle.length > 10;
|
|
46
|
-
const tile = /* @__PURE__ */
|
|
46
|
+
const tile = /* @__PURE__ */ jsxs(
|
|
47
47
|
Box,
|
|
48
48
|
{
|
|
49
49
|
className: `${classes.card} ${classes.entityTypeBox}`,
|
|
50
50
|
display: "flex",
|
|
51
51
|
flexDirection: "column",
|
|
52
|
-
alignItems: "center"
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
52
|
+
alignItems: "center",
|
|
53
|
+
children: [
|
|
54
|
+
/* @__PURE__ */ jsx(Typography, { className: classes.bold, variant: "h6", children: counter }),
|
|
55
|
+
/* @__PURE__ */ jsx(Box, { sx: { width: "100%", textAlign: "center" }, children: /* @__PURE__ */ jsx(
|
|
56
|
+
Typography,
|
|
57
|
+
{
|
|
58
|
+
className: `${classes.bold} ${isLongText && classes.smallFont}`,
|
|
59
|
+
variant: "h6",
|
|
60
|
+
children: /* @__PURE__ */ jsx(
|
|
61
|
+
OverflowTooltip,
|
|
62
|
+
{
|
|
63
|
+
text: pluralize(rawTitle.toLocaleUpperCase("en-US"), counter)
|
|
64
|
+
}
|
|
65
|
+
)
|
|
66
|
+
}
|
|
67
|
+
) }),
|
|
68
|
+
type && /* @__PURE__ */ jsx(Typography, { variant: "subtitle1", children: kind })
|
|
69
|
+
]
|
|
70
|
+
}
|
|
69
71
|
);
|
|
70
72
|
if (url) {
|
|
71
|
-
return /* @__PURE__ */
|
|
73
|
+
return /* @__PURE__ */ jsx(Link, { to: url, variant: "body2", children: tile });
|
|
72
74
|
}
|
|
73
75
|
return tile;
|
|
74
76
|
};
|
|
@@ -94,11 +96,11 @@ const ComponentsGrid = ({
|
|
|
94
96
|
entityLimit
|
|
95
97
|
);
|
|
96
98
|
if (loading) {
|
|
97
|
-
return /* @__PURE__ */
|
|
99
|
+
return /* @__PURE__ */ jsx(Progress, {});
|
|
98
100
|
} else if (error) {
|
|
99
|
-
return /* @__PURE__ */
|
|
101
|
+
return /* @__PURE__ */ jsx(ResponseErrorPanel, { error });
|
|
100
102
|
}
|
|
101
|
-
return /* @__PURE__ */
|
|
103
|
+
return /* @__PURE__ */ jsx(Grid, { container: true, className, children: componentsWithCounters?.map((c) => /* @__PURE__ */ jsx(Grid, { item: true, xs: 6, md: 6, lg: 4, children: /* @__PURE__ */ jsx(
|
|
102
104
|
EntityCountTile,
|
|
103
105
|
{
|
|
104
106
|
counter: c.counter,
|
|
@@ -106,7 +108,7 @@ const ComponentsGrid = ({
|
|
|
106
108
|
type: c.type,
|
|
107
109
|
url: catalogLink && `${catalogLink()}/?${c.queryParams}`
|
|
108
110
|
}
|
|
109
|
-
))));
|
|
111
|
+
) }, c.type ?? c.kind)) });
|
|
110
112
|
};
|
|
111
113
|
|
|
112
114
|
export { ComponentsGrid };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ComponentsGrid.esm.js","sources":["../../../../src/components/Cards/OwnershipCard/ComponentsGrid.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 {\n Link,\n OverflowTooltip,\n Progress,\n ResponseErrorPanel,\n} from '@backstage/core-components';\nimport { useRouteRef } from '@backstage/core-plugin-api';\nimport Box from '@material-ui/core/Box';\nimport Grid from '@material-ui/core/Grid';\nimport Typography from '@material-ui/core/Typography';\nimport { createStyles, makeStyles } from '@material-ui/core/styles';\nimport
|
|
1
|
+
{"version":3,"file":"ComponentsGrid.esm.js","sources":["../../../../src/components/Cards/OwnershipCard/ComponentsGrid.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 {\n Link,\n OverflowTooltip,\n Progress,\n ResponseErrorPanel,\n} from '@backstage/core-components';\nimport { useRouteRef } from '@backstage/core-plugin-api';\nimport Box from '@material-ui/core/Box';\nimport Grid from '@material-ui/core/Grid';\nimport Typography from '@material-ui/core/Typography';\nimport { createStyles, makeStyles } from '@material-ui/core/styles';\nimport pluralize from 'pluralize';\nimport { catalogIndexRouteRef } from '../../../routes';\nimport { useGetEntities } from './useGetEntities';\nimport { EntityRelationAggregation } from '../types';\n\nconst useStyles = makeStyles(theme =>\n createStyles({\n card: {\n border: `1px solid ${theme.palette.divider}`,\n boxShadow: theme.shadows[2],\n borderRadius: '4px',\n padding: theme.spacing(2),\n transition: `${theme.transitions.duration.standard}ms`,\n '&:hover': {\n boxShadow: theme.shadows[4],\n },\n height: '100%',\n },\n bold: {\n fontWeight: theme.typography.fontWeightBold,\n },\n smallFont: {\n fontSize: theme.typography.body2.fontSize,\n },\n entityTypeBox: {\n background: (props: { type: string }) =>\n theme.getPageTheme({ themeId: props.type }).backgroundImage,\n color: (props: { type: string }) =>\n theme.getPageTheme({ themeId: props.type }).fontColor,\n },\n }),\n);\n\nconst EntityCountTile = ({\n counter,\n type,\n kind,\n url,\n}: {\n counter: number;\n type?: string;\n kind: string;\n url?: string;\n}) => {\n const classes = useStyles({ type: type ?? kind });\n\n const rawTitle = type ?? kind;\n const isLongText = rawTitle.length > 10;\n\n const tile = (\n <Box\n className={`${classes.card} ${classes.entityTypeBox}`}\n display=\"flex\"\n flexDirection=\"column\"\n alignItems=\"center\"\n >\n <Typography className={classes.bold} variant=\"h6\">\n {counter}\n </Typography>\n <Box sx={{ width: '100%', textAlign: 'center' }}>\n <Typography\n className={`${classes.bold} ${isLongText && classes.smallFont}`}\n variant=\"h6\"\n >\n <OverflowTooltip\n text={pluralize(rawTitle.toLocaleUpperCase('en-US'), counter)}\n />\n </Typography>\n </Box>\n {type && <Typography variant=\"subtitle1\">{kind}</Typography>}\n </Box>\n );\n\n if (url) {\n return (\n <Link to={url} variant=\"body2\">\n {tile}\n </Link>\n );\n }\n return tile;\n};\n\nexport const ComponentsGrid = ({\n className,\n entity,\n relationsType,\n relationAggregation,\n entityFilterKind,\n entityLimit = 6,\n}: {\n className?: string;\n entity: Entity;\n /** @deprecated Please use relationAggregation instead */\n relationsType?: EntityRelationAggregation;\n relationAggregation?: EntityRelationAggregation;\n entityFilterKind?: string[];\n entityLimit?: number;\n}) => {\n const catalogLink = useRouteRef(catalogIndexRouteRef);\n if (!relationsType && !relationAggregation) {\n throw new Error(\n 'The relationAggregation property must be set as an EntityRelationAggregation type.',\n );\n }\n const { componentsWithCounters, loading, error } = useGetEntities(\n entity,\n (relationAggregation ?? relationsType)!, // we can safely use the non-null assertion here because of the run-time check above\n entityFilterKind,\n entityLimit,\n );\n\n if (loading) {\n return <Progress />;\n } else if (error) {\n return <ResponseErrorPanel error={error} />;\n }\n\n return (\n <Grid container className={className}>\n {componentsWithCounters?.map(c => (\n <Grid item xs={6} md={6} lg={4} key={c.type ?? c.kind}>\n <EntityCountTile\n counter={c.counter}\n kind={c.kind}\n type={c.type}\n url={catalogLink && `${catalogLink()}/?${c.queryParams}`}\n />\n </Grid>\n ))}\n </Grid>\n );\n};\n"],"names":[],"mappings":";;;;;;;;;;;AAiCA,MAAM,SAAY,GAAA,UAAA;AAAA,EAAW,WAC3B,YAAa,CAAA;AAAA,IACX,IAAM,EAAA;AAAA,MACJ,MAAQ,EAAA,CAAA,UAAA,EAAa,KAAM,CAAA,OAAA,CAAQ,OAAO,CAAA,CAAA;AAAA,MAC1C,SAAA,EAAW,KAAM,CAAA,OAAA,CAAQ,CAAC,CAAA;AAAA,MAC1B,YAAc,EAAA,KAAA;AAAA,MACd,OAAA,EAAS,KAAM,CAAA,OAAA,CAAQ,CAAC,CAAA;AAAA,MACxB,UAAY,EAAA,CAAA,EAAG,KAAM,CAAA,WAAA,CAAY,SAAS,QAAQ,CAAA,EAAA,CAAA;AAAA,MA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AAAA;AAAA,IACxB,gBAAA;AAAA,IACA;AAAA,GACF;AAEA,EAAA,IAAI,OAAS,EAAA;AACX,IAAA,2BAAQ,QAAS,EAAA,EAAA,CAAA;AAAA,aACR,KAAO,EAAA;AAChB,IAAO,uBAAA,GAAA,CAAC,sBAAmB,KAAc,EAAA,CAAA;AAAA;AAG3C,EAAA,2BACG,IAAK,EAAA,EAAA,SAAA,EAAS,IAAC,EAAA,SAAA,EACb,kCAAwB,GAAI,CAAA,CAAA,CAAA,qBAC1B,GAAA,CAAA,IAAA,EAAA,EAAK,MAAI,IAAC,EAAA,EAAA,EAAI,GAAG,EAAI,EAAA,CAAA,EAAG,IAAI,CAC3B,EAAA,QAAA,kBAAA,GAAA;AAAA,IAAC,eAAA;AAAA,IAAA;AAAA,MACC,SAAS,CAAE,CAAA,OAAA;AAAA,MACX,MAAM,CAAE,CAAA,IAAA;AAAA,MACR,MAAM,CAAE,CAAA,IAAA;AAAA,MACR,KAAK,WAAe,IAAA,CAAA,EAAG,aAAa,CAAA,EAAA,EAAK,EAAE,WAAW,CAAA;AAAA;AAAA,OALrB,CAAE,CAAA,IAAA,IAAQ,CAAE,CAAA,IAOjD,CACD,CACH,EAAA,CAAA;AAEJ;;;;"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
1
2
|
import { InfoCard } from '@backstage/core-components';
|
|
2
3
|
import { useEntity } from '@backstage/plugin-catalog-react';
|
|
3
4
|
import List from '@material-ui/core/List';
|
|
@@ -7,7 +8,7 @@ import ListItemText from '@material-ui/core/ListItemText';
|
|
|
7
8
|
import Switch from '@material-ui/core/Switch';
|
|
8
9
|
import Tooltip from '@material-ui/core/Tooltip';
|
|
9
10
|
import { makeStyles } from '@material-ui/core/styles';
|
|
10
|
-
import
|
|
11
|
+
import { useState, useEffect } from 'react';
|
|
11
12
|
import { ComponentsGrid } from './ComponentsGrid.esm.js';
|
|
12
13
|
|
|
13
14
|
const useStyles = makeStyles((theme) => ({
|
|
@@ -64,53 +65,60 @@ const OwnershipCard = (props) => {
|
|
|
64
65
|
setRelationAggregation(defaultRelationAggregation);
|
|
65
66
|
}
|
|
66
67
|
}, [setRelationAggregation, defaultRelationAggregation, relationAggregation]);
|
|
67
|
-
return /* @__PURE__ */
|
|
68
|
+
return /* @__PURE__ */ jsxs(
|
|
68
69
|
InfoCard,
|
|
69
70
|
{
|
|
70
71
|
title: "Ownership",
|
|
71
72
|
variant,
|
|
72
73
|
className: classes.card,
|
|
73
|
-
cardClassName: classes.cardContent
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
74
|
+
cardClassName: classes.cardContent,
|
|
75
|
+
children: [
|
|
76
|
+
!relationsToggle && /* @__PURE__ */ jsx(List, { dense: true, children: /* @__PURE__ */ jsxs(ListItem, { className: classes.list, children: [
|
|
77
|
+
/* @__PURE__ */ jsx(ListItemText, { className: classes.listItemText }),
|
|
78
|
+
/* @__PURE__ */ jsxs(
|
|
79
|
+
ListItemSecondaryAction,
|
|
80
|
+
{
|
|
81
|
+
className: classes.listItemSecondaryAction,
|
|
82
|
+
children: [
|
|
83
|
+
"Direct Relations",
|
|
84
|
+
/* @__PURE__ */ jsx(
|
|
85
|
+
Tooltip,
|
|
86
|
+
{
|
|
87
|
+
placement: "top",
|
|
88
|
+
arrow: true,
|
|
89
|
+
title: `${getRelationAggregation === "direct" ? "Direct" : "Aggregated"} Relations`,
|
|
90
|
+
children: /* @__PURE__ */ jsx(
|
|
91
|
+
Switch,
|
|
92
|
+
{
|
|
93
|
+
color: "primary",
|
|
94
|
+
checked: getRelationAggregation !== "direct",
|
|
95
|
+
onChange: () => {
|
|
96
|
+
const updatedRelationAggregation = getRelationAggregation === "direct" ? "aggregated" : "direct";
|
|
97
|
+
setRelationAggregation(updatedRelationAggregation);
|
|
98
|
+
},
|
|
99
|
+
name: "pin",
|
|
100
|
+
inputProps: { "aria-label": "Ownership Type Switch" }
|
|
101
|
+
}
|
|
102
|
+
)
|
|
103
|
+
}
|
|
104
|
+
),
|
|
105
|
+
"Aggregated Relations"
|
|
106
|
+
]
|
|
107
|
+
}
|
|
108
|
+
)
|
|
109
|
+
] }) }),
|
|
110
|
+
/* @__PURE__ */ jsx(
|
|
111
|
+
ComponentsGrid,
|
|
90
112
|
{
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
},
|
|
97
|
-
name: "pin",
|
|
98
|
-
inputProps: { "aria-label": "Ownership Type Switch" }
|
|
113
|
+
className: classes.grid,
|
|
114
|
+
entity,
|
|
115
|
+
entityLimit,
|
|
116
|
+
relationAggregation: getRelationAggregation,
|
|
117
|
+
entityFilterKind
|
|
99
118
|
}
|
|
100
119
|
)
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
))),
|
|
104
|
-
/* @__PURE__ */ React.createElement(
|
|
105
|
-
ComponentsGrid,
|
|
106
|
-
{
|
|
107
|
-
className: classes.grid,
|
|
108
|
-
entity,
|
|
109
|
-
entityLimit,
|
|
110
|
-
relationAggregation: getRelationAggregation,
|
|
111
|
-
entityFilterKind
|
|
112
|
-
}
|
|
113
|
-
)
|
|
120
|
+
]
|
|
121
|
+
}
|
|
114
122
|
);
|
|
115
123
|
};
|
|
116
124
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OwnershipCard.esm.js","sources":["../../../../src/components/Cards/OwnershipCard/OwnershipCard.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 { InfoCard, InfoCardVariants } from '@backstage/core-components';\nimport { useEntity } from '@backstage/plugin-catalog-react';\nimport List from '@material-ui/core/List';\nimport ListItem from '@material-ui/core/ListItem';\nimport ListItemSecondaryAction from '@material-ui/core/ListItemSecondaryAction';\nimport ListItemText from '@material-ui/core/ListItemText';\nimport Switch from '@material-ui/core/Switch';\nimport Tooltip from '@material-ui/core/Tooltip';\nimport { makeStyles } from '@material-ui/core/styles';\nimport
|
|
1
|
+
{"version":3,"file":"OwnershipCard.esm.js","sources":["../../../../src/components/Cards/OwnershipCard/OwnershipCard.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 { InfoCard, InfoCardVariants } from '@backstage/core-components';\nimport { useEntity } from '@backstage/plugin-catalog-react';\nimport List from '@material-ui/core/List';\nimport ListItem from '@material-ui/core/ListItem';\nimport ListItemSecondaryAction from '@material-ui/core/ListItemSecondaryAction';\nimport ListItemText from '@material-ui/core/ListItemText';\nimport Switch from '@material-ui/core/Switch';\nimport Tooltip from '@material-ui/core/Tooltip';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useEffect, useState } from 'react';\nimport { ComponentsGrid } from './ComponentsGrid';\nimport { EntityRelationAggregation } from '../types';\n\nconst useStyles = makeStyles(theme => ({\n card: {\n maxHeight: '100%',\n },\n cardContent: {\n display: 'flex',\n flexDirection: 'column',\n overflow: 'hidden',\n },\n list: {\n [theme.breakpoints.down('xs')]: {\n padding: `0 0 12px`,\n },\n },\n listItemText: {\n [theme.breakpoints.down('xs')]: {\n paddingRight: 0,\n paddingLeft: 0,\n },\n },\n listItemSecondaryAction: {\n [theme.breakpoints.down('xs')]: {\n width: '100%',\n top: 'auto',\n right: 'auto',\n position: 'relative',\n transform: 'unset',\n },\n },\n grid: {\n overflowY: 'auto',\n marginTop: 0,\n },\n}));\n\n/** @public */\nexport const OwnershipCard = (props: {\n variant?: InfoCardVariants;\n entityFilterKind?: string[];\n hideRelationsToggle?: boolean;\n /** @deprecated Please use relationAggregation instead */\n relationsType?: EntityRelationAggregation;\n relationAggregation?: EntityRelationAggregation;\n entityLimit?: number;\n}) => {\n const {\n variant,\n entityFilterKind,\n hideRelationsToggle,\n entityLimit = 6,\n } = props;\n const relationAggregation = props.relationAggregation ?? props.relationsType;\n const relationsToggle =\n hideRelationsToggle === undefined ? false : hideRelationsToggle;\n const classes = useStyles();\n const { entity } = useEntity();\n\n const defaultRelationAggregation =\n entity.kind === 'User' ? 'aggregated' : 'direct';\n const [getRelationAggregation, setRelationAggregation] = useState(\n relationAggregation ?? defaultRelationAggregation,\n );\n\n useEffect(() => {\n if (!relationAggregation) {\n setRelationAggregation(defaultRelationAggregation);\n }\n }, [setRelationAggregation, defaultRelationAggregation, relationAggregation]);\n\n return (\n <InfoCard\n title=\"Ownership\"\n variant={variant}\n className={classes.card}\n cardClassName={classes.cardContent}\n >\n {!relationsToggle && (\n <List dense>\n <ListItem className={classes.list}>\n <ListItemText className={classes.listItemText} />\n <ListItemSecondaryAction\n className={classes.listItemSecondaryAction}\n >\n Direct Relations\n <Tooltip\n placement=\"top\"\n arrow\n title={`${\n getRelationAggregation === 'direct' ? 'Direct' : 'Aggregated'\n } Relations`}\n >\n <Switch\n color=\"primary\"\n checked={getRelationAggregation !== 'direct'}\n onChange={() => {\n const updatedRelationAggregation =\n getRelationAggregation === 'direct'\n ? 'aggregated'\n : 'direct';\n setRelationAggregation(updatedRelationAggregation);\n }}\n name=\"pin\"\n inputProps={{ 'aria-label': 'Ownership Type Switch' }}\n />\n </Tooltip>\n Aggregated Relations\n </ListItemSecondaryAction>\n </ListItem>\n </List>\n )}\n <ComponentsGrid\n className={classes.grid}\n entity={entity}\n entityLimit={entityLimit}\n relationAggregation={getRelationAggregation}\n entityFilterKind={entityFilterKind}\n />\n </InfoCard>\n );\n};\n"],"names":[],"mappings":";;;;;;;;;;;;;AA6BA,MAAM,SAAA,GAAY,WAAW,CAAU,KAAA,MAAA;AAAA,EACrC,IAAM,EAAA;AAAA,IACJ,SAAW,EAAA;AAAA,GACb;AAAA,EACA,WAAa,EAAA;AAAA,IACX,OAAS,EAAA,MAAA;AAAA,IACT,aAAe,EAAA,QAAA;AAAA,IACf,QAAU,EAAA;AAAA,GACZ;AAAA,EACA,IAAM,EAAA;AAAA,IACJ,CAAC,KAAM,CAAA,WAAA,CAAY,IAAK,CAAA,IAAI,CAAC,GAAG;AAAA,MAC9B,OAAS,EAAA,CAAA,QAAA;AAAA;AACX,GACF;AAAA,EACA,YAAc,EAAA;AAAA,IACZ,CAAC,KAAM,CAAA,WAAA,CAAY,IAAK,CAAA,IAAI,CAAC,GAAG;AAAA,MAC9B,YAAc,EAAA,CAAA;AAAA,MACd,WAAa,EAAA;AAAA;AACf,GACF;AAAA,EACA,uBAAyB,EAAA;AAAA,IACvB,CAAC,KAAM,CAAA,WAAA,CAAY,IAAK,CAAA,IAAI,CAAC,GAAG;AAAA,MAC9B,KAAO,EAAA,MAAA;AAAA,MACP,GAAK,EAAA,MAAA;AAAA,MACL,KAAO,EAAA,MAAA;AAAA,MACP,QAAU,EAAA,UAAA;AAAA,MACV,SAAW,EAAA;AAAA;AACb,GACF;AAAA,EACA,IAAM,EAAA;AAAA,IACJ,SAAW,EAAA,MAAA;AAAA,IACX,SAAW,EAAA;AAAA;AAEf,CAAE,CAAA,CAAA;AAGW,MAAA,aAAA,GAAgB,CAAC,KAQxB,KAAA;A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A;AAAA,YAAA;AAAA,cACC,WAAW,OAAQ,CAAA,uBAAA;AAAA,cACpB,QAAA,EAAA;AAAA,gBAAA,kBAAA;AAAA,gCAEC,GAAA;AAAA,kBAAC,OAAA;AAAA,kBAAA;AAAA,oBACC,SAAU,EAAA,KAAA;AAAA,oBACV,KAAK,EAAA,IAAA;AAAA,oBACL,KAAO,EAAA,CAAA,EACL,sBAA2B,KAAA,QAAA,GAAW,WAAW,YACnD,CAAA,UAAA,CAAA;AAAA,oBAEA,QAAA,kBAAA,GAAA;AAAA,sBAAC,MAAA;AAAA,sBAAA;AAAA,wBACC,KAAM,EAAA,SAAA;AAAA,wBACN,SAAS,sBAA2B,KAAA,QAAA;AAAA,wBACpC,UAAU,MAAM;AACd,0BAAM,MAAA,0BAAA,GACJ,sBAA2B,KAAA,QAAA,GACvB,YACA,GAAA,QAAA;AACN,0BAAA,sBAAA,CAAuB,0BAA0B,CAAA;AAAA,yBACnD;AAAA,wBACA,IAAK,EAAA,KAAA;AAAA,wBACL,UAAA,EAAY,EAAE,YAAA,EAAc,uBAAwB;AAAA;AAAA;AACtD;AAAA,iBACF;AAAA,gBAAU;AAAA;AAAA;AAAA;AAEZ,SAAA,EACF,CACF,EAAA,CAAA;AAAA,wBAEF,GAAA;AAAA,UAAC,cAAA;AAAA,UAAA;AAAA,YACC,WAAW,OAAQ,CAAA,IAAA;AAAA,YACnB,MAAA;AAAA,YACA,WAAA;AAAA,YACA,mBAAqB,EAAA,sBAAA;AAAA,YACrB;AAAA;AAAA;AACF;AAAA;AAAA,GACF;AAEJ;;;;"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { jsx, Fragment, jsxs } from 'react/jsx-runtime';
|
|
1
2
|
import { ANNOTATION_EDIT_URL, RELATION_MEMBER_OF } from '@backstage/catalog-model';
|
|
2
3
|
import { InfoCard, Link, Avatar } from '@backstage/core-components';
|
|
3
4
|
import Box from '@material-ui/core/Box';
|
|
@@ -15,13 +16,15 @@ import EmailIcon from '@material-ui/icons/Email';
|
|
|
15
16
|
import GroupIcon from '@material-ui/icons/Group';
|
|
16
17
|
import { LinksGroup } from '../../Meta/LinksGroup.esm.js';
|
|
17
18
|
import PersonIcon from '@material-ui/icons/Person';
|
|
18
|
-
import React from 'react';
|
|
19
19
|
|
|
20
|
-
const CardTitle = (props) => props.title ? /* @__PURE__ */
|
|
20
|
+
const CardTitle = (props) => props.title ? /* @__PURE__ */ jsxs(Box, { display: "flex", alignItems: "center", children: [
|
|
21
|
+
/* @__PURE__ */ jsx(PersonIcon, { fontSize: "inherit" }),
|
|
22
|
+
/* @__PURE__ */ jsx(Box, { ml: 1, children: props.title })
|
|
23
|
+
] }) : null;
|
|
21
24
|
const UserProfileCard = (props) => {
|
|
22
25
|
const { entity: user } = useEntity();
|
|
23
26
|
if (!user) {
|
|
24
|
-
return /* @__PURE__ */
|
|
27
|
+
return /* @__PURE__ */ jsx(Alert, { severity: "error", children: "User not found" });
|
|
25
28
|
}
|
|
26
29
|
const entityMetadataEditUrl = user.metadata.annotations?.[ANNOTATION_EDIT_URL];
|
|
27
30
|
const {
|
|
@@ -33,30 +36,43 @@ const UserProfileCard = (props) => {
|
|
|
33
36
|
const memberOfRelations = getEntityRelations(user, RELATION_MEMBER_OF, {
|
|
34
37
|
kind: "Group"
|
|
35
38
|
});
|
|
36
|
-
return /* @__PURE__ */
|
|
39
|
+
return /* @__PURE__ */ jsx(
|
|
37
40
|
InfoCard,
|
|
38
41
|
{
|
|
39
|
-
title: /* @__PURE__ */
|
|
42
|
+
title: /* @__PURE__ */ jsx(CardTitle, { title: displayName }),
|
|
40
43
|
subheader: description,
|
|
41
44
|
variant: props.variant,
|
|
42
|
-
action: /* @__PURE__ */
|
|
45
|
+
action: /* @__PURE__ */ jsx(Fragment, { children: entityMetadataEditUrl && /* @__PURE__ */ jsx(
|
|
43
46
|
IconButton,
|
|
44
47
|
{
|
|
45
48
|
"aria-label": "Edit",
|
|
46
49
|
title: "Edit Metadata",
|
|
47
50
|
component: Link,
|
|
48
|
-
to: entityMetadataEditUrl
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
))
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
51
|
+
to: entityMetadataEditUrl,
|
|
52
|
+
children: /* @__PURE__ */ jsx(EditIcon, {})
|
|
53
|
+
}
|
|
54
|
+
) }),
|
|
55
|
+
children: /* @__PURE__ */ jsxs(Grid, { container: true, spacing: 3, alignItems: "flex-start", children: [
|
|
56
|
+
/* @__PURE__ */ jsx(Grid, { item: true, xs: 12, sm: 2, xl: 1, children: /* @__PURE__ */ jsx(Avatar, { displayName, picture: profile?.picture }) }),
|
|
57
|
+
/* @__PURE__ */ jsx(Grid, { item: true, md: 10, xl: 11, children: /* @__PURE__ */ jsxs(List, { children: [
|
|
58
|
+
profile?.email && /* @__PURE__ */ jsxs(ListItem, { children: [
|
|
59
|
+
/* @__PURE__ */ jsx(ListItemIcon, { children: /* @__PURE__ */ jsx(Tooltip, { title: "Email", children: /* @__PURE__ */ jsx(EmailIcon, {}) }) }),
|
|
60
|
+
/* @__PURE__ */ jsx(ListItemText, { children: /* @__PURE__ */ jsx(Link, { to: emailHref ?? "", children: profile.email }) })
|
|
61
|
+
] }),
|
|
62
|
+
/* @__PURE__ */ jsxs(ListItem, { children: [
|
|
63
|
+
/* @__PURE__ */ jsx(ListItemIcon, { children: /* @__PURE__ */ jsx(Tooltip, { title: "Member of", children: /* @__PURE__ */ jsx(GroupIcon, {}) }) }),
|
|
64
|
+
/* @__PURE__ */ jsx(ListItemText, { children: /* @__PURE__ */ jsx(
|
|
65
|
+
EntityRefLinks,
|
|
66
|
+
{
|
|
67
|
+
entityRefs: memberOfRelations,
|
|
68
|
+
defaultKind: "Group"
|
|
69
|
+
}
|
|
70
|
+
) })
|
|
71
|
+
] }),
|
|
72
|
+
props?.showLinks && /* @__PURE__ */ jsx(LinksGroup, { links })
|
|
73
|
+
] }) })
|
|
74
|
+
] })
|
|
75
|
+
}
|
|
60
76
|
);
|
|
61
77
|
};
|
|
62
78
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"UserProfileCard.esm.js","sources":["../../../../../src/components/Cards/User/UserProfileCard/UserProfileCard.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 {\n ANNOTATION_EDIT_URL,\n RELATION_MEMBER_OF,\n UserEntity,\n} from '@backstage/catalog-model';\nimport {\n Avatar,\n InfoCard,\n InfoCardVariants,\n Link,\n} from '@backstage/core-components';\nimport Box from '@material-ui/core/Box';\nimport Grid from '@material-ui/core/Grid';\nimport IconButton from '@material-ui/core/IconButton';\nimport List from '@material-ui/core/List';\nimport ListItem from '@material-ui/core/ListItem';\nimport ListItemIcon from '@material-ui/core/ListItemIcon';\nimport ListItemText from '@material-ui/core/ListItemText';\nimport Tooltip from '@material-ui/core/Tooltip';\nimport {\n EntityRefLinks,\n getEntityRelations,\n useEntity,\n} from '@backstage/plugin-catalog-react';\n\nimport Alert from '@material-ui/lab/Alert';\nimport EditIcon from '@material-ui/icons/Edit';\nimport EmailIcon from '@material-ui/icons/Email';\nimport GroupIcon from '@material-ui/icons/Group';\nimport { LinksGroup } from '../../Meta';\nimport PersonIcon from '@material-ui/icons/Person';\
|
|
1
|
+
{"version":3,"file":"UserProfileCard.esm.js","sources":["../../../../../src/components/Cards/User/UserProfileCard/UserProfileCard.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 {\n ANNOTATION_EDIT_URL,\n RELATION_MEMBER_OF,\n UserEntity,\n} from '@backstage/catalog-model';\nimport {\n Avatar,\n InfoCard,\n InfoCardVariants,\n Link,\n} from '@backstage/core-components';\nimport Box from '@material-ui/core/Box';\nimport Grid from '@material-ui/core/Grid';\nimport IconButton from '@material-ui/core/IconButton';\nimport List from '@material-ui/core/List';\nimport ListItem from '@material-ui/core/ListItem';\nimport ListItemIcon from '@material-ui/core/ListItemIcon';\nimport ListItemText from '@material-ui/core/ListItemText';\nimport Tooltip from '@material-ui/core/Tooltip';\nimport {\n EntityRefLinks,\n getEntityRelations,\n useEntity,\n} from '@backstage/plugin-catalog-react';\n\nimport Alert from '@material-ui/lab/Alert';\nimport EditIcon from '@material-ui/icons/Edit';\nimport EmailIcon from '@material-ui/icons/Email';\nimport GroupIcon from '@material-ui/icons/Group';\nimport { LinksGroup } from '../../Meta';\nimport PersonIcon from '@material-ui/icons/Person';\n\nconst CardTitle = (props: { title?: string }) =>\n props.title ? (\n <Box display=\"flex\" alignItems=\"center\">\n <PersonIcon fontSize=\"inherit\" />\n <Box ml={1}>{props.title}</Box>\n </Box>\n ) : null;\n\n/** @public */\nexport const UserProfileCard = (props: {\n variant?: InfoCardVariants;\n showLinks?: boolean;\n}) => {\n const { entity: user } = useEntity<UserEntity>();\n if (!user) {\n return <Alert severity=\"error\">User not found</Alert>;\n }\n\n const entityMetadataEditUrl =\n user.metadata.annotations?.[ANNOTATION_EDIT_URL];\n\n const {\n metadata: { name: metaName, description, links },\n spec: { profile },\n } = user;\n const displayName = profile?.displayName ?? metaName;\n const emailHref = profile?.email ? `mailto:${profile.email}` : undefined;\n const memberOfRelations = getEntityRelations(user, RELATION_MEMBER_OF, {\n kind: 'Group',\n });\n\n return (\n <InfoCard\n title={<CardTitle title={displayName} />}\n subheader={description}\n variant={props.variant}\n action={\n <>\n {entityMetadataEditUrl && (\n <IconButton\n aria-label=\"Edit\"\n title=\"Edit Metadata\"\n component={Link}\n to={entityMetadataEditUrl}\n >\n <EditIcon />\n </IconButton>\n )}\n </>\n }\n >\n <Grid container spacing={3} alignItems=\"flex-start\">\n <Grid item xs={12} sm={2} xl={1}>\n <Avatar displayName={displayName} picture={profile?.picture} />\n </Grid>\n\n <Grid item md={10} xl={11}>\n <List>\n {profile?.email && (\n <ListItem>\n <ListItemIcon>\n <Tooltip title=\"Email\">\n <EmailIcon />\n </Tooltip>\n </ListItemIcon>\n <ListItemText>\n <Link to={emailHref ?? ''}>{profile.email}</Link>\n </ListItemText>\n </ListItem>\n )}\n\n <ListItem>\n <ListItemIcon>\n <Tooltip title=\"Member of\">\n <GroupIcon />\n </Tooltip>\n </ListItemIcon>\n <ListItemText>\n <EntityRefLinks\n entityRefs={memberOfRelations}\n defaultKind=\"Group\"\n />\n </ListItemText>\n </ListItem>\n\n {props?.showLinks && <LinksGroup links={links} />}\n </List>\n </Grid>\n </Grid>\n </InfoCard>\n );\n};\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;AAgDA,MAAM,SAAA,GAAY,CAAC,KAAA,KACjB,KAAM,CAAA,KAAA,wBACH,GAAI,EAAA,EAAA,OAAA,EAAQ,MAAO,EAAA,UAAA,EAAW,QAC7B,EAAA,QAAA,EAAA;AAAA,kBAAC,GAAA,CAAA,UAAA,EAAA,EAAW,UAAS,SAAU,EAAA,CAAA;AAAA,kBAC9B,GAAA,CAAA,GAAA,EAAA,EAAI,EAAI,EAAA,CAAA,EAAI,gBAAM,KAAM,EAAA;AAAA,CAAA,EAC3B,CACE,GAAA,IAAA;AAGO,MAAA,eAAA,GAAkB,CAAC,KAG1B,KA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CAAA;AAAA,UAEC,KAAO,EAAA,SAAA,oBAAc,GAAA,CAAA,UAAA,EAAA,EAAW,KAAc,EAAA;AAAA,SAAA,EACjD,CACF,EAAA;AAAA,OACF,EAAA;AAAA;AAAA,GACF;AAEJ;;;;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { getCompoundEntityRef, DEFAULT_NAMESPACE, stringifyEntityRef } from '@backstage/catalog-model';
|
|
3
3
|
import { SidebarItem, SidebarSubmenu, SidebarSubmenuItem } from '@backstage/core-components';
|
|
4
4
|
import { useApi, identityApiRef, useRouteRef } from '@backstage/core-plugin-api';
|
|
@@ -30,7 +30,7 @@ const MyGroupsSidebarItem = (props) => {
|
|
|
30
30
|
}
|
|
31
31
|
if (groups.length === 1) {
|
|
32
32
|
const group = groups[0];
|
|
33
|
-
return /* @__PURE__ */
|
|
33
|
+
return /* @__PURE__ */ jsx(
|
|
34
34
|
SidebarItem,
|
|
35
35
|
{
|
|
36
36
|
text: singularTitle,
|
|
@@ -39,19 +39,19 @@ const MyGroupsSidebarItem = (props) => {
|
|
|
39
39
|
}
|
|
40
40
|
);
|
|
41
41
|
}
|
|
42
|
-
return /* @__PURE__ */
|
|
42
|
+
return /* @__PURE__ */ jsx(SidebarItem, { icon, text: pluralTitle, children: /* @__PURE__ */ jsx(SidebarSubmenu, { title: pluralTitle, children: groups?.map((group) => {
|
|
43
43
|
const entityDisplayName = entityPresentationApi.forEntity(group);
|
|
44
|
-
return /* @__PURE__ */
|
|
44
|
+
return /* @__PURE__ */ jsx(
|
|
45
45
|
SidebarSubmenuItem,
|
|
46
46
|
{
|
|
47
47
|
title: entityDisplayName.snapshot.primaryTitle,
|
|
48
48
|
subtitle: group.metadata.namespace !== DEFAULT_NAMESPACE ? group.metadata.namespace : void 0,
|
|
49
49
|
to: catalogEntityRoute(getCompoundEntityRef(group)),
|
|
50
|
-
icon
|
|
51
|
-
|
|
52
|
-
|
|
50
|
+
icon
|
|
51
|
+
},
|
|
52
|
+
stringifyEntityRef(group)
|
|
53
53
|
);
|
|
54
|
-
})));
|
|
54
|
+
}) }) });
|
|
55
55
|
};
|
|
56
56
|
|
|
57
57
|
export { MyGroupsSidebarItem };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MyGroupsSidebarItem.esm.js","sources":["../../../src/components/MyGroupsSidebarItem/MyGroupsSidebarItem.tsx"],"sourcesContent":["/*\n * Copyright 2022 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport
|
|
1
|
+
{"version":3,"file":"MyGroupsSidebarItem.esm.js","sources":["../../../src/components/MyGroupsSidebarItem/MyGroupsSidebarItem.tsx"],"sourcesContent":["/*\n * Copyright 2022 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 DEFAULT_NAMESPACE,\n stringifyEntityRef,\n} from '@backstage/catalog-model';\nimport {\n SidebarItem,\n SidebarSubmenu,\n SidebarSubmenuItem,\n} from '@backstage/core-components';\nimport {\n IconComponent,\n identityApiRef,\n useApi,\n useRouteRef,\n} from '@backstage/core-plugin-api';\nimport useAsync from 'react-use/esm/useAsync';\nimport {\n catalogApiRef,\n CatalogApi,\n entityRouteRef,\n} from '@backstage/plugin-catalog-react';\nimport { getCompoundEntityRef } from '@backstage/catalog-model';\n\nimport { entityPresentationApiRef } from '@backstage/plugin-catalog-react';\n\n/**\n * MyGroupsSidebarItem can be added to your sidebar providing quick access to groups the logged in user is a member of\n *\n * @public\n */\nexport const MyGroupsSidebarItem = (props: {\n singularTitle: string;\n pluralTitle: string;\n icon: IconComponent;\n filter?: Record<string, string | symbol | (string | symbol)[]>;\n}) => {\n const { singularTitle, pluralTitle, icon, filter } = props;\n\n const identityApi = useApi(identityApiRef);\n const catalogApi: CatalogApi = useApi(catalogApiRef);\n const catalogEntityRoute = useRouteRef(entityRouteRef);\n const entityPresentationApi = useApi(entityPresentationApiRef);\n\n const { value: groups } = useAsync(async () => {\n const profile = await identityApi.getBackstageIdentity();\n\n const response = await catalogApi.getEntities({\n filter: [\n {\n kind: 'group',\n 'relations.hasMember': profile.userEntityRef,\n ...(filter ?? {}),\n },\n ],\n fields: ['metadata', 'kind'],\n });\n return response.items;\n }, []);\n\n if (!groups?.length) {\n return null;\n }\n\n // Only member of one group\n if (groups.length === 1) {\n const group = groups[0];\n return (\n <SidebarItem\n text={singularTitle}\n to={catalogEntityRoute(getCompoundEntityRef(group))}\n icon={icon}\n />\n );\n }\n\n // Member of more than one group\n return (\n <SidebarItem icon={icon} text={pluralTitle}>\n <SidebarSubmenu title={pluralTitle}>\n {groups?.map(group => {\n const entityDisplayName = entityPresentationApi.forEntity(group);\n return (\n <SidebarSubmenuItem\n title={entityDisplayName.snapshot.primaryTitle}\n subtitle={\n group.metadata.namespace !== DEFAULT_NAMESPACE\n ? group.metadata.namespace\n : undefined\n }\n to={catalogEntityRoute(getCompoundEntityRef(group))}\n icon={icon}\n key={stringifyEntityRef(group)}\n />\n );\n })}\n </SidebarSubmenu>\n </SidebarItem>\n );\n};\n"],"names":[],"mappings":";;;;;;;AA8Ca,MAAA,mBAAA,GAAsB,CAAC,KAK9B,KAAA;AACJ,EAAA,MAAM,EAAE,a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