pb-sxp-ui 1.10.6 → 1.10.7

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 (45) hide show
  1. package/dist/index.cjs +53 -69
  2. package/dist/index.cjs.map +1 -1
  3. package/dist/index.js +53 -69
  4. package/dist/index.js.map +1 -1
  5. package/dist/index.min.cjs +4 -4
  6. package/dist/index.min.cjs.map +1 -1
  7. package/dist/index.min.js +4 -4
  8. package/dist/index.min.js.map +1 -1
  9. package/dist/pb-ui.js +53 -69
  10. package/dist/pb-ui.js.map +1 -1
  11. package/dist/pb-ui.min.js +4 -4
  12. package/dist/pb-ui.min.js.map +1 -1
  13. package/es/core/components/SxpPageRender/FingerSwipeTip/index.js +1 -2
  14. package/es/core/components/SxpPageRender/FormatImage.js +7 -9
  15. package/es/core/components/SxpPageRender/LikeButton/index.js +1 -2
  16. package/es/core/components/SxpPageRender/Modal/index.js +1 -2
  17. package/es/core/components/SxpPageRender/NavBack.js +1 -2
  18. package/es/core/components/SxpPageRender/Nudge/index.js +2 -2
  19. package/es/core/components/SxpPageRender/ToggleButton/index.js +1 -2
  20. package/es/core/components/SxpPageRender/VideoWidget/index.js +1 -3
  21. package/es/core/components/SxpPageRender/index.js +9 -8
  22. package/es/core/context/EditorDataProvider.d.ts +3 -2
  23. package/es/core/context/SxpDataSourceProvider.d.ts +1 -0
  24. package/es/core/context/SxpDataSourceProvider.js +18 -3
  25. package/es/core/utils/tool.d.ts +1 -2
  26. package/es/core/utils/tool.js +1 -14
  27. package/es/materials/sxp/MultiPosts/index.js +7 -10
  28. package/es/materials/sxp/cta/AniLinkPopup/index.js +2 -2
  29. package/lib/core/components/SxpPageRender/FingerSwipeTip/index.js +1 -2
  30. package/lib/core/components/SxpPageRender/FormatImage.js +7 -9
  31. package/lib/core/components/SxpPageRender/LikeButton/index.js +1 -2
  32. package/lib/core/components/SxpPageRender/Modal/index.js +1 -2
  33. package/lib/core/components/SxpPageRender/NavBack.js +1 -2
  34. package/lib/core/components/SxpPageRender/Nudge/index.js +1 -1
  35. package/lib/core/components/SxpPageRender/ToggleButton/index.js +1 -2
  36. package/lib/core/components/SxpPageRender/VideoWidget/index.js +1 -3
  37. package/lib/core/components/SxpPageRender/index.js +9 -8
  38. package/lib/core/context/EditorDataProvider.d.ts +3 -2
  39. package/lib/core/context/SxpDataSourceProvider.d.ts +1 -0
  40. package/lib/core/context/SxpDataSourceProvider.js +18 -3
  41. package/lib/core/utils/tool.d.ts +1 -2
  42. package/lib/core/utils/tool.js +1 -15
  43. package/lib/materials/sxp/MultiPosts/index.js +7 -10
  44. package/lib/materials/sxp/cta/AniLinkPopup/index.js +1 -1
  45. package/package.json +1 -1
package/dist/pb-ui.js CHANGED
@@ -324,19 +324,6 @@
324
324
  /JAWS/i.test(userAgent) ||
325
325
  /ChromeVox/i.test(userAgent));
326
326
  }
327
- const getSpliceQueryUrl = (url) => {
328
- if (!url)
329
- return '';
330
- if ((url === null || url === void 0 ? void 0 : url.indexOf('http')) === -1)
331
- return url;
332
- let query = 'x-im-piez=on';
333
- if ((url === null || url === void 0 ? void 0 : url.indexOf('?')) !== -1) {
334
- return url + ('&' + query );
335
- }
336
- else {
337
- return url + ('?' + query );
338
- }
339
- };
340
327
 
341
328
  function unzip(b64Data) {
342
329
  const strData = atob(b64Data);
@@ -678,6 +665,7 @@
678
665
  const [videoRef, setVideoRef] = React.useState(null);
679
666
  const themeTag = React.useRef();
680
667
  const curTime = React.useRef();
668
+ const multiPostTimeRef = React.useRef();
681
669
  const [selectTag, setSelectTag] = React.useState(DEFAULT_TAG);
682
670
  const checkCommodityIndexRef = React.useRef(-1);
683
671
  const popupCurTimeRef = React.useRef(null);
@@ -1054,7 +1042,7 @@
1054
1042
  let pbType;
1055
1043
  getRecommendVideos()
1056
1044
  .then((data) => {
1057
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
1045
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
1058
1046
  if (data) {
1059
1047
  const list = getFilterRecList(data);
1060
1048
  let curData;
@@ -1097,14 +1085,27 @@
1097
1085
  setCacheRtcList(list);
1098
1086
  bffGetTagList(curData !== null && curData !== void 0 ? curData : finalPageData);
1099
1087
  if (channel) {
1088
+ const item = list === null || list === void 0 ? void 0 : list[0];
1089
+ const traceInfo = ((_k = item === null || item === void 0 ? void 0 : item.video) === null || _k === void 0 ? void 0 : _k.traceInfo) || ((_l = item === null || item === void 0 ? void 0 : item.product) === null || _l === void 0 ? void 0 : _l.traceInfo) || '';
1100
1090
  bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
1101
1091
  eventInfo: {
1102
1092
  eventSubject: 'multiPostClick',
1103
1093
  eventDescription: 'multiPostClick',
1104
- traceInfo: (_m = (_l = (_k = list === null || list === void 0 ? void 0 : list[0]) === null || _k === void 0 ? void 0 : _k.video) === null || _l === void 0 ? void 0 : _l.traceInfo) !== null && _m !== void 0 ? _m : '',
1094
+ traceInfo,
1105
1095
  branchfeed: channel
1106
1096
  }
1107
1097
  });
1098
+ bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
1099
+ eventInfo: {
1100
+ eventSubject: 'endMultiPost',
1101
+ eventDescription: 'endMultiPost',
1102
+ contentFormat: 'image',
1103
+ position: '0',
1104
+ traceInfo,
1105
+ nextStep: 'multipostClick',
1106
+ timeOnSite: Math.floor((new Date() - (multiPostTimeRef === null || multiPostTimeRef === void 0 ? void 0 : multiPostTimeRef.current)) / 1000) + ''
1107
+ }
1108
+ });
1108
1109
  }
1109
1110
  }
1110
1111
  })
@@ -1188,7 +1189,8 @@
1188
1189
  updateChannel,
1189
1190
  channel,
1190
1191
  eventTimeList,
1191
- setEventTimeList
1192
+ setEventTimeList,
1193
+ multiPostTimeRef
1192
1194
  } }, isShowConsent ? (React.createElement(Consent$4, Object.assign({}, (_e = (_d = (_c = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.consent) === null || _c === void 0 ? void 0 : _c[0]) === null || _d === void 0 ? void 0 : _d.item) === null || _e === void 0 ? void 0 : _e.props))) : (render({
1193
1195
  rtcList,
1194
1196
  mutateLike: bffMutateLike,
@@ -9793,7 +9795,7 @@
9793
9795
  * @Author: binruan@chatlabs.com
9794
9796
  * @Date: 2023-11-02 18:34:34
9795
9797
  * @LastEditors: binruan@chatlabs.com
9796
- * @LastEditTime: 2024-12-04 11:34:20
9798
+ * @LastEditTime: 2024-11-20 18:37:10
9797
9799
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\Modal\index.tsx
9798
9800
  *
9799
9801
  */
@@ -9977,7 +9979,7 @@
9977
9979
  }
9978
9980
  })), child()),
9979
9981
  React.createElement("button", { className: 'modal-icon-wrapper', role: 'button', "aria-label": 'close button', onClick: onClose, style: { top: scrollTop } },
9980
- React.createElement("img", { src: getSpliceQueryUrl((globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.popupCloseIcon) || closeIcon$1), alt: 'close button', className: 'modal-icon' }))))))), modalEleRef.current);
9982
+ React.createElement("img", { src: (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.popupCloseIcon) || closeIcon$1, alt: 'close button', className: 'modal-icon' }))))))), modalEleRef.current);
9981
9983
  };
9982
9984
  var Modal$1 = React.memo(Modal);
9983
9985
 
@@ -10050,20 +10052,19 @@
10050
10052
 
10051
10053
  const FormatImage = React.forwardRef((props, ref) => {
10052
10054
  const { src, onLoad, style, className, loading, alt = 'image' } = props;
10053
- const querySrc = src ? getSpliceQueryUrl(src) : '';
10054
- const [imgSrc, setImgSrc] = React.useState(querySrc);
10055
+ const [imgSrc, setImgSrc] = React.useState(src);
10055
10056
  const imgRef = React.useRef(null);
10056
10057
  const [visible, setVisible] = React.useState(false);
10057
10058
  React.useImperativeHandle(ref, () => ({
10058
10059
  setSrc: (v) => {
10059
10060
  if (v)
10060
- setImgSrc(getSpliceQueryUrl(v));
10061
+ setImgSrc(v);
10061
10062
  }
10062
10063
  }));
10063
10064
  React.useEffect(() => {
10064
- if (querySrc)
10065
- setImgSrc(querySrc);
10066
- }, [querySrc]);
10065
+ if (src)
10066
+ setImgSrc(src);
10067
+ }, [src]);
10067
10068
  React.useEffect(() => {
10068
10069
  const onShow = () => {
10069
10070
  if (src && !visible && imgRef.current) {
@@ -10080,8 +10081,8 @@
10080
10081
  !visible && !imgSrc && React.createElement("div", { style: { width: '100%', height: '100%', zIndex: 1, backgroundColor: '#fff' } }),
10081
10082
  (imgSrc === null || imgSrc === void 0 ? void 0 : imgSrc.includes('.avif')) ? (React.createElement("picture", null,
10082
10083
  React.createElement("source", { type: 'image/avif', srcSet: imgSrc }),
10083
- React.createElement("source", { type: 'image/webp', srcSet: `${imgSrc}&imageMogr2/format/webp` }),
10084
- React.createElement("source", { type: 'image/jpeg', srcSet: `${imgSrc}&imageMogr2/format/jpg` }),
10084
+ React.createElement("source", { type: 'image/webp', srcSet: `${imgSrc}?imageMogr2/format/webp` }),
10085
+ React.createElement("source", { type: 'image/jpeg', srcSet: `${imgSrc}?imageMogr2/format/jpg` }),
10085
10086
  React.createElement("img", { ref: imgRef, className: className, src: imgSrc, style: Object.assign({}, style), loading: loading, onLoad: (e) => {
10086
10087
  setVisible(true);
10087
10088
  onLoad === null || onLoad === void 0 ? void 0 : onLoad(e.target);
@@ -16316,7 +16317,7 @@ Made in Italy` })));
16316
16317
  paddingLeft: '6px'
16317
16318
  } }, "Cta Title")) : (React.createElement("div", Object.assign({}, props, { className: `${css.css(Object.assign(Object.assign({}, style), { '--transY': `translateY(calc(100% + ${(_r = style === null || style === void 0 ? void 0 : style.margin) !== null && _r !== void 0 ? _r : 0}px))` }))} ${styles['aniLinkPopup']} ${aniNamStyle} ${css.css(aniTimStyle)}`, onClick: handleTo }),
16318
16319
  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 } },
16319
- React.createElement("img", { src: getSpliceQueryUrl((globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.popupCloseIcon) || closeIcon), alt: 'close', className: styles['modal-icon-wrapper-img'] })),
16320
+ React.createElement("img", { src: (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.popupCloseIcon) || closeIcon, alt: 'close', className: styles['modal-icon-wrapper-img'] })),
16320
16321
  React.createElement(Img$1, { src: src, rec: recData, item: (_x = (_v = (_u = (_t = recData === null || recData === void 0 ? void 0 : recData.video) === null || _t === void 0 ? void 0 : _t.bindProducts) === null || _u === void 0 ? void 0 : _u[0]) !== null && _v !== void 0 ? _v : (_w = recData === null || recData === void 0 ? void 0 : recData.video) === null || _w === void 0 ? void 0 : _w.bindProduct) !== null && _x !== void 0 ? _x : recData === null || recData === void 0 ? void 0 : recData.video, index: index, translateY: translateY, imgStyle: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img, isActive: isActive }),
16321
16322
  (!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: {
16322
16323
  __html: setFontForText((_y = product === null || product === void 0 ? void 0 : product.title) !== null && _y !== void 0 ? _y : 'Product Name', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title)
@@ -16627,7 +16628,7 @@ Made in Italy` })));
16627
16628
  * @Author: binruan@chatlabs.com
16628
16629
  * @Date: 2023-12-26 10:38:53
16629
16630
  * @LastEditors: binruan@chatlabs.com
16630
- * @LastEditTime: 2024-12-03 16:43:47
16631
+ * @LastEditTime: 2024-10-29 18:04:27
16631
16632
  * @FilePath: \pb-sxp-ui\src\core\context\EditorDataProvider.tsx
16632
16633
  *
16633
16634
  */
@@ -16882,11 +16883,10 @@ Made in Italy` })));
16882
16883
  const MultiPosts$1 = (_a) => {
16883
16884
  var _b, _c;
16884
16885
  var { bgImgUrl, style, recData } = _a, props = __rest(_a, ["bgImgUrl", "style", "recData"]);
16885
- const { bffEventReport, curTime, updateChannel } = useSxpDataSource();
16886
+ const { bffEventReport, curTime, updateChannel, multiPostTimeRef } = useSxpDataSource();
16886
16887
  const { isActive } = useSwiperSlide() || {};
16887
16888
  const initRef = React.useRef(false);
16888
- const viewTime = React.useRef();
16889
- const traceInfo = (_c = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.traceInfo) !== null && _c !== void 0 ? _c : '';
16889
+ const traceInfo = ((_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.traceInfo) || ((_c = recData === null || recData === void 0 ? void 0 : recData.product) === null || _c === void 0 ? void 0 : _c.traceInfo) || '';
16890
16890
  const getPropsVal = React.useCallback((index, str) => {
16891
16891
  try {
16892
16892
  return new Function('props', 'str', `if (str) {
@@ -16903,7 +16903,6 @@ Made in Italy` })));
16903
16903
  if (!value)
16904
16904
  return;
16905
16905
  if ((v === null || v === void 0 ? void 0 : v.linkType) === 'recommendFlow') {
16906
- endMultiPost('multipostClick');
16907
16906
  updateChannel === null || updateChannel === void 0 ? void 0 : updateChannel(value);
16908
16907
  curTime.current = new Date();
16909
16908
  }
@@ -16912,12 +16911,12 @@ Made in Italy` })));
16912
16911
  }
16913
16912
  }, [props]);
16914
16913
  const startMultiPost = React.useCallback(() => {
16915
- viewTime.current = new Date();
16914
+ multiPostTimeRef.current = new Date();
16916
16915
  bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
16917
16916
  eventInfo: {
16918
16917
  eventSubject: 'startMultiPost',
16919
16918
  eventDescription: 'startMultiPost',
16920
- contentFormat: 'IMAGE',
16919
+ contentFormat: 'image',
16921
16920
  position: '0',
16922
16921
  traceInfo
16923
16922
  }
@@ -16929,11 +16928,11 @@ Made in Italy` })));
16929
16928
  eventInfo: {
16930
16929
  eventSubject: 'endMultiPost',
16931
16930
  eventDescription: 'endMultiPost',
16932
- contentFormat: 'IMAGE',
16931
+ contentFormat: 'image',
16933
16932
  position: '0',
16934
16933
  traceInfo,
16935
16934
  nextStep: nextStep || 'others',
16936
- timeOnSite: Math.floor((new Date() - (viewTime === null || viewTime === void 0 ? void 0 : viewTime.current)) / 1000) + ''
16935
+ timeOnSite: Math.floor((new Date() - (multiPostTimeRef === null || multiPostTimeRef === void 0 ? void 0 : multiPostTimeRef.current)) / 1000) + ''
16937
16936
  }
16938
16937
  });
16939
16938
  }, []);
@@ -16960,7 +16959,7 @@ Made in Italy` })));
16960
16959
  }, [isActive]);
16961
16960
  return (React.createElement("div", { className: 'multiposts', style: Object.assign(Object.assign({}, style), getBgStyle(bgImgUrl)) }, Array.from({ length: 4 }, (_, index) => {
16962
16961
  return (React.createElement("button", { hidden: !getPropsVal(index, 'Url'), className: 'multiposts-btn', role: 'button', "aria-label": `multiposts-${index + 1}`, onClick: () => handleClick(index) },
16963
- React.createElement("img", { className: 'multiposts-btn-img', src: getSpliceQueryUrl(getPropsVal(index, 'Url')), alt: `multiposts-img-${index + 1}` })));
16962
+ React.createElement("img", { className: 'multiposts-btn-img', src: getPropsVal(index, 'Url'), alt: `multiposts-img-${index + 1}` })));
16964
16963
  })));
16965
16964
  };
16966
16965
  var MultiPosts$2 = React.memo(MultiPosts$1);
@@ -17147,7 +17146,7 @@ Made in Italy` })));
17147
17146
  }
17148
17147
  }), 200);
17149
17148
  return (React.createElement("button", Object.assign({}, props, { "aria-label": 'like', onClick: handleClick }),
17150
- React.createElement("img", { style: { width: '100%', height: '100%', objectFit: 'contain' }, src: getSpliceQueryUrl(state ? activeIcon || likeIcon : unActicveIcon || unlikeIcon), alt: 'icon' })));
17149
+ React.createElement("img", { style: { width: '100%', height: '100%', objectFit: 'contain' }, src: state ? activeIcon || likeIcon : unActicveIcon || unlikeIcon, alt: 'icon' })));
17151
17150
  };
17152
17151
  var LikeButton$1 = React.memo(LikeButton);
17153
17152
 
@@ -17361,10 +17360,9 @@ Made in Italy` })));
17361
17360
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
17362
17361
  if (!isActive)
17363
17362
  return;
17364
- let videoSrc = rec === null || rec === void 0 ? void 0 : rec.video.url;
17363
+ const videoSrc = rec === null || rec === void 0 ? void 0 : rec.video.url;
17365
17364
  if (!videoSrc)
17366
17365
  return;
17367
- videoSrc = getSpliceQueryUrl(videoSrc);
17368
17366
  const videoPlayerWrapperNode = document.querySelector(`#${videoId}`);
17369
17367
  if (!videoPlayerWrapperNode)
17370
17368
  return;
@@ -17548,7 +17546,7 @@ Made in Italy` })));
17548
17546
  setIsTure(defaultValue);
17549
17547
  }, [defaultValue]);
17550
17548
  return (React.createElement("button", { style: style, "aria-label": 'toggle button', className: 'pb-toggle-button', onClick: handleClick },
17551
- React.createElement("img", { className: 'pb-toggle-button-icon', alt: 'toggle image', src: getSpliceQueryUrl(isTrue ? activeIcon : unactiveIcon) })));
17549
+ React.createElement("img", { className: 'pb-toggle-button-icon', alt: 'toggle image', src: isTrue ? activeIcon : unactiveIcon })));
17552
17550
  };
17553
17551
  var ToggleButton$1 = React.memo(ToggleButton);
17554
17552
 
@@ -17556,7 +17554,7 @@ Made in Italy` })));
17556
17554
  * @Author: binruan@chatlabs.com
17557
17555
  * @Date: 2024-01-15 19:03:09
17558
17556
  * @LastEditors: binruan@chatlabs.com
17559
- * @LastEditTime: 2024-12-04 11:24:16
17557
+ * @LastEditTime: 2024-07-11 18:19:29
17560
17558
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\FingerSwipeTip\index.tsx
17561
17559
  *
17562
17560
  */
@@ -17573,7 +17571,7 @@ Made in Italy` })));
17573
17571
  return show ? 'pb-fadeIn' : 'pb-fadeOut';
17574
17572
  }, [show]);
17575
17573
  return (React.createElement("div", { hidden: !show, className: `pb-finger-wrap ${animationCls}`, style: Object.assign(Object.assign({}, style), { animationDuration: `${duration / 1000}s` }) },
17576
- React.createElement("img", { src: getSpliceQueryUrl(imageUrl || FINGER_SWIPE_ICON), alt: 'finger swiper' })));
17574
+ React.createElement("img", { src: imageUrl || FINGER_SWIPE_ICON, alt: 'finger swiper' })));
17577
17575
  };
17578
17576
 
17579
17577
  /*
@@ -17880,7 +17878,7 @@ Made in Italy` })));
17880
17878
  * @Author: binruan@chatlabs.com
17881
17879
  * @Date: 2024-03-26 10:07:41
17882
17880
  * @LastEditors: binruan@chatlabs.com
17883
- * @LastEditTime: 2024-12-04 11:29:23
17881
+ * @LastEditTime: 2024-07-03 10:07:29
17884
17882
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\Nudge\index.tsx
17885
17883
  *
17886
17884
  */
@@ -17893,7 +17891,7 @@ Made in Italy` })));
17893
17891
  backgroundColor: nudge === null || nudge === void 0 ? void 0 : nudge.backgroundColor,
17894
17892
  borderRadius: (_f = nudge === null || nudge === void 0 ? void 0 : nudge.borderRadius) !== null && _f !== void 0 ? _f : 4
17895
17893
  } },
17896
- (nudge === null || nudge === void 0 ? void 0 : nudge.icon) ? (React.createElement("img", { src: getSpliceQueryUrl(nudge.icon), alt: 'nudge icon', style: { height: '100%', objectFit: 'cover', flexShrink: 0 } })) : null,
17894
+ (nudge === null || nudge === void 0 ? void 0 : nudge.icon) ? (React.createElement("img", { src: nudge.icon, alt: 'nudge icon', style: { height: '100%', objectFit: 'cover', flexShrink: 0 } })) : null,
17897
17895
  React.createElement("p", { style: Object.assign(Object.assign({}, nudge === null || nudge === void 0 ? void 0 : nudge.textStyle), { textWrap: 'nowrap', textOverflow: 'ellipsis', overflow: 'hidden', whiteSpace: 'nowrap', flex: 1, marginBottom: 0, marginTop: 0 }), dangerouslySetInnerHTML: {
17898
17896
  __html: setFontForText(nudge === null || nudge === void 0 ? void 0 : nudge.content, nudge === null || nudge === void 0 ? void 0 : nudge.textStyle)
17899
17897
  } })))));
@@ -17986,26 +17984,10 @@ Made in Italy` })));
17986
17984
  padding: 0,
17987
17985
  background: 'transparent'
17988
17986
  }, role: 'button', "aria-label": 'back button', onClick: onClick },
17989
- React.createElement("img", { src: getSpliceQueryUrl((data === null || data === void 0 ? void 0 : data.icon) || img), alt: 'back button', width: 100, style: { objectFit: 'cover' } })));
17987
+ React.createElement("img", { src: (data === null || data === void 0 ? void 0 : data.icon) || img, alt: 'back button', width: 100, style: { objectFit: 'cover' } })));
17990
17988
  };
17991
17989
  var NavBack$1 = React.memo(NavBack);
17992
17990
 
17993
- /*
17994
- * @Author: binruan@chatlabs.com
17995
- * @Date: 2024-03-20 10:27:31
17996
- * @LastEditors: binruan@chatlabs.com
17997
- * @LastEditTime: 2024-12-04 16:13:02
17998
- * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\index.tsx
17999
- *
18000
- */
18001
- /*
18002
- * @Author: binruan@chatlabs.com
18003
- * @Date: 2024-03-20 10:27:31
18004
- * @LastEditors: binruan@chatlabs.com
18005
- * @LastEditTime: 2024-12-03 15:27:20
18006
- * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\index.tsx
18007
- *
18008
- */
18009
17991
  const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.innerHeight, containerWidth = window.innerWidth, tempMap, resolver, data = [], ctaType, tipText, nudge, _schema, hashTagStyle, hashTagRightMargin, tagList = [], licenseUrl }) => {
18010
17992
  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;
18011
17993
  const mutedIcon = useIconLink('/pb_static/5beaaa5ce7f3477b99db3838619cc471.png');
@@ -18094,7 +18076,7 @@ Made in Italy` })));
18094
18076
  else if (item === null || item === void 0 ? void 0 : item.product) {
18095
18077
  fromKName = 'productPage';
18096
18078
  }
18097
- if ((globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.playbook) !== 'organic menu' || activeIndex !== 0) {
18079
+ if ((globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.playbook) !== 'organic menu' || activeIndex !== 0 || channel) {
18098
18080
  bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
18099
18081
  eventInfo: {
18100
18082
  sessionDuration: Math.floor((new Date() - curTime.current) / 1000) + '',
@@ -18140,7 +18122,8 @@ Made in Italy` })));
18140
18122
  backMainFeed,
18141
18123
  openHashtag,
18142
18124
  isShowConsent,
18143
- selectTag
18125
+ selectTag,
18126
+ channel
18144
18127
  ]);
18145
18128
  const tagHeight = React.useMemo(() => {
18146
18129
  let h = 0;
@@ -18193,7 +18176,7 @@ Made in Italy` })));
18193
18176
  new Function(link)();
18194
18177
  }
18195
18178
  })),
18196
- React.createElement("img", { src: getSpliceQueryUrl(globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.logoUrl), alt: 'logo' })));
18179
+ React.createElement("img", { src: globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.logoUrl, alt: 'logo' })));
18197
18180
  }
18198
18181
  return null;
18199
18182
  }, [globalConfig, activeIndex, visList]);
@@ -18483,7 +18466,7 @@ Made in Italy` })));
18483
18466
  const renderView = React.useMemo(() => {
18484
18467
  if (loading) {
18485
18468
  return (React.createElement("div", { style: { height, width: containerWidth, display: 'flex', justifyContent: 'center', alignItems: 'center' } },
18486
- React.createElement("img", { width: 64, height: 64, src: getSpliceQueryUrl(loadingImage), alt: 'loading...', style: { objectFit: 'contain' } })));
18469
+ React.createElement("img", { width: 64, height: 64, src: loadingImage, alt: 'loading...', style: { objectFit: 'contain' } })));
18487
18470
  }
18488
18471
  return visList === null || visList === void 0 ? void 0 : visList.map((rec, index) => {
18489
18472
  return (React.createElement(SwiperSlide, { key: index, virtualIndex: index, style: { overflow: 'hidden' } }, rec && (React.createElement(React.Fragment, null, (rec === null || rec === void 0 ? void 0 : rec.loading) ? (React.createElement("div", { style: {
@@ -18493,7 +18476,7 @@ Made in Italy` })));
18493
18476
  justifyContent: 'center',
18494
18477
  alignItems: 'center'
18495
18478
  } },
18496
- React.createElement("img", { width: 64, height: 64, src: getSpliceQueryUrl(loadingImage), alt: 'loading...', style: { objectFit: 'contain' } }))) : (React.createElement(React.Fragment, null,
18479
+ React.createElement("img", { width: 64, height: 64, src: loadingImage, alt: 'loading...', style: { objectFit: 'contain' } }))) : (React.createElement(React.Fragment, null,
18497
18480
  renderBottom(rec, index),
18498
18481
  renderLikeButton(rec, index, !(globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.likeIconFixed)),
18499
18482
  renderToggleButton(!(globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.muteIconFixed)),
@@ -18526,12 +18509,13 @@ Made in Italy` })));
18526
18509
  ((_f = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.backButton) === null || _f === void 0 ? void 0 : _f.enable) && !channel && !openMultiPosts && !waterFallData && (React.createElement(NavBack$1, { data: globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.backButton, minusHeight: minusHeight, tagHeight: tagHeight, onClick: () => history === null || history === void 0 ? void 0 : history.back() })),
18527
18510
  ((((_l = (_k = (_j = (_h = (_g = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.multiPosts) === null || _g === void 0 ? void 0 : _g[0]) === null || _h === void 0 ? void 0 : _h.item) === null || _j === void 0 ? void 0 : _j.props) === null || _k === void 0 ? void 0 : _k.backButton) === null || _l === void 0 ? void 0 : _l.enable) && channel) || openMultiPosts) &&
18528
18511
  !waterFallData && (React.createElement(NavBack$1, { data: (_q = (_p = (_o = (_m = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.multiPosts) === null || _m === void 0 ? void 0 : _m[0]) === null || _o === void 0 ? void 0 : _o.item) === null || _p === void 0 ? void 0 : _p.props) === null || _q === void 0 ? void 0 : _q.backButton, minusHeight: minusHeight, tagHeight: tagHeight, onClick: () => {
18529
- var _a, _b, _c;
18512
+ var _a, _b;
18513
+ const item = visList === null || visList === void 0 ? void 0 : visList[activeIndex];
18530
18514
  bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
18531
18515
  eventInfo: {
18532
18516
  eventSubject: 'backMultiPostClick',
18533
18517
  eventDescription: 'backMultiPostClick',
18534
- traceInfo: (_c = (_b = (_a = data === null || data === void 0 ? void 0 : data[activeIndex]) === null || _a === void 0 ? void 0 : _a.video) === null || _b === void 0 ? void 0 : _b.traceInfo) !== null && _c !== void 0 ? _c : ''
18518
+ traceInfo: ((_a = item === null || item === void 0 ? void 0 : item.video) === null || _a === void 0 ? void 0 : _a.traceInfo) || ((_b = item === null || item === void 0 ? void 0 : item.product) === null || _b === void 0 ? void 0 : _b.traceInfo) || ''
18535
18519
  }
18536
18520
  });
18537
18521
  location === null || location === void 0 ? void 0 : location.reload();