@graphcommerce/magento-cart 4.0.1 → 4.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,29 @@
1
1
  # Change Log
2
2
 
3
+ ## 4.1.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#1273](https://github.com/ho-nl/m2-pwa/pull/1273)
8
+ [`8c4e4f7cd`](https://github.com/ho-nl/m2-pwa/commit/8c4e4f7cdd2fa4252788fbc9889d0803bba20eef)
9
+ Thanks [@paales](https://github.com/paales)! - Added darkmode support! ☀️🌑, adds a toggle to the
10
+ hamburger menu.
11
+
12
+ ### Patch Changes
13
+
14
+ - [#1271](https://github.com/ho-nl/m2-pwa/pull/1271)
15
+ [`e0008d60d`](https://github.com/ho-nl/m2-pwa/commit/e0008d60d712603219129dd411d1985bf1ebbed1)
16
+ Thanks [@paales](https://github.com/paales)! - make sure the CartFab and MenuFab are stylable with
17
+ sx
18
+
19
+ - Updated dependencies
20
+ [[`e0008d60d`](https://github.com/ho-nl/m2-pwa/commit/e0008d60d712603219129dd411d1985bf1ebbed1),
21
+ [`5d9f8320f`](https://github.com/ho-nl/m2-pwa/commit/5d9f8320ff9621d7357fbe01319ab0cafdf9095d),
22
+ [`8c4e4f7cd`](https://github.com/ho-nl/m2-pwa/commit/8c4e4f7cdd2fa4252788fbc9889d0803bba20eef),
23
+ [`5082b8c81`](https://github.com/ho-nl/m2-pwa/commit/5082b8c8191cc3e0b4627678bf837af093513d57)]:
24
+ - @graphcommerce/next-ui@4.1.0
25
+ - @graphcommerce/magento-customer@4.1.0
26
+
3
27
  ## 4.0.1
4
28
 
5
29
  ### Patch Changes
@@ -7,7 +7,7 @@ import {
7
7
  useScrollY,
8
8
  } from '@graphcommerce/next-ui'
9
9
  import { t } from '@lingui/macro'
10
- import { alpha, Fab, FabProps, NoSsr, styled, useTheme, Box } from '@mui/material'
10
+ import { alpha, Fab, FabProps, NoSsr, styled, useTheme, Box, SxProps, Theme } from '@mui/material'
11
11
  import { m, useTransform } from 'framer-motion'
12
12
  import PageLink from 'next/link'
13
13
  import React from 'react'
@@ -17,6 +17,7 @@ import { CartTotalQuantityFragment } from './CartTotalQuantity.gql'
17
17
 
18
18
  export type CartFabProps = {
19
19
  icon?: React.ReactNode
20
+ sx?: SxProps<Theme>
20
21
  }
21
22
 
22
23
  type CartFabContentProps = CartFabProps & CartTotalQuantityFragment
@@ -32,7 +33,7 @@ const MotionFab = m(
32
33
  const { classes } = extendableComponent('CartFab', ['root', 'cart', 'shadow'] as const)
33
34
 
34
35
  function CartFabContent(props: CartFabContentProps) {
35
- const { total_quantity, icon, ...fabProps } = props
36
+ const { total_quantity, icon, sx = [], ...fabProps } = props
36
37
 
37
38
  const theme2 = useTheme()
38
39
  const scrollY = useScrollY()
@@ -48,7 +49,10 @@ function CartFabContent(props: CartFabContentProps) {
48
49
  return (
49
50
  <Box
50
51
  className={classes.root}
51
- sx={{ position: 'relative', width: fabIconSize, height: fabIconSize }}
52
+ sx={[
53
+ { position: 'relative', width: fabIconSize, height: fabIconSize },
54
+ ...(Array.isArray(sx) ? sx : [sx]),
55
+ ]}
52
56
  >
53
57
  <PageLink href='/cart' passHref>
54
58
  <MotionFab
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@graphcommerce/magento-cart",
3
3
  "homepage": "https://www.graphcommerce.org/",
4
4
  "repository": "github:graphcommerce-org/graphcommerce",
5
- "version": "4.0.1",
5
+ "version": "4.1.0",
6
6
  "sideEffects": false,
7
7
  "prettier": "@graphcommerce/prettier-config-pwa",
8
8
  "eslintConfig": {
@@ -22,10 +22,10 @@
22
22
  "@graphcommerce/framer-scroller": "^2.0.1",
23
23
  "@graphcommerce/graphql": "^3.0.1",
24
24
  "@graphcommerce/image": "^3.0.1",
25
- "@graphcommerce/magento-customer": "^4.0.1",
25
+ "@graphcommerce/magento-customer": "^4.1.0",
26
26
  "@graphcommerce/magento-graphql": "^3.0.1",
27
27
  "@graphcommerce/magento-store": "^4.0.1",
28
- "@graphcommerce/next-ui": "^4.0.1",
28
+ "@graphcommerce/next-ui": "^4.1.0",
29
29
  "@graphcommerce/react-hook-form": "^3.0.1",
30
30
  "@lingui/macro": "^3.13.2",
31
31
  "@mui/material": "^5.4.1",