ordering-ui-react-native 0.16.9 → 0.16.10-release

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.
Files changed (219) hide show
  1. package/package.json +8 -4
  2. package/src/DeliveryApp.tsx +43 -1
  3. package/src/components/ActiveOrders/index.tsx +61 -63
  4. package/src/components/ActiveOrders/styles.tsx +8 -14
  5. package/src/components/AddressForm/index.tsx +18 -2
  6. package/src/components/BusinessBasicInformation/index.tsx +11 -19
  7. package/src/components/BusinessController/index.tsx +10 -8
  8. package/src/components/BusinessInformation/index.tsx +22 -0
  9. package/src/components/BusinessTypeFilter/index.tsx +1 -2
  10. package/src/components/BusinessesListing/index.tsx +1 -1
  11. package/src/components/Checkout/index.tsx +2 -1
  12. package/src/components/LanguageSelector/index.tsx +21 -16
  13. package/src/components/LoginForm/index.tsx +118 -30
  14. package/src/components/LoginForm/styles.tsx +6 -0
  15. package/src/components/Messages/index.tsx +2 -2
  16. package/src/components/NotificationSetting/index.tsx +85 -0
  17. package/src/components/OrderDetails/index.tsx +7 -21
  18. package/src/components/OrdersOption/index.tsx +54 -56
  19. package/src/components/PaymentOptions/index.tsx +335 -365
  20. package/src/components/PaymentOptionsWebView/index.tsx +120 -121
  21. package/src/components/ReviewDriver/index.tsx +1 -1
  22. package/src/components/ReviewOrder/index.tsx +2 -1
  23. package/src/components/ReviewProducts/index.tsx +11 -0
  24. package/src/components/SignupForm/index.tsx +143 -61
  25. package/src/components/SingleProductReview/index.tsx +8 -5
  26. package/src/components/StripeElementsForm/index.tsx +25 -16
  27. package/src/components/StripeMethodForm/index.tsx +1 -2
  28. package/src/components/VerifyPhone/styles.tsx +1 -2
  29. package/src/components/shared/OBottomPopup.tsx +6 -2
  30. package/src/index.tsx +2 -0
  31. package/src/navigators/CheckoutNavigator.tsx +6 -0
  32. package/src/navigators/HomeNavigator.tsx +6 -0
  33. package/src/pages/BusinessesListing.tsx +7 -6
  34. package/src/pages/MultiCheckout.tsx +31 -0
  35. package/src/pages/MultiOrdersDetails.tsx +27 -0
  36. package/src/pages/OrderDetails.tsx +1 -1
  37. package/src/pages/ReviewDriver.tsx +2 -2
  38. package/src/pages/ReviewOrder.tsx +2 -2
  39. package/src/theme.json +0 -1
  40. package/src/types/@fatnlazycat/react-native-recaptcha-v3/index.d.ts +1 -0
  41. package/src/types/index.tsx +13 -9
  42. package/src/utils/index.tsx +0 -1
  43. package/themes/business/index.tsx +4 -0
  44. package/themes/business/src/components/BusinessController/index.tsx +2 -2
  45. package/themes/business/src/components/Chat/index.tsx +42 -34
  46. package/themes/business/src/components/DriverMap/index.tsx +13 -10
  47. package/themes/business/src/components/DriverSchedule/index.tsx +71 -0
  48. package/themes/business/src/components/DriverSchedule/styles.tsx +6 -0
  49. package/themes/business/src/components/LoginForm/index.tsx +111 -74
  50. package/themes/business/src/components/MapView/index.tsx +1 -1
  51. package/themes/business/src/components/MessagesOption/index.tsx +11 -1
  52. package/themes/business/src/components/OrderDetails/Business.tsx +1 -1
  53. package/themes/business/src/components/OrderDetails/Delivery.tsx +3 -3
  54. package/themes/business/src/components/OrderDetails/OrderContentComponent.tsx +19 -18
  55. package/themes/business/src/components/OrdersListManager/index.tsx +10 -3
  56. package/themes/business/src/components/OrdersOption/index.tsx +65 -21
  57. package/themes/business/src/components/OrdersOption/styles.tsx +5 -1
  58. package/themes/business/src/components/OrdersOptionBusiness/index.tsx +15 -1
  59. package/themes/business/src/components/OrdersOptionCity/index.tsx +15 -1
  60. package/themes/business/src/components/OrdersOptionDate/index.tsx +19 -6
  61. package/themes/business/src/components/OrdersOptionDelivery/index.tsx +15 -1
  62. package/themes/business/src/components/OrdersOptionDriver/index.tsx +15 -1
  63. package/themes/business/src/components/OrdersOptionPaymethod/index.tsx +15 -1
  64. package/themes/business/src/components/OrdersOptionStatus/index.tsx +10 -1
  65. package/themes/business/src/components/PreviousMessages/index.tsx +17 -18
  66. package/themes/business/src/components/PreviousOrders/index.tsx +21 -23
  67. package/themes/business/src/components/ProductItemAccordion/index.tsx +5 -4
  68. package/themes/business/src/components/ReviewCustomer/index.tsx +1 -1
  69. package/themes/business/src/components/ScheduleBlocked/index.tsx +53 -0
  70. package/themes/business/src/components/UserFormDetails/index.tsx +5 -2
  71. package/themes/business/src/components/UserProfileForm/index.tsx +28 -4
  72. package/themes/business/src/components/shared/ODropDown.tsx +42 -8
  73. package/themes/business/src/components/shared/ODropDownCalendar.tsx +36 -7
  74. package/themes/business/src/components/shared/OModal.tsx +40 -37
  75. package/themes/business/src/types/index.tsx +14 -9
  76. package/themes/business/src/utils/index.tsx +10 -0
  77. package/themes/doordash/src/components/BusinessesListing/index.tsx +1 -1
  78. package/themes/doordash/src/components/LoginForm/index.tsx +1 -2
  79. package/themes/instacart/src/components/BusinessesListing/index.tsx +1 -1
  80. package/themes/kiosk/src/components/BusinessMenu/index.tsx +2 -1
  81. package/themes/kiosk/src/components/CartItem/index.tsx +4 -3
  82. package/themes/kiosk/src/components/CategoriesMenu/index.tsx +1 -0
  83. package/themes/kiosk/src/components/Checkout/index.tsx +6 -0
  84. package/themes/kiosk/src/components/DrawerView/index.tsx +1 -0
  85. package/themes/kiosk/src/components/DrawerView/styles.tsx +2 -2
  86. package/themes/kiosk/src/components/LoginForm/index.tsx +121 -10
  87. package/themes/kiosk/src/components/LoginForm/styles.tsx +5 -0
  88. package/themes/kiosk/src/components/NavBar/index.tsx +14 -14
  89. package/themes/kiosk/src/components/OptionCard/index.tsx +1 -1
  90. package/themes/kiosk/src/components/OrderTypeCardSelector/index.tsx +8 -10
  91. package/themes/kiosk/src/components/shared/OButton.tsx +5 -18
  92. package/themes/kiosk/src/types/index.d.ts +2 -0
  93. package/themes/original/index.tsx +22 -0
  94. package/themes/original/src/components/ActiveOrders/index.tsx +15 -132
  95. package/themes/original/src/components/ActiveOrders/styles.tsx +0 -54
  96. package/themes/original/src/components/AddressForm/index.tsx +136 -133
  97. package/themes/original/src/components/AddressList/index.tsx +1 -1
  98. package/themes/original/src/components/AppleLogin/index.tsx +4 -4
  99. package/themes/original/src/components/BusinessBasicInformation/index.tsx +302 -160
  100. package/themes/original/src/components/BusinessBasicInformation/styles.tsx +6 -2
  101. package/themes/original/src/components/BusinessController/index.tsx +179 -96
  102. package/themes/original/src/components/BusinessController/styles.tsx +5 -0
  103. package/themes/original/src/components/BusinessItemAccordion/index.tsx +12 -9
  104. package/themes/original/src/components/BusinessItemAccordion/styles.tsx +3 -1
  105. package/themes/original/src/components/BusinessListingSearch/BusinessControllerSkeletons/index.tsx +57 -0
  106. package/themes/original/src/components/BusinessListingSearch/MaxSectionItem/index.tsx +59 -0
  107. package/themes/original/src/components/BusinessListingSearch/MaxSectionItem/styles.tsx +13 -0
  108. package/themes/original/src/components/BusinessListingSearch/index.tsx +106 -126
  109. package/themes/original/src/components/BusinessListingSearch/styles.tsx +18 -13
  110. package/themes/original/src/components/BusinessProductsList/CategoryDescription/index.tsx +44 -0
  111. package/themes/original/src/components/BusinessProductsList/SubcategoriesComponent/index.tsx +87 -0
  112. package/themes/original/src/components/BusinessProductsList/SubcategoriesComponent/styles.tsx +12 -0
  113. package/themes/original/src/components/BusinessProductsList/index.tsx +65 -72
  114. package/themes/original/src/components/BusinessProductsList/styles.tsx +0 -3
  115. package/themes/original/src/components/BusinessProductsListing/index.tsx +290 -178
  116. package/themes/original/src/components/BusinessProductsListing/styles.tsx +18 -0
  117. package/themes/original/src/components/BusinessReviews/index.tsx +6 -1
  118. package/themes/original/src/components/BusinessTypeFilter/index.tsx +106 -38
  119. package/themes/original/src/components/BusinessTypeFilter/styles.tsx +2 -0
  120. package/themes/original/src/components/BusinessesListing/Layout/Appointment/index.tsx +561 -0
  121. package/themes/original/src/components/BusinessesListing/{styles.tsx → Layout/Appointment/styles.tsx} +24 -2
  122. package/themes/original/src/components/BusinessesListing/Layout/Original/index.tsx +673 -0
  123. package/themes/original/src/components/BusinessesListing/Layout/Original/styles.tsx +137 -0
  124. package/themes/original/src/components/BusinessesListing/index.tsx +102 -464
  125. package/themes/original/src/components/Cart/index.tsx +81 -36
  126. package/themes/original/src/components/Cart/styles.tsx +4 -0
  127. package/themes/original/src/components/CartContent/index.tsx +22 -16
  128. package/themes/original/src/components/Checkout/index.tsx +106 -66
  129. package/themes/original/src/components/Checkout/styles.tsx +0 -1
  130. package/themes/original/src/components/DriverTips/index.tsx +4 -4
  131. package/themes/original/src/components/DriverTips/styles.tsx +2 -1
  132. package/themes/original/src/components/Favorite/index.tsx +92 -0
  133. package/themes/original/src/components/Favorite/styles.tsx +22 -0
  134. package/themes/original/src/components/FavoriteList/index.tsx +317 -0
  135. package/themes/original/src/components/FavoriteList/styles.tsx +5 -0
  136. package/themes/original/src/components/GPSButton/index.tsx +25 -17
  137. package/themes/original/src/components/GoogleMap/index.tsx +20 -12
  138. package/themes/original/src/components/HelpAccountAndPayment/index.tsx +8 -3
  139. package/themes/original/src/components/HelpGuide/index.tsx +8 -3
  140. package/themes/original/src/components/HelpOrder/index.tsx +8 -3
  141. package/themes/original/src/components/HighestRatedBusinesses/index.tsx +18 -1
  142. package/themes/original/src/components/LoginForm/Otp/index.tsx +3 -2
  143. package/themes/original/src/components/LoginForm/index.tsx +79 -42
  144. package/themes/original/src/components/Messages/index.tsx +17 -17
  145. package/themes/original/src/components/MomentSelector/index.tsx +197 -0
  146. package/themes/original/src/components/MomentSelector/styles.tsx +6 -0
  147. package/themes/original/src/components/MultiCartsPaymethodsAndWallets/index.tsx +243 -0
  148. package/themes/original/src/components/MultiCartsPaymethodsAndWallets/styles.tsx +46 -0
  149. package/themes/original/src/components/MultiCheckout/index.tsx +304 -0
  150. package/themes/original/src/components/MultiCheckout/styles.tsx +59 -0
  151. package/themes/original/src/components/MultiOrdersDetails/SingleOrderCard.tsx +372 -0
  152. package/themes/original/src/components/MultiOrdersDetails/index.tsx +262 -0
  153. package/themes/original/src/components/MultiOrdersDetails/styles.tsx +50 -0
  154. package/themes/original/src/components/MyOrders/index.tsx +177 -27
  155. package/themes/original/src/components/MyOrders/styles.tsx +8 -1
  156. package/themes/original/src/components/NavBar/index.tsx +11 -5
  157. package/themes/original/src/components/NotFoundSource/index.tsx +2 -1
  158. package/themes/original/src/components/OrderDetails/OrderHistory.tsx +167 -0
  159. package/themes/original/src/components/OrderDetails/index.tsx +125 -40
  160. package/themes/original/src/components/OrderDetails/styles.tsx +5 -2
  161. package/themes/original/src/components/OrderItAgain/index.tsx +75 -0
  162. package/themes/original/src/components/OrderItAgain/styles.tsx +10 -0
  163. package/themes/original/src/components/OrderProgress/index.tsx +8 -2
  164. package/themes/original/src/components/OrderSummary/index.tsx +1 -34
  165. package/themes/original/src/components/OrderTypeSelector/index.tsx +84 -36
  166. package/themes/original/src/components/OrderTypeSelector/styles.tsx +19 -1
  167. package/themes/original/src/components/OrdersOption/PreviousBusinessOrdered/index.tsx +144 -0
  168. package/themes/original/src/components/OrdersOption/PreviousBusinessOrdered/styles.tsx +6 -0
  169. package/themes/original/src/components/OrdersOption/PreviousProductsOrdered/index.tsx +56 -0
  170. package/themes/original/src/components/OrdersOption/PreviousProductsOrdered/styles.tsx +6 -0
  171. package/themes/original/src/components/OrdersOption/index.tsx +130 -37
  172. package/themes/original/src/components/OrdersOption/styles.tsx +4 -1
  173. package/themes/original/src/components/PaymentOptions/index.tsx +57 -37
  174. package/themes/original/src/components/PhoneInputNumber/index.tsx +4 -10
  175. package/themes/original/src/components/PlaceSpot/index.tsx +243 -47
  176. package/themes/original/src/components/PlaceSpot/styles.tsx +0 -2
  177. package/themes/original/src/components/PreviousOrders/index.tsx +18 -147
  178. package/themes/original/src/components/ProductForm/index.tsx +712 -655
  179. package/themes/original/src/components/ProductForm/styles.tsx +9 -7
  180. package/themes/original/src/components/ProductItemAccordion/index.tsx +37 -24
  181. package/themes/original/src/components/ProductOption/index.tsx +1 -1
  182. package/themes/original/src/components/ProfessionalFilter/index.tsx +129 -0
  183. package/themes/original/src/components/ProfessionalFilter/styles.tsx +0 -0
  184. package/themes/original/src/components/ProfessionalProfile/index.tsx +309 -0
  185. package/themes/original/src/components/ProfessionalProfile/styles.tsx +46 -0
  186. package/themes/original/src/components/ReviewDriver/index.tsx +6 -6
  187. package/themes/original/src/components/ReviewOrder/index.tsx +18 -3
  188. package/themes/original/src/components/ReviewProducts/index.tsx +1 -1
  189. package/themes/original/src/components/ReviewTrigger/index.tsx +118 -0
  190. package/themes/original/src/components/ReviewTrigger/styles.tsx +34 -0
  191. package/themes/original/src/components/SearchBar/index.tsx +10 -5
  192. package/themes/original/src/components/ServiceForm/index.tsx +608 -0
  193. package/themes/original/src/components/ServiceForm/styles.tsx +50 -0
  194. package/themes/original/src/components/SignupForm/index.tsx +301 -158
  195. package/themes/original/src/components/SingleOrderCard/index.tsx +316 -0
  196. package/themes/original/src/components/SingleOrderCard/styles.tsx +54 -0
  197. package/themes/original/src/components/SingleProductCard/index.tsx +215 -95
  198. package/themes/original/src/components/SingleProductCard/styles.tsx +2 -2
  199. package/themes/original/src/components/SingleProductReview/index.tsx +30 -3
  200. package/themes/original/src/components/SingleProductReview/styles.tsx +12 -0
  201. package/themes/original/src/components/StripeElementsForm/index.tsx +25 -9
  202. package/themes/original/src/components/StripeElementsForm/naked.tsx +2 -2
  203. package/themes/original/src/components/UpsellingProducts/index.tsx +14 -4
  204. package/themes/original/src/components/UserDetails/index.tsx +32 -18
  205. package/themes/original/src/components/UserFormDetails/index.tsx +107 -73
  206. package/themes/original/src/components/UserProfile/index.tsx +12 -1
  207. package/themes/original/src/components/UserProfileForm/index.tsx +15 -10
  208. package/themes/original/src/components/WalletTransactions/index.tsx +76 -0
  209. package/themes/original/src/components/WalletTransactions/styles.tsx +13 -0
  210. package/themes/original/src/components/Wallets/index.tsx +176 -162
  211. package/themes/original/src/components/Wallets/styles.tsx +10 -8
  212. package/themes/original/src/components/shared/OBottomPopup.tsx +47 -14
  213. package/themes/original/src/components/shared/OButton.tsx +10 -3
  214. package/themes/original/src/components/shared/OInput.tsx +3 -2
  215. package/themes/original/src/components/shared/OModal.tsx +3 -1
  216. package/themes/original/src/layouts/FloatingBottomContainer.tsx +5 -1
  217. package/themes/original/src/types/index.tsx +200 -46
  218. package/themes/original/src/utils/index.tsx +77 -0
  219. package/themes/uber-eats/src/components/BusinessesListing/index.tsx +1 -1
@@ -18,10 +18,10 @@ export interface LoginParams {
18
18
  handleCheckPhoneCode?: any;
19
19
  notificationState?: any;
20
20
  handleReCaptcha?: any;
21
- enableReCaptcha?: any;
21
+ enableReCaptcha?: any;
22
22
  otpType?: string,
23
- setOtpType: (type : string) => void,
24
- generateOtpCode: (values ?: any) => void,
23
+ setOtpType: (type: string) => void,
24
+ generateOtpCode: (values?: any) => void,
25
25
  useLoginOtpEmail?: boolean,
26
26
  useLoginOtpCellphone?: boolean,
27
27
  useLoginOtp?: boolean
@@ -80,6 +80,7 @@ export interface AddressFormParams {
80
80
  saveAddress?: any,
81
81
  userCustomerSetup?: boolean,
82
82
  isRequiredField?: (field: string) => {},
83
+ showField?: (field: string) => {},
83
84
  isGuestUser?: boolean,
84
85
  useValidationFileds?: boolean,
85
86
  isSelectedAfterAdd?: boolean,
@@ -110,9 +111,20 @@ export interface SignupParams {
110
111
  handleSendVerifyCode?: any;
111
112
  handleCheckPhoneCode?: any;
112
113
  notificationState?: any;
114
+ signUpTab?: string;
115
+ useSignUpFullDetails?: boolean;
116
+ useSignUpOtpEmail?: boolean;
117
+ useSignUpOtpCellphone?: boolean;
118
+ willVerifyOtpState?: boolean;
119
+ numOtpInputs?: number;
113
120
  handleChangePromotions: () => void;
121
+ handleChangeInput?: (in1: any, in2: any) => void;
114
122
  enableReCaptcha?: boolean;
115
- handleReCaptcha?: () => void;
123
+ generateOtpCode?: (in1?: any) => void;
124
+ handleReCaptcha?: (token?: any) => void;
125
+ setSignUpTab?: (in1: string) => void;
126
+ setWillVerifyOtpState?: (in1: boolean) => void;
127
+ setOtpState?: (in1: string) => void;
116
128
  }
117
129
 
118
130
  export interface PhoneInputParams {
@@ -154,13 +166,21 @@ export interface BusinessesListingParams {
154
166
  franchiseId?: any;
155
167
  businessId?: any;
156
168
  isGuestUser?: any;
169
+ handleUpdateBusinessList?: any;
170
+ priceLevelSelected?: any;
171
+ handleChangePriceLevel?: any;
172
+ businessTypeSelected?: any;
173
+ logosLayout?: boolean;
157
174
  }
158
175
  export interface HighestRatedBusinessesParams {
159
176
  businessesList: { businesses: Array<any>, loading: boolean, error: null | string };
160
177
  onBusinessClick?: void;
161
178
  navigation?: any;
162
179
  isLoading?: boolean;
163
- getBusinesses: (newFetch: boolean) => void
180
+ getBusinesses: (newFetch: boolean) => void,
181
+ favoriteIds?: any,
182
+ setFavoriteIds?: any,
183
+ handleUpdateBusinessList?: any
164
184
  }
165
185
  export interface BusinessTypeFilterParams {
166
186
  businessTypes?: Array<any>;
@@ -169,7 +189,8 @@ export interface BusinessTypeFilterParams {
169
189
  defaultBusinessType?: string | null;
170
190
  images?: any
171
191
  typesState?: any
172
- setBusinessTypes?: any
192
+ setBusinessTypes?: any,
193
+ isAppoint?: boolean | undefined
173
194
  }
174
195
  export interface BusinessControllerParams {
175
196
  key?: string | number;
@@ -189,7 +210,13 @@ export interface BusinessControllerParams {
189
210
  businessDeliveryPrice?: number,
190
211
  businessDeliveryTime?: string,
191
212
  businessPickupTime?: string,
192
- businessDistance?: number
213
+ businessDistance?: number,
214
+ favoriteIds?: number[],
215
+ handleFavoriteBusiness?: any,
216
+ setFavoriteIds?: any;
217
+ handleUpdateBusinessList?: any;
218
+ enableIntersection?: boolean;
219
+ handleCustomUpdate?: (businessId: number, changes: any) => {};
193
220
  }
194
221
  export interface BusinessProductsListingParams {
195
222
  navigation?: any;
@@ -212,6 +239,9 @@ export interface BusinessProductsListingParams {
212
239
  handleChangeCategory: (value: any) => {};
213
240
  setProductLogin?: () => {};
214
241
  updateProductModal?: (value: any) => {};
242
+ handleUpdateProducts?: any;
243
+ professionalSelected?: any;
244
+ handleChangeProfessionalSelected?: any;
215
245
  }
216
246
  export interface BusinessBasicInformationParams {
217
247
  navigation?: any;
@@ -256,18 +286,28 @@ export interface BusinessProductsListParams {
256
286
  setCategoriesLayout?: any,
257
287
  currentCart?: any,
258
288
  setSubcategoriesSelected?: any,
259
- subcategoriesSelected?: any,
260
- onClickCategory?: any,
261
- lazyLoadProductsRecommended?: boolean,
262
- isFiltMode?: boolean
289
+ subcategoriesSelected?: any,
290
+ onClickCategory?: any,
291
+ lazyLoadProductsRecommended?: boolean,
292
+ isFiltMode?: boolean,
293
+ handleUpdateProducts?: any,
294
+ navigation?: any;
295
+ previouslyProducts?: any;
263
296
  }
264
297
  export interface SingleProductCardParams {
265
- businessId: any,
298
+ businessId: any;
266
299
  product: any;
267
300
  isSoldOut: boolean;
268
301
  onProductClick: any;
269
302
  productAddedToCartLength: number;
270
- style?: ViewStyle
303
+ style?: ViewStyle;
304
+ categoryState?: any;
305
+ handleFavoriteProduct?: any;
306
+ handleUpdateProducts?: any;
307
+ enableIntersection?: boolean;
308
+ navigation?: any;
309
+ isPreviously?: any;
310
+ isProductId?: any;
271
311
  }
272
312
  export interface BusinessInformationParams {
273
313
  navigation?: any,
@@ -301,6 +341,7 @@ export interface OrdersOptionParams {
301
341
  orderList?: any,
302
342
  franchiseId?: any,
303
343
  activeOrders?: boolean,
344
+ pastOrders?: boolean,
304
345
  pagination?: any,
305
346
  titleContent?: string,
306
347
  customArray?: Array<any>,
@@ -319,7 +360,19 @@ export interface OrdersOptionParams {
319
360
  setOpenMessges?: any,
320
361
  loadMoreStatus?: boolean,
321
362
  refreshOrders?: boolean,
322
- setRefreshOrders?: (value : boolean) => void
363
+ setRefreshOrders?: (value: boolean) => void,
364
+ handleUpdateOrderList?: (orderId: number, changes: any) => {},
365
+ handleUpdateProducts?: (productId: number, changes: any) => {},
366
+ handleUpdateBusinesses?: (businessId: number, changes: any) => {},
367
+ isBusiness?: boolean,
368
+ isProducts?: boolean,
369
+ businessOrderIds?: any,
370
+ products?: any,
371
+ businessesSearchList?: any,
372
+ hideOrders?: boolean,
373
+ BusinessControllerSkeletons?: any,
374
+ businessPaginationProps?: any,
375
+ businesses?: any
323
376
  }
324
377
  export interface ActiveOrdersParams {
325
378
  orders?: any,
@@ -332,7 +385,8 @@ export interface ActiveOrdersParams {
332
385
  loadMoreOrders?: () => {},
333
386
  onNavigationRedirect?: (route: string, params?: any) => {},
334
387
  isMessageView?: boolean,
335
- handleClickOrder?: any
388
+ handleClickOrder?: any,
389
+ handleUpdateOrderList?: (orderId: number, changes: any) => {}
336
390
  }
337
391
  export interface PreviousOrdersParams {
338
392
  orders?: any,
@@ -343,6 +397,7 @@ export interface PreviousOrdersParams {
343
397
  loadMoreOrders?: () => {},
344
398
  handleReorder?: (orderId: number) => {},
345
399
  onNavigationRedirect?: (route: string, params?: any) => {}
400
+ handleUpdateOrderList?: (orderId: number, changes: any) => {}
346
401
  }
347
402
  export interface OrderDetailsParams {
348
403
  navigation?: any,
@@ -374,25 +429,26 @@ export interface ProductItemAccordionParams {
374
429
  isFromCheckout?: any
375
430
  }
376
431
  export interface ReviewOrderParams {
377
- order?: { id: number, businessId: number, logo: string, driver: any, products: Array<any>, review: any, user_review: any },
378
- stars?: any,
379
- handleChangeInput?: any,
380
- handleChangeRating?: any,
381
- handleSendReview?: any,
382
- formState?: any,
383
- navigation?: any,
384
- setIsReviewed?: (isReviewed: boolean) => {},
385
- handleReviewState?: any,
386
- setStars?: any,
387
- onNavigationRedirect?: any
432
+ order?: { id: number, business_id: number, logo: string, driver: any, products: Array<any>, review: any, user_review: any };
433
+ stars?: any;
434
+ defaultStar?: number;
435
+ handleChangeInput?: any;
436
+ handleChangeRating?: any;
437
+ handleSendReview?: any;
438
+ formState?: any;
439
+ navigation?: any;
440
+ setIsReviewed?: (isReviewed: boolean) => void;
441
+ handleReviewState?: any;
442
+ setStars?: any;
443
+ onNavigationRedirect?: any;
388
444
  }
389
445
  export interface ReviewProductParams {
390
446
  navigation?: any,
391
447
  onNavigationRedirect?: any,
392
- order?: { orderId: number, businessId: number, logo: string, driver: any, products: Array<any>, review: any, user_review: any },
448
+ order?: { orderId: number, business_id: number, logo: string, driver: any, products: Array<any>, review: any, user_review: any },
393
449
  formState?: any,
394
450
  handleChangeFormState?: any,
395
- handleSendProductReview?: any
451
+ handleSendProductReview?: any;
396
452
  }
397
453
  export interface SingleProductReviewParams {
398
454
  product: any,
@@ -402,12 +458,12 @@ export interface SingleProductReviewParams {
402
458
  export interface ReviewDriverParams {
403
459
  navigation?: any,
404
460
  onNavigationRedirect?: any,
405
- order?: { orderId: number, businessId: number, logo: string, driver: any, products: Array<any>, review: any, user_review: any },
461
+ order?: { orderId: number, business_id: number, logo: string, driver: any, products: Array<any>, review: any, user_review: any },
406
462
  formState?: any,
407
463
  setIsDriverReviewed?: (isReviewed: boolean) => {},
408
464
  dirverReviews?: any,
409
465
  setDriverReviews?: any,
410
- handleSendDriverReview?: any
466
+ handleSendDriverReview?: any;
411
467
  }
412
468
  export interface MessagesParams {
413
469
  type?: string,
@@ -505,7 +561,9 @@ export interface OrderTypeSelectParams {
505
561
  defaultValue?: number;
506
562
  configTypes?: Array<any>;
507
563
  orderTypes: Array<any>;
508
- setOrderTypeValue?: (value : number) => any
564
+ setOrderTypeValue?: (value: number) => any,
565
+ isChewLayout?: boolean;
566
+ chewOrderTypes?: any;
509
567
  }
510
568
  export interface UpsellingProductsParams {
511
569
  isCustomMode?: boolean;
@@ -581,6 +639,9 @@ export interface BusinessSearchParams {
581
639
  setFilters: (filters: any) => void,
582
640
  lazySearch?: boolean,
583
641
  brandList?: any;
642
+ onNavigationRedirect?: any,
643
+ handleUpdateProducts: any,
644
+ handleUpdateBusinessList?: any;
584
645
  }
585
646
 
586
647
  export interface NoNetworkParams {
@@ -588,35 +649,128 @@ export interface NoNetworkParams {
588
649
  }
589
650
 
590
651
  export interface PlaceSpotParams {
591
- isOpenPlaceSpot?: boolean,
652
+ isCheckout?: any,
653
+ isInputMode?: any,
592
654
  cart?: any,
655
+ spotNumberDefault?: any,
656
+ vehicleDefault?: any,
657
+ spotNumber?: any,
658
+ setSpotNumber?: any,
659
+ orderTypes?: any,
593
660
  placesState?: any,
594
- handleChangePlace?: any,
595
- getPlacesList?: any,
596
- setOpenPlaceModal?: any
661
+ handleChangePlace? : any,
662
+ spotState?: any,
663
+ vehicle?: any,
664
+ setVehicle?: any,
665
+ handleChangeSpot?: any
597
666
  }
598
667
 
599
668
  export interface PromotionParams {
600
669
  navigation: any,
601
- offersState: any,
602
- handleSearchValue: any,
603
- searchValue: string,
604
- offerSelected: any,
605
- setOfferSelected: any,
670
+ offersState: any,
671
+ handleSearchValue: any,
672
+ searchValue: string,
673
+ offerSelected: any,
674
+ setOfferSelected: any,
606
675
  loadOffers: any
607
676
  }
608
677
  export interface SessionsParams {
609
678
  navigation: any,
610
679
  sessionsList: any,
611
- actionState: any,
612
- handleDeleteSession: any,
613
- handleDeleteAllSessions: any
680
+ actionState: any,
681
+ handleDeleteSession: any,
682
+ handleDeleteAllSessions: any
614
683
  }
615
684
 
616
685
  export interface otpParams {
617
686
  willVerifyOtpState: boolean,
618
- setWillVerifyOtpState: (val : boolean) => void,
687
+ setWillVerifyOtpState: (val: boolean) => void,
619
688
  onSubmit: () => void,
620
- handleLoginOtp: (code : string) => void,
621
- setAlertState: any
689
+ handleLoginOtp: (code: string) => void,
690
+ setAlertState: any;
691
+ pinCount: number;
692
+ }
693
+
694
+ export interface FavoriteParams {
695
+ favoriteList: any,
696
+ handleUpdateFavoriteList: (id: number, changes: any) => {},
697
+ pagination: any,
698
+ getFavoriteList: (value: number) => {},
699
+ navigation?: any,
700
+ onNavigationRedirect?: (route: string, params?: any) => {},
701
+ reorderState?: any,
702
+ handleReorder?: (orderId: number) => {},
703
+ isOrder?: boolean,
704
+ isProduct?: boolean,
705
+ isBusiness?: boolean
706
+ }
707
+
708
+ export interface SingleOrderCardParams {
709
+ order: any,
710
+ reorderLoading: any,
711
+ handleReorder?: (value: any) => {},
712
+ getOrderStatus: any,
713
+ handleFavoriteOrder?: (value: boolean) => {},
714
+ onNavigationRedirect?: (route: string, params?: any) => {},
715
+ pastOrders: any,
716
+ isMessageView?: any,
717
+ handleClickOrder: (value: any) => {},
718
+ handleRemoveCart: () => {},
719
+ cartState: any
720
+ }
721
+
722
+ export interface PreviousBusinessOrderedParams {
723
+ navigation?: any,
724
+ businessesList?: any,
725
+ setBusinessLoading?: any,
726
+ businessId?: number,
727
+ onNavigationRedirect?: any,
728
+ isBusinessesSearchList?: any,
729
+ businessLoading?: boolean,
730
+ businesses?: any
731
+ handleUpdateBusinesses?: (businessId: number, changes: any) => {},
732
+ }
733
+
734
+ export interface ServiceFormParams {
735
+ navigation?: any,
736
+ professionalSelected: any,
737
+ product: any,
738
+ handleSave: (value?: any) => {}
739
+ productCart?: any
740
+ isSoldOut: boolean,
741
+ maxProductQuantity: any,
742
+ businessSlug?: string,
743
+ onClose: any,
744
+ professionalList: any
745
+ }
746
+
747
+ export interface ProfessionalFilterParams {
748
+ professionals?: any,
749
+ professionalSelected?: any,
750
+ handleChangeProfessionalSelected: any
751
+ }
752
+
753
+ export interface ProfessionalProfileParams {
754
+ professional: any,
755
+ handleChangeProfessionalSelected: any,
756
+ onClose: any
757
+ }
758
+
759
+ export interface OrderItAgainParams {
760
+ onProductClick: any,
761
+ productList: any,
762
+ businessId: any,
763
+ categoryState: any,
764
+ currentCart: any,
765
+ handleUpdateProducts: any,
766
+ navigation: any,
767
+ searchValue?: string
768
+ }
769
+
770
+ export interface PreviousProductsOrderedParams {
771
+ products?: any,
772
+ isProductId?: boolean
773
+ onProductClick?: any,
774
+ isBusinessesSearchList?: boolean
775
+ handleUpdateProducts?: any
622
776
  }
@@ -40,6 +40,72 @@ export const getTraduction = (key: string) => {
40
40
  return keyList[key] ? t(key, keyList[key]) : t(key)
41
41
  }
42
42
 
43
+ /**
44
+ * Change local moment variables
45
+ */
46
+ export const setLocalMoment = (moment : any, t : any) => {
47
+ moment.locale('custom', {
48
+ months: [
49
+ t('MONTH1','January'),
50
+ t('MONTH2','February'),
51
+ t('MONTH3','March'),
52
+ t('MONTH4','April'),
53
+ t('MONTH5','May'),
54
+ t('MONTH6','June'),
55
+ t('MONTH7','July'),
56
+ t('MONTH8','August'),
57
+ t('MONTH9','September'),
58
+ t('MONTH10','October'),
59
+ t('MONTH11','November'),
60
+ t('MONTH12','December')
61
+ ],
62
+ monthsShort: [
63
+ t('MONTHSHORT1','Jan'),
64
+ t('MONTHSHORT2','Feb'),
65
+ t('MONTHSHORT3','Mar'),
66
+ t('MONTHSHORT4','Apr'),
67
+ t('MONTHSHORT5','May'),
68
+ t('MONTHSHORT6','Jun'),
69
+ t('MONTHSHORT7','Jul'),
70
+ t('MONTHSHORT8','Aug'),
71
+ t('MONTHSHORT9','Sep'),
72
+ t('MONTHSHORT10','Oct'),
73
+ t('MONTHSHORT11','Nov'),
74
+ t('MONTHSHORT12','Dec')
75
+ ],
76
+ weekdays: [
77
+ t('DAY7','Sunday'),
78
+ t('DAY1','Monday'),
79
+ t('DAY2','Tuesday'),
80
+ t('DAY3','Wednesday'),
81
+ t('DAY4','Thursday'),
82
+ t('DAY5','Friday'),
83
+ t('DAY6','Saturday')
84
+ ],
85
+ weekdaysShort: [
86
+ t('DAYSHORT7','Sun'),
87
+ t('DAYSHORT1','Mon'),
88
+ t('DAYSHORT2','Tue'),
89
+ t('DAYSHORT3','Wed'),
90
+ t('DAYSHORT4','Thu'),
91
+ t('DAYSHORT5','Fri'),
92
+ t('DAYSHORT6','Sat')
93
+ ],
94
+ weekdaysMin: [
95
+ t('DAYMIN7','Su'),
96
+ t('DAYMIN1','Mo'),
97
+ t('DAYMIN2','Tu'),
98
+ t('DAYMIN3','We'),
99
+ t('DAYMIN4','Th'),
100
+ t('DAYMIN5','Fr'),
101
+ t('DAYMIN6','Sa')
102
+ ],
103
+ meridiem : function (hours : any) {
104
+ return hours < 12 ? t('AM', 'AM') : t('PM','PM');
105
+ }
106
+ })
107
+ }
108
+
43
109
  /**
44
110
  * Function to convert delivery time in minutes
45
111
  * @param {string} time business delivery time
@@ -229,3 +295,14 @@ export const formatSeconds = (seconds : number) => {
229
295
  ret += '' + secs
230
296
  return ret
231
297
  }
298
+
299
+ /**
300
+ * List of price to filter businesses
301
+ */
302
+ export const priceList = [
303
+ { level: '1', content: '$' },
304
+ { level: '2', content: '$$' },
305
+ { level: '3', content: '$$$' },
306
+ { level: '4', content: '$$$$' },
307
+ { level: '5', content: '$$$$$' }
308
+ ]
@@ -144,7 +144,7 @@ const BusinessesListingUI = (props: BusinessesListingParams) => {
144
144
  {isFarAway && (
145
145
  <FarAwayMessage style={styles.farAwayMsg}>
146
146
  <Ionicons name='md-warning-outline' style={styles.iconStyle} />
147
- <OText size={12} numberOfLines={1} ellipsizeMode={'tail'} color={theme.colors.textNormal}>{t('YOU_ARE_FAR_FROM_ADDRESS', 'You are far from this address')}</OText>
147
+ <OText size={12} numberOfLines={1} ellipsizeMode={'tail'} color={theme.colors.textNormal}>{t('YOU_ARE_FAR_FROM_ADDRESS', 'Your are far from this address')}</OText>
148
148
  </FarAwayMessage>
149
149
  )}
150
150
  <View style={styles.wrapperOrderOptions}>