pb-sxp-ui 1.2.6 → 1.2.8

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 (52) hide show
  1. package/dist/index.cjs +119 -107
  2. package/dist/index.cjs.map +1 -1
  3. package/dist/index.css +1 -3
  4. package/dist/index.js +119 -107
  5. package/dist/index.js.map +1 -1
  6. package/dist/index.min.cjs +3 -3
  7. package/dist/index.min.cjs.map +1 -1
  8. package/dist/index.min.js +3 -3
  9. package/dist/index.min.js.map +1 -1
  10. package/dist/pb-ui.js +119 -107
  11. package/dist/pb-ui.js.map +1 -1
  12. package/dist/pb-ui.min.js +3 -3
  13. package/dist/pb-ui.min.js.map +1 -1
  14. package/es/core/components/SxpPageRender/FormatImage.d.ts +1 -0
  15. package/es/core/components/SxpPageRender/FormatImage.js +23 -5
  16. package/es/core/components/SxpPageRender/Popup/index.js +5 -5
  17. package/es/core/components/SxpPageRender/VideoWidget/index.js +2 -2
  18. package/es/core/components/SxpPageRender/index.js +12 -6
  19. package/es/core/context/SxpDataSourceProvider.js +25 -15
  20. package/es/core/hooks/useEventReport.js +4 -4
  21. package/es/materials/sxp/cta/AniLink/index.js +1 -1
  22. package/es/materials/sxp/cta/AniLink/interactionRender.d.ts +0 -3
  23. package/es/materials/sxp/cta/AniLink/interactionRender.js +1 -2
  24. package/es/materials/sxp/cta/AniLink/material.js +9 -1
  25. package/es/materials/sxp/cta/AniLinkPopup/index.js +2 -2
  26. package/es/materials/sxp/cta/AniLinkPopup/interactionRender.d.ts +0 -10
  27. package/es/materials/sxp/cta/AniLinkPopup/interactionRender.js +1 -7
  28. package/es/materials/sxp/cta/AniLinkPopup/material.js +17 -10
  29. package/es/materials/sxp/popup/CommodityList/index.d.ts +0 -1
  30. package/es/materials/sxp/popup/CommodityList/index.js +2 -1
  31. package/es/materials/sxp/template/components/CommodityGroup.d.ts +1 -1
  32. package/es/materials/sxp/template/components/CommodityGroup.js +2 -1
  33. package/lib/core/components/SxpPageRender/FormatImage.d.ts +1 -0
  34. package/lib/core/components/SxpPageRender/FormatImage.js +23 -5
  35. package/lib/core/components/SxpPageRender/Popup/index.js +5 -5
  36. package/lib/core/components/SxpPageRender/VideoWidget/index.js +2 -2
  37. package/lib/core/components/SxpPageRender/index.js +12 -6
  38. package/lib/core/context/SxpDataSourceProvider.js +25 -15
  39. package/lib/core/hooks/useEventReport.js +4 -4
  40. package/lib/materials/sxp/cta/AniLink/index.js +1 -1
  41. package/lib/materials/sxp/cta/AniLink/interactionRender.d.ts +0 -3
  42. package/lib/materials/sxp/cta/AniLink/interactionRender.js +1 -2
  43. package/lib/materials/sxp/cta/AniLink/material.js +9 -1
  44. package/lib/materials/sxp/cta/AniLinkPopup/index.js +2 -2
  45. package/lib/materials/sxp/cta/AniLinkPopup/interactionRender.d.ts +0 -10
  46. package/lib/materials/sxp/cta/AniLinkPopup/interactionRender.js +1 -7
  47. package/lib/materials/sxp/cta/AniLinkPopup/material.js +17 -10
  48. package/lib/materials/sxp/popup/CommodityList/index.d.ts +0 -1
  49. package/lib/materials/sxp/popup/CommodityList/index.js +2 -1
  50. package/lib/materials/sxp/template/components/CommodityGroup.d.ts +1 -1
  51. package/lib/materials/sxp/template/components/CommodityGroup.js +2 -1
  52. package/package.json +1 -1
package/dist/pb-ui.js CHANGED
@@ -573,6 +573,19 @@
573
573
  var _a, _b, _c, _d;
574
574
  return (((_d = (_c = (_b = (_a = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.consent) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.item) === null || _c === void 0 ? void 0 : _c.props) === null || _d === void 0 ? void 0 : _d.privacy_necessity) && !isAgreePolicy && !isEditor) || isOpenConsent;
575
575
  }, [isAgreePolicy, globalConfig, isOpenConsent, isEditor]);
576
+ const getFilterRecList = React.useCallback((data) => {
577
+ var _a;
578
+ const recList = data === null || data === void 0 ? void 0 : data.recList;
579
+ const nList = (_a = recList === null || recList === void 0 ? void 0 : recList.map((item) => {
580
+ var _a, _b, _c, _d, _e, _f;
581
+ if (((_a = item === null || item === void 0 ? void 0 : item.video) === null || _a === void 0 ? void 0 : _a.bindProducts) && ((_c = (_b = item === null || item === void 0 ? void 0 : item.video) === null || _b === void 0 ? void 0 : _b.bindProducts) === null || _c === void 0 ? void 0 : _c.length) > 0) {
582
+ const bindProducts = (_f = (_e = (_d = item === null || item === void 0 ? void 0 : item.video) === null || _d === void 0 ? void 0 : _d.bindProducts) === null || _e === void 0 ? void 0 : _e.filter((item) => !!(item === null || item === void 0 ? void 0 : item.bindCta))) !== null && _f !== void 0 ? _f : [];
583
+ return Object.assign(Object.assign({}, item), { video: Object.assign(Object.assign({}, item === null || item === void 0 ? void 0 : item.video), { bindProducts }) });
584
+ }
585
+ return item;
586
+ })) !== null && _a !== void 0 ? _a : [];
587
+ return nList;
588
+ }, []);
576
589
  React.useEffect(() => {
577
590
  const handleChangeThemeTag = (tag) => {
578
591
  themeTag.current = tag;
@@ -644,7 +657,6 @@
644
657
  return result === null || result === void 0 ? void 0 : result.data;
645
658
  }), [bffFetch, utmVal, maxSize, defaultSize]);
646
659
  const loadVideos = React.useCallback(() => __awaiter(void 0, void 0, void 0, function* () {
647
- var _j, _k;
648
660
  if (rtcList.length <= 0) {
649
661
  return;
650
662
  }
@@ -654,8 +666,8 @@
654
666
  'itemFilter.itemType': waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.itemType,
655
667
  themeTag: themeTag.current
656
668
  });
657
- setRtcList(rtcList.concat((_j = data === null || data === void 0 ? void 0 : data.recList) !== null && _j !== void 0 ? _j : []));
658
- setCacheRtcList(cacheRtcList.concat((_k = data === null || data === void 0 ? void 0 : data.recList) !== null && _k !== void 0 ? _k : []));
669
+ setRtcList(rtcList.concat(getFilterRecList(data)));
670
+ setCacheRtcList(cacheRtcList.concat(getFilterRecList(data)));
659
671
  }), [getRecommendVideos, rtcList, waterFallData, cacheRtcList]);
660
672
  const bffEventReport = React.useCallback(({ userInfo, eventInfo }) => {
661
673
  // 关闭 BFF 事件上报
@@ -719,24 +731,24 @@
719
731
  }), [bffFetch]);
720
732
  // 获取 Tag
721
733
  const bffGetTagList = React.useCallback(() => __awaiter(void 0, void 0, void 0, function* () {
722
- var _l, _m, _o, _p, _q;
734
+ var _j, _k, _l, _m, _o;
723
735
  if (!utmVal || !isShowTag)
724
736
  return;
725
737
  try {
726
- const val = (_o = (_m = (_l = utmVal === null || utmVal === void 0 ? void 0 : utmVal.split('&')) === null || _l === void 0 ? void 0 : _l.filter((val) => {
738
+ const val = (_l = (_k = (_j = utmVal === null || utmVal === void 0 ? void 0 : utmVal.split('&')) === null || _j === void 0 ? void 0 : _j.filter((val) => {
727
739
  var _a, _b;
728
740
  const key = val.split('=')[0];
729
741
  return (_b = ((_a = utmParameter === null || utmParameter === void 0 ? void 0 : utmParameter.channels) !== null && _a !== void 0 ? _a : [])) === null || _b === void 0 ? void 0 : _b.includes(key);
730
- })) === null || _m === void 0 ? void 0 : _m.join('&')) !== null && _o !== void 0 ? _o : '';
742
+ })) === null || _k === void 0 ? void 0 : _k.join('&')) !== null && _l !== void 0 ? _l : '';
731
743
  const result = yield (bffFetch === null || bffFetch === void 0 ? void 0 : bffFetch('/tag/list', { method: 'GET', query: { channel: decodeURIComponent(val) } }));
732
- setTagList((_q = (_p = result === null || result === void 0 ? void 0 : result.data) === null || _p === void 0 ? void 0 : _p.tags) !== null && _q !== void 0 ? _q : []);
744
+ setTagList((_o = (_m = result === null || result === void 0 ? void 0 : result.data) === null || _m === void 0 ? void 0 : _m.tags) !== null && _o !== void 0 ? _o : []);
733
745
  }
734
746
  catch (e) {
735
747
  console.log('e', e);
736
748
  }
737
749
  }), [bffFetch, utmVal, isShowTag]);
738
750
  const ctaEvent = React.useCallback((eventInfo, rec, product, position) => {
739
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2;
751
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3;
740
752
  const cta = product === null || product === void 0 ? void 0 : product.bindCta;
741
753
  const isProd = ((_a = rec === null || rec === void 0 ? void 0 : rec.video) === null || _a === void 0 ? void 0 : _a.bindProduct) || (((_b = rec === null || rec === void 0 ? void 0 : rec.video) === null || _b === void 0 ? void 0 : _b.bindProducts) && ((_d = (_c = rec === null || rec === void 0 ? void 0 : rec.video) === null || _c === void 0 ? void 0 : _c.bindProducts) === null || _d === void 0 ? void 0 : _d.length) > 0);
742
754
  let fromKName = '';
@@ -750,7 +762,7 @@
750
762
  fromKName = 'imagePage';
751
763
  }
752
764
  bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
753
- eventInfo: Object.assign(Object.assign({}, eventInfo), { ctaId: (_h = cta === null || cta === void 0 ? void 0 : cta.itemId) !== null && _h !== void 0 ? _h : '', ctaName: (_j = cta === null || cta === void 0 ? void 0 : cta.title) !== null && _j !== void 0 ? _j : '', contentTags: JSON.stringify(cta === null || cta === void 0 ? void 0 : cta.tags), position: position + '', contentId: (_l = (_k = rec === null || rec === void 0 ? void 0 : rec.video) === null || _k === void 0 ? void 0 : _k.itemId) !== null && _l !== void 0 ? _l : '', productId: isProd ? product === null || product === void 0 ? void 0 : product.itemId : '', traceInfo: (_1 = (_y = (_t = (_p = (_o = (_m = rec === null || rec === void 0 ? void 0 : rec.video) === null || _m === void 0 ? void 0 : _m.bindCta) === null || _o === void 0 ? void 0 : _o.traceInfo) !== null && _p !== void 0 ? _p : (_s = (_r = (_q = rec === null || rec === void 0 ? void 0 : rec.video) === null || _q === void 0 ? void 0 : _q.bindProduct) === null || _r === void 0 ? void 0 : _r.bindCta) === null || _s === void 0 ? void 0 : _s.traceInfo) !== null && _t !== void 0 ? _t : (_x = (_w = (_v = (_u = rec === null || rec === void 0 ? void 0 : rec.video) === null || _u === void 0 ? void 0 : _u.bindProducts) === null || _v === void 0 ? void 0 : _v[0]) === null || _w === void 0 ? void 0 : _w.bindCta) === null || _x === void 0 ? void 0 : _x.traceInfo) !== null && _y !== void 0 ? _y : (_0 = (_z = rec === null || rec === void 0 ? void 0 : rec.product) === null || _z === void 0 ? void 0 : _z.bindCta) === null || _0 === void 0 ? void 0 : _0.traceInfo) !== null && _1 !== void 0 ? _1 : '', fromKName, fromKPage: (_2 = location === null || location === void 0 ? void 0 : location.href) !== null && _2 !== void 0 ? _2 : '' })
765
+ eventInfo: Object.assign(Object.assign({}, eventInfo), { ctaId: (_h = cta === null || cta === void 0 ? void 0 : cta.itemId) !== null && _h !== void 0 ? _h : '', ctaName: (_j = cta === null || cta === void 0 ? void 0 : cta.title) !== null && _j !== void 0 ? _j : '', contentTags: JSON.stringify(cta === null || cta === void 0 ? void 0 : cta.tags), position: position + '', contentId: (_l = (_k = rec === null || rec === void 0 ? void 0 : rec.video) === null || _k === void 0 ? void 0 : _k.itemId) !== null && _l !== void 0 ? _l : '', productId: isProd ? product === null || product === void 0 ? void 0 : product.itemId : '', traceInfo: (_2 = (_z = (_u = (_q = (_m = cta === null || cta === void 0 ? void 0 : cta.traceInfo) !== null && _m !== void 0 ? _m : (_p = (_o = rec === null || rec === void 0 ? void 0 : rec.video) === null || _o === void 0 ? void 0 : _o.bindCta) === null || _p === void 0 ? void 0 : _p.traceInfo) !== null && _q !== void 0 ? _q : (_t = (_s = (_r = rec === null || rec === void 0 ? void 0 : rec.video) === null || _r === void 0 ? void 0 : _r.bindProduct) === null || _s === void 0 ? void 0 : _s.bindCta) === null || _t === void 0 ? void 0 : _t.traceInfo) !== null && _u !== void 0 ? _u : (_y = (_x = (_w = (_v = rec === null || rec === void 0 ? void 0 : rec.video) === null || _v === void 0 ? void 0 : _v.bindProducts) === null || _w === void 0 ? void 0 : _w[0]) === null || _x === void 0 ? void 0 : _x.bindCta) === null || _y === void 0 ? void 0 : _y.traceInfo) !== null && _z !== void 0 ? _z : (_1 = (_0 = rec === null || rec === void 0 ? void 0 : rec.product) === null || _0 === void 0 ? void 0 : _0.bindCta) === null || _1 === void 0 ? void 0 : _1.traceInfo) !== null && _2 !== void 0 ? _2 : '', fromKName, fromKPage: (_3 = location === null || location === void 0 ? void 0 : location.href) !== null && _3 !== void 0 ? _3 : '' })
754
766
  });
755
767
  }, [bffEventReport, isFromHashtag]);
756
768
  const h5EnterLink = React.useCallback(() => {
@@ -790,9 +802,8 @@
790
802
  bffGetTagList();
791
803
  getRecommendVideos()
792
804
  .then((data) => {
793
- var _a, _b;
794
- setRtcList((_a = data === null || data === void 0 ? void 0 : data.recList) !== null && _a !== void 0 ? _a : []);
795
- setCacheRtcList((_b = data === null || data === void 0 ? void 0 : data.recList) !== null && _b !== void 0 ? _b : []);
805
+ setRtcList(getFilterRecList(data));
806
+ setCacheRtcList(getFilterRecList(data));
796
807
  })
797
808
  .finally(() => {
798
809
  bffEventReport({
@@ -812,9 +823,8 @@
812
823
  bffGetTagList();
813
824
  getRecommendVideos()
814
825
  .then((data) => {
815
- var _a, _b;
816
- setRtcList((_a = data === null || data === void 0 ? void 0 : data.recList) !== null && _a !== void 0 ? _a : []);
817
- setCacheRtcList((_b = data === null || data === void 0 ? void 0 : data.recList) !== null && _b !== void 0 ? _b : []);
826
+ setRtcList(getFilterRecList(data));
827
+ setCacheRtcList(getFilterRecList(data));
818
828
  })
819
829
  .finally(() => {
820
830
  setLoading(false);
@@ -1282,14 +1292,14 @@
1282
1292
  * @Author: binruan@chatlabs.com
1283
1293
  * @Date: 2024-03-12 10:59:06
1284
1294
  * @LastEditors: binruan@chatlabs.com
1285
- * @LastEditTime: 2024-07-31 11:41:47
1295
+ * @LastEditTime: 2024-08-01 17:36:34
1286
1296
  * @FilePath: \pb-sxp-ui\src\core\hooks\useEventReport.ts
1287
1297
  *
1288
1298
  */
1289
1299
  function useEventReport() {
1290
1300
  const { bffEventReport, popupDetailData, waterFallData, isFromHashtag } = useSxpDataSource();
1291
1301
  const jumpToWeb = React.useCallback((data, product, cta, position) => {
1292
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0;
1302
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1;
1293
1303
  let fromKName = '';
1294
1304
  if (popupDetailData && (((_b = (_a = data === null || data === void 0 ? void 0 : data.video) === null || _a === void 0 ? void 0 : _a.bindProducts) === null || _b === void 0 ? void 0 : _b.length) || ((_c = data === null || data === void 0 ? void 0 : data.video) === null || _c === void 0 ? void 0 : _c.bindProduct))) {
1295
1305
  fromKName = 'pdpPage';
@@ -1320,12 +1330,12 @@
1320
1330
  position: position + '',
1321
1331
  contentId: (_m = (_l = data === null || data === void 0 ? void 0 : data.video) === null || _l === void 0 ? void 0 : _l.itemId) !== null && _m !== void 0 ? _m : '',
1322
1332
  ctatId: (_o = cta === null || cta === void 0 ? void 0 : cta.itemId) !== null && _o !== void 0 ? _o : '',
1323
- traceInfo: (_0 = (_x = (_v = (_r = (_q = (_p = data === null || data === void 0 ? void 0 : data.video) === null || _p === void 0 ? void 0 : _p.bindProduct) === null || _q === void 0 ? void 0 : _q.traceInfo) !== null && _r !== void 0 ? _r : (_u = (_t = (_s = data === null || data === void 0 ? void 0 : data.video) === null || _s === void 0 ? void 0 : _s.bindProducts) === null || _t === void 0 ? void 0 : _t[0]) === null || _u === void 0 ? void 0 : _u.traceInfo) !== null && _v !== void 0 ? _v : (_w = data === null || data === void 0 ? void 0 : data.product) === null || _w === void 0 ? void 0 : _w.traceInfo) !== null && _x !== void 0 ? _x : (_z = (_y = data === null || data === void 0 ? void 0 : data.video) === null || _y === void 0 ? void 0 : _y.bindCta) === null || _z === void 0 ? void 0 : _z.traceInfo) !== null && _0 !== void 0 ? _0 : ''
1333
+ traceInfo: (_1 = (_y = (_w = (_s = (_p = product === null || product === void 0 ? void 0 : product.traceInfo) !== null && _p !== void 0 ? _p : (_r = (_q = data === null || data === void 0 ? void 0 : data.video) === null || _q === void 0 ? void 0 : _q.bindProduct) === null || _r === void 0 ? void 0 : _r.traceInfo) !== null && _s !== void 0 ? _s : (_v = (_u = (_t = data === null || data === void 0 ? void 0 : data.video) === null || _t === void 0 ? void 0 : _t.bindProducts) === null || _u === void 0 ? void 0 : _u[0]) === null || _v === void 0 ? void 0 : _v.traceInfo) !== null && _w !== void 0 ? _w : (_x = data === null || data === void 0 ? void 0 : data.product) === null || _x === void 0 ? void 0 : _x.traceInfo) !== null && _y !== void 0 ? _y : (_0 = (_z = data === null || data === void 0 ? void 0 : data.video) === null || _z === void 0 ? void 0 : _z.bindCta) === null || _0 === void 0 ? void 0 : _0.traceInfo) !== null && _1 !== void 0 ? _1 : ''
1324
1334
  }
1325
1335
  });
1326
1336
  }, [bffEventReport, popupDetailData, isFromHashtag]);
1327
1337
  const productView = React.useCallback((data, product, cta, viewTime, position) => {
1328
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
1338
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
1329
1339
  let fromKName = '';
1330
1340
  if (popupDetailData && (((_b = (_a = data === null || data === void 0 ? void 0 : data.video) === null || _a === void 0 ? void 0 : _a.bindProducts) === null || _b === void 0 ? void 0 : _b.length) || ((_c = data === null || data === void 0 ? void 0 : data.video) === null || _c === void 0 ? void 0 : _c.bindProduct))) {
1331
1341
  fromKName = 'pdpPage';
@@ -1345,7 +1355,7 @@
1345
1355
  position: position + '',
1346
1356
  contentId: (_d = data === null || data === void 0 ? void 0 : data.video) === null || _d === void 0 ? void 0 : _d.itemId,
1347
1357
  ctatId: cta === null || cta === void 0 ? void 0 : cta.itemId,
1348
- traceInfo: (_o = (_l = (_g = (_f = (_e = data === null || data === void 0 ? void 0 : data.video) === null || _e === void 0 ? void 0 : _e.bindProduct) === null || _f === void 0 ? void 0 : _f.traceInfo) !== null && _g !== void 0 ? _g : (_k = (_j = (_h = data === null || data === void 0 ? void 0 : data.video) === null || _h === void 0 ? void 0 : _h.bindProducts) === null || _j === void 0 ? void 0 : _j[0]) === null || _k === void 0 ? void 0 : _k.traceInfo) !== null && _l !== void 0 ? _l : (_m = data === null || data === void 0 ? void 0 : data.product) === null || _m === void 0 ? void 0 : _m.traceInfo) !== null && _o !== void 0 ? _o : '',
1358
+ traceInfo: (_p = (_m = (_h = (_e = product === null || product === void 0 ? void 0 : product.traceInfo) !== null && _e !== void 0 ? _e : (_g = (_f = data === null || data === void 0 ? void 0 : data.video) === null || _f === void 0 ? void 0 : _f.bindProduct) === null || _g === void 0 ? void 0 : _g.traceInfo) !== null && _h !== void 0 ? _h : (_l = (_k = (_j = data === null || data === void 0 ? void 0 : data.video) === null || _j === void 0 ? void 0 : _j.bindProducts) === null || _k === void 0 ? void 0 : _k[0]) === null || _l === void 0 ? void 0 : _l.traceInfo) !== null && _m !== void 0 ? _m : (_o = data === null || data === void 0 ? void 0 : data.product) === null || _o === void 0 ? void 0 : _o.traceInfo) !== null && _p !== void 0 ? _p : '',
1349
1359
  timeOnSite: Math.floor((new Date() - viewTime) / 1000) + '',
1350
1360
  eventSubject: 'productView',
1351
1361
  eventDescription: 'User browsed the product'
@@ -8795,17 +8805,10 @@
8795
8805
  };
8796
8806
  var ExpandableText$1 = React.memo(ExpandableText);
8797
8807
 
8798
- /*
8799
- * @Author: binruan@chatlabs.com
8800
- * @Date: 2024-03-20 10:27:31
8801
- * @LastEditors: binruan@chatlabs.com
8802
- * @LastEditTime: 2024-07-31 17:54:50
8803
- * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\FormatImage.tsx
8804
- *
8805
- */
8806
8808
  const FormatImage = React.forwardRef((props, ref) => {
8807
- const { src, onLoad, style, className, loading } = props;
8809
+ const { src, onLoad, style, className, loading, alt = 'image' } = props;
8808
8810
  const [imgSrc, setImgSrc] = React.useState();
8811
+ const imgRef = React.useRef(null);
8809
8812
  React.useImperativeHandle(ref, () => ({
8810
8813
  setSrc: (v) => {
8811
8814
  setImgSrc(v);
@@ -8814,39 +8817,32 @@
8814
8817
  React.useEffect(() => {
8815
8818
  setImgSrc(src);
8816
8819
  }, [src]);
8817
- React.useRef(null);
8818
- // useEffect(() => {
8819
- // let observer: any = null;
8820
- // const { current } = imgRef;
8821
- // if (current) {
8822
- // observer = new IntersectionObserver(
8823
- // (entries) => {
8824
- // entries.forEach((entry) => {
8825
- // if (entry.isIntersecting) {
8826
- // setImgSrc(src);
8827
- // observer.unobserve(current);
8828
- // }
8829
- // });
8830
- // },
8831
- // { threshold: 0.1 } // 触发阈值,可根据需要调整
8832
- // );
8833
- // observer.observe(current);
8834
- // }
8835
- // return () => {
8836
- // if (observer && current) {
8837
- // observer.unobserve(current);
8838
- // }
8839
- // };
8840
- // }, [src]);
8820
+ React.useEffect(() => {
8821
+ const onShow = () => {
8822
+ var _a, _b;
8823
+ if (src && ((_b = (_a = imgRef === null || imgRef === void 0 ? void 0 : imgRef.current) === null || _a === void 0 ? void 0 : _a.style) === null || _b === void 0 ? void 0 : _b.display) === 'none') {
8824
+ imgRef.current.src = '';
8825
+ imgRef.current.src = src;
8826
+ }
8827
+ };
8828
+ SXP_EVENT_BUS.on(SXP_EVENT_TYPE.PAGE_DID_SHOW, onShow);
8829
+ return () => {
8830
+ SXP_EVENT_BUS.off(SXP_EVENT_TYPE.PAGE_DID_SHOW, onShow);
8831
+ };
8832
+ }, [src]);
8841
8833
  return (React.createElement(React.Fragment, null, (imgSrc === null || imgSrc === void 0 ? void 0 : imgSrc.includes('.avif')) ? (React.createElement("picture", null,
8842
8834
  React.createElement("source", { type: 'image/avif', srcSet: imgSrc }),
8843
8835
  React.createElement("source", { type: 'image/webp', srcSet: `${imgSrc}?imageMogr2/format/webp` }),
8844
8836
  React.createElement("source", { type: 'image/jpeg', srcSet: `${imgSrc}?imageMogr2/format/jpg` }),
8845
- React.createElement("img", { className: className, src: imgSrc, style: style, loading: loading, onLoad: (e) => {
8837
+ React.createElement("img", { ref: imgRef, className: className, src: imgSrc, style: Object.assign(Object.assign({}, style), { display: 'none' }), loading: loading, onLoad: (e) => {
8838
+ if (imgRef.current)
8839
+ imgRef.current.style.display = 'block';
8846
8840
  onLoad === null || onLoad === void 0 ? void 0 : onLoad(e.target);
8847
- }, alt: 'image' }))) : (React.createElement("img", { className: className, src: imgSrc, style: style, loading: loading, onLoad: (e) => {
8841
+ }, alt: alt }))) : (React.createElement("img", { ref: imgRef, className: className, src: imgSrc, style: Object.assign(Object.assign({}, style), { display: 'none' }), loading: loading, onLoad: (e) => {
8842
+ if (imgRef.current)
8843
+ imgRef.current.style.display = 'block';
8848
8844
  onLoad === null || onLoad === void 0 ? void 0 : onLoad(e.target);
8849
- }, alt: 'image' }))));
8845
+ }, alt: alt }))));
8850
8846
  });
8851
8847
  var FormatImage$1 = React.memo(FormatImage);
8852
8848
 
@@ -8877,7 +8873,8 @@
8877
8873
  const handleClick = (item, index) => {
8878
8874
  if (check === index)
8879
8875
  return;
8880
- productView(popupDetailData, item, item === null || item === void 0 ? void 0 : item.bindCta, popupCurTimeRef.current, popupDetailData === null || popupDetailData === void 0 ? void 0 : popupDetailData.index);
8876
+ const prevItem = products === null || products === void 0 ? void 0 : products[check];
8877
+ productView(popupDetailData, prevItem, prevItem === null || prevItem === void 0 ? void 0 : prevItem.bindCta, popupCurTimeRef.current, popupDetailData === null || popupDetailData === void 0 ? void 0 : popupDetailData.index);
8881
8878
  onCLick === null || onCLick === void 0 ? void 0 : onCLick(index);
8882
8879
  };
8883
8880
  return (React.createElement(React.Fragment, null, (data === null || data === void 0 ? void 0 : data.open) && ((products && (products === null || products === void 0 ? void 0 : products.length) > 1) || !popupDetailData) && (React.createElement(Scroll$1, { enableSlideActive: true, isPadding: false, style: Object.assign(Object.assign({}, style), data === null || data === void 0 ? void 0 : data.style) }, (_a = (popupDetailData ? products : [0, 1, 2, 3])) === null || _a === void 0 ? void 0 : _a.map((item, index) => {
@@ -10198,12 +10195,13 @@ Made in Italy` })));
10198
10195
 
10199
10196
  const CommodityList$1 = (_a) => {
10200
10197
  var _b, _c;
10201
- var { style, isDefault, rec, viewTime, isPost, bottom_image, commodityStyles, buttonStyle, index, translateY = 0, commodityPicture, isExternalLink, onClick } = _a, props = __rest(_a, ["style", "isDefault", "rec", "viewTime", "isPost", "bottom_image", "commodityStyles", "buttonStyle", "index", "translateY", "commodityPicture", "isExternalLink", "onClick"]);
10198
+ var { style, isDefault, rec, viewTime, isPost, bottom_image, commodityStyles, buttonStyle, translateY = 0, commodityPicture, isExternalLink, onClick } = _a, props = __rest(_a, ["style", "isDefault", "rec", "viewTime", "isPost", "bottom_image", "commodityStyles", "buttonStyle", "translateY", "commodityPicture", "isExternalLink", "onClick"]);
10202
10199
  const { sxpParameter, popupDetailData, setPopupDetailData, ctaEvent } = useSxpDataSource();
10203
10200
  const { jumpToWeb } = useEventReport();
10204
10201
  const { popup } = useEditor();
10205
10202
  const recData = isPost ? rec : popupDetailData;
10206
10203
  const product = (_c = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindProducts) !== null && _c !== void 0 ? _c : [null, null, null, null];
10204
+ const index = popupDetailData === null || popupDetailData === void 0 ? void 0 : popupDetailData.index;
10207
10205
  const priceText = React.useCallback((product) => {
10208
10206
  var _a, _b, _c, _d, _e;
10209
10207
  if ((product === null || product === void 0 ? void 0 : product.currency) && (product === null || product === void 0 ? void 0 : product.price)) {
@@ -14057,7 +14055,7 @@ Made in Italy` })));
14057
14055
  onClick === null || onClick === void 0 ? void 0 : onClick();
14058
14056
  }
14059
14057
  };
14060
- const title = (cta === null || cta === void 0 ? void 0 : cta.enTitle) || '查看详情 >';
14058
+ const title = (cta === null || cta === void 0 ? void 0 : cta.enTitle) || '查看详情';
14061
14059
  const aniTimStyle = React.useMemo(() => {
14062
14060
  var _a, _b;
14063
14061
  const ani = event === null || event === void 0 ? void 0 : event.animation;
@@ -14104,7 +14102,7 @@ Made in Italy` })));
14104
14102
  * @Author: binruan@chatlabs.com
14105
14103
  * @Date: 2024-07-05 14:08:41
14106
14104
  * @LastEditors: binruan@chatlabs.com
14107
- * @LastEditTime: 2024-07-09 14:34:49
14105
+ * @LastEditTime: 2024-08-02 16:22:39
14108
14106
  * @FilePath: \pb-sxp-ui\src\materials\sxp\cta\AniLink\interactionRender.tsx
14109
14107
  *
14110
14108
  */
@@ -14132,11 +14130,10 @@ Made in Italy` })));
14132
14130
  label: '动画',
14133
14131
  options: [
14134
14132
  {
14135
- label: '由左向右/中间扩散',
14133
+ label: '默认',
14136
14134
  value: 1
14137
14135
  }
14138
14136
  ],
14139
- initialValue: 1,
14140
14137
  fieldProps: {
14141
14138
  style: {
14142
14139
  width: '100%'
@@ -14163,7 +14160,7 @@ Made in Italy` })));
14163
14160
  * @Author: binruan@chatlabs.com
14164
14161
  * @Date: 2023-07-28 18:29:57
14165
14162
  * @LastEditors: binruan@chatlabs.com
14166
- * @LastEditTime: 2024-07-05 19:27:54
14163
+ * @LastEditTime: 2024-08-02 17:03:34
14167
14164
  * @FilePath: \pb-sxp-ui\src\materials\sxp\cta\AniLink\material.tsx
14168
14165
  *
14169
14166
  */
@@ -14183,7 +14180,15 @@ Made in Italy` })));
14183
14180
  ctaTitle: {
14184
14181
  fontSize: 15,
14185
14182
  color: '#fff',
14186
- textAlign: 'left'
14183
+ textAlign: 'center'
14184
+ }
14185
+ },
14186
+ event: {
14187
+ animation: {
14188
+ backgroundColor: '#F40082',
14189
+ name: 1,
14190
+ delay: 1000,
14191
+ duration: 2000
14187
14192
  }
14188
14193
  }
14189
14194
  },
@@ -14490,7 +14495,7 @@ Made in Italy` })));
14490
14495
  onClick === null || onClick === void 0 ? void 0 : onClick();
14491
14496
  }
14492
14497
  };
14493
- const title = (cta === null || cta === void 0 ? void 0 : cta.enTitle) || '查看详情 >';
14498
+ const title = (cta === null || cta === void 0 ? void 0 : cta.enTitle) || '查看详情';
14494
14499
  const aniTimStyle = React.useMemo(() => {
14495
14500
  const ani = event === null || event === void 0 ? void 0 : event.animation;
14496
14501
  if (ani) {
@@ -14522,7 +14527,7 @@ Made in Italy` })));
14522
14527
  React.createElement("div", { onClick: onClose, className: styles['modal-icon-wrapper'], style: { padding: (_s = style === null || style === void 0 ? void 0 : style['padding']) !== null && _s !== void 0 ? _s : 0 } },
14523
14528
  React.createElement("img", { src: (_t = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.popupCloseIcon) !== null && _t !== void 0 ? _t : closeIcon, alt: 'close', className: styles['modal-icon-wrapper-img'] })),
14524
14529
  React.createElement(Img$1, { src: src, rec: recData, item: (_y = (_w = (_v = (_u = recData === null || recData === void 0 ? void 0 : recData.video) === null || _u === void 0 ? void 0 : _u.bindProducts) === null || _v === void 0 ? void 0 : _v[0]) !== null && _w !== void 0 ? _w : (_x = recData === null || recData === void 0 ? void 0 : recData.video) === null || _x === void 0 ? void 0 : _x.bindProduct) !== null && _y !== void 0 ? _y : recData === null || recData === void 0 ? void 0 : recData.video, index: index, translateY: translateY, imgStyle: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img }),
14525
- (!recData || (product === null || product === void 0 ? void 0 : product.title)) && (React.createElement("div", { className: styles['two-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
14530
+ (!recData || (product === null || product === void 0 ? void 0 : product.title)) && (React.createElement("div", { className: styles['one-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
14526
14531
  __html: setFontForText((_z = product === null || product === void 0 ? void 0 : product.title) !== null && _z !== void 0 ? _z : 'Product Name', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title)
14527
14532
  } })),
14528
14533
  React.createElement("div", { className: styles['one-line-ellipsis'], style: Object.assign(Object.assign({}, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle), { lineHeight: ((_0 = ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle) === null || _0 === void 0 ? void 0 : _0.height) + 'px' }), dangerouslySetInnerHTML: {
@@ -14531,14 +14536,6 @@ Made in Italy` })));
14531
14536
  };
14532
14537
  var AniLinkPopupComponent = React.memo(AniLinkPopup$1);
14533
14538
 
14534
- /*
14535
- * @Author: binruan@chatlabs.com
14536
- * @Date: 2024-07-04 15:28:39
14537
- * @LastEditors: binruan@chatlabs.com
14538
- * @LastEditTime: 2024-07-05 17:46:42
14539
- * @FilePath: \pb-sxp-ui\src\materials\sxp\cta\AniLinkPopup\interactionRender.tsx
14540
- *
14541
- */
14542
14539
  var interactionRender = [
14543
14540
  {
14544
14541
  title: '点击事件',
@@ -14552,22 +14549,16 @@ Made in Italy` })));
14552
14549
  {
14553
14550
  title: '动画效果',
14554
14551
  child: [
14555
- {
14556
- type: 'Color',
14557
- name: ['animation', 'backgroundColor'],
14558
- label: '动画颜色'
14559
- },
14560
14552
  {
14561
14553
  type: 'Select',
14562
14554
  name: ['animation', 'name'],
14563
14555
  label: '动画',
14564
14556
  options: [
14565
14557
  {
14566
- label: '由左向右/中间扩散',
14558
+ label: '默认',
14567
14559
  value: 1
14568
14560
  }
14569
14561
  ],
14570
- initialValue: 1,
14571
14562
  fieldProps: {
14572
14563
  style: {
14573
14564
  width: '100%'
@@ -14590,11 +14581,19 @@ Made in Italy` })));
14590
14581
  }
14591
14582
  ];
14592
14583
 
14584
+ /*
14585
+ * @Author: binruan@chatlabs.com
14586
+ * @Date: 2024-07-24 14:58:40
14587
+ * @LastEditors: binruan@chatlabs.com
14588
+ * @LastEditTime: 2024-08-02 17:09:37
14589
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\cta\AniLinkPopup\material.tsx
14590
+ *
14591
+ */
14593
14592
  /*
14594
14593
  * @Author: binruan@chatlabs.com
14595
14594
  * @Date: 2023-07-28 18:29:57
14596
14595
  * @LastEditors: binruan@chatlabs.com
14597
- * @LastEditTime: 2024-07-08 14:36:05
14596
+ * @LastEditTime: 2024-08-02 17:09:14
14598
14597
  * @FilePath: \pb-sxp-ui\src\materials\sxp\cta\AniLinkPopup\material.tsx
14599
14598
  *
14600
14599
  */
@@ -14613,32 +14612,39 @@ Made in Italy` })));
14613
14612
  ctaTempStyles: {
14614
14613
  img: {
14615
14614
  borderRadius: 3,
14616
- width: 76,
14617
- height: 76,
14618
- marginBottom: 10
14615
+ width: 108,
14616
+ height: 108,
14617
+ marginBottom: 0
14619
14618
  },
14620
14619
  title: {
14621
- fontSize: 12,
14620
+ fontSize: 14,
14622
14621
  color: '#000',
14623
14622
  textAlign: 'left'
14624
14623
  },
14625
14624
  ctaTitle: {
14626
- fontSize: 10,
14625
+ width: 108,
14626
+ height: 22,
14627
+ fontSize: 12,
14627
14628
  color: '#fff',
14628
14629
  textAlign: 'center',
14629
- width: 76,
14630
- height: 20,
14631
14630
  backgroundColor: 'rgba(0,0,0,1)'
14632
14631
  }
14632
+ },
14633
+ event: {
14634
+ animation: {
14635
+ name: 1,
14636
+ delay: 1000,
14637
+ duration: 2000
14638
+ }
14633
14639
  }
14634
14640
  },
14635
14641
  style: {
14636
- width: 90,
14637
- height: 160,
14642
+ width: 120,
14643
+ height: 185,
14638
14644
  borderRadius: 3,
14639
14645
  backgroundColor: 'rgba(255,255,255,1)',
14640
14646
  padding: 7,
14641
- margin: 10
14647
+ margin: 15
14642
14648
  }
14643
14649
  },
14644
14650
  w: 100,
@@ -15112,7 +15118,7 @@ Made in Italy` })));
15112
15118
  } },
15113
15119
  React.createElement("div", { style: { position: 'relative', width: '100%', height: '100%' } },
15114
15120
  React.createElement("div", { className: 'n-full-screen', ref: videoEleRef, id: videoId, style: { width: '100%', height: '100%' } }),
15115
- React.createElement("img", { hidden: !isPauseVideo, className: 'clc-pb-video-pause', alt: 'pause', src: videoPlayIcon !== null && videoPlayIcon !== void 0 ? videoPlayIcon : PAUSE_ICON }))),
15121
+ isPauseVideo && (React.createElement(FormatImage$1, { className: 'clc-pb-video-pause', src: videoPlayIcon !== null && videoPlayIcon !== void 0 ? videoPlayIcon : PAUSE_ICON, alt: 'pause' })))),
15116
15122
  renderPoster,
15117
15123
  renderLoading)) : (React.createElement("div", { className: 'video-container', key: rec === null || rec === void 0 ? void 0 : rec.video.itemId, style: {
15118
15124
  position: 'relative',
@@ -15123,7 +15129,7 @@ Made in Italy` })));
15123
15129
  React.createElement("div", { className: 'n-full-screen', ref: videoEleRef, id: videoId, style: { width: '100%', height: '100%' } }),
15124
15130
  renderPoster,
15125
15131
  renderLoading,
15126
- React.createElement("img", { hidden: !isPauseVideo, className: 'clc-pb-video-pause', src: videoPlayIcon !== null && videoPlayIcon !== void 0 ? videoPlayIcon : PAUSE_ICON, alt: 'pause' })))));
15132
+ isPauseVideo && React.createElement(FormatImage$1, { className: 'clc-pb-video-pause', src: videoPlayIcon !== null && videoPlayIcon !== void 0 ? videoPlayIcon : PAUSE_ICON, alt: 'pause' })))));
15127
15133
  };
15128
15134
  var VideoWidget$3 = React.memo(VideoWidget$2);
15129
15135
 
@@ -15521,7 +15527,7 @@ Made in Italy` })));
15521
15527
  * @Author: binruan@chatlabs.com
15522
15528
  * @Date: 2024-01-15 19:03:09
15523
15529
  * @LastEditors: binruan@chatlabs.com
15524
- * @LastEditTime: 2024-07-31 11:33:42
15530
+ * @LastEditTime: 2024-08-02 10:50:56
15525
15531
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\index.tsx
15526
15532
  *
15527
15533
  */
@@ -15534,6 +15540,8 @@ Made in Italy` })));
15534
15540
  const viewTime = React.useRef();
15535
15541
  const [isLoadMore, setIsLoadMore] = React.useState(false);
15536
15542
  const [isShowMore, setIsShowMore] = React.useState(false);
15543
+ const [isReload, setIsReload] = React.useState(false);
15544
+ const skipLinkRef = React.useRef(false);
15537
15545
  const { loadVideos, bffEventReport, loading, setPopupDetailData, ctaEvent, swiperRef, waterFallData, setOpenHashtag, appDomain, openHashtag, loadingImage, isFromHashtag, popupDetailData, bffFbReport, curTime, h5EnterLink, isShowConsent, selectTag, isPreview } = useSxpDataSource();
15538
15546
  const { backMainFeed } = useEventReport();
15539
15547
  const { productView } = useEventReport();
@@ -15582,7 +15590,7 @@ Made in Italy` })));
15582
15590
  React.useEffect(() => {
15583
15591
  const item = data === null || data === void 0 ? void 0 : data[activeIndex];
15584
15592
  const visibleChange = () => {
15585
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
15593
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v;
15586
15594
  const repCond = !openHashtag && !isShowConsent;
15587
15595
  if (document.visibilityState === 'hidden') {
15588
15596
  // 当用户导航到新页面、切换标签页、关闭标签页、最小化或关闭浏览器、刷新原页面(即离开原页面时),或者在移动设备上从浏览器切换到不同的应用程序时
@@ -15622,11 +15630,14 @@ Made in Italy` })));
15622
15630
  fromKName,
15623
15631
  fromKPage: location === null || location === void 0 ? void 0 : location.href,
15624
15632
  ctatId: (_r = (_q = (_p = item === null || item === void 0 ? void 0 : item.video) === null || _p === void 0 ? void 0 : _p.bindCta) === null || _q === void 0 ? void 0 : _q.itemId) !== null && _r !== void 0 ? _r : '',
15625
- traceInfo: (_t = (_s = item === null || item === void 0 ? void 0 : item.video) === null || _s === void 0 ? void 0 : _s.traceInfo) !== null && _t !== void 0 ? _t : ''
15633
+ traceInfo: (_v = (_t = (_s = item === null || item === void 0 ? void 0 : item.video) === null || _s === void 0 ? void 0 : _s.traceInfo) !== null && _t !== void 0 ? _t : (_u = item === null || item === void 0 ? void 0 : item.product) === null || _u === void 0 ? void 0 : _u.traceInfo) !== null && _v !== void 0 ? _v : ''
15626
15634
  }
15627
15635
  });
15628
15636
  }
15629
15637
  else if (document.visibilityState === 'visible') {
15638
+ if (skipLinkRef.current === true) {
15639
+ setIsReload(true);
15640
+ }
15630
15641
  // 页面可见时触发,注意页面初始化时不会触发
15631
15642
  handleH5EnterLink();
15632
15643
  if (repCond) {
@@ -15667,7 +15678,7 @@ Made in Italy` })));
15667
15678
  const minusHeight = React.useMemo(() => {
15668
15679
  let minusHeight = 0;
15669
15680
  if ((globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.logoUrl) && (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.isShowLogo)) {
15670
- minusHeight += 45;
15681
+ minusHeight += 56;
15671
15682
  }
15672
15683
  return minusHeight;
15673
15684
  }, []);
@@ -15793,7 +15804,7 @@ Made in Italy` })));
15793
15804
  }
15794
15805
  };
15795
15806
  const handleSlideSkip = (item, position) => {
15796
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s;
15807
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u;
15797
15808
  if (isPreview || waterFallData)
15798
15809
  return;
15799
15810
  const t = new Date() - curTime.current;
@@ -15812,10 +15823,11 @@ Made in Italy` })));
15812
15823
  contentTags: (product === null || product === void 0 ? void 0 : product.tags) ? JSON.stringify(product === null || product === void 0 ? void 0 : product.tags) : '',
15813
15824
  position: position + '',
15814
15825
  contentId: (_q = (_p = item === null || item === void 0 ? void 0 : item.video) === null || _p === void 0 ? void 0 : _p.itemId) !== null && _q !== void 0 ? _q : '',
15815
- traceInfo: (_s = (_r = item === null || item === void 0 ? void 0 : item.video) === null || _r === void 0 ? void 0 : _r.traceInfo) !== null && _s !== void 0 ? _s : ''
15826
+ traceInfo: (_u = (_s = (_r = item === null || item === void 0 ? void 0 : item.video) === null || _r === void 0 ? void 0 : _r.traceInfo) !== null && _s !== void 0 ? _s : (_t = item === null || item === void 0 ? void 0 : item.product) === null || _t === void 0 ? void 0 : _t.traceInfo) !== null && _u !== void 0 ? _u : ''
15816
15827
  }
15817
15828
  });
15818
15829
  setSlideSkipState();
15830
+ skipLinkRef.current = true;
15819
15831
  window.location.href = window.getJointUtmLink(link);
15820
15832
  }
15821
15833
  }
@@ -15932,7 +15944,7 @@ Made in Italy` })));
15932
15944
  renderBottom(rec, index),
15933
15945
  renderLikeButton(rec, index)))))));
15934
15946
  });
15935
- }, [containerWidth, data, height, loading, renderBottom, renderContent, visList, loadingImage]);
15947
+ }, [containerWidth, data, height, loading, renderBottom, renderContent, visList, loadingImage, isReload]);
15936
15948
  const mutedIcon = useIconLink('/pb_static/5beaaa5ce7f3477b99db3838619cc471.png');
15937
15949
  const unmutedIcon = useIconLink('/pb_static/fea8668a8a894e4aa3a86bcc775e895e.png');
15938
15950
  return (React.createElement("div", { id: 'sxp-render', className: 'clc-sxp-container' },
@@ -16343,7 +16355,7 @@ Made in Italy` })));
16343
16355
  * @Author: binruan@chatlabs.com
16344
16356
  * @Date: 2023-10-31 10:56:01
16345
16357
  * @LastEditors: binruan@chatlabs.com
16346
- * @LastEditTime: 2024-07-31 18:54:49
16358
+ * @LastEditTime: 2024-08-01 15:23:51
16347
16359
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\Popup\index.tsx
16348
16360
  *
16349
16361
  */
@@ -16369,7 +16381,7 @@ Made in Italy` })));
16369
16381
  }
16370
16382
  }, [popup]);
16371
16383
  const handleClose = () => {
16372
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
16384
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
16373
16385
  if (!popup ||
16374
16386
  (popup === null || popup === void 0 ? void 0 : popup.id) === '' ||
16375
16387
  !visible ||
@@ -16380,10 +16392,10 @@ Made in Italy` })));
16380
16392
  const value = (_d = (_c = (_b = schema === null || schema === void 0 ? void 0 : schema.sxpPageConf) === null || _b === void 0 ? void 0 : _b.globalConfig) === null || _c === void 0 ? void 0 : _c.popupList) === null || _d === void 0 ? void 0 : _d.find((item) => (item === null || item === void 0 ? void 0 : item.id) === (popup === null || popup === void 0 ? void 0 : popup.id));
16381
16393
  if (((_e = value === null || value === void 0 ? void 0 : value.item) === null || _e === void 0 ? void 0 : _e.type) === 'CommodityDetail' || ((_f = value === null || value === void 0 ? void 0 : value.item) === null || _f === void 0 ? void 0 : _f.type) === 'CommodityDetailDiroNew') {
16382
16394
  const data = popupDetailData;
16383
- let product = (_g = data === null || data === void 0 ? void 0 : data.video) === null || _g === void 0 ? void 0 : _g.bindProduct;
16384
- let cta = (_j = (_h = data === null || data === void 0 ? void 0 : data.video) === null || _h === void 0 ? void 0 : _h.bindProduct) === null || _j === void 0 ? void 0 : _j.bindCta;
16395
+ let product = (_h = (_g = data === null || data === void 0 ? void 0 : data.video) === null || _g === void 0 ? void 0 : _g.bindProduct) !== null && _h !== void 0 ? _h : (_k = (_j = data === null || data === void 0 ? void 0 : data.video) === null || _j === void 0 ? void 0 : _j.bindProducts) === null || _k === void 0 ? void 0 : _k[0];
16396
+ let cta = (_o = (_m = (_l = data === null || data === void 0 ? void 0 : data.video) === null || _l === void 0 ? void 0 : _l.bindProduct) === null || _m === void 0 ? void 0 : _m.bindCta) !== null && _o !== void 0 ? _o : (_r = (_q = (_p = data === null || data === void 0 ? void 0 : data.video) === null || _p === void 0 ? void 0 : _p.bindProducts) === null || _q === void 0 ? void 0 : _q[0]) === null || _r === void 0 ? void 0 : _r.bindCta;
16385
16397
  if ((checkCommodityIndexRef === null || checkCommodityIndexRef === void 0 ? void 0 : checkCommodityIndexRef.current) >= 0) {
16386
- const p = (_l = (_k = data === null || data === void 0 ? void 0 : data.video) === null || _k === void 0 ? void 0 : _k.bindProducts) === null || _l === void 0 ? void 0 : _l[checkCommodityIndexRef === null || checkCommodityIndexRef === void 0 ? void 0 : checkCommodityIndexRef.current];
16398
+ const p = (_t = (_s = data === null || data === void 0 ? void 0 : data.video) === null || _s === void 0 ? void 0 : _s.bindProducts) === null || _t === void 0 ? void 0 : _t[checkCommodityIndexRef === null || checkCommodityIndexRef === void 0 ? void 0 : checkCommodityIndexRef.current];
16387
16399
  if (p) {
16388
16400
  product = p;
16389
16401
  cta = p === null || p === void 0 ? void 0 : p.bindCta;
@@ -16409,7 +16421,7 @@ Made in Italy` })));
16409
16421
  const isExternalLink = ((_d = (_c = (_b = value === null || value === void 0 ? void 0 : value.item) === null || _b === void 0 ? void 0 : _b.event) === null || _c === void 0 ? void 0 : _c.onClick) === null || _d === void 0 ? void 0 : _d.linkType) === 'externalLink';
16410
16422
  const isPopup = ((_g = (_f = (_e = value === null || value === void 0 ? void 0 : value.item) === null || _e === void 0 ? void 0 : _e.event) === null || _f === void 0 ? void 0 : _f.onClick) === null || _g === void 0 ? void 0 : _g.linkType) === 'popup';
16411
16423
  const defaulSetting = (_h = t === null || t === void 0 ? void 0 : t.extend) === null || _h === void 0 ? void 0 : _h.defaulSetting;
16412
- return (React.createElement(Component, Object.assign({ key: index, style: Object.assign(Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.style), (_j = value === null || value === void 0 ? void 0 : value.item) === null || _j === void 0 ? void 0 : _j.style), { width: (_k = window.innerWidth) !== null && _k !== void 0 ? _k : '100vw', height: '100%' }), textStyle: Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.textStyle), (_l = value === null || value === void 0 ? void 0 : value.item) === null || _l === void 0 ? void 0 : _l.textStyle), bindDatas: (_o = (_m = value === null || value === void 0 ? void 0 : value.item) === null || _m === void 0 ? void 0 : _m.bindDatas) !== null && _o !== void 0 ? _o : [] }, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.props, (_p = value === null || value === void 0 ? void 0 : value.item) === null || _p === void 0 ? void 0 : _p.props, { event: ((_q = value === null || value === void 0 ? void 0 : value.item) === null || _q === void 0 ? void 0 : _q.event) || {}, schema: schema, id: value === null || value === void 0 ? void 0 : value.id, isExternalLink: isExternalLink, isPopup: isPopup, onClose: handleClose, index: index })));
16424
+ return (React.createElement(Component, Object.assign({ key: index, style: Object.assign(Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.style), (_j = value === null || value === void 0 ? void 0 : value.item) === null || _j === void 0 ? void 0 : _j.style), { width: (_k = window.innerWidth) !== null && _k !== void 0 ? _k : '100vw', height: '100%' }), textStyle: Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.textStyle), (_l = value === null || value === void 0 ? void 0 : value.item) === null || _l === void 0 ? void 0 : _l.textStyle), bindDatas: (_o = (_m = value === null || value === void 0 ? void 0 : value.item) === null || _m === void 0 ? void 0 : _m.bindDatas) !== null && _o !== void 0 ? _o : [] }, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.props, (_p = value === null || value === void 0 ? void 0 : value.item) === null || _p === void 0 ? void 0 : _p.props, { event: ((_q = value === null || value === void 0 ? void 0 : value.item) === null || _q === void 0 ? void 0 : _q.event) || {}, schema: schema, id: value === null || value === void 0 ? void 0 : value.id, isExternalLink: isExternalLink, isPopup: isPopup, onClose: handleClose })));
16413
16425
  }
16414
16426
  else {
16415
16427
  return React.createElement(React.Fragment, null);