@graphcommerce/magento-payment-braintree 9.0.4-canary.0 → 9.0.4-canary.2
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
@@ -120,6 +120,7 @@ export function PaymentMethodOptions(props: PaymentOptionsProps) {
|
|
120
120
|
code,
|
121
121
|
}
|
122
122
|
} catch (e) {
|
123
|
+
// eslint-disable-next-line @typescript-eslint/no-floating-promises
|
123
124
|
if (isBraintreeError(e)) unlock({ payment_id: null })
|
124
125
|
throw e
|
125
126
|
}
|
@@ -132,7 +133,10 @@ export function PaymentMethodOptions(props: PaymentOptionsProps) {
|
|
132
133
|
/** To use an external Pay button we register the current form to be handled there as well. */
|
133
134
|
useFormCompose({ form, step, submit, key: `PaymentMethodOptions_${code}` })
|
134
135
|
|
135
|
-
/**
|
136
|
+
/**
|
137
|
+
* This is the form that the user can fill in. In this case we don't wat the user to fill in
|
138
|
+
* anything.
|
139
|
+
*/
|
136
140
|
return (
|
137
141
|
<form onSubmit={submit}>
|
138
142
|
<input type='hidden' {...register('code')} />
|
@@ -1,8 +1,8 @@
|
|
1
1
|
import type { PaymentModule } from '@graphcommerce/magento-cart-payment-method'
|
2
2
|
import { PaymentMethodPlaceOrderNoop } from '@graphcommerce/magento-cart-payment-method'
|
3
|
+
import { expandMethods } from './expandMethods'
|
3
4
|
import { PaymentHandler } from './PaymentHandler'
|
4
5
|
import { PaymentMethodOptions } from './PaymentMethodOptions'
|
5
|
-
import { expandMethods } from './expandMethods'
|
6
6
|
|
7
7
|
export const braintree_local_payment: PaymentModule = {
|
8
8
|
PaymentOptions: PaymentMethodOptions,
|
@@ -14,9 +14,7 @@ import { BraintreeLocalPaymentsCartDocument } from '../braintree_local_payments/
|
|
14
14
|
export function PaymentMethodOptions(props: PaymentOptionsProps) {
|
15
15
|
const paypal = useBraintreePaypal()
|
16
16
|
|
17
|
-
|
18
|
-
|
19
|
-
const { code, step, child } = props
|
17
|
+
const { code, step } = props
|
20
18
|
const { data: cartData } = useCartQuery(BraintreeLocalPaymentsCartDocument)
|
21
19
|
const [lockState, lock, unlock] = useBraintreeCartLock()
|
22
20
|
const { selectedMethod } = usePaymentMethodContext()
|
@@ -76,7 +74,10 @@ export function PaymentMethodOptions(props: PaymentOptionsProps) {
|
|
76
74
|
/** To use an external Pay button we register the current form to be handled there as well. */
|
77
75
|
useFormCompose({ form, step, submit, key: `PaymentMethodOptions_${code}` })
|
78
76
|
|
79
|
-
/**
|
77
|
+
/**
|
78
|
+
* This is the form that the user can fill in. In this case we don't wat the user to fill in
|
79
|
+
* anything.
|
80
|
+
*/
|
80
81
|
return (
|
81
82
|
<form onSubmit={submit}>
|
82
83
|
<input type='hidden' {...register('code')} />
|
package/package.json
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
"name": "@graphcommerce/magento-payment-braintree",
|
3
3
|
"homepage": "https://www.graphcommerce.org/",
|
4
4
|
"repository": "github:graphcommerce-org/graphcommerce",
|
5
|
-
"version": "9.0.4-canary.
|
5
|
+
"version": "9.0.4-canary.2",
|
6
6
|
"sideEffects": false,
|
7
7
|
"prettier": "@graphcommerce/prettier-config-pwa",
|
8
8
|
"eslintConfig": {
|
@@ -18,19 +18,19 @@
|
|
18
18
|
"braintree-web": "^3.112.1"
|
19
19
|
},
|
20
20
|
"peerDependencies": {
|
21
|
-
"@graphcommerce/eslint-config-pwa": "^9.0.4-canary.
|
22
|
-
"@graphcommerce/graphql": "^9.0.4-canary.
|
23
|
-
"@graphcommerce/image": "^9.0.4-canary.
|
24
|
-
"@graphcommerce/magento-cart": "^9.0.4-canary.
|
25
|
-
"@graphcommerce/magento-cart-payment-method": "^9.0.4-canary.
|
26
|
-
"@graphcommerce/magento-cart-shipping-address": "^9.0.4-canary.
|
27
|
-
"@graphcommerce/magento-product": "^9.0.4-canary.
|
28
|
-
"@graphcommerce/magento-product-configurable": "^9.0.4-canary.
|
29
|
-
"@graphcommerce/magento-store": "^9.0.4-canary.
|
30
|
-
"@graphcommerce/next-ui": "^9.0.4-canary.
|
31
|
-
"@graphcommerce/prettier-config-pwa": "^9.0.4-canary.
|
32
|
-
"@graphcommerce/react-hook-form": "^9.0.4-canary.
|
33
|
-
"@graphcommerce/typescript-config-pwa": "^9.0.4-canary.
|
21
|
+
"@graphcommerce/eslint-config-pwa": "^9.0.4-canary.2",
|
22
|
+
"@graphcommerce/graphql": "^9.0.4-canary.2",
|
23
|
+
"@graphcommerce/image": "^9.0.4-canary.2",
|
24
|
+
"@graphcommerce/magento-cart": "^9.0.4-canary.2",
|
25
|
+
"@graphcommerce/magento-cart-payment-method": "^9.0.4-canary.2",
|
26
|
+
"@graphcommerce/magento-cart-shipping-address": "^9.0.4-canary.2",
|
27
|
+
"@graphcommerce/magento-product": "^9.0.4-canary.2",
|
28
|
+
"@graphcommerce/magento-product-configurable": "^9.0.4-canary.2",
|
29
|
+
"@graphcommerce/magento-store": "^9.0.4-canary.2",
|
30
|
+
"@graphcommerce/next-ui": "^9.0.4-canary.2",
|
31
|
+
"@graphcommerce/prettier-config-pwa": "^9.0.4-canary.2",
|
32
|
+
"@graphcommerce/react-hook-form": "^9.0.4-canary.2",
|
33
|
+
"@graphcommerce/typescript-config-pwa": "^9.0.4-canary.2",
|
34
34
|
"@lingui/core": "^4.2.1",
|
35
35
|
"@lingui/macro": "^4.2.1",
|
36
36
|
"@lingui/react": "^4.2.1",
|