ordering-ui-react-native 0.12.57 → 0.12.58

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 (175) hide show
  1. package/package.json +1 -1
  2. package/themes/single-business/src/components/Cart/index.tsx +91 -15
  3. package/themes/single-business/src/components/Cart/styles.tsx +39 -0
  4. package/themes/single-business/src/components/CartContent/index.tsx +56 -52
  5. package/themes/single-business/src/components/CartContent/styles.tsx +2 -16
  6. package/themes/franchises/index.tsx +0 -111
  7. package/themes/franchises/src/components/ActiveOrders/index.tsx +0 -134
  8. package/themes/franchises/src/components/ActiveOrders/styles.tsx +0 -44
  9. package/themes/franchises/src/components/AddressDetails/index.tsx +0 -77
  10. package/themes/franchises/src/components/AddressDetails/styles.tsx +0 -21
  11. package/themes/franchises/src/components/AddressForm/index.tsx +0 -837
  12. package/themes/franchises/src/components/AddressForm/styles.tsx +0 -27
  13. package/themes/franchises/src/components/AddressList/index.tsx +0 -338
  14. package/themes/franchises/src/components/AddressList/styles.tsx +0 -20
  15. package/themes/franchises/src/components/AppleLogin/index.tsx +0 -149
  16. package/themes/franchises/src/components/AppleLogin/styles.tsx +0 -21
  17. package/themes/franchises/src/components/BottomWrapper/index.tsx +0 -29
  18. package/themes/franchises/src/components/BusinessBasicInformation/index.tsx +0 -310
  19. package/themes/franchises/src/components/BusinessBasicInformation/styles.tsx +0 -66
  20. package/themes/franchises/src/components/BusinessController/index.tsx +0 -184
  21. package/themes/franchises/src/components/BusinessController/styles.tsx +0 -64
  22. package/themes/franchises/src/components/BusinessFeaturedController/index.tsx +0 -189
  23. package/themes/franchises/src/components/BusinessFeaturedController/styles.tsx +0 -50
  24. package/themes/franchises/src/components/BusinessInformation/index.tsx +0 -202
  25. package/themes/franchises/src/components/BusinessInformation/styles.tsx +0 -39
  26. package/themes/franchises/src/components/BusinessItemAccordion/index.tsx +0 -125
  27. package/themes/franchises/src/components/BusinessItemAccordion/styles.tsx +0 -54
  28. package/themes/franchises/src/components/BusinessProductsCategories/index.tsx +0 -87
  29. package/themes/franchises/src/components/BusinessProductsCategories/styles.tsx +0 -8
  30. package/themes/franchises/src/components/BusinessProductsList/index.tsx +0 -199
  31. package/themes/franchises/src/components/BusinessProductsList/styles.tsx +0 -14
  32. package/themes/franchises/src/components/BusinessProductsListing/index.tsx +0 -292
  33. package/themes/franchises/src/components/BusinessProductsListing/styles.tsx +0 -30
  34. package/themes/franchises/src/components/BusinessReviews/index.tsx +0 -249
  35. package/themes/franchises/src/components/BusinessReviews/styles.tsx +0 -59
  36. package/themes/franchises/src/components/BusinessTypeFilter/index.tsx +0 -127
  37. package/themes/franchises/src/components/BusinessTypeFilter/styles.tsx +0 -40
  38. package/themes/franchises/src/components/BusinessesListing/index.tsx +0 -339
  39. package/themes/franchises/src/components/BusinessesListing/styles.tsx +0 -92
  40. package/themes/franchises/src/components/Cart/index.tsx +0 -332
  41. package/themes/franchises/src/components/Cart/styles.tsx +0 -28
  42. package/themes/franchises/src/components/CartContent/index.tsx +0 -60
  43. package/themes/franchises/src/components/CartContent/styles.tsx +0 -19
  44. package/themes/franchises/src/components/Checkout/index.tsx +0 -664
  45. package/themes/franchises/src/components/Checkout/styles.tsx +0 -89
  46. package/themes/franchises/src/components/CouponControl/index.tsx +0 -119
  47. package/themes/franchises/src/components/CouponControl/styles.tsx +0 -22
  48. package/themes/franchises/src/components/DriverTips/index.tsx +0 -167
  49. package/themes/franchises/src/components/DriverTips/styles.tsx +0 -63
  50. package/themes/franchises/src/components/FacebookLogin/index.tsx +0 -107
  51. package/themes/franchises/src/components/FacebookLogin/styles.tsx +0 -21
  52. package/themes/franchises/src/components/FloatingButton/index.tsx +0 -100
  53. package/themes/franchises/src/components/FloatingButton/styles.tsx +0 -26
  54. package/themes/franchises/src/components/ForgotPasswordForm/index.tsx +0 -156
  55. package/themes/franchises/src/components/ForgotPasswordForm/styles.tsx +0 -11
  56. package/themes/franchises/src/components/GPSButton/index.tsx +0 -84
  57. package/themes/franchises/src/components/GPSButton/styles.ts +0 -6
  58. package/themes/franchises/src/components/GoogleLogin/index.tsx +0 -122
  59. package/themes/franchises/src/components/GoogleLogin/styles.tsx +0 -23
  60. package/themes/franchises/src/components/GoogleMap/index.tsx +0 -229
  61. package/themes/franchises/src/components/Help/index.tsx +0 -56
  62. package/themes/franchises/src/components/Help/styles.tsx +0 -11
  63. package/themes/franchises/src/components/HelpAccountAndPayment/index.tsx +0 -68
  64. package/themes/franchises/src/components/HelpAccountAndPayment/styles.tsx +0 -6
  65. package/themes/franchises/src/components/HelpGuide/index.tsx +0 -67
  66. package/themes/franchises/src/components/HelpGuide/styles.tsx +0 -6
  67. package/themes/franchises/src/components/HelpOrder/index.tsx +0 -79
  68. package/themes/franchises/src/components/HelpOrder/styles.tsx +0 -6
  69. package/themes/franchises/src/components/Home/index.tsx +0 -102
  70. package/themes/franchises/src/components/Home/styles.tsx +0 -18
  71. package/themes/franchises/src/components/LanguageSelector/index.tsx +0 -98
  72. package/themes/franchises/src/components/LanguageSelector/styles.tsx +0 -7
  73. package/themes/franchises/src/components/LastOrder/index.tsx +0 -168
  74. package/themes/franchises/src/components/LastOrder/styles.tsx +0 -16
  75. package/themes/franchises/src/components/LastOrders/index.tsx +0 -104
  76. package/themes/franchises/src/components/LastOrders/styles.tsx +0 -17
  77. package/themes/franchises/src/components/LoginForm/index.tsx +0 -512
  78. package/themes/franchises/src/components/LoginForm/styles.tsx +0 -77
  79. package/themes/franchises/src/components/LogoutButton/index.tsx +0 -36
  80. package/themes/franchises/src/components/Messages/index.tsx +0 -359
  81. package/themes/franchises/src/components/Messages/styles.tsx +0 -20
  82. package/themes/franchises/src/components/MomentOption/index.tsx +0 -321
  83. package/themes/franchises/src/components/MomentOption/styles.tsx +0 -66
  84. package/themes/franchises/src/components/NavBar/index.tsx +0 -129
  85. package/themes/franchises/src/components/NotFoundSource/index.tsx +0 -50
  86. package/themes/franchises/src/components/NotFoundSource/styles.tsx +0 -16
  87. package/themes/franchises/src/components/Notifications/index.tsx +0 -120
  88. package/themes/franchises/src/components/Notifications/styles.ts +0 -21
  89. package/themes/franchises/src/components/OrderDetails/index.tsx +0 -828
  90. package/themes/franchises/src/components/OrderDetails/styles.tsx +0 -120
  91. package/themes/franchises/src/components/OrderSummary/index.tsx +0 -266
  92. package/themes/franchises/src/components/OrderSummary/styles.tsx +0 -41
  93. package/themes/franchises/src/components/OrderTypeSelector/index.tsx +0 -92
  94. package/themes/franchises/src/components/OrderTypeSelector/styles.tsx +0 -27
  95. package/themes/franchises/src/components/OrdersOption/index.tsx +0 -243
  96. package/themes/franchises/src/components/OrdersOption/styles.tsx +0 -5
  97. package/themes/franchises/src/components/PaymentOptionCash/index.tsx +0 -102
  98. package/themes/franchises/src/components/PaymentOptionCash/styles.tsx +0 -18
  99. package/themes/franchises/src/components/PaymentOptionStripe/index.tsx +0 -234
  100. package/themes/franchises/src/components/PaymentOptionStripe/styles.tsx +0 -71
  101. package/themes/franchises/src/components/PaymentOptions/index.tsx +0 -430
  102. package/themes/franchises/src/components/PaymentOptions/styles.tsx +0 -77
  103. package/themes/franchises/src/components/PhoneInputNumber/index.tsx +0 -127
  104. package/themes/franchises/src/components/PhoneInputNumber/styles.tsx +0 -3
  105. package/themes/franchises/src/components/PreviousOrders/index.tsx +0 -188
  106. package/themes/franchises/src/components/PreviousOrders/styles.tsx +0 -33
  107. package/themes/franchises/src/components/ProductForm/index.tsx +0 -695
  108. package/themes/franchises/src/components/ProductForm/styles.tsx +0 -78
  109. package/themes/franchises/src/components/ProductIngredient/index.tsx +0 -43
  110. package/themes/franchises/src/components/ProductIngredient/styles.tsx +0 -7
  111. package/themes/franchises/src/components/ProductItemAccordion/index.tsx +0 -276
  112. package/themes/franchises/src/components/ProductItemAccordion/styles.tsx +0 -57
  113. package/themes/franchises/src/components/ProductOption/index.tsx +0 -50
  114. package/themes/franchises/src/components/ProductOption/styles.tsx +0 -11
  115. package/themes/franchises/src/components/ProductOptionSubOption/index.tsx +0 -146
  116. package/themes/franchises/src/components/ProductOptionSubOption/styles.tsx +0 -32
  117. package/themes/franchises/src/components/ReviewDriver/index.tsx +0 -221
  118. package/themes/franchises/src/components/ReviewDriver/styles.tsx +0 -46
  119. package/themes/franchises/src/components/ReviewOrder/index.tsx +0 -325
  120. package/themes/franchises/src/components/ReviewOrder/styles.tsx +0 -46
  121. package/themes/franchises/src/components/ReviewProduct/index.tsx +0 -275
  122. package/themes/franchises/src/components/ReviewProduct/styles.tsx +0 -53
  123. package/themes/franchises/src/components/SearchBar/index.tsx +0 -139
  124. package/themes/franchises/src/components/SignupForm/index.tsx +0 -643
  125. package/themes/franchises/src/components/SignupForm/styles.tsx +0 -27
  126. package/themes/franchises/src/components/SingleProductCard/index.tsx +0 -124
  127. package/themes/franchises/src/components/SingleProductCard/styles.tsx +0 -23
  128. package/themes/franchises/src/components/StripeCardForm/index.tsx +0 -97
  129. package/themes/franchises/src/components/StripeCardForm/naked.tsx +0 -128
  130. package/themes/franchises/src/components/StripeCardForm/styles.tsx +0 -32
  131. package/themes/franchises/src/components/StripeCardsList/index.tsx +0 -182
  132. package/themes/franchises/src/components/StripeElementsForm/index.tsx +0 -204
  133. package/themes/franchises/src/components/StripeElementsForm/naked.tsx +0 -90
  134. package/themes/franchises/src/components/StripeElementsForm/styles.tsx +0 -13
  135. package/themes/franchises/src/components/StripeRedirectForm/index.tsx +0 -159
  136. package/themes/franchises/src/components/StripeRedirectForm/styles.tsx +0 -23
  137. package/themes/franchises/src/components/TagSelector/index.tsx +0 -94
  138. package/themes/franchises/src/components/TagSelector/styles.ts +0 -0
  139. package/themes/franchises/src/components/TaxInformation/index.tsx +0 -51
  140. package/themes/franchises/src/components/TaxInformation/styles.tsx +0 -9
  141. package/themes/franchises/src/components/UpsellingProducts/index.tsx +0 -222
  142. package/themes/franchises/src/components/UpsellingProducts/styles.tsx +0 -50
  143. package/themes/franchises/src/components/UserDetails/index.tsx +0 -134
  144. package/themes/franchises/src/components/UserDetails/styles.tsx +0 -26
  145. package/themes/franchises/src/components/UserFormDetails/index.tsx +0 -351
  146. package/themes/franchises/src/components/UserFormDetails/styles.tsx +0 -35
  147. package/themes/franchises/src/components/UserProfile/index.tsx +0 -179
  148. package/themes/franchises/src/components/UserProfile/styles.ts +0 -42
  149. package/themes/franchises/src/components/UserProfileForm/index.tsx +0 -253
  150. package/themes/franchises/src/components/UserProfileForm/styles.tsx +0 -29
  151. package/themes/franchises/src/components/VerifyPhone/index.tsx +0 -188
  152. package/themes/franchises/src/components/VerifyPhone/styles.tsx +0 -43
  153. package/themes/franchises/src/components/shared/OAlert.tsx +0 -55
  154. package/themes/franchises/src/components/shared/OBottomPopup.tsx +0 -73
  155. package/themes/franchises/src/components/shared/OBottomStickBar.tsx +0 -62
  156. package/themes/franchises/src/components/shared/OButton.tsx +0 -132
  157. package/themes/franchises/src/components/shared/ODropDown.tsx +0 -169
  158. package/themes/franchises/src/components/shared/OIcon.tsx +0 -53
  159. package/themes/franchises/src/components/shared/OIconButton.tsx +0 -127
  160. package/themes/franchises/src/components/shared/OIconText.tsx +0 -54
  161. package/themes/franchises/src/components/shared/OInput.tsx +0 -113
  162. package/themes/franchises/src/components/shared/OKeyButton.tsx +0 -35
  163. package/themes/franchises/src/components/shared/OModal.tsx +0 -172
  164. package/themes/franchises/src/components/shared/OText.tsx +0 -52
  165. package/themes/franchises/src/components/shared/OTextarea.tsx +0 -36
  166. package/themes/franchises/src/components/shared/OToast.tsx +0 -93
  167. package/themes/franchises/src/components/shared/OToggle.tsx +0 -158
  168. package/themes/franchises/src/components/shared/index.tsx +0 -29
  169. package/themes/franchises/src/config/constants.tsx +0 -57
  170. package/themes/franchises/src/layouts/Container.tsx +0 -23
  171. package/themes/franchises/src/layouts/SafeAreaContainer.tsx +0 -6
  172. package/themes/franchises/src/providers/AlertProvider.tsx +0 -43
  173. package/themes/franchises/src/providers/StoreUtil.tsx +0 -50
  174. package/themes/franchises/src/types/index.tsx +0 -445
  175. package/themes/franchises/src/utils/index.tsx +0 -222
@@ -1,56 +0,0 @@
1
- import React from 'react'
2
- import { HelpParams } from '../../types'
3
- import { useLanguage } from 'ordering-components/native'
4
- import NavBar from '../NavBar'
5
- import { OText } from '../shared'
6
- import { LastOrders } from '../LastOrders'
7
-
8
- import {
9
- HelpSubItem,
10
- LastOrdersContainer
11
- } from './styles'
12
-
13
- export const Help = (props: HelpParams) => {
14
- const {
15
- navigation
16
- } = props
17
- const [, t] = useLanguage()
18
-
19
- const goToBack = () => navigation?.canGoBack() && navigation.goBack()
20
- const onRedirect = (route: string, params?: any) => {
21
- navigation.navigate(route, params)
22
- }
23
- return (
24
- <>
25
- <NavBar
26
- title={t('HELP', 'Help')}
27
- titleAlign={'center'}
28
- onActionLeft={goToBack}
29
- showCall={false}
30
- paddingTop={10}
31
- btnStyle={{ paddingLeft: 0 }}
32
- isVertical
33
- />
34
- <HelpSubItem
35
- onPress={() => onRedirect('HelpOrder')}
36
- >
37
- <OText size={14}>{t('HELP_WITH_ORDER', 'Help with an order')}</OText>
38
- </HelpSubItem>
39
- <HelpSubItem
40
- onPress={() => onRedirect('HelpAccountAndPayment')}
41
- >
42
- <OText size={14}>{t('ACCOUNT_PAYMENT_OPTIONS', 'Account and Payment Options')}</OText>
43
- </HelpSubItem>
44
- <HelpSubItem
45
- onPress={() => onRedirect('HelpGuide')}
46
- >
47
- <OText size={14}>{t('GUIDE_TO_ORDERING', 'Guide to Ordering')}</OText>
48
- </HelpSubItem>
49
-
50
- <LastOrdersContainer>
51
- <OText size={18} weight={600}>{t('LAST_ORDERS', 'Last Orders')}</OText>
52
- <LastOrders onRedirect={onRedirect} />
53
- </LastOrdersContainer>
54
- </>
55
- )
56
- }
@@ -1,11 +0,0 @@
1
- import styled from 'styled-components/native'
2
-
3
- export const HelpSubItem = styled.TouchableOpacity`
4
- border-bottom-color: #E9ECEF;
5
- border-bottom-width: 1px;
6
- padding-vertical: 15px;
7
- `
8
-
9
- export const LastOrdersContainer = styled.View`
10
- margin-vertical: 30px;
11
- `
@@ -1,68 +0,0 @@
1
- import React from 'react'
2
- import { useLanguage } from 'ordering-components/native'
3
- import { HelpParams } from '../../types'
4
- import { OText, OButton, OIcon } from '../shared'
5
- import { useTheme } from 'styled-components/native'
6
- import { StyleSheet } from 'react-native'
7
-
8
- import {
9
- Content
10
- } from './styles'
11
-
12
- export const HelpAccountAndPayment = (props: HelpParams) => {
13
- const {
14
- navigation
15
- } = props
16
- const [, t] = useLanguage()
17
- const theme = useTheme()
18
-
19
- const styles = StyleSheet.create({
20
- btnBackArrow: {
21
- borderWidth: 0,
22
- backgroundColor: theme.colors.white,
23
- borderColor: theme.colors.white,
24
- shadowColor: theme.colors.white,
25
- display: 'flex',
26
- justifyContent: 'flex-start',
27
- paddingLeft: 0,
28
- },
29
- imageStyle: {
30
- width: '100%',
31
- height: 300,
32
- marginVertical: 20
33
- },
34
- })
35
-
36
- const goToBack = () => navigation?.canGoBack() && navigation.goBack()
37
-
38
- return (
39
- <>
40
- <OButton
41
- imgLeftSrc={theme.images.general.arrow_left}
42
- imgRightSrc={null}
43
- style={styles.btnBackArrow}
44
- onClick={() => goToBack()}
45
- />
46
- <OText size={22} weight={600}>{t('ACCOUNT_PAYMENT_OPTIONS', 'Account and Payment Options')}</OText>
47
- <Content>
48
- <OText mBottom={20}>
49
- -Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vel in congue nisl, nisi. Mauris, condimentum auctor sed cras cursus arcu pellentesque.
50
- </OText>
51
- <OText mBottom={20}>
52
- -Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vel in congue nisl, nisi. Mauris, condimentum auctor sed cras cursus arcu pellentesque.
53
- </OText>
54
- <OText mBottom={20}>
55
- -Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vel in congue nisl, nisi. Mauris, condimentum auctor sed cras cursus arcu pellentesque.
56
- </OText>
57
- <OText>
58
- -Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vel in congue nisl, nisi. Mauris, condimentum auctor sed cras cursus arcu pellentesque.
59
- </OText>
60
- <OIcon
61
- src={theme.images.general.help}
62
- style={styles.imageStyle}
63
- cover
64
- />
65
- </Content>
66
- </>
67
- )
68
- }
@@ -1,6 +0,0 @@
1
- import styled from 'styled-components/native'
2
-
3
- export const Content = styled.View`
4
- padding-vertical: 20px;
5
- margin-bottom: 20px;
6
- `
@@ -1,67 +0,0 @@
1
- import React from 'react'
2
- import { useLanguage } from 'ordering-components/native'
3
- import { HelpParams } from '../../types'
4
- import { OText, OButton, OIcon } from '../shared'
5
- import { useTheme } from 'styled-components/native'
6
- import { StyleSheet } from 'react-native'
7
- import {
8
- Content
9
- } from './styles'
10
-
11
- export const HelpGuide = (props: HelpParams) => {
12
- const {
13
- navigation
14
- } = props
15
- const [, t] = useLanguage()
16
- const theme = useTheme()
17
-
18
- const styles = StyleSheet.create({
19
- btnBackArrow: {
20
- borderWidth: 0,
21
- backgroundColor: theme.colors.white,
22
- borderColor: theme.colors.white,
23
- shadowColor: theme.colors.white,
24
- display: 'flex',
25
- justifyContent: 'flex-start',
26
- paddingLeft: 0,
27
- },
28
- imageStyle: {
29
- width: '100%',
30
- height: 120,
31
- marginVertical: 20
32
- },
33
- })
34
-
35
- const goToBack = () => navigation?.canGoBack() && navigation.goBack()
36
-
37
- return (
38
- <>
39
- <OButton
40
- imgLeftSrc={theme.images.general.arrow_left}
41
- imgRightSrc={null}
42
- style={styles.btnBackArrow}
43
- onClick={() => goToBack()}
44
- />
45
- <OText size={22} weight={600}>{t('GUIDE_TO_ORDERING', 'Guide to Ordering')}</OText>
46
- <Content>
47
- <OText mBottom={15}>
48
- Lorem ipsum dolor sit amet, consectetur adipiscing elit. Blandit mauris varius faucibus varius condimentum morbi pretium mus. Aliquam bibendum erat venenatis feugiat sed.
49
- </OText>
50
- <OText mBottom={15}>
51
- Lorem ipsum dolor sit amet, consectetur adipiscing elit. Blandit mauris varius faucibus varius condimentum morbi pretium mus. Aliquam bibendum erat venenatis feugiat sed.
52
- </OText>
53
- <OText mBottom={15}>
54
- Lorem ipsum dolor sit amet, consectetur adipiscing elit. Blandit mauris varius faucibus varius condimentum morbi pretium mus. Aliquam bibendum erat venenatis feugiat sed.
55
- </OText>
56
- <OText>
57
- Lorem ipsum dolor sit amet, consectetur adipiscing elit. Blandit mauris varius faucibus varius condimentum morbi pretium mus. Aliquam bibendum erat venenatis feugiat sed.
58
- </OText>
59
- <OIcon
60
- src={theme.images.general.help}
61
- style={styles.imageStyle}
62
- cover
63
- />
64
- </Content>
65
- </>
66
- )
67
- }
@@ -1,6 +0,0 @@
1
- import styled from 'styled-components/native'
2
-
3
- export const Content = styled.View`
4
- padding-vertical: 20px;
5
- margin-bottom: 20px;
6
- `
@@ -1,79 +0,0 @@
1
- import React from 'react'
2
- import { useLanguage } from 'ordering-components/native'
3
- import { HelpParams } from '../../types'
4
- import { OText, OButton, OIcon } from '../shared'
5
- import { useTheme } from 'styled-components/native'
6
- import { StyleSheet } from 'react-native'
7
- import { WebView } from 'react-native-webview'
8
-
9
- import {
10
- Content
11
- } from './styles'
12
-
13
- export const HelpOrder = (props: HelpParams) => {
14
- const {
15
- navigation
16
- } = props
17
- const [, t] = useLanguage()
18
- const theme = useTheme()
19
-
20
- const styles = StyleSheet.create({
21
- btnBackArrow: {
22
- borderWidth: 0,
23
- backgroundColor: theme.colors.white,
24
- borderColor: theme.colors.white,
25
- shadowColor: theme.colors.white,
26
- display: 'flex',
27
- justifyContent: 'flex-start',
28
- paddingLeft: 0,
29
- },
30
- imageStyle: {
31
- width: '100%',
32
- height: 120
33
- },
34
- videoStyle: {
35
- height: 200,
36
- marginVertical: 20
37
- }
38
- })
39
-
40
- const goToBack = () => navigation?.canGoBack() && navigation.goBack()
41
-
42
- return (
43
- <>
44
- <OButton
45
- imgLeftSrc={theme.images.general.arrow_left}
46
- imgRightSrc={null}
47
- style={styles.btnBackArrow}
48
- onClick={() => goToBack()}
49
- />
50
- <OText size={22} weight={600}>{t('HELP_WITH_ORDER', 'Help with an order')}</OText>
51
- <Content>
52
- <OText mBottom={20}>
53
- Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vel in congue nisl, nisi. Mauris, condimentum auctor sed cras cursus arcu pellentesque. Sed tempus et, cursus ultricies nisl nisl, in eros.
54
- Velit sollicitudin vestibulum massa porttitor sit sed vestibulum turpis.
55
- Id id adipiscing sit bibendum aliquet at suspendisse. Posuere felis nec non pulvinar in.
56
- </OText>
57
- <OIcon
58
- src={theme.images.general.help}
59
- style={styles.imageStyle}
60
- cover
61
- />
62
- <OText style={{ marginVertical: 20 }}>
63
- Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vel in congue nisl, nisi. Mauris, condimentum auctor sed cras cursus arcu pellentesque. Sed tempus et, cursus ultricies nisl nisl, in eros.
64
- Velit sollicitudin vestibulum massa porttitor sit sed vestibulum turpis.
65
- Id id adipiscing sit bibendum aliquet at suspendisse. Posuere felis nec non pulvinar in.
66
- </OText>
67
- <WebView
68
- allowsFullscreenVideo
69
- allowsInlineMediaPlayback
70
- mediaPlaybackRequiresUserAction
71
- cacheEnabled={false}
72
- cacheMode='LOAD_NO_CACHE'
73
- source={{ uri: 'https://www.youtube-nocookie.com/embed/Bi8WLLRzZ1g' }}
74
- style={styles.videoStyle}
75
- />
76
- </Content>
77
- </>
78
- )
79
- }
@@ -1,6 +0,0 @@
1
- import styled from 'styled-components/native'
2
-
3
- export const Content = styled.View`
4
- padding-vertical: 20px;
5
- margin-bottom: 20px;
6
- `
@@ -1,102 +0,0 @@
1
- import React from 'react';
2
- import { useLanguage, useOrder } from 'ordering-components/native';
3
- import { useTheme } from 'styled-components/native';
4
- import { StyleSheet, View } from 'react-native';
5
- import { OButton, OIcon, OText } from '../shared';
6
- import { LanguageSelector } from '../LanguageSelector';
7
- import { TouchableOpacity } from 'react-native-gesture-handler';
8
- import { useWindowDimensions } from 'react-native';
9
-
10
- export const Home = (props: any) => {
11
- const { onNavigationRedirect, isSingleBusiness, singleBusiness } = props;
12
- const { width } = useWindowDimensions();
13
- const [, t] = useLanguage();
14
- const [orderState] = useOrder();
15
-
16
- const theme = useTheme();
17
-
18
- return (
19
- <View style={styles.container}>
20
- <View>
21
- <LanguageSelector />
22
- <OIcon
23
- src={theme.images.logos.logotypeInvert}
24
- style={{
25
- ...styles.logo,
26
- resizeMode: 'contain',
27
- width: width - 80,
28
- height: (width - 80) * 0.25,
29
- }}
30
- />
31
- </View>
32
- <View style={styles.wrapperBtn}>
33
- <OText color={theme.colors.white} size={40}>
34
- {t('WELCOME', 'Welcome!')}
35
- </OText>
36
- <OText color={theme.colors.white} size={14} style={{ marginBottom: 46 }}>
37
- {t('LETS_START_ORDER', "Let's start to order now")}
38
- </OText>
39
- <OButton
40
- text={t('LOGIN', 'Login')}
41
- bgColor={theme.colors.primary}
42
- borderColor={theme.colors.primary}
43
- style={styles.buttons}
44
- isCircle={false}
45
- textStyle={{ color: 'white' }}
46
- onClick={() => onNavigationRedirect('Login')}
47
- imgRightSrc={null}
48
- />
49
- <OButton
50
- text={t('SIGNUP', 'Signup')}
51
- bgColor={theme.colors.primaryContrast}
52
- borderColor={theme.colors.primaryContrast}
53
- style={styles.buttons}
54
- onClick={() => onNavigationRedirect('Signup')}
55
- imgRightSrc={null}
56
- />
57
- <TouchableOpacity
58
- style={{ ...styles.textLink, marginTop: 12 }}
59
- onPress={() =>
60
- orderState?.options?.address?.address
61
- ? isSingleBusiness ? onNavigationRedirect('Business', { store: singleBusiness }) : onNavigationRedirect('BusinessList', { isGuestUser: true })
62
- : onNavigationRedirect('AddressForm', { isGuestUser: true })
63
- }>
64
- <OText weight="normal" size={18} color={theme.colors.white}>
65
- {t('CONTINUE_AS_GUEST', 'Continue as guest')}
66
- </OText>
67
- </TouchableOpacity>
68
- </View>
69
- </View>
70
- );
71
- };
72
-
73
- const styles = StyleSheet.create({
74
- textLink: {
75
- flexDirection: 'row',
76
- textAlign: 'center',
77
- justifyContent: 'center',
78
- alignItems: 'center',
79
- },
80
- container: {
81
- flex: 1,
82
- alignItems: 'center',
83
- justifyContent: 'space-between',
84
- paddingHorizontal: 40,
85
- },
86
- logo: {
87
- marginTop: 64,
88
- },
89
- buttons: {
90
- marginVertical: 6,
91
- borderRadius: 7.6,
92
- },
93
- sloganText: {
94
- textAlign: 'center',
95
- },
96
- wrapperBtn: {
97
- width: '100%',
98
- position: 'absolute',
99
- bottom: 0,
100
- marginBottom: 20,
101
- },
102
- });
@@ -1,18 +0,0 @@
1
- import styled from 'styled-components/native';
2
-
3
- export const Container = styled.View`
4
- display: flex;
5
- flex-direction: column;
6
- justify-content: center;
7
- align-items: center;
8
- height: 100%;
9
- `
10
-
11
- export const LogoWrapper = styled.View`
12
- align-items: center;
13
- `;
14
-
15
- export const Slogan = styled.View`
16
- align-items: center;
17
- margin-bottom: 10px;
18
- `;
@@ -1,98 +0,0 @@
1
- import React, { useCallback } from 'react'
2
- import { LanguageSelector as LanguageSelectorController, useOrder } from 'ordering-components/native'
3
- import { useTheme } from 'styled-components/native';
4
- import { Platform, StyleSheet, View } from 'react-native'
5
-
6
- import RNPickerSelect from 'react-native-picker-select'
7
- import { Container } from './styles'
8
- import { LanguageSelectorParams } from '../../types'
9
- import { OIcon } from '../shared'
10
-
11
- const LanguageSelectorUI = (props: LanguageSelectorParams) => {
12
-
13
- const [orderState] = useOrder()
14
-
15
- const theme = useTheme();
16
-
17
- const _pickerStyle = StyleSheet.create({
18
- inputAndroid: {
19
- color: theme.colors.white,
20
- borderWidth: 1,
21
- borderColor: theme.colors.clear,
22
- paddingHorizontal: 10,
23
- paddingEnd: 24,
24
- height: 40,
25
- backgroundColor: theme.colors.clear,
26
- },
27
- inputIOS: {
28
- color: theme.colors.white,
29
- paddingEnd: 24,
30
- height: 40,
31
- borderWidth: 1,
32
- borderColor: theme.colors.clear,
33
- backgroundColor: theme.colors.clear
34
- },
35
- icon: {
36
- width: 10,
37
- marginTop: 9,
38
- marginEnd: 10
39
- },
40
- placeholder: {
41
- color: theme.colors.secundaryContrast
42
- }
43
- })
44
-
45
- const {
46
- languagesState,
47
- currentLanguage,
48
- handleChangeLanguage,
49
- iconColor,
50
- pickerStyle
51
- } = props
52
-
53
- const _languages = languagesState?.languages?.map((language: any) => {
54
- return {
55
- value: language?.code,
56
- label: language?.name,
57
- inputLabel: language?.name
58
- }
59
- })
60
- _languages && _languages.sort((a: any, b: any) =>
61
- (a.content > b.content) ? 1 : ((b.content > a.content) ? -1 : 0)
62
- )
63
-
64
- const changeLang = useCallback((lang) => {
65
- if (lang !== currentLanguage || orderState.loading) {
66
- handleChangeLanguage(lang);
67
- }
68
- }, []);
69
-
70
- return (
71
- <Container>
72
- {languagesState?.languages && (
73
- <>
74
- {iconColor && <OIcon src={theme.images.general.language} color={iconColor} style={{ marginEnd: 14 }} width={16} />}
75
- <RNPickerSelect
76
- onValueChange={changeLang}
77
- items={_languages || []}
78
- value={currentLanguage}
79
- style={pickerStyle ? pickerStyle : _pickerStyle}
80
- useNativeAndroidPickerStyle={false}
81
- placeholder={{}}
82
- Icon={() => <View style={pickerStyle ? pickerStyle.icon : _pickerStyle.icon}><OIcon src={theme.images.general.arrow_down} color={theme.colors.white} style={{ width: '100%' }} /></View>}
83
- disabled={orderState.loading}
84
- />
85
- </>
86
- )}
87
- </Container>
88
- )
89
- }
90
-
91
- export const LanguageSelector = (props: LanguageSelectorParams) => {
92
- const LanguageProps = {
93
- ...props,
94
- UIComponent: LanguageSelectorUI
95
- }
96
-
97
- return <LanguageSelectorController {...LanguageProps} />
98
- }
@@ -1,7 +0,0 @@
1
- import styled from 'styled-components/native'
2
-
3
- export const Container = styled.View`
4
- align-items: center;
5
- justify-content: flex-start;
6
- flex-direction: row;
7
- `