@graphcommerce/magento-cart-payment-method 3.0.4 → 3.0.7
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/Api/PaymentMethodContext.graphql +2 -1
- package/CHANGELOG.md +121 -168
- package/PaymentMethodButton/PaymentMethodButton.tsx +8 -10
- package/PaymentMethodContext/PaymentMethodContext.tsx +22 -17
- package/PaymentMethodOptions/PaymentMethodOptions.tsx +1 -3
- package/PaymentMethodOptionsNoop/PaymentMethodOptionsNoop.tsx +1 -3
- package/PaymentMethodPlaceOrder/PaymentMethodPlaceOrder.tsx +1 -1
- package/PaymentMethodPlaceOrderNoop/PaymentMethodPlaceOrderNoop.tsx +2 -2
- package/PaymentMethodToggles/PaymentMethodToggles.tsx +2 -2
- package/hooks/useCartLock.ts +15 -22
- package/index.ts +5 -14
- package/package.json +14 -14
- package/test/goToPayment.ts +25 -0
- package/hooks/UseCartLock.graphql +0 -7
- package/hooks/UseCartLock.graphqls +0 -7
package/CHANGELOG.md
CHANGED
|
@@ -1,18 +1,61 @@
|
|
|
1
1
|
# Change Log
|
|
2
2
|
|
|
3
|
+
## 3.0.7
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#1378](https://github.com/graphcommerce-org/graphcommerce/pull/1378) [`b610a6e40`](https://github.com/graphcommerce-org/graphcommerce/commit/b610a6e4049e8c9e8b5d2aeff31b8e1bfc24abe5) Thanks [@paales](https://github.com/paales)! - Pin all versions internally so we can’t end up in an unfixable state for the user
|
|
8
|
+
|
|
9
|
+
- Updated dependencies [[`b610a6e40`](https://github.com/graphcommerce-org/graphcommerce/commit/b610a6e4049e8c9e8b5d2aeff31b8e1bfc24abe5), [`22ff9df16`](https://github.com/graphcommerce-org/graphcommerce/commit/22ff9df1677742ae8e07d9b7e5b12fbb487580dc)]:
|
|
10
|
+
- @graphcommerce/framer-scroller@2.1.4
|
|
11
|
+
- @graphcommerce/graphql@3.0.7
|
|
12
|
+
- @graphcommerce/image@3.1.3
|
|
13
|
+
- @graphcommerce/magento-cart@4.2.3
|
|
14
|
+
- @graphcommerce/magento-store@4.1.5
|
|
15
|
+
- @graphcommerce/next-ui@4.5.1
|
|
16
|
+
- @graphcommerce/react-hook-form@3.0.7
|
|
17
|
+
|
|
18
|
+
## 3.0.6
|
|
19
|
+
|
|
20
|
+
### Patch Changes
|
|
21
|
+
|
|
22
|
+
- [#1369](https://github.com/graphcommerce-org/graphcommerce/pull/1369) [`ae6449502`](https://github.com/graphcommerce-org/graphcommerce/commit/ae64495024a455bbe5188588604368c1542840c9) Thanks [@paales](https://github.com/paales)! - Upgraded dependencies
|
|
23
|
+
|
|
24
|
+
* [#1368](https://github.com/graphcommerce-org/graphcommerce/pull/1368) [`892018809`](https://github.com/graphcommerce-org/graphcommerce/commit/8920188093d0422ec50580e408dc28ac5f93e46a) Thanks [@paales](https://github.com/paales)! - Fix issue where the cart couldn't be properly restored when a payment was cancelled
|
|
25
|
+
|
|
26
|
+
* Updated dependencies [[`892018809`](https://github.com/graphcommerce-org/graphcommerce/commit/8920188093d0422ec50580e408dc28ac5f93e46a), [`892018809`](https://github.com/graphcommerce-org/graphcommerce/commit/8920188093d0422ec50580e408dc28ac5f93e46a), [`ae6449502`](https://github.com/graphcommerce-org/graphcommerce/commit/ae64495024a455bbe5188588604368c1542840c9), [`892018809`](https://github.com/graphcommerce-org/graphcommerce/commit/8920188093d0422ec50580e408dc28ac5f93e46a), [`892018809`](https://github.com/graphcommerce-org/graphcommerce/commit/8920188093d0422ec50580e408dc28ac5f93e46a)]:
|
|
27
|
+
- @graphcommerce/graphql@3.0.6
|
|
28
|
+
- @graphcommerce/next-ui@4.5.0
|
|
29
|
+
- @graphcommerce/framer-scroller@2.1.3
|
|
30
|
+
- @graphcommerce/image@3.1.2
|
|
31
|
+
- @graphcommerce/magento-cart@4.2.2
|
|
32
|
+
- @graphcommerce/magento-store@4.1.4
|
|
33
|
+
- @graphcommerce/react-hook-form@3.0.6
|
|
34
|
+
|
|
35
|
+
## 3.0.5
|
|
36
|
+
|
|
37
|
+
### Patch Changes
|
|
38
|
+
|
|
39
|
+
- [#1307](https://github.com/ho-nl/m2-pwa/pull/1307) [`bd10506d3`](https://github.com/ho-nl/m2-pwa/commit/bd10506d32fdbc91d01dadc29a12ebd1e0943655) Thanks [@paales](https://github.com/paales)! - All default exports are now named exports internally and all `index.tsx` are renamed to the component name.
|
|
40
|
+
|
|
41
|
+
* [#1307](https://github.com/ho-nl/m2-pwa/pull/1307) [`27cb1f2d8`](https://github.com/ho-nl/m2-pwa/commit/27cb1f2d8dbfb8f1b301ce56fb6a2b6c1fc6a5ef) Thanks [@paales](https://github.com/paales)! - upgrade dependencies
|
|
42
|
+
|
|
43
|
+
* Updated dependencies [[`3d63b39f7`](https://github.com/ho-nl/m2-pwa/commit/3d63b39f7e330d1827a32dba782667d7b21adaba), [`bd10506d3`](https://github.com/ho-nl/m2-pwa/commit/bd10506d32fdbc91d01dadc29a12ebd1e0943655), [`27cb1f2d8`](https://github.com/ho-nl/m2-pwa/commit/27cb1f2d8dbfb8f1b301ce56fb6a2b6c1fc6a5ef)]:
|
|
44
|
+
- @graphcommerce/next-ui@4.2.4
|
|
45
|
+
- @graphcommerce/framer-scroller@2.0.6
|
|
46
|
+
- @graphcommerce/graphql@3.0.4
|
|
47
|
+
- @graphcommerce/image@3.1.1
|
|
48
|
+
- @graphcommerce/magento-cart@4.1.4
|
|
49
|
+
- @graphcommerce/magento-store@4.1.2
|
|
50
|
+
- @graphcommerce/react-hook-form@3.0.4
|
|
51
|
+
|
|
3
52
|
## 3.0.4
|
|
4
53
|
|
|
5
54
|
### Patch Changes
|
|
6
55
|
|
|
7
|
-
- [#1292](https://github.com/ho-nl/m2-pwa/pull/1292)
|
|
8
|
-
[`5a1ba9e66`](https://github.com/ho-nl/m2-pwa/commit/5a1ba9e664abbac89c4f5f71f7d6d6ed1aefa5c0)
|
|
9
|
-
Thanks [@paales](https://github.com/paales)! - Renamed SvgIcon to IconSvg to prevent collisions
|
|
10
|
-
with MUI
|
|
56
|
+
- [#1292](https://github.com/ho-nl/m2-pwa/pull/1292) [`5a1ba9e66`](https://github.com/ho-nl/m2-pwa/commit/5a1ba9e664abbac89c4f5f71f7d6d6ed1aefa5c0) Thanks [@paales](https://github.com/paales)! - Renamed SvgIcon to IconSvg to prevent collisions with MUI
|
|
11
57
|
|
|
12
|
-
- Updated dependencies
|
|
13
|
-
[[`5a1ba9e66`](https://github.com/ho-nl/m2-pwa/commit/5a1ba9e664abbac89c4f5f71f7d6d6ed1aefa5c0),
|
|
14
|
-
[`990df655b`](https://github.com/ho-nl/m2-pwa/commit/990df655b73b469718d6cb5837ee65dfe2ad6a1d),
|
|
15
|
-
[`63f9b56eb`](https://github.com/ho-nl/m2-pwa/commit/63f9b56eb68ba790567ff1427e599fd2c3c8f1ee)]:
|
|
58
|
+
- Updated dependencies [[`5a1ba9e66`](https://github.com/ho-nl/m2-pwa/commit/5a1ba9e664abbac89c4f5f71f7d6d6ed1aefa5c0), [`990df655b`](https://github.com/ho-nl/m2-pwa/commit/990df655b73b469718d6cb5837ee65dfe2ad6a1d), [`63f9b56eb`](https://github.com/ho-nl/m2-pwa/commit/63f9b56eb68ba790567ff1427e599fd2c3c8f1ee)]:
|
|
16
59
|
- @graphcommerce/magento-cart@4.1.3
|
|
17
60
|
- @graphcommerce/next-ui@4.2.0
|
|
18
61
|
|
|
@@ -20,18 +63,11 @@
|
|
|
20
63
|
|
|
21
64
|
### Patch Changes
|
|
22
65
|
|
|
23
|
-
- [`973ff8645`](https://github.com/ho-nl/m2-pwa/commit/973ff86452a70ade9f4db13fdda6e963d7220e96)
|
|
24
|
-
Thanks [@paales](https://github.com/paales)! - made packages public
|
|
66
|
+
- [`973ff8645`](https://github.com/ho-nl/m2-pwa/commit/973ff86452a70ade9f4db13fdda6e963d7220e96) Thanks [@paales](https://github.com/paales)! - made packages public
|
|
25
67
|
|
|
26
|
-
* [#1278](https://github.com/ho-nl/m2-pwa/pull/1278)
|
|
27
|
-
[`81ea406d5`](https://github.com/ho-nl/m2-pwa/commit/81ea406d54d6b5c662c030a7fea444abc4117a20)
|
|
28
|
-
Thanks [@ErwinOtten](https://github.com/ErwinOtten)! - Upgraded dependencies to the latest version
|
|
68
|
+
* [#1278](https://github.com/ho-nl/m2-pwa/pull/1278) [`81ea406d5`](https://github.com/ho-nl/m2-pwa/commit/81ea406d54d6b5c662c030a7fea444abc4117a20) Thanks [@ErwinOtten](https://github.com/ErwinOtten)! - Upgraded dependencies to the latest version
|
|
29
69
|
|
|
30
|
-
* Updated dependencies
|
|
31
|
-
[[`973ff8645`](https://github.com/ho-nl/m2-pwa/commit/973ff86452a70ade9f4db13fdda6e963d7220e96),
|
|
32
|
-
[`81ea406d5`](https://github.com/ho-nl/m2-pwa/commit/81ea406d54d6b5c662c030a7fea444abc4117a20),
|
|
33
|
-
[`3a719c88c`](https://github.com/ho-nl/m2-pwa/commit/3a719c88cad1eab58602de28c41adc0fc4827e1d),
|
|
34
|
-
[`5ffcb56bf`](https://github.com/ho-nl/m2-pwa/commit/5ffcb56bfcbe49ebeaf24f9341e819a145ab9a14)]:
|
|
70
|
+
* Updated dependencies [[`973ff8645`](https://github.com/ho-nl/m2-pwa/commit/973ff86452a70ade9f4db13fdda6e963d7220e96), [`81ea406d5`](https://github.com/ho-nl/m2-pwa/commit/81ea406d54d6b5c662c030a7fea444abc4117a20), [`3a719c88c`](https://github.com/ho-nl/m2-pwa/commit/3a719c88cad1eab58602de28c41adc0fc4827e1d), [`5ffcb56bf`](https://github.com/ho-nl/m2-pwa/commit/5ffcb56bfcbe49ebeaf24f9341e819a145ab9a14)]:
|
|
35
71
|
- @graphcommerce/framer-scroller@2.0.3
|
|
36
72
|
- @graphcommerce/graphql@3.0.3
|
|
37
73
|
- @graphcommerce/image@3.1.0
|
|
@@ -44,47 +80,23 @@
|
|
|
44
80
|
|
|
45
81
|
### Patch Changes
|
|
46
82
|
|
|
47
|
-
- [#1274](https://github.com/ho-nl/m2-pwa/pull/1274)
|
|
48
|
-
[`381e4c86a`](https://github.com/ho-nl/m2-pwa/commit/381e4c86a8321ce96e1fa5c7d3c0a0c0ff3e02c7)
|
|
49
|
-
Thanks [@paales](https://github.com/paales)! - Moved `ApolloErrorAlert`, `ApolloErrorFullPage` and
|
|
50
|
-
`ApolloErrorSnackbar` to the ecommerce-ui package.
|
|
83
|
+
- [#1274](https://github.com/ho-nl/m2-pwa/pull/1274) [`381e4c86a`](https://github.com/ho-nl/m2-pwa/commit/381e4c86a8321ce96e1fa5c7d3c0a0c0ff3e02c7) Thanks [@paales](https://github.com/paales)! - Moved `ApolloErrorAlert`, `ApolloErrorFullPage` and `ApolloErrorSnackbar` to the ecommerce-ui package.
|
|
51
84
|
|
|
52
|
-
Created `ComposedSubmitButton` and `ComposedSubmitLinkOrButton` to reduce complexity from
|
|
53
|
-
`magento-graphcms` example.
|
|
85
|
+
Created `ComposedSubmitButton` and `ComposedSubmitLinkOrButton` to reduce complexity from `magento-graphcms` example.
|
|
54
86
|
|
|
55
87
|
Removed dependency an `@graphcommerce/react-hook-form` from `magento-graphcms` example.
|
|
56
88
|
|
|
57
89
|
Added dependency `@graphcommerce/ecommerce-ui` from `magento-graphcms` example.
|
|
58
90
|
|
|
59
|
-
* [#1276](https://github.com/ho-nl/m2-pwa/pull/1276)
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
various translations for english 🇺🇸🇬🇧 and dutch 🇳🇱
|
|
69
|
-
|
|
70
|
-
* [#1276](https://github.com/ho-nl/m2-pwa/pull/1276)
|
|
71
|
-
[`52a45bba4`](https://github.com/ho-nl/m2-pwa/commit/52a45bba4dc6dd6df3c81f5023df7d23ed8a534d)
|
|
72
|
-
Thanks [@paales](https://github.com/paales)! - Upgraded to
|
|
73
|
-
[NextJS 12.1](https://nextjs.org/blog/next-12-1)! This is just for compatibility, but we'll be
|
|
74
|
-
implementing
|
|
75
|
-
[On-demand Incremental Static Regeneration](https://nextjs.org/blog/next-12-1#on-demand-incremental-static-regeneration-beta)
|
|
76
|
-
soon.
|
|
77
|
-
|
|
78
|
-
This will greatly reduce the requirement to rebuid stuff and we'll add a management UI on the
|
|
79
|
-
frontend to be able to revalidate pages manually.
|
|
80
|
-
|
|
81
|
-
* Updated dependencies
|
|
82
|
-
[[`381e4c86a`](https://github.com/ho-nl/m2-pwa/commit/381e4c86a8321ce96e1fa5c7d3c0a0c0ff3e02c7),
|
|
83
|
-
[`ce09388e0`](https://github.com/ho-nl/m2-pwa/commit/ce09388e0d7ef33aee660612340f6fbae15ceec2),
|
|
84
|
-
[`e7c8e2756`](https://github.com/ho-nl/m2-pwa/commit/e7c8e2756d637cbcd2e793d62ef5721d35d9fa7b),
|
|
85
|
-
[`b08a8eb1d`](https://github.com/ho-nl/m2-pwa/commit/b08a8eb1d024b9d3e7712ef034029151670db275),
|
|
86
|
-
[`52a45bba4`](https://github.com/ho-nl/m2-pwa/commit/52a45bba4dc6dd6df3c81f5023df7d23ed8a534d),
|
|
87
|
-
[`5a4809b1a`](https://github.com/ho-nl/m2-pwa/commit/5a4809b1a705aa32f620f520085df48ee25f9949)]:
|
|
91
|
+
* [#1276](https://github.com/ho-nl/m2-pwa/pull/1276) [`ce09388e0`](https://github.com/ho-nl/m2-pwa/commit/ce09388e0d7ef33aee660612340f6fbae15ceec2) Thanks [@paales](https://github.com/paales)! - We've moved lots of internal packages from `dependencies` to `peerDependencies`. The result of this is that there will be significantly less duplicate packages in the node_modules folders.
|
|
92
|
+
|
|
93
|
+
- [#1274](https://github.com/ho-nl/m2-pwa/pull/1274) [`b08a8eb1d`](https://github.com/ho-nl/m2-pwa/commit/b08a8eb1d024b9d3e7712ef034029151670db275) Thanks [@paales](https://github.com/paales)! - Fixed extraction of translations and updated various translations for english 🇺🇸🇬🇧 and dutch 🇳🇱
|
|
94
|
+
|
|
95
|
+
* [#1276](https://github.com/ho-nl/m2-pwa/pull/1276) [`52a45bba4`](https://github.com/ho-nl/m2-pwa/commit/52a45bba4dc6dd6df3c81f5023df7d23ed8a534d) Thanks [@paales](https://github.com/paales)! - Upgraded to [NextJS 12.1](https://nextjs.org/blog/next-12-1)! This is just for compatibility, but we'll be implementing [On-demand Incremental Static Regeneration](https://nextjs.org/blog/next-12-1#on-demand-incremental-static-regeneration-beta) soon.
|
|
96
|
+
|
|
97
|
+
This will greatly reduce the requirement to rebuid stuff and we'll add a management UI on the frontend to be able to revalidate pages manually.
|
|
98
|
+
|
|
99
|
+
* Updated dependencies [[`381e4c86a`](https://github.com/ho-nl/m2-pwa/commit/381e4c86a8321ce96e1fa5c7d3c0a0c0ff3e02c7), [`ce09388e0`](https://github.com/ho-nl/m2-pwa/commit/ce09388e0d7ef33aee660612340f6fbae15ceec2), [`e7c8e2756`](https://github.com/ho-nl/m2-pwa/commit/e7c8e2756d637cbcd2e793d62ef5721d35d9fa7b), [`b08a8eb1d`](https://github.com/ho-nl/m2-pwa/commit/b08a8eb1d024b9d3e7712ef034029151670db275), [`52a45bba4`](https://github.com/ho-nl/m2-pwa/commit/52a45bba4dc6dd6df3c81f5023df7d23ed8a534d), [`5a4809b1a`](https://github.com/ho-nl/m2-pwa/commit/5a4809b1a705aa32f620f520085df48ee25f9949)]:
|
|
88
100
|
- @graphcommerce/magento-cart@4.1.1
|
|
89
101
|
- @graphcommerce/next-ui@4.1.1
|
|
90
102
|
- @graphcommerce/react-hook-form@3.0.2
|
|
@@ -97,11 +109,8 @@
|
|
|
97
109
|
|
|
98
110
|
### Patch Changes
|
|
99
111
|
|
|
100
|
-
- [`0cbaa878b`](https://github.com/ho-nl/m2-pwa/commit/0cbaa878b8a844d5abbeb1797b625a33130e6514)
|
|
101
|
-
|
|
102
|
-
so that the packages link to back to the website and repository
|
|
103
|
-
- Updated dependencies
|
|
104
|
-
[[`0cbaa878b`](https://github.com/ho-nl/m2-pwa/commit/0cbaa878b8a844d5abbeb1797b625a33130e6514)]:
|
|
112
|
+
- [`0cbaa878b`](https://github.com/ho-nl/m2-pwa/commit/0cbaa878b8a844d5abbeb1797b625a33130e6514) Thanks [@paales](https://github.com/paales)! - Added homepage and repository package.json files, so that the packages link to back to the website and repository
|
|
113
|
+
- Updated dependencies [[`0cbaa878b`](https://github.com/ho-nl/m2-pwa/commit/0cbaa878b8a844d5abbeb1797b625a33130e6514)]:
|
|
105
114
|
- @graphcommerce/framer-scroller@2.0.1
|
|
106
115
|
- @graphcommerce/graphql@3.0.1
|
|
107
116
|
- @graphcommerce/image@3.0.1
|
|
@@ -114,14 +123,11 @@
|
|
|
114
123
|
|
|
115
124
|
### Major Changes
|
|
116
125
|
|
|
117
|
-
- [#1258](https://github.com/ho-nl/m2-pwa/pull/1258)
|
|
118
|
-
[`ad36382a4`](https://github.com/ho-nl/m2-pwa/commit/ad36382a4d55d83d9e47b7eb6a02671a2a631a05)
|
|
119
|
-
Thanks [@paales](https://github.com/paales)! - Upgraded to Material UI 5
|
|
126
|
+
- [#1258](https://github.com/ho-nl/m2-pwa/pull/1258) [`ad36382a4`](https://github.com/ho-nl/m2-pwa/commit/ad36382a4d55d83d9e47b7eb6a02671a2a631a05) Thanks [@paales](https://github.com/paales)! - Upgraded to Material UI 5
|
|
120
127
|
|
|
121
128
|
### Patch Changes
|
|
122
129
|
|
|
123
|
-
- Updated dependencies
|
|
124
|
-
[[`ad36382a4`](https://github.com/ho-nl/m2-pwa/commit/ad36382a4d55d83d9e47b7eb6a02671a2a631a05)]:
|
|
130
|
+
- Updated dependencies [[`ad36382a4`](https://github.com/ho-nl/m2-pwa/commit/ad36382a4d55d83d9e47b7eb6a02671a2a631a05)]:
|
|
125
131
|
- @graphcommerce/framer-scroller@2.0.0
|
|
126
132
|
- @graphcommerce/graphql@3.0.0
|
|
127
133
|
- @graphcommerce/image@3.0.0
|
|
@@ -130,90 +136,77 @@
|
|
|
130
136
|
- @graphcommerce/next-ui@4.0.0
|
|
131
137
|
- @graphcommerce/react-hook-form@3.0.0
|
|
132
138
|
|
|
133
|
-
All notable changes to this project will be documented in this file. See
|
|
134
|
-
[Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
139
|
+
All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
135
140
|
|
|
136
141
|
# [2.111.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.110.20...@graphcommerce/magento-cart-payment-method@2.111.0) (2021-11-12)
|
|
137
142
|
|
|
138
143
|
### Bug Fixes
|
|
139
144
|
|
|
140
|
-
- even more translations
|
|
141
|
-
([1a1f988](https://github.com/ho-nl/m2-pwa/commit/1a1f98837c704b978f6b42b619d9c52f540b2d48))
|
|
145
|
+
- even more translations ([1a1f988](https://github.com/ho-nl/m2-pwa/commit/1a1f98837c704b978f6b42b619d9c52f540b2d48))
|
|
142
146
|
|
|
143
147
|
### Features
|
|
144
148
|
|
|
145
|
-
- added tons of translations
|
|
146
|
-
([9bb0ac7](https://github.com/ho-nl/m2-pwa/commit/9bb0ac709b58df6ea6141e92e4923a5ca9ae2963))
|
|
149
|
+
- added tons of translations ([9bb0ac7](https://github.com/ho-nl/m2-pwa/commit/9bb0ac709b58df6ea6141e92e4923a5ca9ae2963))
|
|
147
150
|
|
|
148
151
|
## [2.110.7](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.110.6...@graphcommerce/magento-cart-payment-method@2.110.7) (2021-11-04)
|
|
149
152
|
|
|
150
153
|
### Bug Fixes
|
|
151
154
|
|
|
152
|
-
- remove hardcoded fontSize
|
|
153
|
-
([e4e09e1](https://github.com/ho-nl/m2-pwa/commit/e4e09e11baeb8edeff634550b8cdb88571d96911))
|
|
155
|
+
- remove hardcoded fontSize ([e4e09e1](https://github.com/ho-nl/m2-pwa/commit/e4e09e11baeb8edeff634550b8cdb88571d96911))
|
|
154
156
|
|
|
155
157
|
# [2.110.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.109.1...@graphcommerce/magento-cart-payment-method@2.110.0) (2021-11-02)
|
|
156
158
|
|
|
157
159
|
### Features
|
|
158
160
|
|
|
159
|
-
- shipping methods scroller
|
|
160
|
-
([3cc4413](https://github.com/ho-nl/m2-pwa/commit/3cc441320d2a3dd003c499be358a118a17e528c3))
|
|
161
|
+
- shipping methods scroller ([3cc4413](https://github.com/ho-nl/m2-pwa/commit/3cc441320d2a3dd003c499be358a118a17e528c3))
|
|
161
162
|
|
|
162
163
|
# [2.109.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.108.8...@graphcommerce/magento-cart-payment-method@2.109.0) (2021-11-02)
|
|
163
164
|
|
|
164
165
|
### Features
|
|
165
166
|
|
|
166
|
-
- darkTheme
|
|
167
|
-
([968f4f1](https://github.com/ho-nl/m2-pwa/commit/968f4f1360417bf7daa36454c19e6bc5cf53ae90))
|
|
167
|
+
- darkTheme ([968f4f1](https://github.com/ho-nl/m2-pwa/commit/968f4f1360417bf7daa36454c19e6bc5cf53ae90))
|
|
168
168
|
|
|
169
169
|
## [2.108.4](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.108.3...@graphcommerce/magento-cart-payment-method@2.108.4) (2021-10-28)
|
|
170
170
|
|
|
171
171
|
### Bug Fixes
|
|
172
172
|
|
|
173
|
-
- External SVG's can't have alt tags
|
|
174
|
-
([1b1414a](https://github.com/ho-nl/m2-pwa/commit/1b1414a782d55d3acf7b0e6bcaa50f2ad5f18f39))
|
|
173
|
+
- External SVG's can't have alt tags ([1b1414a](https://github.com/ho-nl/m2-pwa/commit/1b1414a782d55d3acf7b0e6bcaa50f2ad5f18f39))
|
|
175
174
|
|
|
176
175
|
## [2.108.3](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.108.2...@graphcommerce/magento-cart-payment-method@2.108.3) (2021-10-28)
|
|
177
176
|
|
|
178
177
|
### Bug Fixes
|
|
179
178
|
|
|
180
|
-
- update SvgImage to SvgImageSimple
|
|
181
|
-
([f116543](https://github.com/ho-nl/m2-pwa/commit/f116543730853fa9782abff0ccacee7032e85789))
|
|
179
|
+
- update SvgImage to SvgImageSimple ([f116543](https://github.com/ho-nl/m2-pwa/commit/f116543730853fa9782abff0ccacee7032e85789))
|
|
182
180
|
|
|
183
181
|
# [2.108.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.107.6...@graphcommerce/magento-cart-payment-method@2.108.0) (2021-10-27)
|
|
184
182
|
|
|
185
183
|
### Features
|
|
186
184
|
|
|
187
|
-
- **nextjs:** upgraded to nextjs 12
|
|
188
|
-
([9331bc8](https://github.com/ho-nl/m2-pwa/commit/9331bc801f6419522115cc47d291d49d608d5a90))
|
|
185
|
+
- **nextjs:** upgraded to nextjs 12 ([9331bc8](https://github.com/ho-nl/m2-pwa/commit/9331bc801f6419522115cc47d291d49d608d5a90))
|
|
189
186
|
|
|
190
187
|
# [2.107.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.106.16...@graphcommerce/magento-cart-payment-method@2.107.0) (2021-10-19)
|
|
191
188
|
|
|
192
189
|
### Features
|
|
193
190
|
|
|
194
|
-
- **framer-scroller:** better defaults so the Scroller doesn't look broken when providing no props
|
|
195
|
-
([b177ce9](https://github.com/ho-nl/m2-pwa/commit/b177ce9570abb9ccfd4eb5cc34e43d157bb4e81a))
|
|
191
|
+
- **framer-scroller:** better defaults so the Scroller doesn't look broken when providing no props ([b177ce9](https://github.com/ho-nl/m2-pwa/commit/b177ce9570abb9ccfd4eb5cc34e43d157bb4e81a))
|
|
196
192
|
|
|
197
193
|
## [2.106.5](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.106.4...@graphcommerce/magento-cart-payment-method@2.106.5) (2021-10-08)
|
|
198
194
|
|
|
199
195
|
### Bug Fixes
|
|
200
196
|
|
|
201
|
-
- make sure we can useCartLock on the success page
|
|
202
|
-
([139349a](https://github.com/ho-nl/m2-pwa/commit/139349a73836c0c58c5d8000a801c912dbe23b3b))
|
|
197
|
+
- make sure we can useCartLock on the success page ([139349a](https://github.com/ho-nl/m2-pwa/commit/139349a73836c0c58c5d8000a801c912dbe23b3b))
|
|
203
198
|
|
|
204
199
|
## [2.106.4](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.106.3...@graphcommerce/magento-cart-payment-method@2.106.4) (2021-10-07)
|
|
205
200
|
|
|
206
201
|
### Bug Fixes
|
|
207
202
|
|
|
208
|
-
- make sure if no payment method is filled in we get an error shown
|
|
209
|
-
([a203e57](https://github.com/ho-nl/m2-pwa/commit/a203e570caad0732427a178e8e8b10b4a15d676b))
|
|
203
|
+
- make sure if no payment method is filled in we get an error shown ([a203e57](https://github.com/ho-nl/m2-pwa/commit/a203e570caad0732427a178e8e8b10b4a15d676b))
|
|
210
204
|
|
|
211
205
|
# [2.106.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.105.11...@graphcommerce/magento-cart-payment-method@2.106.0) (2021-10-04)
|
|
212
206
|
|
|
213
207
|
### Features
|
|
214
208
|
|
|
215
|
-
- sort payment methods by availability
|
|
216
|
-
([52f5d45](https://github.com/ho-nl/m2-pwa/commit/52f5d450a7a2fdec0c7eea9cd5d48336cb304138))
|
|
209
|
+
- sort payment methods by availability ([52f5d45](https://github.com/ho-nl/m2-pwa/commit/52f5d450a7a2fdec0c7eea9cd5d48336cb304138))
|
|
217
210
|
|
|
218
211
|
## [2.105.1](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.105.0...@graphcommerce/magento-cart-payment-method@2.105.1) (2021-09-27)
|
|
219
212
|
|
|
@@ -223,81 +216,50 @@ All notable changes to this project will be documented in this file. See
|
|
|
223
216
|
|
|
224
217
|
### Bug Fixes
|
|
225
218
|
|
|
226
|
-
- **checkout:** purchaseorder and other build in methods wouldnt properly submit
|
|
227
|
-
|
|
228
|
-
-
|
|
229
|
-
|
|
230
|
-
-
|
|
231
|
-
|
|
232
|
-
-
|
|
233
|
-
|
|
234
|
-
- paymentDone removed in favor of a more simple clearCart method
|
|
235
|
-
([5314f77](https://github.com/ho-nl/m2-pwa/commit/5314f7752c2f75a55dcd926bfc26607124561e5d))
|
|
236
|
-
- playwright can't find the place order button
|
|
237
|
-
([b1fda5b](https://github.com/ho-nl/m2-pwa/commit/b1fda5b3e403dad621aba8ed895427f2166bc985))
|
|
238
|
-
- **playwright:** checkout button was renamed
|
|
239
|
-
([09e5b79](https://github.com/ho-nl/m2-pwa/commit/09e5b79333708cfac04232d8071d1dad72968297))
|
|
240
|
-
- rename NextButton to Button, change imports
|
|
241
|
-
([976adb0](https://github.com/ho-nl/m2-pwa/commit/976adb0bf906310d1efce888dcc9be1e28ce0f1b))
|
|
219
|
+
- **checkout:** purchaseorder and other build in methods wouldnt properly submit ([331cb8e](https://github.com/ho-nl/m2-pwa/commit/331cb8e2bed58c14cd41fceeab03e2cdfbe7e6a9))
|
|
220
|
+
- do not use ToggleButtonGroup, only use the ToggleButton ([5172f70](https://github.com/ho-nl/m2-pwa/commit/5172f709ee26122b0a8700afb4325f23cb9ba9b9))
|
|
221
|
+
- ignore md files from triggering version updates ([4f98392](https://github.com/ho-nl/m2-pwa/commit/4f9839250b3a32d3070da5290e5efcc5e2243fba))
|
|
222
|
+
- implement next-ui barrel imports ([75bea70](https://github.com/ho-nl/m2-pwa/commit/75bea703dba898f18a2a1dfa3243ebd0a4e6f0e1))
|
|
223
|
+
- paymentDone removed in favor of a more simple clearCart method ([5314f77](https://github.com/ho-nl/m2-pwa/commit/5314f7752c2f75a55dcd926bfc26607124561e5d))
|
|
224
|
+
- playwright can't find the place order button ([b1fda5b](https://github.com/ho-nl/m2-pwa/commit/b1fda5b3e403dad621aba8ed895427f2166bc985))
|
|
225
|
+
- **playwright:** checkout button was renamed ([09e5b79](https://github.com/ho-nl/m2-pwa/commit/09e5b79333708cfac04232d8071d1dad72968297))
|
|
226
|
+
- rename NextButton to Button, change imports ([976adb0](https://github.com/ho-nl/m2-pwa/commit/976adb0bf906310d1efce888dcc9be1e28ce0f1b))
|
|
242
227
|
|
|
243
228
|
### Features
|
|
244
229
|
|
|
245
|
-
- **cart:** when a cart is not active anymore show a clear cart button
|
|
246
|
-
|
|
247
|
-
-
|
|
248
|
-
|
|
249
|
-
-
|
|
250
|
-
|
|
251
|
-
-
|
|
252
|
-
|
|
253
|
-
-
|
|
254
|
-
|
|
255
|
-
-
|
|
256
|
-
|
|
257
|
-
-
|
|
258
|
-
|
|
259
|
-
- **
|
|
260
|
-
|
|
261
|
-
-
|
|
262
|
-
|
|
263
|
-
-
|
|
264
|
-
([7d61407](https://github.com/ho-nl/m2-pwa/commit/7d614075a778f488045034f74be4f75b93f63c43))
|
|
265
|
-
- only show free payment method when zero subtotal quote
|
|
266
|
-
([fd3ba86](https://github.com/ho-nl/m2-pwa/commit/fd3ba86d3060ebe7dc72ce27fca21464b46b4392))
|
|
267
|
-
- **payment-agreements-form:** checkout agreements checkboxes
|
|
268
|
-
([13c8164](https://github.com/ho-nl/m2-pwa/commit/13c816499d220a2ce940672a95beca508b78ddc9))
|
|
269
|
-
- **payments:** make PaymentMethodContext injectable
|
|
270
|
-
([68c664a](https://github.com/ho-nl/m2-pwa/commit/68c664adb7eb6eb86d7a819213deb87152392347))
|
|
271
|
-
- **playwright:** added new playwright package to enable browser testing
|
|
272
|
-
([6f49ec7](https://github.com/ho-nl/m2-pwa/commit/6f49ec7595563775b96ebf21c27e39da1282e8d9))
|
|
273
|
-
- **react-hook-form:** added buttonState to ComposedSubmit
|
|
274
|
-
([57e77c2](https://github.com/ho-nl/m2-pwa/commit/57e77c29f17720f7f3ee3b63be82779c0e5d8714))
|
|
275
|
-
- renamed all packages to use [@graphcommerce](https://github.com/graphcommerce) instead of
|
|
276
|
-
[@reachdigital](https://github.com/reachdigital)
|
|
277
|
-
([491e4ce](https://github.com/ho-nl/m2-pwa/commit/491e4cec9a2686472dac36b79f999257c0811ffe))
|
|
278
|
-
- solve issue where the order couldn’t be submitted
|
|
279
|
-
([ec0d357](https://github.com/ho-nl/m2-pwa/commit/ec0d3579a1277976e2dc515f420996cf716f83a6))
|
|
280
|
-
- upgraded to nextjs 11
|
|
281
|
-
([0053beb](https://github.com/ho-nl/m2-pwa/commit/0053beb7ef597c190add7264256a0eaec35868da))
|
|
282
|
-
- useFormMutationCart and simpler imports
|
|
283
|
-
([012f090](https://github.com/ho-nl/m2-pwa/commit/012f090e8f54d09f35d393c61ad1e2319f5a90ff))
|
|
230
|
+
- **cart:** when a cart is not active anymore show a clear cart button ([5d04a14](https://github.com/ho-nl/m2-pwa/commit/5d04a14726c040b20b34c0b88f923aee1dff22e5))
|
|
231
|
+
- coupon form on payment page ([a163961](https://github.com/ho-nl/m2-pwa/commit/a1639617be756b357177fcce255cf662c5314499))
|
|
232
|
+
- **graphql:** introduced new graphql package that holds all generated files ([a3e7aa0](https://github.com/ho-nl/m2-pwa/commit/a3e7aa05540540533b5ced9a95f1f802ecbe499f))
|
|
233
|
+
- **image:** introduced completely rewritten Image component ([e3413b3](https://github.com/ho-nl/m2-pwa/commit/e3413b3a57392d6571ea64cb8d9c8dca05ea31df))
|
|
234
|
+
- implemented checkmo payment method ([18525b2](https://github.com/ho-nl/m2-pwa/commit/18525b2f4efe9bd0eea12a7a992d284f341e0c68))
|
|
235
|
+
- implemented purchase order ([3a40033](https://github.com/ho-nl/m2-pwa/commit/3a40033cd4d6712a17bb9c41a8841ebf7aa2f025))
|
|
236
|
+
- implemented the new mollie payment api ([a8b38a9](https://github.com/ho-nl/m2-pwa/commit/a8b38a9a45207e180f795e81bf5ac759f01a583d))
|
|
237
|
+
- **mollie:** first version of mollie payment methods ([e2f7d78](https://github.com/ho-nl/m2-pwa/commit/e2f7d78e50a9afe928f1d8c478f946e03c63b0f2))
|
|
238
|
+
- **mollie:** pay with credit card made working ([5cda84e](https://github.com/ho-nl/m2-pwa/commit/5cda84e0b9c54238ae6adaa34f9e2ad77a708508))
|
|
239
|
+
- next.js 11 ([7d61407](https://github.com/ho-nl/m2-pwa/commit/7d614075a778f488045034f74be4f75b93f63c43))
|
|
240
|
+
- only show free payment method when zero subtotal quote ([fd3ba86](https://github.com/ho-nl/m2-pwa/commit/fd3ba86d3060ebe7dc72ce27fca21464b46b4392))
|
|
241
|
+
- **payment-agreements-form:** checkout agreements checkboxes ([13c8164](https://github.com/ho-nl/m2-pwa/commit/13c816499d220a2ce940672a95beca508b78ddc9))
|
|
242
|
+
- **payments:** make PaymentMethodContext injectable ([68c664a](https://github.com/ho-nl/m2-pwa/commit/68c664adb7eb6eb86d7a819213deb87152392347))
|
|
243
|
+
- **playwright:** added new playwright package to enable browser testing ([6f49ec7](https://github.com/ho-nl/m2-pwa/commit/6f49ec7595563775b96ebf21c27e39da1282e8d9))
|
|
244
|
+
- **react-hook-form:** added buttonState to ComposedSubmit ([57e77c2](https://github.com/ho-nl/m2-pwa/commit/57e77c29f17720f7f3ee3b63be82779c0e5d8714))
|
|
245
|
+
- 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))
|
|
246
|
+
- solve issue where the order couldn’t be submitted ([ec0d357](https://github.com/ho-nl/m2-pwa/commit/ec0d3579a1277976e2dc515f420996cf716f83a6))
|
|
247
|
+
- upgraded to nextjs 11 ([0053beb](https://github.com/ho-nl/m2-pwa/commit/0053beb7ef597c190add7264256a0eaec35868da))
|
|
248
|
+
- useFormMutationCart and simpler imports ([012f090](https://github.com/ho-nl/m2-pwa/commit/012f090e8f54d09f35d393c61ad1e2319f5a90ff))
|
|
284
249
|
|
|
285
250
|
### Reverts
|
|
286
251
|
|
|
287
|
-
- Revert "chore: upgrade @apollo/client"
|
|
288
|
-
([55ff24e](https://github.com/ho-nl/m2-pwa/commit/55ff24ede0e56c85b8095edadadd1ec5e0b1b8d2))
|
|
252
|
+
- Revert "chore: upgrade @apollo/client" ([55ff24e](https://github.com/ho-nl/m2-pwa/commit/55ff24ede0e56c85b8095edadadd1ec5e0b1b8d2))
|
|
289
253
|
|
|
290
254
|
# Change Log
|
|
291
255
|
|
|
292
|
-
All notable changes to this project will be documented in this file. See
|
|
293
|
-
[Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
256
|
+
All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
294
257
|
|
|
295
258
|
# [2.104.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.103.18...@graphcommerce/magento-cart-payment-method@2.104.0) (2021-09-24)
|
|
296
259
|
|
|
297
260
|
### Features
|
|
298
261
|
|
|
299
|
-
- **payment-agreements-form:** checkout agreements checkboxes
|
|
300
|
-
([13c8164](https://github.com/ho-nl/m2-pwa/commit/13c816499d220a2ce940672a95beca508b78ddc9))
|
|
262
|
+
- **payment-agreements-form:** checkout agreements checkboxes ([13c8164](https://github.com/ho-nl/m2-pwa/commit/13c816499d220a2ce940672a95beca508b78ddc9))
|
|
301
263
|
|
|
302
264
|
## [2.103.15](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.103.14...@graphcommerce/magento-cart-payment-method@2.103.15) (2021-09-23)
|
|
303
265
|
|
|
@@ -305,61 +267,52 @@ All notable changes to this project will be documented in this file. See
|
|
|
305
267
|
|
|
306
268
|
### Bug Fixes
|
|
307
269
|
|
|
308
|
-
- do not use ToggleButtonGroup, only use the ToggleButton
|
|
309
|
-
([5172f70](https://github.com/ho-nl/m2-pwa/commit/5172f709ee26122b0a8700afb4325f23cb9ba9b9))
|
|
270
|
+
- do not use ToggleButtonGroup, only use the ToggleButton ([5172f70](https://github.com/ho-nl/m2-pwa/commit/5172f709ee26122b0a8700afb4325f23cb9ba9b9))
|
|
310
271
|
|
|
311
272
|
## [2.103.12](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.103.11...@graphcommerce/magento-cart-payment-method@2.103.12) (2021-09-01)
|
|
312
273
|
|
|
313
274
|
### Bug Fixes
|
|
314
275
|
|
|
315
|
-
- playwright can't find the place order button
|
|
316
|
-
([b1fda5b](https://github.com/ho-nl/m2-pwa/commit/b1fda5b3e403dad621aba8ed895427f2166bc985))
|
|
276
|
+
- playwright can't find the place order button ([b1fda5b](https://github.com/ho-nl/m2-pwa/commit/b1fda5b3e403dad621aba8ed895427f2166bc985))
|
|
317
277
|
|
|
318
278
|
## [2.103.4](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.103.3...@graphcommerce/magento-cart-payment-method@2.103.4) (2021-08-17)
|
|
319
279
|
|
|
320
280
|
### Bug Fixes
|
|
321
281
|
|
|
322
|
-
- **playwright:** checkout button was renamed
|
|
323
|
-
([09e5b79](https://github.com/ho-nl/m2-pwa/commit/09e5b79333708cfac04232d8071d1dad72968297))
|
|
282
|
+
- **playwright:** checkout button was renamed ([09e5b79](https://github.com/ho-nl/m2-pwa/commit/09e5b79333708cfac04232d8071d1dad72968297))
|
|
324
283
|
|
|
325
284
|
# [2.103.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.102.2...@graphcommerce/magento-cart-payment-method@2.103.0) (2021-08-13)
|
|
326
285
|
|
|
327
286
|
### Features
|
|
328
287
|
|
|
329
|
-
- coupon form on payment page
|
|
330
|
-
([a163961](https://github.com/ho-nl/m2-pwa/commit/a1639617be756b357177fcce255cf662c5314499))
|
|
288
|
+
- coupon form on payment page ([a163961](https://github.com/ho-nl/m2-pwa/commit/a1639617be756b357177fcce255cf662c5314499))
|
|
331
289
|
|
|
332
290
|
# [2.102.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.101.10...@graphcommerce/magento-cart-payment-method@2.102.0) (2021-08-12)
|
|
333
291
|
|
|
334
292
|
### Features
|
|
335
293
|
|
|
336
|
-
- upgraded to nextjs 11
|
|
337
|
-
([0053beb](https://github.com/ho-nl/m2-pwa/commit/0053beb7ef597c190add7264256a0eaec35868da))
|
|
294
|
+
- upgraded to nextjs 11 ([0053beb](https://github.com/ho-nl/m2-pwa/commit/0053beb7ef597c190add7264256a0eaec35868da))
|
|
338
295
|
|
|
339
296
|
## [2.101.9](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.101.8...@graphcommerce/magento-cart-payment-method@2.101.9) (2021-08-09)
|
|
340
297
|
|
|
341
298
|
### Reverts
|
|
342
299
|
|
|
343
|
-
- Revert "chore: upgrade @apollo/client"
|
|
344
|
-
([55ff24e](https://github.com/ho-nl/m2-pwa/commit/55ff24ede0e56c85b8095edadadd1ec5e0b1b8d2))
|
|
300
|
+
- Revert "chore: upgrade @apollo/client" ([55ff24e](https://github.com/ho-nl/m2-pwa/commit/55ff24ede0e56c85b8095edadadd1ec5e0b1b8d2))
|
|
345
301
|
|
|
346
302
|
## [2.101.3](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.101.2...@graphcommerce/magento-cart-payment-method@2.101.3) (2021-07-29)
|
|
347
303
|
|
|
348
304
|
### Bug Fixes
|
|
349
305
|
|
|
350
|
-
- paymentDone removed in favor of a more simple clearCart method
|
|
351
|
-
([5314f77](https://github.com/ho-nl/m2-pwa/commit/5314f7752c2f75a55dcd926bfc26607124561e5d))
|
|
306
|
+
- paymentDone removed in favor of a more simple clearCart method ([5314f77](https://github.com/ho-nl/m2-pwa/commit/5314f7752c2f75a55dcd926bfc26607124561e5d))
|
|
352
307
|
|
|
353
308
|
# [2.101.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.100.19...@graphcommerce/magento-cart-payment-method@2.101.0) (2021-07-26)
|
|
354
309
|
|
|
355
310
|
### Features
|
|
356
311
|
|
|
357
|
-
- **playwright:** added new playwright package to enable browser testing
|
|
358
|
-
([6f49ec7](https://github.com/ho-nl/m2-pwa/commit/6f49ec7595563775b96ebf21c27e39da1282e8d9))
|
|
312
|
+
- **playwright:** added new playwright package to enable browser testing ([6f49ec7](https://github.com/ho-nl/m2-pwa/commit/6f49ec7595563775b96ebf21c27e39da1282e8d9))
|
|
359
313
|
|
|
360
314
|
## [2.100.11](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-cart-payment-method@2.100.10...@graphcommerce/magento-cart-payment-method@2.100.11) (2021-07-20)
|
|
361
315
|
|
|
362
316
|
### Bug Fixes
|
|
363
317
|
|
|
364
|
-
- ignore md files from triggering version updates
|
|
365
|
-
([4f98392](https://github.com/ho-nl/m2-pwa/commit/4f9839250b3a32d3070da5290e5efcc5e2243fba))
|
|
318
|
+
- ignore md files from triggering version updates ([4f98392](https://github.com/ho-nl/m2-pwa/commit/4f9839250b3a32d3070da5290e5efcc5e2243fba))
|
|
@@ -1,29 +1,27 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { ApolloCartErrorSnackbar } from '@graphcommerce/magento-cart'
|
|
2
|
+
import { LinkOrButton, LinkOrButtonProps } from '@graphcommerce/next-ui'
|
|
3
3
|
import { ComposedSubmit, ComposedSubmitRenderComponentProps } from '@graphcommerce/react-hook-form'
|
|
4
4
|
import { usePaymentMethodContext } from '../PaymentMethodContext/PaymentMethodContext'
|
|
5
5
|
|
|
6
6
|
export type PaymentMethodButtonProps = LinkOrButtonProps & { display?: 'inline' | 'block' }
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
function PaymentMethodButtonRenderer(
|
|
9
9
|
props: { buttonProps: LinkOrButtonProps } & ComposedSubmitRenderComponentProps,
|
|
10
10
|
) {
|
|
11
11
|
const { buttonProps, error, buttonState, submit } = props
|
|
12
12
|
const { selectedMethod, selectedModule } = usePaymentMethodContext()
|
|
13
13
|
|
|
14
|
-
const btnProps = { ...buttonProps, name: 'placeOrder' }
|
|
15
|
-
|
|
16
14
|
const PaymentButton = selectedModule?.PaymentButton
|
|
17
15
|
|
|
18
16
|
return (
|
|
19
17
|
<>
|
|
20
18
|
{!PaymentButton || !selectedMethod?.code ? (
|
|
21
19
|
<LinkOrButton
|
|
22
|
-
{...
|
|
20
|
+
{...buttonProps}
|
|
23
21
|
onClick={submit}
|
|
24
22
|
loading={buttonState.isSubmitting || (buttonState.isSubmitSuccessful && !error)}
|
|
25
23
|
>
|
|
26
|
-
{
|
|
24
|
+
{buttonProps.children}
|
|
27
25
|
{selectedMethod?.title && (
|
|
28
26
|
<>
|
|
29
27
|
{' '}
|
|
@@ -35,7 +33,7 @@ export function PaymentMethodButtonRenderer(
|
|
|
35
33
|
<PaymentButton
|
|
36
34
|
{...selectedMethod}
|
|
37
35
|
buttonProps={{
|
|
38
|
-
...
|
|
36
|
+
...buttonProps,
|
|
39
37
|
onClick: submit,
|
|
40
38
|
loading: buttonState.isSubmitting || (buttonState.isSubmitSuccessful && !error),
|
|
41
39
|
}}
|
|
@@ -45,7 +43,7 @@ export function PaymentMethodButtonRenderer(
|
|
|
45
43
|
)
|
|
46
44
|
}
|
|
47
45
|
|
|
48
|
-
export
|
|
46
|
+
export function PaymentMethodButton(props: PaymentMethodButtonProps) {
|
|
49
47
|
const { display, ...buttonProps } = props
|
|
50
48
|
|
|
51
49
|
return (
|
|
@@ -65,7 +63,7 @@ export default function PaymentMethodButton(props: PaymentMethodButtonProps) {
|
|
|
65
63
|
) : (
|
|
66
64
|
<>
|
|
67
65
|
{button}
|
|
68
|
-
<
|
|
66
|
+
<ApolloCartErrorSnackbar key='error' error={errorVal} />
|
|
69
67
|
</>
|
|
70
68
|
)
|
|
71
69
|
}}
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { useCartQuery } from '@graphcommerce/magento-cart'
|
|
2
|
-
import React, { PropsWithChildren, useContext, useEffect, useState } from 'react'
|
|
2
|
+
import React, { PropsWithChildren, useContext, useEffect, useMemo, useState } from 'react'
|
|
3
3
|
import { PaymentMethod, PaymentMethodModules, PaymentModule } from '../Api/PaymentMethod'
|
|
4
4
|
import { GetPaymentMethodContextDocument } from './GetPaymentMethodContext.gql'
|
|
5
5
|
|
|
6
6
|
type PaymentMethodContextProps = {
|
|
7
7
|
methods: PaymentMethod[]
|
|
8
8
|
selectedMethod?: PaymentMethod
|
|
9
|
-
setSelectedMethod(method: PaymentMethod | undefined)
|
|
9
|
+
setSelectedMethod: (method: PaymentMethod | undefined) => void
|
|
10
10
|
modules: PaymentMethodModules
|
|
11
11
|
selectedModule?: PaymentModule
|
|
12
|
-
setSelectedModule(module: PaymentModule | undefined)
|
|
12
|
+
setSelectedModule: (module: PaymentModule | undefined) => void
|
|
13
13
|
}
|
|
14
14
|
|
|
15
15
|
const paymentMethodContext = React.createContext<PaymentMethodContextProps>({
|
|
@@ -22,7 +22,7 @@ paymentMethodContext.displayName = 'PaymentMethodContext'
|
|
|
22
22
|
|
|
23
23
|
type PaymentMethodContextProviderProps = PropsWithChildren<{ modules: PaymentMethodModules }>
|
|
24
24
|
|
|
25
|
-
export
|
|
25
|
+
export function PaymentMethodContextProvider(props: PaymentMethodContextProviderProps) {
|
|
26
26
|
const { modules, children } = props
|
|
27
27
|
|
|
28
28
|
const context = useCartQuery(GetPaymentMethodContextDocument)
|
|
@@ -53,25 +53,30 @@ export default function PaymentMethodContextProvider(props: PaymentMethodContext
|
|
|
53
53
|
) ?? []
|
|
54
54
|
|
|
55
55
|
const loaded = (await Promise.all(promises)).flat(1).sort((a) => (a.preferred ? 1 : 0))
|
|
56
|
-
const sortedMethods = loaded.sort((a, b) =>
|
|
57
|
-
!modules?.[a?.code]
|
|
58
|
-
|
|
56
|
+
const sortedMethods = loaded.sort((a, b) => {
|
|
57
|
+
if (!modules?.[a?.code]) return 0
|
|
58
|
+
if (!modules?.[b?.code]) return -1
|
|
59
|
+
return 1
|
|
60
|
+
})
|
|
59
61
|
|
|
60
62
|
setMethods(sortedMethods)
|
|
61
63
|
})()
|
|
62
64
|
}, [cartContext, modules])
|
|
63
65
|
|
|
66
|
+
const value = useMemo(
|
|
67
|
+
() => ({
|
|
68
|
+
methods,
|
|
69
|
+
selectedMethod,
|
|
70
|
+
setSelectedMethod,
|
|
71
|
+
modules,
|
|
72
|
+
selectedModule,
|
|
73
|
+
setSelectedModule,
|
|
74
|
+
}),
|
|
75
|
+
[methods, modules, selectedMethod, selectedModule],
|
|
76
|
+
)
|
|
77
|
+
|
|
64
78
|
return (
|
|
65
|
-
<paymentMethodContext.Provider
|
|
66
|
-
value={{
|
|
67
|
-
methods,
|
|
68
|
-
selectedMethod,
|
|
69
|
-
setSelectedMethod,
|
|
70
|
-
modules,
|
|
71
|
-
selectedModule,
|
|
72
|
-
setSelectedModule,
|
|
73
|
-
}}
|
|
74
|
-
>
|
|
79
|
+
<paymentMethodContext.Provider value={value}>
|
|
75
80
|
{Object.entries(modules).map(([method, module]) => {
|
|
76
81
|
const { PaymentHandler } = module
|
|
77
82
|
if (!PaymentHandler) return null
|
|
@@ -8,9 +8,7 @@ const name = 'PaymentMethodOptions' as const
|
|
|
8
8
|
const parts = ['root'] as const
|
|
9
9
|
const { classes } = extendableComponent(name, parts)
|
|
10
10
|
|
|
11
|
-
export
|
|
12
|
-
props: PaymentMethodOptionsProps & { sx?: SxProps<Theme> },
|
|
13
|
-
) {
|
|
11
|
+
export function PaymentMethodOptions(props: PaymentMethodOptionsProps & { sx?: SxProps<Theme> }) {
|
|
14
12
|
const { sx = [], ...optionsProps } = props
|
|
15
13
|
const { selectedMethod, selectedModule } = usePaymentMethodContext()
|
|
16
14
|
|
|
@@ -4,7 +4,7 @@ import { PaymentOptionsProps } from '../Api/PaymentMethod'
|
|
|
4
4
|
import { PaymentMethodOptionsNoopDocument } from './PaymentMethodOptionsNoop.gql'
|
|
5
5
|
|
|
6
6
|
/** It sets the selected payment method on the cart. */
|
|
7
|
-
function PaymentMethodOptionsNoop(props: PaymentOptionsProps) {
|
|
7
|
+
export function PaymentMethodOptionsNoop(props: PaymentOptionsProps) {
|
|
8
8
|
const { code, step } = props
|
|
9
9
|
|
|
10
10
|
/**
|
|
@@ -26,5 +26,3 @@ function PaymentMethodOptionsNoop(props: PaymentOptionsProps) {
|
|
|
26
26
|
</form>
|
|
27
27
|
)
|
|
28
28
|
}
|
|
29
|
-
|
|
30
|
-
export default PaymentMethodOptionsNoop
|
|
@@ -3,7 +3,7 @@ import { usePaymentMethodContext } from '../PaymentMethodContext/PaymentMethodCo
|
|
|
3
3
|
|
|
4
4
|
export type PaymentMethodPlaceOrderProps = Pick<UseFormComposeOptions, 'step'>
|
|
5
5
|
|
|
6
|
-
export
|
|
6
|
+
export function PaymentMethodPlaceOrder(props: PaymentMethodPlaceOrderProps) {
|
|
7
7
|
const { step } = props
|
|
8
8
|
const { selectedMethod, selectedModule } = usePaymentMethodContext()
|
|
9
9
|
|
|
@@ -9,7 +9,7 @@ import { useEffect } from 'react'
|
|
|
9
9
|
import { PaymentPlaceOrderProps } from '../Api/PaymentMethod'
|
|
10
10
|
import { PaymentMethodPlaceOrderNoopDocument } from './PaymentMethodPlaceOrderNoop.gql'
|
|
11
11
|
|
|
12
|
-
export
|
|
12
|
+
export function PaymentMethodPlaceOrderNoop(props: PaymentPlaceOrderProps) {
|
|
13
13
|
const { step, code } = props
|
|
14
14
|
const clearCurrentCartId = useClearCurrentCartId()
|
|
15
15
|
|
|
@@ -23,7 +23,7 @@ export default function PaymentMethodPlaceOrderNoop(props: PaymentPlaceOrderProp
|
|
|
23
23
|
if (!data?.placeOrder?.order || error || !cartId) return
|
|
24
24
|
clearCurrentCartId()
|
|
25
25
|
// eslint-disable-next-line @typescript-eslint/no-floating-promises
|
|
26
|
-
push({ pathname: '/checkout/success', query: { cartId } })
|
|
26
|
+
push({ pathname: '/checkout/success', query: { cart_id: cartId } })
|
|
27
27
|
}, [cartId, clearCurrentCartId, data?.placeOrder?.order, error, push])
|
|
28
28
|
|
|
29
29
|
const submit = handleSubmit(() => {})
|
|
@@ -47,7 +47,7 @@ const parts = [
|
|
|
47
47
|
] as const
|
|
48
48
|
const { classes } = extendableComponent(cmpName, parts)
|
|
49
49
|
|
|
50
|
-
export
|
|
50
|
+
export function PaymentMethodToggles(props: PaymentMethodTogglesProps) {
|
|
51
51
|
const { step, sx = [] } = props
|
|
52
52
|
const { methods, selectedMethod, setSelectedMethod, setSelectedModule, modules } =
|
|
53
53
|
usePaymentMethodContext()
|
|
@@ -141,7 +141,7 @@ export default function PaymentMethodToggles(props: PaymentMethodTogglesProps) {
|
|
|
141
141
|
}}
|
|
142
142
|
>
|
|
143
143
|
{methods?.map((pm) => {
|
|
144
|
-
const buttonValue = `${pm.code}___${pm.child}`
|
|
144
|
+
const buttonValue = pm.child ? `${pm.code}___${pm.child}` : pm.code
|
|
145
145
|
return (
|
|
146
146
|
<ToggleButton
|
|
147
147
|
name={name}
|
package/hooks/useCartLock.ts
CHANGED
|
@@ -1,7 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
import { useCurrentCartId } from '@graphcommerce/magento-cart'
|
|
2
|
+
import { useUrlQuery } from '@graphcommerce/next-ui'
|
|
3
|
+
|
|
4
|
+
export type CartLockState = {
|
|
5
|
+
cart_id?: string
|
|
6
|
+
locked?: string
|
|
7
|
+
}
|
|
5
8
|
|
|
6
9
|
/**
|
|
7
10
|
* Locking a cart might is usefull in the following cases: We want to disable cart modifications
|
|
@@ -9,25 +12,15 @@ import { UseCartLockDocument } from './UseCartLock.gql'
|
|
|
9
12
|
*
|
|
10
13
|
* Todo: Block all operations on the cart while the cart is being blocked.
|
|
11
14
|
*/
|
|
12
|
-
export function useCartLock() {
|
|
13
|
-
const
|
|
14
|
-
const cartId = useCurrentCartId()
|
|
15
|
-
|
|
16
|
-
const locked = useCartQuery(UseCartLockDocument, { allowUrl: true }).data?.cart?.locked ?? false
|
|
15
|
+
export function useCartLock<E extends Record<string, string | undefined>>() {
|
|
16
|
+
const currentCartId = useCurrentCartId()
|
|
17
17
|
|
|
18
|
-
const
|
|
19
|
-
(locking: boolean) => {
|
|
20
|
-
if (!cartId) return
|
|
18
|
+
const [queryState, setRouterQuery] = useUrlQuery<CartLockState & E>((params) => params)
|
|
21
19
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
broadcast: true,
|
|
27
|
-
})
|
|
28
|
-
},
|
|
29
|
-
[cache, cartId],
|
|
30
|
-
)
|
|
20
|
+
const lock = (params: CartLockState & E) => {
|
|
21
|
+
if (!currentCartId) return
|
|
22
|
+
setRouterQuery({ locked: '1', cart_id: currentCartId, ...params })
|
|
23
|
+
}
|
|
31
24
|
|
|
32
|
-
return
|
|
25
|
+
return [queryState, lock] as const
|
|
33
26
|
}
|
package/index.ts
CHANGED
|
@@ -1,19 +1,10 @@
|
|
|
1
1
|
export * from './Api/PaymentMethod'
|
|
2
2
|
export * from './hooks'
|
|
3
|
-
|
|
4
|
-
export * from './PaymentMethodContext/PaymentMethodContext'
|
|
5
|
-
export { default as PaymentMethodContextProvider } from './PaymentMethodContext/PaymentMethodContext'
|
|
6
|
-
|
|
7
3
|
export * from './PaymentMethodButton/PaymentMethodButton'
|
|
8
|
-
export
|
|
9
|
-
|
|
10
|
-
export
|
|
11
|
-
|
|
4
|
+
export * from './PaymentMethodContext/PaymentMethodContext'
|
|
5
|
+
export * from './PaymentMethodOptions/PaymentMethodOptions'
|
|
6
|
+
export * from './PaymentMethodOptionsNoop/PaymentMethodOptionsNoop'
|
|
12
7
|
export * from './PaymentMethodOptionsNoop/PaymentMethodOptionsNoop.gql'
|
|
13
|
-
export
|
|
14
|
-
|
|
15
|
-
export { default as PaymentMethodPlaceOrder } from './PaymentMethodPlaceOrder/PaymentMethodPlaceOrder'
|
|
16
|
-
export { default as PaymentMethodPlaceOrderNoop } from './PaymentMethodPlaceOrderNoop/PaymentMethodPlaceOrderNoop'
|
|
17
|
-
|
|
8
|
+
export * from './PaymentMethodPlaceOrder/PaymentMethodPlaceOrder'
|
|
9
|
+
export * from './PaymentMethodPlaceOrderNoop/PaymentMethodPlaceOrderNoop'
|
|
18
10
|
export * from './PaymentMethodToggles/PaymentMethodToggles'
|
|
19
|
-
export { default as PaymentMethodToggles } from './PaymentMethodToggles/PaymentMethodToggles'
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@graphcommerce/magento-cart-payment-method",
|
|
3
3
|
"homepage": "https://www.graphcommerce.org/",
|
|
4
4
|
"repository": "github:graphcommerce-org/graphcommerce",
|
|
5
|
-
"version": "3.0.
|
|
5
|
+
"version": "3.0.7",
|
|
6
6
|
"sideEffects": false,
|
|
7
7
|
"engines": {
|
|
8
8
|
"node": "14.x"
|
|
@@ -15,26 +15,26 @@
|
|
|
15
15
|
}
|
|
16
16
|
},
|
|
17
17
|
"devDependencies": {
|
|
18
|
-
"@graphcommerce/eslint-config-pwa": "^4.
|
|
19
|
-
"@graphcommerce/prettier-config-pwa": "^4.0.
|
|
18
|
+
"@graphcommerce/eslint-config-pwa": "^4.1.4",
|
|
19
|
+
"@graphcommerce/prettier-config-pwa": "^4.0.5",
|
|
20
20
|
"@graphcommerce/typescript-config-pwa": "^4.0.2",
|
|
21
|
-
"@playwright/test": "^1.
|
|
21
|
+
"@playwright/test": "^1.20.1",
|
|
22
|
+
"type-fest": "2.12.1"
|
|
22
23
|
},
|
|
23
24
|
"dependencies": {
|
|
24
|
-
"@graphcommerce/framer-scroller": "
|
|
25
|
-
"@graphcommerce/graphql": "
|
|
26
|
-
"@graphcommerce/image": "
|
|
27
|
-
"@graphcommerce/magento-cart": "
|
|
28
|
-
"@graphcommerce/magento-store": "
|
|
29
|
-
"@graphcommerce/next-ui": "
|
|
30
|
-
"@graphcommerce/react-hook-form": "
|
|
31
|
-
"type-fest": "^2.12.0"
|
|
25
|
+
"@graphcommerce/framer-scroller": "2.1.4",
|
|
26
|
+
"@graphcommerce/graphql": "3.0.7",
|
|
27
|
+
"@graphcommerce/image": "3.1.3",
|
|
28
|
+
"@graphcommerce/magento-cart": "4.2.3",
|
|
29
|
+
"@graphcommerce/magento-store": "4.1.5",
|
|
30
|
+
"@graphcommerce/next-ui": "4.5.1",
|
|
31
|
+
"@graphcommerce/react-hook-form": "3.0.7"
|
|
32
32
|
},
|
|
33
33
|
"peerDependencies": {
|
|
34
34
|
"@lingui/macro": "^3.13.2",
|
|
35
|
-
"@mui/material": "
|
|
35
|
+
"@mui/material": "5.5.3",
|
|
36
36
|
"framer-motion": "^6.2.4",
|
|
37
|
-
"next": "
|
|
37
|
+
"next": "12.1.2",
|
|
38
38
|
"react": "^17.0.1",
|
|
39
39
|
"react-dom": "^17.0.1"
|
|
40
40
|
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { ApolloClient, NormalizedCacheObject } from '@graphcommerce/graphql'
|
|
2
|
+
import { fillShippingAddressForm } from '@graphcommerce/magento-cart-shipping-address/test/fillShippingAddressForm'
|
|
3
|
+
import { fillCartAgreementsForm } from '@graphcommerce/magento-cart/test/fillCartAgreementsForm'
|
|
4
|
+
import { Page } from '@playwright/test'
|
|
5
|
+
|
|
6
|
+
export const goToPayment = async (
|
|
7
|
+
page: Page,
|
|
8
|
+
apolloClient: ApolloClient<NormalizedCacheObject>,
|
|
9
|
+
) => {
|
|
10
|
+
await page.locator('a:has-text("View shopping cart")').click()
|
|
11
|
+
|
|
12
|
+
await page.locator('text=Start Checkout').click()
|
|
13
|
+
|
|
14
|
+
const email = page.locator('input[name="email"]')
|
|
15
|
+
await email.click()
|
|
16
|
+
await email.fill('test@test.com')
|
|
17
|
+
|
|
18
|
+
await fillShippingAddressForm(page)
|
|
19
|
+
|
|
20
|
+
await page.click('button[value=flatrate-flatrate]')
|
|
21
|
+
await page.click('#next')
|
|
22
|
+
|
|
23
|
+
// Fill in the agreements
|
|
24
|
+
await fillCartAgreementsForm(page, apolloClient)
|
|
25
|
+
}
|