ordering-ui-react-native 0.18.54 → 0.18.55-test1
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
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ordering-ui-react-native",
|
|
3
|
-
"version": "0.18.
|
|
3
|
+
"version": "0.18.55-test1",
|
|
4
4
|
"description": "Reusable components made in react native",
|
|
5
5
|
"main": "src/index.tsx",
|
|
6
6
|
"author": "ordering.inc",
|
|
@@ -49,8 +49,8 @@
|
|
|
49
49
|
"@react-navigation/material-bottom-tabs": "^5.3.14",
|
|
50
50
|
"@react-navigation/native": "^5.7.6",
|
|
51
51
|
"@react-navigation/stack": "^5.9.3",
|
|
52
|
-
"@segment/analytics-react-native": "^2.
|
|
53
|
-
|
|
52
|
+
"@segment/analytics-react-native": "^2.13.2",
|
|
53
|
+
"@segment/sovran-react-native": "^1.0.1",
|
|
54
54
|
"@sentry/react-native": "^2.6.0",
|
|
55
55
|
"@stripe/stripe-react-native": "^0.2.0",
|
|
56
56
|
"@types/react-native-loading-spinner-overlay": "^0.5.2",
|
|
@@ -83,6 +83,7 @@
|
|
|
83
83
|
"react-native-fbsdk-next": "^7.0.1",
|
|
84
84
|
"react-native-geocoding": "^0.5.0",
|
|
85
85
|
"react-native-gesture-handler": "^1.8.0",
|
|
86
|
+
"react-native-get-random-values": "^1.8.0",
|
|
86
87
|
"react-native-gifted-chat": "^0.16.3",
|
|
87
88
|
"react-native-google-places-autocomplete": "^2.1.3",
|
|
88
89
|
"react-native-html-to-pdf": "^0.10.0",
|
|
@@ -170,6 +170,10 @@ const LoginFormUI = (props: LoginParams) => {
|
|
|
170
170
|
vibrateApp()
|
|
171
171
|
return
|
|
172
172
|
}
|
|
173
|
+
if(!values?.cellphone && otpType === 'cellphone'){
|
|
174
|
+
showToast(ToastType.Error, t('PHONE_NUMBER_REQUIRED', 'Phone number is required'));
|
|
175
|
+
return
|
|
176
|
+
}
|
|
173
177
|
if (loginTab === 'otp') {
|
|
174
178
|
generateOtpCode({
|
|
175
179
|
...values,
|
|
@@ -253,6 +257,7 @@ const LoginFormUI = (props: LoginParams) => {
|
|
|
253
257
|
}
|
|
254
258
|
|
|
255
259
|
const handleLoginOtp = (code: string) => {
|
|
260
|
+
if (!code) return
|
|
256
261
|
handleButtonLoginClick({ code })
|
|
257
262
|
setWillVerifyOtpState(false)
|
|
258
263
|
}
|
|
@@ -152,7 +152,7 @@ const OrderProgressUI = (props: any) => {
|
|
|
152
152
|
</OrderInfoWrapper>
|
|
153
153
|
<View style={{ flex: 1 }}>
|
|
154
154
|
<ProgressContentWrapper>
|
|
155
|
-
<ProgressBar style={{ width: getOrderStatus(lastOrder.status)?.percentage ? `${getOrderStatus(lastOrder.status)
|
|
155
|
+
<ProgressBar style={{ width: getOrderStatus(lastOrder.status)?.percentage ? `${(getOrderStatus(lastOrder.status) as any).percentage * 100}%` : '0%' }} />
|
|
156
156
|
</ProgressContentWrapper>
|
|
157
157
|
<ProgressTextWrapper>
|
|
158
158
|
<OText size={12} style={{ width: '50%' }}>{getOrderStatus(lastOrder.status)?.value}</OText>
|
|
@@ -495,7 +495,7 @@ export const getOrderStatus = (s: string) => {
|
|
|
495
495
|
'Order picked up completed by customer',
|
|
496
496
|
),
|
|
497
497
|
slug: 'ORDER_PICKEDUP_COMPLETED_BY_CUSTOMER',
|
|
498
|
-
percentage:
|
|
498
|
+
percentage: 1,
|
|
499
499
|
image: theme.images.order.status1,
|
|
500
500
|
},
|
|
501
501
|
{
|
|
@@ -542,7 +542,7 @@ export const getOrderStatus = (s: string) => {
|
|
|
542
542
|
'Customer almost arrived to business',
|
|
543
543
|
),
|
|
544
544
|
slug: 'ORDER_CUSTOMER_ALMOST_ARRIVED_BUSINESS',
|
|
545
|
-
percentage:
|
|
545
|
+
percentage: 0.9,
|
|
546
546
|
image: theme.images.order.status7,
|
|
547
547
|
},
|
|
548
548
|
{
|
|
@@ -552,21 +552,21 @@ export const getOrderStatus = (s: string) => {
|
|
|
552
552
|
'Customer arrived to business',
|
|
553
553
|
),
|
|
554
554
|
slug: 'ORDER_CUSTOMER_ARRIVED_BUSINESS',
|
|
555
|
-
percentage: 95,
|
|
555
|
+
percentage: 0.95,
|
|
556
556
|
image: theme.images.order.status7,
|
|
557
557
|
},
|
|
558
558
|
{
|
|
559
559
|
key: 22,
|
|
560
560
|
value: t('ORDER_LOOKING_FOR_DRIVER', 'Looking for driver'),
|
|
561
561
|
slug: 'ORDER_LOOKING_FOR_DRIVER',
|
|
562
|
-
percentage: 35,
|
|
562
|
+
percentage: 0.35,
|
|
563
563
|
image: theme.images.order.status8
|
|
564
564
|
},
|
|
565
565
|
{
|
|
566
566
|
key: 23,
|
|
567
567
|
value: t('ORDER_DRIVER_ON_WAY', 'Driver on way'),
|
|
568
568
|
slug: 'ORDER_DRIVER_ON_WAY',
|
|
569
|
-
percentage: 45,
|
|
569
|
+
percentage: 0.45,
|
|
570
570
|
image: theme.images.order.status8
|
|
571
571
|
}
|
|
572
572
|
];
|