@flipdish/portal-library 1.0.20 → 1.0.22
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/dist/components/index.cjs.js +2 -0
- package/dist/components/index.cjs.js.map +1 -0
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +1 -15
- package/dist/components/index.js.map +1 -1
- package/dist/components/themes/flipdishPublicTheme.cjs.js +2 -0
- package/dist/components/themes/flipdishPublicTheme.cjs.js.map +1 -0
- package/dist/components/themes/flipdishPublicTheme.d.ts +9 -2
- package/dist/components/themes/flipdishPublicTheme.js +1 -172
- package/dist/components/themes/flipdishPublicTheme.js.map +1 -1
- package/dist/components/ui/FDErrorBoundary/FDErrorBoundary.cjs.js +2 -0
- package/dist/components/ui/FDErrorBoundary/FDErrorBoundary.cjs.js.map +1 -0
- package/dist/components/ui/FDErrorBoundary/FDErrorBoundary.js +2 -0
- package/dist/components/ui/FDErrorBoundary/FDErrorBoundary.js.map +1 -0
- package/dist/components/ui/LazyComponent/LazyComponent.cjs.js +2 -0
- package/dist/components/ui/LazyComponent/{LazyComponent.esm.js.map → LazyComponent.cjs.js.map} +1 -1
- package/dist/components/ui/LazyComponent/LazyComponent.js +1 -15
- package/dist/components/ui/LazyComponent/LazyComponent.js.map +1 -1
- package/dist/components/ui/NotFoundPage/NotFoundPage.cjs.js +2 -0
- package/dist/components/ui/NotFoundPage/NotFoundPage.cjs.js.map +1 -0
- package/dist/components/ui/NotFoundPage/NotFoundPage.js +1 -20
- package/dist/components/ui/NotFoundPage/NotFoundPage.js.map +1 -1
- package/dist/components/ui/PageLayout/DocumentTitle.cjs.js +2 -0
- package/dist/components/ui/PageLayout/DocumentTitle.cjs.js.map +1 -0
- package/dist/components/ui/PageLayout/DocumentTitle.js +2 -0
- package/dist/components/ui/PageLayout/DocumentTitle.js.map +1 -0
- package/dist/components/ui/PageLayout/FullWidthContainer.cjs.js +2 -0
- package/dist/components/ui/PageLayout/FullWidthContainer.cjs.js.map +1 -0
- package/dist/components/ui/PageLayout/FullWidthContainer.js +2 -0
- package/dist/components/ui/PageLayout/FullWidthContainer.js.map +1 -0
- package/dist/components/ui/PageLayout/PageLayout.cjs.js +2 -0
- package/dist/components/ui/PageLayout/PageLayout.cjs.js.map +1 -0
- package/dist/components/ui/PageLayout/PageLayout.d.ts +26 -0
- package/dist/components/ui/PageLayout/PageLayout.js +2 -0
- package/dist/components/ui/PageLayout/PageLayout.js.map +1 -0
- package/dist/components/ui/PortalMock/PortalMock.cjs.js +2 -0
- package/dist/components/ui/PortalMock/{PortalMock.esm.js.map → PortalMock.cjs.js.map} +1 -1
- package/dist/components/ui/PortalMock/PortalMock.js +1 -46
- package/dist/components/ui/PortalMock/PortalMock.js.map +1 -1
- package/dist/components/ui/Spacer/Spacer.cjs.js +2 -0
- package/dist/components/ui/Spacer/{Spacer.esm.js.map → Spacer.cjs.js.map} +1 -1
- package/dist/components/ui/Spacer/Spacer.js +1 -33
- package/dist/components/ui/Spacer/Spacer.js.map +1 -1
- package/dist/localization/en.json.cjs.js +2 -0
- package/dist/localization/en.json.cjs.js.map +1 -0
- package/dist/localization/en.json.js +1 -66
- package/dist/localization/en.json.js.map +1 -1
- package/dist/node_modules/.pnpm/@remix-run_router@1.20.0/node_modules/@remix-run/router/dist/router.cjs.js +12 -0
- package/dist/node_modules/.pnpm/@remix-run_router@1.20.0/node_modules/@remix-run/router/dist/router.cjs.js.map +1 -0
- package/dist/node_modules/.pnpm/@remix-run_router@1.20.0/node_modules/@remix-run/router/dist/router.js +12 -0
- package/dist/node_modules/.pnpm/@remix-run_router@1.20.0/node_modules/@remix-run/router/dist/router.js.map +1 -0
- package/dist/node_modules/.pnpm/react-router@6.27.0_react@18.3.1/node_modules/react-router/dist/index.cjs.js +12 -0
- package/dist/node_modules/.pnpm/react-router@6.27.0_react@18.3.1/node_modules/react-router/dist/index.cjs.js.map +1 -0
- package/dist/node_modules/.pnpm/react-router@6.27.0_react@18.3.1/node_modules/react-router/dist/index.js +12 -0
- package/dist/node_modules/.pnpm/react-router@6.27.0_react@18.3.1/node_modules/react-router/dist/index.js.map +1 -0
- package/dist/providers/TranslationProvider.cjs.js +2 -0
- package/dist/providers/{TranslationProvider.esm.js.map → TranslationProvider.cjs.js.map} +1 -1
- package/dist/providers/TranslationProvider.js +1 -22
- package/dist/providers/TranslationProvider.js.map +1 -1
- package/dist/utilities/renderUtilities.cjs.js +2 -0
- package/dist/utilities/renderUtilities.cjs.js.map +1 -0
- package/dist/utilities/renderUtilities.js +2 -0
- package/dist/utilities/renderUtilities.js.map +1 -0
- package/dist/utilities/validation.cjs.js +2 -0
- package/dist/utilities/validation.cjs.js.map +1 -0
- package/dist/utilities/validation.js +2 -0
- package/dist/utilities/validation.js.map +1 -0
- package/package.json +3 -10
- package/dist/components/index.esm.js +0 -6
- package/dist/components/index.esm.js.map +0 -1
- package/dist/components/themes/flipdishPublicTheme.esm.js +0 -171
- package/dist/components/themes/flipdishPublicTheme.esm.js.map +0 -1
- package/dist/components/ui/LazyComponent/LazyComponent.esm.js +0 -14
- package/dist/components/ui/NotFoundPage/NotFoundPage.esm.js +0 -19
- package/dist/components/ui/NotFoundPage/NotFoundPage.esm.js.map +0 -1
- package/dist/components/ui/PortalMock/PortalMock.esm.js +0 -45
- package/dist/components/ui/Spacer/Spacer.esm.js +0 -32
- package/dist/localization/en.json.esm.js +0 -52
- package/dist/localization/en.json.esm.js.map +0 -1
- package/dist/providers/TranslationProvider.esm.js +0 -21
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PageLayout.js","sources":["../../../../src/components/ui/PageLayout/PageLayout.tsx"],"sourcesContent":["import React, { ComponentType, ReactNode } from 'react';\n\nimport Add from '@mui/icons-material/Add';\nimport ArrowBackIcon from '@mui/icons-material/ArrowBack';\nimport Grid from '@mui/material/Grid';\nimport IconButton from '@mui/material/IconButton';\nimport { styled, useTheme } from '@mui/material/styles';\nimport Typography from '@mui/material/Typography';\nimport useMediaQuery from '@mui/material/useMediaQuery';\n\nimport DocumentTitle from './DocumentTitle';\nimport FullWidthContainer from './FullWidthContainer';\nimport FDErrorBoundary from '../FDErrorBoundary/FDErrorBoundary';\nimport Button from '@mui/material/Button';\nimport { useTranslation } from '../../../providers/TranslationProvider';\nimport { getMicroFrontendAttribute } from '../../../utilities/renderUtilities';\nimport { joinUrlPaths } from '../../../utilities/validation';\nimport Spacer from '../Spacer/Spacer';\nimport { useNavigate } from 'react-router-dom';\n\nexport const HORIZONTAL_SPACE_CLASSNAME = 'horizontal-content-space';\nexport const LEFT_HORIZONTAL_SPACE_CLASSNAME = 'left-horizontal-content-space';\nexport const RIGHT_HORIZONTAL_SPACE_CLASSNAME = 'right-horizontal-content-space';\nexport const VERTICAL_SPACE_CLASSNAME = 'vertical-content-space';\nexport const maxWidth = 1112;\nconst historyMinLength = 3;\n\nconst StyledWrapper = styled('div')<{ fluid: boolean }>(({ theme, fluid }) => ({\n maxWidth: fluid ? 'none' : maxWidth,\n [theme.breakpoints.down('md')]: {\n maxWidth: 'none',\n },\n margin: theme.spacing(2, 4),\n}));\n\nconst StyledActionButtonGrid = styled(Grid)(({ theme }) => ({\n [theme.breakpoints.down('sm')]: {\n width: '100%',\n paddingTop: theme.spacing(2),\n },\n}));\n\nconst StyledHeader = styled(Grid)(({ theme }) => ({\n flexWrap: 'nowrap',\n alignItems: 'flex-start',\n paddingTop: theme.spacing(3),\n paddingBottom: theme.spacing(3),\n\n [theme.breakpoints.down('md')]: {\n paddingTop: theme.spacing(2),\n paddingBottom: theme.spacing(3),\n },\n}));\n\nconst StyledTitleContainer = styled(Grid)(({ theme }) => ({\n paddingTop: theme.spacing(2),\n}));\n\nconst StyledTitleSection = styled(Grid)(() => ({\n flexGrow: 1,\n}));\n\nconst StyledTopSection = styled('div')(({ theme }) => ({\n maxWidth,\n paddingBottom: theme.spacing(3),\n\n [theme.breakpoints.down('md')]: {\n paddingBottom: theme.spacing(2),\n paddingLeft: theme.spacing(2),\n paddingRight: theme.spacing(2),\n },\n}));\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nconst StyledBackButton = styled(IconButton)<{ hasTitleComponent: boolean; component: any }>(({ theme, hasTitleComponent }) => ({\n margin: hasTitleComponent ? theme.spacing(-0.75, 0, -1.5, -1.5) : theme.spacing(-1.5, 0, -1.5, -1.5),\n\n [theme.breakpoints.only('sm')]: {\n marginLeft: theme.spacing(-2),\n },\n\n [theme.breakpoints.only('xs')]: {\n marginLeft: theme.spacing(-2),\n },\n}));\n\nconst StyledInnerWrapper = styled('div')(({ theme }) => ({\n maxWidth,\n marginLeft: theme.spacing(6),\n marginRight: theme.spacing(4),\n paddingBottom: theme.spacing(2),\n\n [theme.breakpoints.only('md')]: {\n marginLeft: 12,\n marginRight: theme.spacing(3),\n },\n\n [theme.breakpoints.only('sm')]: {\n marginLeft: theme.spacing(3),\n marginRight: theme.spacing(3),\n maxWidth: 'none',\n },\n\n [theme.breakpoints.only('xs')]: {\n marginLeft: theme.spacing(2),\n marginRight: theme.spacing(2),\n maxWidth: 'none',\n },\n}));\n\nconst StyledHeaderContainer = styled(Grid)(() => ({\n display: 'flex',\n flexGrow: 1,\n justifyContent: 'flex-end',\n}));\nconst StyledCaption = styled(Typography)<{ component: string }>(() => ({\n lineHeight: '26px',\n}));\n\nexport const PageTitle = ({ title }: { title: string | ReactNode }) => (\n <Typography variant=\"h5\" component=\"h2\">\n {title}\n </Typography>\n);\n\nexport type Props = {\n actionBtnTitle?: TranslationId;\n caption?: ReactNode;\n children: ReactNode;\n contextButtons?: ReactNode[];\n documentTitle: string;\n fluid?: boolean;\n fullWidth?: boolean;\n header?: ReactNode;\n hideHeader?: boolean;\n actionButtonLink?: string;\n pageHeader?: ReactNode;\n showActionButton?: boolean;\n showAddIcon?: boolean;\n strictToParent?: boolean;\n title: ReactNode;\n titleComponent?: ComponentType<React.PropsWithChildren<unknown>>;\n toParent?: string;\n openLinkInNewTab?: boolean;\n};\n\nconst PageLayout = (props: Props) => {\n const {\n actionBtnTitle,\n caption,\n children,\n contextButtons,\n documentTitle,\n fluid = false,\n fullWidth,\n header,\n hideHeader,\n actionButtonLink,\n openLinkInNewTab = false,\n pageHeader,\n showActionButton,\n showAddIcon,\n strictToParent,\n title,\n titleComponent: TitleComponent,\n toParent,\n } = props;\n const { translate } = useTranslation();\n const navigate = useNavigate();\n const theme = useTheme();\n const isMobile = useMediaQuery(theme.breakpoints.down('md'));\n const baseUrl = getMicroFrontendAttribute('data-portal-base-url') || '/';\n const actionButtonWithHttps = actionButtonLink?.startsWith('https://');\n const actionButtonLinkFinal = actionButtonWithHttps\n ? actionButtonLink\n : actionButtonLink !== undefined\n ? joinUrlPaths(baseUrl, actionButtonLink)\n : '';\n\n return (\n <StyledWrapper fluid={fluid}>\n {documentTitle && <DocumentTitle>{documentTitle}</DocumentTitle>}\n\n {pageHeader ? pageHeader : null}\n <StyledInnerWrapper>\n {pageHeader && <Spacer size={16} variant=\"vertical\" />}\n {!hideHeader && (\n <StyledHeader container alignItems=\"center\" direction=\"column\">\n <Grid item container direction=\"row\" alignContent=\"space-between\">\n {toParent && (\n <Grid item>\n <StyledBackButton\n aria-label=\"Back\"\n data-testid=\"back_button\"\n hasTitleComponent={!!TitleComponent}\n component={'button'}\n onClick={() => {\n if (toParent && strictToParent) {\n navigate(toParent);\n } else if (toParent && history.length < historyMinLength) {\n navigate(toParent);\n } else {\n navigate(-1);\n }\n }}\n >\n <ArrowBackIcon />\n </StyledBackButton>\n </Grid>\n )}\n <StyledHeaderContainer item>{contextButtons && contextButtons.map((button) => <>{button}</>)}</StyledHeaderContainer>\n </Grid>\n <StyledTitleContainer item container>\n <StyledTitleSection item>\n {TitleComponent ? <TitleComponent /> : <PageTitle title={title} />}\n {caption && (\n <StyledCaption variant=\"caption\" component=\"h3\">\n {caption}\n </StyledCaption>\n )}\n </StyledTitleSection>\n\n {showActionButton && (\n <>\n {isMobile && <Spacer size={56} variant=\"vertical\" />}\n <StyledActionButtonGrid item>\n <Button\n variant=\"contained\"\n fullWidth={true}\n data-testid={`Action-button-${actionBtnTitle}`}\n href={openLinkInNewTab || actionButtonWithHttps ? actionButtonLinkFinal : ''}\n target={openLinkInNewTab ? '_blank' : undefined}\n rel={openLinkInNewTab ? 'noopener noreferrer' : undefined}\n onClick={!openLinkInNewTab && !actionButtonWithHttps ? () => navigate(actionButtonLink) : () => {}}\n >\n {showAddIcon && <Add />}\n {actionBtnTitle && translate(actionBtnTitle)}\n </Button>\n </StyledActionButtonGrid>\n </>\n )}\n </StyledTitleContainer>\n </StyledHeader>\n )}\n <FullWidthContainer fullWidth={fullWidth}>\n {header ? <StyledTopSection>{header}</StyledTopSection> : null}\n <FDErrorBoundary identifier={documentTitle}>\n <>{children}</>\n </FDErrorBoundary>\n </FullWidthContainer>\n </StyledInnerWrapper>\n </StyledWrapper>\n );\n};\n\nexport default PageLayout;\n"],"names":["maxWidth","StyledWrapper","styled","theme","fluid","breakpoints","down","margin","spacing","StyledActionButtonGrid","Grid","width","paddingTop","StyledHeader","flexWrap","alignItems","paddingBottom","StyledTitleContainer","StyledTitleSection","flexGrow","StyledTopSection","paddingLeft","paddingRight","StyledBackButton","IconButton","hasTitleComponent","only","marginLeft","StyledInnerWrapper","marginRight","StyledHeaderContainer","display","justifyContent","StyledCaption","Typography","lineHeight","PageTitle","title","_jsx","variant","component","children","PageLayout","props","actionBtnTitle","caption","contextButtons","documentTitle","fullWidth","header","hideHeader","actionButtonLink","openLinkInNewTab","pageHeader","showActionButton","showAddIcon","strictToParent","titleComponent","TitleComponent","toParent","translate","useTranslation","navigate","useNavigate","useTheme","isMobile","useMediaQuery","baseUrl","getMicroFrontendAttribute","actionButtonWithHttps","startsWith","actionButtonLinkFinal","undefined","joinUrlPaths","_jsxs","DocumentTitle","Spacer","size","container","direction","item","alignContent","onClick","history","length","ArrowBackIcon","map","button","_Fragment","Button","href","target","rel","Add","FullWidthContainer","FDErrorBoundary","identifier"],"mappings":"k5BAwBO,MAAMA,EAAW,KAGlBC,EAAgBC,E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,EACtCoB,IAAKxC,EAAmB,2BAAwBoB,EAChDU,QAAU9B,GAAqBiB,EAA2D,OAAnC,IAAMP,EAASX,GAA4BV,SAAA,CAEjGc,GAAejB,EAACuD,EAAM,CAAA,GACtBjD,GAAkBgB,EAAUhB,iBAQzD8B,EAACoB,EAAkB,CAAC9C,UAAWA,EAASP,SAAA,CACnCQ,EAASX,EAAClB,EAAgB,CAAAqB,SAAEQ,IAA6B,KAC1DX,EAACyD,EAAe,CAACC,WAAYjD,EAAaN,SACtCH,EAAGkD,EAAA,CAAA/C,SAAAA,cAKrB"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";var e=require("react/jsx-runtime"),r=require("@mui/material/styles"),t=require("@mui/material");const i=r.styled("div")((({theme:e})=>({display:"flex",justifyContent:"center",alignItems:"center",backgroundColor:e.palette.grey[300],height:"65px",color:e.palette.text.primary,borderBottom:`2px solid ${e.palette.grey[400]}`}))),o=r.styled("div")((({theme:e})=>({display:"flex",justifyContent:"center",alignItems:"center",backgroundColor:e.palette.grey[300],height:"100%",color:e.palette.text.primary}))),l=198;module.exports=({children:s,loadedFromPortal:n})=>{const a=r.useTheme();if(n)return e.jsx(e.Fragment,{children:s});const x=e.jsx(o,{children:e.jsx(t.Typography,{sx:{fontWeight:"bold"},children:"Sidebar"})});return e.jsxs(t.Box,{sx:{display:"flex"},children:[e.jsx(t.CssBaseline,{}),e.jsx(t.AppBar,{position:"fixed",sx:{width:{sm:"calc(100% - 198px)"},ml:{sm:"198px"},boxShadow:"none"},children:e.jsx(i,{children:e.jsx(t.Typography,{sx:{fontWeight:"bold"},children:"Header"})})}),e.jsx(t.Box,{component:"nav",sx:{width:{sm:l},flexShrink:{sm:0}},"aria-label":"mailbox folders",children:e.jsx(t.Drawer,{variant:"permanent",sx:{display:{xs:"none",sm:"block"},"& .MuiDrawer-paper":{boxSizing:"border-box",width:l,borderColor:a.palette.grey[400],borderWidth:"2px"}},open:!0,children:x})}),e.jsx(t.Box,{component:"main",sx:{flexGrow:1,width:{sm:"calc(100% - 198px)",marginTop:"65px"}},children:s})]})};
|
|
2
|
+
//# sourceMappingURL=PortalMock.cjs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PortalMock.
|
|
1
|
+
{"version":3,"file":"PortalMock.cjs.js","sources":["../../../../src/components/ui/PortalMock/PortalMock.tsx"],"sourcesContent":["import { styled, useTheme } from '@mui/material/styles';\nimport { AppBar, Box, CssBaseline, Drawer, Typography } from '@mui/material';\n\nconst StyledHeader = styled('div')(({ theme }) => ({\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n backgroundColor: theme.palette.grey[300],\n height: '65px',\n color: theme.palette.text.primary,\n borderBottom: `2px solid ${theme.palette.grey[400]}`,\n}));\n\nconst StyledSidebar = styled('div')(({ theme }) => ({\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n backgroundColor: theme.palette.grey[300],\n height: '100%',\n color: theme.palette.text.primary,\n}));\n\ntype Props = {\n loadedFromPortal: boolean;\n children: React.ReactNode;\n};\nconst drawerWidth = 198;\n\nconst PortalMock = ({ children, loadedFromPortal }: Props) => {\n const theme = useTheme();\n\n if (loadedFromPortal) {\n return <>{children}</>;\n }\n\n const drawer = (\n <StyledSidebar>\n <Typography sx={{ fontWeight: 'bold' }}>Sidebar</Typography>\n </StyledSidebar>\n );\n\n return (\n <Box sx={{ display: 'flex' }}>\n <CssBaseline />\n <AppBar\n position=\"fixed\"\n sx={{\n width: { sm: `calc(100% - ${drawerWidth}px)` },\n ml: { sm: `${drawerWidth}px` },\n boxShadow: 'none',\n }}\n >\n <StyledHeader>\n <Typography sx={{ fontWeight: 'bold' }}>Header</Typography>\n </StyledHeader>\n </AppBar>\n <Box component=\"nav\" sx={{ width: { sm: drawerWidth }, flexShrink: { sm: 0 } }} aria-label=\"mailbox folders\">\n <Drawer\n variant=\"permanent\"\n sx={{\n display: { xs: 'none', sm: 'block' },\n '& .MuiDrawer-paper': {\n boxSizing: 'border-box',\n width: drawerWidth,\n borderColor: theme.palette.grey[400],\n borderWidth: '2px',\n },\n }}\n open\n >\n {drawer}\n </Drawer>\n </Box>\n <Box component=\"main\" sx={{ flexGrow: 1, width: { sm: `calc(100% - ${drawerWidth}px)`, marginTop: '65px' } }}>\n {children}\n </Box>\n </Box>\n );\n};\n\nexport default PortalMock;\n"],"names":["StyledHeader","styled","theme","display","justifyContent","alignItems","backgroundColor","palette","grey","height","color","text","primary","borderBottom","StyledSidebar","drawerWidth","children","loadedFromPortal","useTheme","_jsx","jsx","_Fragment","Fragment","drawer","Typography","sx","fontWeight","_jsxs","Box","CssBaseline","AppBar","position","width","sm","ml","boxShadow","component","flexShrink","Drawer","variant","xs","boxSizing","borderColor","borderWidth","open","flexGrow","marginTop"],"mappings":"6GAGA,MAAMA,EAAeC,EAAAA,OAAO,MAAPA,EAAc,EAAGC,YAAa,CAC/CC,QAAS,OACTC,eAAgB,SAChBC,WAAY,SACZC,gBAAiBJ,EAAMK,QAAQC,KAAK,KACpCC,OAAQ,OACRC,MAAOR,EAAMK,QAAQI,KAAKC,QAC1BC,aAAc,aAAaX,EAAMK,QAAQC,KAAK,WAG5CM,EAAgBb,EAAAA,OAAO,MAAPA,EAAc,EAAGC,YAAa,CAChDC,QAAS,OACTC,eAAgB,SAChBC,WAAY,SACZC,gBAAiBJ,EAAMK,QAAQC,KAAK,KACpCC,OAAQ,OACRC,MAAOR,EAAMK,QAAQI,KAAKC,YAOxBG,EAAc,mBAED,EAAGC,WAAUC,uBAC5B,MAAMf,EAAQgB,EAAAA,WAEd,GAAID,EACA,OAAOE,EAAAC,IAAAC,EAAAC,SAAA,CAAAN,SAAGA,IAGd,MAAMO,EACFJ,EAAAA,IAACL,EAAa,CAAAE,SACVG,MAACK,aAAU,CAACC,GAAI,CAAEC,WAAY,QAA8BV,SAAA,cAIpE,OACIW,EAAAA,KAACC,EAAAA,IAAI,CAAAH,GAAI,CAAEtB,QAAS,QAAQa,SAAA,CACxBG,MAACU,EAAWA,YAAA,CAAA,GACZV,EAAAC,IAACU,EAAMA,OAAA,CACHC,SAAS,QACTN,GAAI,CACAO,MAAO,CAAEC,GAAI,sBACbC,GAAI,CAAED,GAAI,SACVE,UAAW,QAGfnB,SAAAG,EAAAC,IAACpB,EAAY,CAAAgB,SACTG,MAACK,EAAAA,YAAWC,GAAI,CAAEC,WAAY,QAA6BV,SAAA,eAGnEG,MAACS,EAAAA,IAAI,CAAAQ,UAAU,MAAMX,GAAI,CAAEO,MAAO,CAAEC,GAAIlB,GAAesB,WAAY,CAAEJ,GAAI,IAAK,aAAa,kBAAiBjB,SACxGG,EAAAA,IAACmB,EAAAA,OACG,CAAAC,QAAQ,YACRd,GAAI,CACAtB,QAAS,CAAEqC,GAAI,OAAQP,GAAI,SAC3B,qBAAsB,CAClBQ,UAAW,aACXT,MAAOjB,EACP2B,YAAaxC,EAAMK,QAAQC,KAAK,KAChCmC,YAAa,QAGrBC,MAEC,EAAA5B,SAAAO,MAGTJ,MAACS,EAAAA,IAAI,CAAAQ,UAAU,OAAOX,GAAI,CAAEoB,SAAU,EAAGb,MAAO,CAAEC,GAAI,qBAAiCa,UAAW,SAAU9B,SACvGA,MAGX"}
|
|
@@ -1,47 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
var jsxRuntime = require('react/jsx-runtime');
|
|
4
|
-
var styles = require('@mui/material/styles');
|
|
5
|
-
var material = require('@mui/material');
|
|
6
|
-
|
|
7
|
-
const StyledHeader = styles.styled('div')(({ theme }) => ({
|
|
8
|
-
display: 'flex',
|
|
9
|
-
justifyContent: 'center',
|
|
10
|
-
alignItems: 'center',
|
|
11
|
-
backgroundColor: theme.palette.grey[300],
|
|
12
|
-
height: '65px',
|
|
13
|
-
color: theme.palette.text.primary,
|
|
14
|
-
borderBottom: `2px solid ${theme.palette.grey[400]}`,
|
|
15
|
-
}));
|
|
16
|
-
const StyledSidebar = styles.styled('div')(({ theme }) => ({
|
|
17
|
-
display: 'flex',
|
|
18
|
-
justifyContent: 'center',
|
|
19
|
-
alignItems: 'center',
|
|
20
|
-
backgroundColor: theme.palette.grey[300],
|
|
21
|
-
height: '100%',
|
|
22
|
-
color: theme.palette.text.primary,
|
|
23
|
-
}));
|
|
24
|
-
const drawerWidth = 198;
|
|
25
|
-
const PortalMock = ({ children, loadedFromPortal }) => {
|
|
26
|
-
const theme = styles.useTheme();
|
|
27
|
-
if (loadedFromPortal) {
|
|
28
|
-
return jsxRuntime.jsx(jsxRuntime.Fragment, { children: children });
|
|
29
|
-
}
|
|
30
|
-
const drawer = (jsxRuntime.jsx(StyledSidebar, { children: jsxRuntime.jsx(material.Typography, { sx: { fontWeight: 'bold' }, children: "Sidebar" }) }));
|
|
31
|
-
return (jsxRuntime.jsxs(material.Box, { sx: { display: 'flex' }, children: [jsxRuntime.jsx(material.CssBaseline, {}), jsxRuntime.jsx(material.AppBar, { position: "fixed", sx: {
|
|
32
|
-
width: { sm: `calc(100% - ${drawerWidth}px)` },
|
|
33
|
-
ml: { sm: `${drawerWidth}px` },
|
|
34
|
-
boxShadow: 'none',
|
|
35
|
-
}, children: jsxRuntime.jsx(StyledHeader, { children: jsxRuntime.jsx(material.Typography, { sx: { fontWeight: 'bold' }, children: "Header" }) }) }), jsxRuntime.jsx(material.Box, { component: "nav", sx: { width: { sm: drawerWidth }, flexShrink: { sm: 0 } }, "aria-label": "mailbox folders", children: jsxRuntime.jsx(material.Drawer, { variant: "permanent", sx: {
|
|
36
|
-
display: { xs: 'none', sm: 'block' },
|
|
37
|
-
'& .MuiDrawer-paper': {
|
|
38
|
-
boxSizing: 'border-box',
|
|
39
|
-
width: drawerWidth,
|
|
40
|
-
borderColor: theme.palette.grey[400],
|
|
41
|
-
borderWidth: '2px',
|
|
42
|
-
},
|
|
43
|
-
}, open: true, children: drawer }) }), jsxRuntime.jsx(material.Box, { component: "main", sx: { flexGrow: 1, width: { sm: `calc(100% - ${drawerWidth}px)`, marginTop: '65px' } }, children: children })] }));
|
|
44
|
-
};
|
|
45
|
-
|
|
46
|
-
module.exports = PortalMock;
|
|
1
|
+
import{jsx as e,Fragment as r,jsxs as t}from"react/jsx-runtime";import{styled as o,useTheme as i}from"@mui/material/styles";import{Typography as l,Box as n,CssBaseline as a,AppBar as d,Drawer as m}from"@mui/material";const s=o("div")((({theme:e})=>({display:"flex",justifyContent:"center",alignItems:"center",backgroundColor:e.palette.grey[300],height:"65px",color:e.palette.text.primary,borderBottom:`2px solid ${e.palette.grey[400]}`}))),p=o("div")((({theme:e})=>({display:"flex",justifyContent:"center",alignItems:"center",backgroundColor:e.palette.grey[300],height:"100%",color:e.palette.text.primary}))),c=198,x=({children:o,loadedFromPortal:x})=>{const h=i();if(x)return e(r,{children:o});const f=e(p,{children:e(l,{sx:{fontWeight:"bold"},children:"Sidebar"})});return t(n,{sx:{display:"flex"},children:[e(a,{}),e(d,{position:"fixed",sx:{width:{sm:"calc(100% - 198px)"},ml:{sm:"198px"},boxShadow:"none"},children:e(s,{children:e(l,{sx:{fontWeight:"bold"},children:"Header"})})}),e(n,{component:"nav",sx:{width:{sm:c},flexShrink:{sm:0}},"aria-label":"mailbox folders",children:e(m,{variant:"permanent",sx:{display:{xs:"none",sm:"block"},"& .MuiDrawer-paper":{boxSizing:"border-box",width:c,borderColor:h.palette.grey[400],borderWidth:"2px"}},open:!0,children:f})}),e(n,{component:"main",sx:{flexGrow:1,width:{sm:"calc(100% - 198px)",marginTop:"65px"}},children:o})]})};export{x as default};
|
|
47
2
|
//# sourceMappingURL=PortalMock.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PortalMock.js","sources":["../../../../src/components/ui/PortalMock/PortalMock.tsx"],"sourcesContent":["import { styled, useTheme } from '@mui/material/styles';\nimport { AppBar, Box, CssBaseline, Drawer, Typography } from '@mui/material';\n\nconst StyledHeader = styled('div')(({ theme }) => ({\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n backgroundColor: theme.palette.grey[300],\n height: '65px',\n color: theme.palette.text.primary,\n borderBottom: `2px solid ${theme.palette.grey[400]}`,\n}));\n\nconst StyledSidebar = styled('div')(({ theme }) => ({\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n backgroundColor: theme.palette.grey[300],\n height: '100%',\n color: theme.palette.text.primary,\n}));\n\ntype Props = {\n loadedFromPortal: boolean;\n children: React.ReactNode;\n};\nconst drawerWidth = 198;\n\nconst PortalMock = ({ children, loadedFromPortal }: Props) => {\n const theme = useTheme();\n\n if (loadedFromPortal) {\n return <>{children}</>;\n }\n\n const drawer = (\n <StyledSidebar>\n <Typography sx={{ fontWeight: 'bold' }}>Sidebar</Typography>\n </StyledSidebar>\n );\n\n return (\n <Box sx={{ display: 'flex' }}>\n <CssBaseline />\n <AppBar\n position=\"fixed\"\n sx={{\n width: { sm: `calc(100% - ${drawerWidth}px)` },\n ml: { sm: `${drawerWidth}px` },\n boxShadow: 'none',\n }}\n >\n <StyledHeader>\n <Typography sx={{ fontWeight: 'bold' }}>Header</Typography>\n </StyledHeader>\n </AppBar>\n <Box component=\"nav\" sx={{ width: { sm: drawerWidth }, flexShrink: { sm: 0 } }} aria-label=\"mailbox folders\">\n <Drawer\n variant=\"permanent\"\n sx={{\n display: { xs: 'none', sm: 'block' },\n '& .MuiDrawer-paper': {\n boxSizing: 'border-box',\n width: drawerWidth,\n borderColor: theme.palette.grey[400],\n borderWidth: '2px',\n },\n }}\n open\n >\n {drawer}\n </Drawer>\n </Box>\n <Box component=\"main\" sx={{ flexGrow: 1, width: { sm: `calc(100% - ${drawerWidth}px)`, marginTop: '65px' } }}>\n {children}\n </Box>\n </Box>\n );\n};\n\nexport default PortalMock;\n"],"names":["styled","
|
|
1
|
+
{"version":3,"file":"PortalMock.js","sources":["../../../../src/components/ui/PortalMock/PortalMock.tsx"],"sourcesContent":["import { styled, useTheme } from '@mui/material/styles';\nimport { AppBar, Box, CssBaseline, Drawer, Typography } from '@mui/material';\n\nconst StyledHeader = styled('div')(({ theme }) => ({\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n backgroundColor: theme.palette.grey[300],\n height: '65px',\n color: theme.palette.text.primary,\n borderBottom: `2px solid ${theme.palette.grey[400]}`,\n}));\n\nconst StyledSidebar = styled('div')(({ theme }) => ({\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n backgroundColor: theme.palette.grey[300],\n height: '100%',\n color: theme.palette.text.primary,\n}));\n\ntype Props = {\n loadedFromPortal: boolean;\n children: React.ReactNode;\n};\nconst drawerWidth = 198;\n\nconst PortalMock = ({ children, loadedFromPortal }: Props) => {\n const theme = useTheme();\n\n if (loadedFromPortal) {\n return <>{children}</>;\n }\n\n const drawer = (\n <StyledSidebar>\n <Typography sx={{ fontWeight: 'bold' }}>Sidebar</Typography>\n </StyledSidebar>\n );\n\n return (\n <Box sx={{ display: 'flex' }}>\n <CssBaseline />\n <AppBar\n position=\"fixed\"\n sx={{\n width: { sm: `calc(100% - ${drawerWidth}px)` },\n ml: { sm: `${drawerWidth}px` },\n boxShadow: 'none',\n }}\n >\n <StyledHeader>\n <Typography sx={{ fontWeight: 'bold' }}>Header</Typography>\n </StyledHeader>\n </AppBar>\n <Box component=\"nav\" sx={{ width: { sm: drawerWidth }, flexShrink: { sm: 0 } }} aria-label=\"mailbox folders\">\n <Drawer\n variant=\"permanent\"\n sx={{\n display: { xs: 'none', sm: 'block' },\n '& .MuiDrawer-paper': {\n boxSizing: 'border-box',\n width: drawerWidth,\n borderColor: theme.palette.grey[400],\n borderWidth: '2px',\n },\n }}\n open\n >\n {drawer}\n </Drawer>\n </Box>\n <Box component=\"main\" sx={{ flexGrow: 1, width: { sm: `calc(100% - ${drawerWidth}px)`, marginTop: '65px' } }}>\n {children}\n </Box>\n </Box>\n );\n};\n\nexport default PortalMock;\n"],"names":["StyledHeader","styled","theme","display","justifyContent","alignItems","backgroundColor","palette","grey","height","color","text","primary","borderBottom","StyledSidebar","drawerWidth","PortalMock","children","loadedFromPortal","useTheme","_jsx","_Fragment","drawer","Typography","sx","fontWeight","_jsxs","Box","CssBaseline","AppBar","position","width","sm","ml","boxShadow","component","flexShrink","Drawer","variant","xs","boxSizing","borderColor","borderWidth","open","flexGrow","marginTop"],"mappings":"yNAGA,MAAMA,EAAeC,EAAO,MAAPA,EAAc,EAAGC,YAAa,CAC/CC,QAAS,OACTC,eAAgB,SAChBC,WAAY,SACZC,gBAAiBJ,EAAMK,QAAQC,KAAK,KACpCC,OAAQ,OACRC,MAAOR,EAAMK,QAAQI,KAAKC,QAC1BC,aAAc,aAAaX,EAAMK,QAAQC,KAAK,WAG5CM,EAAgBb,EAAO,MAAPA,EAAc,EAAGC,YAAa,CAChDC,QAAS,OACTC,eAAgB,SAChBC,WAAY,SACZC,gBAAiBJ,EAAMK,QAAQC,KAAK,KACpCC,OAAQ,OACRC,MAAOR,EAAMK,QAAQI,KAAKC,YAOxBG,EAAc,IAEdC,EAAa,EAAGC,WAAUC,uBAC5B,MAAMhB,EAAQiB,IAEd,GAAID,EACA,OAAOE,EAAAC,EAAA,CAAAJ,SAAGA,IAGd,MAAMK,EACFF,EAACN,EAAa,CAAAG,SACVG,EAACG,EAAU,CAACC,GAAI,CAAEC,WAAY,QAA8BR,SAAA,cAIpE,OACIS,EAACC,EAAI,CAAAH,GAAI,CAAErB,QAAS,QAAQc,SAAA,CACxBG,EAACQ,EAAW,CAAA,GACZR,EAACS,EAAM,CACHC,SAAS,QACTN,GAAI,CACAO,MAAO,CAAEC,GAAI,sBACbC,GAAI,CAAED,GAAI,SACVE,UAAW,QAGfjB,SAAAG,EAACpB,EAAY,CAAAiB,SACTG,EAACG,GAAWC,GAAI,CAAEC,WAAY,QAA6BR,SAAA,eAGnEG,EAACO,EAAI,CAAAQ,UAAU,MAAMX,GAAI,CAAEO,MAAO,CAAEC,GAAIjB,GAAeqB,WAAY,CAAEJ,GAAI,IAAK,aAAa,kBAAiBf,SACxGG,EAACiB,EACG,CAAAC,QAAQ,YACRd,GAAI,CACArB,QAAS,CAAEoC,GAAI,OAAQP,GAAI,SAC3B,qBAAsB,CAClBQ,UAAW,aACXT,MAAOhB,EACP0B,YAAavC,EAAMK,QAAQC,KAAK,KAChCkC,YAAa,QAGrBC,MAEC,EAAA1B,SAAAK,MAGTF,EAACO,EAAI,CAAAQ,UAAU,OAAOX,GAAI,CAAEoB,SAAU,EAAGb,MAAO,CAAEC,GAAI,qBAAiCa,UAAW,SAAU5B,SACvGA,MAGX"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";var i=require("react/jsx-runtime");const e=require("@mui/material/styles").styled("div")((({size:i=8,variant:e,children:r})=>{const a={padding:r?`${i}px`:void 0};return r?"horizontal"===e?a.margin=`${i}px 0`:"vertical"===e&&(a.margin=`0 ${i}px`):"horizontal"===e?a.height=`${i}px`:"vertical"===e&&(a.width=`${i}px`),a}));module.exports=({className:r,variant:a,size:t=8,children:s})=>i.jsx(e,{className:r,variant:a,size:t,children:s});
|
|
2
|
+
//# sourceMappingURL=Spacer.cjs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Spacer.
|
|
1
|
+
{"version":3,"file":"Spacer.cjs.js","sources":["../../../../src/components/ui/Spacer/Spacer.tsx"],"sourcesContent":["import { ReactNode } from 'react';\nimport { styled } from '@mui/material/styles';\n\nexport interface ISpacerProps {\n className?: string;\n variant?: 'horizontal' | 'vertical';\n size?: 8 | 16 | 24 | 32 | 40 | 56;\n children?: ReactNode;\n}\n\nconst SpacerDiv = styled('div')<ISpacerProps>(({ size = 8, variant, children }) => {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const style: any = {\n padding: children ? `${size}px` : undefined,\n };\n\n if (!children) {\n if (variant === 'horizontal') {\n style.height = `${size}px`;\n } else if (variant === 'vertical') {\n style.width = `${size}px`;\n }\n } else {\n if (variant === 'horizontal') {\n style.margin = `${size}px 0`;\n } else if (variant === 'vertical') {\n style.margin = `0 ${size}px`;\n }\n }\n\n return style;\n});\n\nconst Spacer = ({ className, variant, size = 8, children }: ISpacerProps) => {\n return (\n <SpacerDiv className={className} variant={variant} size={size}>\n {children}\n </SpacerDiv>\n );\n};\n\nexport default Spacer;\n"],"names":["SpacerDiv","styled","size","variant","children","style","padding","undefined","margin","height","width","className","_jsx"],"mappings":"gDAUA,MAAMA,kCAAYC,OAAO,MAAPA,EAA4B,EAAGC,OAAO,EAAGC,UAASC,eAEhE,MAAMC,EAAa,CACfC,QAASF,EAAW,GAAGF,WAAWK,GAiBtC,OAdKH,EAOe,eAAZD,EACAE,EAAMG,OAAS,GAAGN,QACC,aAAZC,IACPE,EAAMG,OAAS,KAAKN,OATR,eAAZC,EACAE,EAAMI,OAAS,GAAGP,MACC,aAAZC,IACPE,EAAMK,MAAQ,GAAGR,OAUlBG,CAAK,mBAGD,EAAGM,YAAWR,UAASD,OAAO,EAAGE,cAExCQ,MAACZ,GAAUW,UAAWA,EAAWR,QAASA,EAASD,KAAMA,WACpDE"}
|
|
@@ -1,34 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
var jsxRuntime = require('react/jsx-runtime');
|
|
4
|
-
var styles = require('@mui/material/styles');
|
|
5
|
-
|
|
6
|
-
const SpacerDiv = styles.styled('div')(({ size = 8, variant, children }) => {
|
|
7
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
8
|
-
const style = {
|
|
9
|
-
padding: children ? `${size}px` : undefined,
|
|
10
|
-
};
|
|
11
|
-
if (!children) {
|
|
12
|
-
if (variant === 'horizontal') {
|
|
13
|
-
style.height = `${size}px`;
|
|
14
|
-
}
|
|
15
|
-
else if (variant === 'vertical') {
|
|
16
|
-
style.width = `${size}px`;
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
else {
|
|
20
|
-
if (variant === 'horizontal') {
|
|
21
|
-
style.margin = `${size}px 0`;
|
|
22
|
-
}
|
|
23
|
-
else if (variant === 'vertical') {
|
|
24
|
-
style.margin = `0 ${size}px`;
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
return style;
|
|
28
|
-
});
|
|
29
|
-
const Spacer = ({ className, variant, size = 8, children }) => {
|
|
30
|
-
return (jsxRuntime.jsx(SpacerDiv, { className: className, variant: variant, size: size, children: children }));
|
|
31
|
-
};
|
|
32
|
-
|
|
33
|
-
module.exports = Spacer;
|
|
1
|
+
import{jsx as i}from"react/jsx-runtime";import{styled as a}from"@mui/material/styles";const r=a("div")((({size:i=8,variant:a,children:r})=>{const t={padding:r?`${i}px`:void 0};return r?"horizontal"===a?t.margin=`${i}px 0`:"vertical"===a&&(t.margin=`0 ${i}px`):"horizontal"===a?t.height=`${i}px`:"vertical"===a&&(t.width=`${i}px`),t})),t=({className:a,variant:t,size:e=8,children:n})=>i(r,{className:a,variant:t,size:e,children:n});export{t as default};
|
|
34
2
|
//# sourceMappingURL=Spacer.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Spacer.js","sources":["../../../../src/components/ui/Spacer/Spacer.tsx"],"sourcesContent":["import { ReactNode } from 'react';\nimport { styled } from '@mui/material/styles';\n\nexport interface ISpacerProps {\n className?: string;\n variant?: 'horizontal' | 'vertical';\n size?: 8 | 16 | 24 | 32 | 40 | 56;\n children?: ReactNode;\n}\n\nconst SpacerDiv = styled('div')<ISpacerProps>(({ size = 8, variant, children }) => {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const style: any = {\n padding: children ? `${size}px` : undefined,\n };\n\n if (!children) {\n if (variant === 'horizontal') {\n style.height = `${size}px`;\n } else if (variant === 'vertical') {\n style.width = `${size}px`;\n }\n } else {\n if (variant === 'horizontal') {\n style.margin = `${size}px 0`;\n } else if (variant === 'vertical') {\n style.margin = `0 ${size}px`;\n }\n }\n\n return style;\n});\n\nconst Spacer = ({ className, variant, size = 8, children }: ISpacerProps) => {\n return (\n <SpacerDiv className={className} variant={variant} size={size}>\n {children}\n </SpacerDiv>\n );\n};\n\nexport default Spacer;\n"],"names":["styled","
|
|
1
|
+
{"version":3,"file":"Spacer.js","sources":["../../../../src/components/ui/Spacer/Spacer.tsx"],"sourcesContent":["import { ReactNode } from 'react';\nimport { styled } from '@mui/material/styles';\n\nexport interface ISpacerProps {\n className?: string;\n variant?: 'horizontal' | 'vertical';\n size?: 8 | 16 | 24 | 32 | 40 | 56;\n children?: ReactNode;\n}\n\nconst SpacerDiv = styled('div')<ISpacerProps>(({ size = 8, variant, children }) => {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const style: any = {\n padding: children ? `${size}px` : undefined,\n };\n\n if (!children) {\n if (variant === 'horizontal') {\n style.height = `${size}px`;\n } else if (variant === 'vertical') {\n style.width = `${size}px`;\n }\n } else {\n if (variant === 'horizontal') {\n style.margin = `${size}px 0`;\n } else if (variant === 'vertical') {\n style.margin = `0 ${size}px`;\n }\n }\n\n return style;\n});\n\nconst Spacer = ({ className, variant, size = 8, children }: ISpacerProps) => {\n return (\n <SpacerDiv className={className} variant={variant} size={size}>\n {children}\n </SpacerDiv>\n );\n};\n\nexport default Spacer;\n"],"names":["SpacerDiv","styled","size","variant","children","style","padding","undefined","margin","height","width","Spacer","className","_jsx"],"mappings":"sFAUA,MAAMA,EAAYC,EAAO,MAAPA,EAA4B,EAAGC,OAAO,EAAGC,UAASC,eAEhE,MAAMC,EAAa,CACfC,QAASF,EAAW,GAAGF,WAAWK,GAiBtC,OAdKH,EAOe,eAAZD,EACAE,EAAMG,OAAS,GAAGN,QACC,aAAZC,IACPE,EAAMG,OAAS,KAAKN,OATR,eAAZC,EACAE,EAAMI,OAAS,GAAGP,MACC,aAAZC,IACPE,EAAMK,MAAQ,GAAGR,OAUlBG,CAAK,IAGVM,EAAS,EAAGC,YAAWT,UAASD,OAAO,EAAGE,cAExCS,EAACb,GAAUY,UAAWA,EAAWT,QAASA,EAASD,KAAMA,WACpDE"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e={value:"Home"},o={value:"About"},t={value:"Welcome to the new Flipdish Portal"},a={value:"Page Not Found"},_={value:"Click on the Vite and React logos to learn more"},r={value:"Go to About Page"},l={value:"Go to home Page"},u={value:"Welcome to the About Page"},p={value:"About Page"},n={value:"Something went wrong, please refresh the page"},s={value:"Count is {count}"},g={Home:e,About:o,Welcome_to_new_portal:t,Page_Not_Found:a,"Micro-Frontend_Example":{value:"Micro-Frontend Example"},Click_vite_react:_,Go_to_about_page:r,Go_to_home_page:l,Welcome_about_page:u,About_Page:p,Something_went_wrong_please_refresh_the_page:n,Count_is:s};exports.About=o,exports.About_Page=p,exports.Click_vite_react=_,exports.Count_is=s,exports.Go_to_about_page=r,exports.Go_to_home_page=l,exports.Home=e,exports.Page_Not_Found=a,exports.Something_went_wrong_please_refresh_the_page=n,exports.Welcome_about_page=u,exports.Welcome_to_new_portal=t,exports.default=g;
|
|
2
|
+
//# sourceMappingURL=en.json.cjs.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"en.json.cjs.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
@@ -1,67 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
-
|
|
5
|
-
var Home = {
|
|
6
|
-
value: "Home"
|
|
7
|
-
};
|
|
8
|
-
var About = {
|
|
9
|
-
value: "About"
|
|
10
|
-
};
|
|
11
|
-
var Welcome_to_new_portal = {
|
|
12
|
-
value: "Welcome to the new Flipdish Portal"
|
|
13
|
-
};
|
|
14
|
-
var Page_Not_Found = {
|
|
15
|
-
value: "Page Not Found"
|
|
16
|
-
};
|
|
17
|
-
var Click_vite_react = {
|
|
18
|
-
value: "Click on the Vite and React logos to learn more"
|
|
19
|
-
};
|
|
20
|
-
var Go_to_about_page = {
|
|
21
|
-
value: "Go to About Page"
|
|
22
|
-
};
|
|
23
|
-
var Go_to_home_page = {
|
|
24
|
-
value: "Go to home Page"
|
|
25
|
-
};
|
|
26
|
-
var Welcome_about_page = {
|
|
27
|
-
value: "Welcome to the About Page"
|
|
28
|
-
};
|
|
29
|
-
var About_Page = {
|
|
30
|
-
value: "About Page"
|
|
31
|
-
};
|
|
32
|
-
var Something_went_wrong_please_refresh_the_page = {
|
|
33
|
-
value: "Something went wrong, please refresh the page"
|
|
34
|
-
};
|
|
35
|
-
var Count_is = {
|
|
36
|
-
value: "Count is {count}"
|
|
37
|
-
};
|
|
38
|
-
var en = {
|
|
39
|
-
Home: Home,
|
|
40
|
-
About: About,
|
|
41
|
-
Welcome_to_new_portal: Welcome_to_new_portal,
|
|
42
|
-
Page_Not_Found: Page_Not_Found,
|
|
43
|
-
"Micro-Frontend_Example": {
|
|
44
|
-
value: "Micro-Frontend Example"
|
|
45
|
-
},
|
|
46
|
-
Click_vite_react: Click_vite_react,
|
|
47
|
-
Go_to_about_page: Go_to_about_page,
|
|
48
|
-
Go_to_home_page: Go_to_home_page,
|
|
49
|
-
Welcome_about_page: Welcome_about_page,
|
|
50
|
-
About_Page: About_Page,
|
|
51
|
-
Something_went_wrong_please_refresh_the_page: Something_went_wrong_please_refresh_the_page,
|
|
52
|
-
Count_is: Count_is
|
|
53
|
-
};
|
|
54
|
-
|
|
55
|
-
exports.About = About;
|
|
56
|
-
exports.About_Page = About_Page;
|
|
57
|
-
exports.Click_vite_react = Click_vite_react;
|
|
58
|
-
exports.Count_is = Count_is;
|
|
59
|
-
exports.Go_to_about_page = Go_to_about_page;
|
|
60
|
-
exports.Go_to_home_page = Go_to_home_page;
|
|
61
|
-
exports.Home = Home;
|
|
62
|
-
exports.Page_Not_Found = Page_Not_Found;
|
|
63
|
-
exports.Something_went_wrong_please_refresh_the_page = Something_went_wrong_please_refresh_the_page;
|
|
64
|
-
exports.Welcome_about_page = Welcome_about_page;
|
|
65
|
-
exports.Welcome_to_new_portal = Welcome_to_new_portal;
|
|
66
|
-
exports.default = en;
|
|
1
|
+
var e={value:"Home"},o={value:"About"},t={value:"Welcome to the new Flipdish Portal"},a={value:"Page Not Found"},l={value:"Click on the Vite and React logos to learn more"},u={value:"Go to About Page"},_={value:"Go to home Page"},n={value:"Welcome to the About Page"},g={value:"About Page"},r={value:"Something went wrong, please refresh the page"},v={value:"Count is {count}"},m={Home:e,About:o,Welcome_to_new_portal:t,Page_Not_Found:a,"Micro-Frontend_Example":{value:"Micro-Frontend Example"},Click_vite_react:l,Go_to_about_page:u,Go_to_home_page:_,Welcome_about_page:n,About_Page:g,Something_went_wrong_please_refresh_the_page:r,Count_is:v};export{o as About,g as About_Page,l as Click_vite_react,v as Count_is,u as Go_to_about_page,_ as Go_to_home_page,e as Home,a as Page_Not_Found,r as Something_went_wrong_please_refresh_the_page,n as Welcome_about_page,t as Welcome_to_new_portal,m as default};
|
|
67
2
|
//# sourceMappingURL=en.json.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"en.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"en.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* @remix-run/router v1.20.0
|
|
4
|
+
*
|
|
5
|
+
* Copyright (c) Remix Software Inc.
|
|
6
|
+
*
|
|
7
|
+
* This source code is licensed under the MIT license found in the
|
|
8
|
+
* LICENSE.md file in the root directory of this source tree.
|
|
9
|
+
*
|
|
10
|
+
* @license MIT
|
|
11
|
+
*/function t(){return t=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},t.apply(this,arguments)}var e,n;function r(t,e){if(!1===t||null==t)throw new Error(e)}function a(t){let e={};if(t){let n=t.indexOf("#");n>=0&&(e.hash=t.substr(n),t=t.substr(0,n));let r=t.indexOf("?");r>=0&&(e.search=t.substr(r),t=t.substr(0,r)),t&&(e.pathname=t)}return e}function s(t,e){void 0===e&&(e="/");let{pathname:n,search:r="",hash:s=""}="string"==typeof t?a(t):t,o=n?n.startsWith("/")?n:function(t,e){let n=e.replace(/\/+$/,"").split("/");return t.split("/").forEach((t=>{".."===t?n.length>1&&n.pop():"."!==t&&n.push(t)})),n.length>1?n.join("/"):"/"}(n,e):e;return{pathname:o,search:i(r),hash:h(s)}}function o(t,e,n,r){return"Cannot include a '"+t+"' character in a manually specified `to."+e+"` field ["+JSON.stringify(r)+"]. Please separate it out to the `to."+n+'` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.'}exports.Action=void 0,(e=exports.Action||(exports.Action={})).Pop="POP",e.Push="PUSH",e.Replace="REPLACE",function(t){t.data="data",t.deferred="deferred",t.redirect="redirect",t.error="error"}(n||(n={}));const i=t=>t&&"?"!==t?t.startsWith("?")?t:"?"+t:"",h=t=>t&&"#"!==t?t.startsWith("#")?t:"#"+t:"",p=["post","put","patch","delete"];new Set(p);const l=["get",...p];new Set(l),exports.UNSAFE_getResolveToMatches=function(t,e){let n=function(t){return t.filter(((t,e)=>0===e||t.route.path&&t.route.path.length>0))}(t);return e?n.map(((t,e)=>e===n.length-1?t.pathname:t.pathnameBase)):n.map((t=>t.pathnameBase))},exports.UNSAFE_invariant=r,exports.UNSAFE_warning=function(t,e){if(!t){"undefined"!=typeof console&&console.warn(e);try{throw new Error(e)}catch(t){}}},exports.joinPaths=t=>t.join("/").replace(/\/\/+/g,"/"),exports.parsePath=a,exports.resolvePath=s,exports.resolveTo=function(e,n,i,h){let p;void 0===h&&(h=!1),"string"==typeof e?p=a(e):(p=t({},e),r(!p.pathname||!p.pathname.includes("?"),o("?","pathname","search",p)),r(!p.pathname||!p.pathname.includes("#"),o("#","pathname","hash",p)),r(!p.search||!p.search.includes("#"),o("#","search","hash",p)));let l,c=""===e||""===p.pathname,u=c?"/":p.pathname;if(null==u)l=i;else{let t=n.length-1;if(!h&&u.startsWith("..")){let e=u.split("/");for(;".."===e[0];)e.shift(),t-=1;p.pathname=e.join("/")}l=t>=0?n[t]:"/"}let f=s(p,l),d=u&&"/"!==u&&u.endsWith("/"),m=(c||"."===u)&&i.endsWith("/");return f.pathname.endsWith("/")||!d&&!m||(f.pathname+="/"),f};
|
|
12
|
+
//# sourceMappingURL=router.cjs.js.map
|