@nyris/nyris-webapp 0.3.33 → 0.3.34

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 (82) hide show
  1. package/build/asset-manifest.json +28 -14
  2. package/build/index.html +1 -1
  3. package/build/js/settings.example.js +13 -25
  4. package/build/{precache-manifest.4cff5b8aafe3d00d59bc2c9725eb6ade.js → precache-manifest.b85c7807a93875355f9f0f6490e6dc8c.js} +70 -14
  5. package/build/service-worker.js +1 -1
  6. package/build/static/css/main.f2aa67fc.chunk.css +2 -0
  7. package/build/static/css/main.f2aa67fc.chunk.css.map +1 -0
  8. package/build/static/js/2.d1f7e826.chunk.js +3 -0
  9. package/build/static/js/2.d1f7e826.chunk.js.map +1 -0
  10. package/build/static/js/main.e9aec8a9.chunk.js +3 -0
  11. package/build/static/js/main.e9aec8a9.chunk.js.map +1 -0
  12. package/build/static/media/filter.bc412f08.svg +3 -0
  13. package/build/static/media/icon_search_image2.fab34be4.svg +3 -0
  14. package/build/static/media/img-1-1.6144e5f9.png +0 -0
  15. package/build/static/media/img-1-2.ad943f0f.png +0 -0
  16. package/build/static/media/img2-1.a87c79c7.png +0 -0
  17. package/build/static/media/img2-2.39c5b73f.png +0 -0
  18. package/build/static/media/img3-1.443b0c3a.png +0 -0
  19. package/build/static/media/img3-2.37db7999.png +0 -0
  20. package/build/static/media/img4-1.9c34c158.png +0 -0
  21. package/build/static/media/img4-2.9d280a04.png +0 -0
  22. package/build/static/media/img5-1.b61dbd4d.png +0 -0
  23. package/build/static/media/img5-2.1c77c093.png +0 -0
  24. package/build/static/media/img6-1.8b03dd21.png +0 -0
  25. package/build/static/media/img6-2.1e3e7fed.png +0 -0
  26. package/build/static/media/{info-tooltip.5feeef22.svg → info-tooltip.b98e8a9c.svg} +2 -2
  27. package/build/static/media/take_photo.76423216.svg +5 -0
  28. package/package.json +3 -3
  29. package/public/js/settings.example.js +13 -25
  30. package/src/Store/constants.ts +0 -1
  31. package/src/Store/search/Search.ts +32 -17
  32. package/src/Store/search/search.initialState.ts +17 -16
  33. package/src/Store/search/types.ts +15 -14
  34. package/src/common/assets/icons/expand.svg +3 -27
  35. package/src/common/assets/icons/filter.svg +3 -0
  36. package/src/common/assets/icons/icon_search_image2.svg +2 -25
  37. package/src/common/assets/icons/info-tooltip.svg +2 -2
  38. package/src/common/assets/icons/take_photo.svg +5 -0
  39. package/src/common/assets/images/imageCaptureHelp/img-1-1.png +0 -0
  40. package/src/common/assets/images/imageCaptureHelp/img-1-2.png +0 -0
  41. package/src/common/assets/images/imageCaptureHelp/img2-1.png +0 -0
  42. package/src/common/assets/images/imageCaptureHelp/img2-2.png +0 -0
  43. package/src/common/assets/images/imageCaptureHelp/img3-1.png +0 -0
  44. package/src/common/assets/images/imageCaptureHelp/img3-2.png +0 -0
  45. package/src/common/assets/images/imageCaptureHelp/img4-1.png +0 -0
  46. package/src/common/assets/images/imageCaptureHelp/img4-2.png +0 -0
  47. package/src/common/assets/images/imageCaptureHelp/img5-1.png +0 -0
  48. package/src/common/assets/images/imageCaptureHelp/img5-2.png +0 -0
  49. package/src/common/assets/images/imageCaptureHelp/img6-1.png +0 -0
  50. package/src/common/assets/images/imageCaptureHelp/img6-2.png +0 -0
  51. package/src/components/DetailItem.tsx +54 -73
  52. package/src/components/FooterMobile.tsx +80 -41
  53. package/src/components/HeaderMobile.tsx +225 -227
  54. package/src/components/ImageCaptureHelpModal.tsx +90 -0
  55. package/src/components/Layout.tsx +39 -9
  56. package/src/components/MobilePostFilter.tsx +20 -0
  57. package/src/components/PanelResult/expandable-panel.tsx +21 -21
  58. package/src/components/PanelResult/index.tsx +52 -19
  59. package/src/components/ProductList/index.tsx +5 -3
  60. package/src/components/appMobile.scss +64 -32
  61. package/src/components/carousel/ImagePreviewCarousel.tsx +1 -1
  62. package/src/components/drawer/cameraCustom.tsx +8 -33
  63. package/src/components/input/inputSearch.tsx +68 -80
  64. package/src/components/pre-filter/index.tsx +31 -22
  65. package/src/components/results/ItemResult.tsx +79 -84
  66. package/src/constants.ts +56 -0
  67. package/src/page/landingPage/AppMobile.tsx +34 -104
  68. package/src/page/landingPage/common.scss +164 -36
  69. package/src/page/result/index.tsx +70 -56
  70. package/src/services/Feedback.ts +20 -2
  71. package/src/services/types.ts +0 -1
  72. package/src/translations.ts +4 -0
  73. package/src/types.ts +3 -2
  74. package/build/static/css/main.d0b21fa5.chunk.css +0 -2
  75. package/build/static/css/main.d0b21fa5.chunk.css.map +0 -1
  76. package/build/static/js/2.69ce0823.chunk.js +0 -3
  77. package/build/static/js/2.69ce0823.chunk.js.map +0 -1
  78. package/build/static/js/main.6122377b.chunk.js +0 -3
  79. package/build/static/js/main.6122377b.chunk.js.map +0 -1
  80. package/build/static/media/icon_search_image2.e46fdfc5.svg +0 -26
  81. /package/build/static/js/{2.69ce0823.chunk.js.LICENSE.txt → 2.d1f7e826.chunk.js.LICENSE.txt} +0 -0
  82. /package/build/static/js/{main.6122377b.chunk.js.LICENSE.txt → main.e9aec8a9.chunk.js.LICENSE.txt} +0 -0
@@ -20,7 +20,7 @@ interface Props {
20
20
  numberResult?: number;
21
21
  handlerCloseModal?: () => void;
22
22
  dataItem?: any;
23
- onHandlerModalShare?: () => void;
23
+ onHandlerModalShare: () => void;
24
24
  onSearchImage?: any;
25
25
  moreInfoText?: string;
26
26
  handlerFeedback: any;
@@ -31,7 +31,7 @@ function DetailItem(props: Props) {
31
31
  handlerCloseModal,
32
32
  dataItem,
33
33
  onSearchImage,
34
- // onHandlerModalShare,
34
+ onHandlerModalShare,
35
35
  handlerFeedback,
36
36
  } = props;
37
37
  const [collapDescription, setCollapDescription] = useState(false);
@@ -125,7 +125,7 @@ function DetailItem(props: Props) {
125
125
  }
126
126
  }}
127
127
  >
128
- <IconSearchImage color={settings.theme?.secondaryColor} />
128
+ <IconSearchImage color={'#AAABB5'} />
129
129
  </Button>
130
130
  )}
131
131
  </Box>
@@ -145,7 +145,7 @@ function DetailItem(props: Props) {
145
145
  <Grid container justifyContent="space-between">
146
146
  <Grid item xs={12}>
147
147
  <Typography className="text-f13 fw-500 max-line-1">
148
- {settings.itemIdLabel || 'SKU'}: {sku}
148
+ {settings.itemIdLabel || 'SKU'}: <span> {sku}</span>
149
149
  </Typography>
150
150
  {dataItem[settings.field.manufacturerNumber] && (
151
151
  <Typography
@@ -200,25 +200,54 @@ function DetailItem(props: Props) {
200
200
  </Typography>
201
201
  </Box>
202
202
  )}
203
- {!settings.warehouseVariant && (
204
- <Typography
205
- className={
206
- isMobile
207
- ? 'fw-600 text-dark'
208
- : 'text-f22 fw-600 text-dark'
209
- }
203
+ </Grid>
204
+ <Grid item xs={12}>
205
+ <Box
206
+ style={{
207
+ background: `linear-gradient(270deg, ${settings.theme?.primaryColor}bb 0%, ${settings.theme?.primaryColor} 100%)`,
208
+ // marginBottom: 25,
209
+ boxShadow: '0px 4px 4px rgba(0, 0, 0, 0.25)',
210
+ borderRadius: 4,
211
+ marginTop: 12,
212
+ }}
213
+ display={'flex'}
214
+ justifyContent={'space-between'}
215
+ alignItems={'center'}
216
+ className="btn-detail-item"
217
+ >
218
+ <Button
210
219
  style={{
211
- marginTop: '12px',
212
- display: 'inline-block',
213
- maxWidth: '100%',
214
- wordWrap: 'break-word',
220
+ display: 'flex',
221
+ justifyContent: 'space-between',
222
+ width: '100%',
223
+ padding: '0px 12px',
224
+ minHeight: 64,
215
225
  }}
226
+ onClick={() =>
227
+ window.open(
228
+ `${dataItem[settings.field.ctaLinkField]}`,
229
+ '_blank',
230
+ )
231
+ }
216
232
  >
217
- {dataItem[settings.field.productName]}
218
- </Typography>
219
- )}
220
- </Grid>
221
- <Grid item xs={12}>
233
+ <Typography
234
+ className="text-f18 fw-700 text-white max-line-2"
235
+ align="left"
236
+ style={{
237
+ letterSpacing: '0.55px',
238
+ maxWidth: '300px',
239
+ paddingRight: '4px',
240
+ }}
241
+ >
242
+ {dataItem[settings.field.productName]}
243
+ </Typography>
244
+ <img
245
+ src={IconOpenLink}
246
+ alt=""
247
+ style={{ minWidth: 23, marginLeft: 5 }}
248
+ />
249
+ </Button>
250
+ </Box>
222
251
  {dataItem[settings.field.productDetails] && (
223
252
  <Box className="w-100">
224
253
  <Button
@@ -252,57 +281,6 @@ function DetailItem(props: Props) {
252
281
  </Collapse>
253
282
  </Box>
254
283
  )}
255
- {(settings.showMoreInfo || settings.warehouseVariant) && (
256
- <Box
257
- style={{
258
- background: `linear-gradient(270deg, ${settings.theme?.primaryColor}bb 0%, ${settings.theme?.primaryColor} 100%)`,
259
- // marginBottom: 25,
260
- boxShadow: '0px 4px 4px rgba(0, 0, 0, 0.25)',
261
- borderRadius: 4,
262
- marginTop: 12,
263
- }}
264
- display={'flex'}
265
- justifyContent={'space-between'}
266
- alignItems={'center'}
267
- className="btn-detail-item"
268
- >
269
- <Button
270
- style={{
271
- display: 'flex',
272
- justifyContent: 'space-between',
273
- width: '100%',
274
- padding: '0px 12px',
275
- minHeight: !settings.warehouseVariant ? 48 : 64,
276
- }}
277
- onClick={() =>
278
- window.open(
279
- `${dataItem[settings.field.ctaLinkField]}`,
280
- '_blank',
281
- )
282
- }
283
- >
284
- <Typography
285
- className="text-f18 fw-700 text-white max-line-2"
286
- align="left"
287
- style={{
288
- textTransform: !settings.warehouseVariant
289
- ? 'uppercase'
290
- : 'none',
291
- letterSpacing: '0.55px',
292
- }}
293
- >
294
- {settings.warehouseVariant
295
- ? dataItem[settings.field.productName]
296
- : settings.productCtaText || 'MORE INFO'}
297
- </Typography>
298
- <img
299
- src={IconOpenLink}
300
- alt=""
301
- style={{ width: 23, marginLeft: 5 }}
302
- />
303
- </Button>
304
- </Box>
305
- )}
306
284
  </Grid>
307
285
  </Grid>
308
286
  </Box>
@@ -402,8 +380,11 @@ function DetailItem(props: Props) {
402
380
  {settings.shareOption && (
403
381
  <Grid item>
404
382
  <Box display={'flex'} alignItems={'center'}>
405
- <Button className="btn-item" onClick={() => false}>
406
- <IconShare width={30} height={30} color="gray" />
383
+ <Button
384
+ className="btn-item"
385
+ onClick={() => onHandlerModalShare()}
386
+ >
387
+ <IconShare width={30} height={30} color="#000000" />
407
388
  </Button>
408
389
  </Box>
409
390
  </Grid>
@@ -4,7 +4,9 @@ import { ReactComponent as IconCameraMobile } from 'common/assets/icons/icon_cam
4
4
  import CameraCustom from './drawer/cameraCustom';
5
5
  import { ReactComponent as Home } from 'common/assets/icons/home.svg';
6
6
  import { NavLink, useHistory } from 'react-router-dom';
7
- import { useAppSelector } from 'Store/Store';
7
+ import { useAppDispatch, useAppSelector } from 'Store/Store';
8
+ import { ReactComponent as IconInfo } from 'common/assets/icons/info-tooltip.svg';
9
+ import { setImageCaptureHelpModal } from 'Store/search/Search';
8
10
 
9
11
  interface Props {
10
12
  onLoadingMobile?: any;
@@ -13,53 +15,90 @@ interface Props {
13
15
  function FooterMobile(props: Props): JSX.Element {
14
16
  const [isOpenModalCamera, setOpenModalCamera] = useState<boolean>(false);
15
17
  const history = useHistory();
16
- const { settings } = useAppSelector(state => state);
18
+ const {
19
+ settings,
20
+ search: { imageCaptureHelpModal },
21
+ } = useAppSelector(state => state);
22
+ const dispatch = useAppDispatch();
17
23
 
18
24
  return (
19
- <Box
20
- className="box-footer-mobile"
21
- display={'flex'}
22
- position={'relative'}
23
- alignItems={'center'}
24
- height={'100%'}
25
- >
26
- <NavLink
27
- style={{
28
- width: '70px',
29
- display: 'flex',
30
- justifyContent: 'center',
31
- height: '100%',
32
- alignItems: 'center',
33
- backgroundColor:
34
- history.location.pathname === '/'
35
- ? `${settings.theme?.primaryColor}21`
36
- : '',
37
- }}
38
- activeClassName="active"
39
- to={'/'}
40
- className="nav-link p-0 menu-children rounded-0"
41
- >
42
- <Home
43
- color={
44
- history.location.pathname === '/'
45
- ? settings.theme?.primaryColor
46
- : '#000'
47
- }
48
- />
49
- </NavLink>
25
+ <>
50
26
  <Box
51
- style={{ background: settings.theme?.primaryColor }}
52
- className="box-icon-camera-mobile"
27
+ className="box-footer-mobile"
28
+ display={'flex'}
29
+ position={'relative'}
30
+ alignItems={'center'}
31
+ height={'100%'}
32
+ justifyContent={'space-between'}
33
+ style={{ paddingLeft: '40px', paddingRight: '40px' }}
53
34
  >
54
- <Button
35
+ <NavLink
36
+ style={{
37
+ width: '48px',
38
+ height: '48px',
39
+ display: 'flex',
40
+ alignItems: 'center',
41
+ justifyContent: 'center',
42
+ borderRadius: '100%',
43
+ backgroundColor:
44
+ history.location.pathname === '/' && !imageCaptureHelpModal
45
+ ? `${settings.theme?.primaryColor}21`
46
+ : '',
47
+ }}
48
+ activeClassName="active"
49
+ to={'/'}
50
+ className="nav-link p-0 menu-children rounded-0"
55
51
  onClick={() => {
56
- setOpenModalCamera(!isOpenModalCamera);
52
+ dispatch(setImageCaptureHelpModal(false));
57
53
  }}
58
54
  >
59
- <IconCameraMobile color="#FFFF" />
60
- </Button>
55
+ <Home
56
+ color={
57
+ history.location.pathname === '/' && !imageCaptureHelpModal
58
+ ? settings.theme?.primaryColor
59
+ : '#000'
60
+ }
61
+ />
62
+ </NavLink>
63
+ {history.location?.pathname !== '/' && (
64
+ <Box className="box-icon-camera-mobile">
65
+ <Button
66
+ onClick={() => {
67
+ setOpenModalCamera(!isOpenModalCamera);
68
+ }}
69
+ >
70
+ <IconCameraMobile color="#000" />
71
+ </Button>
72
+ </Box>
73
+ )}
74
+ {history.location?.pathname !== '/' && (
75
+ <div
76
+ style={{
77
+ width: '48px',
78
+ height: '48px',
79
+ display: 'flex',
80
+ alignItems: 'center',
81
+ justifyContent: 'center',
82
+ borderRadius: '100%',
83
+ backgroundColor: imageCaptureHelpModal
84
+ ? `${settings.theme?.primaryColor}21`
85
+ : '',
86
+ }}
87
+ onClick={() => {
88
+ dispatch(setImageCaptureHelpModal(!imageCaptureHelpModal));
89
+ }}
90
+ >
91
+ <IconInfo
92
+ fontSize={24}
93
+ width={24}
94
+ height={24}
95
+ color={
96
+ imageCaptureHelpModal ? settings.theme?.primaryColor : '#000'
97
+ }
98
+ />
99
+ </div>
100
+ )}
61
101
  </Box>
62
-
63
102
  <Box className="box-screenshot-camera">
64
103
  <CameraCustom
65
104
  isToggle={isOpenModalCamera}
@@ -68,7 +107,7 @@ function FooterMobile(props: Props): JSX.Element {
68
107
  }}
69
108
  />
70
109
  </Box>
71
- </Box>
110
+ </>
72
111
  );
73
112
  }
74
113