ordering-ui-react-native 0.16.23-release → 0.16.24-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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ordering-ui-react-native",
3
- "version": "0.16.23-release",
3
+ "version": "0.16.24-release",
4
4
  "description": "Reusable components made in react native",
5
5
  "main": "src/index.tsx",
6
6
  "author": "ordering.inc",
@@ -589,10 +589,11 @@ const AddressFormUI = (props: AddressFormParams) => {
589
589
  borderColor: theme.colors.border,
590
590
  flexGrow: 1,
591
591
  fontSize: 15,
592
- paddingHorizontal: 16,
592
+ paddingLeft: 16,
593
+ paddingRight: 32,
593
594
  minHeight: 50,
594
595
  fontFamily: 'Poppins-Regular',
595
- marginBottom: 24,
596
+ marginBottom: 24
596
597
  },
597
598
  }}
598
599
  />
@@ -600,10 +601,10 @@ const AddressFormUI = (props: AddressFormParams) => {
600
601
  />
601
602
 
602
603
  {(
603
- (!isEditing && !isGuestUser && !formState.changes?.address) ||
604
- (isEditing && !isGuestUser && !formState.changes?.address && formState.changes?.address !== undefined)) ||
605
- (isGuestUser && !formState.changes?.address && formState.changes?.address !== undefined) &&
606
- (
604
+ ((!isEditing && !isGuestUser) ||
605
+ (isEditing && !isGuestUser)) ||
606
+ (isGuestUser)) &&
607
+ (
607
608
  <View style={styles.pinIcon}>
608
609
  <GPSButton
609
610
  apiKey={googleMapsApiKey}
@@ -617,7 +618,7 @@ const AddressFormUI = (props: AddressFormParams) => {
617
618
  IconButton={<OIcon src={theme.images.general.pin} width={16} />}
618
619
  />
619
620
  </View>
620
- )}
621
+ )}
621
622
  </AutocompleteInput>
622
623
 
623
624
  {(locationChange || formState.changes?.location) && (
@@ -57,12 +57,12 @@ export const BusinessBasicInformation = (
57
57
  height: isChewLayout ? 170 : 260,
58
58
  },
59
59
  logoStyle: {
60
- width: 72,
61
- height: 72,
62
- borderRadius: 7.6,
63
- justifyContent: 'flex-start',
64
- alignItems: 'flex-start'
65
- },
60
+ width: 72,
61
+ height: 72,
62
+ borderRadius: 7.6,
63
+ justifyContent: 'flex-start',
64
+ alignItems: 'flex-start'
65
+ },
66
66
  businessInfo: {
67
67
  paddingHorizontal: 40,
68
68
  paddingTop: isChewLayout ? 0 : 56,
@@ -303,15 +303,21 @@ export const BusinessBasicInformation = (
303
303
  {showLogo && (
304
304
  <BusinessLogo isChewLayout={isChewLayout}>
305
305
  {!isBusinessInfoShow && (
306
- <FastImage
307
- style={styles.logoStyle}
308
- source={{
309
- uri: logo || optimizeImage(businessState?.business?.logo || theme?.images?.dummies?.businessLogo, 'h_70,c_limit'),
310
- priority: FastImage.priority.high,
311
- cache:FastImage.cacheControl.web
312
- }}
313
- resizeMode={FastImage.resizeMode.contain}
314
- />
306
+ logo || businessState?.business?.logo ?
307
+ <FastImage
308
+ style={styles.logoStyle}
309
+ source={{
310
+ uri: logo || optimizeImage(businessState?.business?.logo, 'h_70,c_limit'),
311
+ priority: FastImage.priority.high,
312
+ cache: FastImage.cacheControl.web
313
+ }}
314
+ resizeMode={FastImage.resizeMode.contain}
315
+ />
316
+ :
317
+ <OIcon
318
+ src={theme?.images?.dummies?.businessLogo}
319
+ style={styles.logoStyle}
320
+ />
315
321
  )}
316
322
  </BusinessLogo>
317
323
  )}
@@ -186,7 +186,7 @@ const BusinessesListingUI = (props: BusinessesListingParams) => {
186
186
  paginationProps.totalPages === paginationProps.currentPage
187
187
  );
188
188
 
189
- if (y + PIXELS_TO_SCROLL > height && !businessesList.loading && hasMore) {
189
+ if (y + PIXELS_TO_SCROLL > height && !businessesList.loading && hasMore && businessesList?.businesses?.length > 0) {
190
190
  getBusinesses();
191
191
  }
192
192
  };
@@ -7,7 +7,7 @@ import {
7
7
  } from 'ordering-components/native'
8
8
  import { useTheme } from 'styled-components/native'
9
9
  import { View, TouchableOpacity, FlatList, StyleSheet, KeyboardAvoidingView, Platform } from 'react-native'
10
- import { Placeholder, PlaceholderLine, Fade } from 'rn-placeholder'
10
+ import { Placeholder, PlaceholderLine, Fade } from 'rn-placeholder'
11
11
  import { OText, OIcon, OModal, OButton } from '../shared'
12
12
  import { getIconCard, flatArray } from '../../utils'
13
13
  import { StripeElementsForm } from '../StripeElementsForm'
@@ -37,7 +37,7 @@ const MultiCartsPaymethodsAndWalletsUI = (props: any) => {
37
37
  const [{ configs }] = useConfig()
38
38
  const [{ parsePrice }] = useUtils()
39
39
 
40
- const [addCardOpen, setAddCardOpen] = useState({ stripe: false, stripeConnect: false });
40
+ const [addCardOpen, setAddCardOpen] = useState({ stripe: false, stripeConnect: false });
41
41
 
42
42
  const isWalletCashEnabled = configs?.wallet_cash_enabled?.value === '1'
43
43
  const isWalletPointsEnabled = configs?.wallet_credit_point_enabled?.value === '1'
@@ -54,52 +54,52 @@ const MultiCartsPaymethodsAndWalletsUI = (props: any) => {
54
54
  }
55
55
 
56
56
  const getPayIcon = (method: string) => {
57
- switch (method) {
58
- case 'cash':
59
- return theme.images.general.cash
60
- case 'card_delivery':
61
- return theme.images.general.carddelivery
62
- case 'paypal':
63
- return theme.images.general.paypal
64
- case 'stripe':
65
- return theme.images.general.stripe
66
- case 'stripe_direct':
67
- return theme.images.general.stripecc
68
- case 'stripe_connect':
69
- return theme.images.general.stripes
70
- case 'stripe_redirect':
71
- return theme.images.general.stripesb
72
- default:
73
- return theme.images.general.creditCard
74
- }
75
- }
57
+ switch (method) {
58
+ case 'cash':
59
+ return theme.images.general.cash
60
+ case 'card_delivery':
61
+ return theme.images.general.carddelivery
62
+ case 'paypal':
63
+ return theme.images.general.paypal
64
+ case 'stripe':
65
+ return theme.images.general.stripe
66
+ case 'stripe_direct':
67
+ return theme.images.general.stripecc
68
+ case 'stripe_connect':
69
+ return theme.images.general.stripes
70
+ case 'stripe_redirect':
71
+ return theme.images.general.stripesb
72
+ default:
73
+ return theme.images.general.creditCard
74
+ }
75
+ }
76
76
 
77
77
  const renderPaymethods = ({ item }: any) => {
78
- return (
79
- <TouchableOpacity
80
- onPress={() => handleSelectPaymethod(item)}
81
- >
82
- <PMItem
83
- key={item.id}
84
- isActive={paymethodSelected?.paymethod_id === item.paymethod_id}
85
- >
86
- <OIcon
87
- src={getPayIcon(item.paymethod?.gateway)}
88
- width={20}
89
- height={20}
90
- color={paymethodSelected?.paymethod_id === item.paymethod_id ? theme.colors.white : theme.colors.backgroundDark}
91
- />
92
- <OText
93
- size={10}
94
- style={{ margin: 0, marginTop: 4 }}
95
- color={paymethodSelected?.paymethod_id === item.paymethod_id ? theme.colors.white : '#000'}
96
- >
97
- {t(item?.paymethod?.gateway.toUpperCase(), item?.paymethod?.name)}
98
- </OText>
99
- </PMItem>
100
- </TouchableOpacity>
101
- )
102
- }
78
+ return (
79
+ <TouchableOpacity
80
+ onPress={() => handleSelectPaymethod(item)}
81
+ >
82
+ <PMItem
83
+ key={item.id}
84
+ isActive={paymethodSelected?.paymethod_id === item.paymethod_id}
85
+ >
86
+ <OIcon
87
+ src={getPayIcon(item.paymethod?.gateway)}
88
+ width={20}
89
+ height={20}
90
+ color={paymethodSelected?.paymethod_id === item.paymethod_id ? theme.colors.white : theme.colors.backgroundDark}
91
+ />
92
+ <OText
93
+ size={10}
94
+ style={{ margin: 0, marginTop: 4 }}
95
+ color={paymethodSelected?.paymethod_id === item.paymethod_id ? theme.colors.white : '#000'}
96
+ >
97
+ {t(item?.paymethod?.gateway.toUpperCase(), item?.paymethod?.name)}
98
+ </OText>
99
+ </PMItem>
100
+ </TouchableOpacity>
101
+ )
102
+ }
103
103
 
104
104
  return (
105
105
  <PMContainer>
@@ -123,10 +123,10 @@ const MultiCartsPaymethodsAndWalletsUI = (props: any) => {
123
123
  ) : (
124
124
  <FlatList
125
125
  horizontal
126
- showsHorizontalScrollIndicator={false}
127
- data={businessPaymethods.result.filter((paymethod: any) => paymethodsAndWallets.paymethods.find((item: any) => item.id === paymethod.paymethod_id))}
128
- renderItem={renderPaymethods}
129
- keyExtractor={(paymethod: any) => paymethod?.id?.toString?.()}
126
+ showsHorizontalScrollIndicator={false}
127
+ data={businessPaymethods?.result?.filter((paymethod: any) => paymethodsAndWallets.paymethods.find((item: any) => item.id === paymethod.paymethod_id))}
128
+ renderItem={renderPaymethods}
129
+ keyExtractor={(paymethod: any) => paymethod?.id?.toString?.()}
130
130
  />
131
131
  )}
132
132
  {!paymethodsAndWallets.loading && !paymethodsAndWallets.error && paymethodsAndWallets.paymethods.length === 0 && (
@@ -138,22 +138,22 @@ const MultiCartsPaymethodsAndWalletsUI = (props: any) => {
138
138
  {paymethodSelected?.paymethod?.gateway === 'stripe' && (
139
139
  <View>
140
140
  <OButton
141
- text={t('ADD_PAYMENT_CARD', 'Add New Payment Card')}
142
- bgColor={theme.colors.white}
143
- borderColor={theme.colors.primary}
144
- style={styles.btnAddStyle}
145
- textStyle={{ color: theme.colors.primary, fontSize: 12 }}
146
- imgRightSrc={null}
147
- onClick={() => setAddCardOpen({ ...addCardOpen, stripe: true })}
148
- />
141
+ text={t('ADD_PAYMENT_CARD', 'Add New Payment Card')}
142
+ bgColor={theme.colors.white}
143
+ borderColor={theme.colors.primary}
144
+ style={styles.btnAddStyle}
145
+ textStyle={{ color: theme.colors.primary, fontSize: 12 }}
146
+ imgRightSrc={null}
147
+ onClick={() => setAddCardOpen({ ...addCardOpen, stripe: true })}
148
+ />
149
149
  <StripeCardsList
150
- paymethod={paymethodSelected?.paymethod}
151
- businessId={businessIds[0]}
150
+ paymethod={paymethodSelected?.paymethod}
151
+ businessId={businessIds[0]}
152
152
  businessIds={businessIds}
153
- publicKey={paymethodSelected?.data?.publishable}
154
- payType={paymethodSelected?.paymethod?.name}
155
- onSelectCard={handlePaymethodDataChange}
156
- />
153
+ publicKey={paymethodSelected?.data?.publishable}
154
+ payType={paymethodSelected?.paymethod?.name}
155
+ onSelectCard={handlePaymethodDataChange}
156
+ />
157
157
  </View>
158
158
  )}
159
159
 
@@ -170,7 +170,7 @@ const MultiCartsPaymethodsAndWalletsUI = (props: any) => {
170
170
  </>
171
171
  ) : (
172
172
  <>
173
- {walletsState.result.filter((wallet: any) => paymethodsAndWallets.wallets.find((item: any) => item.type === wallet.type)).map((wallet: any, idx: any) => walletName[wallet.type]?.isActive && (
173
+ {walletsState?.result?.filter((wallet: any) => paymethodsAndWallets.wallets.find((item: any) => item.type === wallet.type)).map((wallet: any, idx: any) => walletName[wallet.type]?.isActive && (
174
174
  <WalletItem
175
175
  key={wallet.type}
176
176
  isBottomBorder={idx === paymethodsAndWallets.wallets?.length - 1}
@@ -197,40 +197,40 @@ const MultiCartsPaymethodsAndWalletsUI = (props: any) => {
197
197
  )}
198
198
 
199
199
  <OModal
200
- entireModal
201
- title={t('ADD_CREDIT_OR_DEBIT_CARD', 'Add credit or debit card')}
202
- open={addCardOpen.stripe}
203
- onClose={() => setAddCardOpen({ ...addCardOpen, stripe: false })}
204
- style={{ backgroundColor: 'red' }}
205
- >
206
- <KeyboardAvoidingView
207
- behavior={Platform.OS == 'ios' ? 'padding' : 'height'}
208
- keyboardVerticalOffset={Platform.OS == 'ios' ? 0 : 0}
209
- enabled={Platform.OS === 'ios' ? true : false}
210
- >
211
- <StripeElementsForm
212
- toSave
213
- businessId={businessIds[0]}
200
+ entireModal
201
+ title={t('ADD_CREDIT_OR_DEBIT_CARD', 'Add credit or debit card')}
202
+ open={addCardOpen.stripe}
203
+ onClose={() => setAddCardOpen({ ...addCardOpen, stripe: false })}
204
+ style={{ backgroundColor: 'red' }}
205
+ >
206
+ <KeyboardAvoidingView
207
+ behavior={Platform.OS == 'ios' ? 'padding' : 'height'}
208
+ keyboardVerticalOffset={Platform.OS == 'ios' ? 0 : 0}
209
+ enabled={Platform.OS === 'ios' ? true : false}
210
+ >
211
+ <StripeElementsForm
212
+ toSave
213
+ businessId={businessIds[0]}
214
214
  businessIds={businessIds}
215
215
  publicKey={paymethodSelected?.data?.publishable}
216
- requirements={props.clientSecret}
217
- onSelectCard={handlePaymethodDataChange}
218
- onCancel={() => setAddCardOpen({ ...addCardOpen, stripe: false })}
219
- />
220
- </KeyboardAvoidingView>
221
- </OModal>
216
+ requirements={props.clientSecret}
217
+ onSelectCard={handlePaymethodDataChange}
218
+ onCancel={() => setAddCardOpen({ ...addCardOpen, stripe: false })}
219
+ />
220
+ </KeyboardAvoidingView>
221
+ </OModal>
222
222
  </PMContainer>
223
223
  )
224
224
  }
225
225
 
226
226
  const styles = StyleSheet.create({
227
- btnAddStyle: {
228
- marginVertical: 20,
229
- borderRadius: 7.6,
230
- shadowOpacity: 0,
231
- height: 44,
232
- borderWidth: 1
233
- },
227
+ btnAddStyle: {
228
+ marginVertical: 20,
229
+ borderRadius: 7.6,
230
+ shadowOpacity: 0,
231
+ height: 44,
232
+ borderWidth: 1
233
+ },
234
234
  })
235
235
 
236
236
 
@@ -36,6 +36,7 @@ export const MyOrders = (props: any) => {
36
36
  { key: 'products', value: t('PRODUCTS', 'Products') }
37
37
  ]
38
38
  const isChewLayout = theme?.business_view?.components?.header?.components?.layout?.type === 'chew'
39
+ const showNavbar = theme?.bar_menu?.components?.orders?.hidden
39
40
 
40
41
  const goToBack = () => navigation?.canGoBack() && navigation.goBack()
41
42
 
@@ -72,47 +73,48 @@ export const MyOrders = (props: any) => {
72
73
  onRefresh={() => handleOnRefresh()}
73
74
  />
74
75
  }>
75
- {isChewLayout && (
76
+ {(isChewLayout || showNavbar) && (
76
77
  <View style={{
77
78
  width: '100%',
78
79
  display: 'flex',
79
80
  flexDirection: 'row',
80
81
  alignItems: 'center',
81
- paddingHorizontal: 40
82
+ paddingHorizontal: 40,
83
+ marginTop: Platform.OS === 'android' ? 50 : 30,
82
84
  }}>
85
+ <OButton
86
+ imgLeftStyle={{ width: 18 }}
87
+ imgRightSrc={null}
88
+ style={{
89
+ borderWidth: 0,
90
+ width: 26,
91
+ height: 26,
92
+ backgroundColor: '#FFF',
93
+ borderColor: '#FFF',
94
+ shadowColor: '#FFF',
95
+ paddingLeft: 0,
96
+ paddingRight: 0
97
+ }}
98
+ onClick={goToBack}
99
+ icon={AntDesignIcon}
100
+ iconProps={{
101
+ name: 'arrowleft',
102
+ size: 26
103
+ }}
104
+ />
83
105
  <OText
84
106
  size={24}
85
107
  style={{
86
- marginTop: Platform.OS === 'android' ? 50 : 30,
87
- paddingHorizontal: 20,
88
- textTransform: 'capitalize'
108
+ textTransform: 'capitalize',
109
+ marginLeft: 20,
110
+ top: 2
89
111
  }}
90
112
  >
91
- <OButton
92
- imgLeftStyle={{ width: 18 }}
93
- imgRightSrc={null}
94
- style={{
95
- borderWidth: 0,
96
- width: 26,
97
- height: 26,
98
- backgroundColor: '#FFF',
99
- borderColor: '#FFF',
100
- shadowColor: '#FFF',
101
- paddingLeft: 0,
102
- paddingRight: 0,
103
- }}
104
- onClick={goToBack}
105
- icon={AntDesignIcon}
106
- iconProps={{
107
- name: 'arrowleft',
108
- size: 26
109
- }}
110
- />
111
113
  {t('MY_ORDERS', 'My Orders')}
112
114
  </OText>
113
115
  </View>
114
116
  )}
115
- {!hideOrders && !isChewLayout && (
117
+ {!hideOrders && !isChewLayout && !showNavbar && (
116
118
  <HeaderTitle text={t('MY_ORDERS', 'My Orders')} />
117
119
  )}
118
120
  {!allEmpty && (
@@ -1,15 +1,15 @@
1
1
  import React, { useEffect, useRef, useState, useCallback } from 'react';
2
2
  import {
3
- View,
4
- Keyboard,
5
- TextInput,
6
- TouchableOpacity,
7
- StyleSheet,
8
- Dimensions,
9
- I18nManager,
10
- SafeAreaView,
11
- Platform,
12
- Button
3
+ View,
4
+ Keyboard,
5
+ TextInput,
6
+ TouchableOpacity,
7
+ StyleSheet,
8
+ Dimensions,
9
+ I18nManager,
10
+ SafeAreaView,
11
+ Platform,
12
+ Button
13
13
  } from 'react-native';
14
14
  import {
15
15
  ProductForm as ProductOptions,
@@ -459,13 +459,13 @@ export const ProductOptionsUI = (props: any) => {
459
459
  }
460
460
 
461
461
  useEffect(() => {
462
- const keyboardDidShowListener = Keyboard.addListener('keyboardDidShow', () => {
462
+ const keyboardDidShowListener = Keyboard.addListener('keyboardDidShow', () => {
463
463
  scrollViewRef.current.scrollToEnd({ animated: true })
464
- })
465
- return () => {
466
- keyboardDidShowListener.remove()
467
- }
468
- }, [])
464
+ })
465
+ return () => {
466
+ keyboardDidShowListener.remove()
467
+ }
468
+ }, [])
469
469
 
470
470
 
471
471
  return (
@@ -1054,7 +1054,7 @@ export const ProductOptionsUI = (props: any) => {
1054
1054
  width={16}
1055
1055
  color={
1056
1056
  maxProductQuantity <= 0 ||
1057
- (productCart?.quantity + productAddedToCartLength) >= maxProductQuantity ||
1057
+ (productCart?.quantity + productAddedToCartLength) >= maxProductQuantity ||
1058
1058
  ((productCart?.quantity + productAddedToCartLength) >= product?.maximum_per_order && product?.maximum_per_order) ||
1059
1059
  isSoldOut
1060
1060
  ? theme.colors.backgroundGray
@@ -1108,20 +1108,20 @@ export const ProductOptionsUI = (props: any) => {
1108
1108
 
1109
1109
 
1110
1110
  export const ProductForm = (props: any) => {
1111
- const productOptionsProps = {
1112
- ...props,
1113
- productCart: {
1114
- ...props.productCart,
1115
- quantity: props.productCart?.code
1116
- ? props.productCart?.quantity
1117
- : props?.product?.minimum_per_order || 1
1118
- },
1119
- UIComponent: ProductOptionsUI
1120
- }
1111
+ const productOptionsProps = {
1112
+ ...props,
1113
+ productCart: {
1114
+ ...props.productCart,
1115
+ quantity: props.productCart?.code
1116
+ ? props.productCart?.quantity
1117
+ : props?.product?.minimum_per_order || 1
1118
+ },
1119
+ UIComponent: ProductOptionsUI
1120
+ }
1121
1121
 
1122
- return <ProductOptions {...productOptionsProps} />
1122
+ return <ProductOptions {...productOptionsProps} />
1123
1123
  };
1124
1124
 
1125
1125
  ProductForm.defaultProps = {
1126
- productAddedToCartLength: 0
1126
+ productAddedToCartLength: 0
1127
1127
  }
@@ -191,7 +191,7 @@ export const ProductItemAccordion = (props: ProductItemAccordionParams) => {
191
191
  )
192
192
  )}
193
193
  </ProductImage>
194
- )}
194
+ )}
195
195
  {!!product?.calendar_event ? (
196
196
  <View style={{ flex: 1, marginLeft: 10, flexDirection: 'column' }}>
197
197
  <View>
@@ -201,7 +201,7 @@ export const ProductItemAccordion = (props: ProductItemAccordionParams) => {
201
201
  {parseDate(product?.calendar_event?.start, { outputFormat: 'hh:mm a' })} - {parseDate(product?.calendar_event?.end, { outputFormat: 'hh:mm a' })}
202
202
  </OText>
203
203
  </View>
204
- ): (
204
+ ) : (
205
205
  <>
206
206
  {isCartProduct && !isCartPending && getProductMax && (
207
207
  <ProductInfo>
@@ -316,22 +316,22 @@ export const ProductItemAccordion = (props: ProductItemAccordionParams) => {
316
316
  </View>
317
317
  </AccordionSection>
318
318
  <OModal
319
- open={isServiceOpen}
320
- onClose={() => setIsServiceOpen(false)}
321
- entireModal
322
- >
323
- <ServiceForm
324
- isCartProduct
325
- isService
326
- businessId={product?.business_id}
319
+ open={isServiceOpen}
320
+ onClose={() => setIsServiceOpen(false)}
321
+ entireModal
322
+ >
323
+ <ServiceForm
324
+ isCartProduct
325
+ isService
326
+ businessId={product?.business_id}
327
327
  categoryId={product?.category_id}
328
328
  productId={product?.id}
329
329
  productCart={product}
330
- onSave={() => setIsServiceOpen(false)}
331
- onClose={() => setIsServiceOpen(false)}
332
- professionalSelected={product?.calendar_event?.professional}
333
- />
334
- </OModal>
330
+ onSave={() => setIsServiceOpen(false)}
331
+ onClose={() => setIsServiceOpen(false)}
332
+ professionalSelected={product?.calendar_event?.professional}
333
+ />
334
+ </OModal>
335
335
  </>
336
336
  )
337
337
  }
@@ -146,7 +146,7 @@ const UpsellingProductsUI = (props: UpsellingProductsParams) => {
146
146
  </AddButton>
147
147
  </View>
148
148
  <View>
149
- <OIcon url={product.images} style={styles.imageStyle} />
149
+ <OIcon url={product?.images || theme?.images?.dummies?.product} style={styles.imageStyle} />
150
150
  </View>
151
151
  </Item>
152
152
  )) : (
@@ -114,7 +114,6 @@ const ProfileListUI = (props: ProfileParams) => {
114
114
  const [confirm, setConfirm] = useState<any>({ open: false, content: null, handleOnAccept: null, id: null, title: null })
115
115
  const isWalletEnabled = configs?.cash_wallet?.value && configs?.wallet_enabled?.value === '1' && (configs?.wallet_cash_enabled?.value === '1' || configs?.wallet_credit_point_enabled?.value === '1')
116
116
  const IsPromotionsEnabled = configs?.advanced_offers_module?.value === '1' || configs?.advanced_offers_module?.value === true
117
- const isChewLayout = theme?.business_view?.components?.header?.components?.layout?.type === 'chew'
118
117
  const onRedirect = (route: string, params?: any) => {
119
118
  navigation.navigate(route, params)
120
119
  }
@@ -200,12 +199,10 @@ const ProfileListUI = (props: ProfileParams) => {
200
199
  <MessageCircle name='message1' style={styles.messageIconStyle} color={theme.colors.textNormal} />
201
200
  <OText size={14} lineHeight={24} weight={'400'} color={theme.colors.textNormal}>{t('MESSAGES', 'Messages')}</OText>
202
201
  </ListItem>
203
- {isChewLayout && (
204
- <ListItem onPress={() => onRedirect('MyOrders', { isFromProfile: true, isGoBack: true })} activeOpacity={0.7}>
205
- <FontAwesome name='list-alt' style={styles.messageIconStyle} color={theme.colors.textNormal} />
206
- <OText size={14} lineHeight={24} weight={'400'} color={theme.colors.textNormal}>{t('MY_ORDERS', 'My Orders')}</OText>
207
- </ListItem>
208
- )}
202
+ <ListItem onPress={() => onRedirect('MyOrders', { isFromProfile: true, isGoBack: true })} activeOpacity={0.7}>
203
+ <FontAwesome name='list-alt' style={styles.messageIconStyle} color={theme.colors.textNormal} />
204
+ <OText size={14} lineHeight={24} weight={'400'} color={theme.colors.textNormal}>{t('MY_ORDERS', 'My Orders')}</OText>
205
+ </ListItem>
209
206
  {isWalletEnabled && (
210
207
  <ListItem onPress={() => onRedirect('Wallets', { isFromProfile: true, isGoBack: true })} activeOpacity={0.7}>
211
208
  <Ionicons name='wallet-outline' style={styles.messageIconStyle} color={theme.colors.textNormal} />