@graphcommerce/next-ui 10.0.0-canary.67 → 10.0.0-canary.68
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/ActionCard/ActionCard.tsx +30 -21
- package/ActionCard/ActionCardAccordion.tsx +2 -2
- package/ActionCard/ActionCardLayout.tsx +4 -3
- package/ActionCard/ActionCardList.tsx +13 -6
- package/Blog/BlogAuthor/BlogAuthor.tsx +9 -7
- package/Blog/BlogContent/BlogContent.tsx +7 -4
- package/Blog/BlogHeader/BlogHeader.tsx +7 -4
- package/Blog/BlogList/BlogList.tsx +4 -3
- package/Blog/BlogListItem/BlogListItem.tsx +6 -5
- package/Blog/BlogTags/BlogTag.tsx +2 -4
- package/Blog/BlogTitle/BlogTitle.tsx +2 -6
- package/Breadcrumbs/Breadcrumbs.tsx +24 -38
- package/Breadcrumbs/BreadcrumbsList.tsx +9 -9
- package/Button/Button.tsx +4 -4
- package/Button/LinkOrButton.tsx +8 -7
- package/CHANGELOG.md +8 -0
- package/ChipMenu/ChipMenu.tsx +5 -5
- package/Container/Container.tsx +4 -4
- package/Fab/Fab.tsx +1 -1
- package/Footer/Footer.tsx +5 -5
- package/Form/Form.tsx +6 -6
- package/Form/FormDivider.tsx +1 -1
- package/Form/InputCheckmark.tsx +2 -1
- package/FramerScroller/SidebarGallery.tsx +43 -34
- package/FullPageMessage/FullPageMessage.tsx +13 -4
- package/IconHeader/IconHeader.tsx +22 -8
- package/IconSvg/IconSvg.tsx +1 -1
- package/Layout/components/LayoutHeader.tsx +7 -6
- package/Layout/components/LayoutHeaderBack.tsx +0 -2
- package/Layout/components/LayoutHeaderContent.tsx +22 -18
- package/Layout/components/LayoutTitle.tsx +4 -3
- package/LayoutDefault/components/LayoutDefault.tsx +5 -4
- package/LayoutOverlay/components/LayoutOverlayHeader.tsx +4 -3
- package/LayoutOverlay/components/LayoutOverlayHeader2.tsx +0 -6
- package/LayoutParts/DesktopHeaderBadge.tsx +4 -3
- package/LayoutParts/DesktopNavBar.tsx +10 -11
- package/LayoutParts/DesktopNavBarItem.tsx +22 -16
- package/LayoutParts/GlobalHead.tsx +1 -1
- package/LayoutParts/Logo.tsx +2 -1
- package/LayoutParts/MenuFab.tsx +36 -14
- package/LayoutParts/MenuFabItem.tsx +2 -1
- package/LayoutParts/MenuFabSecondaryItem.tsx +6 -3
- package/LayoutParts/PlaceholderFab.tsx +2 -1
- package/LayoutParts/StickyBelowHeader.tsx +4 -3
- package/MediaQuery/MediaQuery.tsx +2 -4
- package/Navigation/components/NavigationFab.tsx +31 -11
- package/Navigation/components/NavigationItem.tsx +14 -10
- package/Navigation/components/NavigationOverlay.tsx +39 -20
- package/Overlay/components/OverlayBase.tsx +21 -23
- package/Overlay/components/OverlayContainer.tsx +35 -12
- package/Overlay/components/OverlayHeader.tsx +2 -1
- package/Overlay/components/OverlayStickyBottom.tsx +2 -5
- package/OverlayOrPopperChip/OverlayOrPopperChip.tsx +35 -31
- package/OverlayOrPopperChip/OverlayPanel.tsx +4 -5
- package/OverlayOrPopperChip/OverlayPanelActions.tsx +2 -1
- package/OverlayOrPopperChip/PopperPanelActions.tsx +2 -1
- package/Pagination/Pagination.tsx +9 -6
- package/Pagination/PaginationExtended.tsx +4 -3
- package/Row/ButtonLinkList/ButtonLinkList.tsx +14 -15
- package/Row/ButtonLinkList/ButtonLinkListItem.tsx +1 -1
- package/Row/ColumnThree/ColumnThree.tsx +4 -3
- package/Row/ColumnTwo/ColumnTwo.tsx +16 -5
- package/Row/ColumnTwoSpread/ColumnTwoSpread.tsx +15 -4
- package/Row/ColumnTwoWithTop/ColumnTwoWithTop.tsx +22 -6
- package/Row/ContentLinks/ContentLinks.tsx +4 -3
- package/Row/HeroBanner/HeroBanner.tsx +3 -7
- package/Row/IconBlocks/IconBlock.tsx +4 -3
- package/Row/IconBlocks/IconBlocks.tsx +2 -1
- package/Row/ImageText/ImageText.tsx +5 -5
- package/Row/ImageTextBoxed/ImageTextBoxed.tsx +2 -2
- package/Row/ParagraphWithSidebarSlide/ParagraphWithSidebarSlide.tsx +1 -1
- package/Row/RowLinks/variant/VariantImageLabelSwiper.tsx +4 -3
- package/Row/RowLinks/variant/VariantInline.tsx +2 -4
- package/Row/RowLinks/variant/VariantLogoSwiper.tsx +4 -3
- package/Row/RowLinks/variant/VariantUsps.tsx +4 -3
- package/Row/SpecialBanner/SpecialBanner.tsx +2 -2
- package/SectionContainer/SectionContainer.tsx +6 -5
- package/SectionHeader/SectionHeader.tsx +4 -3
- package/Separator/Separator.tsx +4 -3
- package/SkipLink/SkipLink.tsx +2 -2
- package/Snackbar/MessageSnackbarImpl.tsx +22 -10
- package/StarRatingField/StarRatingField.tsx +1 -1
- package/Stepper/Stepper.tsx +6 -5
- package/Styles/withTheme.tsx +6 -5
- package/Tabs/TabItem.tsx +4 -5
- package/TextInputNumber/TextInputNumber.tsx +76 -50
- package/Theme/DarkLightModeThemeProvider.tsx +41 -88
- package/Theme/MuiButton.ts +23 -22
- package/Theme/MuiChip.ts +12 -13
- package/Theme/MuiFab.ts +5 -5
- package/Theme/MuiSlider.ts +5 -5
- package/Theme/createTheme.ts +1 -3
- package/Theme/themeDefaults.ts +1 -1
- package/ToggleButton/ToggleButton.tsx +10 -11
- package/ToggleButtonGroup/ToggleButtonGroup.tsx +4 -3
- package/UspList/UspList.tsx +4 -3
- package/UspList/UspListItem.tsx +4 -3
- package/package.json +10 -10
- package/types.ts +1 -0
- package/utils/sxx.ts +1 -1
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { sxx } from '@graphcommerce/next-ui'
|
|
1
2
|
import type { ContainerProps } from '@mui/material'
|
|
2
3
|
import { Box } from '@mui/material'
|
|
3
4
|
import React from 'react'
|
|
@@ -21,7 +22,7 @@ export function ColumnTwo(props: ColumnTwoProps) {
|
|
|
21
22
|
maxWidth='lg'
|
|
22
23
|
{...containerProps}
|
|
23
24
|
className={classes.root}
|
|
24
|
-
sx={
|
|
25
|
+
sx={sxx(
|
|
25
26
|
(theme) => ({
|
|
26
27
|
gridColumnGap: theme.spacings.md,
|
|
27
28
|
gridRowGap: theme.spacings.lg,
|
|
@@ -33,13 +34,23 @@ export function ColumnTwo(props: ColumnTwoProps) {
|
|
|
33
34
|
gridTemplateAreas: '"one two"',
|
|
34
35
|
},
|
|
35
36
|
}),
|
|
36
|
-
|
|
37
|
-
|
|
37
|
+
sx,
|
|
38
|
+
)}
|
|
38
39
|
>
|
|
39
|
-
<Box
|
|
40
|
+
<Box
|
|
41
|
+
className={classes.colOne}
|
|
42
|
+
sx={{
|
|
43
|
+
gridArea: 'one',
|
|
44
|
+
}}
|
|
45
|
+
>
|
|
40
46
|
{colOneContent}
|
|
41
47
|
</Box>
|
|
42
|
-
<Box
|
|
48
|
+
<Box
|
|
49
|
+
className={classes.colTwo}
|
|
50
|
+
sx={{
|
|
51
|
+
gridArea: 'two',
|
|
52
|
+
}}
|
|
53
|
+
>
|
|
43
54
|
{colTwoContent}
|
|
44
55
|
</Box>
|
|
45
56
|
</Row>
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { sxx } from '@graphcommerce/next-ui'
|
|
1
2
|
import type { ColumnTwoProps } from '../ColumnTwo/ColumnTwo'
|
|
2
3
|
import { ColumnTwo } from '../ColumnTwo/ColumnTwo'
|
|
3
4
|
|
|
@@ -12,11 +13,10 @@ export function ColumnTwoSpread(props: ColumnTwoSpreadProps) {
|
|
|
12
13
|
<ColumnTwo
|
|
13
14
|
{...colProps}
|
|
14
15
|
className='ColumnTwoSpread'
|
|
15
|
-
sx={
|
|
16
|
+
sx={sxx(
|
|
16
17
|
(theme) => ({
|
|
17
18
|
[theme.breakpoints.up('md')]: {
|
|
18
19
|
gridTemplateColumns: '1fr 1fr 1fr',
|
|
19
|
-
gridTemplateAreas: nodeLength ? '"one one two"' : '"one two two"',
|
|
20
20
|
'& h2, & h3': {
|
|
21
21
|
'&:empty': {
|
|
22
22
|
display: 'block',
|
|
@@ -27,8 +27,19 @@ export function ColumnTwoSpread(props: ColumnTwoSpreadProps) {
|
|
|
27
27
|
gridTemplateColumns: '1fr',
|
|
28
28
|
gridTemplateAreas: '"one" "two"',
|
|
29
29
|
}),
|
|
30
|
-
|
|
31
|
-
|
|
30
|
+
nodeLength
|
|
31
|
+
? (theme) => ({
|
|
32
|
+
[theme.breakpoints.up('md')]: {
|
|
33
|
+
gridTemplateAreas: '"one one two"',
|
|
34
|
+
},
|
|
35
|
+
})
|
|
36
|
+
: (theme) => ({
|
|
37
|
+
[theme.breakpoints.up('md')]: {
|
|
38
|
+
gridTemplateAreas: '"one two two"',
|
|
39
|
+
},
|
|
40
|
+
}),
|
|
41
|
+
sx,
|
|
42
|
+
)}
|
|
32
43
|
/>
|
|
33
44
|
)
|
|
34
45
|
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { sxx } from '@graphcommerce/next-ui'
|
|
1
2
|
import type { ContainerProps } from '@mui/material'
|
|
2
3
|
import { Box } from '@mui/material'
|
|
3
4
|
import React from 'react'
|
|
@@ -21,7 +22,7 @@ export function ColumnTwoWithTop(props: ColumnTwoWithTopProps) {
|
|
|
21
22
|
<Row
|
|
22
23
|
maxWidth='lg'
|
|
23
24
|
className={classes.root}
|
|
24
|
-
sx={
|
|
25
|
+
sx={sxx(
|
|
25
26
|
(theme) => ({
|
|
26
27
|
display: 'grid',
|
|
27
28
|
gap: `${theme.spacings.lg} 0`,
|
|
@@ -32,17 +33,32 @@ export function ColumnTwoWithTop(props: ColumnTwoWithTopProps) {
|
|
|
32
33
|
gap: `${theme.spacings.sm} ${theme.spacings.xxl}`,
|
|
33
34
|
},
|
|
34
35
|
}),
|
|
35
|
-
|
|
36
|
-
|
|
36
|
+
sx,
|
|
37
|
+
)}
|
|
37
38
|
{...containerProps}
|
|
38
39
|
>
|
|
39
|
-
<Box
|
|
40
|
+
<Box
|
|
41
|
+
className={classes.colOne}
|
|
42
|
+
sx={{
|
|
43
|
+
gridArea: 'top',
|
|
44
|
+
}}
|
|
45
|
+
>
|
|
40
46
|
{top}
|
|
41
47
|
</Box>
|
|
42
|
-
<Box
|
|
48
|
+
<Box
|
|
49
|
+
className={classes.colOne}
|
|
50
|
+
sx={{
|
|
51
|
+
gridArea: 'left',
|
|
52
|
+
}}
|
|
53
|
+
>
|
|
43
54
|
{left}
|
|
44
55
|
</Box>
|
|
45
|
-
<Box
|
|
56
|
+
<Box
|
|
57
|
+
className={classes.colTwo}
|
|
58
|
+
sx={{
|
|
59
|
+
gridArea: 'right',
|
|
60
|
+
}}
|
|
61
|
+
>
|
|
46
62
|
{right}
|
|
47
63
|
</Box>
|
|
48
64
|
</Row>
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Scroller, ScrollerProvider } from '@graphcommerce/framer-scroller'
|
|
2
|
+
import { sxx } from '@graphcommerce/next-ui'
|
|
2
3
|
import type { SxProps, Theme } from '@mui/material'
|
|
3
4
|
import { Container, Typography } from '@mui/material'
|
|
4
5
|
import React from 'react'
|
|
@@ -21,12 +22,12 @@ export function ContentLinks(props: ContentLinksProps) {
|
|
|
21
22
|
<Container
|
|
22
23
|
className={classes.root}
|
|
23
24
|
maxWidth={false}
|
|
24
|
-
sx={
|
|
25
|
+
sx={sxx(
|
|
25
26
|
(theme) => ({
|
|
26
27
|
marginBottom: `${theme.spacings.md}`,
|
|
27
28
|
}),
|
|
28
|
-
|
|
29
|
-
|
|
29
|
+
sx,
|
|
30
|
+
)}
|
|
30
31
|
>
|
|
31
32
|
<ScrollerProvider scrollSnapAlign='none'>
|
|
32
33
|
<Scroller
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { clientSize } from '@graphcommerce/framer-utils'
|
|
2
|
+
import { sxx } from '@graphcommerce/next-ui'
|
|
2
3
|
import type { ContainerProps, SxProps, Theme } from '@mui/material'
|
|
3
4
|
import { Box, styled } from '@mui/material'
|
|
4
5
|
import { m, useTransform } from 'framer-motion'
|
|
@@ -28,12 +29,7 @@ export function HeroBanner(props: HeroBannerProps) {
|
|
|
28
29
|
)
|
|
29
30
|
|
|
30
31
|
return (
|
|
31
|
-
<Row
|
|
32
|
-
maxWidth={false}
|
|
33
|
-
{...containerProps}
|
|
34
|
-
className={classes.root}
|
|
35
|
-
sx={[{}, ...(Array.isArray(sx) ? sx : [sx])]}
|
|
36
|
-
>
|
|
32
|
+
<Row maxWidth={false} {...containerProps} className={classes.root} sx={sx}>
|
|
37
33
|
<Box
|
|
38
34
|
className={classes.wrapper}
|
|
39
35
|
sx={(theme) => ({
|
|
@@ -53,7 +49,7 @@ export function HeroBanner(props: HeroBannerProps) {
|
|
|
53
49
|
alignContent: 'center',
|
|
54
50
|
textAlign: 'center',
|
|
55
51
|
p: theme.spacings.md,
|
|
56
|
-
color: theme.palette.secondary.contrastText,
|
|
52
|
+
color: theme.vars.palette.secondary.contrastText,
|
|
57
53
|
})}
|
|
58
54
|
>
|
|
59
55
|
{children}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { sxx } from '@graphcommerce/next-ui'
|
|
1
2
|
import type { ButtonProps, SxProps, Theme } from '@mui/material'
|
|
2
3
|
import { Box, Button, Typography } from '@mui/material'
|
|
3
4
|
import React from 'react'
|
|
@@ -27,7 +28,7 @@ export const IconBlock = React.forwardRef<HTMLAnchorElement & HTMLButtonElement,
|
|
|
27
28
|
color='primary'
|
|
28
29
|
className={classes.block}
|
|
29
30
|
{...buttonProps}
|
|
30
|
-
sx={
|
|
31
|
+
sx={sxx(
|
|
31
32
|
(theme) => ({
|
|
32
33
|
padding: `${theme.spacings.sm}`,
|
|
33
34
|
textAlign: 'center',
|
|
@@ -38,8 +39,8 @@ export const IconBlock = React.forwardRef<HTMLAnchorElement & HTMLButtonElement,
|
|
|
38
39
|
gap: `${theme.spacings.xxs}`,
|
|
39
40
|
},
|
|
40
41
|
}),
|
|
41
|
-
|
|
42
|
-
|
|
42
|
+
sx,
|
|
43
|
+
)}
|
|
43
44
|
>
|
|
44
45
|
<Box>
|
|
45
46
|
{icon}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { sxx } from '@graphcommerce/next-ui'
|
|
1
2
|
import type { SxProps, Theme } from '@mui/material'
|
|
2
3
|
import { Box } from '@mui/material'
|
|
3
4
|
import React from 'react'
|
|
@@ -19,7 +20,7 @@ export function IconBlocks(props: IconBlocksProps) {
|
|
|
19
20
|
const { title, children, sx = [] } = props
|
|
20
21
|
|
|
21
22
|
return (
|
|
22
|
-
<Row maxWidth='
|
|
23
|
+
<Row maxWidth='md' className={classes.container} sx={sxx({ maxWidth: 820 }, sx)}>
|
|
23
24
|
<Box className={classes.wrapper} sx={(theme) => ({ paddingTop: `${theme.spacings.lg}` })}>
|
|
24
25
|
<Box
|
|
25
26
|
className={classes.title}
|
|
@@ -24,10 +24,7 @@ export function ImageText(props: ImageTextProps) {
|
|
|
24
24
|
className={classes.wrapper}
|
|
25
25
|
sx={(theme) => ({
|
|
26
26
|
display: 'grid',
|
|
27
|
-
background:
|
|
28
|
-
theme.palette.mode === 'light'
|
|
29
|
-
? theme.palette.background.image
|
|
30
|
-
: theme.palette.background.paper,
|
|
27
|
+
background: theme.vars.palette.background.paper,
|
|
31
28
|
justifyItems: 'center',
|
|
32
29
|
columnGap: theme.spacings.lg,
|
|
33
30
|
marginTop: theme.spacings.lg,
|
|
@@ -44,6 +41,9 @@ export function ImageText(props: ImageTextProps) {
|
|
|
44
41
|
theme.shape.borderRadius * 3,
|
|
45
42
|
theme.breakpoints.values,
|
|
46
43
|
),
|
|
44
|
+
...theme.applyStyles('light', {
|
|
45
|
+
background: theme.vars.palette.background.image,
|
|
46
|
+
}),
|
|
47
47
|
})}
|
|
48
48
|
>
|
|
49
49
|
<Box
|
|
@@ -70,7 +70,7 @@ export function ImageText(props: ImageTextProps) {
|
|
|
70
70
|
className={classes.copy}
|
|
71
71
|
sx={(theme) => ({
|
|
72
72
|
marginTop: theme.spacings.lg,
|
|
73
|
-
color: theme.palette.text.primary,
|
|
73
|
+
color: theme.vars.palette.text.primary,
|
|
74
74
|
maxWidth: '80%',
|
|
75
75
|
display: 'grid',
|
|
76
76
|
alignContent: 'center',
|
|
@@ -25,7 +25,7 @@ export function ImageTextBoxed(props: ImageTextBoxedProps) {
|
|
|
25
25
|
className={classes.wrapper}
|
|
26
26
|
sx={(theme) => ({
|
|
27
27
|
display: 'grid',
|
|
28
|
-
border: `1px solid ${theme.palette.divider}`,
|
|
28
|
+
border: `1px solid ${theme.vars.palette.divider}`,
|
|
29
29
|
justifyItems: 'center',
|
|
30
30
|
columnGap: `${theme.spacings.lg}`,
|
|
31
31
|
padding: 0,
|
|
@@ -47,7 +47,7 @@ export function ImageTextBoxed(props: ImageTextBoxedProps) {
|
|
|
47
47
|
className={classes.copy}
|
|
48
48
|
sx={(theme) => ({
|
|
49
49
|
padding: `${theme.spacings.lg} 0`,
|
|
50
|
-
color: theme.palette.text.primary,
|
|
50
|
+
color: theme.vars.palette.text.primary,
|
|
51
51
|
maxWidth: '80%',
|
|
52
52
|
display: 'grid',
|
|
53
53
|
alignContent: 'center',
|
|
@@ -59,7 +59,7 @@ export function ParagraphWithSidebarSlide(props: ParagraphWithSidebarSlideProps)
|
|
|
59
59
|
<Box
|
|
60
60
|
className={classes.copy}
|
|
61
61
|
sx={(theme) => ({
|
|
62
|
-
color: theme.palette.secondary.contrastText,
|
|
62
|
+
color: theme.vars.palette.secondary.contrastText,
|
|
63
63
|
display: 'grid',
|
|
64
64
|
zIndex: 1,
|
|
65
65
|
justifyItems: 'start',
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { sxx } from '@graphcommerce/next-ui'
|
|
1
2
|
import type { RowLinksProps } from '../RowLinks'
|
|
2
3
|
import { RowLinks } from '../RowLinks'
|
|
3
4
|
|
|
@@ -7,7 +8,7 @@ export function VariantImageLabelSwiper(props: RowLinksProps) {
|
|
|
7
8
|
return (
|
|
8
9
|
<RowLinks
|
|
9
10
|
{...rowLinksProps}
|
|
10
|
-
sx={
|
|
11
|
+
sx={sxx(
|
|
11
12
|
{
|
|
12
13
|
// '& .Scroller-root': {
|
|
13
14
|
// alignItems: 'start',
|
|
@@ -20,8 +21,8 @@ export function VariantImageLabelSwiper(props: RowLinksProps) {
|
|
|
20
21
|
textTransform: 'uppercase',
|
|
21
22
|
},
|
|
22
23
|
},
|
|
23
|
-
|
|
24
|
-
|
|
24
|
+
sx,
|
|
25
|
+
)}
|
|
25
26
|
/>
|
|
26
27
|
)
|
|
27
28
|
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { sxx } from '@graphcommerce/next-ui'
|
|
1
2
|
import type { RowLinksProps } from '../RowLinks'
|
|
2
3
|
import { RowLinks } from '../RowLinks'
|
|
3
4
|
|
|
@@ -8,10 +9,7 @@ export function VariantInline(props: RowLinksProps) {
|
|
|
8
9
|
<RowLinks
|
|
9
10
|
inlineTitle={inlineTitle}
|
|
10
11
|
{...rowLinksProps}
|
|
11
|
-
sx={
|
|
12
|
-
(theme) => ({ '& .RowLinks-scrollerWrapper': { my: theme.spacings.md } }),
|
|
13
|
-
...(Array.isArray(sx) ? sx : [sx]),
|
|
14
|
-
]}
|
|
12
|
+
sx={sxx((theme) => ({ '& .RowLinks-scrollerWrapper': { my: theme.spacings.md } }), sx)}
|
|
15
13
|
/>
|
|
16
14
|
)
|
|
17
15
|
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { sxx } from '@graphcommerce/next-ui'
|
|
1
2
|
import type { RowLinksProps } from '../RowLinks'
|
|
2
3
|
import { RowLinks } from '../RowLinks'
|
|
3
4
|
|
|
@@ -7,7 +8,7 @@ export function VariantLogoSwiper(props: RowLinksProps) {
|
|
|
7
8
|
return (
|
|
8
9
|
<RowLinks
|
|
9
10
|
{...rowLinksProps}
|
|
10
|
-
sx={
|
|
11
|
+
sx={sxx(
|
|
11
12
|
(theme) => ({
|
|
12
13
|
'& .RowLinks-title': {
|
|
13
14
|
display: 'none',
|
|
@@ -19,8 +20,8 @@ export function VariantLogoSwiper(props: RowLinksProps) {
|
|
|
19
20
|
gap: theme.spacings.xxl,
|
|
20
21
|
},
|
|
21
22
|
}),
|
|
22
|
-
|
|
23
|
-
|
|
23
|
+
sx,
|
|
24
|
+
)}
|
|
24
25
|
/>
|
|
25
26
|
)
|
|
26
27
|
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { sxx } from '@graphcommerce/next-ui'
|
|
1
2
|
import type { RowLinksProps } from '../RowLinks'
|
|
2
3
|
import { RowLinks } from '../RowLinks'
|
|
3
4
|
|
|
@@ -8,7 +9,7 @@ export function VariantUsps(props: RowLinksProps) {
|
|
|
8
9
|
<RowLinks
|
|
9
10
|
inlineTitle={inlineTitle}
|
|
10
11
|
{...rowLinksProps}
|
|
11
|
-
sx={
|
|
12
|
+
sx={sxx(
|
|
12
13
|
(theme) => ({
|
|
13
14
|
'& .RowLinks-title': {
|
|
14
15
|
display: 'none',
|
|
@@ -20,8 +21,8 @@ export function VariantUsps(props: RowLinksProps) {
|
|
|
20
21
|
gap: theme.spacings.lg,
|
|
21
22
|
},
|
|
22
23
|
}),
|
|
23
|
-
|
|
24
|
-
|
|
24
|
+
sx,
|
|
25
|
+
)}
|
|
25
26
|
/>
|
|
26
27
|
)
|
|
27
28
|
}
|
|
@@ -27,7 +27,7 @@ export function SpecialBanner(props: SpecialBannerProps) {
|
|
|
27
27
|
disableGutters
|
|
28
28
|
sx={(theme) => ({
|
|
29
29
|
display: 'grid',
|
|
30
|
-
background: theme.palette.background.paper,
|
|
30
|
+
background: theme.vars.palette.background.paper,
|
|
31
31
|
justifyItems: 'center',
|
|
32
32
|
columnGap: `${theme.spacings.lg}`,
|
|
33
33
|
paddingTop: theme.spacings.lg,
|
|
@@ -87,7 +87,7 @@ export function SpecialBanner(props: SpecialBannerProps) {
|
|
|
87
87
|
<Box
|
|
88
88
|
className={classes.copy}
|
|
89
89
|
sx={(theme) => ({
|
|
90
|
-
color: theme.palette.text.primary,
|
|
90
|
+
color: theme.vars.palette.text.primary,
|
|
91
91
|
maxWidth: '70%',
|
|
92
92
|
display: 'grid',
|
|
93
93
|
alignContent: 'center',
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { sxx } from '@graphcommerce/next-ui'
|
|
1
2
|
import { Box } from '@mui/material'
|
|
2
3
|
import type { SectionHeaderProps } from '../SectionHeader/SectionHeader'
|
|
3
4
|
import { SectionHeader } from '../SectionHeader/SectionHeader'
|
|
@@ -18,19 +19,19 @@ export function SectionContainer(props: SectionContainerProps) {
|
|
|
18
19
|
return (
|
|
19
20
|
<Box
|
|
20
21
|
className={`${classes.root} ${className ?? ''}`}
|
|
21
|
-
sx={
|
|
22
|
+
sx={sxx(
|
|
22
23
|
(theme) => ({
|
|
23
24
|
'&.borderBottom': {
|
|
24
|
-
borderBottom: `1px solid ${theme.palette.divider}`,
|
|
25
|
+
borderBottom: `1px solid ${theme.vars.palette.divider}`,
|
|
25
26
|
},
|
|
26
27
|
}),
|
|
27
|
-
|
|
28
|
-
|
|
28
|
+
sx,
|
|
29
|
+
)}
|
|
29
30
|
>
|
|
30
31
|
<SectionHeader
|
|
31
32
|
{...sectionHeaderProps}
|
|
32
33
|
sx={(theme) => ({
|
|
33
|
-
borderBottom: `1px solid ${theme.palette.divider}`,
|
|
34
|
+
borderBottom: `1px solid ${theme.vars.palette.divider}`,
|
|
34
35
|
paddingBottom: theme.spacings.xxs,
|
|
35
36
|
marginBottom: theme.spacings.xxs,
|
|
36
37
|
})}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { sxx } from '@graphcommerce/next-ui'
|
|
1
2
|
import type { SxProps, Theme, TypographyProps } from '@mui/material'
|
|
2
3
|
import { Box, Typography } from '@mui/material'
|
|
3
4
|
import React from 'react'
|
|
@@ -32,7 +33,7 @@ export function SectionHeader(props: SectionHeaderProps) {
|
|
|
32
33
|
return (
|
|
33
34
|
<Box
|
|
34
35
|
className={classes.root}
|
|
35
|
-
sx={
|
|
36
|
+
sx={sxx(
|
|
36
37
|
(theme) => ({
|
|
37
38
|
position: 'relative',
|
|
38
39
|
'&:focus': {
|
|
@@ -49,8 +50,8 @@ export function SectionHeader(props: SectionHeaderProps) {
|
|
|
49
50
|
paddingLeft: theme.spacings.xxs,
|
|
50
51
|
paddingRight: theme.spacings.xxs,
|
|
51
52
|
})),
|
|
52
|
-
|
|
53
|
-
|
|
53
|
+
sx,
|
|
54
|
+
)}
|
|
54
55
|
>
|
|
55
56
|
<Typography
|
|
56
57
|
className={classes.left}
|
package/Separator/Separator.tsx
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { sxx } from '@graphcommerce/next-ui'
|
|
1
2
|
import type { TypographyProps } from '@mui/material'
|
|
2
3
|
import { Box, Typography } from '@mui/material'
|
|
3
4
|
import React from 'react'
|
|
@@ -17,13 +18,13 @@ export function Separator(props: DividedLinksProps) {
|
|
|
17
18
|
return (
|
|
18
19
|
<Box
|
|
19
20
|
className={classes.root}
|
|
20
|
-
sx={
|
|
21
|
+
sx={sxx(
|
|
21
22
|
(theme) => ({
|
|
22
23
|
display: 'inline',
|
|
23
24
|
padding: `0 ${theme.spacings.xxs} 0 ${theme.spacings.xxs}`,
|
|
24
25
|
}),
|
|
25
|
-
|
|
26
|
-
|
|
26
|
+
sx,
|
|
27
|
+
)}
|
|
27
28
|
>
|
|
28
29
|
{icon ?? (
|
|
29
30
|
<Typography component='span' variant='body1' color={color}>
|
package/SkipLink/SkipLink.tsx
CHANGED
|
@@ -24,8 +24,8 @@ export function SkipLink() {
|
|
|
24
24
|
zIndex: '-1',
|
|
25
25
|
marginLeft: theme.page.horizontal,
|
|
26
26
|
padding: theme.spacings.xxs,
|
|
27
|
-
backgroundColor: theme.palette.background.paper,
|
|
28
|
-
border: theme.palette.text.primary,
|
|
27
|
+
backgroundColor: theme.vars.palette.background.paper,
|
|
28
|
+
border: theme.vars.palette.text.primary,
|
|
29
29
|
borderRadius: theme.shape.borderRadius,
|
|
30
30
|
'&:focus': {
|
|
31
31
|
zIndex: 9999,
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
import { sxx } from '@graphcommerce/next-ui'
|
|
1
2
|
import { t } from '@lingui/core/macro'
|
|
2
3
|
import type { SnackbarProps, SxProps, Theme } from '@mui/material'
|
|
3
|
-
import { Box, Fab,
|
|
4
|
+
import { Box, Fab, Portal, Snackbar, SnackbarContent } from '@mui/material'
|
|
4
5
|
import React, { useEffect, useState } from 'react'
|
|
5
6
|
import { iconCheckmark, iconClose, iconSadFace } from '../icons'
|
|
6
7
|
import iconInfo from '../icons/info.svg'
|
|
@@ -108,13 +109,13 @@ export default function MessageSnackbarImpl(props: MessageSnackbarProps) {
|
|
|
108
109
|
open={showSnackbar}
|
|
109
110
|
autoHideDuration={autoHide ? 5000 : null}
|
|
110
111
|
className={classes.root}
|
|
111
|
-
sx={
|
|
112
|
+
sx={sxx(
|
|
112
113
|
{
|
|
113
114
|
pointerEvents: 'none',
|
|
114
115
|
'& > *': { pointerEvents: 'auto' },
|
|
115
116
|
},
|
|
116
|
-
|
|
117
|
-
|
|
117
|
+
sx,
|
|
118
|
+
)}
|
|
118
119
|
onClose={hideSnackbar}
|
|
119
120
|
>
|
|
120
121
|
<SnackbarContent
|
|
@@ -122,8 +123,8 @@ export default function MessageSnackbarImpl(props: MessageSnackbarProps) {
|
|
|
122
123
|
className={classes.content}
|
|
123
124
|
sx={(theme) => ({
|
|
124
125
|
'&.variantPill': {
|
|
125
|
-
backgroundColor: theme.palette.background.paper,
|
|
126
|
-
color: theme.palette.text.primary,
|
|
126
|
+
backgroundColor: theme.vars.palette.background.paper,
|
|
127
|
+
color: theme.vars.palette.text.primary,
|
|
127
128
|
[theme.breakpoints.up('md')]: {
|
|
128
129
|
...breakpointVal(
|
|
129
130
|
'borderRadius',
|
|
@@ -154,7 +155,6 @@ export default function MessageSnackbarImpl(props: MessageSnackbarProps) {
|
|
|
154
155
|
gridArea: 'children',
|
|
155
156
|
},
|
|
156
157
|
},
|
|
157
|
-
|
|
158
158
|
'&.disableIcon .MuiSnackbarContent-message': {
|
|
159
159
|
gridTemplate: {
|
|
160
160
|
xs: `"children close"
|
|
@@ -180,10 +180,22 @@ export default function MessageSnackbarImpl(props: MessageSnackbarProps) {
|
|
|
180
180
|
message={
|
|
181
181
|
<>
|
|
182
182
|
{!disableIcon && <IconSvg src={icon2} size='large' />}
|
|
183
|
-
<Box
|
|
183
|
+
<Box
|
|
184
|
+
sx={{
|
|
185
|
+
gridArea: 'children',
|
|
186
|
+
}}
|
|
187
|
+
>
|
|
188
|
+
{children}
|
|
189
|
+
</Box>
|
|
184
190
|
{/* </Box> */}
|
|
185
191
|
{action && (
|
|
186
|
-
<Box
|
|
192
|
+
<Box
|
|
193
|
+
className={classes.actionButton}
|
|
194
|
+
onClick={hideSnackbar}
|
|
195
|
+
sx={{
|
|
196
|
+
gridArea: 'action',
|
|
197
|
+
}}
|
|
198
|
+
>
|
|
187
199
|
{action}
|
|
188
200
|
</Box>
|
|
189
201
|
)}
|
|
@@ -196,7 +208,7 @@ export default function MessageSnackbarImpl(props: MessageSnackbarProps) {
|
|
|
196
208
|
onMouseDown={preventAnimationBubble}
|
|
197
209
|
onTouchStart={preventAnimationBubble}
|
|
198
210
|
sx={(theme) => ({
|
|
199
|
-
backgroundColor: lighten(theme.palette.background.paper, 0.1),
|
|
211
|
+
backgroundColor: theme.lighten(theme.vars.palette.background.paper, 0.1),
|
|
200
212
|
})}
|
|
201
213
|
>
|
|
202
214
|
<IconSvg src={iconClose} />
|
|
@@ -27,7 +27,7 @@ export function StarRatingField(props: StarRatingFieldProps) {
|
|
|
27
27
|
src={iconStar}
|
|
28
28
|
size='large'
|
|
29
29
|
className={classes.starFull}
|
|
30
|
-
sx={(theme) => ({ fill: theme.palette.divider, stroke: 'none', margin: '0 3px' })}
|
|
30
|
+
sx={(theme) => ({ fill: theme.vars.palette.divider, stroke: 'none', margin: '0 3px' })}
|
|
31
31
|
/>
|
|
32
32
|
}
|
|
33
33
|
icon={
|
package/Stepper/Stepper.tsx
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { sxx } from '@graphcommerce/next-ui'
|
|
1
2
|
import type { SxProps, Theme } from '@mui/material'
|
|
2
3
|
import { Box } from '@mui/material'
|
|
3
4
|
import { extendableComponent } from '../Styles'
|
|
@@ -18,19 +19,19 @@ export function Stepper(props: StepperProps) {
|
|
|
18
19
|
return (
|
|
19
20
|
<Box
|
|
20
21
|
className={classes.root}
|
|
21
|
-
sx={
|
|
22
|
+
sx={sxx(
|
|
22
23
|
(theme) => ({
|
|
23
24
|
marginTop: '-2px',
|
|
24
25
|
display: 'grid',
|
|
25
26
|
gridAutoFlow: 'column',
|
|
26
27
|
gap: theme.spacings.xxs,
|
|
27
28
|
}),
|
|
28
|
-
|
|
29
|
-
|
|
29
|
+
sx,
|
|
30
|
+
)}
|
|
30
31
|
>
|
|
31
32
|
{[...Array(steps).keys()].map((step: number) => (
|
|
32
33
|
<Box
|
|
33
|
-
sx={
|
|
34
|
+
sx={sxx(
|
|
34
35
|
{
|
|
35
36
|
height: 2,
|
|
36
37
|
bgcolor: 'divider',
|
|
@@ -38,7 +39,7 @@ export function Stepper(props: StepperProps) {
|
|
|
38
39
|
currentStep - 1 >= step && {
|
|
39
40
|
bgcolor: 'secondary.main',
|
|
40
41
|
},
|
|
41
|
-
|
|
42
|
+
)}
|
|
42
43
|
className={`${classes.step} ${currentStep - 1 >= step ? classes.activeStep : ''}`}
|
|
43
44
|
key={step}
|
|
44
45
|
/>
|
package/Styles/withTheme.tsx
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { sxx } from '@graphcommerce/next-ui'
|
|
1
2
|
import type { SxProps, Theme } from '@mui/material'
|
|
2
3
|
import { ThemeProvider } from '@mui/material'
|
|
3
4
|
import React from 'react'
|
|
@@ -49,14 +50,14 @@ export function withTheme<T>(
|
|
|
49
50
|
<ThemeProvider theme={theme}>
|
|
50
51
|
<Component
|
|
51
52
|
{...data}
|
|
52
|
-
sx={
|
|
53
|
+
sx={sxx(
|
|
53
54
|
{
|
|
54
55
|
typography: 'body1',
|
|
55
|
-
color: theme.palette.text.primary,
|
|
56
|
-
backgroundColor: theme.palette.background.default,
|
|
56
|
+
color: theme.vars.palette.text.primary,
|
|
57
|
+
backgroundColor: theme.vars.palette.background.default,
|
|
57
58
|
},
|
|
58
|
-
|
|
59
|
-
|
|
59
|
+
sx,
|
|
60
|
+
)}
|
|
60
61
|
/>
|
|
61
62
|
</ThemeProvider>
|
|
62
63
|
)
|
package/Tabs/TabItem.tsx
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Box, ButtonBase, type SxProps, type Theme } from '@mui/material'
|
|
2
|
-
import {
|
|
2
|
+
import { useTheme } from '@mui/material/styles'
|
|
3
3
|
import { forwardRef } from 'react'
|
|
4
4
|
import { extendableComponent } from '../Styles/extendableComponent'
|
|
5
5
|
import { responsiveVal } from '../Styles/responsiveVal'
|
|
@@ -46,7 +46,7 @@ export const TabItem = forwardRef<HTMLButtonElement, TabItemProps>((props, ref)
|
|
|
46
46
|
sx,
|
|
47
47
|
disableRipple = true,
|
|
48
48
|
className,
|
|
49
|
-
color = (theme) => theme.palette.background.default,
|
|
49
|
+
color = (theme) => theme.vars.palette.background.default,
|
|
50
50
|
variant = 'chrome',
|
|
51
51
|
...other
|
|
52
52
|
} = props
|
|
@@ -74,12 +74,11 @@ export const TabItem = forwardRef<HTMLButtonElement, TabItemProps>((props, ref)
|
|
|
74
74
|
pb: spacing,
|
|
75
75
|
mx: `calc(${spacing} / 2)`,
|
|
76
76
|
transition: 'background-color 0.2s ease-in-out',
|
|
77
|
-
|
|
78
77
|
'&:hover:not(.selected) .TabItem-content': {
|
|
79
|
-
bgcolor: alpha(color(theme), 0.5),
|
|
78
|
+
bgcolor: theme.alpha(color(theme), 0.5),
|
|
80
79
|
},
|
|
81
80
|
'&:focus:not(.selected) .TabItem-content': {
|
|
82
|
-
bgcolor: alpha(color(theme), 0.5),
|
|
81
|
+
bgcolor: theme.alpha(color(theme), 0.5),
|
|
83
82
|
},
|
|
84
83
|
'&::before': {
|
|
85
84
|
opacity: 0,
|