ordering-ui-react-native 0.15.36 → 0.15.37

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.15.36",
3
+ "version": "0.15.37",
4
4
  "description": "Reusable components made in react native",
5
5
  "main": "src/index.tsx",
6
6
  "author": "ordering.inc",
@@ -7,11 +7,15 @@ import { SignupForm } from './src/components/SignupForm';
7
7
  import { ActiveOrders } from './src/components/ActiveOrders';
8
8
  import { AddressList } from './src/components/AddressList';
9
9
  import { AppleLogin } from './src/components/AppleLogin';
10
+ import { BusinessBasicInformation } from './src/components/BusinessBasicInformation';
11
+ import { BusinessProductsCategories } from './src/components/BusinessProductsCategories';
12
+ import { BusinessProductsList } from './src/components/BusinessProductsList';
10
13
  import { BusinessesListing } from './src/components/BusinessesListing';
11
14
  import { BusinessProductsListing } from './src/components/BusinessProductsListing';
12
15
  import { CartContent } from './src/components/CartContent';
13
16
  import { BusinessCart } from './src/components/BusinessCart';
14
17
  import { Checkout } from './src/components/Checkout';
18
+ import { FloatingButton } from './src/components/FloatingButton';
15
19
  import { ForgotPasswordForm } from './src/components/ForgotPasswordForm';
16
20
  import { MomentOption } from './src/components/MomentOption';
17
21
  import { OrdersOption } from './src/components/OrdersOption';
@@ -33,6 +37,7 @@ import { HelpOrder } from './src/components/HelpOrder';
33
37
  import { NetworkError } from './src/components/NetworkError';
34
38
  import { NotFoundSource } from './src/components/NotFoundSource';
35
39
  import { OrderTypeSelector } from './src/components/OrderTypeSelector';
40
+ import { SearchBar } from './src/components/SearchBar';
36
41
  import { Wallets } from './src/components/Wallets';
37
42
  import { PaymentOptionWallet } from './src/components/PaymentOptionWallet';
38
43
  import { ProductForm } from './src/components/ProductForm';
@@ -94,7 +99,7 @@ export {
94
99
  BusinessMenuList,
95
100
  UserProfile,
96
101
  MessageListing,
97
- Messages,
102
+ Messages,
98
103
  Help,
99
104
  HelpAccountAndPayment,
100
105
  HelpGuide,
@@ -108,6 +113,11 @@ export {
108
113
  UpsellingProducts,
109
114
  UserVerification,
110
115
  BusinessListingSearch,
116
+ BusinessBasicInformation,
117
+ BusinessProductsCategories,
118
+ BusinessProductsList,
119
+ FloatingButton,
120
+ SearchBar,
111
121
 
112
122
  // OComponents
113
123
  Toast,
@@ -46,7 +46,6 @@ import { ProductOptionSubOption } from '../ProductOptionSubOption';
46
46
  import { NotFoundSource } from '../NotFoundSource';
47
47
  import { Placeholder, PlaceholderLine, Fade } from 'rn-placeholder';
48
48
  import { useState } from 'react';
49
-
50
49
  const windowHeight = Dimensions.get('window').height;
51
50
  const windowWidth = Dimensions.get('window').width;
52
51
 
@@ -291,15 +290,23 @@ export const ProductOptionsUI = (props: any) => {
291
290
  if (img?.video) {
292
291
  const keys = img?.video.split('/')
293
292
  let _videoId = keys[keys.length - 1]
293
+
294
294
  if (_videoId.includes('watch')) {
295
- const __url = _videoId.split('=')[1]
296
- _videoId = __url
295
+ const __url = _videoId.split('=')[1]
296
+ _videoId = __url
297
+ } else if (_videoId.includes('?')) {
298
+ const __url = _videoId.split('?')[0]
299
+ _videoId = __url
300
+ }
301
+
302
+ if (_videoId.search(/&/i) >= 0) {
303
+ _videoId = _videoId.split('&')[0]
304
+ } else if (_videoId.search(/\?/i) >= 0) {
305
+ _videoId = _videoId.split('?')[0]
297
306
  }
298
- if (_videoId.includes('?')) {
299
- const __url = _videoId.split('?')[0]
300
- _videoId = __url
307
+ if ((_videoId.length === 11)) {
308
+ videoList.push(_videoId)
301
309
  }
302
- videoList.push(_videoId)
303
310
  }
304
311
  }
305
312
  }
@@ -338,9 +345,9 @@ export const ProductOptionsUI = (props: any) => {
338
345
  </OText>
339
346
  </TouchableOpacity>
340
347
  )}
341
- {options.map(({ id, name, respect_to }: any) => (
348
+ {options.map(({ id, name, respect_to, suboptions }: any) => (
342
349
  <React.Fragment key={`cont_key_${id}`}>
343
- {respect_to == null && (
350
+ {respect_to == null && suboptions?.length > 0 && (
344
351
  <TouchableOpacity
345
352
  key={`eopt_key_${id}`}
346
353
  onPress={() => setSelectedOpt(id)}