ordering-ui-external 1.1.6 → 1.2.0
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/_bundles/{0.ordering-ui.ff2158785c5abf7d9a26.js → 0.ordering-ui.5a3714c3be025beef39b.js} +0 -0
- package/_bundles/{1.ordering-ui.ff2158785c5abf7d9a26.js → 1.ordering-ui.5a3714c3be025beef39b.js} +0 -0
- package/_bundles/{3.ordering-ui.ff2158785c5abf7d9a26.js → 3.ordering-ui.5a3714c3be025beef39b.js} +0 -0
- package/_bundles/{4.ordering-ui.ff2158785c5abf7d9a26.js → 4.ordering-ui.5a3714c3be025beef39b.js} +0 -0
- package/_bundles/{5.ordering-ui.ff2158785c5abf7d9a26.js → 5.ordering-ui.5a3714c3be025beef39b.js} +0 -0
- package/_bundles/{6.ordering-ui.ff2158785c5abf7d9a26.js → 6.ordering-ui.5a3714c3be025beef39b.js} +0 -0
- package/_bundles/{7.ordering-ui.ff2158785c5abf7d9a26.js → 7.ordering-ui.5a3714c3be025beef39b.js} +1 -1
- package/_bundles/{7.ordering-ui.ff2158785c5abf7d9a26.js.LICENSE.txt → 7.ordering-ui.5a3714c3be025beef39b.js.LICENSE.txt} +0 -0
- package/_bundles/{8.ordering-ui.ff2158785c5abf7d9a26.js → 8.ordering-ui.5a3714c3be025beef39b.js} +0 -0
- package/_bundles/{9.ordering-ui.ff2158785c5abf7d9a26.js → 9.ordering-ui.5a3714c3be025beef39b.js} +0 -0
- package/_bundles/ordering-ui.5a3714c3be025beef39b.js +2 -0
- package/_bundles/{ordering-ui.ff2158785c5abf7d9a26.js.LICENSE.txt → ordering-ui.5a3714c3be025beef39b.js.LICENSE.txt} +0 -0
- package/_modules/themes/five/index.js +8 -0
- package/_modules/themes/five/src/components/BusinessBasicInformation/index.js +33 -1
- package/_modules/themes/five/src/components/BusinessBasicInformation/styles.js +3 -1
- package/_modules/themes/five/src/components/BusinessInformation/styles.js +2 -2
- package/_modules/themes/five/src/components/BusinessProductsCategories/index.js +27 -11
- package/_modules/themes/five/src/components/BusinessProductsCategories/styles.js +1 -1
- package/_modules/themes/five/src/components/BusinessProductsListing/index.js +5 -3
- package/_modules/themes/five/src/components/BusinessesListing/layouts/OriginalBusinessesListing/index.js +3 -7
- package/_modules/themes/five/src/components/Cart/index.js +14 -3
- package/_modules/themes/five/src/components/Cart/styles.js +9 -3
- package/_modules/themes/five/src/components/Checkout/index.js +1 -10
- package/_modules/themes/five/src/components/Checkout/styles.js +1 -1
- package/_modules/themes/five/src/components/Modal/styles.js +1 -1
- package/_modules/themes/five/src/components/MomentControl/styles.js +1 -1
- package/_modules/themes/five/src/components/MultiCheckout/index.js +4 -0
- package/_modules/themes/five/src/components/OrderItAgain/index.js +60 -0
- package/_modules/themes/five/src/components/OrderItAgain/styles.js +46 -0
- package/_modules/themes/five/src/components/ProductForm/index.js +5 -0
- package/_modules/themes/five/src/components/ProfessionalFilter/index.js +4 -2
- package/_modules/themes/five/src/components/ProfessionalFilter/styles.js +20 -8
- package/_modules/themes/five/src/components/RenderProductsLayout/index.js +20 -6
- package/_modules/themes/five/src/components/RenderProductsLayout/styles.js +29 -24
- package/_modules/themes/five/src/components/ReviewProduct/styles.js +6 -6
- package/_modules/themes/five/src/components/ServiceForm/index.js +5 -7
- package/_modules/themes/five/src/components/ServiceForm/styles.js +9 -5
- package/_modules/themes/five/src/components/SidebarMenu/index.js +13 -2
- package/_modules/themes/five/src/components/SingleOrderCard/index.js +1 -1
- package/_modules/themes/five/src/components/SingleProductCard/index.js +17 -9
- package/_modules/themes/five/src/components/SingleProductCard/styles.js +60 -48
- package/_modules/themes/four/src/components/BusinessBasicInformation/index.js +1 -1
- package/package.json +1 -1
- package/src/themes/five/index.js +2 -0
- package/src/themes/five/src/components/BusinessBasicInformation/index.js +29 -1
- package/src/themes/five/src/components/BusinessBasicInformation/styles.js +11 -0
- package/src/themes/five/src/components/BusinessInformation/styles.js +3 -3
- package/src/themes/five/src/components/BusinessProductsCategories/index.js +21 -11
- package/src/themes/five/src/components/BusinessProductsCategories/styles.js +3 -3
- package/src/themes/five/src/components/BusinessProductsListing/index.js +2 -2
- package/src/themes/five/src/components/BusinessesListing/layouts/OriginalBusinessesListing/index.js +2 -4
- package/src/themes/five/src/components/Cart/index.js +37 -2
- package/src/themes/five/src/components/Cart/styles.js +17 -0
- package/src/themes/five/src/components/Checkout/index.js +1 -5
- package/src/themes/five/src/components/Checkout/styles.js +5 -1
- package/src/themes/five/src/components/Modal/styles.js +5 -0
- package/src/themes/five/src/components/MomentControl/index.js +48 -48
- package/src/themes/five/src/components/MomentControl/styles.js +0 -1
- package/src/themes/five/src/components/MultiCheckout/index.js +2 -0
- package/src/themes/five/src/components/OrderItAgain/index.js +46 -0
- package/src/themes/five/src/components/OrderItAgain/styles.js +60 -0
- package/src/themes/five/src/components/ProductForm/index.js +1 -0
- package/src/themes/five/src/components/ProfessionalFilter/index.js +10 -2
- package/src/themes/five/src/components/ProfessionalFilter/styles.js +24 -9
- package/src/themes/five/src/components/RenderProductsLayout/index.js +20 -3
- package/src/themes/five/src/components/RenderProductsLayout/styles.js +12 -5
- package/src/themes/five/src/components/ReviewProduct/styles.js +14 -0
- package/src/themes/five/src/components/ServiceForm/index.js +31 -22
- package/src/themes/five/src/components/ServiceForm/styles.js +16 -0
- package/src/themes/five/src/components/SidebarMenu/index.js +32 -1
- package/src/themes/five/src/components/SingleOrderCard/index.js +1 -1
- package/src/themes/five/src/components/SingleProductCard/index.js +10 -6
- package/src/themes/five/src/components/SingleProductCard/styles.js +21 -7
- package/src/themes/four/src/components/BusinessBasicInformation/index.js +15 -17
- package/_bundles/ordering-ui.ff2158785c5abf7d9a26.js +0 -2
|
@@ -128,64 +128,64 @@ const MomentControlUI = (props) => {
|
|
|
128
128
|
const setLocalMoment = () => {
|
|
129
129
|
moment.updateLocale('custom', {
|
|
130
130
|
months: [
|
|
131
|
-
t('MONTH1','January'),
|
|
132
|
-
t('MONTH2','February'),
|
|
133
|
-
t('MONTH3','March'),
|
|
134
|
-
t('MONTH4','April'),
|
|
135
|
-
t('MONTH5','May'),
|
|
136
|
-
t('MONTH6','June'),
|
|
137
|
-
t('MONTH7','July'),
|
|
138
|
-
t('MONTH8','August'),
|
|
139
|
-
t('MONTH9','September'),
|
|
140
|
-
t('MONTH10','October'),
|
|
141
|
-
t('MONTH11','November'),
|
|
142
|
-
t('MONTH12','December')
|
|
131
|
+
t('MONTH1', 'January'),
|
|
132
|
+
t('MONTH2', 'February'),
|
|
133
|
+
t('MONTH3', 'March'),
|
|
134
|
+
t('MONTH4', 'April'),
|
|
135
|
+
t('MONTH5', 'May'),
|
|
136
|
+
t('MONTH6', 'June'),
|
|
137
|
+
t('MONTH7', 'July'),
|
|
138
|
+
t('MONTH8', 'August'),
|
|
139
|
+
t('MONTH9', 'September'),
|
|
140
|
+
t('MONTH10', 'October'),
|
|
141
|
+
t('MONTH11', 'November'),
|
|
142
|
+
t('MONTH12', 'December')
|
|
143
143
|
],
|
|
144
144
|
monthsShort: [
|
|
145
|
-
t('MONTHSHORT1','Jan'),
|
|
146
|
-
t('MONTHSHORT2','Feb'),
|
|
147
|
-
t('MONTHSHORT3','Mar'),
|
|
148
|
-
t('MONTHSHORT4','Apr'),
|
|
149
|
-
t('MONTHSHORT5','May'),
|
|
150
|
-
t('MONTHSHORT6','Jun'),
|
|
151
|
-
t('MONTHSHORT7','Jul'),
|
|
152
|
-
t('MONTHSHORT8','Aug'),
|
|
153
|
-
t('MONTHSHORT9','Sep'),
|
|
154
|
-
t('MONTHSHORT10','Oct'),
|
|
155
|
-
t('MONTHSHORT11','Nov'),
|
|
156
|
-
t('MONTHSHORT12','Dec')
|
|
145
|
+
t('MONTHSHORT1', 'Jan'),
|
|
146
|
+
t('MONTHSHORT2', 'Feb'),
|
|
147
|
+
t('MONTHSHORT3', 'Mar'),
|
|
148
|
+
t('MONTHSHORT4', 'Apr'),
|
|
149
|
+
t('MONTHSHORT5', 'May'),
|
|
150
|
+
t('MONTHSHORT6', 'Jun'),
|
|
151
|
+
t('MONTHSHORT7', 'Jul'),
|
|
152
|
+
t('MONTHSHORT8', 'Aug'),
|
|
153
|
+
t('MONTHSHORT9', 'Sep'),
|
|
154
|
+
t('MONTHSHORT10', 'Oct'),
|
|
155
|
+
t('MONTHSHORT11', 'Nov'),
|
|
156
|
+
t('MONTHSHORT12', 'Dec')
|
|
157
157
|
],
|
|
158
158
|
weekdays: [
|
|
159
|
-
t('DAY7','Sunday'),
|
|
160
|
-
t('DAY1','Monday'),
|
|
161
|
-
t('DAY2','Tuesday'),
|
|
162
|
-
t('DAY3','Wednesday'),
|
|
163
|
-
t('DAY4','Thursday'),
|
|
164
|
-
t('DAY5','Friday'),
|
|
165
|
-
t('DAY6','Saturday')
|
|
159
|
+
t('DAY7', 'Sunday'),
|
|
160
|
+
t('DAY1', 'Monday'),
|
|
161
|
+
t('DAY2', 'Tuesday'),
|
|
162
|
+
t('DAY3', 'Wednesday'),
|
|
163
|
+
t('DAY4', 'Thursday'),
|
|
164
|
+
t('DAY5', 'Friday'),
|
|
165
|
+
t('DAY6', 'Saturday')
|
|
166
166
|
],
|
|
167
167
|
weekdaysShort: [
|
|
168
|
-
t('DAYSHORT7','Sun'),
|
|
169
|
-
t('DAYSHORT1','Mon'),
|
|
170
|
-
t('DAYSHORT2','Tue'),
|
|
171
|
-
t('DAYSHORT3','Wed'),
|
|
172
|
-
t('DAYSHORT4','Thu'),
|
|
173
|
-
t('DAYSHORT5','Fri'),
|
|
174
|
-
t('DAYSHORT6','Sat')
|
|
168
|
+
t('DAYSHORT7', 'Sun'),
|
|
169
|
+
t('DAYSHORT1', 'Mon'),
|
|
170
|
+
t('DAYSHORT2', 'Tue'),
|
|
171
|
+
t('DAYSHORT3', 'Wed'),
|
|
172
|
+
t('DAYSHORT4', 'Thu'),
|
|
173
|
+
t('DAYSHORT5', 'Fri'),
|
|
174
|
+
t('DAYSHORT6', 'Sat')
|
|
175
175
|
],
|
|
176
176
|
weekdaysMin: [
|
|
177
|
-
t('DAYMIN7','Su'),
|
|
178
|
-
t('DAYMIN1','Mo'),
|
|
179
|
-
t('DAYMIN2','Tu'),
|
|
180
|
-
t('DAYMIN3','We'),
|
|
181
|
-
t('DAYMIN4','Th'),
|
|
182
|
-
t('DAYMIN5','Fr'),
|
|
183
|
-
t('DAYMIN6','Sa')
|
|
177
|
+
t('DAYMIN7', 'Su'),
|
|
178
|
+
t('DAYMIN1', 'Mo'),
|
|
179
|
+
t('DAYMIN2', 'Tu'),
|
|
180
|
+
t('DAYMIN3', 'We'),
|
|
181
|
+
t('DAYMIN4', 'Th'),
|
|
182
|
+
t('DAYMIN5', 'Fr'),
|
|
183
|
+
t('DAYMIN6', 'Sa')
|
|
184
184
|
],
|
|
185
|
-
meridiem
|
|
186
|
-
return hours < 12 ? t('AM', 'AM') : t('PM','PM')
|
|
185
|
+
meridiem: function (hours) {
|
|
186
|
+
return hours < 12 ? t('AM', 'AM') : t('PM', 'PM')
|
|
187
187
|
}
|
|
188
|
-
|
|
188
|
+
})
|
|
189
189
|
}
|
|
190
190
|
|
|
191
191
|
useEffect(() => {
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import React, { useState, useEffect } from 'react'
|
|
2
|
+
import { useHistory } from 'react-router-dom'
|
|
2
3
|
import {
|
|
3
4
|
useLanguage,
|
|
4
5
|
useUtils,
|
|
@@ -62,6 +63,7 @@ const MultiCheckoutUI = (props) => {
|
|
|
62
63
|
const [customerState] = useCustomer()
|
|
63
64
|
const [validationFields] = useValidationFields()
|
|
64
65
|
const [{ user }] = useSession()
|
|
66
|
+
const history = useHistory()
|
|
65
67
|
|
|
66
68
|
const [userErrors, setUserErrors] = useState([])
|
|
67
69
|
const [isUserDetailsEdit, setIsUserDetailsEdit] = useState(null)
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
import { useLanguage } from 'ordering-components-external'
|
|
3
|
+
import { SingleProductCard } from '../SingleProductCard'
|
|
4
|
+
import {
|
|
5
|
+
Container,
|
|
6
|
+
ContentHeader,
|
|
7
|
+
ProductListWrapper,
|
|
8
|
+
ProductList
|
|
9
|
+
} from './styles'
|
|
10
|
+
import { AutoScroll } from '../AutoScroll'
|
|
11
|
+
|
|
12
|
+
export const OrderItAgain = (props) => {
|
|
13
|
+
const {
|
|
14
|
+
onProductClick,
|
|
15
|
+
isGroceries,
|
|
16
|
+
productList,
|
|
17
|
+
businessId
|
|
18
|
+
} = props
|
|
19
|
+
|
|
20
|
+
const [, t] = useLanguage()
|
|
21
|
+
|
|
22
|
+
return (
|
|
23
|
+
<Container isGroceries={isGroceries}>
|
|
24
|
+
<ContentHeader isGroceries={isGroceries}>
|
|
25
|
+
<h2>{t('ORDER_IT_AGAIN', 'Order it again')}</h2>
|
|
26
|
+
<p>{t('ORDER_IT_AGAIN_DESC', 'Quickly add items from your past orders.')}</p>
|
|
27
|
+
</ContentHeader>
|
|
28
|
+
<ProductListWrapper>
|
|
29
|
+
<ProductList>
|
|
30
|
+
<AutoScroll scrollId='orderItAgain'>
|
|
31
|
+
{productList.map((product, i) => (
|
|
32
|
+
<SingleProductCard
|
|
33
|
+
key={i}
|
|
34
|
+
isSoldOut={product.inventoried && !product.quantity}
|
|
35
|
+
businessId={businessId}
|
|
36
|
+
product={product}
|
|
37
|
+
onProductClick={onProductClick}
|
|
38
|
+
isPreviously
|
|
39
|
+
/>
|
|
40
|
+
))}
|
|
41
|
+
</AutoScroll>
|
|
42
|
+
</ProductList>
|
|
43
|
+
</ProductListWrapper>
|
|
44
|
+
</Container>
|
|
45
|
+
)
|
|
46
|
+
}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import styled, { css } from 'styled-components'
|
|
2
|
+
|
|
3
|
+
export const Container = styled.div`
|
|
4
|
+
padding-top: 30px;
|
|
5
|
+
margin-right: 30px;
|
|
6
|
+
${props => props.theme.rtl && css`
|
|
7
|
+
margin-left: 30px;
|
|
8
|
+
margin-right: 0px;
|
|
9
|
+
`}
|
|
10
|
+
${({ isGroceries }) => isGroceries && css`
|
|
11
|
+
padding-top: 0px;
|
|
12
|
+
margin-right: 0px;
|
|
13
|
+
margin-left: 0px;
|
|
14
|
+
`}
|
|
15
|
+
`
|
|
16
|
+
|
|
17
|
+
export const ContentHeader = styled.div`
|
|
18
|
+
margin-bottom: 27px;
|
|
19
|
+
|
|
20
|
+
> h2 {
|
|
21
|
+
font-weight: 600;
|
|
22
|
+
font-size: 24px;
|
|
23
|
+
line-height: 36px;
|
|
24
|
+
margin: 0px;
|
|
25
|
+
}
|
|
26
|
+
p {
|
|
27
|
+
font-weight: 400;
|
|
28
|
+
font-size: 14px;
|
|
29
|
+
line-height: 24px;
|
|
30
|
+
margin: 0px;
|
|
31
|
+
color: ${props => props.theme.colors.darkGray};
|
|
32
|
+
}
|
|
33
|
+
${({ isGroceries }) => isGroceries && css`
|
|
34
|
+
${props => props.theme.rtl ? css`
|
|
35
|
+
margin-right: 10px;
|
|
36
|
+
` : css`
|
|
37
|
+
margin-left: 10px;
|
|
38
|
+
`}
|
|
39
|
+
`}
|
|
40
|
+
`
|
|
41
|
+
|
|
42
|
+
export const ProductListWrapper = styled.div`
|
|
43
|
+
overflow: auto hidden;
|
|
44
|
+
width: 100%;
|
|
45
|
+
::-webkit-scrollbar {
|
|
46
|
+
width: 6px;
|
|
47
|
+
height: 6px;
|
|
48
|
+
}
|
|
49
|
+
`
|
|
50
|
+
|
|
51
|
+
export const ProductList = styled.div`
|
|
52
|
+
display: flex;
|
|
53
|
+
flex-direction: row;
|
|
54
|
+
box-sizing: border-box;
|
|
55
|
+
align-items: center;
|
|
56
|
+
|
|
57
|
+
#orderItAgain > div {
|
|
58
|
+
width: 350px;
|
|
59
|
+
}
|
|
60
|
+
`
|
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
import React, { useState } from 'react'
|
|
2
2
|
import { useLanguage } from 'ordering-components-external'
|
|
3
3
|
import FaUserAlt from '@meronex/icons/fa/FaUserAlt'
|
|
4
|
+
import { Heart as DisLike, HeartFill as Like } from 'react-bootstrap-icons'
|
|
4
5
|
import {
|
|
5
6
|
Container,
|
|
6
7
|
ProfessionalItem,
|
|
7
8
|
ProfessionalPhoto,
|
|
8
9
|
ContentWrapper,
|
|
9
|
-
ProfessionalListing
|
|
10
|
+
ProfessionalListing,
|
|
11
|
+
InfoWrapper,
|
|
12
|
+
HeartIconWrapper
|
|
10
13
|
} from './styles'
|
|
11
14
|
import { Modal } from '../Modal'
|
|
12
15
|
import { ProfessionalProfile } from '../ProfessionalProfile'
|
|
@@ -53,7 +56,12 @@ export const ProfessionalFilter = (props) => {
|
|
|
53
56
|
onClick={() => handleOpenProfile(professional)}
|
|
54
57
|
>
|
|
55
58
|
{professional?.photo ? <ProfessionalPhoto bgimage={professional?.photo} /> : <FaUserAlt />}
|
|
56
|
-
<
|
|
59
|
+
<InfoWrapper>
|
|
60
|
+
<p className='name'>{professional?.name} {professional?.lastname}</p>
|
|
61
|
+
<HeartIconWrapper>
|
|
62
|
+
{professional?.favorite ? <Like /> : <DisLike />}
|
|
63
|
+
</HeartIconWrapper>
|
|
64
|
+
</InfoWrapper>
|
|
57
65
|
</ProfessionalItem>
|
|
58
66
|
))}
|
|
59
67
|
</AutoScroll>
|
|
@@ -32,9 +32,14 @@ export const ProfessionalItem = styled.div`
|
|
|
32
32
|
height: 42px;
|
|
33
33
|
width: 42px;
|
|
34
34
|
min-width: 42px;
|
|
35
|
+
margin-right: 12px;
|
|
36
|
+
${props => props.theme.rtl && css`
|
|
37
|
+
margin-left: 12px;
|
|
38
|
+
margin-right: 0px;
|
|
39
|
+
`}
|
|
35
40
|
}
|
|
36
41
|
|
|
37
|
-
|
|
42
|
+
p {
|
|
38
43
|
font-weight: 400;
|
|
39
44
|
font-size: 14px;
|
|
40
45
|
line-height: 24px;
|
|
@@ -42,14 +47,6 @@ export const ProfessionalItem = styled.div`
|
|
|
42
47
|
white-space: nowrap;
|
|
43
48
|
overflow: hidden;
|
|
44
49
|
text-overflow: ellipsis;
|
|
45
|
-
|
|
46
|
-
&.name {
|
|
47
|
-
margin-left: 12px;
|
|
48
|
-
${props => props.theme.rtl && css`
|
|
49
|
-
margin-right: 12px;
|
|
50
|
-
margin-left: 0px;
|
|
51
|
-
`}
|
|
52
|
-
}
|
|
53
50
|
}
|
|
54
51
|
|
|
55
52
|
${({ active }) => active && css`
|
|
@@ -68,6 +65,11 @@ const ProfessionalPhotoStyled = styled.div`
|
|
|
68
65
|
width: 42px;
|
|
69
66
|
min-width: 42px;
|
|
70
67
|
border-radius: 7.6px;
|
|
68
|
+
margin-right: 12px;
|
|
69
|
+
${props => props.theme.rtl && css`
|
|
70
|
+
margin-left: 12px;
|
|
71
|
+
margin-right: 0px;
|
|
72
|
+
`}
|
|
71
73
|
`
|
|
72
74
|
export const ProfessionalPhoto = (props) => {
|
|
73
75
|
const style = {}
|
|
@@ -89,3 +91,16 @@ export const ContentWrapper = styled.div`
|
|
|
89
91
|
export const ProfessionalListing = styled.div`
|
|
90
92
|
display: flex;
|
|
91
93
|
`
|
|
94
|
+
|
|
95
|
+
export const InfoWrapper = styled.div`
|
|
96
|
+
width: calc(100% - 54px);
|
|
97
|
+
`
|
|
98
|
+
|
|
99
|
+
export const HeartIconWrapper = styled.div`
|
|
100
|
+
display: flex;
|
|
101
|
+
justify-content: flex-end;
|
|
102
|
+
svg {
|
|
103
|
+
color: ${props => props.theme.colors.danger500};
|
|
104
|
+
font-size: 16px;
|
|
105
|
+
}
|
|
106
|
+
`
|
|
@@ -40,6 +40,7 @@ import { SearchProducts as SearchProductsOld } from '../../../../../components/R
|
|
|
40
40
|
import { SearchProducts as SearchProductsStarbucks } from '../../../../six/src/components/BusinessProductsListing/SearchProducts'
|
|
41
41
|
import { ProfessionalFilter } from '../ProfessionalFilter'
|
|
42
42
|
import { SearchIconWrapper } from '../BusinessBasicInformation/styles'
|
|
43
|
+
import { OrderItAgain } from '../OrderItAgain'
|
|
43
44
|
|
|
44
45
|
const layoutOne = 'groceries'
|
|
45
46
|
|
|
@@ -111,7 +112,7 @@ export const RenderProductsLayout = (props) => {
|
|
|
111
112
|
layoutOne: frontLayout === layoutOne && isUseParentCategory
|
|
112
113
|
}
|
|
113
114
|
const showCartOnProductList = !orderingTheme?.theme?.business_view?.components?.cart?.components?.hidden
|
|
114
|
-
const hideBusinessNearCity =
|
|
115
|
+
const hideBusinessNearCity = theme?.business_view?.components?.near_business?.hidden ?? true
|
|
115
116
|
|
|
116
117
|
const BusinessLayoutCategories = businessLayout.layoutOne
|
|
117
118
|
? CategoriesLayoutGroceries
|
|
@@ -125,7 +126,7 @@ export const RenderProductsLayout = (props) => {
|
|
|
125
126
|
<>
|
|
126
127
|
{!isLoading && business?.id && (
|
|
127
128
|
<WrappLayout isCartOnProductsList={isCartOnProductsList}>
|
|
128
|
-
{
|
|
129
|
+
{!hideBusinessNearCity && !useKioskApp && (
|
|
129
130
|
<NearBusiness>
|
|
130
131
|
<BusinessesListing
|
|
131
132
|
logosLayout
|
|
@@ -234,6 +235,13 @@ export const RenderProductsLayout = (props) => {
|
|
|
234
235
|
/>
|
|
235
236
|
</ProfessionalFilterWrapper>
|
|
236
237
|
)}
|
|
238
|
+
{!business?.loading && business?.previously_products?.length > 0 && (
|
|
239
|
+
<OrderItAgain
|
|
240
|
+
onProductClick={onProductClick}
|
|
241
|
+
productList={business?.previously_products}
|
|
242
|
+
businessId={business?.id}
|
|
243
|
+
/>
|
|
244
|
+
)}
|
|
237
245
|
<BusinessLayoutProductsList
|
|
238
246
|
categories={[
|
|
239
247
|
{ id: null, name: t('ALL', theme?.defaultLanguages?.ALL || 'All') },
|
|
@@ -328,11 +336,20 @@ export const RenderProductsLayout = (props) => {
|
|
|
328
336
|
openCategories={openCategories}
|
|
329
337
|
business={business}
|
|
330
338
|
currentCart={currentCart}
|
|
339
|
+
useKioskApp={useKioskApp}
|
|
331
340
|
/>
|
|
332
341
|
)}
|
|
333
342
|
</BusinessCategoriesContainer>
|
|
334
343
|
<BusinessCategoryProductWrapper>
|
|
335
|
-
<WrapContent>
|
|
344
|
+
<WrapContent isGroceries>
|
|
345
|
+
{!business?.loading && business?.previously_products?.length > 0 && (
|
|
346
|
+
<OrderItAgain
|
|
347
|
+
onProductClick={onProductClick}
|
|
348
|
+
productList={business?.previously_products}
|
|
349
|
+
businessId={business?.id}
|
|
350
|
+
isGroceries
|
|
351
|
+
/>
|
|
352
|
+
)}
|
|
336
353
|
<BusinessLayoutProductsList
|
|
337
354
|
categories={[
|
|
338
355
|
{ id: null, name: t('ALL', theme?.defaultLanguages?.ALL || 'All') },
|
|
@@ -12,9 +12,12 @@ export const WrappLayout = styled.div``
|
|
|
12
12
|
|
|
13
13
|
export const WrapContent = styled.div`
|
|
14
14
|
padding: 5px;
|
|
15
|
-
margin-top: 70px;
|
|
16
15
|
background: ${props => props.theme.colors.backgroundPage};
|
|
17
16
|
|
|
17
|
+
${({ isGroceries }) => !isGroceries && css`
|
|
18
|
+
margin-top: 70px;
|
|
19
|
+
`}
|
|
20
|
+
|
|
18
21
|
@media (min-width: 576px) {
|
|
19
22
|
padding: 0px;
|
|
20
23
|
}
|
|
@@ -51,7 +54,7 @@ export const BusinessCategoryProductWrapper = styled.div`
|
|
|
51
54
|
}
|
|
52
55
|
|
|
53
56
|
@media (min-width: 1000px) {
|
|
54
|
-
width: ${({ showCartOnProductList }) => showCartOnProductList ? '70%' : '
|
|
57
|
+
width: ${({ showCartOnProductList }) => showCartOnProductList ? '70%' : '85%'};
|
|
55
58
|
}
|
|
56
59
|
`
|
|
57
60
|
|
|
@@ -214,11 +217,15 @@ export const ProfessionalFilterWrapper = styled.div`
|
|
|
214
217
|
export const WrapperSearchAbsolute = styled.div`
|
|
215
218
|
position: absolute;
|
|
216
219
|
right: 5px;
|
|
217
|
-
top:
|
|
218
|
-
height: 100%;
|
|
220
|
+
top: 0px;
|
|
219
221
|
display: flex;
|
|
220
222
|
justify-content: center;
|
|
221
|
-
align-items:
|
|
223
|
+
align-items: flex-end;
|
|
224
|
+
width: 40px;
|
|
225
|
+
height: 52px;
|
|
226
|
+
background-color: ${props => props.theme.colors.backgroundPage};
|
|
227
|
+
box-sizing: border-box;
|
|
228
|
+
padding-bottom: 5px;
|
|
222
229
|
`
|
|
223
230
|
|
|
224
231
|
export const NearBusiness = styled.div`
|
|
@@ -9,15 +9,18 @@ export const ActionBlock = styled.div`
|
|
|
9
9
|
justify-content: space-between;
|
|
10
10
|
margin-top: 30px;
|
|
11
11
|
width: 100%;
|
|
12
|
+
|
|
12
13
|
span {
|
|
13
14
|
cursor: pointer;
|
|
14
15
|
font-weight: 600;
|
|
15
16
|
font-size: 16px;
|
|
16
17
|
user-select: none;
|
|
17
18
|
}
|
|
19
|
+
|
|
18
20
|
button {
|
|
19
21
|
font-size: 14px;
|
|
20
22
|
padding: 6px 20px;
|
|
23
|
+
|
|
21
24
|
svg {
|
|
22
25
|
color: white;
|
|
23
26
|
font-size: 21px;
|
|
@@ -40,6 +43,7 @@ export const HandReviewWrapper = styled.div`
|
|
|
40
43
|
display: flex;
|
|
41
44
|
align-items: center;
|
|
42
45
|
justify-content: space-between;
|
|
46
|
+
|
|
43
47
|
p {
|
|
44
48
|
font-size: 15px;
|
|
45
49
|
color: ${props => props.theme?.colors.headingColor};
|
|
@@ -58,16 +62,19 @@ export const HandReviewContent = styled.div`
|
|
|
58
62
|
|
|
59
63
|
export const HandIconWrapper = styled.span`
|
|
60
64
|
margin-left: 15px;
|
|
65
|
+
|
|
61
66
|
${props => props.theme?.rtl && css`
|
|
62
67
|
margin-right: 15px;
|
|
63
68
|
margin-left: 0;
|
|
64
69
|
`}
|
|
70
|
+
|
|
65
71
|
svg {
|
|
66
72
|
font-size: 24px;
|
|
67
73
|
color: #B1BCCC;
|
|
68
74
|
cursor: pointer;
|
|
69
75
|
transition: all 0.3s linear;
|
|
70
76
|
}
|
|
77
|
+
|
|
71
78
|
${({ active }) => active && css`
|
|
72
79
|
svg {
|
|
73
80
|
color: ${props => props.theme?.colors.primary};
|
|
@@ -86,6 +93,7 @@ export const AddCommentHideShow = styled.p`
|
|
|
86
93
|
transition: all 0.3s linear;
|
|
87
94
|
color: #909BA9;
|
|
88
95
|
font-size: 13px;
|
|
96
|
+
|
|
89
97
|
&:hover {
|
|
90
98
|
color: ${props => props.theme?.colors.primary};
|
|
91
99
|
}
|
|
@@ -97,12 +105,14 @@ export const AddCommentHideShow = styled.p`
|
|
|
97
105
|
|
|
98
106
|
export const Comments = styled.div`
|
|
99
107
|
margin-top: 50px;
|
|
108
|
+
|
|
100
109
|
p {
|
|
101
110
|
margin-top: 0;
|
|
102
111
|
margin-bottom: 8px;
|
|
103
112
|
font-size: 14px;
|
|
104
113
|
color: #344050;
|
|
105
114
|
}
|
|
115
|
+
|
|
106
116
|
textarea {
|
|
107
117
|
width: 100%;
|
|
108
118
|
box-sizing: border-box;
|
|
@@ -124,18 +134,22 @@ export const ButtonCustomized = styled(Button)`
|
|
|
124
134
|
background: #E9ECEF;
|
|
125
135
|
border: 1px solid #E9ECEF;
|
|
126
136
|
transition: all 0.3s linear;
|
|
137
|
+
|
|
127
138
|
${props => props.theme?.rtl && css`
|
|
128
139
|
margin-left: 18px;
|
|
129
140
|
margin-right: 0;
|
|
130
141
|
`}
|
|
142
|
+
|
|
131
143
|
svg {
|
|
132
144
|
vertical-align: middle;
|
|
133
145
|
margin-left: 5px;
|
|
146
|
+
|
|
134
147
|
${props => props.theme?.rtl && css`
|
|
135
148
|
margin-right: 5px;
|
|
136
149
|
margin-left: 0;
|
|
137
150
|
`}
|
|
138
151
|
}
|
|
152
|
+
|
|
139
153
|
${({ active }) => active && css`
|
|
140
154
|
background: ${props => props.theme?.colors.primary};
|
|
141
155
|
border: 1px solid ${props => props.theme?.colors.primary};
|
|
@@ -33,7 +33,8 @@ import {
|
|
|
33
33
|
NameWrapper,
|
|
34
34
|
StatusInfo,
|
|
35
35
|
DropDownWrapper,
|
|
36
|
-
DropDownTitle
|
|
36
|
+
DropDownTitle,
|
|
37
|
+
EmptyProfessional
|
|
37
38
|
} from './styles'
|
|
38
39
|
import moment from 'moment'
|
|
39
40
|
SwiperCore.use([Navigation])
|
|
@@ -201,31 +202,35 @@ const ServiceFormUI = (props) => {
|
|
|
201
202
|
</SectionHeader>
|
|
202
203
|
<ProfessionalSelectWrapper ref={dropDownRef}>
|
|
203
204
|
<SelectedItem onClick={() => setIsDropDown(prev => !prev)}>
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
<
|
|
212
|
-
|
|
213
|
-
{isBusyTime(
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
205
|
+
{currentProfessional ? (
|
|
206
|
+
<InfoWrapper>
|
|
207
|
+
{currentProfessional?.photo ? (
|
|
208
|
+
<ProfessionalPhoto
|
|
209
|
+
bgimage={currentProfessional?.photo}
|
|
210
|
+
/>
|
|
211
|
+
) : <FaUserAlt />}
|
|
212
|
+
<NameWrapper>
|
|
213
|
+
<p>{currentProfessional?.name} {currentProfessional?.lastname}</p>
|
|
214
|
+
<StatusInfo available={!isBusyTime()}>
|
|
215
|
+
{isBusyTime(currentProfessional) ? (
|
|
216
|
+
<>
|
|
217
|
+
<span className='status'>{t('BUSY_ON_SELECTED_TIME', 'Busy on selected time')}</span>
|
|
218
|
+
</>
|
|
219
|
+
) : (
|
|
220
|
+
<span className='status'>{t('AVAILABLE', 'Available')}</span>
|
|
221
|
+
)}
|
|
222
|
+
</StatusInfo>
|
|
223
|
+
</NameWrapper>
|
|
224
|
+
</InfoWrapper>
|
|
225
|
+
) : (
|
|
226
|
+
<p>{t('SELECT_PROFESSIONAL', 'Select professional')}</p>
|
|
227
|
+
)}
|
|
223
228
|
<ChevronDown />
|
|
224
229
|
</SelectedItem>
|
|
225
230
|
{isDropDown && (
|
|
226
231
|
<DropDownWrapper>
|
|
227
232
|
<DropDownTitle>{t('ANY_PROFESSIONAL_MEMBER', 'Any professional member')}</DropDownTitle>
|
|
228
|
-
{professionalList?.map((professional) =>
|
|
233
|
+
{professionalList?.map((professional) => (
|
|
229
234
|
<SelectedItem
|
|
230
235
|
key={professional?.id}
|
|
231
236
|
isDropDown
|
|
@@ -263,7 +268,7 @@ const ServiceFormUI = (props) => {
|
|
|
263
268
|
<h2>{t('SCHEDULE', 'Schedule')}</h2>
|
|
264
269
|
<span>{t('REQUIRED', 'Required')}</span>
|
|
265
270
|
</SectionHeader>
|
|
266
|
-
{currentProfessional
|
|
271
|
+
{currentProfessional ? (
|
|
267
272
|
<BusinessPreorder
|
|
268
273
|
business={currentProfessional}
|
|
269
274
|
isProfessional
|
|
@@ -271,6 +276,10 @@ const ServiceFormUI = (props) => {
|
|
|
271
276
|
onChangeMoment={setDateSelected}
|
|
272
277
|
useOrderContext={false}
|
|
273
278
|
/>
|
|
279
|
+
) : (
|
|
280
|
+
<EmptyProfessional>
|
|
281
|
+
{t('NO_SCHEDULE', 'No schedule')}
|
|
282
|
+
</EmptyProfessional>
|
|
274
283
|
)}
|
|
275
284
|
</ScheduleWrapper>
|
|
276
285
|
<ButtonWrapper>
|
|
@@ -190,6 +190,8 @@ export const DropDownWrapper = styled.div`
|
|
|
190
190
|
width: 100%;
|
|
191
191
|
z-index: 10;
|
|
192
192
|
box-sizing: border-box;
|
|
193
|
+
max-height: 263px;
|
|
194
|
+
overflow: auto;
|
|
193
195
|
`
|
|
194
196
|
|
|
195
197
|
export const SelectedItem = styled.div`
|
|
@@ -203,6 +205,11 @@ export const SelectedItem = styled.div`
|
|
|
203
205
|
cursor: pointer;
|
|
204
206
|
transition: all 0.3s linear;
|
|
205
207
|
|
|
208
|
+
> p {
|
|
209
|
+
margin: 0px;
|
|
210
|
+
line-height: 42px;
|
|
211
|
+
}
|
|
212
|
+
|
|
206
213
|
${({ isDropDown }) => isDropDown && css`
|
|
207
214
|
border: none;
|
|
208
215
|
padding: 12px 0px;
|
|
@@ -295,3 +302,12 @@ export const StatusInfo = styled.div`
|
|
|
295
302
|
}
|
|
296
303
|
`}
|
|
297
304
|
`
|
|
305
|
+
|
|
306
|
+
export const EmptyProfessional = styled.div`
|
|
307
|
+
min-height: 100px;
|
|
308
|
+
margin-bottom: 100px;
|
|
309
|
+
text-align: center;
|
|
310
|
+
display: flex;
|
|
311
|
+
align-items: center;
|
|
312
|
+
justify-content: center;
|
|
313
|
+
`
|