@backstage/plugin-home 0.7.0-next.2 → 0.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +44 -0
- package/alpha/package.json +1 -1
- package/dist/alpha.esm.js +1 -1
- package/dist/esm/{Content-5578e5a3.esm.js → Content-Quo42yad.esm.js} +13 -5
- package/dist/esm/Content-Quo42yad.esm.js.map +1 -0
- package/dist/esm/{RecentlyVisited-04568b67.esm.js → RecentlyVisited-qOUgoCVu.esm.js} +17 -9
- package/dist/esm/{RecentlyVisited-04568b67.esm.js.map → RecentlyVisited-qOUgoCVu.esm.js.map} +1 -1
- package/dist/esm/{TopVisited-1659adf6.esm.js → TopVisited-B_KhSJit.esm.js} +17 -9
- package/dist/esm/{TopVisited-1659adf6.esm.js.map → TopVisited-B_KhSJit.esm.js.map} +1 -1
- package/dist/esm/{VisitListener-7a513ef0.esm.js → VisitListener-dDLtFiIW.esm.js} +9 -3
- package/dist/esm/VisitListener-dDLtFiIW.esm.js.map +1 -0
- package/dist/esm/{index-c91caa6e.esm.js → index-BMySa_Iw.esm.js} +4 -3
- package/dist/esm/{index-c91caa6e.esm.js.map → index-BMySa_Iw.esm.js.map} +1 -1
- package/dist/esm/{index-3155d776.esm.js → index-BNfZuEhy.esm.js} +8 -2
- package/dist/esm/index-BNfZuEhy.esm.js.map +1 -0
- package/dist/esm/{index-59fc0760.esm.js → index-BvvJGS3L.esm.js} +1 -1
- package/dist/esm/{index-59fc0760.esm.js.map → index-BvvJGS3L.esm.js.map} +1 -1
- package/dist/esm/{index-abfba912.esm.js → index-Bzg5mDMo.esm.js} +10 -4
- package/dist/esm/{index-abfba912.esm.js.map → index-Bzg5mDMo.esm.js.map} +1 -1
- package/dist/esm/{index-40d9ffac.esm.js → index-CeXFfTX2.esm.js} +5 -2
- package/dist/esm/index-CeXFfTX2.esm.js.map +1 -0
- package/dist/esm/{index-21ffb782.esm.js → index-D7JTE1IL.esm.js} +4 -3
- package/dist/esm/index-D7JTE1IL.esm.js.map +1 -0
- package/dist/esm/{index-4517c5bc.esm.js → index-Dg9lslkf.esm.js} +7 -2
- package/dist/esm/index-Dg9lslkf.esm.js.map +1 -0
- package/dist/esm/{index-476343c1.esm.js → index-FqRX6ImF.esm.js} +2 -2
- package/dist/esm/index-FqRX6ImF.esm.js.map +1 -0
- package/dist/esm/{index-6d94aeff.esm.js → index-SfHoDIi1.esm.js} +11 -3
- package/dist/esm/index-SfHoDIi1.esm.js.map +1 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.esm.js +24 -18
- package/dist/index.esm.js.map +1 -1
- package/package.json +15 -15
- package/dist/esm/Content-5578e5a3.esm.js.map +0 -1
- package/dist/esm/VisitListener-7a513ef0.esm.js.map +0 -1
- package/dist/esm/index-21ffb782.esm.js.map +0 -1
- package/dist/esm/index-3155d776.esm.js.map +0 -1
- package/dist/esm/index-40d9ffac.esm.js.map +0 -1
- package/dist/esm/index-4517c5bc.esm.js.map +0 -1
- package/dist/esm/index-476343c1.esm.js.map +0 -1
- package/dist/esm/index-6d94aeff.esm.js.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index-BNfZuEhy.esm.js","sources":["../../src/componentRenderers/ComponentAccordion.tsx","../../src/componentRenderers/ComponentTabs/ComponentTabs.tsx","../../src/componentRenderers/ComponentTabs/ComponentTab.tsx"],"sourcesContent":["/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React from 'react';\nimport { SettingsModal } from '@backstage/plugin-home-react';\nimport Accordion from '@material-ui/core/Accordion';\nimport AccordionDetails from '@material-ui/core/AccordionDetails';\nimport AccordionSummary from '@material-ui/core/AccordionSummary';\nimport Typography from '@material-ui/core/Typography';\nimport IconButton from '@material-ui/core/IconButton';\nimport { Theme } from '@material-ui/core/styles';\nimport { makeStyles } from '@material-ui/core/styles';\nimport ExpandMoreIcon from '@material-ui/icons/ExpandMore';\nimport SettingsIcon from '@material-ui/icons/Settings';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n settingsIconButton: {\n padding: theme.spacing(0, 1, 0, 0),\n },\n contentContainer: {\n width: '100%',\n },\n}));\n\nexport const ComponentAccordion = (props: {\n title?: string;\n expanded?: boolean;\n Content: () => JSX.Element;\n Actions?: () => JSX.Element;\n Settings?: () => JSX.Element;\n ContextProvider?: (props: any) => JSX.Element;\n}) => {\n const {\n title,\n expanded = false,\n Content,\n Actions,\n Settings,\n ContextProvider,\n ...childProps\n } = props;\n\n const classes = useStyles();\n const [settingsIsExpanded, setSettingsIsExpanded] = React.useState(false);\n const [isExpanded, setIsExpanded] = React.useState(expanded);\n\n const handleOpenSettings = (e: any) => {\n e.stopPropagation();\n setSettingsIsExpanded(prevState => !prevState);\n };\n\n const innerContent = (\n <>\n {Settings && (\n <SettingsModal\n open={settingsIsExpanded}\n close={() => setSettingsIsExpanded(false)}\n componentName={title}\n >\n <Settings />\n </SettingsModal>\n )}\n <Accordion\n expanded={isExpanded}\n onChange={(_e: any, expandedValue: boolean) =>\n setIsExpanded(expandedValue)\n }\n >\n <AccordionSummary expandIcon={<ExpandMoreIcon />}>\n {Settings && (\n <IconButton\n onClick={handleOpenSettings}\n className={classes.settingsIconButton}\n >\n <SettingsIcon />\n </IconButton>\n )}\n <Typography>{title}</Typography>\n </AccordionSummary>\n <AccordionDetails>\n <div className={classes.contentContainer}>\n <Content />\n {Actions && <Actions />}\n </div>\n </AccordionDetails>\n </Accordion>\n </>\n );\n\n return ContextProvider ? (\n <ContextProvider {...childProps}>{innerContent}</ContextProvider>\n ) : (\n innerContent\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 Tabs from '@material-ui/core/Tabs';\nimport Tab from '@material-ui/core/Tab';\nimport { InfoCard } from '@backstage/core-components';\n\ntype TabType = {\n label: string;\n Component: () => JSX.Element;\n};\n\nexport const ComponentTabs = (props: { title: string; tabs: TabType[] }) => {\n const { title, tabs } = props;\n\n const [value, setValue] = React.useState(0);\n\n const handleChange = (_event: any, newValue: number) => {\n setValue(newValue);\n };\n\n return (\n <InfoCard title={title}>\n <Tabs value={value} onChange={handleChange}>\n {tabs.map(t => (\n <Tab key={t.label} label={t.label} />\n ))}\n </Tabs>\n {tabs.map(({ Component }, idx) => (\n <div\n key={idx}\n {...(idx !== value ? { style: { display: 'none' } } : {})}\n >\n <Component />\n </div>\n ))}\n </InfoCard>\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';\n\nexport const ComponentTab = (props: {\n title: string;\n Content: () => JSX.Element;\n ContextProvider?: (props: any) => JSX.Element;\n}) => {\n const { title, Content, ContextProvider, ...childProps } = props;\n\n return ContextProvider ? (\n <ContextProvider {...childProps}>\n <Content />\n </Cont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sx"],"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 { HeaderLabel } from '@backstage/core-components';\n\nconst timeFormat: Intl.DateTimeFormatOptions = {\n hour: '2-digit',\n minute: '2-digit',\n};\n\ntype TimeObj = {\n label: string;\n value: string;\n dateTime: string;\n};\n\n/** @public */\nexport type ClockConfig = {\n label: string;\n timeZone: string;\n};\n\nfunction getTimes(\n clockConfigs: ClockConfig[],\n customTimeFormat?: Intl.DateTimeFormatOptions,\n) {\n const d = new Date();\n const lang = window.navigator.language;\n\n const clocks: TimeObj[] = [];\n\n if (!clockConfigs) {\n return clocks;\n }\n\n for (const clockConfig of clockConfigs) {\n let label = clockConfig.label;\n\n const options: Intl.DateTimeFormatOptions = {\n timeZone: clockConfig.timeZone,\n ...(customTimeFormat ?? timeFormat),\n };\n\n try {\n new Date().toLocaleString(lang, options);\n } catch (e) {\n // eslint-disable-next-line no-console\n console.warn(\n `The timezone ${options.timeZone} is invalid. Defaulting to GMT`,\n );\n options.timeZone = 'GMT';\n label = 'GMT';\n }\n\n const value = d.toLocaleTimeString(lang, options);\n const dateTime = d.toLocaleTimeString(lang, {\n timeZone: options.timeZone,\n hour: '2-digit',\n minute: '2-digit',\n hour12: false,\n });\n clocks.push({ label, value, dateTime });\n }\n\n return clocks;\n}\n\n/**\n * A component to display a configurable list of clocks for various time zones.\n *\n * @example\n * Here's a simple example:\n * ```\n * // This will give you a clock for the time zone that Stockholm is in\n * // you can add more than one but keep in mind space may be limited\n * const clockConfigs: ClockConfig[] = [\n * {\n * label: 'STO',\n * timeZone: 'Europe/Stockholm',\n * },\n * ];\n *\n * // Setting hour12 to false will make all the clocks show in the 24hr format\n * const timeFormat: Intl.DateTimeFormatOptions = {\n * hour: '2-digit',\n * minute: '2-digit',\n * hour12: false,\n * };\n *\n * // Here is the component in use:\n * <HeaderWorldClock\n * clockConfigs={clockConfigs}\n * customTimeFormat={timeFormat}\n * />\n * ```\n *\n * @public\n */\nexport const HeaderWorldClock = (props: {\n clockConfigs: ClockConfig[];\n customTimeFormat?: Intl.DateTimeFormatOptions;\n}) => {\n const { clockConfigs, customTimeFormat } = props;\n\n const defaultTimes: TimeObj[] = [];\n const [clocks, setTimes] = React.useState(defaultTimes);\n\n React.useEffect(() => {\n setTimes(getTimes(clockConfigs, customTimeFormat));\n\n const intervalId = setInterval(() => {\n setTimes(getTimes(clockConfigs, customTimeFormat));\n }, 1000);\n\n return () => {\n clearInterval(intervalId);\n };\n }, [clockConfigs, customTimeFormat]);\n\n if (clocks.length !== 0) {\n return (\n <>\n {clocks.map(clock => (\n <HeaderLabel\n key={clock.label}\n label={clock.label}\n value={<time dateTime={clock.dateTime}>{clock.value}</time>}\n />\n ))}\n </>\n );\n }\n return null;\n};\n"],"names":[],"mappings":";;;AAmBA,MAAM,UAAyC,GAAA;AAAA,EAC7C,IAAM,EAAA,SAAA;AAAA,EACN,MAAQ,EAAA,SAAA;AACV,CAAA,CAAA;AAcA,SAAS,QAAA,CACP,cACA,gBACA,EAAA;AACA,EAAM,MAAA,CAAA,uBAAQ,IAAK,EAAA,CAAA;AACnB,EAAM,MAAA,IAAA,GAAO,OAAO,SAAU,CAAA,QAAA,CAAA;AAE9B,EAAA,MAAM,SAAoB,EAAC,CAAA;AAE3B,EAAA,IAAI,CAAC,YAAc,EAAA;AACjB,IAAO,OAAA,MAAA,CAAA;AAAA,GACT;AAEA,EAAA,KAAA,MAAW,eAAe,YAAc,EAAA;AACtC,IAAA,IAAI,QAAQ,WAAY,CAAA,KAAA,CAAA;AAExB,IAAA,MAAM,OAAs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c,EAAA,gBAAgB,CAAC,CAAA,CAAA;AAEjD,IAAM,MAAA,UAAA,GAAa,YAAY,MAAM;AACnC,MAAS,QAAA,CAAA,QAAA,CAAS,YAAc,EAAA,gBAAgB,CAAC,CAAA,CAAA;AAAA,OAChD,GAAI,CAAA,CAAA;AAEP,IAAA,OAAO,MAAM;AACX,MAAA,aAAA,CAAc,UAAU,CAAA,CAAA;AAAA,KAC1B,CAAA;AAAA,GACC,EAAA,CAAC,YAAc,EAAA,gBAAgB,CAAC,CAAA,CAAA;AAEnC,EAAI,IAAA,MAAA,CAAO,WAAW,CAAG,EAAA;AACvB,IACE,uBAAA,KAAA,CAAA,aAAA,CAAA,KAAA,CAAA,QAAA,EAAA,IAAA,EACG,MAAO,CAAA,GAAA,CAAI,CACV,KAAA,qBAAA,KAAA,CAAA,aAAA;AAAA,MAAC,WAAA;AAAA,MAAA;AAAA,QACC,KAAK,KAAM,CAAA,KAAA;AAAA,QACX,OAAO,KAAM,CAAA,KAAA;AAAA,QACb,uBAAQ,KAAA,CAAA,aAAA,CAAA,MAAA,EAAA,EAAK,UAAU,KAAM,CAAA,QAAA,EAAA,EAAW,MAAM,KAAM,CAAA;AAAA,OAAA;AAAA,KAEvD,CACH,CAAA,CAAA;AAAA,GAEJ;AACA,EAAO,OAAA,IAAA,CAAA;AACT;;;;"}
|
|
@@ -1,15 +1,19 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { useOutlet } from 'react-router-dom';
|
|
3
|
-
export { C as CustomHomepageGrid, V as VisitListener } from './VisitListener-
|
|
3
|
+
export { C as CustomHomepageGrid, V as VisitListener } from './VisitListener-dDLtFiIW.esm.js';
|
|
4
4
|
import 'react-grid-layout';
|
|
5
5
|
import '@backstage/core-plugin-api';
|
|
6
6
|
import 'react-grid-layout/css/styles.css';
|
|
7
7
|
import 'react-resizable/css/styles.css';
|
|
8
|
-
import '@material-ui/core';
|
|
8
|
+
import '@material-ui/core/Dialog';
|
|
9
|
+
import '@material-ui/core/styles';
|
|
9
10
|
import 'lodash';
|
|
10
|
-
import 'react-use/
|
|
11
|
+
import 'react-use/esm/useObservable';
|
|
11
12
|
import '@backstage/core-components';
|
|
12
13
|
import '@material-ui/core/Typography';
|
|
14
|
+
import '@material-ui/core/DialogContent';
|
|
15
|
+
import '@material-ui/core/Grid';
|
|
16
|
+
import '@material-ui/core/Tooltip';
|
|
13
17
|
import '@material-ui/core/IconButton';
|
|
14
18
|
import '@material-ui/icons/Settings';
|
|
15
19
|
import '@material-ui/icons/Delete';
|
|
@@ -18,6 +22,8 @@ import '@rjsf/material-ui';
|
|
|
18
22
|
import '@rjsf/validator-ajv8';
|
|
19
23
|
import '@material-ui/core/List';
|
|
20
24
|
import '@material-ui/core/ListItem';
|
|
25
|
+
import '@material-ui/core/DialogTitle';
|
|
26
|
+
import '@material-ui/core/ListItemAvatar';
|
|
21
27
|
import '@material-ui/icons/Add';
|
|
22
28
|
import '@material-ui/core/ListItemText';
|
|
23
29
|
import '@material-ui/core/Button';
|
|
@@ -36,4 +42,4 @@ const HomepageCompositionRoot = (props) => {
|
|
|
36
42
|
};
|
|
37
43
|
|
|
38
44
|
export { HomepageCompositionRoot };
|
|
39
|
-
//# sourceMappingURL=index-
|
|
45
|
+
//# sourceMappingURL=index-Bzg5mDMo.esm.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index-
|
|
1
|
+
{"version":3,"file":"index-Bzg5mDMo.esm.js","sources":["../../src/components/HomepageCompositionRoot.tsx"],"sourcesContent":["/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React, { ReactNode } from 'react';\nimport { useOutlet } from 'react-router-dom';\n\nexport const HomepageCompositionRoot = (props: {\n title?: string;\n children?: ReactNode;\n}) => {\n const outlet = useOutlet();\n const children = props.children ?? outlet;\n return <>{children}</>;\n};\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAmBa,MAAA,uBAAA,GAA0B,CAAC,KAGlC,KAAA;AAtBN,EAAA,IAAA,EAAA,CAAA;AAuBE,EAAA,MAAM,SAAS,SAAU,EAAA,CAAA;AACzB,EAAM,MAAA,QAAA,GAAA,CAAW,EAAM,GAAA,KAAA,CAAA,QAAA,KAAN,IAAkB,GAAA,EAAA,GAAA,MAAA,CAAA;AACnC,EAAA,iEAAU,QAAS,CAAA,CAAA;AACrB;;;;"}
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
import { Link } from '@backstage/core-components';
|
|
2
|
-
import
|
|
2
|
+
import List from '@material-ui/core/List';
|
|
3
|
+
import ListItemIcon from '@material-ui/core/ListItemIcon';
|
|
4
|
+
import ListItemText from '@material-ui/core/ListItemText';
|
|
5
|
+
import { makeStyles } from '@material-ui/core/styles';
|
|
3
6
|
import React, { createContext } from 'react';
|
|
4
7
|
|
|
5
8
|
const Context = createContext(void 0);
|
|
@@ -58,4 +61,4 @@ const Content = (props) => {
|
|
|
58
61
|
};
|
|
59
62
|
|
|
60
63
|
export { Content, ContextProvider };
|
|
61
|
-
//# sourceMappingURL=index-
|
|
64
|
+
//# sourceMappingURL=index-CeXFfTX2.esm.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index-CeXFfTX2.esm.js","sources":["../../src/homePageComponents/Toolkit/Context.tsx","../../src/homePageComponents/Toolkit/Content.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 React, { createContext } from 'react';\n\n/** @public */\nexport type Tool = {\n label: string;\n url: string;\n icon: React.ReactNode;\n};\n\ntype ToolkitContextValue = {\n tools: Tool[];\n};\n\nconst Context = createContext<ToolkitContextValue | undefined>(undefined);\n\nexport const ContextProvider = (props: {\n children: JSX.Element;\n tools: Tool[];\n}) => {\n const { children, tools } = props;\n\n const [toolsValue, _setTools] = React.useState(tools);\n\n const value: ToolkitContextValue = {\n tools: toolsValue,\n };\n\n return <Context.Provider value={value}>{children}</Context.Provider>;\n};\n\nexport const useToolkit = () => {\n const value = React.useContext(Context);\n return value;\n};\n\nexport default Context;\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 { Link } from '@backstage/core-components';\nimport List from '@material-ui/core/List';\nimport ListItemIcon from '@material-ui/core/ListItemIcon';\nimport ListItemText from '@material-ui/core/ListItemText';\nimport { makeStyles } from '@material-ui/core/styles';\nimport React from 'react';\nimport { useToolkit, Tool } from './Context';\n\nconst useStyles = makeStyles(theme => ({\n toolkit: {\n display: 'flex',\n flexWrap: 'wrap',\n textAlign: 'center',\n },\n tool: {\n margin: theme.spacing(0.5, 1),\n },\n label: {\n marginTop: theme.spacing(1),\n width: '72px',\n fontSize: '0.9em',\n lineHeight: '1.25',\n overflowWrap: 'break-word',\n color: theme.palette.text.secondary,\n },\n icon: {\n width: '64px',\n height: '64px',\n borderRadius: '50px',\n justifyContent: 'center',\n alignItems: 'center',\n boxShadow: theme.shadows[1],\n backgroundColor: theme.palette.background.default,\n },\n}));\n\n/**\n * A component to display a list of tools for the user.\n *\n * @public\n */\nexport const Content = (props: ToolkitContentProps) => {\n const classes = useStyles();\n const toolkit = useToolkit();\n const tools = toolkit?.tools ?? props.tools;\n\n return (\n <List className={classes.toolkit}>\n {tools.map((tool: Tool) => (\n <Link key={tool.url} to={tool.url} className={classes.tool}>\n <ListItemIcon className={classes.icon}>{tool.icon}</ListItemIcon>\n <ListItemText\n secondaryTypographyProps={{ className: classes.label }}\n secondary={tool.label}\n />\n </Link>\n ))}\n </List>\n );\n};\n\n/**\n * Props for Toolkit Content component.\n *\n * @public\n */\nexport type ToolkitContentProps = {\n tools: Tool[];\n};\n"],"names":[],"mappings":";;;;;;;AA6BA,MAAM,OAAA,GAAU,cAA+C,KAAS,CAAA,CAAA,CAAA;AAE3D,MAAA,eAAA,GAAkB,CAAC,KAG1B,KAAA;AACJ,EAAM,MAAA,EAAE,QAAU,EAAA,KAAA,EAAU,GAAA,KAAA,CAAA;AAE5B,EAAA,MAAM,CAAC,UAAY,EAAA,SAAS,CAAI,GAAA,KAAA,CAAM,SAAS,KAAK,CAAA,CAAA;AAEpD,EAAA,MAAM,KAA6B,GAAA;AAAA,IACjC,KAAO,EAAA,UAAA;AAAA,GACT,CAAA;AAEA,EAAA,uBAAQ,KAAA,CAAA,aAAA,CAAA,OAAA,CAAQ,QAAR,EAAA,EAAiB,SAAe,QAAS,CAAA,CAAA;AACnD,EAAA;AAEO,MAAM,aAAa,MAAM;AAC9B,EAAM,MAAA,KAAA,GAAQ,KAAM,CAAA,UAAA,CAAW,OAAO,CAAA,CAAA;AACtC,EAAO,OAAA,KAAA,CAAA;AACT,CAAA;;ACzBA,MAAM,SAAA,GAAY,WAAW,CAAU,KAAA,MAAA;AAAA,EACrC,OAAS,EAAA;AAAA,IACP,OAAS,EAAA,MAAA;AA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ACtB,KAAM,CAAA,GAAA,CAAI,CAAC,IAAA,qBACT,KAAA,CAAA,aAAA,CAAA,IAAA,EAAA,EAAK,GAAK,EAAA,IAAA,CAAK,GAAK,EAAA,EAAA,EAAI,IAAK,CAAA,GAAA,EAAK,SAAW,EAAA,OAAA,CAAQ,IACpD,EAAA,kBAAA,KAAA,CAAA,aAAA,CAAC,YAAa,EAAA,EAAA,SAAA,EAAW,OAAQ,CAAA,IAAA,EAAA,EAAO,IAAK,CAAA,IAAK,CAClD,kBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,YAAA;AAAA,IAAA;AAAA,MACC,wBAA0B,EAAA,EAAE,SAAW,EAAA,OAAA,CAAQ,KAAM,EAAA;AAAA,MACrD,WAAW,IAAK,CAAA,KAAA;AAAA,KAAA;AAAA,GAEpB,CACD,CACH,CAAA,CAAA;AAEJ;;;;"}
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import useAsync from 'react-use/
|
|
2
|
+
import useAsync from 'react-use/esm/useAsync';
|
|
3
3
|
import { Progress, ErrorPanel, Link, EmptyState, LinkButton } from '@backstage/core-components';
|
|
4
4
|
import { catalogApiRef, EntityDisplayName } from '@backstage/plugin-catalog-react';
|
|
5
5
|
import { useApi } from '@backstage/core-plugin-api';
|
|
6
|
-
import
|
|
6
|
+
import Typography from '@material-ui/core/Typography';
|
|
7
|
+
import { makeStyles } from '@material-ui/core/styles';
|
|
7
8
|
import { stringifyEntityRef } from '@backstage/catalog-model';
|
|
8
9
|
|
|
9
10
|
const useStyles = makeStyles(
|
|
@@ -93,4 +94,4 @@ const Content = (props) => {
|
|
|
93
94
|
};
|
|
94
95
|
|
|
95
96
|
export { Content };
|
|
96
|
-
//# sourceMappingURL=index-
|
|
97
|
+
//# sourceMappingURL=index-D7JTE1IL.esm.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index-D7JTE1IL.esm.js","sources":["../../src/homePageComponents/FeaturedDocsCard/Content.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 React from 'react';\nimport useAsync from 'react-use/esm/useAsync';\nimport {\n LinkButton,\n EmptyState,\n Link,\n Progress,\n ErrorPanel,\n} from '@backstage/core-components';\nimport {\n catalogApiRef,\n CatalogApi,\n EntityDisplayName,\n} from '@backstage/plugin-catalog-react';\nimport { useApi } from '@backstage/core-plugin-api';\nimport { EntityFilterQuery } from '@backstage/catalog-client';\n\nimport Typography from '@material-ui/core/Typography';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { stringifyEntityRef } from '@backstage/catalog-model';\n\n/**\n * Props customizing the <FeaturedDocsCard/> component.\n *\n * @public\n */\nexport type FeaturedDocsCardProps = {\n /** The entity filter used to display only the intended item/s */\n filter: EntityFilterQuery;\n /** An optional ReactNode for empty states */\n emptyState?: React.JSX.Element;\n /** An optional linkDestination to set for the Featured Doc */\n linkDestination?: string;\n /** An optional limit to set for link destination */\n responseLimit?: number;\n /** An optional string to customize sublink text */\n subLinkText?: string;\n};\n\nconst useStyles = makeStyles(\n theme => ({\n docDescription: {\n fontSize: theme.typography.body1.fontSize,\n fontWeight: theme.typography.body1.fontWeight,\n marginBottom: theme.spacing(2),\n marginTop: theme.spacing(2),\n },\n docSubLink: {\n fontSize: theme.typography.subtitle1.fontSize,\n fontWeight: theme.typography.subtitle1.fontWeight,\n lineHeight: theme.typography.subtitle1.lineHeight,\n },\n docsTitleLink: {\n fontSize: theme.typography.h6.fontSize,\n fontWeight: theme.typography.h6.fontWeight,\n lineHeight: theme.typography.h6.lineHeight,\n },\n }),\n { name: 'HomeFeaturedDocsCard' },\n);\n\n/**\n * A component to display specific Featured Docs.\n *\n * @public\n */\nexport const Content = (props: FeaturedDocsCardProps): JSX.Element => {\n const { emptyState, filter, linkDestination, responseLimit, subLinkText } =\n props;\n const linkText = subLinkText || 'LEARN MORE';\n const styles = useStyles();\n const catalogApi: CatalogApi = useApi(catalogApiRef);\n const {\n value: entities,\n loading,\n error,\n } = useAsync(async () => {\n const response = await catalogApi.getEntities({\n filter: filter,\n limit: responseLimit || 10,\n });\n return response.items;\n });\n\n if (loading) {\n return <Progress />;\n }\n if (error) {\n return <ErrorPanel error={error} />;\n }\n\n return entities?.length ? (\n <>\n {entities.map(d => (\n <div\n key={`${d.metadata.name}-${d.kind}-${d.metadata.namespace}`}\n data-testid=\"docs-card-content\"\n >\n <Link\n className={styles.docsTitleLink}\n data-testid=\"docs-card-title\"\n to={\n linkDestination ||\n `/docs/${d.metadata.namespace || 'default'}/${d.kind}/${\n d.metadata.name\n }/`\n }\n >\n <EntityDisplayName entityRef={stringifyEntityRef(d)} />\n </Link>\n {d.metadata.description && (\n <Typography className={styles.docDescription}>\n {d.metadata.description}\n </Typography>\n )}\n <Link\n className={styles.docSubLink}\n data-testid=\"docs-card-sub-link\"\n to={\n linkDestination ||\n `/docs/${d.metadata.namespace || 'default'}/${d.kind}/${\n d.metadata.name\n }/`\n }\n >\n {linkText}\n </Link>\n </div>\n ))}\n </>\n ) : (\n emptyState || (\n <EmptyState\n missing=\"data\"\n title=\"No documents to show\"\n description=\"Create your own document. Check out our Getting Started Information\"\n action={\n <LinkButton\n to=\"https://backstage.io/docs/features/techdocs/getting-started\"\n variant=\"contained\"\n >\n DOCS\n </LinkButton>\n }\n />\n )\n );\n};\n"],"names":[],"mappings":";;;;;;;;;AAuDA,MAAM,SAAY,GAAA,UAAA;AAAA,EAChB,CAAU,KAAA,MAAA;AAAA,IACR,cAAgB,EAAA;AAAA,MACd,QAAA,EAAU,KAAM,CAAA,UAAA,CAA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A,IACC,CAAA,CAAE,QAAS,CAAA,WAAA,oBACT,KAAA,CAAA,aAAA,CAAA,UAAA,EAAA,EAAW,WAAW,MAAO,CAAA,cAAA,EAAA,EAC3B,CAAE,CAAA,QAAA,CAAS,WACd,CAAA;AAAA,oBAEF,KAAA,CAAA,aAAA;AAAA,MAAC,IAAA;AAAA,MAAA;AAAA,QACC,WAAW,MAAO,CAAA,UAAA;AAAA,QAClB,aAAY,EAAA,oBAAA;AAAA,QACZ,EACE,EAAA,eAAA,IACA,CAAS,MAAA,EAAA,CAAA,CAAE,QAAS,CAAA,SAAA,IAAa,SAAS,CAAA,CAAA,EAAI,CAAE,CAAA,IAAI,CAClD,CAAA,EAAA,CAAA,CAAE,SAAS,IACb,CAAA,CAAA,CAAA;AAAA,OAAA;AAAA,MAGD,QAAA;AAAA,KACH;AAAA,GAEH,CACH,CAAA,GAEA,UACE,oBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,UAAA;AAAA,IAAA;AAAA,MACC,OAAQ,EAAA,MAAA;AAAA,MACR,KAAM,EAAA,sBAAA;AAAA,MACN,WAAY,EAAA,qEAAA;AAAA,MACZ,MACE,kBAAA,KAAA,CAAA,aAAA;AAAA,QAAC,UAAA;AAAA,QAAA;AAAA,UACC,EAAG,EAAA,6DAAA;AAAA,UACH,OAAQ,EAAA,WAAA;AAAA,SAAA;AAAA,QACT,MAAA;AAAA,OAED;AAAA,KAAA;AAAA,GAEJ,CAAA;AAGN;;;;"}
|
|
@@ -1,6 +1,11 @@
|
|
|
1
1
|
import React, { createContext } from 'react';
|
|
2
|
-
import
|
|
2
|
+
import Button from '@material-ui/core/Button';
|
|
3
3
|
import Typography from '@material-ui/core/Typography';
|
|
4
|
+
import FormControl from '@material-ui/core/FormControl';
|
|
5
|
+
import FormLabel from '@material-ui/core/FormLabel';
|
|
6
|
+
import RadioGroup from '@material-ui/core/RadioGroup';
|
|
7
|
+
import FormControlLabel from '@material-ui/core/FormControlLabel';
|
|
8
|
+
import Radio from '@material-ui/core/Radio';
|
|
4
9
|
import upperFirst from 'lodash/upperFirst';
|
|
5
10
|
|
|
6
11
|
const Context = createContext(void 0);
|
|
@@ -82,4 +87,4 @@ const Settings = () => {
|
|
|
82
87
|
};
|
|
83
88
|
|
|
84
89
|
export { Actions, Content, ContextProvider, Settings };
|
|
85
|
-
//# sourceMappingURL=index-
|
|
90
|
+
//# sourceMappingURL=index-Dg9lslkf.esm.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index-Dg9lslkf.esm.js","sources":["../../src/homePageComponents/RandomJoke/Context.tsx","../../src/homePageComponents/RandomJoke/Actions.tsx","../../src/homePageComponents/RandomJoke/Content.tsx","../../src/homePageComponents/RandomJoke/Settings.tsx"],"sourcesContent":["/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React, { createContext } from 'react';\n\nexport type JokeType = 'any' | 'programming';\n\ntype Joke = {\n setup: string;\n punchline: string;\n};\n\ntype RandomJokeContextValue = {\n loading: boolean;\n joke: Joke;\n type: JokeType;\n rerollJoke: Function;\n handleChangeType: Function;\n};\n\nconst Context = createContext<RandomJokeContextValue | undefined>(undefined);\n\nconst getNewJoke = (type: string): Promise<Joke> =>\n fetch(\n `https://official-joke-api.appspot.com/jokes${\n type !== 'any' ? `/${type}` : ''\n }/random`,\n )\n .then(res => res.json())\n .then(data => (Array.isArray(data) ? data[0] : data));\n\nexport const ContextProvider = (props: {\n children: JSX.Element;\n defaultCategory?: JokeType;\n}) => {\n const { children, defaultCategory } = props;\n\n const [loading, setLoading] = React.useState(true);\n const [joke, setJoke] = React.useState<Joke>({\n setup: '',\n punchline: '',\n });\n const [type, setType] = React.useState<JokeType>(\n defaultCategory || ('programming' as JokeType),\n );\n\n const rerollJoke = React.useCallback(() => {\n setLoading(true);\n getNewJoke(type).then(newJoke => setJoke(newJoke));\n }, [type]);\n\n const handleChangeType = (newType: JokeType) => {\n setType(newType);\n };\n\n React.useEffect(() => {\n setLoading(false);\n }, [joke]);\n\n React.useEffect(() => {\n rerollJoke();\n }, [rerollJoke]);\n\n const value: RandomJokeContextValue = {\n loading,\n joke,\n type,\n rerollJoke,\n handleChangeType,\n };\n\n return <Context.Provider value={value}>{children}</Context.Provider>;\n};\n\nexport const useRandomJoke = () => {\n const value = React.useContext(Context);\n\n if (value === undefined) {\n throw new Error('useRandomJoke must be used within a RandomJokeProvider');\n }\n\n return value;\n};\n\nexport default Context;\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';\n\nimport Button from '@material-ui/core/Button';\nimport { useRandomJoke } from './Context';\n\nexport const Actions = () => {\n const { rerollJoke } = useRandomJoke();\n return (\n <Button variant=\"contained\" color=\"primary\" onClick={() => rerollJoke()}>\n Reroll\n </Button>\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 Typography from '@material-ui/core/Typography';\nimport React from 'react';\nimport { useRandomJoke } from './Context';\n\nexport const Content = () => {\n const { joke, loading } = useRandomJoke();\n\n if (loading) return <Typography paragraph>Loading...</Typography>;\n\n return (\n <div>\n <Typography paragraph>{joke.setup}</Typography>\n <Typography paragraph>{joke.punchline}</Typography>\n </div>\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 */\nimport FormControl from '@material-ui/core/FormControl';\nimport FormLabel from '@material-ui/core/FormLabel';\nimport RadioGroup from '@material-ui/core/RadioGroup';\nimport FormControlLabel from '@material-ui/core/FormControlLabel';\nimport Radio from '@material-ui/core/Radio';\nimport React from 'react';\nimport { useRandomJoke, JokeType } from './Context';\nimport upperFirst from 'lodash/upperFirst';\n\nexport const Settings = () => {\n const { type, handleChangeType } = useRandomJoke();\n const JOKE_TYPES: JokeType[] = ['any' as JokeType, 'programming' as JokeType];\n return (\n <FormControl component=\"fieldset\">\n <FormLabel component=\"legend\">Joke Type</FormLabel>\n <RadioGroup\n aria-label=\"joke type\"\n value={type}\n onChange={e => handleChangeType(e.target.value)}\n >\n {JOKE_TYPES.map(t => (\n <FormControlLabel\n key={t}\n value={t}\n control={<Radio />}\n label={upperFirst(t)}\n />\n ))}\n </RadioGroup>\n </FormControl>\n );\n};\n"],"names":[],"mappings":";;;;;;;;;;AAiCA,MAAM,OAAA,GAAU,cAAkD,KAAS,CAAA,CAAA,CAAA;AAE3E,MAAM,UAAA,GAAa,CAAC,IAClB,KAAA,KAAA;AAAA,EACE,8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AW,WAAS,IAAE,EAAA,EAAA,IAAA,CAAK,KAAM,CAAA,sCACjC,UAAW,EAAA,EAAA,SAAA,EAAS,IAAE,EAAA,EAAA,IAAA,CAAK,SAAU,CACxC,CAAA,CAAA;AAEJ;;ACPO,MAAM,WAAW,MAAM;AAC5B,EAAA,MAAM,EAAE,IAAA,EAAM,gBAAiB,EAAA,GAAI,aAAc,EAAA,CAAA;AACjD,EAAM,MAAA,UAAA,GAAyB,CAAC,KAAA,EAAmB,aAAyB,CAAA,CAAA;AAC5E,EACE,uBAAA,KAAA,CAAA,aAAA,CAAC,eAAY,SAAU,EAAA,UAAA,EAAA,sCACpB,SAAU,EAAA,EAAA,SAAA,EAAU,QAAS,EAAA,EAAA,WAAS,CACvC,kBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,UAAA;AAAA,IAAA;AAAA,MACC,YAAW,EAAA,WAAA;AAAA,MACX,KAAO,EAAA,IAAA;AAAA,MACP,QAAU,EAAA,CAAA,CAAA,KAAK,gBAAiB,CAAA,CAAA,CAAE,OAAO,KAAK,CAAA;AAAA,KAAA;AAAA,IAE7C,UAAA,CAAW,IAAI,CACd,CAAA,qBAAA,KAAA,CAAA,aAAA;AAAA,MAAC,gBAAA;AAAA,MAAA;AAAA,QACC,GAAK,EAAA,CAAA;AAAA,QACL,KAAO,EAAA,CAAA;AAAA,QACP,OAAA,sCAAU,KAAM,EAAA,IAAA,CAAA;AAAA,QAChB,KAAA,EAAO,WAAW,CAAC,CAAA;AAAA,OAAA;AAAA,KAEtB,CAAA;AAAA,GAEL,CAAA,CAAA;AAEJ;;;;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import Typography from '@material-ui/core/Typography';
|
|
2
2
|
import { useApi, configApiRef } from '@backstage/core-plugin-api';
|
|
3
3
|
import React from 'react';
|
|
4
4
|
|
|
@@ -9,4 +9,4 @@ const CompanyLogo = (props) => {
|
|
|
9
9
|
};
|
|
10
10
|
|
|
11
11
|
export { CompanyLogo };
|
|
12
|
-
//# sourceMappingURL=index-
|
|
12
|
+
//# sourceMappingURL=index-FqRX6ImF.esm.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index-FqRX6ImF.esm.js","sources":["../../src/homePageComponents/CompanyLogo/CompanyLogo.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 */\nimport Typography from '@material-ui/core/Typography';\nimport { configApiRef, useApi } from '@backstage/core-plugin-api';\nimport React from 'react';\n\ntype CompanyLogoProps = {\n logo?: React.ReactNode;\n className?: string;\n};\n\n/**\n * A component to display a company logo for the user.\n *\n * @public\n */\nexport const CompanyLogo = (props: CompanyLogoProps) => {\n const { logo, className } = props;\n const configApi = useApi(configApiRef);\n\n return (\n <div className={className}>\n {logo ? (\n <>{logo}</>\n ) : (\n <Typography variant=\"h1\">{configApi.getString('app.title')}</Typography>\n )}\n </div>\n );\n};\n"],"names":[],"mappings":";;;;AA6Ba,MAAA,WAAA,GAAc,CAAC,KAA4B,KAAA;AACtD,EAAM,MAAA,EAAE,IAAM,EAAA,SAAA,EAAc,GAAA,KAAA,CAAA;AAC5B,EAAM,MAAA,SAAA,GAAY,OAAO,YAAY,CAAA,CAAA;AAErC,EAAA,uBACG,KAAA,CAAA,aAAA,CAAA,KAAA,EAAA,EAAI,SACF,EAAA,EAAA,IAAA,6DACI,IAAK,CAAA,mBAEP,KAAA,CAAA,aAAA,CAAA,UAAA,EAAA,EAAW,SAAQ,IAAM,EAAA,EAAA,SAAA,CAAU,SAAU,CAAA,WAAW,CAAE,CAE/D,CAAA,CAAA;AAEJ;;;;"}
|
|
@@ -2,9 +2,17 @@ import { entityRouteRef, entityRouteParams, catalogApiRef, useStarredEntities }
|
|
|
2
2
|
import { stringifyEntityRef } from '@backstage/catalog-model';
|
|
3
3
|
import { useRouteRef, useApi } from '@backstage/core-plugin-api';
|
|
4
4
|
import { Progress, ResponseErrorPanel } from '@backstage/core-components';
|
|
5
|
-
import
|
|
5
|
+
import List from '@material-ui/core/List';
|
|
6
|
+
import Typography from '@material-ui/core/Typography';
|
|
7
|
+
import Tabs from '@material-ui/core/Tabs';
|
|
8
|
+
import Tab from '@material-ui/core/Tab';
|
|
6
9
|
import React from 'react';
|
|
7
|
-
import useAsync from 'react-use/
|
|
10
|
+
import useAsync from 'react-use/esm/useAsync';
|
|
11
|
+
import ListItem from '@material-ui/core/ListItem';
|
|
12
|
+
import ListItemIcon from '@material-ui/core/ListItemIcon';
|
|
13
|
+
import Tooltip from '@material-ui/core/Tooltip';
|
|
14
|
+
import IconButton from '@material-ui/core/IconButton';
|
|
15
|
+
import ListItemText from '@material-ui/core/ListItemText';
|
|
8
16
|
import { Link } from 'react-router-dom';
|
|
9
17
|
import StarIcon from '@material-ui/icons/Star';
|
|
10
18
|
|
|
@@ -103,4 +111,4 @@ const Content = ({
|
|
|
103
111
|
};
|
|
104
112
|
|
|
105
113
|
export { Content };
|
|
106
|
-
//# sourceMappingURL=index-
|
|
114
|
+
//# sourceMappingURL=index-SfHoDIi1.esm.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index-SfHoDIi1.esm.js","sources":["../../src/components/StarredEntityListItem/StarredEntityListItem.tsx","../../src/homePageComponents/StarredEntities/Content.tsx"],"sourcesContent":["/*\n * Copyright 2023 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { Entity, stringifyEntityRef } from '@backstage/catalog-model';\nimport { entityRouteParams } from '@backstage/plugin-catalog-react';\nimport ListItem from '@material-ui/core/ListItem';\nimport ListItemIcon from '@material-ui/core/ListItemIcon';\nimport Tooltip from '@material-ui/core/Tooltip';\nimport IconButton from '@material-ui/core/IconButton';\nimport ListItemText from '@material-ui/core/ListItemText';\nimport React from 'react';\nimport { Link } from 'react-router-dom';\nimport { entityRouteRef } from '@backstage/plugin-catalog-react';\nimport { useRouteRef } from '@backstage/core-plugin-api';\nimport StarIcon from '@material-ui/icons/Star';\n\ntype EntityListItemProps = {\n entity: Entity;\n onToggleStarredEntity: (entity: Entity) => void;\n};\n\nexport const StarredEntityListItem = ({\n entity,\n onToggleStarredEntity,\n}: EntityListItemProps) => {\n const catalogEntityRoute = useRouteRef(entityRouteRef);\n\n return (\n <ListItem key={stringifyEntityRef(entity)}>\n <ListItemIcon>\n <Tooltip title=\"Remove from starred\">\n <IconButton\n edge=\"end\"\n aria-label=\"unstar\"\n onClick={() => onToggleStarredEntity(entity)}\n >\n <StarIcon style={{ color: '#f3ba37' }} />\n </IconButton>\n </Tooltip>\n </ListItemIcon>\n <Link to={catalogEntityRoute(entityRouteParams(entity))}>\n <ListItemText primary={entity.metadata.title ?? entity.metadata.name} />\n </Link>\n </ListItem>\n );\n};\n","/*\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 catalogApiRef,\n useStarredEntities,\n} from '@backstage/plugin-catalog-react';\nimport { Entity, stringifyEntityRef } from '@backstage/catalog-model';\nimport { useApi } from '@backstage/core-plugin-api';\nimport { Progress, ResponseErrorPanel } from '@backstage/core-components';\nimport List from '@material-ui/core/List';\nimport Typography from '@material-ui/core/Typography';\nimport Tabs from '@material-ui/core/Tabs';\nimport Tab from '@material-ui/core/Tab';\nimport React from 'react';\nimport useAsync from 'react-use/esm/useAsync';\nimport { StarredEntityListItem } from '../../components/StarredEntityListItem/StarredEntityListItem';\n\n/**\n * A component to display a list of starred entities for the user.\n *\n * @public\n */\n\nexport type StarredEntitiesProps = {\n noStarredEntitiesMessage?: React.ReactNode | undefined;\n groupByKind?: boolean;\n};\n\nexport const Content = ({\n noStarredEntitiesMessage,\n groupByKind,\n}: StarredEntitiesProps) => {\n const catalogApi = useApi(catalogApiRef);\n const { starredEntities, toggleStarredEntity } = useStarredEntities();\n const [activeTab, setActiveTab] = React.useState(0);\n\n // Grab starred entities from catalog to ensure they still exist and also retrieve display titles\n const entities = useAsync(async () => {\n if (!starredEntities.size) {\n return [];\n }\n\n return (\n await catalogApi.getEntitiesByRefs({\n entityRefs: [...starredEntities],\n fields: [\n 'kind',\n 'metadata.namespace',\n 'metadata.name',\n 'metadata.title',\n ],\n })\n ).items.filter((e): e is Entity => !!e);\n }, [catalogApi, starredEntities]);\n\n if (starredEntities.size === 0)\n return (\n <Typography variant=\"body1\">\n {noStarredEntitiesMessage ||\n 'Click the star beside an entity name to add it to this list!'}\n </Typography>\n );\n\n if (entities.loading) {\n return <Progress />;\n }\n\n const groupedEntities: { [kind: string]: Entity[] } = {};\n entities.value?.forEach(entity => {\n const kind = entity.kind;\n if (!groupedEntities[kind]) {\n groupedEntities[kind] = [];\n }\n groupedEntities[kind].push(entity);\n });\n\n const groupByKindEntries = Object.entries(groupedEntities);\n\n return entities.error ? (\n <ResponseErrorPanel error={entities.error} />\n ) : (\n <div>\n {!groupByKind && (\n <List>\n {entities.value\n ?.sort((a, b) =>\n (a.metadata.title ?? a.metadata.name).localeCompare(\n b.metadata.title ?? b.metadata.name,\n ),\n )\n .map(entity => (\n <StarredEntityListItem\n key={stringifyEntityRef(entity)}\n entity={entity}\n onToggleStarredEntity={toggleStarredEntity}\n />\n ))}\n </List>\n )}\n\n {groupByKind && (\n <Tabs\n value={activeTab}\n onChange={(_, newValue) => setActiveTab(newValue)}\n variant=\"scrollable\"\n scrollButtons=\"auto\"\n aria-label=\"entity-tabs\"\n >\n {groupByKindEntries.map(([kind]) => (\n <Tab key={kind} label={kind} />\n ))}\n </Tabs>\n )}\n\n {groupByKind &&\n groupByKindEntries.map(([kind, entitiesByKind], index) => (\n <div key={kind} hidden={groupByKind && activeTab !== index}>\n <List>\n {entitiesByKind\n ?.sort((a, b) =>\n (a.metadata.title ?? a.metadata.name).localeCompare(\n b.metadata.title ?? b.metadata.name,\n ),\n )\n .map(entity => (\n <StarredEntityListItem\n key={stringifyEntityRef(entity)}\n entity={entity}\n onToggleStarredEntity={toggleStarredEntity}\n />\n ))}\n </List>\n </div>\n ))}\n </div>\n );\n};\n"],"names":["_a","_b"],"mappings":";;;;;;;;;;;;;;;;;;AAiCO,MAAM,wBAAwB,CAAC;AAAA,EACpC,MAAA;AAAA,EACA,qBAAA;AACF,CAA2B,KAAA;AApC3B,EAAA,IAAA,EAAA,CAAA;AAqCE,EAAM,MAAA,kBAAA,GAAqB,YAAY,cAAc,CAAA,CAAA;AAErD,EACE,uBAAA,KAAA,CAAA,aAAA,CAAC,QAAS,EAAA,EAAA,GAAA,EAAK,kBAAmB,CAAA,MAAM,CACtC,EAAA,kBAAA,KAAA,CAAA,aAAA,CAAC,YACC,EAAA,IAAA,kBAAA,KAAA,CAAA,aAAA,CAAC,OAAQ,EAAA,EAAA,KAAA,EAAM,qBACb,EAAA,kBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,UAAA;AAAA,IAAA;AAAA,MACC,IAAK,EAAA,KAAA;AAAA,MACL,YAAW,EAAA,QAA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A,IAAAD,GAAAC,EAAAA,GAAAA,CAAAA;AAsImB,MAAAD,OAAAA,CAAAA,CAAAA,GAAAA,GAAA,EAAE,QAAS,CAAA,KAAA,KAAX,OAAAA,GAAoB,GAAA,CAAA,CAAE,SAAS,IAAM,EAAA,aAAA;AAAA,QAAA,CACpCC,MAAA,CAAE,CAAA,QAAA,CAAS,UAAX,IAAAA,GAAAA,GAAAA,GAAoB,EAAE,QAAS,CAAA,IAAA;AAAA,OACjC,CAAA;AAAA,KAAA;AAAA,GAAA,CAED,IAAI,CACH,MAAA,qBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,qBAAA;AAAA,IAAA;AAAA,MACC,GAAA,EAAK,mBAAmB,MAAM,CAAA;AAAA,MAC9B,MAAA;AAAA,MACA,qBAAuB,EAAA,mBAAA;AAAA,KAAA;AAAA,GACzB,CAEN,CACF,CACD,CACL,CAAA,CAAA;AAEJ;;;;"}
|
package/dist/index.d.ts
CHANGED
|
@@ -242,6 +242,7 @@ declare const ComponentAccordion: (props: {
|
|
|
242
242
|
expanded?: boolean | undefined;
|
|
243
243
|
Content: () => JSX.Element;
|
|
244
244
|
Actions?: (() => JSX.Element) | undefined;
|
|
245
|
+
/** @public */
|
|
245
246
|
Settings?: (() => JSX.Element) | undefined;
|
|
246
247
|
ContextProvider?: ((props: any) => JSX.Element) | undefined;
|
|
247
248
|
}) => React.JSX.Element;
|
|
@@ -490,4 +491,4 @@ declare const SettingsModal: (props: {
|
|
|
490
491
|
children: JSX.Element;
|
|
491
492
|
}) => React.JSX.Element;
|
|
492
493
|
|
|
493
|
-
export { Breakpoint, CardConfig, CardExtensionProps, CardLayout, CardSettings, ClockConfig, ComponentAccordion, ComponentParts, ComponentRenderer, ComponentTab, ComponentTabs, CustomHomepageGrid, CustomHomepageGridProps, FeaturedDocsCard, FeaturedDocsCardProps, HeaderWorldClock, HomePageCompanyLogo, HomePageRandomJoke, HomePageRecentlyVisited, HomePageStarredEntities, HomePageToolkit, HomePageTopVisited, HomepageCompositionRoot, LayoutConfiguration, Operators, RendererProps, SettingsModal, StarredEntitiesProps, TemplateBackstageLogo, TemplateBackstageLogoIcon, Tool, ToolkitContentProps, Visit, VisitListener, VisitedByTypeKind, VisitedByTypeProps, VisitsApi, VisitsApiQueryParams, VisitsApiSaveParams, VisitsStorageApi, VisitsStorageApiOptions, VisitsWebStorageApi, VisitsWebStorageApiOptions, WelcomeTitle, WelcomeTitleLanguageProps, createCardExtension, homePlugin, isOperator, visitsApiRef };
|
|
494
|
+
export { type Breakpoint, type CardConfig, type CardExtensionProps, type CardLayout, type CardSettings, type ClockConfig, ComponentAccordion, type ComponentParts, type ComponentRenderer, ComponentTab, ComponentTabs, CustomHomepageGrid, type CustomHomepageGridProps, FeaturedDocsCard, type FeaturedDocsCardProps, HeaderWorldClock, HomePageCompanyLogo, HomePageRandomJoke, HomePageRecentlyVisited, HomePageStarredEntities, HomePageToolkit, HomePageTopVisited, HomepageCompositionRoot, type LayoutConfiguration, type Operators, type RendererProps, SettingsModal, type StarredEntitiesProps, TemplateBackstageLogo, TemplateBackstageLogoIcon, type Tool, type ToolkitContentProps, type Visit, VisitListener, type VisitedByTypeKind, type VisitedByTypeProps, type VisitsApi, type VisitsApiQueryParams, type VisitsApiSaveParams, VisitsStorageApi, type VisitsStorageApiOptions, VisitsWebStorageApi, type VisitsWebStorageApiOptions, WelcomeTitle, type WelcomeTitleLanguageProps, createCardExtension, homePlugin, isOperator, visitsApiRef };
|
package/dist/index.esm.js
CHANGED
|
@@ -1,18 +1,22 @@
|
|
|
1
1
|
import { createRouteRef, createPlugin, createApiFactory, storageApiRef, identityApiRef, createRoutableExtension, createComponentExtension } from '@backstage/core-plugin-api';
|
|
2
2
|
import { createCardExtension as createCardExtension$1, SettingsModal as SettingsModal$1 } from '@backstage/plugin-home-react';
|
|
3
3
|
import { WebStorage } from '@backstage/core-app-api';
|
|
4
|
-
import { v as visitsApiRef } from './esm/VisitListener-
|
|
5
|
-
export { C as CustomHomepageGrid, V as VisitListener, i as isOperator
|
|
4
|
+
import { v as visitsApiRef } from './esm/VisitListener-dDLtFiIW.esm.js';
|
|
5
|
+
export { C as CustomHomepageGrid, V as VisitListener, i as isOperator } from './esm/VisitListener-dDLtFiIW.esm.js';
|
|
6
6
|
import React from 'react';
|
|
7
7
|
import 'react-router-dom';
|
|
8
|
-
import { makeStyles } from '@material-ui/core';
|
|
8
|
+
import { makeStyles } from '@material-ui/core/styles';
|
|
9
9
|
import 'react-grid-layout';
|
|
10
10
|
import 'react-grid-layout/css/styles.css';
|
|
11
11
|
import 'react-resizable/css/styles.css';
|
|
12
|
+
import '@material-ui/core/Dialog';
|
|
12
13
|
import 'lodash';
|
|
13
|
-
import 'react-use/
|
|
14
|
+
import 'react-use/esm/useObservable';
|
|
14
15
|
import '@backstage/core-components';
|
|
15
16
|
import '@material-ui/core/Typography';
|
|
17
|
+
import '@material-ui/core/DialogContent';
|
|
18
|
+
import '@material-ui/core/Grid';
|
|
19
|
+
import '@material-ui/core/Tooltip';
|
|
16
20
|
import '@material-ui/core/IconButton';
|
|
17
21
|
import '@material-ui/icons/Settings';
|
|
18
22
|
import '@material-ui/icons/Delete';
|
|
@@ -21,6 +25,8 @@ import '@rjsf/material-ui';
|
|
|
21
25
|
import '@rjsf/validator-ajv8';
|
|
22
26
|
import '@material-ui/core/List';
|
|
23
27
|
import '@material-ui/core/ListItem';
|
|
28
|
+
import '@material-ui/core/DialogTitle';
|
|
29
|
+
import '@material-ui/core/ListItemAvatar';
|
|
24
30
|
import '@material-ui/icons/Add';
|
|
25
31
|
import '@material-ui/core/ListItemText';
|
|
26
32
|
import '@material-ui/core/Button';
|
|
@@ -179,7 +185,7 @@ const homePlugin = createPlugin({
|
|
|
179
185
|
const HomepageCompositionRoot = homePlugin.provide(
|
|
180
186
|
createRoutableExtension({
|
|
181
187
|
name: "HomepageCompositionRoot",
|
|
182
|
-
component: () => import('./esm/index-
|
|
188
|
+
component: () => import('./esm/index-Bzg5mDMo.esm.js').then((m) => m.HomepageCompositionRoot),
|
|
183
189
|
mountPoint: rootRouteRef
|
|
184
190
|
})
|
|
185
191
|
);
|
|
@@ -187,7 +193,7 @@ const ComponentAccordion = homePlugin.provide(
|
|
|
187
193
|
createComponentExtension({
|
|
188
194
|
name: "ComponentAccordion",
|
|
189
195
|
component: {
|
|
190
|
-
lazy: () => import('./esm/index-
|
|
196
|
+
lazy: () => import('./esm/index-BNfZuEhy.esm.js').then((m) => m.ComponentAccordion)
|
|
191
197
|
}
|
|
192
198
|
})
|
|
193
199
|
);
|
|
@@ -195,7 +201,7 @@ const ComponentTabs = homePlugin.provide(
|
|
|
195
201
|
createComponentExtension({
|
|
196
202
|
name: "ComponentTabs",
|
|
197
203
|
component: {
|
|
198
|
-
lazy: () => import('./esm/index-
|
|
204
|
+
lazy: () => import('./esm/index-BNfZuEhy.esm.js').then((m) => m.ComponentTabs)
|
|
199
205
|
}
|
|
200
206
|
})
|
|
201
207
|
);
|
|
@@ -203,7 +209,7 @@ const ComponentTab = homePlugin.provide(
|
|
|
203
209
|
createComponentExtension({
|
|
204
210
|
name: "ComponentTab",
|
|
205
211
|
component: {
|
|
206
|
-
lazy: () => import('./esm/index-
|
|
212
|
+
lazy: () => import('./esm/index-BNfZuEhy.esm.js').then((m) => m.ComponentTab)
|
|
207
213
|
}
|
|
208
214
|
})
|
|
209
215
|
);
|
|
@@ -211,7 +217,7 @@ const WelcomeTitle = homePlugin.provide(
|
|
|
211
217
|
createComponentExtension({
|
|
212
218
|
name: "WelcomeTitle",
|
|
213
219
|
component: {
|
|
214
|
-
lazy: () => import('./esm/index-
|
|
220
|
+
lazy: () => import('./esm/index-BMySa_Iw.esm.js').then((m) => m.WelcomeTitle)
|
|
215
221
|
}
|
|
216
222
|
})
|
|
217
223
|
);
|
|
@@ -219,7 +225,7 @@ const HomePageCompanyLogo = homePlugin.provide(
|
|
|
219
225
|
createComponentExtension({
|
|
220
226
|
name: "CompanyLogo",
|
|
221
227
|
component: {
|
|
222
|
-
lazy: () => import('./esm/index-
|
|
228
|
+
lazy: () => import('./esm/index-FqRX6ImF.esm.js').then((m) => m.CompanyLogo)
|
|
223
229
|
}
|
|
224
230
|
})
|
|
225
231
|
);
|
|
@@ -227,7 +233,7 @@ const HomePageRandomJoke = homePlugin.provide(
|
|
|
227
233
|
createCardExtension$1({
|
|
228
234
|
name: "HomePageRandomJoke",
|
|
229
235
|
title: "Random Joke",
|
|
230
|
-
components: () => import('./esm/index-
|
|
236
|
+
components: () => import('./esm/index-Dg9lslkf.esm.js'),
|
|
231
237
|
description: "Shows a random joke about optional category",
|
|
232
238
|
layout: {
|
|
233
239
|
height: { minRows: 4 },
|
|
@@ -253,21 +259,21 @@ const HomePageToolkit = homePlugin.provide(
|
|
|
253
259
|
createCardExtension$1({
|
|
254
260
|
name: "HomePageToolkit",
|
|
255
261
|
title: "Toolkit",
|
|
256
|
-
components: () => import('./esm/index-
|
|
262
|
+
components: () => import('./esm/index-CeXFfTX2.esm.js')
|
|
257
263
|
})
|
|
258
264
|
);
|
|
259
265
|
const HomePageStarredEntities = homePlugin.provide(
|
|
260
266
|
createCardExtension$1({
|
|
261
267
|
name: "HomePageStarredEntities",
|
|
262
268
|
title: "Your Starred Entities",
|
|
263
|
-
components: () => import('./esm/index-
|
|
269
|
+
components: () => import('./esm/index-SfHoDIi1.esm.js')
|
|
264
270
|
})
|
|
265
271
|
);
|
|
266
272
|
const HeaderWorldClock = homePlugin.provide(
|
|
267
273
|
createComponentExtension({
|
|
268
274
|
name: "HeaderWorldClock",
|
|
269
275
|
component: {
|
|
270
|
-
lazy: () => import('./esm/index-
|
|
276
|
+
lazy: () => import('./esm/index-BvvJGS3L.esm.js').then(
|
|
271
277
|
(m) => m.HeaderWorldClock
|
|
272
278
|
)
|
|
273
279
|
}
|
|
@@ -277,21 +283,21 @@ const HomePageTopVisited = homePlugin.provide(
|
|
|
277
283
|
createCardExtension$1({
|
|
278
284
|
name: "HomePageTopVisited",
|
|
279
285
|
title: "Top Visited",
|
|
280
|
-
components: () => import('./esm/TopVisited-
|
|
286
|
+
components: () => import('./esm/TopVisited-B_KhSJit.esm.js')
|
|
281
287
|
})
|
|
282
288
|
);
|
|
283
289
|
const HomePageRecentlyVisited = homePlugin.provide(
|
|
284
290
|
createCardExtension$1({
|
|
285
291
|
name: "HomePageRecentlyVisited",
|
|
286
292
|
title: "Recently Visited",
|
|
287
|
-
components: () => import('./esm/RecentlyVisited-
|
|
293
|
+
components: () => import('./esm/RecentlyVisited-qOUgoCVu.esm.js')
|
|
288
294
|
})
|
|
289
295
|
);
|
|
290
296
|
const FeaturedDocsCard = homePlugin.provide(
|
|
291
297
|
createCardExtension$1({
|
|
292
298
|
name: "FeaturedDocsCard",
|
|
293
299
|
title: "Featured Docs",
|
|
294
|
-
components: () => import('./esm/index-
|
|
300
|
+
components: () => import('./esm/index-D7JTE1IL.esm.js')
|
|
295
301
|
})
|
|
296
302
|
);
|
|
297
303
|
|
|
@@ -344,5 +350,5 @@ const TemplateBackstageLogoIcon = () => {
|
|
|
344
350
|
const createCardExtension = createCardExtension$1;
|
|
345
351
|
const SettingsModal = SettingsModal$1;
|
|
346
352
|
|
|
347
|
-
export { ComponentAccordion, ComponentTab, ComponentTabs, FeaturedDocsCard, HeaderWorldClock, HomePageCompanyLogo, HomePageRandomJoke, HomePageRecentlyVisited, HomePageStarredEntities, HomePageToolkit, HomePageTopVisited, HomepageCompositionRoot, SettingsModal, TemplateBackstageLogo, TemplateBackstageLogoIcon, VisitsStorageApi, VisitsWebStorageApi, WelcomeTitle, createCardExtension, homePlugin };
|
|
353
|
+
export { ComponentAccordion, ComponentTab, ComponentTabs, FeaturedDocsCard, HeaderWorldClock, HomePageCompanyLogo, HomePageRandomJoke, HomePageRecentlyVisited, HomePageStarredEntities, HomePageToolkit, HomePageTopVisited, HomepageCompositionRoot, SettingsModal, TemplateBackstageLogo, TemplateBackstageLogoIcon, VisitsStorageApi, VisitsWebStorageApi, WelcomeTitle, createCardExtension, homePlugin, visitsApiRef };
|
|
348
354
|
//# sourceMappingURL=index.esm.js.map
|