@red-hat-developer-hub/backstage-plugin-global-header 1.11.2 → 1.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +14 -0
- package/app-config.dynamic.yaml +11 -1
- package/config.d.ts +7 -0
- package/dist/components/CompanyLogo/CompanyLogo.esm.js +11 -5
- package/dist/components/CompanyLogo/CompanyLogo.esm.js.map +1 -1
- package/dist/components/HeaderDropdownComponent/HelpDropdown.esm.js +45 -0
- package/dist/components/HeaderDropdownComponent/HelpDropdown.esm.js.map +1 -0
- package/dist/components/QuickstartButton/QuickstartButton.esm.js +34 -0
- package/dist/components/QuickstartButton/QuickstartButton.esm.js.map +1 -0
- package/dist/components/QuickstartButton/const.esm.js +4 -0
- package/dist/components/QuickstartButton/const.esm.js.map +1 -0
- package/dist/components/QuickstartButton/useQuickstartButtonPermission.esm.js +27 -0
- package/dist/components/QuickstartButton/useQuickstartButtonPermission.esm.js.map +1 -0
- package/dist/components/SupportButton/SupportButton.esm.js +19 -23
- package/dist/components/SupportButton/SupportButton.esm.js.map +1 -1
- package/dist/defaultMountPoints/defaultMountPoints.esm.js +18 -2
- package/dist/defaultMountPoints/defaultMountPoints.esm.js.map +1 -1
- package/dist/hooks/useHelpDropdownMountPoints.esm.js +14 -0
- package/dist/hooks/useHelpDropdownMountPoints.esm.js.map +1 -0
- package/dist/index.d.ts +128 -110
- package/dist/index.esm.js +1 -1
- package/dist/plugin.esm.js +13 -2
- package/dist/plugin.esm.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# @red-hat-developer-hub/backstage-plugin-global-header
|
|
2
2
|
|
|
3
|
+
## 1.12.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 667e8c2: **BREAKING**: The `CompanyLogo` prop `logoWidth` has been renamed to `width`.
|
|
8
|
+
|
|
9
|
+
Allow configuring `width` and `height` for `CompanyLogo` via configuration. When `width` is not specified, `CompanyLogo` will now fall back to using the value from `app.branding.fullLogoWidth`.
|
|
10
|
+
|
|
11
|
+
- 5000863: **BREAKING**: `SupportButton` is now a `MenuItem` and `style` config prop can be used to update color, size and other required css properties.
|
|
12
|
+
|
|
13
|
+
Add `HelpDropdown` in global header plugin.
|
|
14
|
+
|
|
15
|
+
- 5638ede: Add QuickstartButton to global header plugin
|
|
16
|
+
|
|
3
17
|
## 1.11.2
|
|
4
18
|
|
|
5
19
|
### Patch Changes
|
package/app-config.dynamic.yaml
CHANGED
|
@@ -67,10 +67,20 @@ dynamicPlugins:
|
|
|
67
67
|
link: https://github.com/redhat-developer/rhdh-local
|
|
68
68
|
|
|
69
69
|
- mountPoint: global.header/component
|
|
70
|
-
importName:
|
|
70
|
+
importName: HelpDropdown
|
|
71
71
|
config:
|
|
72
72
|
priority: 80
|
|
73
73
|
|
|
74
|
+
- mountPoint: global.header/help
|
|
75
|
+
importName: QuickstartButton
|
|
76
|
+
config:
|
|
77
|
+
priority: 100
|
|
78
|
+
|
|
79
|
+
- mountPoint: global.header/help
|
|
80
|
+
importName: SupportButton
|
|
81
|
+
config:
|
|
82
|
+
priority: 10
|
|
83
|
+
|
|
74
84
|
- mountPoint: global.header/component
|
|
75
85
|
importName: NotificationButton
|
|
76
86
|
config:
|
package/config.d.ts
CHANGED
|
@@ -38,6 +38,13 @@ declare module '@backstage/config' {
|
|
|
38
38
|
*/
|
|
39
39
|
dark: string;
|
|
40
40
|
};
|
|
41
|
+
/**
|
|
42
|
+
* Fallback width for the full logo in the global header.
|
|
43
|
+
* Accepts any valid CSS length (e.g. `'200px'`, `'12rem'`).
|
|
44
|
+
* Used only when a `width` prop isn’t supplied through the extension configuration.
|
|
45
|
+
* @visibility frontend
|
|
46
|
+
*/
|
|
47
|
+
fullLogoWidth?: string | number;
|
|
41
48
|
};
|
|
42
49
|
};
|
|
43
50
|
}
|
|
@@ -8,7 +8,8 @@ import { useAppBarBackgroundScheme } from '../../hooks/useAppBarBackgroundScheme
|
|
|
8
8
|
const LogoRender = ({
|
|
9
9
|
base64Logo,
|
|
10
10
|
defaultLogo,
|
|
11
|
-
width = 150
|
|
11
|
+
width = 150,
|
|
12
|
+
height = 40
|
|
12
13
|
}) => {
|
|
13
14
|
return base64Logo ? /* @__PURE__ */ jsx(
|
|
14
15
|
"img",
|
|
@@ -19,8 +20,7 @@ const LogoRender = ({
|
|
|
19
20
|
style: {
|
|
20
21
|
objectFit: "contain",
|
|
21
22
|
objectPosition: "left",
|
|
22
|
-
maxHeight:
|
|
23
|
-
// "kind of" aligns with PF's MastheadLogo height
|
|
23
|
+
maxHeight: height
|
|
24
24
|
},
|
|
25
25
|
width
|
|
26
26
|
}
|
|
@@ -36,10 +36,15 @@ const useFullLogo = (logo) => {
|
|
|
36
36
|
};
|
|
37
37
|
const CompanyLogo = ({
|
|
38
38
|
logo,
|
|
39
|
-
|
|
39
|
+
width,
|
|
40
|
+
height,
|
|
40
41
|
to = "/"
|
|
41
42
|
}) => {
|
|
42
43
|
const logoURL = useFullLogo(logo);
|
|
44
|
+
const configApi = useApi(configApiRef);
|
|
45
|
+
const fullLogoWidth = configApi.getOptional(
|
|
46
|
+
"app.branding.fullLogoWidth"
|
|
47
|
+
);
|
|
43
48
|
return /* @__PURE__ */ jsx(
|
|
44
49
|
Box,
|
|
45
50
|
{
|
|
@@ -68,7 +73,8 @@ const CompanyLogo = ({
|
|
|
68
73
|
{
|
|
69
74
|
base64Logo: logoURL,
|
|
70
75
|
defaultLogo: /* @__PURE__ */ jsx(DefaultLogo, {}),
|
|
71
|
-
width:
|
|
76
|
+
width: width ?? fullLogoWidth,
|
|
77
|
+
height
|
|
72
78
|
}
|
|
73
79
|
)
|
|
74
80
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CompanyLogo.esm.js","sources":["../../../src/components/CompanyLogo/CompanyLogo.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 type { CSSProperties } from 'react';\nimport { Link } from '@backstage/core-components';\nimport { configApiRef, useApi } from '@backstage/core-plugin-api';\nimport DefaultLogo from './DefaultLogo';\nimport Box from '@mui/material/Box';\nimport { useAppBarBackgroundScheme } from '../../hooks/useAppBarBackgroundScheme';\n\nconst LogoRender = ({\n base64Logo,\n defaultLogo,\n width = 150,\n}: {\n base64Logo: string | undefined;\n defaultLogo: JSX.Element;\n width?: number;\n}) => {\n return base64Logo ? (\n <img\n data-testid=\"home-logo\"\n src={base64Logo}\n alt=\"Home logo\"\n style={{\n objectFit: 'contain',\n objectPosition: 'left',\n maxHeight:
|
|
1
|
+
{"version":3,"file":"CompanyLogo.esm.js","sources":["../../../src/components/CompanyLogo/CompanyLogo.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 type { CSSProperties } from 'react';\nimport { Link } from '@backstage/core-components';\nimport { configApiRef, useApi } from '@backstage/core-plugin-api';\nimport DefaultLogo from './DefaultLogo';\nimport Box from '@mui/material/Box';\nimport { useAppBarBackgroundScheme } from '../../hooks/useAppBarBackgroundScheme';\n\nconst LogoRender = ({\n base64Logo,\n defaultLogo,\n width = 150,\n height = 40,\n}: {\n base64Logo: string | undefined;\n defaultLogo: JSX.Element;\n width?: number | string;\n height?: number | string;\n}) => {\n return base64Logo ? (\n <img\n data-testid=\"home-logo\"\n src={base64Logo}\n alt=\"Home logo\"\n style={{\n objectFit: 'contain',\n objectPosition: 'left',\n maxHeight: height,\n }}\n width={width}\n />\n ) : (\n defaultLogo\n );\n};\n\n/**\n * An interface representing the URLs for light and dark variants of a logo.\n * @public\n */\nexport type LogoURLs =\n | {\n /** The logo that will be used in global headers with a light-coloured background */\n light: string;\n /** The logo that will be used in global headers with a dark-coloured background */\n dark: string;\n }\n | string\n | undefined;\n\n/**\n * @public\n */\nexport interface CompanyLogoProps {\n /** An object containing the logo URLs */\n logo?: LogoURLs;\n /** The route to link the logo to */\n to?: string;\n /**\n * The width of the logo in pixels (defaults to 150px). This prop fixes an\n * issue where encoded SVGs without an explicit width would not render.\n * You likely do not need to set this prop, but we recommend setting it\n * to a value under 200px.\n */\n width?: string | number;\n /**\n * The maximum height of the logo in pixels (defaults to 40px).\n * Note that changing this value may result in changes in the height of the global header.\n **/\n height?: string | number;\n /** This prop is not used by this component. */\n layout?: CSSProperties;\n}\n\n/**\n * Gets a themed image based on the current theme.\n */\nconst useFullLogo = (logo: LogoURLs): string | undefined => {\n const appBarBackgroundScheme = useAppBarBackgroundScheme();\n\n const configApi = useApi(configApiRef);\n\n /** The fullLogo config specified by app.branding.fullLogo */\n const fullLogo = configApi.getOptional<LogoURLs>('app.branding.fullLogo');\n\n /** The URI of the logo specified by app.branding.fullLogo */\n const fullLogoURI =\n typeof fullLogo === 'string'\n ? fullLogo\n : fullLogo?.[appBarBackgroundScheme];\n\n /** The URI of the logo specified by CompanyLogo props */\n const propsLogoURI =\n typeof logo === 'string' ? logo : logo?.[appBarBackgroundScheme];\n\n return propsLogoURI ?? fullLogoURI ?? undefined;\n};\n\nexport const CompanyLogo = ({\n logo,\n width,\n height,\n to = '/',\n}: CompanyLogoProps) => {\n const logoURL = useFullLogo(logo);\n const configApi = useApi(configApiRef);\n const fullLogoWidth = configApi.getOptional<number | string>(\n 'app.branding.fullLogoWidth',\n );\n return (\n <Box\n data-testid=\"global-header-company-logo\"\n sx={{\n minWidth: '200px',\n marginRight: '13px', // align with BackstageContent\n display: 'flex',\n justifyContent: 'flex-start',\n alignItems: 'center',\n }}\n >\n <Link\n to={to}\n underline=\"none\"\n aria-label=\"Home\"\n style={{\n display: 'flex',\n justifyContent: 'flex-start',\n alignItems: 'center',\n }}\n >\n <LogoRender\n base64Logo={logoURL}\n defaultLogo={<DefaultLogo />}\n width={width ?? fullLogoWidth}\n height={height}\n />\n </Link>\n </Box>\n );\n};\n"],"names":[],"mappings":";;;;;;;AAsBA,MAAM,aAAa,CAAC;AAAA,EAClB,UAAA;AAAA,EACA,WAAA;AAAA,EACA,KAAQ,GAAA,GAAA;AAAA,EACR,MAAS,GAAA;AACX,CAKM,KAAA;AACJ,EAAA,OAAO,UACL,mBAAA,GAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,aAAY,EAAA,WAAA;AAAA,MACZ,GAAK,EAAA,UAAA;AAAA,MACL,GAAI,EAAA,WAAA;AAAA,MACJ,KAAO,EAAA;AAAA,QACL,SAAW,EAAA,SAAA;AAAA,QACX,cAAgB,EAAA,MAAA;AAAA,QAChB,SAAW,EAAA;AAAA,OACb;AAAA,MACA;AAAA;AAAA,GAGF,GAAA,WAAA;AAEJ,CAAA;AA2CA,MAAM,WAAA,GAAc,CAAC,IAAuC,KAAA;AAC1D,EAAA,MAAM,yBAAyB,yBAA0B,EAAA;AAEzD,EAAM,MAAA,SAAA,GAAY,OAAO,YAAY,CAAA;AAGrC,EAAM,MAAA,QAAA,GAAW,SAAU,CAAA,WAAA,CAAsB,uBAAuB,CAAA;AAGxE,EAAA,MAAM,cACJ,OAAO,QAAA,KAAa,QAChB,GAAA,QAAA,GACA,WAAW,sBAAsB,CAAA;AAGvC,EAAA,MAAM,eACJ,OAAO,IAAA,KAAS,QA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 'react';
|
|
3
|
+
import { HeaderDropdownComponent } from './HeaderDropdownComponent.esm.js';
|
|
4
|
+
import { useDropdownManager } from '../../hooks/useDropdownManager.esm.js';
|
|
5
|
+
import HelpOutlineIcon from '@mui/icons-material/HelpOutline';
|
|
6
|
+
import { useHelpDropdownMountPoints } from '../../hooks/useHelpDropdownMountPoints.esm.js';
|
|
7
|
+
import { MenuSection } from './MenuSection.esm.js';
|
|
8
|
+
|
|
9
|
+
const HelpDropdown = ({ layout }) => {
|
|
10
|
+
const { anchorEl, handleOpen, handleClose } = useDropdownManager();
|
|
11
|
+
const helpDropdownMountPoints = useHelpDropdownMountPoints();
|
|
12
|
+
const menuItems = useMemo(() => {
|
|
13
|
+
return (helpDropdownMountPoints ?? []).map((mp) => ({
|
|
14
|
+
Component: mp.Component,
|
|
15
|
+
icon: mp.config?.props?.icon,
|
|
16
|
+
label: mp.config?.props?.title,
|
|
17
|
+
link: mp.config?.props?.link,
|
|
18
|
+
tooltip: mp.config?.props?.tooltip,
|
|
19
|
+
style: mp.config?.style,
|
|
20
|
+
priority: mp.config?.priority ?? 0
|
|
21
|
+
})).sort((a, b) => (b.priority ?? 0) - (a.priority ?? 0));
|
|
22
|
+
}, [helpDropdownMountPoints]);
|
|
23
|
+
if (menuItems.length === 0) {
|
|
24
|
+
return null;
|
|
25
|
+
}
|
|
26
|
+
return /* @__PURE__ */ jsx(
|
|
27
|
+
HeaderDropdownComponent,
|
|
28
|
+
{
|
|
29
|
+
isIconButton: true,
|
|
30
|
+
tooltip: "Help",
|
|
31
|
+
buttonContent: /* @__PURE__ */ jsx(HelpOutlineIcon, {}),
|
|
32
|
+
buttonProps: {
|
|
33
|
+
color: "inherit",
|
|
34
|
+
sx: layout
|
|
35
|
+
},
|
|
36
|
+
onOpen: handleOpen,
|
|
37
|
+
onClose: handleClose,
|
|
38
|
+
anchorEl,
|
|
39
|
+
children: /* @__PURE__ */ jsx(MenuSection, { hideDivider: true, items: menuItems, handleClose })
|
|
40
|
+
}
|
|
41
|
+
);
|
|
42
|
+
};
|
|
43
|
+
|
|
44
|
+
export { HelpDropdown };
|
|
45
|
+
//# sourceMappingURL=HelpDropdown.esm.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"HelpDropdown.esm.js","sources":["../../../src/components/HeaderDropdownComponent/HelpDropdown.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 { useMemo } from 'react';\nimport type { CSSProperties } from 'react';\nimport { HeaderDropdownComponent } from './HeaderDropdownComponent';\nimport { useDropdownManager } from '../../hooks';\nimport HelpOutlineIcon from '@mui/icons-material/HelpOutline';\nimport { useHelpDropdownMountPoints } from '../../hooks/useHelpDropdownMountPoints';\nimport { MenuSection } from './MenuSection';\n\n/**\n * @public\n * Props for Help Dropdown\n */\nexport interface HelpDropdownProps {\n layout?: CSSProperties;\n}\n\nexport const HelpDropdown = ({ layout }: HelpDropdownProps) => {\n const { anchorEl, handleOpen, handleClose } = useDropdownManager();\n\n const helpDropdownMountPoints = useHelpDropdownMountPoints();\n\n const menuItems = useMemo(() => {\n return (helpDropdownMountPoints ?? [])\n .map(mp => ({\n Component: mp.Component,\n icon: mp.config?.props?.icon,\n label: mp.config?.props?.title,\n link: mp.config?.props?.link,\n tooltip: mp.config?.props?.tooltip,\n style: mp.config?.style,\n priority: mp.config?.priority ?? 0,\n }))\n .sort((a, b) => (b.priority ?? 0) - (a.priority ?? 0));\n }, [helpDropdownMountPoints]);\n\n if (menuItems.length === 0) {\n return null;\n }\n\n return (\n <HeaderDropdownComponent\n isIconButton\n tooltip=\"Help\"\n buttonContent={<HelpOutlineIcon />}\n buttonProps={{\n color: 'inherit',\n sx: layout,\n }}\n onOpen={handleOpen}\n onClose={handleClose}\n anchorEl={anchorEl}\n >\n <MenuSection hideDivider items={menuItems} handleClose={handleClose} />\n </HeaderDropdownComponent>\n );\n};\n"],"names":[],"mappings":";;;;;;;;AAgCO,MAAM,YAAe,GAAA,CAAC,EAAE,MAAA,EAAgC,KAAA;AAC7D,EAAA,MAAM,EAAE,QAAA,EAAU,UAAY,EAAA,WAAA,KAAgB,kBAAmB,EAAA;AAEjE,EAAA,MAAM,0BAA0B,0BAA2B,EAAA;AAE3D,EAAM,MAAA,SAAA,GAAY,QAAQ,MAAM;AAC9B,IAAA,OAAA,CAAQ,uBAA2B,IAAA,EAChC,EAAA,GAAA,CAAI,CAAO,EAAA,MAAA;AAAA,MACV,WAAW,EAAG,CAAA,SAAA;AAAA,MACd,IAAA,EAAM,EAAG,CAAA,MAAA,EAAQ,KAAO,EAAA,IAAA;AAAA,MACxB,KAAA,EAAO,EAAG,CAAA,MAAA,EAAQ,KAAO,EAAA,KAAA;AAAA,MACzB,IAAA,EAAM,EAAG,CAAA,MAAA,EAAQ,KAAO,EAAA,IAAA;AAAA,MACxB,OAAA,EAAS,EAAG,CAAA,MAAA,EAAQ,KAAO,EAAA,OAAA;AAAA,MAC3B,KAAA,EAAO,GAAG,MAAQ,EAAA,KAAA;AAAA,MAClB,QAAA,EAAU,EAAG,CAAA,MAAA,EAAQ,QAAY,IAAA;AAAA,KACnC,CAAE,CACD,CAAA,IAAA,CAAK,CAAC,CAAA,EAAG,CAAO,KAAA,CAAA,CAAA,CAAE,QAAY,IAAA,CAAA,KAAM,CAAE,CAAA,QAAA,IAAY,CAAE,CAAA,CAAA;AAAA,GACzD,EAAG,CAAC,uBAAuB,CAAC,CAAA;AAE5B,EAAI,IAAA,SAAA,CAAU,WAAW,CAAG,EAAA;AAC1B,IAAO,OAAA,IAAA;AAAA;AAGT,EACE,uBAAA,GAAA;AAAA,IAAC,uBAAA;AAAA,IAAA;AAAA,MACC,YAAY,EAAA,IAAA;AAAA,MACZ,OAAQ,EAAA,MAAA;AAAA,MACR,aAAA,sBAAgB,eAAgB,EAAA,EAAA,CAAA;AAAA,MAChC,WAAa,EAAA;AAAA,QACX,KAAO,EAAA,SAAA;AAAA,QACP,EAAI,EAAA;AAAA,OACN;AAAA,MACA,MAAQ,EAAA,UAAA;AAAA,MACR,OAAS,EAAA,WAAA;AAAA,MACT,QAAA;AAAA,MAEA,8BAAC,WAAY,EAAA,EAAA,WAAA,EAAW,IAAC,EAAA,KAAA,EAAO,WAAW,WAA0B,EAAA;AAAA;AAAA,GACvE;AAEJ;;;;"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
|
+
import { useCallback } from 'react';
|
|
3
|
+
import MenuItem from '@mui/material/MenuItem';
|
|
4
|
+
import { MenuItemLink } from '../MenuItemLink/MenuItemLink.esm.js';
|
|
5
|
+
import { QUICKSTART_DRAWER_OPEN_KEY } from './const.esm.js';
|
|
6
|
+
import { useQuickstartButtonPermission } from './useQuickstartButtonPermission.esm.js';
|
|
7
|
+
|
|
8
|
+
const QuickstartButton = ({
|
|
9
|
+
icon = "quickstart",
|
|
10
|
+
title = "Quick start",
|
|
11
|
+
tooltip,
|
|
12
|
+
style
|
|
13
|
+
}) => {
|
|
14
|
+
const isAllowed = useQuickstartButtonPermission();
|
|
15
|
+
const toggleDrawer = useCallback(() => {
|
|
16
|
+
const isDrawerOpen = localStorage.getItem(QUICKSTART_DRAWER_OPEN_KEY) === "true";
|
|
17
|
+
localStorage.setItem(
|
|
18
|
+
QUICKSTART_DRAWER_OPEN_KEY,
|
|
19
|
+
(!isDrawerOpen).toString()
|
|
20
|
+
);
|
|
21
|
+
}, []);
|
|
22
|
+
return isAllowed ? /* @__PURE__ */ jsx(
|
|
23
|
+
MenuItem,
|
|
24
|
+
{
|
|
25
|
+
sx: { width: "100%", color: "inherit", ...style },
|
|
26
|
+
"data-testid": "quickstart-button",
|
|
27
|
+
onClick: toggleDrawer,
|
|
28
|
+
children: /* @__PURE__ */ jsx(MenuItemLink, { to: "", title, icon, tooltip })
|
|
29
|
+
}
|
|
30
|
+
) : null;
|
|
31
|
+
};
|
|
32
|
+
|
|
33
|
+
export { QuickstartButton };
|
|
34
|
+
//# sourceMappingURL=QuickstartButton.esm.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"QuickstartButton.esm.js","sources":["../../../src/components/QuickstartButton/QuickstartButton.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 { CSSProperties, useCallback } from 'react';\nimport MenuItem from '@mui/material/MenuItem';\nimport { MenuItemLink } from '../MenuItemLink/MenuItemLink';\nimport { QUICKSTART_DRAWER_OPEN_KEY } from './const';\nimport { useQuickstartButtonPermission } from './useQuickstartButtonPermission';\n\n/**\n * @public\n */\nexport interface QuickstartButtonProps {\n icon?: string;\n title?: string;\n tooltip?: string;\n style?: CSSProperties;\n}\n\n/**\n * @public\n */\nexport const QuickstartButton = ({\n icon = 'quickstart',\n title = 'Quick start',\n tooltip,\n style,\n}: QuickstartButtonProps) => {\n const isAllowed = useQuickstartButtonPermission();\n const toggleDrawer = useCallback(() => {\n const isDrawerOpen =\n localStorage.getItem(QUICKSTART_DRAWER_OPEN_KEY) === 'true';\n localStorage.setItem(\n QUICKSTART_DRAWER_OPEN_KEY,\n (!isDrawerOpen).toString(),\n );\n }, []);\n\n return isAllowed ? (\n <MenuItem\n sx={{ width: '100%', color: 'inherit', ...style }}\n data-testid=\"quickstart-button\"\n onClick={toggleDrawer}\n >\n <MenuItemLink to=\"\" title={title} icon={icon} tooltip={tooltip} />\n </MenuItem>\n ) : null;\n};\n"],"names":[],"mappings":";;;;;;;AAmCO,MAAM,mBAAmB,CAAC;AAAA,EAC/B,IAAO,GAAA,YAAA;AAAA,EACP,KAAQ,GAAA,aAAA;AAAA,EACR,OAAA;AAAA,EACA;AACF,CAA6B,KAAA;AAC3B,EAAA,MAAM,YAAY,6BAA8B,EAAA;AAChD,EAAM,MAAA,YAAA,GAAe,YAAY,MAAM;AACrC,IAAA,MAAM,YACJ,GAAA,YAAA,CAAa,OAAQ,CAAA,0BAA0B,CAAM,KAAA,MAAA;AACvD,IAAa,YAAA,CAAA,OAAA;AAAA,MACX,0BAAA;AAAA,MACC,CAAA,CAAC,cAAc,QAAS;AAAA,KAC3B;AAAA,GACF,EAAG,EAAE,CAAA;AAEL,EAAA,OAAO,SACL,mBAAA,GAAA;AAAA,IAAC,QAAA;AAAA,IAAA;AAAA,MACC,IAAI,EAAE,KAAA,EAAO,QAAQ,KAAO,EAAA,SAAA,EAAW,GAAG,KAAM,EAAA;AAAA,MAChD,aAAY,EAAA,mBAAA;AAAA,MACZ,OAAS,EAAA,YAAA;AAAA,MAET,8BAAC,YAAa,EAAA,EAAA,EAAA,EAAG,EAAG,EAAA,KAAA,EAAc,MAAY,OAAkB,EAAA;AAAA;AAAA,GAEhE,GAAA,IAAA;AACN;;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"const.esm.js","sources":["../../../src/components/QuickstartButton/const.ts"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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\nexport const QUICKSTART_DRAWER_OPEN_KEY = 'quickstart-drawer-open';\n"],"names":[],"mappings":"AAgBO,MAAM,0BAA6B,GAAA;;;;"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { useApi, identityApiRef, configApiRef } from '@backstage/core-plugin-api';
|
|
2
|
+
import { useAsync } from 'react-use';
|
|
3
|
+
|
|
4
|
+
const useQuickstartButtonPermission = () => {
|
|
5
|
+
const identityApi = useApi(identityApiRef);
|
|
6
|
+
const configApi = useApi(configApiRef);
|
|
7
|
+
const getUserAuthorization = async () => {
|
|
8
|
+
const { token: idToken } = await identityApi.getCredentials();
|
|
9
|
+
const backendUrl = configApi.getString("backend.baseUrl");
|
|
10
|
+
const jsonResponse = await fetch(`${backendUrl}/api/permission/`, {
|
|
11
|
+
headers: {
|
|
12
|
+
...idToken && { Authorization: `Bearer ${idToken}` }
|
|
13
|
+
}
|
|
14
|
+
});
|
|
15
|
+
return jsonResponse.json();
|
|
16
|
+
};
|
|
17
|
+
const { loading: isUserLoading, value: result } = useAsync(
|
|
18
|
+
async () => await getUserAuthorization(),
|
|
19
|
+
[]
|
|
20
|
+
);
|
|
21
|
+
const isRBACPluginEnabled = configApi.getOptionalBoolean("permission.enabled");
|
|
22
|
+
if (!isRBACPluginEnabled) return true;
|
|
23
|
+
return !isUserLoading && result.status === "Authorized";
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
export { useQuickstartButtonPermission };
|
|
27
|
+
//# sourceMappingURL=useQuickstartButtonPermission.esm.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useQuickstartButtonPermission.esm.js","sources":["../../../src/components/QuickstartButton/useQuickstartButtonPermission.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 configApiRef,\n identityApiRef,\n useApi,\n} from '@backstage/core-plugin-api';\nimport { useAsync } from 'react-use';\n\nexport const useQuickstartButtonPermission = () => {\n const identityApi = useApi(identityApiRef);\n const configApi = useApi(configApiRef);\n\n const getUserAuthorization = async () => {\n const { token: idToken } = await identityApi.getCredentials();\n const backendUrl = configApi.getString('backend.baseUrl');\n const jsonResponse = await fetch(`${backendUrl}/api/permission/`, {\n headers: {\n ...(idToken && { Authorization: `Bearer ${idToken}` }),\n },\n });\n return jsonResponse.json();\n };\n const { loading: isUserLoading, value: result } = useAsync(\n async () => await getUserAuthorization(),\n [],\n );\n\n const isRBACPluginEnabled =\n configApi.getOptionalBoolean('permission.enabled');\n\n if (!isRBACPluginEnabled) return true;\n\n return !isUserLoading && result.status === 'Authorized';\n};\n"],"names":[],"mappings":";;;AAuBO,MAAM,gCAAgC,MAAM;AACjD,EAAM,MAAA,WAAA,GAAc,OAAO,cAAc,CAAA;AACzC,EAAM,MAAA,SAAA,GAAY,OAAO,YAAY,CAAA;AAErC,EAAA,MAAM,uBAAuB,YAAY;AACvC,IAAA,MAAM,EAAE,KAAO,EAAA,OAAA,EAAY,GAAA,MAAM,YAAY,cAAe,EAAA;AAC5D,IAAM,MAAA,UAAA,GAAa,SAAU,CAAA,SAAA,CAAU,iBAAiB,CAAA;AACxD,IAAA,MAAM,YAAe,GAAA,MAAM,KAAM,CAAA,CAAA,EAAG,UAAU,CAAoB,gBAAA,CAAA,EAAA;AAAA,MAChE,OAAS,EAAA;AAAA,QACP,GAAI,OAAW,IAAA,EAAE,aAAe,EAAA,CAAA,OAAA,EAAU,OAAO,CAAG,CAAA;AAAA;AACtD,KACD,CAAA;AACD,IAAA,OAAO,aAAa,IAAK,EAAA;AAAA,GAC3B;AACA,EAAA,MAAM,EAAE,OAAA,EAAS,aAAe,EAAA,KAAA,EAAO,QAAW,GAAA,QAAA;AAAA,IAChD,YAAY,MAAM,oBAAqB,EAAA;AAAA,IACvC;AAAC,GACH;AAEA,EAAM,MAAA,mBAAA,GACJ,SAAU,CAAA,kBAAA,CAAmB,oBAAoB,CAAA;AAEnD,EAAI,IAAA,CAAC,qBAA4B,OAAA,IAAA;AAEjC,EAAO,OAAA,CAAC,aAAiB,IAAA,MAAA,CAAO,MAAW,KAAA,YAAA;AAC7C;;;;"}
|
|
@@ -1,19 +1,15 @@
|
|
|
1
1
|
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { useApiHolder, configApiRef } from '@backstage/core-plugin-api';
|
|
3
|
-
import { Link
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import Tooltip from '@mui/material/Tooltip';
|
|
7
|
-
import HelpIcon from '@mui/icons-material/HelpOutline';
|
|
3
|
+
import { Link } from '@backstage/core-components';
|
|
4
|
+
import MenuItem from '@mui/material/MenuItem';
|
|
5
|
+
import { MenuItemLink } from '../MenuItemLink/MenuItemLink.esm.js';
|
|
8
6
|
|
|
9
|
-
const Link = (props) => /* @__PURE__ */ jsx(Link$1, { ...props, color: "inherit", externalLinkIcon: false });
|
|
10
7
|
const SupportButton = ({
|
|
11
8
|
title = "Support",
|
|
12
|
-
tooltip,
|
|
13
|
-
color = "inherit",
|
|
14
|
-
size = "small",
|
|
15
9
|
to,
|
|
16
|
-
|
|
10
|
+
icon = "support",
|
|
11
|
+
tooltip,
|
|
12
|
+
style
|
|
17
13
|
}) => {
|
|
18
14
|
const apiHolder = useApiHolder();
|
|
19
15
|
const config = apiHolder.get(configApiRef);
|
|
@@ -21,24 +17,24 @@ const SupportButton = ({
|
|
|
21
17
|
if (!supportUrl) {
|
|
22
18
|
return null;
|
|
23
19
|
}
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
Tooltip,
|
|
20
|
+
return /* @__PURE__ */ jsx(
|
|
21
|
+
MenuItem,
|
|
27
22
|
{
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
23
|
+
to: supportUrl,
|
|
24
|
+
component: Link,
|
|
25
|
+
sx: { width: "100%", color: "inherit", ...style },
|
|
26
|
+
"data-testid": "support-button",
|
|
27
|
+
children: /* @__PURE__ */ jsx(
|
|
28
|
+
MenuItemLink,
|
|
31
29
|
{
|
|
32
|
-
component: Link,
|
|
33
|
-
color,
|
|
34
|
-
size,
|
|
35
30
|
to: supportUrl,
|
|
36
|
-
|
|
37
|
-
|
|
31
|
+
title,
|
|
32
|
+
icon,
|
|
33
|
+
tooltip
|
|
38
34
|
}
|
|
39
|
-
)
|
|
35
|
+
)
|
|
40
36
|
}
|
|
41
|
-
)
|
|
37
|
+
);
|
|
42
38
|
};
|
|
43
39
|
|
|
44
40
|
export { SupportButton };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SupportButton.esm.js","sources":["../../../src/components/SupportButton/SupportButton.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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":"SupportButton.esm.js","sources":["../../../src/components/SupportButton/SupportButton.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 { configApiRef, useApiHolder } from '@backstage/core-plugin-api';\nimport { Link } from '@backstage/core-components';\nimport MenuItem from '@mui/material/MenuItem';\nimport { MenuItemLink } from '../MenuItemLink/MenuItemLink';\nimport { CSSProperties } from 'react';\n\n/**\n * @public\n */\nexport interface SupportButtonProps {\n icon?: string;\n title?: string;\n to?: string;\n tooltip?: string;\n style?: CSSProperties;\n}\n/**\n * @public\n */\nexport const SupportButton = ({\n title = 'Support',\n to,\n icon = 'support',\n tooltip,\n style,\n}: SupportButtonProps) => {\n const apiHolder = useApiHolder();\n const config = apiHolder.get(configApiRef);\n const supportUrl = to ?? config?.getOptionalString('app.support.url');\n\n if (!supportUrl) {\n return null;\n }\n\n return (\n <MenuItem\n to={supportUrl}\n component={Link}\n sx={{ width: '100%', color: 'inherit', ...style }}\n data-testid=\"support-button\"\n >\n <MenuItemLink\n to={supportUrl}\n title={title}\n icon={icon}\n tooltip={tooltip}\n />\n </MenuItem>\n );\n};\n"],"names":[],"mappings":";;;;;;AAmCO,MAAM,gBAAgB,CAAC;AAAA,EAC5B,KAAQ,GAAA,SAAA;AAAA,EACR,EAAA;AAAA,EACA,IAAO,GAAA,SAAA;AAAA,EACP,OAAA;AAAA,EACA;AACF,CAA0B,KAAA;AACxB,EAAA,MAAM,YAAY,YAAa,EAAA;AAC/B,EAAM,MAAA,MAAA,GAAS,SAAU,CAAA,GAAA,CAAI,YAAY,CAAA;AACzC,EAAA,MAAM,UAAa,GAAA,EAAA,IAAM,MAAQ,EAAA,iBAAA,CAAkB,iBAAiB,CAAA;AAEpE,EAAA,IAAI,CAAC,UAAY,EAAA;AACf,IAAO,OAAA,IAAA;AAAA;AAGT,EACE,uBAAA,GAAA;AAAA,IAAC,QAAA;AAAA,IAAA;AAAA,MACC,EAAI,EAAA,UAAA;AAAA,MACJ,SAAW,EAAA,IAAA;AAAA,MACX,IAAI,EAAE,KAAA,EAAO,QAAQ,KAAO,EAAA,SAAA,EAAW,GAAG,KAAM,EAAA;AAAA,MAChD,aAAY,EAAA,gBAAA;AAAA,MAEZ,QAAA,kBAAA,GAAA;AAAA,QAAC,YAAA;AAAA,QAAA;AAAA,UACC,EAAI,EAAA,UAAA;AAAA,UACJ,KAAA;AAAA,UACA,IAAA;AAAA,UACA;AAAA;AAAA;AACF;AAAA,GACF;AAEJ;;;;"}
|
|
@@ -12,6 +12,8 @@ import { Spacer } from '../components/Spacer/Spacer.esm.js';
|
|
|
12
12
|
import { StarredDropdown } from '../components/HeaderDropdownComponent/StarredDropdown.esm.js';
|
|
13
13
|
import { ApplicationLauncherDropdown } from '../components/HeaderDropdownComponent/ApplicationLauncherDropdown.esm.js';
|
|
14
14
|
import { CompanyLogo } from '../components/CompanyLogo/CompanyLogo.esm.js';
|
|
15
|
+
import { HelpDropdown } from '../components/HeaderDropdownComponent/HelpDropdown.esm.js';
|
|
16
|
+
import { QuickstartButton } from '../components/QuickstartButton/QuickstartButton.esm.js';
|
|
15
17
|
|
|
16
18
|
const defaultGlobalHeaderComponentsMountPoints = [
|
|
17
19
|
{
|
|
@@ -72,7 +74,7 @@ const defaultGlobalHeaderComponentsMountPoints = [
|
|
|
72
74
|
}
|
|
73
75
|
},
|
|
74
76
|
{
|
|
75
|
-
Component:
|
|
77
|
+
Component: HelpDropdown,
|
|
76
78
|
config: {
|
|
77
79
|
priority: 80
|
|
78
80
|
}
|
|
@@ -130,6 +132,20 @@ const defaultProfileDropdownMountPoints = [
|
|
|
130
132
|
}
|
|
131
133
|
}
|
|
132
134
|
];
|
|
135
|
+
const defaultHelpDropdownMountPoints = [
|
|
136
|
+
{
|
|
137
|
+
Component: QuickstartButton,
|
|
138
|
+
config: {
|
|
139
|
+
priority: 100
|
|
140
|
+
}
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
Component: SupportButton,
|
|
144
|
+
config: {
|
|
145
|
+
priority: 10
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
];
|
|
133
149
|
const defaultApplicationLauncherDropdownMountPoints = [
|
|
134
150
|
{
|
|
135
151
|
Component: MenuItemLink,
|
|
@@ -157,5 +173,5 @@ const defaultApplicationLauncherDropdownMountPoints = [
|
|
|
157
173
|
}
|
|
158
174
|
];
|
|
159
175
|
|
|
160
|
-
export { defaultApplicationLauncherDropdownMountPoints, defaultCreateDropdownMountPoints, defaultGlobalHeaderComponentsMountPoints, defaultProfileDropdownMountPoints };
|
|
176
|
+
export { defaultApplicationLauncherDropdownMountPoints, defaultCreateDropdownMountPoints, defaultGlobalHeaderComponentsMountPoints, defaultHelpDropdownMountPoints, defaultProfileDropdownMountPoints };
|
|
161
177
|
//# sourceMappingURL=defaultMountPoints.esm.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"defaultMountPoints.esm.js","sources":["../../src/defaultMountPoints/defaultMountPoints.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 type { CSSProperties, ComponentType } from 'react';\nimport { LogoutButton } from '../components/LogoutButton/LogoutButton';\nimport { CreateDropdown } from '../components/HeaderDropdownComponent/CreateDropdown';\nimport { ProfileDropdown } from '../components/HeaderDropdownComponent/ProfileDropdown';\nimport { RegisterAComponentSection } from '../components/HeaderDropdownComponent/RegisterAComponentSection';\nimport { SoftwareTemplatesSection } from '../components/HeaderDropdownComponent/SoftwareTemplatesSection';\nimport { SearchComponent } from '../components/SearchComponent/SearchComponent';\nimport { SupportButton } from '../components/SupportButton/SupportButton';\nimport {\n ApplicationLauncherDropdownMountPoint,\n CreateDropdownMountPoint,\n GlobalHeaderComponentMountPoint,\n ProfileDropdownMountPoint,\n} from '../types';\nimport { NotificationButton } from '../components/NotificationButton/NotificationButton';\nimport { Divider } from '../components/Divider/Divider';\nimport { MenuItemLink } from '../components/MenuItemLink/MenuItemLink';\nimport { Spacer } from '../components/Spacer/Spacer';\nimport { StarredDropdown } from '../components/HeaderDropdownComponent/StarredDropdown';\nimport { ApplicationLauncherDropdown } from '../components/HeaderDropdownComponent/ApplicationLauncherDropdown';\nimport { CompanyLogo } from '../components/CompanyLogo/CompanyLogo';\n\n/**\n * default Global Header Components mount points\n *\n * @public\n */\nexport const defaultGlobalHeaderComponentsMountPoints: GlobalHeaderComponentMountPoint[] =\n [\n {\n Component: CompanyLogo,\n config: {\n priority: 200,\n props: {\n to: '/catalog',\n logo: {\n light:\n 'data:image/svg+xml,%3Csvg%20width%3D%22451.199%22%20height%3D%2279.993%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cg%20style%3D%22fill%3A%23000%22%3E%3Cpath%20d%3D%22M6.3052259-2.8329q0-.6232379-.226632-1.1574419-.218538-.534204-.615144-.922716-.388512-.396606-.922716-.615144-.534204-.226632-1.157442-.226632-.6232379%200-1.1574419.226632-.534204.218538-.93081.615144-.38851202.388512-.61514401.922716-.218538.534204-.218538%201.1574419%200%20.623238.218538%201.157442.22663199.534204.61514401.93081001.396606.388512.93081.61514399.534204.218538%201.1574419.218538.623238%200%201.157442-.218538.534204-.22663199.922716-.61514399.396606-.39660601.615144-.93081001.226632-.534204.226632-1.157442zm-.598956%200q0%20.52611-.178068.963186-.178068.428982-.48564.736554-.307572.30757201-.736554.47754601-.428982.169974-.922716.169974-.5018279%200-.9308099-.169974-.420888-.169974-.72846-.47754601-.307572-.307572-.48564-.736554-.178068-.437076-.178068-.963186%200-.5261099.178068-.9550919.178068-.437076.48564-.744648.307572-.307572.72846-.477546.428982-.169974.9308099-.169974.493734%200%20.922716.169974t.736554.477546q.307572.307572.48564.744648.178068.428982.178068.9550919zm-.825588%201.513578-.631332-1.206006q.259008-.12141.412794-.339948.16188-.2266319.16188-.5908619%200-.56658-.339948-.801306t-.898434-.234726H2.161098v3.1728479h.8660579V-2.38773h.356136l.518016%201.068408zm-.93081-2.1125339q0%20.169974-.097128.259008-.089034.089034-.307572.089034h-.518016v-.68799h.534204q.210444%200%20.299478.097128.089034.089034.089034.24282z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%20169.9661%207.67311)%22%20aria-label%3D%22%C2%AE%22%2F%3E%3Cpath%20d%3D%22M25.629191-15.26571q0-3.87018-1.032048-6.665309-1.032048-2.79513-2.881134-4.601214-1.806084-1.849086-4.343201-2.709126-2.494116-.86004-5.461254-.86004H3.9561839V0h7.3533421q3.01014%200%205.633262-.81703798Q19.56591-1.677078%2021.500999-3.5261639q1.93509-1.849086%203.01014-4.7302199%201.118052-2.9241362%201.118052-7.0093262zm-3.354156.129006q0%203.22515-.731034%205.5472582-.731034%202.279106-2.107097%203.7411739-1.376064%201.462068-3.311154%202.1501-1.93509.64503-4.386204.64503H7.3103398V-27.048257h4.3432022q5.203242%200%207.912368%203.053142%202.709125%203.053142%202.709125%208.858411zM51.043415%200v-3.0531419h-15.48072V-14.534676h8.6004v-3.053142h-8.6004v-9.460439h14.83569v-3.053142H32.208539V0Zm28.553323-30.101399h-3.44016L69.405264-9.5894458l-.516024%201.548072q-.258012.86004-.559026%201.72008-.258012.8600399-.473021%201.6340759-.21501.731034-.344016%201.118052-.129006-.387018-.344016-1.118052-.21501-.731034-.473022-1.5480719-.258012-.86004-.559026-1.72008-.258012-.86004-.473022-1.548072L58.955779-30.101399h-3.526164L65.664091%200h3.698171zM104.62387%200v-3.0531419H89.143149V-14.534676h8.6004v-3.053142h-8.6004v-9.460439h14.835691v-3.053142H85.788993V0Zm24.64014%200v-3.0531419h-14.8787V-30.101399h-3.35415V0Zm29.06938-15.093702q0-3.397158-.90304-6.235289-.90304-2.838132-2.53712-4.902228t-3.95618-3.182148q-2.27911-1.161054-5.07424-1.161054-2.79513%200-5.11724%201.161054-2.3221%201.161054-3.95618%203.22515t-2.53712%204.94523q-.90304%202.838131-.90304%206.235289%200%203.397158.86004%206.2352902.90304%202.838132%202.53712%204.9022279%201.63407%202.0640959%203.91318%203.22514992%202.32211%201.11805197%205.11724%201.11805197t5.11723-1.16105397q2.32211-1.16105402%203.95619-3.22514992%201.67708-2.0640959%202.58012-4.9022279.90304-2.8811342.90304-6.2782922zm-3.35416.086q0%202.838132-.68803%205.1602403-.68803%202.2791059-1.89209%203.9131819-1.20405%201.5910739-2.88113%202.4941159-1.67708.86004-3.61217.86004-1.97809%200-3.65517-.86004-1.67707-.903042-2.92413-2.5371179-1.20406-1.677078-1.93509-3.9561839-.68803-2.3221083-.68803-5.1602403t.68803-5.117237q.68803-2.322108%201.89209-3.913182%201.20405-1.634076%202.83813-2.494116%201.67708-.903042%203.61217-.903042%201.97809%200%203.65516.903042%201.67708.86004%202.92414%202.537118%201.24706%201.634076%201.93509%203.956184.73103%202.279105.73103%205.117237zm30.83244-6.106283q0-2.279106-.73104-3.956184-.73103-1.72008-2.02109-2.838132-1.29006-1.118052-3.05314-1.634076-1.72008-.559026-3.78418-.559026H164.9557V0h3.35415v-11.82555h7.31034q2.23611%200%204.12819-.602028%201.89209-.602028%203.22515-1.763082%201.33307-1.204056%202.0641-2.924136.77404-1.763082.77404-3.999185zm-3.35416.129006q0%206.106283-6.79432%206.106283h-7.35334v-12.169565h7.78336q3.09615%200%204.73022%201.591074%201.63408%201.548072%201.63408%204.472208zM210.32281%200v-3.0531419h-15.48072V-14.534676h8.6004v-3.053142h-8.6004v-9.460439h14.83569v-3.053142h-18.18984V0Zm27.69329-21.587003q0-2.193102-.73103-3.784176-.73104-1.591074-1.9781-2.623122-1.24705-1.07505-2.96713-1.591074t-3.69818-.516024h-11.91155V0h3.35416v-12.814596h7.13833L233.6729%200h3.87018l-6.62231-13.072608q3.22515-.688032%205.16024-2.838132%201.93509-2.1501%201.93509-5.676263zm-3.35416.129006q0%202.838131-1.63407%204.257197-1.59108%201.376064-4.94523%201.376064h-7.99837v-11.223521h8.42839q3.01014%200%204.55821%201.419066%201.59107%201.376064%201.59107%204.171194zM277.49192%200v-30.101399h-3.35415v12.857597h-14.9647v-12.857597h-3.35415V0h3.35415v-14.19066h14.9647V0Zm29.37035-12.298572v-17.802827h-3.35415v17.888831q0%204.9022282-1.67708%207.2673381-1.67708%202.36511-5.59026%202.36511-7.69736%200-7.69736-9.7184521v-17.802827h-3.35416v17.888831q0%206.2782922%202.70913%209.5034421%202.75213%203.18214789%208.17038%203.18214789%205.46125%200%208.12738-3.22514989%202.66612-3.2681519%202.66612-9.5464441zm28.2523%203.3971582q0-1.8060842-.51603-3.0961442-.51602-1.333062-1.33306-2.193102-.81704-.903042-1.84909-1.419066-1.03204-.559026-2.06409-.817038%201.93509-.688032%203.13914-2.1501%201.20406-1.505069%201.20406-3.999185%200-1.93509-.60203-3.354156-.60203-1.419066-1.72008-2.322108-1.07505-.946044-2.58012-1.376064-1.46207-.473022-3.26815-.473022h-11.00851V0h10.7935q4.77322%200%207.26734-2.1931019%202.53712-2.236104%202.53712-6.7083119zm-4.77323-13.5456292q0%201.978092-1.20405%203.397157-1.20406%201.376064-3.99919%201.376064h-7.26734v-9.374435h7.52535q2.53712%200%203.74118%201.29006%201.20405%201.247058%201.20405%203.311154zm1.41907%2013.7176372q0%202.58012-1.41907%204.1281919-1.41906%201.548072-4.81622%201.548072h-7.65436V-14.663682h7.48235q2.96714%200%204.68722%201.548072%201.72008%201.548072%201.72008%204.3862042z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%20-5.23714%2079.36255)%22%20aria-label%3D%22DEVELOPER%20HUB%22%2F%3E%3Cpath%20d%3D%22m18.792026%200-3.92084-7.4776021q1.624348-.7281561%202.576552-2.1284561.952204-1.4002998.952204-3.6127738%200-1.736372-.56012-2.94063-.532114-1.232264-1.54033-1.988426t-2.436522-1.092234q-1.4003-.364078-3.108666-.364078H1.988426V0h5.3491461v-6.6094161h2.1844681L12.714724%200Zm-5.797242-13.078802q0%201.064228-.56012%201.624348t-1.904408.56012H7.3375721v-4.284918h3.2767019q1.288276%200%201.82039.588126.56012.588126.56012%201.512324zM37.219965%200v-4.5649781h-9.830106v-3.36072h5.797242v-4.5089659h-5.797242v-2.604558h9.634064V-19.6042H22.012707V0Zm20.388361-9.9141242q0-2.7725938-.728156-4.6209898-.70015-1.848396-2.016432-2.968636-1.288276-1.148246-3.164678-1.624348-1.876402-.476102-4.172894-.476102h-6.86147V0h6.357362q2.604558%200%204.564978-.50410801Q53.575462-1.036222%2054.91975-2.184468q1.344288-1.1762521%202.016432-3.0526541.672144-1.904408.672144-4.6770021zm-5.573194.084018q0%201.456312-.252054%202.4645281-.252054.98021-.84018%201.596342-.56012.588126-1.456312.868186-.896192.252054-2.156462.252054h-1.176252V-14.955204h1.344288q1.26027%200%202.128456.308066.868186.28006%201.4003.896192.532114.616132.756162%201.596342.252054.98021.252054%202.3244978z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%20-2.65123%2027.43044)%22%20aria-label%3D%22RED%22%2F%3E%3Cpath%20d%3D%22M6.3052259-2.8329q0-.6232379-.226632-1.1574419-.218538-.534204-.615144-.922716-.388512-.396606-.922716-.615144-.534204-.226632-1.157442-.226632-.6232379%200-1.1574419.226632-.534204.218538-.93081.615144-.38851202.388512-.61514401.922716-.218538.534204-.218538%201.1574419%200%20.623238.218538%201.157442.22663199.534204.61514401.93081001.396606.388512.93081.61514399.534204.218538%201.1574419.218538.623238%200%201.157442-.218538.534204-.22663199.922716-.61514399.396606-.39660601.615144-.93081001.226632-.534204.226632-1.157442zm-.598956%200q0%20.52611-.178068.963186-.178068.428982-.48564.736554-.307572.30757201-.736554.47754601-.428982.169974-.922716.169974-.5018279%200-.9308099-.169974-.420888-.169974-.72846-.47754601-.307572-.307572-.48564-.736554-.178068-.437076-.178068-.963186%200-.5261099.178068-.9550919.178068-.437076.48564-.744648.307572-.307572.72846-.477546.428982-.169974.9308099-.169974.493734%200%20.922716.169974t.736554.477546q.307572.307572.48564.744648.178068.428982.178068.9550919zm-.825588%201.513578-.631332-1.206006q.259008-.12141.412794-.339948.16188-.2266319.16188-.5908619%200-.56658-.339948-.801306t-.898434-.234726H2.161098v3.1728479h.8660579V-2.38773h.356136l.518016%201.068408zm-.93081-2.1125339q0%20.169974-.097128.259008-.089034.089034-.307572.089034h-.518016v-.68799h.534204q.210444%200%20.299478.097128.089034.089034.089034.24282z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%20442.7922%2047.06522)%22%20aria-label%3D%22%C2%AE%22%2F%3E%3Cpath%20d%3D%22M19.18411%200v-19.6042h-5.545188v7.14153H7.5336141v-7.14153H1.988426V0h5.5451881v-7.7296561h6.1053079V0Zm22.488833%200-7.113524-19.6042h-5.489176L21.956719%200h5.825248l1.064228-3.4447381h5.88126L35.791683%200Zm-8.26177-7.7576621h-3.248696l.364078-1.2882761q.252054-.924198.448096-1.6243478.196042-.70015.336072-1.26027.168036-.56012.28006-1.036222.112024-.476102.196042-.98021.08402.504108.196042.98021l.252054%201.008216q.168036.56012.364078%201.26027.196042.7001498.448096%201.6523538zm23.973112-7.1135239V-19.6042H40.972768v4.733014h5.489177V0h5.433164v-14.871186z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%2089.90877%2027.43044)%22%20aria-label%3D%22HAT%22%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E',\n dark: 'data:image/svg+xml,%3Csvg%20width%3D%22451.199%22%20height%3D%2279.993%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cg%20style%3D%22fill%3A%23fff%22%3E%3Cpath%20d%3D%22M6.3052259-2.8329q0-.6232379-.226632-1.1574419-.218538-.534204-.615144-.922716-.388512-.396606-.922716-.615144-.534204-.226632-1.157442-.226632-.6232379%200-1.1574419.226632-.534204.218538-.93081.615144-.38851202.388512-.61514401.922716-.218538.534204-.218538%201.1574419%200%20.623238.218538%201.157442.22663199.534204.61514401.93081001.396606.388512.93081.61514399.534204.218538%201.1574419.218538.623238%200%201.157442-.218538.534204-.22663199.922716-.61514399.396606-.39660601.615144-.93081001.226632-.534204.226632-1.157442zm-.598956%200q0%20.52611-.178068.963186-.178068.428982-.48564.736554-.307572.30757201-.736554.47754601-.428982.169974-.922716.169974-.5018279%200-.9308099-.169974-.420888-.169974-.72846-.47754601-.307572-.307572-.48564-.736554-.178068-.437076-.178068-.963186%200-.5261099.178068-.9550919.178068-.437076.48564-.744648.307572-.307572.72846-.477546.428982-.169974.9308099-.169974.493734%200%20.922716.169974t.736554.477546q.307572.307572.48564.744648.178068.428982.178068.9550919zm-.825588%201.513578-.631332-1.206006q.259008-.12141.412794-.339948.16188-.2266319.16188-.5908619%200-.56658-.339948-.801306t-.898434-.234726H2.161098v3.1728479h.8660579V-2.38773h.356136l.518016%201.068408zm-.93081-2.1125339q0%20.169974-.097128.259008-.089034.089034-.307572.089034h-.518016v-.68799h.534204q.210444%200%20.299478.097128.089034.089034.089034.24282z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%20169.9661%207.67311)%22%20aria-label%3D%22%C2%AE%22%2F%3E%3Cpath%20d%3D%22M25.629191-15.26571q0-3.87018-1.032048-6.665309-1.032048-2.79513-2.881134-4.601214-1.806084-1.849086-4.343201-2.709126-2.494116-.86004-5.461254-.86004H3.9561839V0h7.3533421q3.01014%200%205.633262-.81703798Q19.56591-1.677078%2021.500999-3.5261639q1.93509-1.849086%203.01014-4.7302199%201.118052-2.9241362%201.118052-7.0093262zm-3.354156.129006q0%203.22515-.731034%205.5472582-.731034%202.279106-2.107097%203.7411739-1.376064%201.462068-3.311154%202.1501-1.93509.64503-4.386204.64503H7.3103398V-27.048257h4.3432022q5.203242%200%207.912368%203.053142%202.709125%203.053142%202.709125%208.858411zM51.043415%200v-3.0531419h-15.48072V-14.534676h8.6004v-3.053142h-8.6004v-9.460439h14.83569v-3.053142H32.208539V0Zm28.553323-30.101399h-3.44016L69.405264-9.5894458l-.516024%201.548072q-.258012.86004-.559026%201.72008-.258012.8600399-.473021%201.6340759-.21501.731034-.344016%201.118052-.129006-.387018-.344016-1.118052-.21501-.731034-.473022-1.5480719-.258012-.86004-.559026-1.72008-.258012-.86004-.473022-1.548072L58.955779-30.101399h-3.526164L65.664091%200h3.698171zM104.62387%200v-3.0531419H89.143149V-14.534676h8.6004v-3.053142h-8.6004v-9.460439h14.835691v-3.053142H85.788993V0Zm24.64014%200v-3.0531419h-14.8787V-30.101399h-3.35415V0Zm29.06938-15.093702q0-3.397158-.90304-6.235289-.90304-2.838132-2.53712-4.902228t-3.95618-3.182148q-2.27911-1.161054-5.07424-1.161054-2.79513%200-5.11724%201.161054-2.3221%201.161054-3.95618%203.22515t-2.53712%204.94523q-.90304%202.838131-.90304%206.235289%200%203.397158.86004%206.2352902.90304%202.838132%202.53712%204.9022279%201.63407%202.0640959%203.91318%203.22514992%202.32211%201.11805197%205.11724%201.11805197t5.11723-1.16105397q2.32211-1.16105402%203.95619-3.22514992%201.67708-2.0640959%202.58012-4.9022279.90304-2.8811342.90304-6.2782922zm-3.35416.086q0%202.838132-.68803%205.1602403-.68803%202.2791059-1.89209%203.9131819-1.20405%201.5910739-2.88113%202.4941159-1.67708.86004-3.61217.86004-1.97809%200-3.65517-.86004-1.67707-.903042-2.92413-2.5371179-1.20406-1.677078-1.93509-3.9561839-.68803-2.3221083-.68803-5.1602403t.68803-5.117237q.68803-2.322108%201.89209-3.913182%201.20405-1.634076%202.83813-2.494116%201.67708-.903042%203.61217-.903042%201.97809%200%203.65516.903042%201.67708.86004%202.92414%202.537118%201.24706%201.634076%201.93509%203.956184.73103%202.279105.73103%205.117237zm30.83244-6.106283q0-2.279106-.73104-3.956184-.73103-1.72008-2.02109-2.838132-1.29006-1.118052-3.05314-1.634076-1.72008-.559026-3.78418-.559026H164.9557V0h3.35415v-11.82555h7.31034q2.23611%200%204.12819-.602028%201.89209-.602028%203.22515-1.763082%201.33307-1.204056%202.0641-2.924136.77404-1.763082.77404-3.999185zm-3.35416.129006q0%206.106283-6.79432%206.106283h-7.35334v-12.169565h7.78336q3.09615%200%204.73022%201.591074%201.63408%201.548072%201.63408%204.472208zM210.32281%200v-3.0531419h-15.48072V-14.534676h8.6004v-3.053142h-8.6004v-9.460439h14.83569v-3.053142h-18.18984V0Zm27.69329-21.587003q0-2.193102-.73103-3.784176-.73104-1.591074-1.9781-2.623122-1.24705-1.07505-2.96713-1.591074t-3.69818-.516024h-11.91155V0h3.35416v-12.814596h7.13833L233.6729%200h3.87018l-6.62231-13.072608q3.22515-.688032%205.16024-2.838132%201.93509-2.1501%201.93509-5.676263zm-3.35416.129006q0%202.838131-1.63407%204.257197-1.59108%201.376064-4.94523%201.376064h-7.99837v-11.223521h8.42839q3.01014%200%204.55821%201.419066%201.59107%201.376064%201.59107%204.171194zM277.49192%200v-30.101399h-3.35415v12.857597h-14.9647v-12.857597h-3.35415V0h3.35415v-14.19066h14.9647V0Zm29.37035-12.298572v-17.802827h-3.35415v17.888831q0%204.9022282-1.67708%207.2673381-1.67708%202.36511-5.59026%202.36511-7.69736%200-7.69736-9.7184521v-17.802827h-3.35416v17.888831q0%206.2782922%202.70913%209.5034421%202.75213%203.18214789%208.17038%203.18214789%205.46125%200%208.12738-3.22514989%202.66612-3.2681519%202.66612-9.5464441zm28.2523%203.3971582q0-1.8060842-.51603-3.0961442-.51602-1.333062-1.33306-2.193102-.81704-.903042-1.84909-1.419066-1.03204-.559026-2.06409-.817038%201.93509-.688032%203.13914-2.1501%201.20406-1.505069%201.20406-3.999185%200-1.93509-.60203-3.354156-.60203-1.419066-1.72008-2.322108-1.07505-.946044-2.58012-1.376064-1.46207-.473022-3.26815-.473022h-11.00851V0h10.7935q4.77322%200%207.26734-2.1931019%202.53712-2.236104%202.53712-6.7083119zm-4.77323-13.5456292q0%201.978092-1.20405%203.397157-1.20406%201.376064-3.99919%201.376064h-7.26734v-9.374435h7.52535q2.53712%200%203.74118%201.29006%201.20405%201.247058%201.20405%203.311154zm1.41907%2013.7176372q0%202.58012-1.41907%204.1281919-1.41906%201.548072-4.81622%201.548072h-7.65436V-14.663682h7.48235q2.96714%200%204.68722%201.548072%201.72008%201.548072%201.72008%204.3862042z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%20-5.23714%2079.36255)%22%20aria-label%3D%22DEVELOPER%20HUB%22%2F%3E%3Cpath%20d%3D%22m18.792026%200-3.92084-7.4776021q1.624348-.7281561%202.576552-2.1284561.952204-1.4002998.952204-3.6127738%200-1.736372-.56012-2.94063-.532114-1.232264-1.54033-1.988426t-2.436522-1.092234q-1.4003-.364078-3.108666-.364078H1.988426V0h5.3491461v-6.6094161h2.1844681L12.714724%200Zm-5.797242-13.078802q0%201.064228-.56012%201.624348t-1.904408.56012H7.3375721v-4.284918h3.2767019q1.288276%200%201.82039.588126.56012.588126.56012%201.512324zM37.219965%200v-4.5649781h-9.830106v-3.36072h5.797242v-4.5089659h-5.797242v-2.604558h9.634064V-19.6042H22.012707V0Zm20.388361-9.9141242q0-2.7725938-.728156-4.6209898-.70015-1.848396-2.016432-2.968636-1.288276-1.148246-3.164678-1.624348-1.876402-.476102-4.172894-.476102h-6.86147V0h6.357362q2.604558%200%204.564978-.50410801Q53.575462-1.036222%2054.91975-2.184468q1.344288-1.1762521%202.016432-3.0526541.672144-1.904408.672144-4.6770021zm-5.573194.084018q0%201.456312-.252054%202.4645281-.252054.98021-.84018%201.596342-.56012.588126-1.456312.868186-.896192.252054-2.156462.252054h-1.176252V-14.955204h1.344288q1.26027%200%202.128456.308066.868186.28006%201.4003.896192.532114.616132.756162%201.596342.252054.98021.252054%202.3244978z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%20-2.65123%2027.43044)%22%20aria-label%3D%22RED%22%2F%3E%3Cpath%20d%3D%22M6.3052259-2.8329q0-.6232379-.226632-1.1574419-.218538-.534204-.615144-.922716-.388512-.396606-.922716-.615144-.534204-.226632-1.157442-.226632-.6232379%200-1.1574419.226632-.534204.218538-.93081.615144-.38851202.388512-.61514401.922716-.218538.534204-.218538%201.1574419%200%20.623238.218538%201.157442.22663199.534204.61514401.93081001.396606.388512.93081.61514399.534204.218538%201.1574419.218538.623238%200%201.157442-.218538.534204-.22663199.922716-.61514399.396606-.39660601.615144-.93081001.226632-.534204.226632-1.157442zm-.598956%200q0%20.52611-.178068.963186-.178068.428982-.48564.736554-.307572.30757201-.736554.47754601-.428982.169974-.922716.169974-.5018279%200-.9308099-.169974-.420888-.169974-.72846-.47754601-.307572-.307572-.48564-.736554-.178068-.437076-.178068-.963186%200-.5261099.178068-.9550919.178068-.437076.48564-.744648.307572-.307572.72846-.477546.428982-.169974.9308099-.169974.493734%200%20.922716.169974t.736554.477546q.307572.307572.48564.744648.178068.428982.178068.9550919zm-.825588%201.513578-.631332-1.206006q.259008-.12141.412794-.339948.16188-.2266319.16188-.5908619%200-.56658-.339948-.801306t-.898434-.234726H2.161098v3.1728479h.8660579V-2.38773h.356136l.518016%201.068408zm-.93081-2.1125339q0%20.169974-.097128.259008-.089034.089034-.307572.089034h-.518016v-.68799h.534204q.210444%200%20.299478.097128.089034.089034.089034.24282z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%20442.7922%2047.06522)%22%20aria-label%3D%22%C2%AE%22%2F%3E%3Cpath%20d%3D%22M19.18411%200v-19.6042h-5.545188v7.14153H7.5336141v-7.14153H1.988426V0h5.5451881v-7.7296561h6.1053079V0Zm22.488833%200-7.113524-19.6042h-5.489176L21.956719%200h5.825248l1.064228-3.4447381h5.88126L35.791683%200Zm-8.26177-7.7576621h-3.248696l.364078-1.2882761q.252054-.924198.448096-1.6243478.196042-.70015.336072-1.26027.168036-.56012.28006-1.036222.112024-.476102.196042-.98021.08402.504108.196042.98021l.252054%201.008216q.168036.56012.364078%201.26027.196042.7001498.448096%201.6523538zm23.973112-7.1135239V-19.6042H40.972768v4.733014h5.489177V0h5.433164v-14.871186z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%2089.90877%2027.43044)%22%20aria-label%3D%22HAT%22%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E',\n },\n },\n },\n },\n {\n Component: SearchComponent,\n config: {\n priority: 100, // the greater the number, the more to the left it will be\n },\n },\n {\n Component: Spacer,\n config: {\n priority: 99, // the greater the number, the more to the left it will be\n props: {\n growFactor: 0,\n },\n },\n },\n // Notice: 1.5 ships with a Create link instead of a dropdown!!!\n {\n Component: CreateDropdown,\n config: {\n priority: 90,\n layout: {\n display: {\n sm: 'none',\n md: 'block',\n },\n mr: 1.5,\n } as any as CSSProperties, // I don't used MUI v5 specific `sx` types here to allow us changing the implementation later\n },\n },\n {\n Component: StarredDropdown,\n config: {\n priority: 85,\n },\n },\n {\n Component: ApplicationLauncherDropdown,\n config: {\n priority: 82,\n },\n },\n {\n Component: SupportButton,\n config: {\n priority: 80,\n },\n },\n {\n Component: NotificationButton,\n config: {\n priority: 70,\n },\n },\n {\n Component: Divider,\n config: {\n priority: 50,\n },\n },\n {\n Component: ProfileDropdown,\n config: {\n priority: 10, // the greater the number, the more to the left it will be\n },\n },\n ];\n\nexport const defaultCreateDropdownMountPoints: CreateDropdownMountPoint[] = [\n {\n Component: SoftwareTemplatesSection as ComponentType,\n config: {\n priority: 200,\n },\n },\n {\n Component: RegisterAComponentSection as ComponentType,\n config: {\n priority: 100,\n },\n },\n];\n\nexport const defaultProfileDropdownMountPoints: ProfileDropdownMountPoint[] = [\n {\n Component: MenuItemLink as ComponentType,\n config: {\n priority: 200,\n props: {\n title: 'Settings',\n icon: 'manageAccounts',\n link: '/settings',\n },\n },\n },\n {\n Component: LogoutButton,\n config: {\n priority: 100,\n },\n },\n];\n\nexport const defaultApplicationLauncherDropdownMountPoints: ApplicationLauncherDropdownMountPoint[] =\n [\n {\n Component: MenuItemLink as ComponentType,\n config: {\n section: 'Documentation',\n priority: 150,\n props: {\n title: 'Developer Hub',\n icon: 'developerHub',\n link: 'https://docs.redhat.com/en/documentation/red_hat_developer_hub',\n },\n },\n },\n {\n Component: MenuItemLink as ComponentType,\n config: {\n section: 'Developer Tools',\n priority: 130,\n props: {\n title: 'RHDH Local',\n icon: 'developerHub',\n link: 'https://github.com/redhat-developer/rhdh-local',\n },\n },\n },\n ];\n"],"names":[],"mappings":";;;;;;;;;;;;;;;AA0CO,MAAM,wCACX,GAAA;AAAA,EACE;AAAA,IACE,SAAW,EAAA,WAAA;AAAA,IACX,MAAQ,EAAA;AAAA,MACN,QAAU,EAAA,GAAA;AAAA,MACV,KAAO,EAAA;AAAA,QACL,EAAI,EAAA,UAAA;AAAA,QACJ,IAAM,EAAA;AAAA,UACJ,KACE,EAAA,yuTAAA;AAAA,UACF,IAAM,EAAA;AAAA;AACR;AACF;AACF,GACF;AAAA,EACA;AAAA,IACE,SAAW,EAAA,eAAA;AAAA,IACX,MAAQ,EAAA;AAAA,MACN,QAAU,EAAA;AAAA;AAAA;AACZ,GACF;AAAA,EACA;AAAA,IACE,SAAW,EAAA,MAAA;AAAA,IACX,MAAQ,EAAA;AAAA,MACN,QAAU,EAAA,EAAA;AAAA;AAAA,MACV,KAAO,EAAA;AAAA,QACL,UAAY,EAAA;AAAA;AACd;AACF,GACF;AAAA;AAAA,EAEA;AAAA,IACE,SAAW,EAAA,cAAA;AAAA,IACX,MAAQ,EAAA;AAAA,MACN,QAAU,EAAA,EAAA;AAAA,MACV,MAAQ,EAAA;AAAA,QACN,OAAS,EAAA;AAAA,UACP,EAAI,EAAA,MAAA;AAAA,UACJ,EAAI,EAAA;AAAA,SACN;AAAA,QACA,EAAI,EAAA;AAAA;AACN;AAAA;AACF,GACF;AAAA,EACA;AAAA,IACE,SAAW,EAAA,eAAA;AAAA,IACX,MAAQ,EAAA;AAAA,MACN,QAAU,EAAA;AAAA;AACZ,GACF;AAAA,EACA;AAAA,IACE,SAAW,EAAA,2BAAA;AAAA,IACX,MAAQ,EAAA;AAAA,MACN,QAAU,EAAA;AAAA;AACZ,GACF;AA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A,cAAA;AAAA,QACN,IAAM,EAAA;AAAA;AACR;AACF,GACF;AAAA,EACA;AAAA,IACE,SAAW,EAAA,YAAA;AAAA,IACX,MAAQ,EAAA;AAAA,MACN,OAAS,EAAA,iBAAA;AAAA,MACT,QAAU,EAAA,GAAA;AAAA,MACV,KAAO,EAAA;AAAA,QACL,KAAO,EAAA,YAAA;AAAA,QACP,IAAM,EAAA,cAAA;AAAA,QACN,IAAM,EAAA;AAAA;AACR;AACF;AAEJ;;;;"}
|
|
1
|
+
{"version":3,"file":"defaultMountPoints.esm.js","sources":["../../src/defaultMountPoints/defaultMountPoints.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 type { CSSProperties, ComponentType } from 'react';\nimport { LogoutButton } from '../components/LogoutButton/LogoutButton';\nimport { CreateDropdown } from '../components/HeaderDropdownComponent/CreateDropdown';\nimport { ProfileDropdown } from '../components/HeaderDropdownComponent/ProfileDropdown';\nimport { RegisterAComponentSection } from '../components/HeaderDropdownComponent/RegisterAComponentSection';\nimport { SoftwareTemplatesSection } from '../components/HeaderDropdownComponent/SoftwareTemplatesSection';\nimport { SearchComponent } from '../components/SearchComponent/SearchComponent';\nimport { SupportButton } from '../components/SupportButton/SupportButton';\nimport {\n ApplicationLauncherDropdownMountPoint,\n CreateDropdownMountPoint,\n GlobalHeaderComponentMountPoint,\n HelpDropdownMountPoint,\n ProfileDropdownMountPoint,\n} from '../types';\nimport { NotificationButton } from '../components/NotificationButton/NotificationButton';\nimport { Divider } from '../components/Divider/Divider';\nimport { MenuItemLink } from '../components/MenuItemLink/MenuItemLink';\nimport { Spacer } from '../components/Spacer/Spacer';\nimport { StarredDropdown } from '../components/HeaderDropdownComponent/StarredDropdown';\nimport { ApplicationLauncherDropdown } from '../components/HeaderDropdownComponent/ApplicationLauncherDropdown';\nimport { CompanyLogo } from '../components/CompanyLogo/CompanyLogo';\nimport { HelpDropdown } from '../components/HeaderDropdownComponent/HelpDropdown';\nimport { QuickstartButton } from '../components/QuickstartButton/QuickstartButton';\n\n/**\n * default Global Header Components mount points\n *\n * @public\n */\nexport const defaultGlobalHeaderComponentsMountPoints: GlobalHeaderComponentMountPoint[] =\n [\n {\n Component: CompanyLogo,\n config: {\n priority: 200,\n props: {\n to: '/catalog',\n logo: {\n light:\n 'data:image/svg+xml,%3Csvg%20width%3D%22451.199%22%20height%3D%2279.993%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cg%20style%3D%22fill%3A%23000%22%3E%3Cpath%20d%3D%22M6.3052259-2.8329q0-.6232379-.226632-1.1574419-.218538-.534204-.615144-.922716-.388512-.396606-.922716-.615144-.534204-.226632-1.157442-.226632-.6232379%200-1.1574419.226632-.534204.218538-.93081.615144-.38851202.388512-.61514401.922716-.218538.534204-.218538%201.1574419%200%20.623238.218538%201.157442.22663199.534204.61514401.93081001.396606.388512.93081.61514399.534204.218538%201.1574419.218538.623238%200%201.157442-.218538.534204-.22663199.922716-.61514399.396606-.39660601.615144-.93081001.226632-.534204.226632-1.157442zm-.598956%200q0%20.52611-.178068.963186-.178068.428982-.48564.736554-.307572.30757201-.736554.47754601-.428982.169974-.922716.169974-.5018279%200-.9308099-.169974-.420888-.169974-.72846-.47754601-.307572-.307572-.48564-.736554-.178068-.437076-.178068-.963186%200-.5261099.178068-.9550919.178068-.437076.48564-.744648.307572-.307572.72846-.477546.428982-.169974.9308099-.169974.493734%200%20.922716.169974t.736554.477546q.307572.307572.48564.744648.178068.428982.178068.9550919zm-.825588%201.513578-.631332-1.206006q.259008-.12141.412794-.339948.16188-.2266319.16188-.5908619%200-.56658-.339948-.801306t-.898434-.234726H2.161098v3.1728479h.8660579V-2.38773h.356136l.518016%201.068408zm-.93081-2.1125339q0%20.169974-.097128.259008-.089034.089034-.307572.089034h-.518016v-.68799h.534204q.210444%200%20.299478.097128.089034.089034.089034.24282z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%20169.9661%207.67311)%22%20aria-label%3D%22%C2%AE%22%2F%3E%3Cpath%20d%3D%22M25.629191-15.26571q0-3.87018-1.032048-6.665309-1.032048-2.79513-2.881134-4.601214-1.806084-1.849086-4.343201-2.709126-2.494116-.86004-5.461254-.86004H3.9561839V0h7.3533421q3.01014%200%205.633262-.81703798Q19.56591-1.677078%2021.500999-3.5261639q1.93509-1.849086%203.01014-4.7302199%201.118052-2.9241362%201.118052-7.0093262zm-3.354156.129006q0%203.22515-.731034%205.5472582-.731034%202.279106-2.107097%203.7411739-1.376064%201.462068-3.311154%202.1501-1.93509.64503-4.386204.64503H7.3103398V-27.048257h4.3432022q5.203242%200%207.912368%203.053142%202.709125%203.053142%202.709125%208.858411zM51.043415%200v-3.0531419h-15.48072V-14.534676h8.6004v-3.053142h-8.6004v-9.460439h14.83569v-3.053142H32.208539V0Zm28.553323-30.101399h-3.44016L69.405264-9.5894458l-.516024%201.548072q-.258012.86004-.559026%201.72008-.258012.8600399-.473021%201.6340759-.21501.731034-.344016%201.118052-.129006-.387018-.344016-1.118052-.21501-.731034-.473022-1.5480719-.258012-.86004-.559026-1.72008-.258012-.86004-.473022-1.548072L58.955779-30.101399h-3.526164L65.664091%200h3.698171zM104.62387%200v-3.0531419H89.143149V-14.534676h8.6004v-3.053142h-8.6004v-9.460439h14.835691v-3.053142H85.788993V0Zm24.64014%200v-3.0531419h-14.8787V-30.101399h-3.35415V0Zm29.06938-15.093702q0-3.397158-.90304-6.235289-.90304-2.838132-2.53712-4.902228t-3.95618-3.182148q-2.27911-1.161054-5.07424-1.161054-2.79513%200-5.11724%201.161054-2.3221%201.161054-3.95618%203.22515t-2.53712%204.94523q-.90304%202.838131-.90304%206.235289%200%203.397158.86004%206.2352902.90304%202.838132%202.53712%204.9022279%201.63407%202.0640959%203.91318%203.22514992%202.32211%201.11805197%205.11724%201.11805197t5.11723-1.16105397q2.32211-1.16105402%203.95619-3.22514992%201.67708-2.0640959%202.58012-4.9022279.90304-2.8811342.90304-6.2782922zm-3.35416.086q0%202.838132-.68803%205.1602403-.68803%202.2791059-1.89209%203.9131819-1.20405%201.5910739-2.88113%202.4941159-1.67708.86004-3.61217.86004-1.97809%200-3.65517-.86004-1.67707-.903042-2.92413-2.5371179-1.20406-1.677078-1.93509-3.9561839-.68803-2.3221083-.68803-5.1602403t.68803-5.117237q.68803-2.322108%201.89209-3.913182%201.20405-1.634076%202.83813-2.494116%201.67708-.903042%203.61217-.903042%201.97809%200%203.65516.903042%201.67708.86004%202.92414%202.537118%201.24706%201.634076%201.93509%203.956184.73103%202.279105.73103%205.117237zm30.83244-6.106283q0-2.279106-.73104-3.956184-.73103-1.72008-2.02109-2.838132-1.29006-1.118052-3.05314-1.634076-1.72008-.559026-3.78418-.559026H164.9557V0h3.35415v-11.82555h7.31034q2.23611%200%204.12819-.602028%201.89209-.602028%203.22515-1.763082%201.33307-1.204056%202.0641-2.924136.77404-1.763082.77404-3.999185zm-3.35416.129006q0%206.106283-6.79432%206.106283h-7.35334v-12.169565h7.78336q3.09615%200%204.73022%201.591074%201.63408%201.548072%201.63408%204.472208zM210.32281%200v-3.0531419h-15.48072V-14.534676h8.6004v-3.053142h-8.6004v-9.460439h14.83569v-3.053142h-18.18984V0Zm27.69329-21.587003q0-2.193102-.73103-3.784176-.73104-1.591074-1.9781-2.623122-1.24705-1.07505-2.96713-1.591074t-3.69818-.516024h-11.91155V0h3.35416v-12.814596h7.13833L233.6729%200h3.87018l-6.62231-13.072608q3.22515-.688032%205.16024-2.838132%201.93509-2.1501%201.93509-5.676263zm-3.35416.129006q0%202.838131-1.63407%204.257197-1.59108%201.376064-4.94523%201.376064h-7.99837v-11.223521h8.42839q3.01014%200%204.55821%201.419066%201.59107%201.376064%201.59107%204.171194zM277.49192%200v-30.101399h-3.35415v12.857597h-14.9647v-12.857597h-3.35415V0h3.35415v-14.19066h14.9647V0Zm29.37035-12.298572v-17.802827h-3.35415v17.888831q0%204.9022282-1.67708%207.2673381-1.67708%202.36511-5.59026%202.36511-7.69736%200-7.69736-9.7184521v-17.802827h-3.35416v17.888831q0%206.2782922%202.70913%209.5034421%202.75213%203.18214789%208.17038%203.18214789%205.46125%200%208.12738-3.22514989%202.66612-3.2681519%202.66612-9.5464441zm28.2523%203.3971582q0-1.8060842-.51603-3.0961442-.51602-1.333062-1.33306-2.193102-.81704-.903042-1.84909-1.419066-1.03204-.559026-2.06409-.817038%201.93509-.688032%203.13914-2.1501%201.20406-1.505069%201.20406-3.999185%200-1.93509-.60203-3.354156-.60203-1.419066-1.72008-2.322108-1.07505-.946044-2.58012-1.376064-1.46207-.473022-3.26815-.473022h-11.00851V0h10.7935q4.77322%200%207.26734-2.1931019%202.53712-2.236104%202.53712-6.7083119zm-4.77323-13.5456292q0%201.978092-1.20405%203.397157-1.20406%201.376064-3.99919%201.376064h-7.26734v-9.374435h7.52535q2.53712%200%203.74118%201.29006%201.20405%201.247058%201.20405%203.311154zm1.41907%2013.7176372q0%202.58012-1.41907%204.1281919-1.41906%201.548072-4.81622%201.548072h-7.65436V-14.663682h7.48235q2.96714%200%204.68722%201.548072%201.72008%201.548072%201.72008%204.3862042z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%20-5.23714%2079.36255)%22%20aria-label%3D%22DEVELOPER%20HUB%22%2F%3E%3Cpath%20d%3D%22m18.792026%200-3.92084-7.4776021q1.624348-.7281561%202.576552-2.1284561.952204-1.4002998.952204-3.6127738%200-1.736372-.56012-2.94063-.532114-1.232264-1.54033-1.988426t-2.436522-1.092234q-1.4003-.364078-3.108666-.364078H1.988426V0h5.3491461v-6.6094161h2.1844681L12.714724%200Zm-5.797242-13.078802q0%201.064228-.56012%201.624348t-1.904408.56012H7.3375721v-4.284918h3.2767019q1.288276%200%201.82039.588126.56012.588126.56012%201.512324zM37.219965%200v-4.5649781h-9.830106v-3.36072h5.797242v-4.5089659h-5.797242v-2.604558h9.634064V-19.6042H22.012707V0Zm20.388361-9.9141242q0-2.7725938-.728156-4.6209898-.70015-1.848396-2.016432-2.968636-1.288276-1.148246-3.164678-1.624348-1.876402-.476102-4.172894-.476102h-6.86147V0h6.357362q2.604558%200%204.564978-.50410801Q53.575462-1.036222%2054.91975-2.184468q1.344288-1.1762521%202.016432-3.0526541.672144-1.904408.672144-4.6770021zm-5.573194.084018q0%201.456312-.252054%202.4645281-.252054.98021-.84018%201.596342-.56012.588126-1.456312.868186-.896192.252054-2.156462.252054h-1.176252V-14.955204h1.344288q1.26027%200%202.128456.308066.868186.28006%201.4003.896192.532114.616132.756162%201.596342.252054.98021.252054%202.3244978z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%20-2.65123%2027.43044)%22%20aria-label%3D%22RED%22%2F%3E%3Cpath%20d%3D%22M6.3052259-2.8329q0-.6232379-.226632-1.1574419-.218538-.534204-.615144-.922716-.388512-.396606-.922716-.615144-.534204-.226632-1.157442-.226632-.6232379%200-1.1574419.226632-.534204.218538-.93081.615144-.38851202.388512-.61514401.922716-.218538.534204-.218538%201.1574419%200%20.623238.218538%201.157442.22663199.534204.61514401.93081001.396606.388512.93081.61514399.534204.218538%201.1574419.218538.623238%200%201.157442-.218538.534204-.22663199.922716-.61514399.396606-.39660601.615144-.93081001.226632-.534204.226632-1.157442zm-.598956%200q0%20.52611-.178068.963186-.178068.428982-.48564.736554-.307572.30757201-.736554.47754601-.428982.169974-.922716.169974-.5018279%200-.9308099-.169974-.420888-.169974-.72846-.47754601-.307572-.307572-.48564-.736554-.178068-.437076-.178068-.963186%200-.5261099.178068-.9550919.178068-.437076.48564-.744648.307572-.307572.72846-.477546.428982-.169974.9308099-.169974.493734%200%20.922716.169974t.736554.477546q.307572.307572.48564.744648.178068.428982.178068.9550919zm-.825588%201.513578-.631332-1.206006q.259008-.12141.412794-.339948.16188-.2266319.16188-.5908619%200-.56658-.339948-.801306t-.898434-.234726H2.161098v3.1728479h.8660579V-2.38773h.356136l.518016%201.068408zm-.93081-2.1125339q0%20.169974-.097128.259008-.089034.089034-.307572.089034h-.518016v-.68799h.534204q.210444%200%20.299478.097128.089034.089034.089034.24282z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%20442.7922%2047.06522)%22%20aria-label%3D%22%C2%AE%22%2F%3E%3Cpath%20d%3D%22M19.18411%200v-19.6042h-5.545188v7.14153H7.5336141v-7.14153H1.988426V0h5.5451881v-7.7296561h6.1053079V0Zm22.488833%200-7.113524-19.6042h-5.489176L21.956719%200h5.825248l1.064228-3.4447381h5.88126L35.791683%200Zm-8.26177-7.7576621h-3.248696l.364078-1.2882761q.252054-.924198.448096-1.6243478.196042-.70015.336072-1.26027.168036-.56012.28006-1.036222.112024-.476102.196042-.98021.08402.504108.196042.98021l.252054%201.008216q.168036.56012.364078%201.26027.196042.7001498.448096%201.6523538zm23.973112-7.1135239V-19.6042H40.972768v4.733014h5.489177V0h5.433164v-14.871186z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%2089.90877%2027.43044)%22%20aria-label%3D%22HAT%22%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E',\n dark: 'data:image/svg+xml,%3Csvg%20width%3D%22451.199%22%20height%3D%2279.993%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cg%20style%3D%22fill%3A%23fff%22%3E%3Cpath%20d%3D%22M6.3052259-2.8329q0-.6232379-.226632-1.1574419-.218538-.534204-.615144-.922716-.388512-.396606-.922716-.615144-.534204-.226632-1.157442-.226632-.6232379%200-1.1574419.226632-.534204.218538-.93081.615144-.38851202.388512-.61514401.922716-.218538.534204-.218538%201.1574419%200%20.623238.218538%201.157442.22663199.534204.61514401.93081001.396606.388512.93081.61514399.534204.218538%201.1574419.218538.623238%200%201.157442-.218538.534204-.22663199.922716-.61514399.396606-.39660601.615144-.93081001.226632-.534204.226632-1.157442zm-.598956%200q0%20.52611-.178068.963186-.178068.428982-.48564.736554-.307572.30757201-.736554.47754601-.428982.169974-.922716.169974-.5018279%200-.9308099-.169974-.420888-.169974-.72846-.47754601-.307572-.307572-.48564-.736554-.178068-.437076-.178068-.963186%200-.5261099.178068-.9550919.178068-.437076.48564-.744648.307572-.307572.72846-.477546.428982-.169974.9308099-.169974.493734%200%20.922716.169974t.736554.477546q.307572.307572.48564.744648.178068.428982.178068.9550919zm-.825588%201.513578-.631332-1.206006q.259008-.12141.412794-.339948.16188-.2266319.16188-.5908619%200-.56658-.339948-.801306t-.898434-.234726H2.161098v3.1728479h.8660579V-2.38773h.356136l.518016%201.068408zm-.93081-2.1125339q0%20.169974-.097128.259008-.089034.089034-.307572.089034h-.518016v-.68799h.534204q.210444%200%20.299478.097128.089034.089034.089034.24282z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%20169.9661%207.67311)%22%20aria-label%3D%22%C2%AE%22%2F%3E%3Cpath%20d%3D%22M25.629191-15.26571q0-3.87018-1.032048-6.665309-1.032048-2.79513-2.881134-4.601214-1.806084-1.849086-4.343201-2.709126-2.494116-.86004-5.461254-.86004H3.9561839V0h7.3533421q3.01014%200%205.633262-.81703798Q19.56591-1.677078%2021.500999-3.5261639q1.93509-1.849086%203.01014-4.7302199%201.118052-2.9241362%201.118052-7.0093262zm-3.354156.129006q0%203.22515-.731034%205.5472582-.731034%202.279106-2.107097%203.7411739-1.376064%201.462068-3.311154%202.1501-1.93509.64503-4.386204.64503H7.3103398V-27.048257h4.3432022q5.203242%200%207.912368%203.053142%202.709125%203.053142%202.709125%208.858411zM51.043415%200v-3.0531419h-15.48072V-14.534676h8.6004v-3.053142h-8.6004v-9.460439h14.83569v-3.053142H32.208539V0Zm28.553323-30.101399h-3.44016L69.405264-9.5894458l-.516024%201.548072q-.258012.86004-.559026%201.72008-.258012.8600399-.473021%201.6340759-.21501.731034-.344016%201.118052-.129006-.387018-.344016-1.118052-.21501-.731034-.473022-1.5480719-.258012-.86004-.559026-1.72008-.258012-.86004-.473022-1.548072L58.955779-30.101399h-3.526164L65.664091%200h3.698171zM104.62387%200v-3.0531419H89.143149V-14.534676h8.6004v-3.053142h-8.6004v-9.460439h14.835691v-3.053142H85.788993V0Zm24.64014%200v-3.0531419h-14.8787V-30.101399h-3.35415V0Zm29.06938-15.093702q0-3.397158-.90304-6.235289-.90304-2.838132-2.53712-4.902228t-3.95618-3.182148q-2.27911-1.161054-5.07424-1.161054-2.79513%200-5.11724%201.161054-2.3221%201.161054-3.95618%203.22515t-2.53712%204.94523q-.90304%202.838131-.90304%206.235289%200%203.397158.86004%206.2352902.90304%202.838132%202.53712%204.9022279%201.63407%202.0640959%203.91318%203.22514992%202.32211%201.11805197%205.11724%201.11805197t5.11723-1.16105397q2.32211-1.16105402%203.95619-3.22514992%201.67708-2.0640959%202.58012-4.9022279.90304-2.8811342.90304-6.2782922zm-3.35416.086q0%202.838132-.68803%205.1602403-.68803%202.2791059-1.89209%203.9131819-1.20405%201.5910739-2.88113%202.4941159-1.67708.86004-3.61217.86004-1.97809%200-3.65517-.86004-1.67707-.903042-2.92413-2.5371179-1.20406-1.677078-1.93509-3.9561839-.68803-2.3221083-.68803-5.1602403t.68803-5.117237q.68803-2.322108%201.89209-3.913182%201.20405-1.634076%202.83813-2.494116%201.67708-.903042%203.61217-.903042%201.97809%200%203.65516.903042%201.67708.86004%202.92414%202.537118%201.24706%201.634076%201.93509%203.956184.73103%202.279105.73103%205.117237zm30.83244-6.106283q0-2.279106-.73104-3.956184-.73103-1.72008-2.02109-2.838132-1.29006-1.118052-3.05314-1.634076-1.72008-.559026-3.78418-.559026H164.9557V0h3.35415v-11.82555h7.31034q2.23611%200%204.12819-.602028%201.89209-.602028%203.22515-1.763082%201.33307-1.204056%202.0641-2.924136.77404-1.763082.77404-3.999185zm-3.35416.129006q0%206.106283-6.79432%206.106283h-7.35334v-12.169565h7.78336q3.09615%200%204.73022%201.591074%201.63408%201.548072%201.63408%204.472208zM210.32281%200v-3.0531419h-15.48072V-14.534676h8.6004v-3.053142h-8.6004v-9.460439h14.83569v-3.053142h-18.18984V0Zm27.69329-21.587003q0-2.193102-.73103-3.784176-.73104-1.591074-1.9781-2.623122-1.24705-1.07505-2.96713-1.591074t-3.69818-.516024h-11.91155V0h3.35416v-12.814596h7.13833L233.6729%200h3.87018l-6.62231-13.072608q3.22515-.688032%205.16024-2.838132%201.93509-2.1501%201.93509-5.676263zm-3.35416.129006q0%202.838131-1.63407%204.257197-1.59108%201.376064-4.94523%201.376064h-7.99837v-11.223521h8.42839q3.01014%200%204.55821%201.419066%201.59107%201.376064%201.59107%204.171194zM277.49192%200v-30.101399h-3.35415v12.857597h-14.9647v-12.857597h-3.35415V0h3.35415v-14.19066h14.9647V0Zm29.37035-12.298572v-17.802827h-3.35415v17.888831q0%204.9022282-1.67708%207.2673381-1.67708%202.36511-5.59026%202.36511-7.69736%200-7.69736-9.7184521v-17.802827h-3.35416v17.888831q0%206.2782922%202.70913%209.5034421%202.75213%203.18214789%208.17038%203.18214789%205.46125%200%208.12738-3.22514989%202.66612-3.2681519%202.66612-9.5464441zm28.2523%203.3971582q0-1.8060842-.51603-3.0961442-.51602-1.333062-1.33306-2.193102-.81704-.903042-1.84909-1.419066-1.03204-.559026-2.06409-.817038%201.93509-.688032%203.13914-2.1501%201.20406-1.505069%201.20406-3.999185%200-1.93509-.60203-3.354156-.60203-1.419066-1.72008-2.322108-1.07505-.946044-2.58012-1.376064-1.46207-.473022-3.26815-.473022h-11.00851V0h10.7935q4.77322%200%207.26734-2.1931019%202.53712-2.236104%202.53712-6.7083119zm-4.77323-13.5456292q0%201.978092-1.20405%203.397157-1.20406%201.376064-3.99919%201.376064h-7.26734v-9.374435h7.52535q2.53712%200%203.74118%201.29006%201.20405%201.247058%201.20405%203.311154zm1.41907%2013.7176372q0%202.58012-1.41907%204.1281919-1.41906%201.548072-4.81622%201.548072h-7.65436V-14.663682h7.48235q2.96714%200%204.68722%201.548072%201.72008%201.548072%201.72008%204.3862042z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%20-5.23714%2079.36255)%22%20aria-label%3D%22DEVELOPER%20HUB%22%2F%3E%3Cpath%20d%3D%22m18.792026%200-3.92084-7.4776021q1.624348-.7281561%202.576552-2.1284561.952204-1.4002998.952204-3.6127738%200-1.736372-.56012-2.94063-.532114-1.232264-1.54033-1.988426t-2.436522-1.092234q-1.4003-.364078-3.108666-.364078H1.988426V0h5.3491461v-6.6094161h2.1844681L12.714724%200Zm-5.797242-13.078802q0%201.064228-.56012%201.624348t-1.904408.56012H7.3375721v-4.284918h3.2767019q1.288276%200%201.82039.588126.56012.588126.56012%201.512324zM37.219965%200v-4.5649781h-9.830106v-3.36072h5.797242v-4.5089659h-5.797242v-2.604558h9.634064V-19.6042H22.012707V0Zm20.388361-9.9141242q0-2.7725938-.728156-4.6209898-.70015-1.848396-2.016432-2.968636-1.288276-1.148246-3.164678-1.624348-1.876402-.476102-4.172894-.476102h-6.86147V0h6.357362q2.604558%200%204.564978-.50410801Q53.575462-1.036222%2054.91975-2.184468q1.344288-1.1762521%202.016432-3.0526541.672144-1.904408.672144-4.6770021zm-5.573194.084018q0%201.456312-.252054%202.4645281-.252054.98021-.84018%201.596342-.56012.588126-1.456312.868186-.896192.252054-2.156462.252054h-1.176252V-14.955204h1.344288q1.26027%200%202.128456.308066.868186.28006%201.4003.896192.532114.616132.756162%201.596342.252054.98021.252054%202.3244978z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%20-2.65123%2027.43044)%22%20aria-label%3D%22RED%22%2F%3E%3Cpath%20d%3D%22M6.3052259-2.8329q0-.6232379-.226632-1.1574419-.218538-.534204-.615144-.922716-.388512-.396606-.922716-.615144-.534204-.226632-1.157442-.226632-.6232379%200-1.1574419.226632-.534204.218538-.93081.615144-.38851202.388512-.61514401.922716-.218538.534204-.218538%201.1574419%200%20.623238.218538%201.157442.22663199.534204.61514401.93081001.396606.388512.93081.61514399.534204.218538%201.1574419.218538.623238%200%201.157442-.218538.534204-.22663199.922716-.61514399.396606-.39660601.615144-.93081001.226632-.534204.226632-1.157442zm-.598956%200q0%20.52611-.178068.963186-.178068.428982-.48564.736554-.307572.30757201-.736554.47754601-.428982.169974-.922716.169974-.5018279%200-.9308099-.169974-.420888-.169974-.72846-.47754601-.307572-.307572-.48564-.736554-.178068-.437076-.178068-.963186%200-.5261099.178068-.9550919.178068-.437076.48564-.744648.307572-.307572.72846-.477546.428982-.169974.9308099-.169974.493734%200%20.922716.169974t.736554.477546q.307572.307572.48564.744648.178068.428982.178068.9550919zm-.825588%201.513578-.631332-1.206006q.259008-.12141.412794-.339948.16188-.2266319.16188-.5908619%200-.56658-.339948-.801306t-.898434-.234726H2.161098v3.1728479h.8660579V-2.38773h.356136l.518016%201.068408zm-.93081-2.1125339q0%20.169974-.097128.259008-.089034.089034-.307572.089034h-.518016v-.68799h.534204q.210444%200%20.299478.097128.089034.089034.089034.24282z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%20442.7922%2047.06522)%22%20aria-label%3D%22%C2%AE%22%2F%3E%3Cpath%20d%3D%22M19.18411%200v-19.6042h-5.545188v7.14153H7.5336141v-7.14153H1.988426V0h5.5451881v-7.7296561h6.1053079V0Zm22.488833%200-7.113524-19.6042h-5.489176L21.956719%200h5.825248l1.064228-3.4447381h5.88126L35.791683%200Zm-8.26177-7.7576621h-3.248696l.364078-1.2882761q.252054-.924198.448096-1.6243478.196042-.70015.336072-1.26027.168036-.56012.28006-1.036222.112024-.476102.196042-.98021.08402.504108.196042.98021l.252054%201.008216q.168036.56012.364078%201.26027.196042.7001498.448096%201.6523538zm23.973112-7.1135239V-19.6042H40.972768v4.733014h5.489177V0h5.433164v-14.871186z%22%20transform%3D%22matrix(1.33333%200%200%201.33333%2089.90877%2027.43044)%22%20aria-label%3D%22HAT%22%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E',\n },\n },\n },\n },\n {\n Component: SearchComponent,\n config: {\n priority: 100, // the greater the number, the more to the left it will be\n },\n },\n {\n Component: Spacer,\n config: {\n priority: 99, // the greater the number, the more to the left it will be\n props: {\n growFactor: 0,\n },\n },\n },\n // Notice: 1.5 ships with a Create link instead of a dropdown!!!\n {\n Component: CreateDropdown,\n config: {\n priority: 90,\n layout: {\n display: {\n sm: 'none',\n md: 'block',\n },\n mr: 1.5,\n } as any as CSSProperties, // I don't used MUI v5 specific `sx` types here to allow us changing the implementation later\n },\n },\n {\n Component: StarredDropdown,\n config: {\n priority: 85,\n },\n },\n {\n Component: ApplicationLauncherDropdown,\n config: {\n priority: 82,\n },\n },\n {\n Component: HelpDropdown,\n config: {\n priority: 80,\n },\n },\n {\n Component: NotificationButton,\n config: {\n priority: 70,\n },\n },\n {\n Component: Divider,\n config: {\n priority: 50,\n },\n },\n {\n Component: ProfileDropdown,\n config: {\n priority: 10, // the greater the number, the more to the left it will be\n },\n },\n ];\n\nexport const defaultCreateDropdownMountPoints: CreateDropdownMountPoint[] = [\n {\n Component: SoftwareTemplatesSection as ComponentType,\n config: {\n priority: 200,\n },\n },\n {\n Component: RegisterAComponentSection as ComponentType,\n config: {\n priority: 100,\n },\n },\n];\n\nexport const defaultProfileDropdownMountPoints: ProfileDropdownMountPoint[] = [\n {\n Component: MenuItemLink as ComponentType,\n config: {\n priority: 200,\n props: {\n title: 'Settings',\n icon: 'manageAccounts',\n link: '/settings',\n },\n },\n },\n {\n Component: LogoutButton,\n config: {\n priority: 100,\n },\n },\n];\n\nexport const defaultHelpDropdownMountPoints: HelpDropdownMountPoint[] = [\n {\n Component: QuickstartButton,\n config: {\n priority: 100,\n },\n },\n {\n Component: SupportButton,\n config: {\n priority: 10,\n },\n },\n];\n\nexport const defaultApplicationLauncherDropdownMountPoints: ApplicationLauncherDropdownMountPoint[] =\n [\n {\n Component: MenuItemLink as ComponentType,\n config: {\n section: 'Documentation',\n priority: 150,\n props: {\n title: 'Developer Hub',\n icon: 'developerHub',\n link: 'https://docs.redhat.com/en/documentation/red_hat_developer_hub',\n },\n },\n },\n {\n Component: MenuItemLink as ComponentType,\n config: {\n section: 'Developer Tools',\n priority: 130,\n props: {\n title: 'RHDH Local',\n icon: 'developerHub',\n link: 'https://github.com/redhat-developer/rhdh-local',\n },\n },\n },\n ];\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AA6CO,MAAM,wCACX,GAAA;AAAA,EACE;AAAA,IACE,SAAW,EAAA,WAAA;AAAA,IACX,MAAQ,EAAA;AAAA,MACN,QAAU,EAAA,GAAA;AAAA,MACV,KAAO,EAAA;AAAA,QACL,EAAI,EAAA,UAAA;AAAA,QACJ,IAAM,EAAA;AAAA,UACJ,KACE,EAAA,yuTAAA;AAAA,UACF,IAAM,EAAA;AAAA;AACR;AACF;AACF,GACF;AAAA,EACA;AAAA,IACE,SAAW,EAAA,eAAA;AAAA,IACX,MAAQ,EAAA;AAAA,MACN,QAAU,EAAA;AAAA;AAAA;AACZ,GACF;AAAA,EACA;AAAA,IACE,SAAW,EAAA,MAAA;AAAA,IACX,MAAQ,EAAA;AAAA,MACN,QAAU,EAAA,EAAA;AAAA;AAAA,MACV,KAAO,EAAA;AAAA,QACL,UAAY,EAAA;AAAA;AACd;AACF,GACF;AAAA;AAAA,EAEA;AAAA,IACE,SAAW,EAAA,cAAA;AAAA,IACX,MAAQ,EAAA;AAAA,MACN,QAAU,EAAA,EAAA;AAAA,MACV,MAAQ,EAAA;AAAA,QACN,OAAS,EAAA;AAAA,UACP,EAAI,EAAA,MAAA;AAAA,UACJ,EAAI,EAAA;AAAA,SACN;AAAA,QACA,EAAI,EAAA;AAAA;AACN;AAAA;AACF,GACF;AAAA,EACA;AAAA,IACE,SAAW,EAAA,eAAA;AAAA,IACX,MAAQ,EAAA;AAAA,MACN,QAAU,EAAA;AAAA;AACZ,GACF;AAAA,EACA;AAAA,IACE,SAAW,EAAA,2BAAA;AAAA,IACX,MAAQ,EAAA;AAAA,MACN,QAAU,EAAA;AAAA;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N,QAAU,EAAA;AAAA;AACZ;AAEJ;AAEO,MAAM,6CACX,GAAA;AAAA,EACE;AAAA,IACE,SAAW,EAAA,YAAA;AAAA,IACX,MAAQ,EAAA;AAAA,MACN,OAAS,EAAA,eAAA;AAAA,MACT,QAAU,EAAA,GAAA;AAAA,MACV,KAAO,EAAA;AAAA,QACL,KAAO,EAAA,eAAA;AAAA,QACP,IAAM,EAAA,cAAA;AAAA,QACN,IAAM,EAAA;AAAA;AACR;AACF,GACF;AAAA,EACA;AAAA,IACE,SAAW,EAAA,YAAA;AAAA,IACX,MAAQ,EAAA;AAAA,MACN,OAAS,EAAA,iBAAA;AAAA,MACT,QAAU,EAAA,GAAA;AAAA,MACV,KAAO,EAAA;AAAA,QACL,KAAO,EAAA,YAAA;AAAA,QACP,IAAM,EAAA,cAAA;AAAA,QACN,IAAM,EAAA;AAAA;AACR;AACF;AAEJ;;;;"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { defaultHelpDropdownMountPoints } from '../defaultMountPoints/defaultMountPoints.esm.js';
|
|
2
|
+
import { useScalprum } from '@scalprum/react-core';
|
|
3
|
+
|
|
4
|
+
const useHelpDropdownMountPoints = () => {
|
|
5
|
+
const scalprum = useScalprum();
|
|
6
|
+
const helpDropdownMountPoints = scalprum?.api?.dynamicRootConfig?.mountPoints?.["global.header/help"];
|
|
7
|
+
if (Object.keys(scalprum?.api || {}).length === 0) {
|
|
8
|
+
return defaultHelpDropdownMountPoints;
|
|
9
|
+
}
|
|
10
|
+
return helpDropdownMountPoints ?? [];
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
export { useHelpDropdownMountPoints };
|
|
14
|
+
//# sourceMappingURL=useHelpDropdownMountPoints.esm.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useHelpDropdownMountPoints.esm.js","sources":["../../src/hooks/useHelpDropdownMountPoints.ts"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 { defaultHelpDropdownMountPoints } from '../defaultMountPoints/defaultMountPoints';\nimport { HelpDropdownMountPoint, ScalprumState } from '../types';\nimport { useScalprum } from '@scalprum/react-core';\n\nexport const useHelpDropdownMountPoints = ():\n | HelpDropdownMountPoint[]\n | undefined => {\n const scalprum = useScalprum<ScalprumState>();\n\n const helpDropdownMountPoints =\n scalprum?.api?.dynamicRootConfig?.mountPoints?.['global.header/help'];\n\n // default help dropdown components for dev env\n if (Object.keys(scalprum?.api || {}).length === 0) {\n return defaultHelpDropdownMountPoints;\n }\n\n return helpDropdownMountPoints ?? [];\n};\n"],"names":[],"mappings":";;;AAoBO,MAAM,6BAA6B,MAEzB;AACf,EAAA,MAAM,WAAW,WAA2B,EAAA;AAE5C,EAAA,MAAM,uBACJ,GAAA,QAAA,EAAU,GAAK,EAAA,iBAAA,EAAmB,cAAc,oBAAoB,CAAA;AAGtE,EAAI,IAAA,MAAA,CAAO,KAAK,QAAU,EAAA,GAAA,IAAO,EAAE,CAAA,CAAE,WAAW,CAAG,EAAA;AACjD,IAAO,OAAA,8BAAA;AAAA;AAGT,EAAA,OAAO,2BAA2B,EAAC;AACrC;;;;"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,106 +1,109 @@
|
|
|
1
|
-
import { CSSProperties, ComponentType } from 'react';
|
|
2
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
2
|
import * as _backstage_core_plugin_api from '@backstage/core-plugin-api';
|
|
3
|
+
import { ComponentType, CSSProperties } from 'react';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
|
-
*
|
|
6
|
+
* Global Header Config
|
|
7
|
+
*
|
|
7
8
|
* @public
|
|
8
9
|
*/
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
/** The logo that will be used in global headers with a dark-coloured background */
|
|
13
|
-
dark: string;
|
|
14
|
-
} | string | undefined;
|
|
10
|
+
interface GlobalHeaderComponentMountPointConfig {
|
|
11
|
+
priority?: number;
|
|
12
|
+
}
|
|
15
13
|
/**
|
|
14
|
+
* Global Header Component Mount Point
|
|
15
|
+
*
|
|
16
16
|
* @public
|
|
17
17
|
*/
|
|
18
|
-
interface
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
* You likely do not need to set this prop, but we recommend setting it
|
|
27
|
-
* to a value under 200px.
|
|
28
|
-
*/
|
|
29
|
-
logoWidth?: number;
|
|
30
|
-
/** This prop is not used by this component. */
|
|
31
|
-
layout?: CSSProperties;
|
|
18
|
+
interface GlobalHeaderComponentMountPoint {
|
|
19
|
+
Component: ComponentType<{
|
|
20
|
+
layout?: CSSProperties;
|
|
21
|
+
}>;
|
|
22
|
+
config?: GlobalHeaderComponentMountPointConfig & {
|
|
23
|
+
props?: Record<string, any>;
|
|
24
|
+
layout?: CSSProperties;
|
|
25
|
+
};
|
|
32
26
|
}
|
|
33
27
|
|
|
34
28
|
/**
|
|
29
|
+
* Global Header Component properties
|
|
35
30
|
* @public
|
|
36
31
|
*/
|
|
37
|
-
|
|
32
|
+
interface GlobalHeaderComponentProps {
|
|
33
|
+
globalHeaderMountPoints: GlobalHeaderComponentMountPoint[];
|
|
34
|
+
}
|
|
35
|
+
|
|
38
36
|
/**
|
|
37
|
+
* Header Icon Button properties
|
|
39
38
|
* @public
|
|
40
39
|
*/
|
|
41
|
-
interface
|
|
42
|
-
|
|
43
|
-
title
|
|
44
|
-
|
|
40
|
+
interface MenuItemLinkProps {
|
|
41
|
+
to: string;
|
|
42
|
+
title?: string;
|
|
43
|
+
subTitle?: string;
|
|
45
44
|
icon?: string;
|
|
46
|
-
|
|
47
|
-
backgroundColor?: string;
|
|
48
|
-
borderColor?: string;
|
|
49
|
-
layout?: CSSProperties;
|
|
50
|
-
dismiss?: NotificationBannerDismiss;
|
|
45
|
+
tooltip?: string;
|
|
51
46
|
}
|
|
52
47
|
|
|
53
48
|
/**
|
|
49
|
+
* Software Templates Section properties
|
|
50
|
+
*
|
|
54
51
|
* @public
|
|
55
52
|
*/
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
size?: 'small' | 'medium' | 'large';
|
|
61
|
-
badgeColor?: 'primary' | 'secondary' | 'default' | 'error' | 'info' | 'success' | 'warning';
|
|
62
|
-
to?: string;
|
|
63
|
-
layout?: CSSProperties;
|
|
64
|
-
}
|
|
53
|
+
type SoftwareTemplatesSectionProps = {
|
|
54
|
+
handleClose: () => void;
|
|
55
|
+
hideDivider?: boolean;
|
|
56
|
+
};
|
|
65
57
|
|
|
66
58
|
/**
|
|
59
|
+
* Register A Component Section properties
|
|
60
|
+
*
|
|
67
61
|
* @public
|
|
68
62
|
*/
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
63
|
+
type RegisterAComponentSectionProps = {
|
|
64
|
+
hideDivider: boolean;
|
|
65
|
+
handleClose: () => void;
|
|
66
|
+
};
|
|
67
|
+
|
|
68
|
+
/**
|
|
69
|
+
* @public
|
|
70
|
+
* Props for Create Dropdown
|
|
71
|
+
*/
|
|
72
|
+
interface CreateDropdownProps {
|
|
75
73
|
layout?: CSSProperties;
|
|
76
74
|
}
|
|
77
75
|
|
|
78
76
|
/**
|
|
79
77
|
* @public
|
|
78
|
+
* Props for Profile Dropdown
|
|
80
79
|
*/
|
|
81
|
-
interface
|
|
80
|
+
interface ProfileDropdownProps {
|
|
82
81
|
layout?: CSSProperties;
|
|
83
82
|
}
|
|
84
83
|
|
|
85
84
|
/**
|
|
86
85
|
* @public
|
|
87
86
|
*/
|
|
88
|
-
interface
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
87
|
+
interface QuickstartButtonProps {
|
|
88
|
+
icon?: string;
|
|
89
|
+
title?: string;
|
|
90
|
+
tooltip?: string;
|
|
91
|
+
style?: CSSProperties;
|
|
92
92
|
}
|
|
93
93
|
|
|
94
94
|
/**
|
|
95
95
|
* @public
|
|
96
96
|
*/
|
|
97
|
-
interface
|
|
97
|
+
interface HeaderButtonProps {
|
|
98
98
|
title: string;
|
|
99
|
-
icon: string;
|
|
100
99
|
tooltip?: string;
|
|
101
100
|
color?: 'inherit' | 'primary' | 'secondary' | 'default';
|
|
102
101
|
size?: 'small' | 'medium' | 'large';
|
|
102
|
+
variant?: 'text' | 'outlined' | 'contained';
|
|
103
103
|
ariaLabel?: string;
|
|
104
|
+
startIcon?: string;
|
|
105
|
+
endIcon?: string;
|
|
106
|
+
externalLinkIcon?: boolean;
|
|
104
107
|
to: string;
|
|
105
108
|
layout?: CSSProperties;
|
|
106
109
|
}
|
|
@@ -117,110 +120,121 @@ interface HeaderIconProps {
|
|
|
117
120
|
/**
|
|
118
121
|
* @public
|
|
119
122
|
*/
|
|
120
|
-
interface
|
|
123
|
+
interface HeaderIconButtonProps {
|
|
121
124
|
title: string;
|
|
125
|
+
icon: string;
|
|
122
126
|
tooltip?: string;
|
|
123
127
|
color?: 'inherit' | 'primary' | 'secondary' | 'default';
|
|
124
128
|
size?: 'small' | 'medium' | 'large';
|
|
125
|
-
variant?: 'text' | 'outlined' | 'contained';
|
|
126
129
|
ariaLabel?: string;
|
|
127
|
-
startIcon?: string;
|
|
128
|
-
endIcon?: string;
|
|
129
|
-
externalLinkIcon?: boolean;
|
|
130
130
|
to: string;
|
|
131
131
|
layout?: CSSProperties;
|
|
132
132
|
}
|
|
133
133
|
|
|
134
134
|
/**
|
|
135
|
-
*
|
|
135
|
+
* Menu item configuration
|
|
136
136
|
*
|
|
137
137
|
* @public
|
|
138
138
|
*/
|
|
139
|
-
interface
|
|
140
|
-
|
|
139
|
+
interface MenuItemConfig {
|
|
140
|
+
Component: ComponentType<MenuItemLinkProps | {}>;
|
|
141
|
+
label: string;
|
|
142
|
+
icon?: string;
|
|
143
|
+
subLabel?: string;
|
|
144
|
+
link?: string;
|
|
141
145
|
}
|
|
146
|
+
|
|
142
147
|
/**
|
|
143
|
-
* Global Header Component Mount Point
|
|
144
|
-
*
|
|
145
148
|
* @public
|
|
146
149
|
*/
|
|
147
|
-
interface
|
|
148
|
-
|
|
149
|
-
layout?: CSSProperties;
|
|
150
|
-
}>;
|
|
151
|
-
config?: GlobalHeaderComponentMountPointConfig & {
|
|
152
|
-
props?: Record<string, any>;
|
|
153
|
-
layout?: CSSProperties;
|
|
154
|
-
};
|
|
150
|
+
interface DividerProps {
|
|
151
|
+
layout?: CSSProperties;
|
|
155
152
|
}
|
|
156
153
|
|
|
157
154
|
/**
|
|
158
|
-
* Global Header Component properties
|
|
159
155
|
* @public
|
|
160
156
|
*/
|
|
161
|
-
interface
|
|
162
|
-
|
|
157
|
+
interface SpacerProps {
|
|
158
|
+
growFactor?: number;
|
|
159
|
+
minWidth?: number | string;
|
|
160
|
+
layout?: CSSProperties;
|
|
163
161
|
}
|
|
164
162
|
|
|
165
163
|
/**
|
|
166
|
-
* Header Icon Button properties
|
|
167
164
|
* @public
|
|
168
165
|
*/
|
|
169
|
-
interface
|
|
170
|
-
to: string;
|
|
171
|
-
title?: string;
|
|
172
|
-
subTitle?: string;
|
|
166
|
+
interface SupportButtonProps {
|
|
173
167
|
icon?: string;
|
|
168
|
+
title?: string;
|
|
169
|
+
to?: string;
|
|
174
170
|
tooltip?: string;
|
|
171
|
+
style?: CSSProperties;
|
|
175
172
|
}
|
|
176
173
|
|
|
177
174
|
/**
|
|
178
|
-
* Software Templates Section properties
|
|
179
|
-
*
|
|
180
175
|
* @public
|
|
181
176
|
*/
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
177
|
+
interface NotificationButtonProps {
|
|
178
|
+
title?: string;
|
|
179
|
+
tooltip?: string;
|
|
180
|
+
color?: 'inherit' | 'default' | 'primary' | 'secondary' | 'error' | 'info' | 'success' | 'warning';
|
|
181
|
+
size?: 'small' | 'medium' | 'large';
|
|
182
|
+
badgeColor?: 'primary' | 'secondary' | 'default' | 'error' | 'info' | 'success' | 'warning';
|
|
183
|
+
to?: string;
|
|
184
|
+
layout?: CSSProperties;
|
|
185
|
+
}
|
|
186
186
|
|
|
187
187
|
/**
|
|
188
|
-
*
|
|
189
|
-
*
|
|
188
|
+
* An interface representing the URLs for light and dark variants of a logo.
|
|
190
189
|
* @public
|
|
191
190
|
*/
|
|
192
|
-
type
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
191
|
+
type LogoURLs = {
|
|
192
|
+
/** The logo that will be used in global headers with a light-coloured background */
|
|
193
|
+
light: string;
|
|
194
|
+
/** The logo that will be used in global headers with a dark-coloured background */
|
|
195
|
+
dark: string;
|
|
196
|
+
} | string | undefined;
|
|
197
197
|
/**
|
|
198
198
|
* @public
|
|
199
|
-
* Props for Create Dropdown
|
|
200
199
|
*/
|
|
201
|
-
interface
|
|
200
|
+
interface CompanyLogoProps {
|
|
201
|
+
/** An object containing the logo URLs */
|
|
202
|
+
logo?: LogoURLs;
|
|
203
|
+
/** The route to link the logo to */
|
|
204
|
+
to?: string;
|
|
205
|
+
/**
|
|
206
|
+
* The width of the logo in pixels (defaults to 150px). This prop fixes an
|
|
207
|
+
* issue where encoded SVGs without an explicit width would not render.
|
|
208
|
+
* You likely do not need to set this prop, but we recommend setting it
|
|
209
|
+
* to a value under 200px.
|
|
210
|
+
*/
|
|
211
|
+
width?: string | number;
|
|
212
|
+
/**
|
|
213
|
+
* The maximum height of the logo in pixels (defaults to 40px).
|
|
214
|
+
* Note that changing this value may result in changes in the height of the global header.
|
|
215
|
+
**/
|
|
216
|
+
height?: string | number;
|
|
217
|
+
/** This prop is not used by this component. */
|
|
202
218
|
layout?: CSSProperties;
|
|
203
219
|
}
|
|
204
220
|
|
|
205
221
|
/**
|
|
206
222
|
* @public
|
|
207
|
-
* Props for Profile Dropdown
|
|
208
223
|
*/
|
|
209
|
-
|
|
210
|
-
layout?: CSSProperties;
|
|
211
|
-
}
|
|
212
|
-
|
|
224
|
+
type NotificationBannerDismiss = 'none' | 'session' | 'localstorage';
|
|
213
225
|
/**
|
|
214
|
-
* Menu item configuration
|
|
215
|
-
*
|
|
216
226
|
* @public
|
|
217
227
|
*/
|
|
218
|
-
interface
|
|
219
|
-
|
|
220
|
-
|
|
228
|
+
interface NotificationBannerProps {
|
|
229
|
+
id?: string;
|
|
230
|
+
title: string;
|
|
231
|
+
markdown?: boolean;
|
|
221
232
|
icon?: string;
|
|
222
|
-
|
|
223
|
-
|
|
233
|
+
textColor?: string;
|
|
234
|
+
backgroundColor?: string;
|
|
235
|
+
borderColor?: string;
|
|
236
|
+
layout?: CSSProperties;
|
|
237
|
+
dismiss?: NotificationBannerDismiss;
|
|
224
238
|
}
|
|
225
239
|
|
|
226
240
|
/**
|
|
@@ -317,7 +331,11 @@ declare const Divider: ({ layout }: DividerProps) => react_jsx_runtime.JSX.Eleme
|
|
|
317
331
|
/**
|
|
318
332
|
* @public
|
|
319
333
|
*/
|
|
320
|
-
declare const SupportButton:
|
|
334
|
+
declare const SupportButton: ComponentType<SupportButtonProps>;
|
|
335
|
+
/**
|
|
336
|
+
* @public
|
|
337
|
+
*/
|
|
338
|
+
declare const QuickstartButton: ComponentType<QuickstartButtonProps>;
|
|
321
339
|
/**
|
|
322
340
|
* @public
|
|
323
341
|
*/
|
|
@@ -345,6 +363,6 @@ declare const ApplicationLauncherDropdown: () => react_jsx_runtime.JSX.Element;
|
|
|
345
363
|
*
|
|
346
364
|
* @public
|
|
347
365
|
*/
|
|
348
|
-
declare const CompanyLogo: ({ logo,
|
|
366
|
+
declare const CompanyLogo: ({ logo, width, height, to, }: CompanyLogoProps) => react_jsx_runtime.JSX.Element;
|
|
349
367
|
|
|
350
|
-
export { ApplicationLauncherDropdown, CompanyLogo, type CompanyLogoProps, CreateDropdown, type CreateDropdownProps, Divider, type DividerProps, GlobalHeader, GlobalHeaderComponent, type GlobalHeaderComponentMountPoint, type GlobalHeaderComponentMountPointConfig, type GlobalHeaderComponentProps, HeaderButton, type HeaderButtonProps, HeaderIcon, HeaderIconButton, type HeaderIconButtonProps, type HeaderIconProps, type LogoURLs, LogoutButton, type MenuItemConfig, MenuItemLink, type MenuItemLinkProps, NotificationBanner, type NotificationBannerDismiss, type NotificationBannerProps, NotificationButton, type NotificationButtonProps, ProfileDropdown, type ProfileDropdownProps, RegisterAComponentSection, type RegisterAComponentSectionProps, SearchComponent, SoftwareTemplatesSection, type SoftwareTemplatesSectionProps, Spacer, type SpacerProps, StarredDropdown, SupportButton, type SupportButtonProps, defaultGlobalHeaderComponentsMountPoints, globalHeaderPlugin };
|
|
368
|
+
export { ApplicationLauncherDropdown, CompanyLogo, type CompanyLogoProps, CreateDropdown, type CreateDropdownProps, Divider, type DividerProps, GlobalHeader, GlobalHeaderComponent, type GlobalHeaderComponentMountPoint, type GlobalHeaderComponentMountPointConfig, type GlobalHeaderComponentProps, HeaderButton, type HeaderButtonProps, HeaderIcon, HeaderIconButton, type HeaderIconButtonProps, type HeaderIconProps, type LogoURLs, LogoutButton, type MenuItemConfig, MenuItemLink, type MenuItemLinkProps, NotificationBanner, type NotificationBannerDismiss, type NotificationBannerProps, NotificationButton, type NotificationButtonProps, ProfileDropdown, type ProfileDropdownProps, QuickstartButton, type QuickstartButtonProps, RegisterAComponentSection, type RegisterAComponentSectionProps, SearchComponent, SoftwareTemplatesSection, type SoftwareTemplatesSectionProps, Spacer, type SpacerProps, StarredDropdown, SupportButton, type SupportButtonProps, defaultGlobalHeaderComponentsMountPoints, globalHeaderPlugin };
|
package/dist/index.esm.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { unstable_ClassNameGenerator } from '@mui/material/className';
|
|
2
|
-
export { ApplicationLauncherDropdown, CompanyLogo, CreateDropdown, Divider, GlobalHeader, GlobalHeaderComponent, HeaderButton, HeaderIcon, HeaderIconButton, LogoutButton, MenuItemLink, NotificationBanner, NotificationButton, ProfileDropdown, RegisterAComponentSection, SearchComponent, SoftwareTemplatesSection, Spacer, StarredDropdown, SupportButton, globalHeaderPlugin } from './plugin.esm.js';
|
|
2
|
+
export { ApplicationLauncherDropdown, CompanyLogo, CreateDropdown, Divider, GlobalHeader, GlobalHeaderComponent, HeaderButton, HeaderIcon, HeaderIconButton, LogoutButton, MenuItemLink, NotificationBanner, NotificationButton, ProfileDropdown, QuickstartButton, RegisterAComponentSection, SearchComponent, SoftwareTemplatesSection, Spacer, StarredDropdown, SupportButton, globalHeaderPlugin } from './plugin.esm.js';
|
|
3
3
|
export { defaultGlobalHeaderComponentsMountPoints } from './defaultMountPoints/defaultMountPoints.esm.js';
|
|
4
4
|
|
|
5
5
|
unstable_ClassNameGenerator.configure((componentName) => {
|
package/dist/plugin.esm.js
CHANGED
|
@@ -29,7 +29,6 @@ import '@mui/material/InputAdornment';
|
|
|
29
29
|
import '@mui/icons-material/Search';
|
|
30
30
|
import '@mui/material/ListItem';
|
|
31
31
|
import '@mui/icons-material/ArrowForward';
|
|
32
|
-
import '@mui/icons-material/HelpOutline';
|
|
33
32
|
import '@mui/material/Badge';
|
|
34
33
|
import '@mui/icons-material/NotificationsOutlined';
|
|
35
34
|
import '@backstage/plugin-notifications';
|
|
@@ -42,6 +41,8 @@ import '@mui/material/ListItemIcon';
|
|
|
42
41
|
import '@mui/material/ListItemText';
|
|
43
42
|
import '@mui/icons-material/Apps';
|
|
44
43
|
import '@mui/icons-material/AppRegistration';
|
|
44
|
+
import '@mui/icons-material/HelpOutline';
|
|
45
|
+
import 'react-use';
|
|
45
46
|
|
|
46
47
|
const globalHeaderPlugin = createPlugin({
|
|
47
48
|
id: "global-header"
|
|
@@ -184,6 +185,16 @@ const SupportButton = globalHeaderPlugin.provide(
|
|
|
184
185
|
}
|
|
185
186
|
})
|
|
186
187
|
);
|
|
188
|
+
const QuickstartButton = globalHeaderPlugin.provide(
|
|
189
|
+
createComponentExtension({
|
|
190
|
+
name: "QuickstartButton",
|
|
191
|
+
component: {
|
|
192
|
+
lazy: () => import('./components/QuickstartButton/QuickstartButton.esm.js').then(
|
|
193
|
+
(m) => m.QuickstartButton
|
|
194
|
+
)
|
|
195
|
+
}
|
|
196
|
+
})
|
|
197
|
+
);
|
|
187
198
|
const NotificationButton = globalHeaderPlugin.provide(
|
|
188
199
|
createComponentExtension({
|
|
189
200
|
name: "NotificationButton",
|
|
@@ -231,5 +242,5 @@ const CompanyLogo = globalHeaderPlugin.provide(
|
|
|
231
242
|
})
|
|
232
243
|
);
|
|
233
244
|
|
|
234
|
-
export { ApplicationLauncherDropdown, CompanyLogo, CreateDropdown, Divider, GlobalHeader, GlobalHeaderComponent, HeaderButton, HeaderIcon, HeaderIconButton, LogoutButton, MenuItemLink, NotificationBanner, NotificationButton, ProfileDropdown, RegisterAComponentSection, SearchComponent, SoftwareTemplatesSection, Spacer, StarredDropdown, SupportButton, globalHeaderPlugin };
|
|
245
|
+
export { ApplicationLauncherDropdown, CompanyLogo, CreateDropdown, Divider, GlobalHeader, GlobalHeaderComponent, HeaderButton, HeaderIcon, HeaderIconButton, LogoutButton, MenuItemLink, NotificationBanner, NotificationButton, ProfileDropdown, QuickstartButton, RegisterAComponentSection, SearchComponent, SoftwareTemplatesSection, Spacer, StarredDropdown, SupportButton, globalHeaderPlugin };
|
|
235
246
|
//# sourceMappingURL=plugin.esm.js.map
|
package/dist/plugin.esm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugin.esm.js","sources":["../src/plugin.ts"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 type { ComponentType } from 'react';\n\nimport {\n createPlugin,\n createComponentExtension,\n} from '@backstage/core-plugin-api';\n\nimport { GlobalHeaderComponentProps } from './components/GlobalHeaderComponent';\nimport { MenuItemLinkProps } from './components/MenuItemLink/MenuItemLink';\nimport { SoftwareTemplatesSectionProps } from './components/HeaderDropdownComponent/SoftwareTemplatesSection';\nimport { RegisterAComponentSectionProps } from './components/HeaderDropdownComponent/RegisterAComponentSection';\nimport { CreateDropdownProps } from './components/HeaderDropdownComponent/CreateDropdown';\nimport { ProfileDropdownProps } from './components/HeaderDropdownComponent/ProfileDropdown';\n\nexport type { GlobalHeaderComponentProps } from './components/GlobalHeaderComponent';\n\nexport type { HeaderButtonProps } from './components/HeaderButton/HeaderButton';\nexport type { HeaderIconProps } from './components/HeaderIcon/HeaderIcon';\nexport type { HeaderIconButtonProps } from './components/HeaderIconButton/HeaderIconButton';\nexport type { CreateDropdownProps } from './components/HeaderDropdownComponent/CreateDropdown';\nexport type { ProfileDropdownProps } from './components/HeaderDropdownComponent/ProfileDropdown';\n\nexport type { MenuItemLinkProps } from './components/MenuItemLink/MenuItemLink';\nexport type { MenuItemConfig } from './components/HeaderDropdownComponent/MenuSection';\nexport type { SoftwareTemplatesSectionProps } from './components/HeaderDropdownComponent/SoftwareTemplatesSection';\nexport type { RegisterAComponentSectionProps } from './components/HeaderDropdownComponent/RegisterAComponentSection';\nexport type { DividerProps } from './components/Divider/Divider';\nexport type { SpacerProps } from './components/Spacer/Spacer';\nexport type { SupportButtonProps } from './components/SupportButton/SupportButton';\nexport type { NotificationButtonProps } from './components/NotificationButton/NotificationButton';\nexport type {\n LogoURLs,\n CompanyLogoProps,\n} from './components/CompanyLogo/CompanyLogo';\n\nexport type {\n NotificationBannerProps,\n NotificationBannerDismiss,\n} from './components/NotificationBanner';\n\nexport type {\n GlobalHeaderComponentMountPoint,\n GlobalHeaderComponentMountPointConfig,\n} from './types';\n\nexport { defaultGlobalHeaderComponentsMountPoints } from './defaultMountPoints/defaultMountPoints';\n\n/**\n * Global Header Plugin\n *\n * @public\n */\nexport const globalHeaderPlugin = createPlugin({\n id: 'global-header',\n});\n\n/**\n * Global Header\n *\n * @public\n */\nexport const GlobalHeader = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'GlobalHeader',\n component: {\n lazy: () => import('./components/GlobalHeader').then(m => m.GlobalHeader),\n },\n }),\n);\n\n/**\n * Global Header Component\n *\n * @public\n */\nexport const GlobalHeaderComponent: ComponentType<GlobalHeaderComponentProps> =\n globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'GlobalHeaderComponent',\n component: {\n lazy: () =>\n import('./components/GlobalHeaderComponent').then(\n m => m.GlobalHeaderComponent,\n ),\n },\n }),\n );\n\n/**\n * @public\n */\nexport const HeaderButton = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'HeaderButton',\n component: {\n lazy: () =>\n import('./components/HeaderButton/HeaderButton').then(\n m => m.HeaderButton,\n ),\n },\n }),\n);\n\n/**\n * @public\n */\nexport const HeaderIcon = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'HeaderIcon',\n component: {\n lazy: () =>\n import('./components/HeaderIcon/HeaderIcon').then(m => m.HeaderIcon),\n },\n }),\n);\n\n/**\n * @public\n */\nexport const HeaderIconButton = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'HeaderIconButton',\n component: {\n lazy: () =>\n import('./components/HeaderIconButton/HeaderIconButton').then(\n m => m.HeaderIconButton,\n ),\n },\n }),\n);\n\n/**\n * Search Component\n *\n * @public\n */\nexport const SearchComponent: ComponentType = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'SearchComponent',\n component: {\n lazy: () =>\n import('./components/SearchComponent/SearchComponent').then(\n m => m.SearchComponent,\n ),\n },\n }),\n);\n\n/**\n * Create Dropdown\n *\n * @public\n */\nexport const CreateDropdown: ComponentType<CreateDropdownProps> =\n globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'CreateDropdown',\n component: {\n lazy: () =>\n import('./components/HeaderDropdownComponent/CreateDropdown').then(\n m => m.CreateDropdown,\n ),\n },\n }),\n );\n\n/**\n * Profile Dropdown\n *\n * @public\n */\nexport const ProfileDropdown: ComponentType<ProfileDropdownProps> =\n globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'ProfileDropdown',\n component: {\n lazy: () =>\n import('./components/HeaderDropdownComponent/ProfileDropdown').then(\n m => m.ProfileDropdown,\n ),\n },\n }),\n );\n\n/**\n * Software Templates List\n *\n * @public\n */\nexport const SoftwareTemplatesSection: ComponentType<SoftwareTemplatesSectionProps> =\n globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'SoftwareTemplatesSection',\n component: {\n lazy: () =>\n import(\n './components/HeaderDropdownComponent/SoftwareTemplatesSection'\n ).then(m => m.SoftwareTemplatesSection),\n },\n }),\n );\n\n/**\n * Register A Component Link\n *\n * @public\n */\nexport const RegisterAComponentSection: ComponentType<RegisterAComponentSectionProps> =\n globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'RegisterAComponentSection',\n component: {\n lazy: () =>\n import(\n './components/HeaderDropdownComponent/RegisterAComponentSection'\n ).then(m => m.RegisterAComponentSection),\n },\n }),\n );\n\n/**\n * Header Link\n *\n * @public\n */\nexport const MenuItemLink: ComponentType<MenuItemLinkProps> =\n globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'MenuItemLink',\n component: {\n lazy: () =>\n import('./components/MenuItemLink/MenuItemLink').then(\n m => m.MenuItemLink,\n ),\n },\n }),\n );\n\n/**\n * Header Logout Button\n *\n * @public\n */\nexport const LogoutButton: ComponentType = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'LogoutButton',\n component: {\n lazy: () =>\n import('./components/LogoutButton/LogoutButton').then(\n m => m.LogoutButton,\n ),\n },\n }),\n);\n\n/**\n * Spacer component that allow users to add a flexible spacing between components.\n *\n * Supports two props: `growFactor` with default 1 and `minWidth` width default 8 pixels.\n *\n * @public\n */\nexport const Spacer = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'Spacer',\n component: {\n lazy: () => import('./components/Spacer/Spacer').then(m => m.Spacer),\n },\n }),\n);\n\n/**\n * @public\n */\nexport const Divider = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'Divider',\n component: {\n lazy: () => import('./components/Divider/Divider').then(m => m.Divider),\n },\n }),\n);\n\n/**\n * @public\n */\nexport const SupportButton = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'SupportButton',\n component: {\n lazy: () =>\n import('./components/SupportButton/SupportButton').then(\n m => m.SupportButton,\n ),\n },\n }),\n);\n\n/**\n * @public\n */\nexport const NotificationButton = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'NotificationButton',\n component: {\n lazy: () =>\n import('./components/NotificationButton/NotificationButton').then(\n m => m.NotificationButton,\n ),\n },\n }),\n);\n\n/**\n * NotificationBanner\n *\n * @public\n */\nexport const NotificationBanner = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'NotificationBanner',\n component: {\n lazy: () =>\n import('./components/NotificationBanner').then(\n m => m.NotificationBanner,\n ),\n },\n }),\n);\n\n/**\n * Starred Dropdown\n *\n * @public\n */\nexport const StarredDropdown = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'StarredDropdown',\n component: {\n lazy: () =>\n import('./components/HeaderDropdownComponent/StarredDropdown').then(\n m => m.StarredDropdown,\n ),\n },\n }),\n);\n\n/**\n * Application Launcher Dropdown\n *\n * @public\n */\nexport const ApplicationLauncherDropdown = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'ApplicationLauncherDropdown',\n component: {\n lazy: () =>\n import(\n './components/HeaderDropdownComponent/ApplicationLauncherDropdown'\n ).then(m => m.ApplicationLauncherDropdown),\n },\n }),\n);\n\n/**\n * Company Logo\n *\n * @public\n */\nexport const CompanyLogo = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'CompanyLogo',\n component: {\n lazy: () =>\n import('./components/CompanyLogo/CompanyLogo').then(m => m.CompanyLogo),\n },\n }),\n);\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAoEO,MAAM,qBAAqB,YAAa,CAAA;AAAA,EAC7C,EAAI,EAAA;AACN,CAAC;AAOM,MAAM,eAAe,kBAAmB,CAAA,OAAA;AAAA,EAC7C,wBAAyB,CAAA;AAAA,IACvB,IAAM,EAAA,cAAA;AAAA,IACN,SAAW,EAAA;AAAA,MACT,IAAA,EAAM,MAAM,OAAO,kCAA2B,EAAE,IAAK,CAAA,CAAA,CAAA,KAAK,EAAE,YAAY;AAAA;AAC1E,GACD;AACH;AAOO,MAAM,wBACX,kBAAmB,CAAA,OAAA;AAAA,EACjB,wBAAyB,CAAA;AAAA,IACvB,IAAM,EAAA,uBAAA;AAAA,IACN,SAAW,EAAA;AAAA,MACT,IAAM,EAAA,MACJ,OAAO,2CAAoC,CAAE,CAAA,IAAA;AAAA,QAC3C,OAAK,CAAE,CAAA;AAAA;AACT;AACJ,GACD;AACH;AAKK,MAAM,eAAe,kBAAmB,CAAA,OAAA;AAAA,EAC7C,wBAAyB,CAAA;AAAA,IACvB,IAAM,EAAA,cAAA;AAAA,IACN,SAAW,EAAA;AAAA,MACT,IAAM,EAAA,MACJ,OAAO,+CAAwC,CAAE,CAAA,IAAA;AAAA,QAC/C,OAAK,CAAE,CAAA;AAAA;AACT;AACJ,GACD;AACH;AAKO,MAAM,aAAa,kBAAmB,CAAA,OAAA;AAAA,EAC3C,wBAAyB,CAAA;AAAA,IACvB,IAAM,EAAA,YAAA;AAAA,IACN,SAAW,EAAA;AAAA,MACT,IAAA,EAAM,MACJ,OAAO,2CAAoC,EAAE,IAAK,CAAA,CAAA,CAAA,KAAK,EAAE,UAAU;AAAA;AACvE,GACD;AACH;AAKO,MAAM,mBAA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C,EAAE,IAAK,CAAA,CAAA,CAAA,KAAK,EAAE,WAAW;AAAA;AAC1E,GACD;AACH;;;;"}
|
|
1
|
+
{"version":3,"file":"plugin.esm.js","sources":["../src/plugin.ts"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 type { ComponentType } from 'react';\n\nimport {\n createPlugin,\n createComponentExtension,\n} from '@backstage/core-plugin-api';\n\nimport { GlobalHeaderComponentProps } from './components/GlobalHeaderComponent';\nimport { MenuItemLinkProps } from './components/MenuItemLink/MenuItemLink';\nimport { SoftwareTemplatesSectionProps } from './components/HeaderDropdownComponent/SoftwareTemplatesSection';\nimport { RegisterAComponentSectionProps } from './components/HeaderDropdownComponent/RegisterAComponentSection';\nimport { CreateDropdownProps } from './components/HeaderDropdownComponent/CreateDropdown';\nimport { ProfileDropdownProps } from './components/HeaderDropdownComponent/ProfileDropdown';\nimport { QuickstartButtonProps } from './components/QuickstartButton/QuickstartButton';\nimport { SupportButtonProps } from './plugin';\n\nexport type { GlobalHeaderComponentProps } from './components/GlobalHeaderComponent';\n\nexport type { HeaderButtonProps } from './components/HeaderButton/HeaderButton';\nexport type { HeaderIconProps } from './components/HeaderIcon/HeaderIcon';\nexport type { HeaderIconButtonProps } from './components/HeaderIconButton/HeaderIconButton';\nexport type { CreateDropdownProps } from './components/HeaderDropdownComponent/CreateDropdown';\nexport type { ProfileDropdownProps } from './components/HeaderDropdownComponent/ProfileDropdown';\n\nexport type { MenuItemLinkProps } from './components/MenuItemLink/MenuItemLink';\nexport type { MenuItemConfig } from './components/HeaderDropdownComponent/MenuSection';\nexport type { SoftwareTemplatesSectionProps } from './components/HeaderDropdownComponent/SoftwareTemplatesSection';\nexport type { RegisterAComponentSectionProps } from './components/HeaderDropdownComponent/RegisterAComponentSection';\nexport type { DividerProps } from './components/Divider/Divider';\nexport type { SpacerProps } from './components/Spacer/Spacer';\nexport type { SupportButtonProps } from './components/SupportButton/SupportButton';\nexport type { QuickstartButtonProps } from './components/QuickstartButton/QuickstartButton';\nexport type { NotificationButtonProps } from './components/NotificationButton/NotificationButton';\nexport type {\n LogoURLs,\n CompanyLogoProps,\n} from './components/CompanyLogo/CompanyLogo';\n\nexport type {\n NotificationBannerProps,\n NotificationBannerDismiss,\n} from './components/NotificationBanner';\n\nexport type {\n GlobalHeaderComponentMountPoint,\n GlobalHeaderComponentMountPointConfig,\n} from './types';\n\nexport { defaultGlobalHeaderComponentsMountPoints } from './defaultMountPoints/defaultMountPoints';\n\n/**\n * Global Header Plugin\n *\n * @public\n */\nexport const globalHeaderPlugin = createPlugin({\n id: 'global-header',\n});\n\n/**\n * Global Header\n *\n * @public\n */\nexport const GlobalHeader = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'GlobalHeader',\n component: {\n lazy: () => import('./components/GlobalHeader').then(m => m.GlobalHeader),\n },\n }),\n);\n\n/**\n * Global Header Component\n *\n * @public\n */\nexport const GlobalHeaderComponent: ComponentType<GlobalHeaderComponentProps> =\n globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'GlobalHeaderComponent',\n component: {\n lazy: () =>\n import('./components/GlobalHeaderComponent').then(\n m => m.GlobalHeaderComponent,\n ),\n },\n }),\n );\n\n/**\n * @public\n */\nexport const HeaderButton = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'HeaderButton',\n component: {\n lazy: () =>\n import('./components/HeaderButton/HeaderButton').then(\n m => m.HeaderButton,\n ),\n },\n }),\n);\n\n/**\n * @public\n */\nexport const HeaderIcon = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'HeaderIcon',\n component: {\n lazy: () =>\n import('./components/HeaderIcon/HeaderIcon').then(m => m.HeaderIcon),\n },\n }),\n);\n\n/**\n * @public\n */\nexport const HeaderIconButton = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'HeaderIconButton',\n component: {\n lazy: () =>\n import('./components/HeaderIconButton/HeaderIconButton').then(\n m => m.HeaderIconButton,\n ),\n },\n }),\n);\n\n/**\n * Search Component\n *\n * @public\n */\nexport const SearchComponent: ComponentType = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'SearchComponent',\n component: {\n lazy: () =>\n import('./components/SearchComponent/SearchComponent').then(\n m => m.SearchComponent,\n ),\n },\n }),\n);\n\n/**\n * Create Dropdown\n *\n * @public\n */\nexport const CreateDropdown: ComponentType<CreateDropdownProps> =\n globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'CreateDropdown',\n component: {\n lazy: () =>\n import('./components/HeaderDropdownComponent/CreateDropdown').then(\n m => m.CreateDropdown,\n ),\n },\n }),\n );\n\n/**\n * Profile Dropdown\n *\n * @public\n */\nexport const ProfileDropdown: ComponentType<ProfileDropdownProps> =\n globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'ProfileDropdown',\n component: {\n lazy: () =>\n import('./components/HeaderDropdownComponent/ProfileDropdown').then(\n m => m.ProfileDropdown,\n ),\n },\n }),\n );\n\n/**\n * Software Templates List\n *\n * @public\n */\nexport const SoftwareTemplatesSection: ComponentType<SoftwareTemplatesSectionProps> =\n globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'SoftwareTemplatesSection',\n component: {\n lazy: () =>\n import(\n './components/HeaderDropdownComponent/SoftwareTemplatesSection'\n ).then(m => m.SoftwareTemplatesSection),\n },\n }),\n );\n\n/**\n * Register A Component Link\n *\n * @public\n */\nexport const RegisterAComponentSection: ComponentType<RegisterAComponentSectionProps> =\n globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'RegisterAComponentSection',\n component: {\n lazy: () =>\n import(\n './components/HeaderDropdownComponent/RegisterAComponentSection'\n ).then(m => m.RegisterAComponentSection),\n },\n }),\n );\n\n/**\n * Header Link\n *\n * @public\n */\nexport const MenuItemLink: ComponentType<MenuItemLinkProps> =\n globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'MenuItemLink',\n component: {\n lazy: () =>\n import('./components/MenuItemLink/MenuItemLink').then(\n m => m.MenuItemLink,\n ),\n },\n }),\n );\n\n/**\n * Header Logout Button\n *\n * @public\n */\nexport const LogoutButton: ComponentType = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'LogoutButton',\n component: {\n lazy: () =>\n import('./components/LogoutButton/LogoutButton').then(\n m => m.LogoutButton,\n ),\n },\n }),\n);\n\n/**\n * Spacer component that allow users to add a flexible spacing between components.\n *\n * Supports two props: `growFactor` with default 1 and `minWidth` width default 8 pixels.\n *\n * @public\n */\nexport const Spacer = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'Spacer',\n component: {\n lazy: () => import('./components/Spacer/Spacer').then(m => m.Spacer),\n },\n }),\n);\n\n/**\n * @public\n */\nexport const Divider = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'Divider',\n component: {\n lazy: () => import('./components/Divider/Divider').then(m => m.Divider),\n },\n }),\n);\n\n/**\n * @public\n */\nexport const SupportButton: ComponentType<SupportButtonProps> =\n globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'SupportButton',\n component: {\n lazy: () =>\n import('./components/SupportButton/SupportButton').then(\n m => m.SupportButton,\n ),\n },\n }),\n );\n\n/**\n * @public\n */\nexport const QuickstartButton: ComponentType<QuickstartButtonProps> =\n globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'QuickstartButton',\n component: {\n lazy: () =>\n import('./components/QuickstartButton/QuickstartButton').then(\n m => m.QuickstartButton,\n ),\n },\n }),\n );\n\n/**\n * @public\n */\nexport const NotificationButton = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'NotificationButton',\n component: {\n lazy: () =>\n import('./components/NotificationButton/NotificationButton').then(\n m => m.NotificationButton,\n ),\n },\n }),\n);\n\n/**\n * NotificationBanner\n *\n * @public\n */\nexport const NotificationBanner = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'NotificationBanner',\n component: {\n lazy: () =>\n import('./components/NotificationBanner').then(\n m => m.NotificationBanner,\n ),\n },\n }),\n);\n\n/**\n * Starred Dropdown\n *\n * @public\n */\nexport const StarredDropdown = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'StarredDropdown',\n component: {\n lazy: () =>\n import('./components/HeaderDropdownComponent/StarredDropdown').then(\n m => m.StarredDropdown,\n ),\n },\n }),\n);\n\n/**\n * Application Launcher Dropdown\n *\n * @public\n */\nexport const ApplicationLauncherDropdown = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'ApplicationLauncherDropdown',\n component: {\n lazy: () =>\n import(\n './components/HeaderDropdownComponent/ApplicationLauncherDropdown'\n ).then(m => m.ApplicationLauncherDropdown),\n },\n }),\n);\n\n/**\n * Company Logo\n *\n * @public\n */\nexport const CompanyLogo = globalHeaderPlugin.provide(\n createComponentExtension({\n name: 'CompanyLogo',\n component: {\n lazy: () =>\n import('./components/CompanyLogo/CompanyLogo').then(m => m.CompanyLogo),\n },\n }),\n);\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAuEO,MAAM,qBAAqB,YAAa,CAAA;AAAA,EAC7C,EAAI,EAAA;AACN,CAAC;AAOM,MAAM,eAAe,kBAAmB,CAAA,OAAA;AAAA,EAC7C,wBAAyB,CAAA;AAAA,IACvB,IAAM,EAAA,cAAA;AAAA,IACN,SAAW,EAAA;AAAA,MACT,IAAA,EAAM,MAAM,OAAO,kCAA2B,EAAE,IAAK,CAAA,CAAA,CAAA,KAAK,EAAE,YAAY;AAAA;AAC1E,GACD;AACH;AAOO,MAAM,wBACX,kBAAmB,CAAA,OAAA;AAAA,EACjB,wBAAyB,CAAA;AAAA,IACvB,IAAM,EAAA,uBAAA;AAAA,IACN,SAAW,EAAA;AAAA,MACT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