@graphcommerce/mollie-magento-payment 2.106.47 → 3.0.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/CHANGELOG.md CHANGED
@@ -1,115 +1,121 @@
1
1
  # Change Log
2
2
 
3
- All notable changes to this project will be documented in this file.
4
- See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
3
+ ## 3.0.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [`0cbaa878b`](https://github.com/ho-nl/m2-pwa/commit/0cbaa878b8a844d5abbeb1797b625a33130e6514)
8
+ Thanks [@paales](https://github.com/paales)! - Added homepage and repository package.json files,
9
+ so that the packages link to back to the website and repository
10
+ - Updated dependencies
11
+ [[`0cbaa878b`](https://github.com/ho-nl/m2-pwa/commit/0cbaa878b8a844d5abbeb1797b625a33130e6514)]:
12
+ - @graphcommerce/graphql@3.0.1
13
+ - @graphcommerce/image@3.0.1
14
+ - @graphcommerce/magento-cart@4.0.1
15
+ - @graphcommerce/magento-cart-payment-method@3.0.1
16
+ - @graphcommerce/magento-store@4.0.1
17
+ - @graphcommerce/next-ui@4.0.1
18
+ - @graphcommerce/react-hook-form@3.0.1
19
+
20
+ ## 3.0.0
21
+
22
+ ### Major Changes
23
+
24
+ - [#1258](https://github.com/ho-nl/m2-pwa/pull/1258)
25
+ [`ad36382a4`](https://github.com/ho-nl/m2-pwa/commit/ad36382a4d55d83d9e47b7eb6a02671a2a631a05)
26
+ Thanks [@paales](https://github.com/paales)! - Upgraded to Material UI 5
27
+
28
+ ### Patch Changes
29
+
30
+ - Updated dependencies
31
+ [[`ad36382a4`](https://github.com/ho-nl/m2-pwa/commit/ad36382a4d55d83d9e47b7eb6a02671a2a631a05)]:
32
+ - @graphcommerce/graphql@3.0.0
33
+ - @graphcommerce/image@3.0.0
34
+ - @graphcommerce/magento-cart@4.0.0
35
+ - @graphcommerce/magento-cart-payment-method@3.0.0
36
+ - @graphcommerce/magento-store@4.0.0
37
+ - @graphcommerce/next-ui@4.0.0
38
+ - @graphcommerce/react-hook-form@3.0.0
5
39
 
6
- ## [2.106.24](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/mollie-magento-payment@2.106.23...@graphcommerce/mollie-magento-payment@2.106.24) (2021-12-20)
40
+ All notable changes to this project will be documented in this file. See
41
+ [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
7
42
 
43
+ ## [2.106.24](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/mollie-magento-payment@2.106.23...@graphcommerce/mollie-magento-payment@2.106.24) (2021-12-20)
8
44
 
9
45
  ### Bug Fixes
10
46
 
11
- * animations would run on background page, make sure animations are not running when page is not active ([2fcf4b8](https://github.com/ho-nl/m2-pwa/commit/2fcf4b8a853108147477e3a67c7ea202abb2842f))
12
-
13
-
14
-
15
-
47
+ - animations would run on background page, make sure animations are not running when page is not
48
+ active
49
+ ([2fcf4b8](https://github.com/ho-nl/m2-pwa/commit/2fcf4b8a853108147477e3a67c7ea202abb2842f))
16
50
 
17
51
  # [2.106.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/mollie-magento-payment@2.105.32...@graphcommerce/mollie-magento-payment@2.106.0) (2021-11-12)
18
52
 
19
-
20
53
  ### Features
21
54
 
22
- * added tons of translations ([9bb0ac7](https://github.com/ho-nl/m2-pwa/commit/9bb0ac709b58df6ea6141e92e4923a5ca9ae2963))
23
-
24
-
25
-
26
-
55
+ - added tons of translations
56
+ ([9bb0ac7](https://github.com/ho-nl/m2-pwa/commit/9bb0ac709b58df6ea6141e92e4923a5ca9ae2963))
27
57
 
28
58
  ## [2.105.9](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/mollie-magento-payment@2.105.8...@graphcommerce/mollie-magento-payment@2.105.9) (2021-11-02)
29
59
 
30
-
31
60
  ### Bug Fixes
32
61
 
33
- * input labels ([ba46c9a](https://github.com/ho-nl/m2-pwa/commit/ba46c9a17b3b460daab5015df39ac9ae66858df4))
34
- * overlapping checkmark icon ([b4da61a](https://github.com/ho-nl/m2-pwa/commit/b4da61ae33ab058a56f0f32c2874a2e77d77d01d))
35
-
36
-
37
-
38
-
62
+ - input labels
63
+ ([ba46c9a](https://github.com/ho-nl/m2-pwa/commit/ba46c9a17b3b460daab5015df39ac9ae66858df4))
64
+ - overlapping checkmark icon
65
+ ([b4da61a](https://github.com/ho-nl/m2-pwa/commit/b4da61ae33ab058a56f0f32c2874a2e77d77d01d))
39
66
 
40
67
  # [2.105.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/mollie-magento-payment@2.104.33...@graphcommerce/mollie-magento-payment@2.105.0) (2021-10-27)
41
68
 
42
-
43
69
  ### Features
44
70
 
45
- * **nextjs:** upgraded to nextjs 12 ([9331bc8](https://github.com/ho-nl/m2-pwa/commit/9331bc801f6419522115cc47d291d49d608d5a90))
46
-
47
-
48
-
49
-
71
+ - **nextjs:** upgraded to nextjs 12
72
+ ([9331bc8](https://github.com/ho-nl/m2-pwa/commit/9331bc801f6419522115cc47d291d49d608d5a90))
50
73
 
51
74
  ## [2.104.13](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/mollie-magento-payment@2.104.12...@graphcommerce/mollie-magento-payment@2.104.13) (2021-10-08)
52
75
 
53
-
54
76
  ### Bug Fixes
55
77
 
56
- * **mollie:** make sure we're redirected to the success page ([316d2b2](https://github.com/ho-nl/m2-pwa/commit/316d2b2a99189f093e74db98521c27e8e7267dd4))
57
-
58
-
59
-
60
-
78
+ - **mollie:** make sure we're redirected to the success page
79
+ ([316d2b2](https://github.com/ho-nl/m2-pwa/commit/316d2b2a99189f093e74db98521c27e8e7267dd4))
61
80
 
62
81
  ## [2.104.11](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/mollie-magento-payment@2.104.10...@graphcommerce/mollie-magento-payment@2.104.11) (2021-10-07)
63
82
 
64
-
65
83
  ### Bug Fixes
66
84
 
67
- * make sure if no payment method is filled in we get an error shown ([a203e57](https://github.com/ho-nl/m2-pwa/commit/a203e570caad0732427a178e8e8b10b4a15d676b))
68
-
69
-
70
-
71
-
85
+ - make sure if no payment method is filled in we get an error shown
86
+ ([a203e57](https://github.com/ho-nl/m2-pwa/commit/a203e570caad0732427a178e8e8b10b4a15d676b))
72
87
 
73
88
  # 2.104.0 (2021-09-29)
74
89
 
75
-
76
90
  ### Bug Fixes
77
91
 
78
- * make sure mollie only gets build optionally ([e5e2347](https://github.com/ho-nl/m2-pwa/commit/e5e23475e170dc2fc0c13103dfb8fbdb9009715f))
79
- * make sure the mollie module doesn't start with magento- to prevent building from node moduels ([ed406b9](https://github.com/ho-nl/m2-pwa/commit/ed406b9f56bd8cb5df0463cc50e4b1e9a728d4ca))
80
-
92
+ - make sure mollie only gets build optionally
93
+ ([e5e2347](https://github.com/ho-nl/m2-pwa/commit/e5e23475e170dc2fc0c13103dfb8fbdb9009715f))
94
+ - make sure the mollie module doesn't start with magento- to prevent building from node moduels
95
+ ([ed406b9](https://github.com/ho-nl/m2-pwa/commit/ed406b9f56bd8cb5df0463cc50e4b1e9a728d4ca))
81
96
 
82
97
  ### Features
83
98
 
84
- * renamed all packages to use [@graphcommerce](https://github.com/graphcommerce) instead of [@reachdigital](https://github.com/reachdigital) ([491e4ce](https://github.com/ho-nl/m2-pwa/commit/491e4cec9a2686472dac36b79f999257c0811ffe))
85
-
86
-
87
-
88
-
99
+ - renamed all packages to use [@graphcommerce](https://github.com/graphcommerce) instead of
100
+ [@reachdigital](https://github.com/reachdigital)
101
+ ([491e4ce](https://github.com/ho-nl/m2-pwa/commit/491e4cec9a2686472dac36b79f999257c0811ffe))
89
102
 
90
103
  ## [2.103.1](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-payment-mollie@2.103.0...@graphcommerce/magento-payment-mollie@2.103.1) (2021-09-27)
91
104
 
92
105
  **Note:** Version bump only for package @graphcommerce/magento-payment-mollie
93
106
 
94
-
95
-
96
-
97
-
98
107
  # 2.103.0 (2021-09-27)
99
108
 
100
-
101
109
  ### Bug Fixes
102
110
 
103
- * make sure mollie only gets build optionally ([e5e2347](https://github.com/ho-nl/m2-pwa/commit/e5e23475e170dc2fc0c13103dfb8fbdb9009715f))
104
-
111
+ - make sure mollie only gets build optionally
112
+ ([e5e2347](https://github.com/ho-nl/m2-pwa/commit/e5e23475e170dc2fc0c13103dfb8fbdb9009715f))
105
113
 
106
114
  ### Features
107
115
 
108
- * renamed all packages to use [@graphcommerce](https://github.com/graphcommerce) instead of [@reachdigital](https://github.com/reachdigital) ([491e4ce](https://github.com/ho-nl/m2-pwa/commit/491e4cec9a2686472dac36b79f999257c0811ffe))
109
-
110
-
111
-
112
-
116
+ - renamed all packages to use [@graphcommerce](https://github.com/graphcommerce) instead of
117
+ [@reachdigital](https://github.com/reachdigital)
118
+ ([491e4ce](https://github.com/ho-nl/m2-pwa/commit/491e4cec9a2686472dac36b79f999257c0811ffe))
113
119
 
114
120
  # Change Log
115
121
 
@@ -1,29 +1,20 @@
1
1
  import { useFormGqlMutationCart } from '@graphcommerce/magento-cart'
2
2
  import { PaymentOptionsProps } from '@graphcommerce/magento-cart-payment-method'
3
- import { FormRow, InputCheckmark } from '@graphcommerce/next-ui'
3
+ import { extendableComponent, FormRow, InputCheckmark } from '@graphcommerce/next-ui'
4
4
  import { useFormCompose, useFormPersist, useFormValidFields } from '@graphcommerce/react-hook-form'
5
5
  import { Trans } from '@lingui/macro'
6
- import { makeStyles, TextField, Theme, Typography } from '@material-ui/core'
7
- import React from 'react'
6
+ import { Box, TextField, Typography } from '@mui/material'
8
7
  import { SetMolliePaymentMethodIssuerOnCartDocument } from './SetMolliePaymentMethodIssuerOnCart.gql'
9
8
 
10
9
  type MollieIssuerOptionsProps = PaymentOptionsProps & { label: string }
11
10
 
12
- const useStyles = makeStyles(
13
- (theme: Theme) => ({
14
- root: {
15
- ...theme.typography.body2,
16
- paddingLeft: theme.spacings.xs,
17
- margin: 0,
18
- },
19
- }),
20
- { name: 'MollieIssuerOptions' },
21
- )
11
+ const compName = 'MollieIssuerOptions' as const
12
+ const parts = ['root', 'list'] as const
13
+ const { classes } = extendableComponent(compName, parts)
22
14
 
23
15
  export default function MollieIssuerOptions(props: MollieIssuerOptionsProps) {
24
16
  const { mollie_available_issuers = [] } = props
25
- const { code, step, Container, label, title } = props
26
- const classes = useStyles()
17
+ const { code, step, Container, label, title = '' } = props
27
18
 
28
19
  const form = useFormGqlMutationCart(SetMolliePaymentMethodIssuerOnCartDocument, {
29
20
  mode: 'onChange',
@@ -40,7 +31,7 @@ export default function MollieIssuerOptions(props: MollieIssuerOptionsProps) {
40
31
  return (
41
32
  <Container>
42
33
  <Typography variant='h5' component='span'>
43
- Pay with {title}
34
+ <Trans>Pay with {title}</Trans>
44
35
  </Typography>
45
36
  <form onSubmit={submit} noValidate>
46
37
  <FormRow>
@@ -71,7 +62,7 @@ export default function MollieIssuerOptions(props: MollieIssuerOptionsProps) {
71
62
  // return (
72
63
  // <MenuItem key={issuer.code} value={issuer.code}>
73
64
  // <ListItemIcon>
74
- // <SvgImageSimple src={issuer.svg} alt={issuer.name} size='small' />
65
+ // <SvgIcon src={issuer.svg} alt={issuer.name} size='small' />
75
66
  // </ListItemIcon>
76
67
  // <Typography variant='inherit'>{issuer.name}</Typography>
77
68
  // </MenuItem>
@@ -79,7 +70,15 @@ export default function MollieIssuerOptions(props: MollieIssuerOptionsProps) {
79
70
  })}
80
71
  </TextField>
81
72
  </FormRow>
82
- <ul className={classes.root}>
73
+ <Box
74
+ component='ul'
75
+ className={classes.list}
76
+ sx={(theme) => ({
77
+ typography: 'body2',
78
+ paddingLeft: theme.spacings.xs,
79
+ margin: 0,
80
+ })}
81
+ >
83
82
  <li>
84
83
  <Trans>Choose your bank, and place your order.</Trans>
85
84
  </li>
@@ -91,7 +90,7 @@ export default function MollieIssuerOptions(props: MollieIssuerOptionsProps) {
91
90
  As soon as the payment is completed, you will automatically return to the webshop.
92
91
  </Trans>
93
92
  </li>
94
- </ul>
93
+ </Box>
95
94
  </form>
96
95
  </Container>
97
96
  )
@@ -1,11 +1,11 @@
1
- import { useQuery } from '@apollo/client'
1
+ import { useQuery } from '@graphcommerce/graphql'
2
2
  import { useFormGqlMutationCart } from '@graphcommerce/magento-cart'
3
3
  import { PaymentOptionsProps } from '@graphcommerce/magento-cart-payment-method'
4
4
  import { StoreConfigDocument } from '@graphcommerce/magento-store'
5
5
  import { FormRow } from '@graphcommerce/next-ui'
6
6
  import { useFormCompose } from '@graphcommerce/react-hook-form'
7
- import { Typography } from '@material-ui/core'
8
- import { Alert } from '@material-ui/lab'
7
+ import { Trans } from '@lingui/macro'
8
+ import { Typography, Alert } from '@mui/material'
9
9
  import Script from 'next/script'
10
10
  import React, { useEffect, useState } from 'react'
11
11
  import { Mollie } from '../../Mollie'
@@ -14,7 +14,7 @@ import { SetMolliePaymentMethodTokenOnCartDocument } from './SetMolliePaymentMet
14
14
  import { mollieContext, MollieContext } from './mollieContext'
15
15
 
16
16
  export default function MollieCreditCardOptions(props: PaymentOptionsProps) {
17
- const { code, step, Container, title } = props
17
+ const { code, step, Container, title = '' } = props
18
18
  const [loaded, setLoaded] = useState<boolean>(false)
19
19
  const [mollie, setMollie] = useState<MollieContext>(undefined)
20
20
  const conf = useQuery(StoreConfigDocument)
@@ -63,7 +63,7 @@ export default function MollieCreditCardOptions(props: PaymentOptionsProps) {
63
63
  <Script src='https://js.mollie.com/v1/mollie.js' onLoad={() => setLoaded(true)} />
64
64
  <mollieContext.Provider value={mollie}>
65
65
  <Typography variant='h5' component='span'>
66
- Pay with {title}
66
+ <Trans>Pay with {title}</Trans>
67
67
  </Typography>
68
68
  <form onSubmit={submit} noValidate>
69
69
  <FormRow>
@@ -1,10 +1,4 @@
1
- import {
2
- InputBaseComponentProps,
3
- makeStyles,
4
- TextField,
5
- TextFieldProps,
6
- Theme,
7
- } from '@material-ui/core'
1
+ import { InputBaseComponentProps, TextField, TextFieldProps } from '@mui/material'
8
2
  import React, {
9
3
  Dispatch,
10
4
  SetStateAction,
@@ -104,19 +98,9 @@ type MollieFieldProps = {
104
98
  isSubmitted?: boolean
105
99
  } & TextFieldProps
106
100
 
107
- const useStyles = makeStyles((theme: Theme) => ({
108
- label: {
109
- background:
110
- theme.palette.type === 'light'
111
- ? theme.palette.secondary.light
112
- : theme.palette.background.paper,
113
- },
114
- }))
115
-
116
101
  export default function MollieField(props: MollieFieldProps) {
117
102
  const { isSubmitted = false, label, ...fieldProps } = props
118
103
 
119
- const classes = useStyles()
120
104
  const [state, setState] = useState<ComponentFieldState>({
121
105
  dirty: false,
122
106
  touched: false,
@@ -136,8 +120,13 @@ export default function MollieField(props: MollieFieldProps) {
136
120
  inputProps: { component: IframeField },
137
121
  }}
138
122
  InputLabelProps={{
123
+ sx: (theme) => ({
124
+ background:
125
+ theme.palette.mode === 'light'
126
+ ? theme.palette.secondary.light
127
+ : theme.palette.background.paper,
128
+ }),
139
129
  shrink: true,
140
- classes: { root: classes.label },
141
130
  }}
142
131
  />
143
132
  </mollieFieldContext.Provider>
@@ -1,5 +1,5 @@
1
1
  import { ApolloCartErrorFullPage, useClearCurrentCartId } from '@graphcommerce/magento-cart'
2
- import { Button, Dialog } from '@material-ui/core'
2
+ import { Button, Dialog } from '@mui/material'
3
3
  import { useRouter } from 'next/router'
4
4
  import React from 'react'
5
5
  import { useMolliePaymentTokenHandler } from '../../hooks/useMolliePaymentTokenHandler'
@@ -1,4 +1,4 @@
1
- import { useMutation } from '@apollo/client'
1
+ import { useMutation } from '@graphcommerce/graphql'
2
2
  import { PaymentStatusEnum } from '@graphcommerce/graphql'
3
3
  import { useClearCurrentCartId, useCurrentCartId } from '@graphcommerce/magento-cart'
4
4
  import { useCartLock, usePaymentMethodContext } from '@graphcommerce/magento-cart-payment-method'
package/package.json CHANGED
@@ -1,14 +1,13 @@
1
1
  {
2
2
  "name": "@graphcommerce/mollie-magento-payment",
3
- "version": "2.106.47",
3
+ "homepage": "https://www.graphcommerce.org/",
4
+ "repository": "github:graphcommerce-org/graphcommerce",
5
+ "version": "3.0.1",
4
6
  "sideEffects": false,
5
7
  "engines": {
6
8
  "node": "14.x"
7
9
  },
8
10
  "prettier": "@graphcommerce/prettier-config-pwa",
9
- "browserslist": [
10
- "extends @graphcommerce/browserslist-config-pwa"
11
- ],
12
11
  "eslintConfig": {
13
12
  "extends": "@graphcommerce/eslint-config-pwa",
14
13
  "parserOptions": {
@@ -16,33 +15,28 @@
16
15
  }
17
16
  },
18
17
  "devDependencies": {
19
- "@graphcommerce/browserslist-config-pwa": "^3.0.3",
20
- "@graphcommerce/eslint-config-pwa": "^3.1.10",
21
- "@graphcommerce/magento-cart-shipping-address": "^2.106.46",
22
- "@graphcommerce/magento-product": "^3.8.12",
23
- "@graphcommerce/magento-product-configurable": "^3.6.42",
24
- "@graphcommerce/prettier-config-pwa": "^3.0.5",
25
- "@graphcommerce/typescript-config-pwa": "^3.1.2",
26
- "@playwright/test": "^1.17.1"
18
+ "@graphcommerce/eslint-config-pwa": "^4.0.1",
19
+ "@graphcommerce/magento-cart-shipping-address": "^3.0.1",
20
+ "@graphcommerce/magento-product": "^4.0.1",
21
+ "@graphcommerce/magento-product-configurable": "^4.0.1",
22
+ "@graphcommerce/prettier-config-pwa": "^4.0.1",
23
+ "@graphcommerce/typescript-config-pwa": "^4.0.1",
24
+ "@playwright/test": "^1.18.1"
27
25
  },
28
26
  "dependencies": {
29
- "@apollo/client": "^3.5.6",
30
- "@graphcommerce/graphql": "^2.105.13",
31
- "@graphcommerce/image": "^2.105.13",
32
- "@graphcommerce/magento-cart": "^3.10.2",
33
- "@graphcommerce/magento-cart-payment-method": "^2.111.46",
34
- "@graphcommerce/magento-store": "^3.4.11",
35
- "@graphcommerce/next-ui": "^3.25.2",
36
- "@graphcommerce/react-hook-form": "^2.104.7",
37
- "@lingui/macro": "^3.13.0",
38
- "@material-ui/core": "^4.12.3",
39
- "@material-ui/lab": "^4.0.0-alpha.60",
40
- "clsx": "^1.1.1",
41
- "framer-motion": "^5.5.5",
42
- "next": "^12.0.7",
27
+ "@graphcommerce/graphql": "^3.0.1",
28
+ "@graphcommerce/image": "^3.0.1",
29
+ "@graphcommerce/magento-cart": "^4.0.1",
30
+ "@graphcommerce/magento-cart-payment-method": "^3.0.1",
31
+ "@graphcommerce/magento-store": "^4.0.1",
32
+ "@graphcommerce/next-ui": "^4.0.1",
33
+ "@graphcommerce/react-hook-form": "^3.0.1",
34
+ "@lingui/macro": "^3.13.2",
35
+ "@mui/material": "^5.4.1",
36
+ "framer-motion": "^6.2.4",
37
+ "next": "^12.0.10",
43
38
  "react": "^17.0.1",
44
39
  "react-dom": "^17.0.1",
45
- "type-fest": "^2.8.0"
46
- },
47
- "gitHead": "110ddb032ee3ce6e363b9f5f7d21af71fb51b527"
40
+ "type-fest": "^2.11.2"
41
+ }
48
42
  }