@graphcommerce/next-ui 3.15.1 → 3.17.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AppShell/AppShellHeader/index.tsx +1 -3
- package/AppShell/Footer/index.tsx +2 -1
- package/AppShell/FullPageShellBase.tsx +1 -1
- package/AppShell/SheetShellBase/index.tsx +8 -4
- package/AppShell/SheetShellBase/useSheetStyles.ts +10 -3
- package/AppShell/useFixedFabAnimation.tsx +10 -10
- package/Blog/BlogListItem/index.tsx +1 -1
- package/Button/index.tsx +1 -4
- package/CHANGELOG.md +69 -0
- package/ChipMenu/index.tsx +4 -5
- package/FramerScroller/components/SidebarGallery.tsx +0 -1
- package/FullPageMessage/index.tsx +1 -5
- package/Pagination/index.tsx +17 -5
- package/Row/HeroBanner/index.tsx +11 -9
- package/Row/IconBlocks/IconBlock/index.tsx +13 -6
- package/Row/SpecialBanner/index.tsx +2 -1
- package/SvgImage/SvgImageSimple.tsx +3 -2
- package/TextInputNumber/index.tsx +1 -1
- package/ToggleButton/index.tsx +5 -2
- package/package.json +10 -10
|
@@ -186,9 +186,6 @@ const useStyles = makeStyles(
|
|
|
186
186
|
'&:hover': {
|
|
187
187
|
background: theme.palette.background.paper,
|
|
188
188
|
},
|
|
189
|
-
'& svg': {
|
|
190
|
-
stroke: theme.palette.text.primary,
|
|
191
|
-
},
|
|
192
189
|
},
|
|
193
190
|
sheetShellActionsFullPage: {
|
|
194
191
|
'& * > a, & * > button': {
|
|
@@ -340,6 +337,7 @@ export default function AppShellHeader(props: AppShellHeaderProps) {
|
|
|
340
337
|
{up?.href === router.asPath ? up?.title : 'Back'}
|
|
341
338
|
</Button>
|
|
342
339
|
)
|
|
340
|
+
|
|
343
341
|
if (!canClickBack && up?.href) {
|
|
344
342
|
back = (
|
|
345
343
|
<PageLink href={up?.href} passHref>
|
|
@@ -17,6 +17,7 @@ const useStyles = makeStyles(
|
|
|
17
17
|
alignItems: 'center',
|
|
18
18
|
[theme.breakpoints.down('xs')]: {
|
|
19
19
|
paddingTop: theme.spacings.lg,
|
|
20
|
+
paddingBottom: theme.spacings.lg,
|
|
20
21
|
justifyItems: 'center',
|
|
21
22
|
gridTemplateAreas: `
|
|
22
23
|
'switcher switcher'
|
|
@@ -45,7 +46,7 @@ const useStyles = makeStyles(
|
|
|
45
46
|
[theme.breakpoints.down('xs')]: {
|
|
46
47
|
gridAutoFlow: 'row',
|
|
47
48
|
textAlign: 'center',
|
|
48
|
-
gap:
|
|
49
|
+
gap: 4,
|
|
49
50
|
},
|
|
50
51
|
},
|
|
51
52
|
support: {
|
|
@@ -8,11 +8,11 @@ import ShellBase, { PageLayoutBaseProps } from './ShellBase'
|
|
|
8
8
|
const useStyles = makeStyles(
|
|
9
9
|
(theme: Theme) => ({
|
|
10
10
|
root: {
|
|
11
|
-
background: theme.palette.background.default,
|
|
12
11
|
minHeight: '100vh',
|
|
13
12
|
display: 'grid',
|
|
14
13
|
gridTemplateRows: `auto 1fr auto`,
|
|
15
14
|
gridTemplateColumns: '100%',
|
|
15
|
+
background: theme.palette.background.default,
|
|
16
16
|
},
|
|
17
17
|
hideFabsOnVirtualKeyboardOpen: {
|
|
18
18
|
[theme.breakpoints.down('sm')]: {
|
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
import { makeStyles, StyleRules, Theme } from '@material-ui/core'
|
|
13
13
|
import { useDomEvent } from 'framer-motion'
|
|
14
14
|
import { useRouter } from 'next/router'
|
|
15
|
-
import React, { useRef } from 'react'
|
|
15
|
+
import React, { useEffect, useRef, useState } from 'react'
|
|
16
16
|
import responsiveVal from '../../Styles/responsiveVal'
|
|
17
17
|
import AppShellProvider from '../AppShellProvider'
|
|
18
18
|
import ShellBase, { PageLayoutBaseProps } from '../ShellBase'
|
|
@@ -63,11 +63,15 @@ function SheetShellBase(props: SheetShellBaseProps) {
|
|
|
63
63
|
const { depth, closeSteps, active, direction } = usePageContext()
|
|
64
64
|
const open = depth < 0 || router.asPath === pageRouter.asPath
|
|
65
65
|
const initialLocale = useRef(router.locale)
|
|
66
|
+
const [isNavigating, setIsNavigating] = useState<boolean>(false)
|
|
66
67
|
|
|
67
68
|
function handleClose() {
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
69
|
+
if (!isNavigating) {
|
|
70
|
+
setIsNavigating(true)
|
|
71
|
+
return initialLocale.current !== router.locale
|
|
72
|
+
? pageRouter.push('/')
|
|
73
|
+
: pageRouter.go(closeSteps * -1)
|
|
74
|
+
}
|
|
71
75
|
}
|
|
72
76
|
|
|
73
77
|
function handleSnap(snapPoint: SnapPoint) {
|
|
@@ -4,8 +4,15 @@ import { ClassNameMap } from '@material-ui/styles'
|
|
|
4
4
|
|
|
5
5
|
type UseSheetStylesReturn = (props?: Record<string, unknown>) => ClassNameMap<ClassKeys>
|
|
6
6
|
|
|
7
|
-
const useSheetStyles = makeStyles<Theme, never, ClassKeys>(
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
const useSheetStyles = makeStyles<Theme, never, ClassKeys>(
|
|
8
|
+
(theme: Theme) => ({
|
|
9
|
+
...(styles as StyleRules<ClassKeys>),
|
|
10
|
+
content: {
|
|
11
|
+
...styles.content,
|
|
12
|
+
backgroundColor: theme.palette.background.default,
|
|
13
|
+
},
|
|
14
|
+
}),
|
|
15
|
+
{ name: 'Sheet' },
|
|
16
|
+
) as UseSheetStylesReturn
|
|
10
17
|
|
|
11
18
|
export default useSheetStyles
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { alpha, useTheme } from '@material-ui/core'
|
|
2
2
|
import { useMotionTemplate, useTransform, useViewportScroll } from 'framer-motion'
|
|
3
3
|
|
|
4
4
|
export default function useFixedFabAnimation() {
|
|
5
5
|
const theme = useTheme()
|
|
6
|
-
const isMobile = useMediaQuery(theme.breakpoints.down('sm'))
|
|
7
6
|
const { scrollY } = useViewportScroll()
|
|
8
|
-
const
|
|
9
|
-
const
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
7
|
+
const opacity = useTransform(scrollY, [50, 60], [0, 0.08])
|
|
8
|
+
const opacity1 = useTransform(
|
|
9
|
+
scrollY,
|
|
10
|
+
[0, 10],
|
|
11
|
+
[alpha(theme.palette.background.paper, 0), alpha(theme.palette.background.paper, 1)],
|
|
12
|
+
)
|
|
13
|
+
const boxShadow = useMotionTemplate`0 2px 10px 0 rgba(0, 0, 0, ${opacity})`
|
|
14
|
+
const backgroundColor = useMotionTemplate`${opacity1}`
|
|
15
|
+
return { boxShadow, backgroundColor, opacity }
|
|
16
16
|
}
|
package/Button/index.tsx
CHANGED
|
@@ -63,14 +63,11 @@ const useStyles = makeStyles<
|
|
|
63
63
|
textTransform: 'none',
|
|
64
64
|
...theme.typography.body2,
|
|
65
65
|
fontWeight: 400,
|
|
66
|
-
padding: `${responsiveVal(8, 10)} ${responsiveVal(
|
|
66
|
+
padding: `${responsiveVal(8, 10)} ${responsiveVal(16, 20)}`,
|
|
67
67
|
backgroundColor: theme.palette.secondary.main,
|
|
68
68
|
color: theme.palette.primary.contrastText,
|
|
69
69
|
borderRadius: '99em',
|
|
70
70
|
boxShadow: theme.shadows[1],
|
|
71
|
-
'& svg': {
|
|
72
|
-
stroke: theme.palette.primary.contrastText,
|
|
73
|
-
},
|
|
74
71
|
'&:hover': {
|
|
75
72
|
background: theme.palette.secondary.dark,
|
|
76
73
|
},
|
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,75 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [3.17.1](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/next-ui@3.17.0...@graphcommerce/next-ui@3.17.1) (2021-11-12)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Bug Fixes
|
|
10
|
+
|
|
11
|
+
* disable CartFab animation for mobile ([ea04e67](https://github.com/ho-nl/m2-pwa/commit/ea04e678b7d5ab23e903a59a7f369053d17f9e79))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
# [3.17.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/next-ui@3.16.0...@graphcommerce/next-ui@3.17.0) (2021-11-12)
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
### Features
|
|
21
|
+
|
|
22
|
+
* added tons of translations ([9bb0ac7](https://github.com/ho-nl/m2-pwa/commit/9bb0ac709b58df6ea6141e92e4923a5ca9ae2963))
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
# [3.16.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/next-ui@3.15.2...@graphcommerce/next-ui@3.16.0) (2021-11-12)
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
### Bug Fixes
|
|
32
|
+
|
|
33
|
+
* Accessibility: Tap targets are sized appropriately ([55177f0](https://github.com/ho-nl/m2-pwa/commit/55177f03e79a29a879022ed34439e6c7aebbd80e))
|
|
34
|
+
* behaviour for CartFab animation including darkTheme support ([6152ef3](https://github.com/ho-nl/m2-pwa/commit/6152ef32d093e42c58ee79d4d713c5b8c2870746))
|
|
35
|
+
* clean up themeProvider ([6868e71](https://github.com/ho-nl/m2-pwa/commit/6868e71b59a637be8229a2ab49791dd324e02bb9))
|
|
36
|
+
* darkTheme ([b08f522](https://github.com/ho-nl/m2-pwa/commit/b08f52255c91dcba5498481ba5e9f0fa0b6c5013))
|
|
37
|
+
* darkTheme proof background color for sheet ([2af3b4a](https://github.com/ho-nl/m2-pwa/commit/2af3b4a6b7115400c5bbed36a21cd48852bea122))
|
|
38
|
+
* design ([a8e2888](https://github.com/ho-nl/m2-pwa/commit/a8e288856011ca7d8fdcb75d7c672629a8f8bcf4))
|
|
39
|
+
* design ([2dd5f41](https://github.com/ho-nl/m2-pwa/commit/2dd5f415010d19549158d837f0f98497d350fc2d))
|
|
40
|
+
* fab animation should be background paper ([b538f96](https://github.com/ho-nl/m2-pwa/commit/b538f963b6c45a3973b11abe8de7823f2864326b))
|
|
41
|
+
* hex for darktheme paper value, so calculations can be made ([c93bb22](https://github.com/ho-nl/m2-pwa/commit/c93bb22ba287c85ad5c27fd5f13d82dbb9a7d16f))
|
|
42
|
+
* icon style ([6b9fea9](https://github.com/ho-nl/m2-pwa/commit/6b9fea9112206bb38b419e8257ad1b2b3fad74b6))
|
|
43
|
+
* pagination color not primary ([c4e6d4f](https://github.com/ho-nl/m2-pwa/commit/c4e6d4f35d2df7a93fe045bde6c015fbcc5e5089))
|
|
44
|
+
* perfectly spaced video ([f1481ed](https://github.com/ho-nl/m2-pwa/commit/f1481edaf08564315a8c6f50fa1a500bbdc58fc5))
|
|
45
|
+
* prevent video casting on android ([a8baf94](https://github.com/ho-nl/m2-pwa/commit/a8baf949283c854283fe32befae4a60b119e02e0))
|
|
46
|
+
* remove unused wrapping div ([6ced7b9](https://github.com/ho-nl/m2-pwa/commit/6ced7b912229303a9d708db1d2621f50f431c73f))
|
|
47
|
+
* replace value with headerInnerHeight ([656fedc](https://github.com/ho-nl/m2-pwa/commit/656fedc573bbdd941c34e05e4dcd9a6af49fe987))
|
|
48
|
+
* replace value with headerInnerHeight ([d961720](https://github.com/ho-nl/m2-pwa/commit/d9617200d375a9db98f7f1c3b47a5927764dae71))
|
|
49
|
+
* revert background changes ([7661670](https://github.com/ho-nl/m2-pwa/commit/76616703968099039d79a4ca6001b942684adda5))
|
|
50
|
+
* set sheet backgroundColor to background.default ([5d3f971](https://github.com/ho-nl/m2-pwa/commit/5d3f9719b446ee9440ac8834679ef5ba14be53d4))
|
|
51
|
+
* text color iconBlock and styling ([0f2b0a8](https://github.com/ho-nl/m2-pwa/commit/0f2b0a896b11eafb79ea045c44f0115649a2040e))
|
|
52
|
+
* use alpha to set rgba value of theme variable ([aebee87](https://github.com/ho-nl/m2-pwa/commit/aebee87b32eb769c6454ad9ced10d5612c4d1af8))
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
### Features
|
|
56
|
+
|
|
57
|
+
* provide all (different type of) overlays with the default background color ([111fe71](https://github.com/ho-nl/m2-pwa/commit/111fe718fbfddbeef452829e08b574ca46d51345))
|
|
58
|
+
* remove svg stroke definitions, set all to currentColor ([189814f](https://github.com/ho-nl/m2-pwa/commit/189814f822d111c8adc6be1fff65c9a4a4c50c65))
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+
## [3.15.2](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/next-ui@3.15.1...@graphcommerce/next-ui@3.15.2) (2021-11-12)
|
|
65
|
+
|
|
66
|
+
|
|
67
|
+
### Bug Fixes
|
|
68
|
+
|
|
69
|
+
* **sheet-shell-base:** prevent sheet backdrop from navigating back multiple times ([5ca2f7e](https://github.com/ho-nl/m2-pwa/commit/5ca2f7e0d3404501a6b5763daf1d442c8080f8cb))
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
|
|
73
|
+
|
|
74
|
+
|
|
6
75
|
## [3.15.1](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/next-ui@3.15.0...@graphcommerce/next-ui@3.15.1) (2021-11-11)
|
|
7
76
|
|
|
8
77
|
|
package/ChipMenu/index.tsx
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Chip, ChipProps, makeStyles, Menu, Theme } from '@material-ui/core'
|
|
1
|
+
import { Chip, ChipProps, lighten, makeStyles, Menu, Theme } from '@material-ui/core'
|
|
2
2
|
import clsx from 'clsx'
|
|
3
3
|
import React, { PropsWithChildren, useState } from 'react'
|
|
4
4
|
import SectionHeader from '../SectionHeader'
|
|
@@ -8,7 +8,9 @@ import { iconChevronDown, iconChevronUp, iconCancelAlt } from '../icons'
|
|
|
8
8
|
|
|
9
9
|
export const useChipMenuStyles = makeStyles(
|
|
10
10
|
(theme: Theme) => ({
|
|
11
|
-
chip: {
|
|
11
|
+
chip: {
|
|
12
|
+
background: `${theme.palette.background.default} !important`,
|
|
13
|
+
},
|
|
12
14
|
chipSelected: {
|
|
13
15
|
borderColor: theme.palette.text.primary,
|
|
14
16
|
color: theme.palette.text.primary,
|
|
@@ -19,9 +21,6 @@ export const useChipMenuStyles = makeStyles(
|
|
|
19
21
|
'&:focus': {
|
|
20
22
|
background: `${theme.palette.background.paper} !important`,
|
|
21
23
|
},
|
|
22
|
-
'& svg': {
|
|
23
|
-
stroke: theme.palette.text.primary,
|
|
24
|
-
},
|
|
25
24
|
},
|
|
26
25
|
menuPaper: {
|
|
27
26
|
minWidth: responsiveVal(200, 560),
|
|
@@ -23,16 +23,12 @@ const useStyles = makeStyles(
|
|
|
23
23
|
textAlign: 'center',
|
|
24
24
|
marginTop: theme.spacings.sm,
|
|
25
25
|
},
|
|
26
|
-
|
|
27
26
|
button: {
|
|
28
27
|
marginTop: theme.spacings.sm,
|
|
29
28
|
},
|
|
30
29
|
altButton: {
|
|
31
30
|
marginTop: 6,
|
|
32
31
|
},
|
|
33
|
-
icon: {
|
|
34
|
-
height: responsiveVal(120, 180),
|
|
35
|
-
},
|
|
36
32
|
}),
|
|
37
33
|
{ name: 'FullPageMessage' },
|
|
38
34
|
)
|
|
@@ -53,7 +49,7 @@ export default function FullPageMessage(props: FullPageMessageProps) {
|
|
|
53
49
|
return (
|
|
54
50
|
<div className={clsx(classes.root, disableMargin || classes.rootMargin)}>
|
|
55
51
|
<Container maxWidth='md' className={classes.innerContainer}>
|
|
56
|
-
<div
|
|
52
|
+
<div>{icon}</div>
|
|
57
53
|
|
|
58
54
|
<div className={classes.subject}>
|
|
59
55
|
<Typography variant='h3' gutterBottom>
|
package/Pagination/index.tsx
CHANGED
|
@@ -17,9 +17,6 @@ const useStyles = makeStyles((theme: Theme) => ({
|
|
|
17
17
|
gap: 6,
|
|
18
18
|
'& .Mui-disabled': {
|
|
19
19
|
background: 'none',
|
|
20
|
-
'& svg': {
|
|
21
|
-
stroke: theme.palette.text.disabled,
|
|
22
|
-
},
|
|
23
20
|
},
|
|
24
21
|
},
|
|
25
22
|
pagination: {
|
|
@@ -38,6 +35,9 @@ const useStyles = makeStyles((theme: Theme) => ({
|
|
|
38
35
|
boxShadow: 'none',
|
|
39
36
|
},
|
|
40
37
|
},
|
|
38
|
+
fab: {
|
|
39
|
+
color: theme.palette.text.primary,
|
|
40
|
+
},
|
|
41
41
|
}))
|
|
42
42
|
|
|
43
43
|
export type PagePaginationProps = {
|
|
@@ -66,13 +66,25 @@ export default function Pagination(props: PagePaginationProps) {
|
|
|
66
66
|
const nextBtnProps = items[items.length - 1]
|
|
67
67
|
|
|
68
68
|
const chevronLeft = (
|
|
69
|
-
<Fab
|
|
69
|
+
<Fab
|
|
70
|
+
size='medium'
|
|
71
|
+
disabled={page === 1}
|
|
72
|
+
color='inherit'
|
|
73
|
+
aria-label='Previous page'
|
|
74
|
+
className={classes.fab}
|
|
75
|
+
>
|
|
70
76
|
<SvgImageSimple src={iconChevronLeft} />
|
|
71
77
|
</Fab>
|
|
72
78
|
)
|
|
73
79
|
|
|
74
80
|
const chevronRight = (
|
|
75
|
-
<Fab
|
|
81
|
+
<Fab
|
|
82
|
+
size='medium'
|
|
83
|
+
disabled={page === count}
|
|
84
|
+
color='inherit'
|
|
85
|
+
aria-label='Next page'
|
|
86
|
+
className={classes.fab}
|
|
87
|
+
>
|
|
76
88
|
<SvgImageSimple src={iconChevronRight} />
|
|
77
89
|
</Fab>
|
|
78
90
|
)
|
package/Row/HeroBanner/index.tsx
CHANGED
|
@@ -22,13 +22,19 @@ const useStyles = makeStyles(
|
|
|
22
22
|
justifyItems: 'center',
|
|
23
23
|
alignContent: 'center',
|
|
24
24
|
padding: `${theme.spacings.lg} ${theme.spacings.md}`,
|
|
25
|
-
minHeight:
|
|
25
|
+
minHeight: `calc(100vh - ${theme.page.headerInnerHeight.sm})`,
|
|
26
26
|
'& > *': {
|
|
27
27
|
zIndex: 1,
|
|
28
28
|
maxWidth: 'max-content',
|
|
29
29
|
},
|
|
30
|
+
[theme.breakpoints.down('sm')]: {
|
|
31
|
+
['@supports (-webkit-touch-callout: none)']: {
|
|
32
|
+
minHeight: '-webkit-fill-available',
|
|
33
|
+
},
|
|
34
|
+
},
|
|
30
35
|
[theme.breakpoints.up('md')]: {
|
|
31
36
|
width: '70%',
|
|
37
|
+
minHeight: `calc(100vh - ${theme.page.headerInnerHeight.md})`,
|
|
32
38
|
},
|
|
33
39
|
[theme.breakpoints.up('lg')]: {
|
|
34
40
|
padding: `${theme.spacings.lg} ${theme.spacings.lg}`,
|
|
@@ -44,6 +50,7 @@ const useStyles = makeStyles(
|
|
|
44
50
|
display: 'grid',
|
|
45
51
|
justifyItems: 'center',
|
|
46
52
|
overflow: 'hidden',
|
|
53
|
+
paddingBottom: theme.spacings.md,
|
|
47
54
|
'& video': {
|
|
48
55
|
objectFit: 'cover',
|
|
49
56
|
width: '100%',
|
|
@@ -83,14 +90,9 @@ export default function HeroBanner(props: HeroBannerProps) {
|
|
|
83
90
|
{pageLinks}
|
|
84
91
|
</div>
|
|
85
92
|
<div className={classes.asset}>
|
|
86
|
-
<m.
|
|
87
|
-
src={videoSrc}
|
|
88
|
-
|
|
89
|
-
muted
|
|
90
|
-
loop
|
|
91
|
-
playsInline
|
|
92
|
-
style={{ width: actionsAnimWidth }}
|
|
93
|
-
/>
|
|
93
|
+
<m.div style={{ width: actionsAnimWidth }}>
|
|
94
|
+
<video src={videoSrc} autoPlay muted loop playsInline disableRemotePlayback />
|
|
95
|
+
</m.div>
|
|
94
96
|
</div>
|
|
95
97
|
</div>
|
|
96
98
|
</Row>
|
|
@@ -6,19 +6,24 @@ import { UseStyles } from '../../../Styles'
|
|
|
6
6
|
const useStyles = makeStyles(
|
|
7
7
|
(theme: Theme) => ({
|
|
8
8
|
block: {
|
|
9
|
-
display: 'grid',
|
|
10
|
-
gridAutoFlow: 'row',
|
|
11
|
-
justifyItems: 'center',
|
|
12
|
-
gap: `${theme.spacings.xs}`,
|
|
13
9
|
border: `1px solid ${theme.palette.divider}`,
|
|
14
10
|
padding: `${theme.spacings.sm}`,
|
|
15
11
|
borderRadius: '6px',
|
|
16
12
|
textAlign: 'center',
|
|
17
|
-
color: theme.palette.primary
|
|
13
|
+
color: theme.palette.text.primary,
|
|
14
|
+
'& > * > *': {
|
|
15
|
+
display: 'grid',
|
|
16
|
+
gridAutoFlow: 'row',
|
|
17
|
+
justifyItems: 'center',
|
|
18
|
+
gap: `${theme.spacings.xxs}`,
|
|
19
|
+
},
|
|
18
20
|
},
|
|
19
21
|
link: {
|
|
20
22
|
textDecoration: 'none',
|
|
21
23
|
},
|
|
24
|
+
title: {
|
|
25
|
+
fontWeight: theme.typography.fontWeightBold,
|
|
26
|
+
},
|
|
22
27
|
}),
|
|
23
28
|
{ name: 'IconBlock' },
|
|
24
29
|
)
|
|
@@ -37,7 +42,9 @@ const IconBlock = React.forwardRef<HTMLAnchorElement, IconBlockProps>((props, re
|
|
|
37
42
|
const content = (
|
|
38
43
|
<>
|
|
39
44
|
{icon}
|
|
40
|
-
<Typography variant='
|
|
45
|
+
<Typography variant='subtitle1' className={classes.title}>
|
|
46
|
+
{title}
|
|
47
|
+
</Typography>
|
|
41
48
|
{children}
|
|
42
49
|
</>
|
|
43
50
|
)
|
|
@@ -7,7 +7,7 @@ const useStyles = makeStyles(
|
|
|
7
7
|
(theme: Theme) => ({
|
|
8
8
|
wrapper: {
|
|
9
9
|
display: 'grid',
|
|
10
|
-
background:
|
|
10
|
+
background: theme.palette.background.paper,
|
|
11
11
|
justifyItems: 'center',
|
|
12
12
|
columnGap: `${theme.spacings.lg}`,
|
|
13
13
|
padding: `${theme.spacings.lg} 0`,
|
|
@@ -23,6 +23,7 @@ const useStyles = makeStyles(
|
|
|
23
23
|
asset: {
|
|
24
24
|
width: responsiveVal(200, 900),
|
|
25
25
|
height: 'auto',
|
|
26
|
+
marginBottom: theme.spacings.md,
|
|
26
27
|
'& img': {
|
|
27
28
|
width: responsiveVal(200, 900),
|
|
28
29
|
height: 'auto',
|
|
@@ -16,13 +16,14 @@ const useStyles = makeStyles(
|
|
|
16
16
|
strokeLinecap: 'square',
|
|
17
17
|
strokeLinejoin: 'miter',
|
|
18
18
|
fill: 'none',
|
|
19
|
+
stroke: 'currentColor',
|
|
19
20
|
},
|
|
20
21
|
sizeInherit: {
|
|
21
22
|
fontSize: 'inherit',
|
|
22
23
|
},
|
|
23
24
|
sizeSmall: {
|
|
24
|
-
width: responsiveVal(
|
|
25
|
-
height: responsiveVal(
|
|
25
|
+
width: responsiveVal(12, 16),
|
|
26
|
+
height: responsiveVal(12, 16),
|
|
26
27
|
strokeWidth: 2.3,
|
|
27
28
|
},
|
|
28
29
|
sizeLarge: {
|
package/ToggleButton/index.tsx
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// @inheritedComponent ButtonBase
|
|
2
2
|
|
|
3
|
-
import { capitalize, makeStyles, Theme } from '@material-ui/core'
|
|
3
|
+
import { capitalize, lighten, makeStyles, Theme } from '@material-ui/core'
|
|
4
4
|
import clsx from 'clsx'
|
|
5
5
|
import React, { FormEvent } from 'react'
|
|
6
6
|
import Button, { ButtonProps } from '../Button'
|
|
@@ -13,7 +13,10 @@ export const useStyles = makeStyles(
|
|
|
13
13
|
/* Styles applied to the root element. */
|
|
14
14
|
root: {
|
|
15
15
|
border: '2px solid transparent',
|
|
16
|
-
backgroundColor:
|
|
16
|
+
backgroundColor:
|
|
17
|
+
theme.palette.type === 'light'
|
|
18
|
+
? theme.palette.background.default
|
|
19
|
+
: lighten(theme.palette.background.default, theme.palette.action.hoverOpacity),
|
|
17
20
|
borderRadius: 4,
|
|
18
21
|
// boxShadow: theme.shadows['1'],
|
|
19
22
|
boxShadow: `0px 0px 2px ${theme.palette.grey[400]}`,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@graphcommerce/next-ui",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.17.1",
|
|
4
4
|
"author": "",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"scripts": {
|
|
@@ -10,13 +10,13 @@
|
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@apollo/client": "^3.4.16",
|
|
13
|
-
"@graphcommerce/framer-next-pages": "^2.107.
|
|
14
|
-
"@graphcommerce/framer-scroller": "^1.0.
|
|
15
|
-
"@graphcommerce/framer-sheet": "^2.106.
|
|
16
|
-
"@graphcommerce/framer-utils": "^2.103.
|
|
17
|
-
"@graphcommerce/graphql": "^2.105.
|
|
18
|
-
"@graphcommerce/image": "^2.105.
|
|
19
|
-
"@
|
|
13
|
+
"@graphcommerce/framer-next-pages": "^2.107.5",
|
|
14
|
+
"@graphcommerce/framer-scroller": "^1.0.4",
|
|
15
|
+
"@graphcommerce/framer-sheet": "^2.106.2",
|
|
16
|
+
"@graphcommerce/framer-utils": "^2.103.15",
|
|
17
|
+
"@graphcommerce/graphql": "^2.105.5",
|
|
18
|
+
"@graphcommerce/image": "^2.105.4",
|
|
19
|
+
"@lingui/macro": "^3.12.1",
|
|
20
20
|
"@material-ui/core": "^4.12.3",
|
|
21
21
|
"@material-ui/lab": "^4.0.0-alpha.60",
|
|
22
22
|
"@material-ui/styles": "^4.11.4",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
},
|
|
35
35
|
"devDependencies": {
|
|
36
36
|
"@graphcommerce/browserslist-config-pwa": "^3.0.2",
|
|
37
|
-
"@graphcommerce/eslint-config-pwa": "^3.1.
|
|
37
|
+
"@graphcommerce/eslint-config-pwa": "^3.1.5",
|
|
38
38
|
"@graphcommerce/prettier-config-pwa": "^3.0.4",
|
|
39
39
|
"@graphcommerce/typescript-config-pwa": "^3.1.1",
|
|
40
40
|
"@playwright/test": "^1.16.2",
|
|
@@ -53,5 +53,5 @@
|
|
|
53
53
|
"project": "./tsconfig.json"
|
|
54
54
|
}
|
|
55
55
|
},
|
|
56
|
-
"gitHead": "
|
|
56
|
+
"gitHead": "e8578cc336e58d896531179f5fcb6973e8a983ce"
|
|
57
57
|
}
|