@flipdish/portal-library 2.1.5 → 3.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (53) hide show
  1. package/dist/components/Form/FormItemLayout/index.cjs.js +1 -1
  2. package/dist/components/Form/FormItemLayout/index.cjs.js.map +1 -1
  3. package/dist/components/Form/FormItemLayout/index.js +1 -1
  4. package/dist/components/Form/FormItemLayout/index.js.map +1 -1
  5. package/dist/components/GenericTable/index.cjs.js +17 -17
  6. package/dist/components/GenericTable/index.cjs.js.map +1 -1
  7. package/dist/components/GenericTable/index.d.ts +3 -3
  8. package/dist/components/GenericTable/index.js +17 -17
  9. package/dist/components/GenericTable/index.js.map +1 -1
  10. package/dist/components/GenericTableTitle/index.cjs.js +1 -1
  11. package/dist/components/GenericTableTitle/index.cjs.js.map +1 -1
  12. package/dist/components/GenericTableTitle/index.d.ts +4 -5
  13. package/dist/components/GenericTableTitle/index.js +1 -1
  14. package/dist/components/GenericTableTitle/index.js.map +1 -1
  15. package/dist/components/ListItemLinkButton/index.cjs.js +1 -1
  16. package/dist/components/ListItemLinkButton/index.cjs.js.map +1 -1
  17. package/dist/components/ListItemLinkButton/index.d.ts +1 -1
  18. package/dist/components/ListItemLinkButton/index.js +1 -1
  19. package/dist/components/ListItemLinkButton/index.js.map +1 -1
  20. package/dist/components/PageLayout/FullWidthContainer.cjs.js +1 -1
  21. package/dist/components/PageLayout/FullWidthContainer.cjs.js.map +1 -1
  22. package/dist/components/PageLayout/FullWidthContainer.d.ts +2 -2
  23. package/dist/components/PageLayout/FullWidthContainer.js +1 -1
  24. package/dist/components/PageLayout/FullWidthContainer.js.map +1 -1
  25. package/dist/components/PageLayout/GlobalSpacingStyles.cjs.js +1 -1
  26. package/dist/components/PageLayout/GlobalSpacingStyles.cjs.js.map +1 -1
  27. package/dist/components/PageLayout/GlobalSpacingStyles.js +1 -1
  28. package/dist/components/PageLayout/GlobalSpacingStyles.js.map +1 -1
  29. package/dist/components/PageLayout/index.cjs.js +1 -1
  30. package/dist/components/PageLayout/index.cjs.js.map +1 -1
  31. package/dist/components/PageLayout/index.d.ts +4 -4
  32. package/dist/components/PageLayout/index.js +1 -1
  33. package/dist/components/PageLayout/index.js.map +1 -1
  34. package/dist/components/PortalMock/index.cjs.js +22 -22
  35. package/dist/components/PortalMock/index.cjs.js.map +1 -1
  36. package/dist/components/PortalMock/index.d.ts +2 -2
  37. package/dist/components/PortalMock/index.js +22 -22
  38. package/dist/components/PortalMock/index.js.map +1 -1
  39. package/dist/themes/flipdishPublicTheme.cjs.js +1 -1
  40. package/dist/themes/flipdishPublicTheme.cjs.js.map +1 -1
  41. package/dist/themes/flipdishPublicTheme.js +1 -1
  42. package/dist/themes/flipdishPublicTheme.js.map +1 -1
  43. package/dist/themes/tokens/breakpoints/breakpoints.cjs.js +2 -0
  44. package/dist/themes/tokens/breakpoints/breakpoints.cjs.js.map +1 -0
  45. package/dist/themes/tokens/breakpoints/breakpoints.d.ts +20 -0
  46. package/dist/themes/tokens/breakpoints/breakpoints.js +2 -0
  47. package/dist/themes/tokens/breakpoints/breakpoints.js.map +1 -0
  48. package/dist/themes/tokens/spacing/spacing.cjs.js +1 -1
  49. package/dist/themes/tokens/spacing/spacing.cjs.js.map +1 -1
  50. package/dist/themes/tokens/spacing/spacing.d.ts +1 -0
  51. package/dist/themes/tokens/spacing/spacing.js +1 -1
  52. package/dist/themes/tokens/spacing/spacing.js.map +1 -1
  53. package/package.json +7 -7
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../src/components/PortalMock/index.tsx"],"sourcesContent":["import { styled } from '@mui/material/styles';\nimport AppBar from '@mui/material/AppBar';\nimport Box from '@mui/material/Box';\nimport CssBaseline from '@mui/material/CssBaseline';\nimport Drawer from '@mui/material/Drawer';\nimport Typography from '@mui/material/Typography';\n\nconst drawerWidth = 198;\n\nconst StyledHeader = styled('div')(({ theme }) => ({\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n backgroundColor: theme.palette.semantic.background['background-sunken'],\n height: '65px',\n color: theme.palette.semantic.text['text-weak'],\n borderBottom: `2px solid ${theme.palette.semantic.stroke['stroke-weak']}`,\n}));\n\nconst StyledSidebar = styled('div')(({ theme }) => ({\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n backgroundColor: theme.palette.semantic.background['background-sunken'],\n height: '100%',\n color: theme.palette.semantic.text['text-weak'],\n}));\n\nconst StyledAppBar = styled(AppBar)`\n width: ${({ theme }) => (theme.breakpoints.up('sm') ? `calc(100% - ${drawerWidth}px)` : '100%')};\n margin-left: ${({ theme }) => (theme.breakpoints.up('sm') ? `${drawerWidth}px` : '0')};\n box-shadow: none;\n`;\n\nconst StyledDrawer = styled(Drawer)`\n display: ${({ theme }) => (theme.breakpoints.up('sm') ? 'block' : 'none')};\n & .MuiDrawer-paper {\n box-sizing: border-box;\n width: ${drawerWidth}px;\n border-color: ${({ theme }) => theme.palette.semantic.stroke['stroke-weak']};\n border-width: 2px;\n }\n`;\n\nconst StyledNavBox = styled(Box)`\n width: ${({ theme }) => (theme.breakpoints.up('sm') ? `${drawerWidth}px` : '0')};\n flex-shrink: ${({ theme }) => (theme.breakpoints.up('sm') ? '0' : '1')};\n`;\n\nconst StyledMainBox = styled(Box)`\n flex-grow: 1;\n width: ${({ theme }) => (theme.breakpoints.up('sm') ? `calc(100% - ${drawerWidth}px)` : '100%')};\n margin-top: 65px;\n`;\n\nconst StyledBoldTypography = styled(Typography)`\n font-weight: bold;\n`;\n\ntype Props = {\n loadedFromPortal: boolean;\n children: React.ReactNode;\n};\n\nconst PortalMock = ({ children, loadedFromPortal }: Props) => {\n if (loadedFromPortal) {\n return <>{children}</>;\n }\n\n const drawer = (\n <StyledSidebar>\n <StyledBoldTypography>Sidebar</StyledBoldTypography>\n </StyledSidebar>\n );\n\n return (\n <Box sx={{ display: 'flex' }}>\n <CssBaseline />\n <StyledAppBar position=\"fixed\">\n <StyledHeader>\n <StyledBoldTypography>Header</StyledBoldTypography>\n </StyledHeader>\n </StyledAppBar>\n <StyledNavBox as=\"nav\" aria-label=\"mailbox folders\">\n <StyledDrawer variant=\"permanent\" open>\n {drawer}\n </StyledDrawer>\n </StyledNavBox>\n <StyledMainBox as=\"main\">{children}</StyledMainBox>\n </Box>\n );\n};\n\nexport default PortalMock;\n"],"names":["drawerWidth","StyledHeader","styled","theme","display","justifyContent","alignItems","backgroundColor","palette","semantic","background","height","color","text","borderBottom","stroke","StyledSidebar","StyledAppBar","AppBar","breakpoints","up","StyledDrawer","Drawer","StyledNavBox","Box","StyledMainBox","StyledBoldTypography","Typography","PortalMock","children","loadedFromPortal","_jsx","_Fragment","drawer","_jsxs","sx","CssBaseline","position","as","variant","open"],"mappings":"wSAOA,MAAMA,EAAc,IAEdC,EAAeC,EAAO,MAAPA,EAAc,EAAGC,YAAa,CAC/CC,QAAS,OACTC,eAAgB,SAChBC,WAAY,SACZC,gBAAiBJ,EAAMK,QAAQC,SAASC,WAAW,qBACnDC,OAAQ,OACRC,MAAOT,EAAMK,QAAQC,SAASI,KAAK,aACnCC,aAAc,aAAaX,EAAMK,QAAQC,SAASM,OAAO,qBAGvDC,EAAgBd,EAAO,MAAPA,EAAc,EAAGC,YAAa,CAChDC,QAAS,OACTC,eAAgB,SAChBC,WAAY,SACZC,gBAAiBJ,EAAMK,QAAQC,SAASC,WAAW,qBACnDC,OAAQ,OACRC,MAAOT,EAAMK,QAAQC,SAASI,KAAK,iBAGjCI,EAAef,EAAOgB,EAAO;aACtB,EAAGf,WAAaA,EAAMgB,YAAYC,GAAG,MAAQ,qBAAkC;mBACzE,EAAGjB,WAAaA,EAAMgB,YAAYC,GAAG,MAAQ,QAAqB;;EAI/EC,EAAenB,EAAOoB,EAAO;eACpB,EAAGnB,WAAaA,EAAMgB,YAAYC,GAAG,MAAQ,QAAU;;;iBAGrDpB;wBACO,EAAGG,WAAYA,EAAMK,QAAQC,SAASM,OAAO;;;EAK/DQ,EAAerB,EAAOsB,EAAI;aACnB,EAAGrB,WAAaA,EAAMgB,YAAYC,GAAG,MAAQ,QAAqB;mBAC5D,EAAGjB,WAAaA,EAAMgB,YAAYC,GAAG,MAAQ,IAAM;EAGhEK,EAAgBvB,EAAOsB,EAAI;;aAEpB,EAAGrB,WAAaA,EAAMgB,YAAYC,GAAG,MAAQ,qBAAkC;;EAItFM,EAAuBxB,EAAOyB,EAAW;;EASzCC,EAAa,EAAGC,WAAUC,uBAC5B,GAAIA,EACA,OAAOC,EAAAC,EAAA,CAAAH,SAAGA,IAGd,MAAMI,EACFF,EAACf,EACG,CAAAa,SAAAE,EAACL,EAAoB,CAAAG,SAAA,cAI7B,OACIK,EAACV,EAAG,CAACW,GAAI,CAAE/B,QAAS,QAAQyB,SAAA,CACxBE,EAACK,EAAW,CAAA,GACZL,EAACd,EAAY,CAACoB,SAAS,QAAOR,SAC1BE,EAAC9B,EACG,CAAA4B,SAAAE,EAACL,EAAoB,CAAAG,SAAA,eAG7BE,EAACR,EAAa,CAAAe,GAAG,MAAiB,aAAA,kBAC9BT,SAAAE,EAACV,EAAY,CAACkB,QAAQ,YAAYC,MAC7B,EAAAX,SAAAI,MAGTF,EAACN,EAAc,CAAAa,GAAG,OAAQT,SAAAA,MACxB"}
1
+ {"version":3,"file":"index.js","sources":["../../../src/components/PortalMock/index.tsx"],"sourcesContent":["import AppBar from '@mui/material/AppBar';\nimport Box from '@mui/material/Box';\nimport CssBaseline from '@mui/material/CssBaseline';\nimport Drawer from '@mui/material/Drawer';\nimport { styled } from '@mui/material/styles';\nimport Typography from '@mui/material/Typography';\n\nconst drawerWidth = 198;\n\nconst StyledHeader = styled('div')(({ theme }) => ({\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n backgroundColor: theme.palette.semantic.background['background-sunken'],\n height: '65px',\n color: theme.palette.semantic.text['text-weak'],\n borderBottom: `2px solid ${theme.palette.semantic.stroke['stroke-weak']}`,\n}));\n\nconst StyledSidebar = styled('div')(({ theme }) => ({\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n backgroundColor: theme.palette.semantic.background['background-sunken'],\n height: '100%',\n color: theme.palette.semantic.text['text-weak'],\n}));\n\nconst StyledAppBar = styled(AppBar)`\n width: ${({ theme }) => (theme.breakpoints.up('tablet') ? `calc(100% - ${drawerWidth}px)` : '100%')};\n margin-left: ${({ theme }) => (theme.breakpoints.up('tablet') ? `${drawerWidth}px` : '0')};\n box-shadow: none;\n`;\n\nconst StyledDrawer = styled(Drawer)`\n display: ${({ theme }) => (theme.breakpoints.up('tablet') ? 'block' : 'none')};\n & .MuiDrawer-paper {\n box-sizing: border-box;\n width: ${drawerWidth}px;\n border-color: ${({ theme }) => theme.palette.semantic.stroke['stroke-weak']};\n border-width: 2px;\n }\n`;\n\nconst StyledNavBox = styled(Box)`\n width: ${({ theme }) => (theme.breakpoints.up('tablet') ? `${drawerWidth}px` : '0')};\n flex-shrink: ${({ theme }) => (theme.breakpoints.up('tablet') ? '0' : '1')};\n`;\n\nconst StyledMainBox = styled(Box)`\n flex-grow: 1;\n width: ${({ theme }) => (theme.breakpoints.up('tablet') ? `calc(100% - ${drawerWidth}px)` : '100%')};\n margin-top: 65px;\n`;\n\nconst StyledBoldTypography = styled(Typography)`\n font-weight: bold;\n`;\n\ninterface Props {\n loadedFromPortal: boolean;\n children: React.ReactNode;\n}\n\nconst PortalMock = ({ children, loadedFromPortal }: Props) => {\n if (loadedFromPortal) {\n /* eslint-disable-next-line react/jsx-no-useless-fragment */\n return <>{children}</>;\n }\n\n const drawer = (\n <StyledSidebar>\n <StyledBoldTypography>Sidebar</StyledBoldTypography>\n </StyledSidebar>\n );\n\n return (\n <Box sx={{ display: 'flex' }}>\n <CssBaseline />\n <StyledAppBar position=\"fixed\">\n <StyledHeader>\n <StyledBoldTypography>Header</StyledBoldTypography>\n </StyledHeader>\n </StyledAppBar>\n <StyledNavBox aria-label=\"mailbox folders\" as=\"nav\">\n <StyledDrawer open variant=\"permanent\">\n {drawer}\n </StyledDrawer>\n </StyledNavBox>\n <StyledMainBox as=\"main\">{children}</StyledMainBox>\n </Box>\n );\n};\n\nexport default PortalMock;\n"],"names":["drawerWidth","StyledHeader","styled","theme","display","justifyContent","alignItems","backgroundColor","palette","semantic","background","height","color","text","borderBottom","stroke","StyledSidebar","StyledAppBar","AppBar","breakpoints","up","StyledDrawer","Drawer","StyledNavBox","Box","StyledMainBox","StyledBoldTypography","Typography","PortalMock","children","loadedFromPortal","_jsx","_Fragment","drawer","_jsxs","sx","CssBaseline","position","as","open","variant"],"mappings":"wSAOA,MAAMA,EAAc,IAEdC,EAAeC,EAAO,MAAPA,EAAc,EAAGC,YAAa,CACjDC,QAAS,OACTC,eAAgB,SAChBC,WAAY,SACZC,gBAAiBJ,EAAMK,QAAQC,SAASC,WAAW,qBACnDC,OAAQ,OACRC,MAAOT,EAAMK,QAAQC,SAASI,KAAK,aACnCC,aAAc,aAAaX,EAAMK,QAAQC,SAASM,OAAO,qBAGrDC,EAAgBd,EAAO,MAAPA,EAAc,EAAGC,YAAa,CAClDC,QAAS,OACTC,eAAgB,SAChBC,WAAY,SACZC,gBAAiBJ,EAAMK,QAAQC,SAASC,WAAW,qBACnDC,OAAQ,OACRC,MAAOT,EAAMK,QAAQC,SAASI,KAAK,iBAG/BI,EAAef,EAAOgB,EAAO;WACxB,EAAGf,WAAaA,EAAMgB,YAAYC,GAAG,UAAY,qBAAkC;iBAC7E,EAAGjB,WAAaA,EAAMgB,YAAYC,GAAG,UAAY,QAAqB;;EAIjFC,EAAenB,EAAOoB,EAAO;aACtB,EAAGnB,WAAaA,EAAMgB,YAAYC,GAAG,UAAY,QAAU;;;aAG3DpB;oBACO,EAAGG,WAAYA,EAAMK,QAAQC,SAASM,OAAO;;;EAK3DQ,EAAerB,EAAOsB,EAAI;WACrB,EAAGrB,WAAaA,EAAMgB,YAAYC,GAAG,UAAY,QAAqB;iBAChE,EAAGjB,WAAaA,EAAMgB,YAAYC,GAAG,UAAY,IAAM;EAGlEK,EAAgBvB,EAAOsB,EAAI;;WAEtB,EAAGrB,WAAaA,EAAMgB,YAAYC,GAAG,UAAY,qBAAkC;;EAIxFM,EAAuBxB,EAAOyB,EAAW;;EASzCC,EAAa,EAAGC,WAAUC,uBAC9B,GAAIA,EAEF,OAAOC,EAAAC,EAAA,CAAAH,SAAGA,IAGZ,MAAMI,EACJF,EAACf,EACC,CAAAa,SAAAE,EAACL,EAAoB,CAAAG,SAAA,cAIzB,OACEK,EAACV,EAAG,CAACW,GAAI,CAAE/B,QAAS,QAAQyB,SAAA,CAC1BE,EAACK,EAAW,CAAA,GACZL,EAACd,EAAY,CAACoB,SAAS,QAAOR,SAC5BE,EAAC9B,EACC,CAAA4B,SAAAE,EAACL,EAAoB,CAAAG,SAAA,eAGzBE,EAACR,EAAwB,CAAA,aAAA,kBAAkBe,GAAG,MAC5CT,SAAAE,EAACV,EAAY,CAACkB,MAAI,EAACC,QAAQ,YACxBX,SAAAI,MAGLF,EAACN,EAAc,CAAAa,GAAG,OAAQT,SAAAA,MACtB"}
@@ -1,2 +1,2 @@
1
- "use strict";var e=require("@mui/material/styles/createTheme"),r=require("../icons/Cancel/index.cjs.js");require("./tokens/colours/primitives.cjs.js");var o=require("./tokens/colours/semantic.cjs.js"),t=require("./tokens/radius/radius.cjs.js"),i=require("./tokens/typography/variant-mapping.cjs.js"),s=require("./typography.cjs.js");const a=a=>{const p=e({typography:s.typography,palette:"light"===a?o.lightColours:o.darkColours,radius:t.radius});return Object.keys(s.typography).forEach((e=>{const r=e.split(/(?=[A-Z])/)[0];p.typography[e]={...p.typography[e],[p.breakpoints.down("md")]:{...s.getMobileTextStyle(r)}}})),e(p,{shape:{borderRadius:"4px"},components:{MuiAlert:{defaultProps:{components:{CloseIcon:r}},styleOverrides:{root:{borderRadius:"8px",padding:"24px"},icon:{marginRight:"12px",padding:0},action:{padding:0,"& button":{marginTop:"-5px"}},message:{padding:0}}},MuiButton:{styleOverrides:{root:{padding:"12px 24px",textTransform:"none"}}},MuiCard:{styleOverrides:{root:{boxShadow:"none",borderWidth:"1px",borderStyle:"solid",borderColor:p.palette.divider}}},MuiChip:{styleOverrides:{root:{fontWeight:"bold",paddingLeft:"6px",paddingRight:"6px"}}},MuiListItemButton:{styleOverrides:{root:{"&:hover":{backgroundColor:p.palette.semantic.fill["fill-primary-weak"]},"&:not(:last-child)":{borderBottom:`1px solid ${p.palette.semantic.stroke["stroke-weak"]}`}}}},MuiTableRow:{styleOverrides:{root:{"&.MuiTableRow-hover:hover":{backgroundColor:p.palette.semantic.fill["fill-secondary"],cursor:"pointer"}}}},MuiTypography:{defaultProps:{variantMapping:i.typographyVariantMapping}}}})},p=a("light"),n=a("dark");exports.darkTheme=n,exports.lightTheme=p;
1
+ "use strict";var e=require("@mui/material/styles/createTheme"),r=require("../icons/Cancel/index.cjs.js"),t=require("./tokens/breakpoints/breakpoints.cjs.js");require("./tokens/colours/primitives.cjs.js");var o=require("./tokens/colours/semantic.cjs.js"),i=require("./tokens/radius/radius.cjs.js"),s=require("./tokens/typography/variant-mapping.cjs.js"),a=require("./typography.cjs.js");const p=p=>{const n=e({typography:a.typography,palette:"light"===p?o.lightColours:o.darkColours,radius:i.radius,breakpoints:{values:t.breakpointValues}});return Object.keys(a.typography).forEach((e=>{const r=e.split(/(?=[A-Z])/)[0];n.typography[e]={...n.typography[e],[n.breakpoints.down("tablet")]:{...a.getMobileTextStyle(r)}}})),e(n,{shape:{borderRadius:"4px"},components:{MuiAlert:{defaultProps:{components:{CloseIcon:r}},styleOverrides:{root:{borderRadius:"8px",padding:"24px"},icon:{marginRight:"12px",padding:0},action:{padding:0,"& button":{marginTop:"-5px"}},message:{padding:0}}},MuiButton:{styleOverrides:{root:{padding:"12px 24px",textTransform:"none"}}},MuiCard:{styleOverrides:{root:{boxShadow:"none",borderWidth:"1px",borderStyle:"solid",borderColor:n.palette.divider}}},MuiChip:{styleOverrides:{root:{fontWeight:"bold",paddingLeft:"6px",paddingRight:"6px"}}},MuiListItemButton:{styleOverrides:{root:{"&:hover":{backgroundColor:n.palette.semantic.fill["fill-primary-weak"]},"&:not(:last-child)":{borderBottom:`1px solid ${n.palette.semantic.stroke["stroke-weak"]}`}}}},MuiTableRow:{styleOverrides:{root:{"&.MuiTableRow-hover:hover":{backgroundColor:n.palette.semantic.fill["fill-secondary"],cursor:"pointer"}}}},MuiTypography:{defaultProps:{variantMapping:s.typographyVariantMapping}}}})},n=p("light"),d=p("dark");exports.darkTheme=d,exports.lightTheme=n;
2
2
  //# sourceMappingURL=flipdishPublicTheme.cjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"flipdishPublicTheme.cjs.js","sources":["../../src/themes/flipdishPublicTheme.ts"],"sourcesContent":["import createTheme, { type Theme, type ThemeOptions } from '@mui/material/styles/createTheme';\n\nimport CancelIcon from '../icons/Cancel';\nimport { darkColours, lightColours } from './tokens/colours';\nimport { radius } from './tokens/radius/radius';\nimport type { fontSize } from './tokens/typography/font-size';\nimport { typographyVariantMapping } from './tokens/typography/variant-mapping';\nimport { getMobileTextStyle, typography } from './typography';\n\nconst createFlipdishThemeFactory = (mode: 'dark' | 'light'): Theme => {\n const baseTheme = createTheme({\n typography,\n palette: mode === 'light' ? lightColours : darkColours,\n radius,\n });\n\n /* \n Add mobile text styles to typography\n Has to be done using media queries, otherwise it isn't responsive :(\n https://mui.com/material-ui/customization/typography/#responsive-font-sizes \n */\n Object.keys(typography).forEach((key) => {\n // only key before the suffix split by capital letter (h1Strong -> h1)\n const keyWithoutVariantSuffix = key.split(/(?=[A-Z])/)[0];\n baseTheme.typography[key] = {\n ...baseTheme.typography[key],\n [baseTheme.breakpoints.down('md')]: {\n ...getMobileTextStyle(keyWithoutVariantSuffix as keyof (typeof fontSize)['mobile']),\n },\n };\n });\n\n // Create final theme with component overrides and additional configurations\n return createTheme(baseTheme as ThemeOptions, {\n shape: {\n borderRadius: '4px',\n },\n components: {\n MuiAlert: {\n defaultProps: {\n components: {\n CloseIcon: CancelIcon,\n },\n },\n styleOverrides: {\n root: {\n // TODO: Replace with borderRadius from tokens when implemented\n borderRadius: '8px',\n // TODO: Replace with spacing from tokens when implemented\n padding: '24px',\n },\n icon: {\n // TODO: Replace with spacing from tokens when implemented\n marginRight: '12px',\n padding: 0,\n },\n action: {\n padding: 0,\n '& button': {\n marginTop: '-5px',\n },\n },\n message: {\n padding: 0,\n },\n },\n },\n MuiButton: {\n styleOverrides: {\n root: {\n padding: '12px 24px',\n textTransform: 'none',\n },\n },\n },\n MuiCard: {\n styleOverrides: {\n root: {\n boxShadow: 'none',\n borderWidth: '1px',\n borderStyle: 'solid',\n borderColor: baseTheme.palette.divider,\n },\n },\n },\n MuiChip: {\n styleOverrides: {\n root: {\n fontWeight: 'bold',\n paddingLeft: '6px',\n paddingRight: '6px',\n },\n },\n },\n MuiListItemButton: {\n styleOverrides: {\n root: {\n '&:hover': {\n backgroundColor: baseTheme.palette.semantic.fill['fill-primary-weak'],\n },\n '&:not(:last-child)': {\n borderBottom: `1px solid ${baseTheme.palette.semantic.stroke['stroke-weak']}`,\n },\n },\n },\n },\n MuiTableRow: {\n styleOverrides: {\n root: {\n '&.MuiTableRow-hover:hover': {\n backgroundColor: baseTheme.palette.semantic.fill['fill-secondary'],\n cursor: 'pointer',\n },\n },\n },\n },\n MuiTypography: {\n defaultProps: {\n variantMapping: typographyVariantMapping,\n },\n },\n },\n });\n};\n\nexport const lightTheme = createFlipdishThemeFactory('light');\nexport const darkTheme = createFlipdishThemeFactory('dark');\n"],"names":["createFlipdishThemeFactory","mode","baseTheme","createTheme","typography","palette","lightColours","darkColours","radius","Object","keys","forEach","key","keyWithoutVariantSuffix","split","breakpoints","down","getMobileTextStyle","shape","borderRadius","components","MuiAlert","defaultProps","CloseIcon","CancelIcon","styleOverrides","root","padding","icon","marginRight","action","marginTop","message","MuiButton","textTransform","MuiCard","boxShadow","borderWidth","borderStyle","borderColor","divider","MuiChip","fontWeight","paddingLeft","paddingRight","MuiListItemButton","backgroundColor","semantic","fill","borderBottom","stroke","MuiTableRow","cursor","MuiTypography","variantMapping","typographyVariantMapping","lightTheme","darkTheme"],"mappings":"6UASA,MAAMA,EAA8BC,IAClC,MAAMC,EAAYC,EAAY,YAC5BC,EAAUA,WACVC,QAAkB,UAATJ,EAAmBK,EAAAA,aAAeC,EAAWA,mBACtDC,EAAMA,SAoBR,OAZAC,OAAOC,KAAKN,EAAAA,YAAYO,SAASC,IAE/B,MAAMC,EAA0BD,EAAIE,MAAM,aAAa,GACvDZ,EAAUE,WAAWQ,GAAO,IACvBV,EAAUE,WAAWQ,GACxB,CAACV,EAAUa,YAAYC,KAAK,OAAQ,IAC/BC,EAAAA,mBAAmBJ,IAEzB,IAIIV,EAAYD,EAA2B,CAC5CgB,MAAO,CACLC,aAAc,OAEhBC,WAAY,CACVC,SAAU,CACRC,aAAc,CACZF,WAAY,CACVG,UAAWC,IAGfC,eAAgB,CACdC,KAAM,CAEJP,aAAc,MAEdQ,QAAS,QAEXC,KAAM,CAEJC,YAAa,OACbF,QAAS,GAEXG,OAAQ,CACNH,QAAS,EACT,WAAY,CACVI,UAAW,SAGfC,QAAS,CACPL,QAAS,KAIfM,UAAW,CACTR,eAAgB,CACdC,KAAM,CACJC,QAAS,YACTO,cAAe,UAIrBC,QAAS,CACPV,eAAgB,CACdC,KAAM,CACJU,UAAW,OACXC,YAAa,MACbC,YAAa,QACbC,YAAarC,EAAUG,QAAQmC,WAIrCC,QAAS,CACPhB,eAAgB,CACdC,KAAM,CACJgB,WAAY,OACZC,YAAa,MACbC,aAAc,SAIpBC,kBAAmB,CACjBpB,eAAgB,CACdC,KAAM,CACJ,UAAW,CACToB,gBAAiB5C,EAAUG,QAAQ0C,SAASC,KAAK,sBAEnD,qBAAsB,CACpBC,aAAc,aAAa/C,EAAUG,QAAQ0C,SAASG,OAAO,qBAKrEC,YAAa,CACX1B,eAAgB,CACdC,KAAM,CACJ,4BAA6B,CAC3BoB,gBAAiB5C,EAAUG,QAAQ0C,SAASC,KAAK,kBACjDI,OAAQ,cAKhBC,cAAe,CACb/B,aAAc,CACZgC,eAAgBC,EAAwBA,6BAI9C,EAGSC,EAAaxD,EAA2B,SACxCyD,EAAYzD,EAA2B"}
1
+ {"version":3,"file":"flipdishPublicTheme.cjs.js","sources":["../../src/themes/flipdishPublicTheme.ts"],"sourcesContent":["import createTheme, { type Theme, type ThemeOptions } from '@mui/material/styles/createTheme';\n\nimport CancelIcon from '../icons/Cancel';\nimport { breakpointValues } from './tokens/breakpoints/breakpoints';\nimport { darkColours, lightColours } from './tokens/colours';\nimport { radius } from './tokens/radius/radius';\nimport type { fontSize } from './tokens/typography/font-size';\nimport { typographyVariantMapping } from './tokens/typography/variant-mapping';\nimport { getMobileTextStyle, typography } from './typography';\n\nconst createFlipdishThemeFactory = (mode: 'dark' | 'light'): Theme => {\n const baseTheme = createTheme({\n typography,\n palette: mode === 'light' ? lightColours : darkColours,\n radius,\n breakpoints: {\n values: breakpointValues,\n },\n });\n\n /* \n Add mobile text styles to typography\n Has to be done using media queries, otherwise it isn't responsive :(\n https://mui.com/material-ui/customization/typography/#responsive-font-sizes \n */\n Object.keys(typography).forEach((key) => {\n // only key before the suffix split by capital letter (h1Strong -> h1)\n const keyWithoutVariantSuffix = key.split(/(?=[A-Z])/)[0];\n baseTheme.typography[key] = {\n ...baseTheme.typography[key],\n [baseTheme.breakpoints.down('tablet')]: {\n ...getMobileTextStyle(keyWithoutVariantSuffix as keyof (typeof fontSize)['mobile']),\n },\n };\n });\n\n // Create final theme with component overrides and additional configurations\n return createTheme(baseTheme as ThemeOptions, {\n shape: {\n borderRadius: '4px',\n },\n components: {\n MuiAlert: {\n defaultProps: {\n components: {\n CloseIcon: CancelIcon,\n },\n },\n styleOverrides: {\n root: {\n // TODO: Replace with borderRadius from tokens when implemented\n borderRadius: '8px',\n // TODO: Replace with spacing from tokens when implemented\n padding: '24px',\n },\n icon: {\n // TODO: Replace with spacing from tokens when implemented\n marginRight: '12px',\n padding: 0,\n },\n action: {\n padding: 0,\n '& button': {\n marginTop: '-5px',\n },\n },\n message: {\n padding: 0,\n },\n },\n },\n MuiButton: {\n styleOverrides: {\n root: {\n padding: '12px 24px',\n textTransform: 'none',\n },\n },\n },\n MuiCard: {\n styleOverrides: {\n root: {\n boxShadow: 'none',\n borderWidth: '1px',\n borderStyle: 'solid',\n borderColor: baseTheme.palette.divider,\n },\n },\n },\n MuiChip: {\n styleOverrides: {\n root: {\n fontWeight: 'bold',\n paddingLeft: '6px',\n paddingRight: '6px',\n },\n },\n },\n MuiListItemButton: {\n styleOverrides: {\n root: {\n '&:hover': {\n backgroundColor: baseTheme.palette.semantic.fill['fill-primary-weak'],\n },\n '&:not(:last-child)': {\n borderBottom: `1px solid ${baseTheme.palette.semantic.stroke['stroke-weak']}`,\n },\n },\n },\n },\n MuiTableRow: {\n styleOverrides: {\n root: {\n '&.MuiTableRow-hover:hover': {\n backgroundColor: baseTheme.palette.semantic.fill['fill-secondary'],\n cursor: 'pointer',\n },\n },\n },\n },\n MuiTypography: {\n defaultProps: {\n variantMapping: typographyVariantMapping,\n },\n },\n },\n });\n};\n\nexport const lightTheme = createFlipdishThemeFactory('light');\nexport const darkTheme = createFlipdishThemeFactory('dark');\n"],"names":["createFlipdishThemeFactory","mode","baseTheme","createTheme","typography","palette","lightColours","darkColours","radius","breakpoints","values","breakpointValues","Object","keys","forEach","key","keyWithoutVariantSuffix","split","down","getMobileTextStyle","shape","borderRadius","components","MuiAlert","defaultProps","CloseIcon","CancelIcon","styleOverrides","root","padding","icon","marginRight","action","marginTop","message","MuiButton","textTransform","MuiCard","boxShadow","borderWidth","borderStyle","borderColor","divider","MuiChip","fontWeight","paddingLeft","paddingRight","MuiListItemButton","backgroundColor","semantic","fill","borderBottom","stroke","MuiTableRow","cursor","MuiTypography","variantMapping","typographyVariantMapping","lightTheme","darkTheme"],"mappings":"kYAUA,MAAMA,EAA8BC,IAClC,MAAMC,EAAYC,EAAY,YAC5BC,EAAUA,WACVC,QAAkB,UAATJ,EAAmBK,EAAAA,aAAeC,EAAWA,mBACtDC,EAAMA,OACNC,YAAa,CACXC,OAAQC,EAAgBA,oBAqB5B,OAZAC,OAAOC,KAAKT,EAAAA,YAAYU,SAASC,IAE/B,MAAMC,EAA0BD,EAAIE,MAAM,aAAa,GACvDf,EAAUE,WAAWW,GAAO,IACvBb,EAAUE,WAAWW,GACxB,CAACb,EAAUO,YAAYS,KAAK,WAAY,IACnCC,EAAAA,mBAAmBH,IAEzB,IAIIb,EAAYD,EAA2B,CAC5CkB,MAAO,CACLC,aAAc,OAEhBC,WAAY,CACVC,SAAU,CACRC,aAAc,CACZF,WAAY,CACVG,UAAWC,IAGfC,eAAgB,CACdC,KAAM,CAEJP,aAAc,MAEdQ,QAAS,QAEXC,KAAM,CAEJC,YAAa,OACbF,QAAS,GAEXG,OAAQ,CACNH,QAAS,EACT,WAAY,CACVI,UAAW,SAGfC,QAAS,CACPL,QAAS,KAIfM,UAAW,CACTR,eAAgB,CACdC,KAAM,CACJC,QAAS,YACTO,cAAe,UAIrBC,QAAS,CACPV,eAAgB,CACdC,KAAM,CACJU,UAAW,OACXC,YAAa,MACbC,YAAa,QACbC,YAAavC,EAAUG,QAAQqC,WAIrCC,QAAS,CACPhB,eAAgB,CACdC,KAAM,CACJgB,WAAY,OACZC,YAAa,MACbC,aAAc,SAIpBC,kBAAmB,CACjBpB,eAAgB,CACdC,KAAM,CACJ,UAAW,CACToB,gBAAiB9C,EAAUG,QAAQ4C,SAASC,KAAK,sBAEnD,qBAAsB,CACpBC,aAAc,aAAajD,EAAUG,QAAQ4C,SAASG,OAAO,qBAKrEC,YAAa,CACX1B,eAAgB,CACdC,KAAM,CACJ,4BAA6B,CAC3BoB,gBAAiB9C,EAAUG,QAAQ4C,SAASC,KAAK,kBACjDI,OAAQ,cAKhBC,cAAe,CACb/B,aAAc,CACZgC,eAAgBC,EAAwBA,6BAI9C,EAGSC,EAAa1D,EAA2B,SACxC2D,EAAY3D,EAA2B"}
@@ -1,2 +1,2 @@
1
- import o from"@mui/material/styles/createTheme";import r from"../icons/Cancel/index.js";import"./tokens/colours/primitives.js";import{lightColours as t,darkColours as e}from"./tokens/colours/semantic.js";import{radius as i}from"./tokens/radius/radius.js";import{typographyVariantMapping as s}from"./tokens/typography/variant-mapping.js";import{typography as a,getMobileTextStyle as p}from"./typography.js";const n=n=>{const d=o({typography:a,palette:"light"===n?t:e,radius:i});return Object.keys(a).forEach((o=>{const r=o.split(/(?=[A-Z])/)[0];d.typography[o]={...d.typography[o],[d.breakpoints.down("md")]:{...p(r)}}})),o(d,{shape:{borderRadius:"4px"},components:{MuiAlert:{defaultProps:{components:{CloseIcon:r}},styleOverrides:{root:{borderRadius:"8px",padding:"24px"},icon:{marginRight:"12px",padding:0},action:{padding:0,"& button":{marginTop:"-5px"}},message:{padding:0}}},MuiButton:{styleOverrides:{root:{padding:"12px 24px",textTransform:"none"}}},MuiCard:{styleOverrides:{root:{boxShadow:"none",borderWidth:"1px",borderStyle:"solid",borderColor:d.palette.divider}}},MuiChip:{styleOverrides:{root:{fontWeight:"bold",paddingLeft:"6px",paddingRight:"6px"}}},MuiListItemButton:{styleOverrides:{root:{"&:hover":{backgroundColor:d.palette.semantic.fill["fill-primary-weak"]},"&:not(:last-child)":{borderBottom:`1px solid ${d.palette.semantic.stroke["stroke-weak"]}`}}}},MuiTableRow:{styleOverrides:{root:{"&.MuiTableRow-hover:hover":{backgroundColor:d.palette.semantic.fill["fill-secondary"],cursor:"pointer"}}}},MuiTypography:{defaultProps:{variantMapping:s}}}})},d=n("light"),l=n("dark");export{l as darkTheme,d as lightTheme};
1
+ import o from"@mui/material/styles/createTheme";import r from"../icons/Cancel/index.js";import{breakpointValues as t}from"./tokens/breakpoints/breakpoints.js";import"./tokens/colours/primitives.js";import{lightColours as e,darkColours as i}from"./tokens/colours/semantic.js";import{radius as s}from"./tokens/radius/radius.js";import{typographyVariantMapping as a}from"./tokens/typography/variant-mapping.js";import{typography as p,getMobileTextStyle as n}from"./typography.js";const d=d=>{const l=o({typography:p,palette:"light"===d?e:i,radius:s,breakpoints:{values:t}});return Object.keys(p).forEach((o=>{const r=o.split(/(?=[A-Z])/)[0];l.typography[o]={...l.typography[o],[l.breakpoints.down("tablet")]:{...n(r)}}})),o(l,{shape:{borderRadius:"4px"},components:{MuiAlert:{defaultProps:{components:{CloseIcon:r}},styleOverrides:{root:{borderRadius:"8px",padding:"24px"},icon:{marginRight:"12px",padding:0},action:{padding:0,"& button":{marginTop:"-5px"}},message:{padding:0}}},MuiButton:{styleOverrides:{root:{padding:"12px 24px",textTransform:"none"}}},MuiCard:{styleOverrides:{root:{boxShadow:"none",borderWidth:"1px",borderStyle:"solid",borderColor:l.palette.divider}}},MuiChip:{styleOverrides:{root:{fontWeight:"bold",paddingLeft:"6px",paddingRight:"6px"}}},MuiListItemButton:{styleOverrides:{root:{"&:hover":{backgroundColor:l.palette.semantic.fill["fill-primary-weak"]},"&:not(:last-child)":{borderBottom:`1px solid ${l.palette.semantic.stroke["stroke-weak"]}`}}}},MuiTableRow:{styleOverrides:{root:{"&.MuiTableRow-hover:hover":{backgroundColor:l.palette.semantic.fill["fill-secondary"],cursor:"pointer"}}}},MuiTypography:{defaultProps:{variantMapping:a}}}})},l=d("light"),m=d("dark");export{m as darkTheme,l as lightTheme};
2
2
  //# sourceMappingURL=flipdishPublicTheme.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"flipdishPublicTheme.js","sources":["../../src/themes/flipdishPublicTheme.ts"],"sourcesContent":["import createTheme, { type Theme, type ThemeOptions } from '@mui/material/styles/createTheme';\n\nimport CancelIcon from '../icons/Cancel';\nimport { darkColours, lightColours } from './tokens/colours';\nimport { radius } from './tokens/radius/radius';\nimport type { fontSize } from './tokens/typography/font-size';\nimport { typographyVariantMapping } from './tokens/typography/variant-mapping';\nimport { getMobileTextStyle, typography } from './typography';\n\nconst createFlipdishThemeFactory = (mode: 'dark' | 'light'): Theme => {\n const baseTheme = createTheme({\n typography,\n palette: mode === 'light' ? lightColours : darkColours,\n radius,\n });\n\n /* \n Add mobile text styles to typography\n Has to be done using media queries, otherwise it isn't responsive :(\n https://mui.com/material-ui/customization/typography/#responsive-font-sizes \n */\n Object.keys(typography).forEach((key) => {\n // only key before the suffix split by capital letter (h1Strong -> h1)\n const keyWithoutVariantSuffix = key.split(/(?=[A-Z])/)[0];\n baseTheme.typography[key] = {\n ...baseTheme.typography[key],\n [baseTheme.breakpoints.down('md')]: {\n ...getMobileTextStyle(keyWithoutVariantSuffix as keyof (typeof fontSize)['mobile']),\n },\n };\n });\n\n // Create final theme with component overrides and additional configurations\n return createTheme(baseTheme as ThemeOptions, {\n shape: {\n borderRadius: '4px',\n },\n components: {\n MuiAlert: {\n defaultProps: {\n components: {\n CloseIcon: CancelIcon,\n },\n },\n styleOverrides: {\n root: {\n // TODO: Replace with borderRadius from tokens when implemented\n borderRadius: '8px',\n // TODO: Replace with spacing from tokens when implemented\n padding: '24px',\n },\n icon: {\n // TODO: Replace with spacing from tokens when implemented\n marginRight: '12px',\n padding: 0,\n },\n action: {\n padding: 0,\n '& button': {\n marginTop: '-5px',\n },\n },\n message: {\n padding: 0,\n },\n },\n },\n MuiButton: {\n styleOverrides: {\n root: {\n padding: '12px 24px',\n textTransform: 'none',\n },\n },\n },\n MuiCard: {\n styleOverrides: {\n root: {\n boxShadow: 'none',\n borderWidth: '1px',\n borderStyle: 'solid',\n borderColor: baseTheme.palette.divider,\n },\n },\n },\n MuiChip: {\n styleOverrides: {\n root: {\n fontWeight: 'bold',\n paddingLeft: '6px',\n paddingRight: '6px',\n },\n },\n },\n MuiListItemButton: {\n styleOverrides: {\n root: {\n '&:hover': {\n backgroundColor: baseTheme.palette.semantic.fill['fill-primary-weak'],\n },\n '&:not(:last-child)': {\n borderBottom: `1px solid ${baseTheme.palette.semantic.stroke['stroke-weak']}`,\n },\n },\n },\n },\n MuiTableRow: {\n styleOverrides: {\n root: {\n '&.MuiTableRow-hover:hover': {\n backgroundColor: baseTheme.palette.semantic.fill['fill-secondary'],\n cursor: 'pointer',\n },\n },\n },\n },\n MuiTypography: {\n defaultProps: {\n variantMapping: typographyVariantMapping,\n },\n },\n },\n });\n};\n\nexport const lightTheme = createFlipdishThemeFactory('light');\nexport const darkTheme = createFlipdishThemeFactory('dark');\n"],"names":["createFlipdishThemeFactory","mode","baseTheme","createTheme","typography","palette","lightColours","darkColours","radius","Object","keys","forEach","key","keyWithoutVariantSuffix","split","breakpoints","down","getMobileTextStyle","shape","borderRadius","components","MuiAlert","defaultProps","CloseIcon","CancelIcon","styleOverrides","root","padding","icon","marginRight","action","marginTop","message","MuiButton","textTransform","MuiCard","boxShadow","borderWidth","borderStyle","borderColor","divider","MuiChip","fontWeight","paddingLeft","paddingRight","MuiListItemButton","backgroundColor","semantic","fill","borderBottom","stroke","MuiTableRow","cursor","MuiTypography","variantMapping","typographyVariantMapping","lightTheme","darkTheme"],"mappings":"sZASA,MAAMA,EAA8BC,IAClC,MAAMC,EAAYC,EAAY,CAC5BC,aACAC,QAAkB,UAATJ,EAAmBK,EAAeC,EAC3CC,WAoBF,OAZAC,OAAOC,KAAKN,GAAYO,SAASC,IAE/B,MAAMC,EAA0BD,EAAIE,MAAM,aAAa,GACvDZ,EAAUE,WAAWQ,GAAO,IACvBV,EAAUE,WAAWQ,GACxB,CAACV,EAAUa,YAAYC,KAAK,OAAQ,IAC/BC,EAAmBJ,IAEzB,IAIIV,EAAYD,EAA2B,CAC5CgB,MAAO,CACLC,aAAc,OAEhBC,WAAY,CACVC,SAAU,CACRC,aAAc,CACZF,WAAY,CACVG,UAAWC,IAGfC,eAAgB,CACdC,KAAM,CAEJP,aAAc,MAEdQ,QAAS,QAEXC,KAAM,CAEJC,YAAa,OACbF,QAAS,GAEXG,OAAQ,CACNH,QAAS,EACT,WAAY,CACVI,UAAW,SAGfC,QAAS,CACPL,QAAS,KAIfM,UAAW,CACTR,eAAgB,CACdC,KAAM,CACJC,QAAS,YACTO,cAAe,UAIrBC,QAAS,CACPV,eAAgB,CACdC,KAAM,CACJU,UAAW,OACXC,YAAa,MACbC,YAAa,QACbC,YAAarC,EAAUG,QAAQmC,WAIrCC,QAAS,CACPhB,eAAgB,CACdC,KAAM,CACJgB,WAAY,OACZC,YAAa,MACbC,aAAc,SAIpBC,kBAAmB,CACjBpB,eAAgB,CACdC,KAAM,CACJ,UAAW,CACToB,gBAAiB5C,EAAUG,QAAQ0C,SAASC,KAAK,sBAEnD,qBAAsB,CACpBC,aAAc,aAAa/C,EAAUG,QAAQ0C,SAASG,OAAO,qBAKrEC,YAAa,CACX1B,eAAgB,CACdC,KAAM,CACJ,4BAA6B,CAC3BoB,gBAAiB5C,EAAUG,QAAQ0C,SAASC,KAAK,kBACjDI,OAAQ,cAKhBC,cAAe,CACb/B,aAAc,CACZgC,eAAgBC,MAItB,EAGSC,EAAaxD,EAA2B,SACxCyD,EAAYzD,EAA2B"}
1
+ {"version":3,"file":"flipdishPublicTheme.js","sources":["../../src/themes/flipdishPublicTheme.ts"],"sourcesContent":["import createTheme, { type Theme, type ThemeOptions } from '@mui/material/styles/createTheme';\n\nimport CancelIcon from '../icons/Cancel';\nimport { breakpointValues } from './tokens/breakpoints/breakpoints';\nimport { darkColours, lightColours } from './tokens/colours';\nimport { radius } from './tokens/radius/radius';\nimport type { fontSize } from './tokens/typography/font-size';\nimport { typographyVariantMapping } from './tokens/typography/variant-mapping';\nimport { getMobileTextStyle, typography } from './typography';\n\nconst createFlipdishThemeFactory = (mode: 'dark' | 'light'): Theme => {\n const baseTheme = createTheme({\n typography,\n palette: mode === 'light' ? lightColours : darkColours,\n radius,\n breakpoints: {\n values: breakpointValues,\n },\n });\n\n /* \n Add mobile text styles to typography\n Has to be done using media queries, otherwise it isn't responsive :(\n https://mui.com/material-ui/customization/typography/#responsive-font-sizes \n */\n Object.keys(typography).forEach((key) => {\n // only key before the suffix split by capital letter (h1Strong -> h1)\n const keyWithoutVariantSuffix = key.split(/(?=[A-Z])/)[0];\n baseTheme.typography[key] = {\n ...baseTheme.typography[key],\n [baseTheme.breakpoints.down('tablet')]: {\n ...getMobileTextStyle(keyWithoutVariantSuffix as keyof (typeof fontSize)['mobile']),\n },\n };\n });\n\n // Create final theme with component overrides and additional configurations\n return createTheme(baseTheme as ThemeOptions, {\n shape: {\n borderRadius: '4px',\n },\n components: {\n MuiAlert: {\n defaultProps: {\n components: {\n CloseIcon: CancelIcon,\n },\n },\n styleOverrides: {\n root: {\n // TODO: Replace with borderRadius from tokens when implemented\n borderRadius: '8px',\n // TODO: Replace with spacing from tokens when implemented\n padding: '24px',\n },\n icon: {\n // TODO: Replace with spacing from tokens when implemented\n marginRight: '12px',\n padding: 0,\n },\n action: {\n padding: 0,\n '& button': {\n marginTop: '-5px',\n },\n },\n message: {\n padding: 0,\n },\n },\n },\n MuiButton: {\n styleOverrides: {\n root: {\n padding: '12px 24px',\n textTransform: 'none',\n },\n },\n },\n MuiCard: {\n styleOverrides: {\n root: {\n boxShadow: 'none',\n borderWidth: '1px',\n borderStyle: 'solid',\n borderColor: baseTheme.palette.divider,\n },\n },\n },\n MuiChip: {\n styleOverrides: {\n root: {\n fontWeight: 'bold',\n paddingLeft: '6px',\n paddingRight: '6px',\n },\n },\n },\n MuiListItemButton: {\n styleOverrides: {\n root: {\n '&:hover': {\n backgroundColor: baseTheme.palette.semantic.fill['fill-primary-weak'],\n },\n '&:not(:last-child)': {\n borderBottom: `1px solid ${baseTheme.palette.semantic.stroke['stroke-weak']}`,\n },\n },\n },\n },\n MuiTableRow: {\n styleOverrides: {\n root: {\n '&.MuiTableRow-hover:hover': {\n backgroundColor: baseTheme.palette.semantic.fill['fill-secondary'],\n cursor: 'pointer',\n },\n },\n },\n },\n MuiTypography: {\n defaultProps: {\n variantMapping: typographyVariantMapping,\n },\n },\n },\n });\n};\n\nexport const lightTheme = createFlipdishThemeFactory('light');\nexport const darkTheme = createFlipdishThemeFactory('dark');\n"],"names":["createFlipdishThemeFactory","mode","baseTheme","createTheme","typography","palette","lightColours","darkColours","radius","breakpoints","values","breakpointValues","Object","keys","forEach","key","keyWithoutVariantSuffix","split","down","getMobileTextStyle","shape","borderRadius","components","MuiAlert","defaultProps","CloseIcon","CancelIcon","styleOverrides","root","padding","icon","marginRight","action","marginTop","message","MuiButton","textTransform","MuiCard","boxShadow","borderWidth","borderStyle","borderColor","divider","MuiChip","fontWeight","paddingLeft","paddingRight","MuiListItemButton","backgroundColor","semantic","fill","borderBottom","stroke","MuiTableRow","cursor","MuiTypography","variantMapping","typographyVariantMapping","lightTheme","darkTheme"],"mappings":"6dAUA,MAAMA,EAA8BC,IAClC,MAAMC,EAAYC,EAAY,CAC5BC,aACAC,QAAkB,UAATJ,EAAmBK,EAAeC,EAC3CC,SACAC,YAAa,CACXC,OAAQC,KAqBZ,OAZAC,OAAOC,KAAKT,GAAYU,SAASC,IAE/B,MAAMC,EAA0BD,EAAIE,MAAM,aAAa,GACvDf,EAAUE,WAAWW,GAAO,IACvBb,EAAUE,WAAWW,GACxB,CAACb,EAAUO,YAAYS,KAAK,WAAY,IACnCC,EAAmBH,IAEzB,IAIIb,EAAYD,EAA2B,CAC5CkB,MAAO,CACLC,aAAc,OAEhBC,WAAY,CACVC,SAAU,CACRC,aAAc,CACZF,WAAY,CACVG,UAAWC,IAGfC,eAAgB,CACdC,KAAM,CAEJP,aAAc,MAEdQ,QAAS,QAEXC,KAAM,CAEJC,YAAa,OACbF,QAAS,GAEXG,OAAQ,CACNH,QAAS,EACT,WAAY,CACVI,UAAW,SAGfC,QAAS,CACPL,QAAS,KAIfM,UAAW,CACTR,eAAgB,CACdC,KAAM,CACJC,QAAS,YACTO,cAAe,UAIrBC,QAAS,CACPV,eAAgB,CACdC,KAAM,CACJU,UAAW,OACXC,YAAa,MACbC,YAAa,QACbC,YAAavC,EAAUG,QAAQqC,WAIrCC,QAAS,CACPhB,eAAgB,CACdC,KAAM,CACJgB,WAAY,OACZC,YAAa,MACbC,aAAc,SAIpBC,kBAAmB,CACjBpB,eAAgB,CACdC,KAAM,CACJ,UAAW,CACToB,gBAAiB9C,EAAUG,QAAQ4C,SAASC,KAAK,sBAEnD,qBAAsB,CACpBC,aAAc,aAAajD,EAAUG,QAAQ4C,SAASG,OAAO,qBAKrEC,YAAa,CACX1B,eAAgB,CACdC,KAAM,CACJ,4BAA6B,CAC3BoB,gBAAiB9C,EAAUG,QAAQ4C,SAASC,KAAK,kBACjDI,OAAQ,cAKhBC,cAAe,CACb/B,aAAc,CACZgC,eAAgBC,MAItB,EAGSC,EAAa1D,EAA2B,SACxC2D,EAAY3D,EAA2B"}
@@ -0,0 +1,2 @@
1
+ "use strict";exports.breakpointValues={base:0,mobile:375,tablet:768,laptop:1240,desktop:1440,widescreen:1920},exports.breakpoints={"breakpoint-base":"0px","breakpoint-mobile":"375px","breakpoint-tablet":"768px","breakpoint-laptop":"1240px","breakpoint-desktop":"1440px","breakpoint-widescreen":"1920px"};
2
+ //# sourceMappingURL=breakpoints.cjs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"breakpoints.cjs.js","sources":["../../../../src/themes/tokens/breakpoints/breakpoints.ts"],"sourcesContent":["export const breakpoints = {\n 'breakpoint-base': '0px',\n 'breakpoint-mobile': '375px',\n 'breakpoint-tablet': '768px',\n 'breakpoint-laptop': '1240px',\n 'breakpoint-desktop': '1440px',\n 'breakpoint-widescreen': '1920px',\n} as const;\n\nexport type BreakpointToken = keyof typeof breakpoints;\n\n// MUI breakpoint values in pixels (without units)\nexport const breakpointValues = {\n base: 0,\n mobile: 375,\n tablet: 768,\n laptop: 1240,\n desktop: 1440,\n widescreen: 1920,\n};\n"],"names":["base","mobile","tablet","laptop","desktop","widescreen"],"mappings":"sCAYgC,CAC9BA,KAAM,EACNC,OAAQ,IACRC,OAAQ,IACRC,OAAQ,KACRC,QAAS,KACTC,WAAY,0BAlBa,CACzB,kBAAmB,MACnB,oBAAqB,QACrB,oBAAqB,QACrB,oBAAqB,SACrB,qBAAsB,SACtB,wBAAyB"}
@@ -0,0 +1,20 @@
1
+ declare const breakpoints: {
2
+ readonly 'breakpoint-base': "0px";
3
+ readonly 'breakpoint-mobile': "375px";
4
+ readonly 'breakpoint-tablet': "768px";
5
+ readonly 'breakpoint-laptop': "1240px";
6
+ readonly 'breakpoint-desktop': "1440px";
7
+ readonly 'breakpoint-widescreen': "1920px";
8
+ };
9
+ type BreakpointToken = keyof typeof breakpoints;
10
+ declare const breakpointValues: {
11
+ base: number;
12
+ mobile: number;
13
+ tablet: number;
14
+ laptop: number;
15
+ desktop: number;
16
+ widescreen: number;
17
+ };
18
+
19
+ export { breakpointValues, breakpoints };
20
+ export type { BreakpointToken };
@@ -0,0 +1,2 @@
1
+ const e={"breakpoint-base":"0px","breakpoint-mobile":"375px","breakpoint-tablet":"768px","breakpoint-laptop":"1240px","breakpoint-desktop":"1440px","breakpoint-widescreen":"1920px"},p={base:0,mobile:375,tablet:768,laptop:1240,desktop:1440,widescreen:1920};export{p as breakpointValues,e as breakpoints};
2
+ //# sourceMappingURL=breakpoints.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"breakpoints.js","sources":["../../../../src/themes/tokens/breakpoints/breakpoints.ts"],"sourcesContent":["export const breakpoints = {\n 'breakpoint-base': '0px',\n 'breakpoint-mobile': '375px',\n 'breakpoint-tablet': '768px',\n 'breakpoint-laptop': '1240px',\n 'breakpoint-desktop': '1440px',\n 'breakpoint-widescreen': '1920px',\n} as const;\n\nexport type BreakpointToken = keyof typeof breakpoints;\n\n// MUI breakpoint values in pixels (without units)\nexport const breakpointValues = {\n base: 0,\n mobile: 375,\n tablet: 768,\n laptop: 1240,\n desktop: 1440,\n widescreen: 1920,\n};\n"],"names":["breakpoints","breakpointValues","base","mobile","tablet","laptop","desktop","widescreen"],"mappings":"AAAa,MAAAA,EAAc,CACzB,kBAAmB,MACnB,oBAAqB,QACrB,oBAAqB,QACrB,oBAAqB,SACrB,qBAAsB,SACtB,wBAAyB,UAMdC,EAAmB,CAC9BC,KAAM,EACNC,OAAQ,IACRC,OAAQ,IACRC,OAAQ,KACRC,QAAS,KACTC,WAAY"}
@@ -1,2 +1,2 @@
1
- "use strict";exports.spacing={"spacing-0":"0px","spacing-4":"4px","spacing-8":"8px","spacing-12":"12px","spacing-16":"16px","spacing-20":"20px","spacing-24":"24px","spacing-32":"32px","spacing-40":"40px","spacing-48":"48px","spacing-56":"56px","spacing-64":"64px","spacing-96":"96px","spacing-128":"128px","spacing-192":"192px","spacing-256":"256px"};
1
+ "use strict";exports.spacing={"spacing-0":"0px","spacing-4":"4px","spacing-8":"8px","spacing-12":"12px","spacing-16":"16px","spacing-20":"20px","spacing-24":"24px","spacing-32":"32px","spacing-40":"40px","spacing-48":"48px","spacing-56":"56px","spacing-64":"64px","spacing-80":"80px","spacing-96":"96px","spacing-128":"128px","spacing-192":"192px","spacing-256":"256px"};
2
2
  //# sourceMappingURL=spacing.cjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"spacing.cjs.js","sources":["../../../../src/themes/tokens/spacing/spacing.ts"],"sourcesContent":["export const spacing = {\n 'spacing-0': '0px',\n 'spacing-4': '4px',\n 'spacing-8': '8px',\n 'spacing-12': '12px',\n 'spacing-16': '16px',\n 'spacing-20': '20px',\n 'spacing-24': '24px',\n 'spacing-32': '32px',\n 'spacing-40': '40px',\n 'spacing-48': '48px',\n 'spacing-56': '56px',\n 'spacing-64': '64px',\n 'spacing-96': '96px',\n 'spacing-128': '128px',\n 'spacing-192': '192px',\n 'spacing-256': '256px',\n} as const;\n\nexport type SpacingToken = keyof typeof spacing;\n"],"names":[],"mappings":"6BAAuB,CACrB,YAAa,MACb,YAAa,MACb,YAAa,MACb,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,cAAe,QACf,cAAe,QACf,cAAe"}
1
+ {"version":3,"file":"spacing.cjs.js","sources":["../../../../src/themes/tokens/spacing/spacing.ts"],"sourcesContent":["export const spacing = {\n 'spacing-0': '0px',\n 'spacing-4': '4px',\n 'spacing-8': '8px',\n 'spacing-12': '12px',\n 'spacing-16': '16px',\n 'spacing-20': '20px',\n 'spacing-24': '24px',\n 'spacing-32': '32px',\n 'spacing-40': '40px',\n 'spacing-48': '48px',\n 'spacing-56': '56px',\n 'spacing-64': '64px',\n 'spacing-80': '80px',\n 'spacing-96': '96px',\n 'spacing-128': '128px',\n 'spacing-192': '192px',\n 'spacing-256': '256px',\n} as const;\n\nexport type SpacingToken = keyof typeof spacing;\n"],"names":[],"mappings":"6BAAuB,CACrB,YAAa,MACb,YAAa,MACb,YAAa,MACb,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,cAAe,QACf,cAAe,QACf,cAAe"}
@@ -11,6 +11,7 @@ declare const spacing: {
11
11
  readonly 'spacing-48': "48px";
12
12
  readonly 'spacing-56': "56px";
13
13
  readonly 'spacing-64': "64px";
14
+ readonly 'spacing-80': "80px";
14
15
  readonly 'spacing-96': "96px";
15
16
  readonly 'spacing-128': "128px";
16
17
  readonly 'spacing-192': "192px";
@@ -1,2 +1,2 @@
1
- const p={"spacing-0":"0px","spacing-4":"4px","spacing-8":"8px","spacing-12":"12px","spacing-16":"16px","spacing-20":"20px","spacing-24":"24px","spacing-32":"32px","spacing-40":"40px","spacing-48":"48px","spacing-56":"56px","spacing-64":"64px","spacing-96":"96px","spacing-128":"128px","spacing-192":"192px","spacing-256":"256px"};export{p as spacing};
1
+ const p={"spacing-0":"0px","spacing-4":"4px","spacing-8":"8px","spacing-12":"12px","spacing-16":"16px","spacing-20":"20px","spacing-24":"24px","spacing-32":"32px","spacing-40":"40px","spacing-48":"48px","spacing-56":"56px","spacing-64":"64px","spacing-80":"80px","spacing-96":"96px","spacing-128":"128px","spacing-192":"192px","spacing-256":"256px"};export{p as spacing};
2
2
  //# sourceMappingURL=spacing.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"spacing.js","sources":["../../../../src/themes/tokens/spacing/spacing.ts"],"sourcesContent":["export const spacing = {\n 'spacing-0': '0px',\n 'spacing-4': '4px',\n 'spacing-8': '8px',\n 'spacing-12': '12px',\n 'spacing-16': '16px',\n 'spacing-20': '20px',\n 'spacing-24': '24px',\n 'spacing-32': '32px',\n 'spacing-40': '40px',\n 'spacing-48': '48px',\n 'spacing-56': '56px',\n 'spacing-64': '64px',\n 'spacing-96': '96px',\n 'spacing-128': '128px',\n 'spacing-192': '192px',\n 'spacing-256': '256px',\n} as const;\n\nexport type SpacingToken = keyof typeof spacing;\n"],"names":["spacing"],"mappings":"AAAa,MAAAA,EAAU,CACrB,YAAa,MACb,YAAa,MACb,YAAa,MACb,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,cAAe,QACf,cAAe,QACf,cAAe"}
1
+ {"version":3,"file":"spacing.js","sources":["../../../../src/themes/tokens/spacing/spacing.ts"],"sourcesContent":["export const spacing = {\n 'spacing-0': '0px',\n 'spacing-4': '4px',\n 'spacing-8': '8px',\n 'spacing-12': '12px',\n 'spacing-16': '16px',\n 'spacing-20': '20px',\n 'spacing-24': '24px',\n 'spacing-32': '32px',\n 'spacing-40': '40px',\n 'spacing-48': '48px',\n 'spacing-56': '56px',\n 'spacing-64': '64px',\n 'spacing-80': '80px',\n 'spacing-96': '96px',\n 'spacing-128': '128px',\n 'spacing-192': '192px',\n 'spacing-256': '256px',\n} as const;\n\nexport type SpacingToken = keyof typeof spacing;\n"],"names":["spacing"],"mappings":"AAAa,MAAAA,EAAU,CACrB,YAAa,MACb,YAAa,MACb,YAAa,MACb,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,aAAc,OACd,cAAe,QACf,cAAe,QACf,cAAe"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flipdish/portal-library",
3
- "version": "2.1.5",
3
+ "version": "3.0.0",
4
4
  "files": [
5
5
  "dist"
6
6
  ],
@@ -40,8 +40,8 @@
40
40
  "@actions/core": "^1.11.1",
41
41
  "@emotion/react": "11.14.0",
42
42
  "@emotion/styled": "11.14.0",
43
- "@mui/icons-material": "6.4.10",
44
- "@mui/material": "6.4.10",
43
+ "@mui/icons-material": "6.4.11",
44
+ "@mui/material": "6.4.11",
45
45
  "@mui/x-date-pickers": "^7.23.3",
46
46
  "@tanstack/react-query": "^5.62.0",
47
47
  "formik": "^2.4.6",
@@ -79,10 +79,10 @@
79
79
  "@testing-library/jest-dom": "6.6.3",
80
80
  "@testing-library/react": "15.0.7",
81
81
  "@types/react": "18.3.20",
82
- "@types/react-dom": "18.3.6",
82
+ "@types/react-dom": "18.3.7",
83
83
  "@typescript-eslint/eslint-plugin": "7.18.0",
84
84
  "@typescript-eslint/parser": "7.18.0",
85
- "@vitejs/plugin-react-swc": "3.8.1",
85
+ "@vitejs/plugin-react-swc": "3.9.0",
86
86
  "chromatic": "^11.25.2",
87
87
  "dotenv": "^16.4.5",
88
88
  "eslint": "^8.56.0",
@@ -93,7 +93,7 @@
93
93
  "eslint-plugin-prettier": "^5.1.3",
94
94
  "eslint-plugin-react": "^7.37.4",
95
95
  "eslint-plugin-react-hooks": "4.6.2",
96
- "eslint-plugin-react-refresh": "0.4.19",
96
+ "eslint-plugin-react-refresh": "0.4.20",
97
97
  "eslint-plugin-simple-import-sort": "^12.0.0",
98
98
  "eslint-plugin-storybook": "^0.12.0",
99
99
  "eslint-plugin-testing-library": "^7.1.1",
@@ -109,7 +109,7 @@
109
109
  "storybook": "^8.6.7",
110
110
  "tslib": "^2.8.0",
111
111
  "typescript": "5.4.5",
112
- "vite": "5.4.16",
112
+ "vite": "5.4.19",
113
113
  "vite-plugin-svgr": "^3.2.0",
114
114
  "vitest": "1.6.1"
115
115
  },