ordering-ui-react-native 0.17.9 → 0.17.10
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
|
@@ -6,7 +6,7 @@ import CalendarPicker from 'react-native-calendar-picker'
|
|
|
6
6
|
import FeatherIcon from 'react-native-vector-icons/Feather';
|
|
7
7
|
import moment from 'moment'
|
|
8
8
|
import SelectDropdown from 'react-native-select-dropdown'
|
|
9
|
-
import { OButton, OText } from '../shared'
|
|
9
|
+
import { OButton, OText, OIcon } from '../shared'
|
|
10
10
|
import IconAntDesign from 'react-native-vector-icons/AntDesign'
|
|
11
11
|
import { useSafeAreaInsets } from 'react-native-safe-area-context'
|
|
12
12
|
import { ProfessionalProfileParams } from '../../types'
|
|
@@ -58,6 +58,9 @@ export const ProfessionalProfile = (props: ProfessionalProfileParams) => {
|
|
|
58
58
|
height: 40,
|
|
59
59
|
marginBottom: 30
|
|
60
60
|
},
|
|
61
|
+
photoStyle: {
|
|
62
|
+
alignSelf: 'center'
|
|
63
|
+
}
|
|
61
64
|
})
|
|
62
65
|
|
|
63
66
|
const onDateChange = (date: any) => {
|
|
@@ -151,13 +154,21 @@ export const ProfessionalProfile = (props: ProfessionalProfileParams) => {
|
|
|
151
154
|
|
|
152
155
|
return (
|
|
153
156
|
<Container>
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
157
|
+
{!!professional?.photo ? (
|
|
158
|
+
<ProfessionalPhoto
|
|
159
|
+
source={{
|
|
160
|
+
uri: professional?.photo
|
|
161
|
+
}}
|
|
162
|
+
/>
|
|
163
|
+
) : (
|
|
164
|
+
<OIcon
|
|
165
|
+
src={theme.images.general.user}
|
|
166
|
+
style={styles.photoStyle}
|
|
167
|
+
cover={false}
|
|
168
|
+
width={200}
|
|
169
|
+
height={200}
|
|
170
|
+
/>
|
|
171
|
+
)}
|
|
161
172
|
<InfoWrapper>
|
|
162
173
|
<OText
|
|
163
174
|
size={20}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { useState, useEffect, useRef } from 'react'
|
|
2
2
|
import { useTheme } from 'styled-components/native'
|
|
3
3
|
import { Platform, View, StyleSheet, Dimensions, ScrollView, TouchableOpacity } from 'react-native'
|
|
4
|
-
import { OText, OButton, OModal } from '../shared'
|
|
4
|
+
import { OText, OButton, OModal, OIcon } from '../shared'
|
|
5
5
|
import FastImage from 'react-native-fast-image'
|
|
6
6
|
import IconAntDesign from 'react-native-vector-icons/AntDesign'
|
|
7
7
|
import SelectDropdown from 'react-native-select-dropdown'
|
|
@@ -241,13 +241,21 @@ const ServiceFormUI = (props: ServiceFormParams) => {
|
|
|
241
241
|
return (
|
|
242
242
|
<>
|
|
243
243
|
<Container>
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
244
|
+
{!!product?.images ? (
|
|
245
|
+
<ProfessionalPhoto
|
|
246
|
+
source={{
|
|
247
|
+
uri: product?.images
|
|
248
|
+
}}
|
|
249
|
+
/>
|
|
250
|
+
) : (
|
|
251
|
+
<OIcon
|
|
252
|
+
src={theme?.images?.dummies?.product}
|
|
253
|
+
cover={false}
|
|
254
|
+
style={{ alignSelf: 'center' }}
|
|
255
|
+
width={200}
|
|
256
|
+
height={200}
|
|
257
|
+
/>
|
|
258
|
+
)}
|
|
251
259
|
<InfoWrapper>
|
|
252
260
|
<OText
|
|
253
261
|
size={20}
|
|
@@ -301,14 +309,22 @@ const ServiceFormUI = (props: ServiceFormParams) => {
|
|
|
301
309
|
onPress={() => setIsOpen(true)}
|
|
302
310
|
>
|
|
303
311
|
<View style={{ flexDirection: 'row' }}>
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
+
{!!currentProfessional?.photo ? (
|
|
313
|
+
<FastImage
|
|
314
|
+
style={styles.photoStyle}
|
|
315
|
+
source={{
|
|
316
|
+
uri: optimizeImage(currentProfessional?.photo, 'h_250,c_limit'),
|
|
317
|
+
priority: FastImage.priority.normal,
|
|
318
|
+
}}
|
|
319
|
+
resizeMode={FastImage.resizeMode.cover}
|
|
320
|
+
/>
|
|
321
|
+
) : (
|
|
322
|
+
<OIcon
|
|
323
|
+
src={theme?.images?.general?.user}
|
|
324
|
+
cover={false}
|
|
325
|
+
style={styles.photoStyle}
|
|
326
|
+
/>
|
|
327
|
+
)}
|
|
312
328
|
<View style={{ marginLeft: 14 }}>
|
|
313
329
|
<OText
|
|
314
330
|
size={14}
|
|
@@ -532,14 +548,22 @@ const ServiceFormUI = (props: ServiceFormParams) => {
|
|
|
532
548
|
onPress={() => handleChangeProfessional(professional)}
|
|
533
549
|
>
|
|
534
550
|
<View style={{ flexDirection: 'row' }}>
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
551
|
+
{!!professional?.photo ? (
|
|
552
|
+
<FastImage
|
|
553
|
+
style={styles.photoStyle}
|
|
554
|
+
source={{
|
|
555
|
+
uri: optimizeImage(professional?.photo, 'h_250,c_limit'),
|
|
556
|
+
priority: FastImage.priority.normal,
|
|
557
|
+
}}
|
|
558
|
+
resizeMode={FastImage.resizeMode.cover}
|
|
559
|
+
/>
|
|
560
|
+
) : (
|
|
561
|
+
<OIcon
|
|
562
|
+
src={theme?.images?.general?.user}
|
|
563
|
+
cover={false}
|
|
564
|
+
style={styles.photoStyle}
|
|
565
|
+
/>
|
|
566
|
+
)}
|
|
543
567
|
<View style={{ marginLeft: 14 }}>
|
|
544
568
|
<OText
|
|
545
569
|
size={14}
|