ordering-ui-react-native 0.21.97 → 0.21.98
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/package.json +1 -1
- package/src/components/StripeMethodForm/index.tsx +3 -3
- package/src/types/index.tsx +2 -1
- package/themes/original/src/components/Checkout/index.tsx +2 -0
- package/themes/original/src/components/OrderProgress/index.tsx +2 -2
- package/themes/original/src/components/PaymentOptions/index.tsx +4 -1
- package/themes/original/src/components/StripeElementsForm/index.tsx +3 -1
package/package.json
CHANGED
|
@@ -3,7 +3,6 @@ import { useLanguage, useConfig, useOrder } from 'ordering-components/native'
|
|
|
3
3
|
import { useGooglePay, useApplePay } from '@stripe/stripe-react-native'
|
|
4
4
|
import { Platform } from 'react-native';
|
|
5
5
|
import { StripeMethodFormParams } from '../../types';
|
|
6
|
-
import { android_app_id } from '../../config.json'
|
|
7
6
|
|
|
8
7
|
export const StripeMethodForm = (props: StripeMethodFormParams) => {
|
|
9
8
|
const {
|
|
@@ -17,7 +16,8 @@ export const StripeMethodForm = (props: StripeMethodFormParams) => {
|
|
|
17
16
|
placeByMethodPay,
|
|
18
17
|
methodPaySupported,
|
|
19
18
|
setPlaceByMethodPay,
|
|
20
|
-
cartTotal
|
|
19
|
+
cartTotal,
|
|
20
|
+
androidAppId
|
|
21
21
|
} = props
|
|
22
22
|
const { initGooglePay, createGooglePayPaymentMethod, loading } = useGooglePay();
|
|
23
23
|
const { presentApplePay, isApplePaySupported } = useApplePay();
|
|
@@ -61,7 +61,7 @@ export const StripeMethodForm = (props: StripeMethodFormParams) => {
|
|
|
61
61
|
})
|
|
62
62
|
const { error } = await initGooglePay({
|
|
63
63
|
testEnv: devMode,
|
|
64
|
-
merchantName:
|
|
64
|
+
merchantName: androidAppId,
|
|
65
65
|
countryCode: 'US',
|
|
66
66
|
billingAddressConfig: {
|
|
67
67
|
format: 'FULL',
|
package/src/types/index.tsx
CHANGED
|
@@ -102,6 +102,7 @@ const CheckoutUI = (props: any) => {
|
|
|
102
102
|
merchantId,
|
|
103
103
|
setPlaceSpotNumber,
|
|
104
104
|
maxDate,
|
|
105
|
+
androidAppId,
|
|
105
106
|
urlscheme
|
|
106
107
|
} = props
|
|
107
108
|
|
|
@@ -819,6 +820,7 @@ const CheckoutUI = (props: any) => {
|
|
|
819
820
|
handlePlaceOrder={handlePlaceOrder}
|
|
820
821
|
merchantId={merchantId}
|
|
821
822
|
urlscheme={urlscheme}
|
|
823
|
+
androidAppId={androidAppId}
|
|
822
824
|
setMethodPaySupported={setMethodPaySupported}
|
|
823
825
|
methodPaySupported={methodPaySupported}
|
|
824
826
|
placeByMethodPay={placeByMethodPay}
|
|
@@ -58,8 +58,8 @@ const OrderProgressUI = (props: any) => {
|
|
|
58
58
|
shadowOpacity: 0.2,
|
|
59
59
|
shadowRadius: 2,
|
|
60
60
|
elevation: 3,
|
|
61
|
-
borderWidth:
|
|
62
|
-
borderColor: 'rgba(0,0,0,0.
|
|
61
|
+
borderWidth: 1,
|
|
62
|
+
borderColor: 'rgba(0,0,0,0.1)'
|
|
63
63
|
},
|
|
64
64
|
logoWrapper: {
|
|
65
65
|
overflow: 'hidden',
|
|
@@ -75,7 +75,8 @@ const PaymentOptionsUI = (props: any) => {
|
|
|
75
75
|
requiredFields,
|
|
76
76
|
openUserModal,
|
|
77
77
|
paymethodClicked,
|
|
78
|
-
setPaymethodClicked
|
|
78
|
+
setPaymethodClicked,
|
|
79
|
+
androidAppId
|
|
79
80
|
} = props
|
|
80
81
|
|
|
81
82
|
const theme = useTheme();
|
|
@@ -362,6 +363,7 @@ const PaymentOptionsUI = (props: any) => {
|
|
|
362
363
|
onCancel={() => handlePaymethodClick(null)}
|
|
363
364
|
merchantId={merchantId}
|
|
364
365
|
urlscheme={urlscheme}
|
|
366
|
+
androidAppId={androidAppId}
|
|
365
367
|
setMethodPaySupported={setMethodPaySupported}
|
|
366
368
|
methodPaySupported={methodPaySupported}
|
|
367
369
|
placeByMethodPay={placeByMethodPay}
|
|
@@ -410,6 +412,7 @@ const PaymentOptionsUI = (props: any) => {
|
|
|
410
412
|
onCancel={() => handlePaymethodClick(null)}
|
|
411
413
|
merchantId={merchantId}
|
|
412
414
|
urlscheme={urlscheme}
|
|
415
|
+
androidAppId={androidAppId}
|
|
413
416
|
publicKeyAddCard={isOpenMethod?.paymethod?.credentials?.stripe?.publishable}
|
|
414
417
|
/>
|
|
415
418
|
</KeyboardAvoidingView>
|
|
@@ -35,7 +35,8 @@ const StripeElementsFormUI = (props: any) => {
|
|
|
35
35
|
setPlaceByMethodPay,
|
|
36
36
|
cartTotal,
|
|
37
37
|
publicKeyAddCard,
|
|
38
|
-
urlScheme
|
|
38
|
+
urlScheme,
|
|
39
|
+
androidAppId
|
|
39
40
|
} = props;
|
|
40
41
|
|
|
41
42
|
const theme = useTheme();
|
|
@@ -220,6 +221,7 @@ const StripeElementsFormUI = (props: any) => {
|
|
|
220
221
|
placeByMethodPay={placeByMethodPay}
|
|
221
222
|
methodPaySupported={methodPaySupported}
|
|
222
223
|
setPlaceByMethodPay={setPlaceByMethodPay}
|
|
224
|
+
androidAppId={androidAppId}
|
|
223
225
|
/>
|
|
224
226
|
) : (
|
|
225
227
|
<CardField
|