pb-sxp-ui 1.16.11 → 1.16.12

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 (35) hide show
  1. package/dist/index.cjs +142 -182
  2. package/dist/index.cjs.map +1 -1
  3. package/dist/index.js +142 -182
  4. package/dist/index.js.map +1 -1
  5. package/dist/index.min.cjs +6 -6
  6. package/dist/index.min.cjs.map +1 -1
  7. package/dist/index.min.js +6 -6
  8. package/dist/index.min.js.map +1 -1
  9. package/dist/pb-ui.js +142 -182
  10. package/dist/pb-ui.js.map +1 -1
  11. package/dist/pb-ui.min.js +6 -6
  12. package/dist/pb-ui.min.js.map +1 -1
  13. package/es/core/components/DiyPortalPreview/VideoWidget.js +8 -10
  14. package/es/core/components/SxpPageRender/LikeButton/index.js +15 -17
  15. package/es/core/components/SxpPageRender/PictureGroup/index.d.ts +0 -5
  16. package/es/core/components/SxpPageRender/PictureGroup/index.js +13 -41
  17. package/es/core/components/SxpPageRender/VideoWidget/index.js +44 -33
  18. package/es/core/components/SxpPageRender/WaterFall/index.js +3 -4
  19. package/es/core/components/SxpPageRender/index.js +37 -53
  20. package/es/core/context/SxpDataSourceProvider.js +3 -18
  21. package/es/core/hooks/useEventReport.js +5 -6
  22. package/es/materials/sxp/popup/CommodityDetail/index.js +7 -1
  23. package/es/materials/sxp/popup/CommodityDetailDiroNew/index.js +7 -1
  24. package/lib/core/components/DiyPortalPreview/VideoWidget.js +8 -10
  25. package/lib/core/components/SxpPageRender/LikeButton/index.js +15 -17
  26. package/lib/core/components/SxpPageRender/PictureGroup/index.d.ts +0 -5
  27. package/lib/core/components/SxpPageRender/PictureGroup/index.js +12 -40
  28. package/lib/core/components/SxpPageRender/VideoWidget/index.js +44 -33
  29. package/lib/core/components/SxpPageRender/WaterFall/index.js +3 -4
  30. package/lib/core/components/SxpPageRender/index.js +37 -53
  31. package/lib/core/context/SxpDataSourceProvider.js +3 -18
  32. package/lib/core/hooks/useEventReport.js +5 -6
  33. package/lib/materials/sxp/popup/CommodityDetail/index.js +7 -1
  34. package/lib/materials/sxp/popup/CommodityDetailDiroNew/index.js +7 -1
  35. package/package.json +1 -1
package/dist/index.cjs CHANGED
@@ -644,7 +644,6 @@ const DEFAULT_TAG = 'FOR U';
644
644
  const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent = true, maxSize, defaultSize, isPreview = false, sxpParameter, appDomain, hashTagSize, loadingImage, isOpenHashTag = false, enabledMetaConversionApi = false, consentHeight, consentWidth, isOpenConsent = false, isEditor = false, utmParameter, channelQueryList, data, dataList, isDiyH5, onUpdateSchema, onUpdateChannel }) => {
645
645
  var _a, _b, _c, _d, _e;
646
646
  const [rtcList, setRtcList] = React.useState([]);
647
- const [firstRtcList, setFirstRtcList] = React.useState([]);
648
647
  const [tagList, setTagList] = React.useState([]);
649
648
  const [loading, setLoading] = React.useState(true);
650
649
  const [curReqInfo, setCurReqInfo] = React.useState({ rtc: '', requestId: '' });
@@ -815,9 +814,6 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
815
814
  if ((rtcList === null || rtcList === void 0 ? void 0 : rtcList.length) === 0) {
816
815
  setRtcList(getFilterRecList(Object.assign(Object.assign({}, result === null || result === void 0 ? void 0 : result.data), { recList: list })));
817
816
  setCacheRtcList(getFilterRecList(Object.assign(Object.assign({}, result === null || result === void 0 ? void 0 : result.data), { recList: list })));
818
- if (isDiyH5) {
819
- setFirstRtcList(getFilterRecList(Object.assign(Object.assign({}, result === null || result === void 0 ? void 0 : result.data), { recList: list })));
820
- }
821
817
  }
822
818
  const isNotNullList = (_0 = (_z = result === null || result === void 0 ? void 0 : result.data) === null || _z === void 0 ? void 0 : _z.recList) === null || _0 === void 0 ? void 0 : _0.some((item) => (item === null || item === void 0 ? void 0 : item.product) || (item === null || item === void 0 ? void 0 : item.video));
823
819
  if (isNotNullList) {
@@ -857,17 +853,12 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
857
853
  if (rtcList.length <= 0) {
858
854
  return;
859
855
  }
860
- if (isDiyH5 && (firstRtcList === null || firstRtcList === void 0 ? void 0 : firstRtcList.length) > 0) {
861
- setRtcList(rtcList.concat(firstRtcList));
862
- setCacheRtcList(cacheRtcList.concat(firstRtcList));
863
- return;
864
- }
865
856
  const lastItem = rtcList === null || rtcList === void 0 ? void 0 : rtcList[(rtcList === null || rtcList === void 0 ? void 0 : rtcList.length) - 1];
866
857
  const data = yield getRecommendVideos(Object.assign(Object.assign(Object.assign(Object.assign({ hashTag: waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.hashTag }, (((_1 = lastItem === null || lastItem === void 0 ? void 0 : lastItem.product) === null || _1 === void 0 ? void 0 : _1.itemId) && { productFilter: [(_2 = lastItem === null || lastItem === void 0 ? void 0 : lastItem.product) === null || _2 === void 0 ? void 0 : _2.itemId] })), (((_3 = lastItem === null || lastItem === void 0 ? void 0 : lastItem.video) === null || _3 === void 0 ? void 0 : _3.itemId) && { contentFilter: [(_4 = lastItem === null || lastItem === void 0 ? void 0 : lastItem.video) === null || _4 === void 0 ? void 0 : _4.itemId] })), { themeTag: themeTag.current }), ((globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.enablePreview) && !isEditor && { pageNum })));
867
858
  setRtcList(rtcList.concat(getFilterRecList(data)));
868
859
  setCacheRtcList(cacheRtcList.concat(getFilterRecList(data)));
869
860
  return data;
870
- }), [getRecommendVideos, rtcList, waterFallData, cacheRtcList, isDiyH5, firstRtcList]);
861
+ }), [getRecommendVideos, rtcList, waterFallData, cacheRtcList]);
871
862
  const refreshFeSession = React.useCallback((enableReSid, event) => {
872
863
  var _a, _b, _c, _d, _e;
873
864
  let expire = false;
@@ -1094,7 +1085,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
1094
1085
  }
1095
1086
  }), [bffFetch, utmVal]);
1096
1087
  const ctaEvent = React.useCallback((eventInfo, rec, product, position) => {
1097
- 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, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, _14;
1088
+ 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, _4, _5, _6, _7, _8, _9, _10, _11;
1098
1089
  const cta = product === null || product === void 0 ? void 0 : product.bindCta;
1099
1090
  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);
1100
1091
  let fromKName = '';
@@ -1112,7 +1103,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
1112
1103
  }
1113
1104
  const contentTags = (_p = (_m = (_h = product === null || product === void 0 ? void 0 : product.tags) !== null && _h !== void 0 ? _h : (_l = (_k = (_j = rec === null || rec === void 0 ? void 0 : rec.video) === null || _j === void 0 ? void 0 : _j.bindProducts) === null || _k === void 0 ? void 0 : _k[0]) === null || _l === void 0 ? void 0 : _l.tags) !== null && _m !== void 0 ? _m : (_o = rec === null || rec === void 0 ? void 0 : rec.video) === null || _o === void 0 ? void 0 : _o.tags) !== null && _p !== void 0 ? _p : (_q = rec === null || rec === void 0 ? void 0 : rec.product) === null || _q === void 0 ? void 0 : _q.tags;
1114
1105
  bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
1115
- eventInfo: Object.assign(Object.assign({}, eventInfo), { ctaId: (_r = cta === null || cta === void 0 ? void 0 : cta.itemId) !== null && _r !== void 0 ? _r : '', ctaName: (_s = cta === null || cta === void 0 ? void 0 : cta.title) !== null && _s !== void 0 ? _s : '', contentTags: contentTags ? JSON.stringify(contentTags) : '', position: position + '', contentId: (_u = (_t = rec === null || rec === void 0 ? void 0 : rec.video) === null || _t === void 0 ? void 0 : _t.itemId) !== null && _u !== void 0 ? _u : '', sceneId: (_x = (_w = (_v = rec === null || rec === void 0 ? void 0 : rec.video) === null || _v === void 0 ? void 0 : _v.scene) === null || _w === void 0 ? void 0 : _w.sceneId) !== null && _x !== void 0 ? _x : '', productId: isProd ? product === null || product === void 0 ? void 0 : product.itemId : '', traceInfo: (_13 = (_10 = (_5 = (_1 = (_y = cta === null || cta === void 0 ? void 0 : cta.traceInfo) !== null && _y !== void 0 ? _y : (_0 = (_z = rec === null || rec === void 0 ? void 0 : rec.video) === null || _z === void 0 ? void 0 : _z.bindCta) === null || _0 === void 0 ? void 0 : _0.traceInfo) !== null && _1 !== void 0 ? _1 : (_4 = (_3 = (_2 = rec === null || rec === void 0 ? void 0 : rec.video) === null || _2 === void 0 ? void 0 : _2.bindProduct) === null || _3 === void 0 ? void 0 : _3.bindCta) === null || _4 === void 0 ? void 0 : _4.traceInfo) !== null && _5 !== void 0 ? _5 : (_9 = (_8 = (_7 = (_6 = rec === null || rec === void 0 ? void 0 : rec.video) === null || _6 === void 0 ? void 0 : _6.bindProducts) === null || _7 === void 0 ? void 0 : _7[0]) === null || _8 === void 0 ? void 0 : _8.bindCta) === null || _9 === void 0 ? void 0 : _9.traceInfo) !== null && _10 !== void 0 ? _10 : (_12 = (_11 = rec === null || rec === void 0 ? void 0 : rec.product) === null || _11 === void 0 ? void 0 : _11.bindCta) === null || _12 === void 0 ? void 0 : _12.traceInfo) !== null && _13 !== void 0 ? _13 : '', fromKName, fromKPage: (_14 = location === null || location === void 0 ? void 0 : location.href) !== null && _14 !== void 0 ? _14 : '', contentFormat })
1106
+ eventInfo: Object.assign(Object.assign({}, eventInfo), { ctaId: (_r = cta === null || cta === void 0 ? void 0 : cta.itemId) !== null && _r !== void 0 ? _r : '', ctaName: (_s = cta === null || cta === void 0 ? void 0 : cta.title) !== null && _s !== void 0 ? _s : '', contentTags: contentTags ? JSON.stringify(contentTags) : '', position: position + '', contentId: (_u = (_t = rec === null || rec === void 0 ? void 0 : rec.video) === null || _t === void 0 ? void 0 : _t.itemId) !== null && _u !== void 0 ? _u : '', productId: isProd ? product === null || product === void 0 ? void 0 : product.itemId : '', traceInfo: (_10 = (_7 = (_2 = (_y = (_v = cta === null || cta === void 0 ? void 0 : cta.traceInfo) !== null && _v !== void 0 ? _v : (_x = (_w = rec === null || rec === void 0 ? void 0 : rec.video) === null || _w === void 0 ? void 0 : _w.bindCta) === null || _x === void 0 ? void 0 : _x.traceInfo) !== null && _y !== void 0 ? _y : (_1 = (_0 = (_z = rec === null || rec === void 0 ? void 0 : rec.video) === null || _z === void 0 ? void 0 : _z.bindProduct) === null || _0 === void 0 ? void 0 : _0.bindCta) === null || _1 === void 0 ? void 0 : _1.traceInfo) !== null && _2 !== void 0 ? _2 : (_6 = (_5 = (_4 = (_3 = rec === null || rec === void 0 ? void 0 : rec.video) === null || _3 === void 0 ? void 0 : _3.bindProducts) === null || _4 === void 0 ? void 0 : _4[0]) === null || _5 === void 0 ? void 0 : _5.bindCta) === null || _6 === void 0 ? void 0 : _6.traceInfo) !== null && _7 !== void 0 ? _7 : (_9 = (_8 = rec === null || rec === void 0 ? void 0 : rec.product) === null || _8 === void 0 ? void 0 : _8.bindCta) === null || _9 === void 0 ? void 0 : _9.traceInfo) !== null && _10 !== void 0 ? _10 : '', fromKName, fromKPage: (_11 = location === null || location === void 0 ? void 0 : location.href) !== null && _11 !== void 0 ? _11 : '', contentFormat })
1116
1107
  });
1117
1108
  }, [bffEventReport, isFromHashtag]);
1118
1109
  const h5EnterLink = React.useCallback(() => {
@@ -1214,9 +1205,6 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
1214
1205
  }
1215
1206
  setRtcList(list);
1216
1207
  setCacheRtcList(list);
1217
- if (isDiyH5) {
1218
- setFirstRtcList(list);
1219
- }
1220
1208
  bffGetTagList(curData !== null && curData !== void 0 ? curData : finalPageData);
1221
1209
  if (channel) {
1222
1210
  const item = list === null || list === void 0 ? void 0 : list[0];
@@ -1252,9 +1240,6 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
1252
1240
  }
1253
1241
  setRtcList(list);
1254
1242
  setCacheRtcList(list);
1255
- if (isDiyH5) {
1256
- setFirstRtcList(list);
1257
- }
1258
1243
  }
1259
1244
  })
1260
1245
  .finally(() => {
@@ -1779,14 +1764,14 @@ var settingRender$f = [
1779
1764
  * @Author: binruan@chatlabs.com
1780
1765
  * @Date: 2024-03-12 10:59:06
1781
1766
  * @LastEditors: binruan@chatlabs.com
1782
- * @LastEditTime: 2025-05-09 15:30:59
1767
+ * @LastEditTime: 2024-11-28 11:17:16
1783
1768
  * @FilePath: \pb-sxp-ui\src\core\hooks\useEventReport.ts
1784
1769
  *
1785
1770
  */
1786
1771
  function useEventReport() {
1787
1772
  const { bffEventReport, popupDetailData, isFromHashtag, eventTimeList, setEventTimeList } = useSxpDataSource();
1788
1773
  const jumpToWeb = React.useCallback((e, data, product, cta, position, traceInfo) => {
1789
- 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, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, _14, _15, _16;
1774
+ 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, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13;
1790
1775
  const i = eventTimeList === null || eventTimeList === void 0 ? void 0 : eventTimeList.findIndex((item) => item.target === (e === null || e === void 0 ? void 0 : e.target));
1791
1776
  if (i !== -1) {
1792
1777
  return;
@@ -1819,11 +1804,11 @@ function useEventReport() {
1819
1804
  contentFormat = 'image';
1820
1805
  }
1821
1806
  bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
1822
- eventInfo: Object.assign({ eventSubject: 'jumpToWeb', eventDescription: 'User jumped to website', productId: (_v = product === null || product === void 0 ? void 0 : product.itemId) !== null && _v !== void 0 ? _v : '', productName: (_w = product === null || product === void 0 ? void 0 : product.title) !== null && _w !== void 0 ? _w : '', price: (product === null || product === void 0 ? void 0 : product.price) ? (product === null || product === void 0 ? void 0 : product.price) + '' : '0', productCollection: (_x = product === null || product === void 0 ? void 0 : product.collection) !== null && _x !== void 0 ? _x : '', fromKName, fromKPage: location === null || location === void 0 ? void 0 : location.href, contentTags: contentTags ? JSON.stringify(contentTags) : '', position: position + '', contentId: (_z = (_y = data === null || data === void 0 ? void 0 : data.video) === null || _y === void 0 ? void 0 : _y.itemId) !== null && _z !== void 0 ? _z : '', sceneId: (_2 = (_1 = (_0 = data === null || data === void 0 ? void 0 : data.video) === null || _0 === void 0 ? void 0 : _0.scene) === null || _1 === void 0 ? void 0 : _1.sceneId) !== null && _2 !== void 0 ? _2 : '', ctatId: (_3 = cta === null || cta === void 0 ? void 0 : cta.itemId) !== null && _3 !== void 0 ? _3 : '', traceInfo: (_16 = (_13 = (_11 = (_7 = (_4 = traceInfo !== null && traceInfo !== void 0 ? traceInfo : product === null || product === void 0 ? void 0 : product.traceInfo) !== null && _4 !== void 0 ? _4 : (_6 = (_5 = data === null || data === void 0 ? void 0 : data.video) === null || _5 === void 0 ? void 0 : _5.bindProduct) === null || _6 === void 0 ? void 0 : _6.traceInfo) !== null && _7 !== void 0 ? _7 : (_10 = (_9 = (_8 = data === null || data === void 0 ? void 0 : data.video) === null || _8 === void 0 ? void 0 : _8.bindProducts) === null || _9 === void 0 ? void 0 : _9[0]) === null || _10 === void 0 ? void 0 : _10.traceInfo) !== null && _11 !== void 0 ? _11 : (_12 = data === null || data === void 0 ? void 0 : data.product) === null || _12 === void 0 ? void 0 : _12.traceInfo) !== null && _13 !== void 0 ? _13 : (_15 = (_14 = data === null || data === void 0 ? void 0 : data.video) === null || _14 === void 0 ? void 0 : _14.bindCta) === null || _15 === void 0 ? void 0 : _15.traceInfo) !== null && _16 !== void 0 ? _16 : '' }, (contentFormat && { contentFormat }))
1807
+ eventInfo: Object.assign({ eventSubject: 'jumpToWeb', eventDescription: 'User jumped to website', productId: (_v = product === null || product === void 0 ? void 0 : product.itemId) !== null && _v !== void 0 ? _v : '', productName: (_w = product === null || product === void 0 ? void 0 : product.title) !== null && _w !== void 0 ? _w : '', price: (product === null || product === void 0 ? void 0 : product.price) ? (product === null || product === void 0 ? void 0 : product.price) + '' : '0', productCollection: (_x = product === null || product === void 0 ? void 0 : product.collection) !== null && _x !== void 0 ? _x : '', fromKName, fromKPage: location === null || location === void 0 ? void 0 : location.href, contentTags: contentTags ? JSON.stringify(contentTags) : '', position: position + '', contentId: (_z = (_y = data === null || data === void 0 ? void 0 : data.video) === null || _y === void 0 ? void 0 : _y.itemId) !== null && _z !== void 0 ? _z : '', ctatId: (_0 = cta === null || cta === void 0 ? void 0 : cta.itemId) !== null && _0 !== void 0 ? _0 : '', traceInfo: (_13 = (_10 = (_8 = (_4 = (_1 = traceInfo !== null && traceInfo !== void 0 ? traceInfo : product === null || product === void 0 ? void 0 : product.traceInfo) !== null && _1 !== void 0 ? _1 : (_3 = (_2 = data === null || data === void 0 ? void 0 : data.video) === null || _2 === void 0 ? void 0 : _2.bindProduct) === null || _3 === void 0 ? void 0 : _3.traceInfo) !== null && _4 !== void 0 ? _4 : (_7 = (_6 = (_5 = data === null || data === void 0 ? void 0 : data.video) === null || _5 === void 0 ? void 0 : _5.bindProducts) === null || _6 === void 0 ? void 0 : _6[0]) === null || _7 === void 0 ? void 0 : _7.traceInfo) !== null && _8 !== void 0 ? _8 : (_9 = data === null || data === void 0 ? void 0 : data.product) === null || _9 === void 0 ? void 0 : _9.traceInfo) !== null && _10 !== void 0 ? _10 : (_12 = (_11 = data === null || data === void 0 ? void 0 : data.video) === null || _11 === void 0 ? void 0 : _11.bindCta) === null || _12 === void 0 ? void 0 : _12.traceInfo) !== null && _13 !== void 0 ? _13 : '' }, (contentFormat && { contentFormat }))
1823
1808
  });
1824
1809
  }, [bffEventReport, popupDetailData, isFromHashtag, eventTimeList]);
1825
1810
  const productView = React.useCallback((data, product, cta, viewTime, position) => {
1826
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s;
1811
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
1827
1812
  let fromKName = '';
1828
1813
  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))) {
1829
1814
  fromKName = 'pdpPage';
@@ -1842,9 +1827,8 @@ function useEventReport() {
1842
1827
  contentTags: JSON.stringify(product === null || product === void 0 ? void 0 : product.tags),
1843
1828
  position: position + '',
1844
1829
  contentId: (_d = data === null || data === void 0 ? void 0 : data.video) === null || _d === void 0 ? void 0 : _d.itemId,
1845
- sceneId: (_g = (_f = (_e = data === null || data === void 0 ? void 0 : data.video) === null || _e === void 0 ? void 0 : _e.scene) === null || _f === void 0 ? void 0 : _f.sceneId) !== null && _g !== void 0 ? _g : '',
1846
1830
  ctatId: cta === null || cta === void 0 ? void 0 : cta.itemId,
1847
- traceInfo: (_s = (_q = (_l = (_h = product === null || product === void 0 ? void 0 : product.traceInfo) !== null && _h !== void 0 ? _h : (_k = (_j = data === null || data === void 0 ? void 0 : data.video) === null || _j === void 0 ? void 0 : _j.bindProduct) === null || _k === void 0 ? void 0 : _k.traceInfo) !== null && _l !== void 0 ? _l : (_p = (_o = (_m = data === null || data === void 0 ? void 0 : data.video) === null || _m === void 0 ? void 0 : _m.bindProducts) === null || _o === void 0 ? void 0 : _o[0]) === null || _p === void 0 ? void 0 : _p.traceInfo) !== null && _q !== void 0 ? _q : (_r = data === null || data === void 0 ? void 0 : data.product) === null || _r === void 0 ? void 0 : _r.traceInfo) !== null && _s !== void 0 ? _s : '',
1831
+ 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 : '',
1848
1832
  timeOnSite: Math.floor((new Date() - viewTime) / 1000) + '',
1849
1833
  eventSubject: 'productView',
1850
1834
  eventDescription: 'User browsed the product'
@@ -10396,7 +10380,7 @@ const getPriceText = ({ product, enableFormattedPrice, globalConfig, isHiddenDef
10396
10380
  const CommodityDetail$1 = (_a) => {
10397
10381
  var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0;
10398
10382
  var { content, style, bgImg, onClick, schema, isDefault, bottom_image, tipText, isPost, viewTime, rec, swiper, commodityStyles, buttonStyle, index, commodityGroup, popupBg, iframeIcon, commodityImgRatio, isTel, iframeBgColor, isActive = true } = _a, props = __rest(_a, ["content", "style", "bgImg", "onClick", "schema", "isDefault", "bottom_image", "tipText", "isPost", "viewTime", "rec", "swiper", "commodityStyles", "buttonStyle", "index", "commodityGroup", "popupBg", "iframeIcon", "commodityImgRatio", "isTel", "iframeBgColor", "isActive"]);
10399
- const { sxpParameter, popupDetailData, isPreview, bffFbReport, popupCurTimeRef, checkCommodityIndexRef, globalConfig } = useSxpDataSource();
10383
+ const { sxpParameter, popupDetailData, isPreview, bffFbReport, popupCurTimeRef, checkCommodityIndexRef, globalConfig, ctaEvent } = useSxpDataSource();
10400
10384
  const { jumpToWeb, productView } = useEventReport();
10401
10385
  const curTimeRef = React.useRef(null);
10402
10386
  const [showModal, setShowModal] = React.useState(false);
@@ -10422,6 +10406,12 @@ const CommodityDetail$1 = (_a) => {
10422
10406
  if (!isPost) {
10423
10407
  productView(data, product, cta, viewTime || curTimeRef.current, position);
10424
10408
  }
10409
+ else {
10410
+ ctaEvent === null || ctaEvent === void 0 ? void 0 : ctaEvent({
10411
+ eventSubject: 'clickCta',
10412
+ eventDescription: 'User clicked the CTA'
10413
+ }, data, product, position);
10414
+ }
10425
10415
  window.location.href = window.getJointUtmLink(product.link);
10426
10416
  }
10427
10417
  };
@@ -11324,7 +11314,7 @@ const CommodityDetailDiroNew$1 = (_a) => {
11324
11314
  var _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, _4;
11325
11315
  var { style, isDefault, rec, viewTime, isPost, bottom_image, tipText, swiper, commodityStyles, buttonStyle, index, commodityGroup, popupBg, iframeIcon, commodityImgRatio, isTel, iframeBgColor, isActive = true } = _a, props = __rest(_a, ["style", "isDefault", "rec", "viewTime", "isPost", "bottom_image", "tipText", "swiper", "commodityStyles", "buttonStyle", "index", "commodityGroup", "popupBg", "iframeIcon", "commodityImgRatio", "isTel", "iframeBgColor", "isActive"]);
11326
11316
  React.useState(true);
11327
- const { sxpParameter, popupCurTimeRef, popupDetailData, isPreview, bffFbReport, checkCommodityIndexRef, globalConfig } = useSxpDataSource();
11317
+ const { sxpParameter, popupCurTimeRef, popupDetailData, isPreview, bffFbReport, checkCommodityIndexRef, globalConfig, ctaEvent } = useSxpDataSource();
11328
11318
  const { jumpToWeb, productView } = useEventReport();
11329
11319
  React.useState(false);
11330
11320
  React.useState(false);
@@ -11353,6 +11343,12 @@ const CommodityDetailDiroNew$1 = (_a) => {
11353
11343
  if (!isPost) {
11354
11344
  productView(data, product, cta, viewTime || curTimeRef.current, position);
11355
11345
  }
11346
+ else {
11347
+ ctaEvent === null || ctaEvent === void 0 ? void 0 : ctaEvent({
11348
+ eventSubject: 'clickCta',
11349
+ eventDescription: 'User clicked the CTA'
11350
+ }, data, product, position);
11351
+ }
11356
11352
  window.location.href = window.getJointUtmLink(product.link);
11357
11353
  }
11358
11354
  };
@@ -15647,7 +15643,7 @@ function WaterfallList(_a) {
15647
15643
  * @Author: binruan@chatlabs.com
15648
15644
  * @Date: 2024-01-10 10:58:24
15649
15645
  * @LastEditors: binruan@chatlabs.com
15650
- * @LastEditTime: 2025-05-09 15:30:41
15646
+ * @LastEditTime: 2025-02-28 10:00:31
15651
15647
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\WaterFall\index.tsx
15652
15648
  *
15653
15649
  */
@@ -15685,7 +15681,7 @@ const WaterFall = (props) => {
15685
15681
  }
15686
15682
  }, [waterFallData]);
15687
15683
  const reportTagsView = React.useCallback(() => {
15688
- var _a, _b, _c, _d, _e, _f, _g, _h, _j;
15684
+ var _a, _b, _c, _d, _e, _f;
15689
15685
  const rec = recData === null || recData === void 0 ? void 0 : recData.rec;
15690
15686
  if (!rec)
15691
15687
  return;
@@ -15705,10 +15701,9 @@ const WaterFall = (props) => {
15705
15701
  bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
15706
15702
  eventInfo: {
15707
15703
  contentId: (_d = rec === null || rec === void 0 ? void 0 : rec.video) === null || _d === void 0 ? void 0 : _d.itemId,
15708
- sceneId: (_g = (_f = (_e = rec === null || rec === void 0 ? void 0 : rec.video) === null || _e === void 0 ? void 0 : _e.scene) === null || _f === void 0 ? void 0 : _f.sceneId) !== null && _g !== void 0 ? _g : '',
15709
15704
  position: cacheActiveIndex + '',
15710
- contentTags: JSON.stringify((_h = rec === null || rec === void 0 ? void 0 : rec.video) === null || _h === void 0 ? void 0 : _h.tags),
15711
- traceInfo: (_j = rec === null || rec === void 0 ? void 0 : rec.video) === null || _j === void 0 ? void 0 : _j.traceInfo,
15705
+ contentTags: JSON.stringify((_e = rec === null || rec === void 0 ? void 0 : rec.video) === null || _e === void 0 ? void 0 : _e.tags),
15706
+ traceInfo: (_f = rec === null || rec === void 0 ? void 0 : rec.video) === null || _f === void 0 ? void 0 : _f.traceInfo,
15712
15707
  hashTags: JSON.stringify([recData === null || recData === void 0 ? void 0 : recData.hashTag]),
15713
15708
  fromKName,
15714
15709
  fromKPage: location === null || location === void 0 ? void 0 : location.href,
@@ -17790,7 +17785,7 @@ const LikeButton = (_a) => {
17790
17785
  const likeIcon = useIconLink(defaultLikeIconPath$2);
17791
17786
  const unlikeIcon = useIconLink(defaultUnLikeIconPath$2);
17792
17787
  const handleClick = lodash.debounce(() => __awaiter(void 0, void 0, void 0, function* () {
17793
- var _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, _4, _5;
17788
+ var _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z;
17794
17789
  if (state) {
17795
17790
  // 先设置状态
17796
17791
  setState(false);
@@ -17800,12 +17795,11 @@ const LikeButton = (_a) => {
17800
17795
  eventSubject: 'favoriteContentCanceled',
17801
17796
  eventDescription: 'This content was unfavorite by the user',
17802
17797
  contentId: (_g = (_f = recData === null || recData === void 0 ? void 0 : recData.video) === null || _f === void 0 ? void 0 : _f.itemId) !== null && _g !== void 0 ? _g : '',
17803
- sceneId: (_k = (_j = (_h = recData === null || recData === void 0 ? void 0 : recData.video) === null || _h === void 0 ? void 0 : _h.scene) === null || _j === void 0 ? void 0 : _j.sceneId) !== null && _k !== void 0 ? _k : '',
17804
- contentName: (_m = (_l = recData === null || recData === void 0 ? void 0 : recData.video) === null || _l === void 0 ? void 0 : _l.title) !== null && _m !== void 0 ? _m : '',
17805
- contentTags: JSON.stringify((_p = (_o = recData === null || recData === void 0 ? void 0 : recData.video) === null || _o === void 0 ? void 0 : _o.tags) !== null && _p !== void 0 ? _p : []),
17798
+ contentName: (_j = (_h = recData === null || recData === void 0 ? void 0 : recData.video) === null || _h === void 0 ? void 0 : _h.title) !== null && _j !== void 0 ? _j : '',
17799
+ contentTags: JSON.stringify((_l = (_k = recData === null || recData === void 0 ? void 0 : recData.video) === null || _k === void 0 ? void 0 : _k.tags) !== null && _l !== void 0 ? _l : []),
17806
17800
  position: position + '',
17807
- contentFormat: ((_q = recData === null || recData === void 0 ? void 0 : recData.video) === null || _q === void 0 ? void 0 : _q.url) ? 'video' : 'image',
17808
- traceInfo: (_r = recData === null || recData === void 0 ? void 0 : recData.video) === null || _r === void 0 ? void 0 : _r.traceInfo
17801
+ contentFormat: ((_m = recData === null || recData === void 0 ? void 0 : recData.video) === null || _m === void 0 ? void 0 : _m.url) ? 'video' : 'image',
17802
+ traceInfo: (_o = recData === null || recData === void 0 ? void 0 : recData.video) === null || _o === void 0 ? void 0 : _o.traceInfo
17809
17803
  }
17810
17804
  });
17811
17805
  // 如果接口调用失败,则回滚状态
@@ -17813,41 +17807,40 @@ const LikeButton = (_a) => {
17813
17807
  setState(true);
17814
17808
  }
17815
17809
  else {
17816
- const nRtcList = (_s = cacheRtcList === null || cacheRtcList === void 0 ? void 0 : cacheRtcList.map((item, index) => {
17810
+ const nRtcList = (_p = cacheRtcList === null || cacheRtcList === void 0 ? void 0 : cacheRtcList.map((item, index) => {
17817
17811
  if (index === position) {
17818
17812
  item.isCollected = false;
17819
17813
  }
17820
17814
  return item;
17821
- })) !== null && _s !== void 0 ? _s : [];
17815
+ })) !== null && _p !== void 0 ? _p : [];
17822
17816
  setCacheRtcList === null || setCacheRtcList === void 0 ? void 0 : setCacheRtcList(nRtcList);
17823
17817
  }
17824
17818
  }
17825
17819
  else {
17826
17820
  setState(true);
17827
- const result = (_t = (yield (mutateLike === null || mutateLike === void 0 ? void 0 : mutateLike({ content: JSON.stringify(recData) })))) !== null && _t !== void 0 ? _t : false;
17821
+ const result = (_q = (yield (mutateLike === null || mutateLike === void 0 ? void 0 : mutateLike({ content: JSON.stringify(recData) })))) !== null && _q !== void 0 ? _q : false;
17828
17822
  bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
17829
17823
  eventInfo: {
17830
17824
  eventSubject: 'favoriteContent',
17831
17825
  eventDescription: 'This content was favorite by the user',
17832
- contentId: (_v = (_u = recData === null || recData === void 0 ? void 0 : recData.video) === null || _u === void 0 ? void 0 : _u.itemId) !== null && _v !== void 0 ? _v : '',
17833
- sceneId: (_y = (_x = (_w = recData === null || recData === void 0 ? void 0 : recData.video) === null || _w === void 0 ? void 0 : _w.scene) === null || _x === void 0 ? void 0 : _x.sceneId) !== null && _y !== void 0 ? _y : '',
17834
- contentName: (_0 = (_z = recData === null || recData === void 0 ? void 0 : recData.video) === null || _z === void 0 ? void 0 : _z.title) !== null && _0 !== void 0 ? _0 : '',
17835
- contentTags: JSON.stringify((_2 = (_1 = recData === null || recData === void 0 ? void 0 : recData.video) === null || _1 === void 0 ? void 0 : _1.tags) !== null && _2 !== void 0 ? _2 : []),
17826
+ contentId: (_s = (_r = recData === null || recData === void 0 ? void 0 : recData.video) === null || _r === void 0 ? void 0 : _r.itemId) !== null && _s !== void 0 ? _s : '',
17827
+ contentName: (_u = (_t = recData === null || recData === void 0 ? void 0 : recData.video) === null || _t === void 0 ? void 0 : _t.title) !== null && _u !== void 0 ? _u : '',
17828
+ contentTags: JSON.stringify((_w = (_v = recData === null || recData === void 0 ? void 0 : recData.video) === null || _v === void 0 ? void 0 : _v.tags) !== null && _w !== void 0 ? _w : []),
17836
17829
  position: position + '',
17837
- contentFormat: ((_3 = recData === null || recData === void 0 ? void 0 : recData.video) === null || _3 === void 0 ? void 0 : _3.url) ? 'video' : 'image',
17838
- traceInfo: (_4 = recData === null || recData === void 0 ? void 0 : recData.video) === null || _4 === void 0 ? void 0 : _4.traceInfo
17830
+ contentFormat: ((_x = recData === null || recData === void 0 ? void 0 : recData.video) === null || _x === void 0 ? void 0 : _x.url) ? 'video' : 'image',
17831
+ traceInfo: (_y = recData === null || recData === void 0 ? void 0 : recData.video) === null || _y === void 0 ? void 0 : _y.traceInfo
17839
17832
  }
17840
17833
  });
17841
17834
  if (!result) {
17842
17835
  setState(false);
17843
17836
  }
17844
17837
  else {
17845
- const nRtcList = (_5 = cacheRtcList === null || cacheRtcList === void 0 ? void 0 : cacheRtcList.map((item, index) => {
17838
+ const nRtcList = (_z = cacheRtcList === null || cacheRtcList === void 0 ? void 0 : cacheRtcList.map((item, index) => {
17846
17839
  if (index === position) {
17847
17840
  item.isCollected = true;
17848
17841
  }
17849
17842
  return item;
17850
- })) !== null && _5 !== void 0 ? _5 : [];
17843
+ })) !== null && _z !== void 0 ? _z : [];
17851
17844
  setCacheRtcList === null || setCacheRtcList === void 0 ? void 0 : setCacheRtcList(nRtcList);
17852
17845
  }
17853
17846
  }
@@ -17950,24 +17943,6 @@ const VideoWidget$4 = React.forwardRef(({ rec, index, height, data, muted, activ
17950
17943
  return;
17951
17944
  (_a = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _a === void 0 ? void 0 : _a.play();
17952
17945
  }, [videoRef === null || videoRef === void 0 ? void 0 : videoRef.current]);
17953
- const handleEnd = () => {
17954
- var _a, _b, _c, _d, _e, _f;
17955
- if (!videoRef.current)
17956
- return;
17957
- if (isDiyH5) {
17958
- (_a = videoRef.current) === null || _a === void 0 ? void 0 : _a.pause();
17959
- if (!loopPlayRef.current)
17960
- return;
17961
- if (index === (data === null || data === void 0 ? void 0 : data.length) - 1) ;
17962
- else {
17963
- const i = (_c = (_b = swiperRef === null || swiperRef === void 0 ? void 0 : swiperRef.current) === null || _b === void 0 ? void 0 : _b.swiper) === null || _c === void 0 ? void 0 : _c.activeIndex;
17964
- (_e = (_d = swiperRef === null || swiperRef === void 0 ? void 0 : swiperRef.current) === null || _d === void 0 ? void 0 : _d.swiper) === null || _e === void 0 ? void 0 : _e.slideTo(i + 1);
17965
- }
17966
- }
17967
- else {
17968
- (_f = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _f === void 0 ? void 0 : _f.play();
17969
- }
17970
- };
17971
17946
  const PAUSE_ICON = useIconLink('/pb_static/06f28a2025c74c1cb49be6767316d827.png');
17972
17947
  const handlePlaying = React.useCallback(() => {
17973
17948
  if (!(videoRef === null || videoRef === void 0 ? void 0 : videoRef.current))
@@ -17976,7 +17951,7 @@ const VideoWidget$4 = React.forwardRef(({ rec, index, height, data, muted, activ
17976
17951
  setIsLoadFinish(true);
17977
17952
  }, []);
17978
17953
  const handleStartPlay = React.useCallback(() => __awaiter(void 0, void 0, void 0, function* () {
17979
- var _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
17954
+ var _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
17980
17955
  if (!(videoRef === null || videoRef === void 0 ? void 0 : videoRef.current))
17981
17956
  return;
17982
17957
  setIsPauseVideo(false);
@@ -17987,11 +17962,16 @@ const VideoWidget$4 = React.forwardRef(({ rec, index, height, data, muted, activ
17987
17962
  const videoCurrentTime = ((_h = (_g = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _g === void 0 ? void 0 : _g.currentTime) !== null && _h !== void 0 ? _h : 0).toFixed(2);
17988
17963
  const playType = (isFirstPlayRef === null || isFirstPlayRef === void 0 ? void 0 : isFirstPlayRef.current) ? '0' : '1';
17989
17964
  bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
17990
- eventInfo: Object.assign({ eventSubject: 'playVideo', eventDescription: 'User played the video', contentId: (_k = (_j = item === null || item === void 0 ? void 0 : item.video) === null || _j === void 0 ? void 0 : _j.itemId) !== null && _k !== void 0 ? _k : '', sceneId: (_o = (_m = (_l = item === null || item === void 0 ? void 0 : item.video) === null || _l === void 0 ? void 0 : _l.scene) === null || _m === void 0 ? void 0 : _m.sceneId) !== null && _o !== void 0 ? _o : '', contentName: (_q = (_p = item === null || item === void 0 ? void 0 : item.video) === null || _p === void 0 ? void 0 : _p.title) !== null && _q !== void 0 ? _q : '', playType, startTime: videoCurrentTime, videoDuration, contentTags: JSON.stringify((_s = (_r = item === null || item === void 0 ? void 0 : item.video) === null || _r === void 0 ? void 0 : _r.tags) !== null && _s !== void 0 ? _s : []), position: index + '', contentFormat: 'video', traceInfo: (_t = item === null || item === void 0 ? void 0 : item.video) === null || _t === void 0 ? void 0 : _t.traceInfo }, ((isFirstPlayRef === null || isFirstPlayRef === void 0 ? void 0 : isFirstPlayRef.current) && { loadTime: (loadedTimeRef === null || loadedTimeRef === void 0 ? void 0 : loadedTimeRef.current) - (initTimeRef === null || initTimeRef === void 0 ? void 0 : initTimeRef.current) + '' }))
17965
+ eventInfo: Object.assign({ eventSubject: 'playVideo', eventDescription: 'User played the video', contentId: (_k = (_j = item === null || item === void 0 ? void 0 : item.video) === null || _j === void 0 ? void 0 : _j.itemId) !== null && _k !== void 0 ? _k : '', contentName: (_m = (_l = item === null || item === void 0 ? void 0 : item.video) === null || _l === void 0 ? void 0 : _l.title) !== null && _m !== void 0 ? _m : '', playType, startTime: videoCurrentTime, videoDuration, contentTags: JSON.stringify((_p = (_o = item === null || item === void 0 ? void 0 : item.video) === null || _o === void 0 ? void 0 : _o.tags) !== null && _p !== void 0 ? _p : []), position: index + '', contentFormat: 'video', traceInfo: (_q = item === null || item === void 0 ? void 0 : item.video) === null || _q === void 0 ? void 0 : _q.traceInfo }, ((isFirstPlayRef === null || isFirstPlayRef === void 0 ? void 0 : isFirstPlayRef.current) && { loadTime: (loadedTimeRef === null || loadedTimeRef === void 0 ? void 0 : loadedTimeRef.current) - (initTimeRef === null || initTimeRef === void 0 ? void 0 : initTimeRef.current) + '' }))
17991
17966
  });
17992
17967
  isFirstPlayRef.current = false;
17993
17968
  }
17994
17969
  }), [bffEventReport, data, index, isFirstPlayRef, videoRef === null || videoRef === void 0 ? void 0 : videoRef.current]);
17970
+ const setCurrentTimeByStartTime = React.useCallback(() => {
17971
+ if (isDiyH5) {
17972
+ videoRef.current.currentTime = scene === null || scene === void 0 ? void 0 : scene.startTime;
17973
+ }
17974
+ }, []);
17995
17975
  const handLoadeddata = React.useCallback(() => {
17996
17976
  if (!(videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) || firstFrameSrc || !blur)
17997
17977
  return;
@@ -18016,12 +17996,13 @@ const VideoWidget$4 = React.forwardRef(({ rec, index, height, data, muted, activ
18016
17996
  const handleLoadedmetadata = React.useCallback(() => {
18017
17997
  if (!videoRef.current)
18018
17998
  return;
17999
+ setCurrentTimeByStartTime();
18019
18000
  loadedTimeRef.current = new Date();
18020
18001
  handleStartPlay();
18021
18002
  handLoadeddata();
18022
18003
  }, [videoRef.current, handLoadeddata, handleStartPlay]);
18023
18004
  const handleClickVideo = React.useCallback((type) => () => {
18024
- var _a, _b, _c, _d, _e;
18005
+ var _a, _b, _c, _d, _e, _f;
18025
18006
  if (!videoRef.current)
18026
18007
  return;
18027
18008
  if (!isLoadFinish)
@@ -18042,17 +18023,20 @@ const VideoWidget$4 = React.forwardRef(({ rec, index, height, data, muted, activ
18042
18023
  break;
18043
18024
  default:
18044
18025
  if (isPause) {
18045
- (_d = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _d === void 0 ? void 0 : _d.play();
18026
+ if (isDiyH5 && Math.round((_d = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _d === void 0 ? void 0 : _d.currentTime) >= (scene === null || scene === void 0 ? void 0 : scene.endTime)) {
18027
+ videoRef.current.currentTime = scene === null || scene === void 0 ? void 0 : scene.startTime;
18028
+ }
18029
+ (_e = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _e === void 0 ? void 0 : _e.play();
18046
18030
  }
18047
18031
  else {
18048
- (_e = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _e === void 0 ? void 0 : _e.pause();
18032
+ (_f = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _f === void 0 ? void 0 : _f.pause();
18049
18033
  }
18050
18034
  setIsPauseVideo(!isPause);
18051
18035
  break;
18052
18036
  }
18053
18037
  }, [isLoadFinish, videoRef === null || videoRef === void 0 ? void 0 : videoRef.current]);
18054
18038
  const handlePause = React.useCallback(() => {
18055
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
18039
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
18056
18040
  if (!(videoRef === null || videoRef === void 0 ? void 0 : videoRef.current))
18057
18041
  return;
18058
18042
  if (activeIndex !== index)
@@ -18068,15 +18052,14 @@ const VideoWidget$4 = React.forwardRef(({ rec, index, height, data, muted, activ
18068
18052
  eventSubject: 'playOverVideo',
18069
18053
  eventDescription: 'User finished playing the video',
18070
18054
  contentId: (_h = (_g = item === null || item === void 0 ? void 0 : item.video) === null || _g === void 0 ? void 0 : _g.itemId) !== null && _h !== void 0 ? _h : '',
18071
- sceneId: (_l = (_k = (_j = item === null || item === void 0 ? void 0 : item.video) === null || _j === void 0 ? void 0 : _j.scene) === null || _k === void 0 ? void 0 : _k.sceneId) !== null && _l !== void 0 ? _l : '',
18072
- contentName: (_o = (_m = item === null || item === void 0 ? void 0 : item.video) === null || _m === void 0 ? void 0 : _m.title) !== null && _o !== void 0 ? _o : '',
18055
+ contentName: (_k = (_j = item === null || item === void 0 ? void 0 : item.video) === null || _j === void 0 ? void 0 : _j.title) !== null && _k !== void 0 ? _k : '',
18073
18056
  endTime: videoCurrentTime,
18074
18057
  videoDuration,
18075
18058
  playDuration,
18076
- contentTags: JSON.stringify((_q = (_p = item === null || item === void 0 ? void 0 : item.video) === null || _p === void 0 ? void 0 : _p.tags) !== null && _q !== void 0 ? _q : []),
18059
+ contentTags: JSON.stringify((_m = (_l = item === null || item === void 0 ? void 0 : item.video) === null || _l === void 0 ? void 0 : _l.tags) !== null && _m !== void 0 ? _m : []),
18077
18060
  position: index + '',
18078
18061
  contentFormat: 'video',
18079
- traceInfo: (_r = item === null || item === void 0 ? void 0 : item.video) === null || _r === void 0 ? void 0 : _r.traceInfo
18062
+ traceInfo: (_o = item === null || item === void 0 ? void 0 : item.video) === null || _o === void 0 ? void 0 : _o.traceInfo
18080
18063
  }
18081
18064
  });
18082
18065
  }
@@ -18084,8 +18067,27 @@ const VideoWidget$4 = React.forwardRef(({ rec, index, height, data, muted, activ
18084
18067
  const handleWaiting = React.useCallback(() => {
18085
18068
  setWaiting(true);
18086
18069
  }, []);
18070
+ const handleTimeUpload = () => {
18071
+ if (!videoRef.current || !isDiyH5)
18072
+ return;
18073
+ setTimeout(() => {
18074
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j;
18075
+ if (Math.round((_a = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _a === void 0 ? void 0 : _a.currentTime) >= ((_b = scene === null || scene === void 0 ? void 0 : scene.endTime) !== null && _b !== void 0 ? _b : 0)) {
18076
+ (_c = videoRef.current) === null || _c === void 0 ? void 0 : _c.pause();
18077
+ if (!loopPlayRef.current)
18078
+ return;
18079
+ if (index === (data === null || data === void 0 ? void 0 : data.length) - 1) {
18080
+ (_e = (_d = swiperRef === null || swiperRef === void 0 ? void 0 : swiperRef.current) === null || _d === void 0 ? void 0 : _d.swiper) === null || _e === void 0 ? void 0 : _e.slideTo(0);
18081
+ }
18082
+ else {
18083
+ const i = (_g = (_f = swiperRef === null || swiperRef === void 0 ? void 0 : swiperRef.current) === null || _f === void 0 ? void 0 : _f.swiper) === null || _g === void 0 ? void 0 : _g.activeIndex;
18084
+ (_j = (_h = swiperRef === null || swiperRef === void 0 ? void 0 : swiperRef.current) === null || _h === void 0 ? void 0 : _h.swiper) === null || _j === void 0 ? void 0 : _j.slideTo(i + 1);
18085
+ }
18086
+ }
18087
+ });
18088
+ };
18087
18089
  React.useEffect(() => {
18088
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
18090
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
18089
18091
  if (!isActive)
18090
18092
  return;
18091
18093
  const videoSrc = videoUrl;
@@ -18106,6 +18108,7 @@ const VideoWidget$4 = React.forwardRef(({ rec, index, height, data, muted, activ
18106
18108
  hls === null || hls === void 0 ? void 0 : hls.attachMedia(videoRef === null || videoRef === void 0 ? void 0 : videoRef.current);
18107
18109
  hls === null || hls === void 0 ? void 0 : hls.on(Hls.Events.MANIFEST_PARSED, function () {
18108
18110
  var _a;
18111
+ setCurrentTimeByStartTime();
18109
18112
  (_a = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _a === void 0 ? void 0 : _a.play();
18110
18113
  });
18111
18114
  }
@@ -18119,11 +18122,12 @@ const VideoWidget$4 = React.forwardRef(({ rec, index, height, data, muted, activ
18119
18122
  (_e = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _e === void 0 ? void 0 : _e.addEventListener('play', handleStartPlay);
18120
18123
  (_f = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _f === void 0 ? void 0 : _f.addEventListener('playing', handlePlaying);
18121
18124
  (_g = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _g === void 0 ? void 0 : _g.addEventListener('pause', handlePause);
18122
- (_h = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _h === void 0 ? void 0 : _h.addEventListener('ended', handleEnd);
18125
+ (_h = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _h === void 0 ? void 0 : _h.addEventListener('ended', handlePlay);
18123
18126
  (_j = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _j === void 0 ? void 0 : _j.addEventListener('canplay', handlePlay);
18124
18127
  (_k = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _k === void 0 ? void 0 : _k.addEventListener('waiting', handleWaiting);
18128
+ (_l = videoRef.current) === null || _l === void 0 ? void 0 : _l.addEventListener('timeupdate', handleTimeUpload);
18125
18129
  return () => {
18126
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
18130
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
18127
18131
  const isPause = (_a = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _a === void 0 ? void 0 : _a.paused;
18128
18132
  if (!isPause)
18129
18133
  handlePause();
@@ -18135,9 +18139,10 @@ const VideoWidget$4 = React.forwardRef(({ rec, index, height, data, muted, activ
18135
18139
  (_e = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _e === void 0 ? void 0 : _e.removeEventListener('play', handleStartPlay);
18136
18140
  (_f = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _f === void 0 ? void 0 : _f.removeEventListener('playing', handlePlaying);
18137
18141
  (_g = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _g === void 0 ? void 0 : _g.removeEventListener('pause', handlePause);
18138
- (_h = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _h === void 0 ? void 0 : _h.removeEventListener('ended', handleEnd);
18142
+ (_h = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _h === void 0 ? void 0 : _h.removeEventListener('ended', handlePlay);
18139
18143
  (_j = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _j === void 0 ? void 0 : _j.removeEventListener('canplay', handlePlay);
18140
18144
  (_k = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _k === void 0 ? void 0 : _k.removeEventListener('waiting', handleWaiting);
18145
+ (_l = videoRef.current) === null || _l === void 0 ? void 0 : _l.removeEventListener('timeupdate', handleTimeUpload);
18141
18146
  };
18142
18147
  }, [isActive]);
18143
18148
  React.useEffect(() => {
@@ -18348,46 +18353,19 @@ const Picture = (props) => {
18348
18353
  }, onLoad: onShowFirstImage }))));
18349
18354
  };
18350
18355
 
18351
- const PictureGroup$4 = React.forwardRef(({ imgUrls, data, height, rec, index, onViewImageEndEvent, onViewImageStartEvent, imgUrlsPostConfig, swiperRef }, ref) => {
18356
+ const PictureGroup$4 = ({ imgUrls, width, height, rec, index, onViewImageEndEvent, onViewImageStartEvent, imgUrlsPostConfig }) => {
18352
18357
  var _a, _b;
18353
18358
  const { isActive } = useSwiperSlide();
18354
- const { sxpParameter, openHashtag, isDiyH5 } = useSxpDataSource();
18359
+ const { sxpParameter, openHashtag } = useSxpDataSource();
18355
18360
  const [isLoad, setIsLoad] = React.useState(false);
18356
18361
  const [imgInfo, setImgInfo] = React.useState();
18357
18362
  const [swiperActiveIndex, setSwiperActiveIndex] = React.useState(0);
18358
- const imgsSwiperRef = React.useRef();
18363
+ const swiperRef = React.useRef();
18359
18364
  const isFirstPlayRef = React.useRef(true);
18360
- const loopPlayRef = React.useRef(true);
18361
18365
  const initTime = new Date();
18362
- React.useImperativeHandle(ref, () => {
18363
- return {
18364
- setLoopPlay(v) {
18365
- loopPlayRef.current = v;
18366
- }
18367
- };
18368
- });
18369
- React.useEffect(() => {
18370
- let timerId;
18371
- if (isLoad && isActive && isDiyH5) {
18372
- timerId = setTimeout(() => {
18373
- var _a, _b, _c, _d;
18374
- if (!loopPlayRef.current)
18375
- return;
18376
- if (index === (data === null || data === void 0 ? void 0 : data.length) - 1) ;
18377
- else {
18378
- const i = (_b = (_a = swiperRef === null || swiperRef === void 0 ? void 0 : swiperRef.current) === null || _a === void 0 ? void 0 : _a.swiper) === null || _b === void 0 ? void 0 : _b.activeIndex;
18379
- (_d = (_c = swiperRef === null || swiperRef === void 0 ? void 0 : swiperRef.current) === null || _c === void 0 ? void 0 : _c.swiper) === null || _d === void 0 ? void 0 : _d.slideTo(i + 1);
18380
- }
18381
- }, 3000);
18382
- }
18383
- return () => {
18384
- if (timerId)
18385
- clearTimeout(timerId);
18386
- };
18387
- }, [isLoad, isActive, isDiyH5, index, swiperRef]);
18388
18366
  React.useEffect(() => {
18389
18367
  if (isLoad && isActive) {
18390
- (imgsSwiperRef === null || imgsSwiperRef === void 0 ? void 0 : imgsSwiperRef.current) && imgsSwiperRef.current.swiper.autoplay.start();
18368
+ (swiperRef === null || swiperRef === void 0 ? void 0 : swiperRef.current) && swiperRef.current.swiper.autoplay.start();
18391
18369
  if (openHashtag) {
18392
18370
  onViewImageEndEvent(rec);
18393
18371
  }
@@ -18397,7 +18375,7 @@ const PictureGroup$4 = React.forwardRef(({ imgUrls, data, height, rec, index, on
18397
18375
  }
18398
18376
  }
18399
18377
  else {
18400
- (imgsSwiperRef === null || imgsSwiperRef === void 0 ? void 0 : imgsSwiperRef.current) && imgsSwiperRef.current.swiper.autoplay.stop();
18378
+ (swiperRef === null || swiperRef === void 0 ? void 0 : swiperRef.current) && swiperRef.current.swiper.autoplay.stop();
18401
18379
  }
18402
18380
  }, [rec, isActive, onViewImageEndEvent, openHashtag, index, onViewImageStartEvent, isLoad, imgInfo]);
18403
18381
  const showFirstImageFn = React.useCallback((e) => __awaiter(void 0, void 0, void 0, function* () {
@@ -18424,13 +18402,13 @@ const PictureGroup$4 = React.forwardRef(({ imgUrls, data, height, rec, index, on
18424
18402
  };
18425
18403
  }, [isActive, imgInfo]);
18426
18404
  const handleMouseEnter = React.useCallback(() => {
18427
- if (imgsSwiperRef.current && imgsSwiperRef.current.swiper && isAlly) {
18428
- imgsSwiperRef.current.swiper.autoplay.stop();
18405
+ if (swiperRef.current && swiperRef.current.swiper && isAlly) {
18406
+ swiperRef.current.swiper.autoplay.stop();
18429
18407
  }
18430
18408
  }, []);
18431
18409
  const handleMouseLeave = React.useCallback(() => {
18432
- if (imgsSwiperRef.current && imgsSwiperRef.current.swiper && isAlly) {
18433
- imgsSwiperRef.current.swiper.autoplay.start();
18410
+ if (swiperRef.current && swiperRef.current.swiper && isAlly) {
18411
+ swiperRef.current.swiper.autoplay.start();
18434
18412
  }
18435
18413
  }, []);
18436
18414
  const handleSlideChange = React.useCallback((swiper) => {
@@ -18451,7 +18429,7 @@ const PictureGroup$4 = React.forwardRef(({ imgUrls, data, height, rec, index, on
18451
18429
  enabled: true
18452
18430
  }
18453
18431
  }
18454
- : {}), { loop: true, ref: imgsSwiperRef, onSlideChange: handleSlideChange, className: css.css(Object.assign(Object.assign({ '.swiper-pagination': {
18432
+ : {}), { loop: true, ref: swiperRef, onSlideChange: handleSlideChange, className: css.css(Object.assign(Object.assign({ '.swiper-pagination': {
18455
18433
  bottom: (_a = imgUrlsPostConfig === null || imgUrlsPostConfig === void 0 ? void 0 : imgUrlsPostConfig.marginBottom) !== null && _a !== void 0 ? _a : 0,
18456
18434
  fontSize: '14px'
18457
18435
  } }, ((imgUrlsPostConfig === null || imgUrlsPostConfig === void 0 ? void 0 : imgUrlsPostConfig.dotsBgColor) && {
@@ -18468,7 +18446,7 @@ const PictureGroup$4 = React.forwardRef(({ imgUrls, data, height, rec, index, on
18468
18446
  return (React.createElement(SwiperSlide, { key: srcKey, "aria-hidden": srcKey !== swiperActiveIndex },
18469
18447
  React.createElement(Picture, { src: !isLoad && srcKey > 0 ? '' : url, height: height, imgUrlsPostConfig: imgUrlsPostConfig, onShowFirstImage: showFirstImageFn })));
18470
18448
  }))));
18471
- });
18449
+ };
18472
18450
  var PictureGroup$5 = React.memo(PictureGroup$4);
18473
18451
 
18474
18452
  /*
@@ -18748,7 +18726,7 @@ var NavBack$1 = React.memo(NavBack);
18748
18726
  * @Author: binruan@chatlabs.com
18749
18727
  * @Date: 2024-03-20 10:27:31
18750
18728
  * @LastEditors: binruan@chatlabs.com
18751
- * @LastEditTime: 2025-05-12 14:26:15
18729
+ * @LastEditTime: 2025-05-09 15:51:40
18752
18730
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\index.tsx
18753
18731
  *
18754
18732
  */
@@ -18768,7 +18746,6 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
18768
18746
  const skipLinkRef = React.useRef(false);
18769
18747
  const [pageNum, setPageNum] = React.useState(2);
18770
18748
  const videoWidgetRef = React.useRef(null);
18771
- const pictureGroupRef = React.useRef(null);
18772
18749
  const { loadVideos, bffEventReport, loading, setPopupDetailData, ctaEvent, swiperRef, waterFallData, setOpenHashtag, appDomain, openHashtag, loadingImage, isFromHashtag, popupDetailData, bffFbReport, curTime, h5EnterLink, isShowConsent, selectTag, isPreview, isEditor, cacheRtcList, setRtcList, cacheActiveIndex, rtcList, isNoMoreData, channel, refreshFeSession, isDiyH5 } = useSxpDataSource();
18773
18750
  const { backMainFeed, productView, jumpToWeb } = useEventReport();
18774
18751
  const isShowFingerTip = React.useMemo(() => {
@@ -18816,7 +18793,7 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
18816
18793
  (_a = swiperRef === null || swiperRef === void 0 ? void 0 : swiperRef.current) === null || _a === void 0 ? void 0 : _a.swiper.slideTo(index);
18817
18794
  }, [data, ctaType, swiperRef]);
18818
18795
  const handleSessionCompleted = React.useCallback((fk) => {
18819
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y;
18796
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v;
18820
18797
  const item = data === null || data === void 0 ? void 0 : data[activeIndex];
18821
18798
  let fromKName = '';
18822
18799
  if (popupDetailData && (((_b = (_a = item === null || item === void 0 ? void 0 : item.video) === null || _a === void 0 ? void 0 : _a.bindProducts) === null || _b === void 0 ? void 0 : _b.length) || ((_c = item === null || item === void 0 ? void 0 : item.video) === null || _c === void 0 ? void 0 : _c.bindProduct))) {
@@ -18843,13 +18820,12 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
18843
18820
  eventSubject: 'sessionCompleted',
18844
18821
  eventDescription: 'Session completed',
18845
18822
  contentId: (_m = item === null || item === void 0 ? void 0 : item.video) === null || _m === void 0 ? void 0 : _m.itemId,
18846
- sceneId: (_q = (_p = (_o = item === null || item === void 0 ? void 0 : item.video) === null || _o === void 0 ? void 0 : _o.scene) === null || _p === void 0 ? void 0 : _p.sceneId) !== null && _q !== void 0 ? _q : '',
18847
- productId: (_r = item === null || item === void 0 ? void 0 : item.product) === null || _r === void 0 ? void 0 : _r.itemId,
18823
+ productId: (_o = item === null || item === void 0 ? void 0 : item.product) === null || _o === void 0 ? void 0 : _o.itemId,
18848
18824
  position: activeIndex + '',
18849
18825
  fromKName: fk || fromKName,
18850
18826
  fromKPage: location === null || location === void 0 ? void 0 : location.href,
18851
- ctatId: (_u = (_t = (_s = item === null || item === void 0 ? void 0 : item.video) === null || _s === void 0 ? void 0 : _s.bindCta) === null || _t === void 0 ? void 0 : _t.itemId) !== null && _u !== void 0 ? _u : '',
18852
- traceInfo: (_y = (_w = (_v = item === null || item === void 0 ? void 0 : item.video) === null || _v === void 0 ? void 0 : _v.traceInfo) !== null && _w !== void 0 ? _w : (_x = item === null || item === void 0 ? void 0 : item.product) === null || _x === void 0 ? void 0 : _x.traceInfo) !== null && _y !== void 0 ? _y : ''
18827
+ 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 : '',
18828
+ 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 : ''
18853
18829
  }
18854
18830
  });
18855
18831
  }, [data, bffEventReport, activeIndex, popupDetailData, tempMap, isFromHashtag, curTime]);
@@ -18908,9 +18884,8 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
18908
18884
  refreshFeSession
18909
18885
  ]);
18910
18886
  const handleSessionExpire = React.useCallback(lodash.debounce(() => {
18911
- var _a, _b;
18887
+ var _a;
18912
18888
  (_a = videoWidgetRef.current) === null || _a === void 0 ? void 0 : _a.setLoopPlay(false);
18913
- (_b = pictureGroupRef.current) === null || _b === void 0 ? void 0 : _b.setLoopPlay(false);
18914
18889
  refreshFeSession === null || refreshFeSession === void 0 ? void 0 : refreshFeSession(false, handleSessionCompleted);
18915
18890
  }, 1000), [handleSessionCompleted, refreshFeSession]);
18916
18891
  React.useEffect(() => {
@@ -18980,18 +18955,18 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
18980
18955
  return null;
18981
18956
  }, [globalConfig, activeIndex, visList]);
18982
18957
  const renderContent = React.useCallback((rec, index) => {
18983
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
18958
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
18984
18959
  if (rec === 'organic menu') {
18985
18960
  return (React.createElement(MultiPosts$2, Object.assign({ recData: data === null || data === void 0 ? void 0 : data[1] }, (_c = (_b = (_a = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.multiPosts) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.item) === null || _c === void 0 ? void 0 : _c.props, (_f = (_e = (_d = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.multiPosts) === null || _d === void 0 ? void 0 : _d[0]) === null || _e === void 0 ? void 0 : _e.item) === null || _f === void 0 ? void 0 : _f.event)));
18986
18961
  }
18987
- if (((_h = (_g = rec.video) === null || _g === void 0 ? void 0 : _g.scene) === null || _h === void 0 ? void 0 : _h.mediaUrl) || ((_j = rec === null || rec === void 0 ? void 0 : rec.video) === null || _j === void 0 ? void 0 : _j.url)) {
18962
+ if ((_g = rec === null || rec === void 0 ? void 0 : rec.video) === null || _g === void 0 ? void 0 : _g.url) {
18988
18963
  return (React.createElement(VideoWidget$5, Object.assign({ key: isReload }, (activeIndex === index && { ref: videoWidgetRef }), { rec: rec, index: index, muted: isMuted, data: data, height: height, activeIndex: activeIndex, videoPostConfig: globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.videoPost, videoPlayIcon: globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.videoPlayIcon, loopPlay: true, swiperRef: swiperRef })));
18989
18964
  }
18990
- if ((_k = rec === null || rec === void 0 ? void 0 : rec.video) === null || _k === void 0 ? void 0 : _k.imgUrls) {
18991
- return (React.createElement(PictureGroup$5, Object.assign({ data: data }, (activeIndex === index && { ref: pictureGroupRef }), { key: rec === null || rec === void 0 ? void 0 : rec.video.itemId, imgUrls: rec === null || rec === void 0 ? void 0 : rec.video.imgUrls, width: containerWidth, height: height, rec: rec, index: index, onViewImageEndEvent: handleViewImageStartEnd, onViewImageStartEvent: handleViewImageStartEvent, imgUrlsPostConfig: globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.imgUrlsPost, swiperRef: swiperRef })));
18965
+ if ((_h = rec === null || rec === void 0 ? void 0 : rec.video) === null || _h === void 0 ? void 0 : _h.imgUrls) {
18966
+ return (React.createElement(PictureGroup$5, { key: rec === null || rec === void 0 ? void 0 : rec.video.itemId, imgUrls: rec === null || rec === void 0 ? void 0 : rec.video.imgUrls, width: containerWidth, height: height, rec: rec, index: index, onViewImageEndEvent: handleViewImageStartEnd, onViewImageStartEvent: handleViewImageStartEvent, imgUrlsPostConfig: globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.imgUrlsPost }));
18992
18967
  }
18993
- if (rec.product && Array.isArray(globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.productPost) && ((_l = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.productPost) === null || _l === void 0 ? void 0 : _l.length) > 0) {
18994
- return (_m = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.productPost) === null || _m === void 0 ? void 0 : _m.map((value, idx) => {
18968
+ if (rec.product && Array.isArray(globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.productPost) && ((_j = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.productPost) === null || _j === void 0 ? void 0 : _j.length) > 0) {
18969
+ return (_k = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.productPost) === null || _k === void 0 ? void 0 : _k.map((value, idx) => {
18995
18970
  var _a, _b, _c, _d, _e, _f, _g, _h;
18996
18971
  const t = resolver[(_a = value === null || value === void 0 ? void 0 : value.item) === null || _a === void 0 ? void 0 : _a.type];
18997
18972
  const Component = withBindDataSource(t);
@@ -19029,7 +19004,7 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
19029
19004
  };
19030
19005
  }, [isShowMore]);
19031
19006
  const renderBottom = React.useCallback((rec, index) => {
19032
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
19007
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
19033
19008
  if (rec === null || rec === void 0 ? void 0 : rec.video) {
19034
19009
  let cta = null;
19035
19010
  if ((_b = (_a = rec === null || rec === void 0 ? void 0 : rec.video) === null || _a === void 0 ? void 0 : _a.bindProducts) === null || _b === void 0 ? void 0 : _b.length) {
@@ -19038,27 +19013,24 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
19038
19013
  else if ((_c = rec === null || rec === void 0 ? void 0 : rec.video) === null || _c === void 0 ? void 0 : _c.bindProduct) {
19039
19014
  cta = '商品CTA';
19040
19015
  }
19041
- else if (tempMap && ((_d = Object.keys(tempMap)) === null || _d === void 0 ? void 0 : _d.includes('服务CTA')) && ((_f = (_e = rec === null || rec === void 0 ? void 0 : rec.video) === null || _e === void 0 ? void 0 : _e.bindCta) === null || _f === void 0 ? void 0 : _f.itemId)) {
19042
- cta = '服务CTA';
19043
- }
19044
19016
  else {
19045
- cta = (_h = (_g = rec === null || rec === void 0 ? void 0 : rec.video) === null || _g === void 0 ? void 0 : _g.bindCta) === null || _h === void 0 ? void 0 : _h.itemId;
19017
+ cta = (_e = (_d = rec === null || rec === void 0 ? void 0 : rec.video) === null || _d === void 0 ? void 0 : _d.bindCta) === null || _e === void 0 ? void 0 : _e.itemId;
19046
19018
  }
19047
19019
  const value = tempMap === null || tempMap === void 0 ? void 0 : tempMap[cta];
19048
19020
  const isNineProduct = (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.nineProductEnable) &&
19049
19021
  index === ((rtcList === null || rtcList === void 0 ? void 0 : rtcList[0]) === 'organic menu' ? 2 : 1) &&
19050
- ((_j = ['MultiCommodity', 'MultiCommodityDiro', 'MultiCommodityDiroNew']) === null || _j === void 0 ? void 0 : _j.includes((_k = value === null || value === void 0 ? void 0 : value.item) === null || _k === void 0 ? void 0 : _k.type));
19022
+ ((_f = ['MultiCommodity', 'MultiCommodityDiro', 'MultiCommodityDiroNew']) === null || _f === void 0 ? void 0 : _f.includes((_g = value === null || value === void 0 ? void 0 : value.item) === null || _g === void 0 ? void 0 : _g.type));
19051
19023
  return (React.createElement(React.Fragment, null,
19052
19024
  isNineProduct && (React.createElement(RenderCard$1, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, isActive: index === activeIndex, value: value, isNineProduct: isNineProduct })),
19053
- ((_l = rec === null || rec === void 0 ? void 0 : rec.video) === null || _l === void 0 ? void 0 : _l.title) && !isShowMore && React.createElement("div", { className: 'clc-sxp-bottom-shadow' }),
19054
- React.createElement("div", { className: 'clc-sxp-bottom', style: { marginBottom: `${(_m = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.bottomInfoDist) !== null && _m !== void 0 ? _m : 40}px` } },
19025
+ ((_h = rec === null || rec === void 0 ? void 0 : rec.video) === null || _h === void 0 ? void 0 : _h.title) && !isShowMore && React.createElement("div", { className: 'clc-sxp-bottom-shadow' }),
19026
+ React.createElement("div", { className: 'clc-sxp-bottom', style: { marginBottom: `${(_j = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.bottomInfoDist) !== null && _j !== void 0 ? _j : 40}px` } },
19055
19027
  React.createElement(Nudge, { nudge: nudge }),
19056
19028
  ((globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.isShowCTA) === undefined || (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.isShowCTA)) && !isNineProduct ? (React.createElement("div", { className: 'clc-sxp-bottom-card' },
19057
19029
  React.createElement(RenderCard$1, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, isActive: index === activeIndex, value: value }))) : null,
19058
19030
  React.createElement("div", null,
19059
- React.createElement(ExpandableText$1, { className: 'clc-sxp-bottom-text', isPost: true, foldText: tipText === null || tipText === void 0 ? void 0 : tipText.foldText, unfoldText: tipText === null || tipText === void 0 ? void 0 : tipText.unfoldText, text: (_p = (_o = rec === null || rec === void 0 ? void 0 : rec.video) === null || _o === void 0 ? void 0 : _o.title) !== null && _p !== void 0 ? _p : '', style: Object.assign(Object.assign({}, descStyle), { textShadow: (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.isOpenTextShadow) ? '2px 2px 4px rgba(0, 0, 0, 0.5)' : 'none' }), onChange: onExpandableChange }),
19031
+ React.createElement(ExpandableText$1, { className: 'clc-sxp-bottom-text', isPost: true, foldText: tipText === null || tipText === void 0 ? void 0 : tipText.foldText, unfoldText: tipText === null || tipText === void 0 ? void 0 : tipText.unfoldText, text: (_l = (_k = rec === null || rec === void 0 ? void 0 : rec.video) === null || _k === void 0 ? void 0 : _k.title) !== null && _l !== void 0 ? _l : '', style: Object.assign(Object.assign({}, descStyle), { textShadow: (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.isOpenTextShadow) ? '2px 2px 4px rgba(0, 0, 0, 0.5)' : 'none' }), onChange: onExpandableChange }),
19060
19032
  React.createElement(RenderCard$1, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, includesCtaType: ['AniLink'], isActive: index === activeIndex, value: value }),
19061
- React.createElement(Hashtag$1, { index: activeIndex, tags: (_r = (_q = rec === null || rec === void 0 ? void 0 : rec.video) === null || _q === void 0 ? void 0 : _q.hashTags) !== null && _r !== void 0 ? _r : [], itemId: (_s = rec === null || rec === void 0 ? void 0 : rec.video) === null || _s === void 0 ? void 0 : _s.itemId, itemType: ((_t = rec === null || rec === void 0 ? void 0 : rec.video) === null || _t === void 0 ? void 0 : _t.itemId) ? 'VIDEO' : null, rec: rec, hashTagStyle: hashTagStyle, hashTagRightMargin: containerWidth - (hashTagRightMargin !== null && hashTagRightMargin !== void 0 ? hashTagRightMargin : 0) }))),
19033
+ React.createElement(Hashtag$1, { index: activeIndex, tags: (_o = (_m = rec === null || rec === void 0 ? void 0 : rec.video) === null || _m === void 0 ? void 0 : _m.hashTags) !== null && _o !== void 0 ? _o : [], itemId: (_p = rec === null || rec === void 0 ? void 0 : rec.video) === null || _p === void 0 ? void 0 : _p.itemId, itemType: ((_q = rec === null || rec === void 0 ? void 0 : rec.video) === null || _q === void 0 ? void 0 : _q.itemId) ? 'VIDEO' : null, rec: rec, hashTagStyle: hashTagStyle, hashTagRightMargin: containerWidth - (hashTagRightMargin !== null && hashTagRightMargin !== void 0 ? hashTagRightMargin : 0) }))),
19062
19034
  React.createElement(RenderCard$1, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, includesCtaType: ['AniLinkPopup'], isActive: index === activeIndex, value: value })));
19063
19035
  }
19064
19036
  return null;
@@ -19097,7 +19069,7 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
19097
19069
  return null;
19098
19070
  }, [globalConfig, waterFallData]);
19099
19071
  const handleViewImageStartEnd = (item) => {
19100
- var _a, _b, _c, _d, _e, _f, _g, _h, _j;
19072
+ var _a, _b, _c, _d, _e, _f;
19101
19073
  if (!((_a = item === null || item === void 0 ? void 0 : item.video) === null || _a === void 0 ? void 0 : _a.url) && ((_b = item === null || item === void 0 ? void 0 : item.video) === null || _b === void 0 ? void 0 : _b.imgUrls)) {
19102
19074
  const endTime = Date.now();
19103
19075
  const duration = viewImageStartTime.current === 0 ? 0 : (endTime - viewImageStartTime.current) / 1000;
@@ -19106,11 +19078,10 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
19106
19078
  eventSubject: 'viewImageCarouselEnd',
19107
19079
  eventDescription: 'User end view the image carousel',
19108
19080
  contentId: (_d = (_c = item === null || item === void 0 ? void 0 : item.video) === null || _c === void 0 ? void 0 : _c.itemId) !== null && _d !== void 0 ? _d : '',
19109
- sceneId: (_g = (_f = (_e = item === null || item === void 0 ? void 0 : item.video) === null || _e === void 0 ? void 0 : _e.scene) === null || _f === void 0 ? void 0 : _f.sceneId) !== null && _g !== void 0 ? _g : '',
19110
- contentName: (_h = item === null || item === void 0 ? void 0 : item.video.title) !== null && _h !== void 0 ? _h : '',
19081
+ contentName: (_e = item === null || item === void 0 ? void 0 : item.video.title) !== null && _e !== void 0 ? _e : '',
19111
19082
  imageEndTime: `${endTime}`,
19112
19083
  playDuration: `${duration}`,
19113
- contentTags: JSON.stringify((_j = item === null || item === void 0 ? void 0 : item.video.tags) !== null && _j !== void 0 ? _j : []),
19084
+ contentTags: JSON.stringify((_f = item === null || item === void 0 ? void 0 : item.video.tags) !== null && _f !== void 0 ? _f : []),
19114
19085
  position: activeIndex + '',
19115
19086
  contentFormat: 'image',
19116
19087
  traceInfo: item === null || item === void 0 ? void 0 : item.video.traceInfo
@@ -19119,7 +19090,7 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
19119
19090
  }
19120
19091
  };
19121
19092
  const handleSlideSkip = (item, position) => {
19122
- 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;
19093
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x;
19123
19094
  if (isPreview || waterFallData)
19124
19095
  return;
19125
19096
  const t = new Date() - curTime.current;
@@ -19145,8 +19116,7 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
19145
19116
  contentTags: (product === null || product === void 0 ? void 0 : product.tags) ? JSON.stringify(product === null || product === void 0 ? void 0 : product.tags) : '',
19146
19117
  position: position + '',
19147
19118
  contentId: (_t = (_s = item === null || item === void 0 ? void 0 : item.video) === null || _s === void 0 ? void 0 : _s.itemId) !== null && _t !== void 0 ? _t : '',
19148
- sceneId: (_w = (_v = (_u = item === null || item === void 0 ? void 0 : item.video) === null || _u === void 0 ? void 0 : _u.scene) === null || _v === void 0 ? void 0 : _v.sceneId) !== null && _w !== void 0 ? _w : '',
19149
- traceInfo: (_0 = (_y = (_x = item === null || item === void 0 ? void 0 : item.video) === null || _x === void 0 ? void 0 : _x.traceInfo) !== null && _y !== void 0 ? _y : (_z = item === null || item === void 0 ? void 0 : item.product) === null || _z === void 0 ? void 0 : _z.traceInfo) !== null && _0 !== void 0 ? _0 : '',
19119
+ traceInfo: (_x = (_v = (_u = item === null || item === void 0 ? void 0 : item.video) === null || _u === void 0 ? void 0 : _u.traceInfo) !== null && _v !== void 0 ? _v : (_w = item === null || item === void 0 ? void 0 : item.product) === null || _w === void 0 ? void 0 : _w.traceInfo) !== null && _x !== void 0 ? _x : '',
19150
19120
  contentFormat
19151
19121
  }
19152
19122
  });
@@ -19156,7 +19126,7 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
19156
19126
  }
19157
19127
  };
19158
19128
  const handleScrollEvent = (swiper) => {
19159
- 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;
19129
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w;
19160
19130
  const item = data[swiper.previousIndex];
19161
19131
  if (!item)
19162
19132
  return;
@@ -19173,12 +19143,11 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
19173
19143
  eventSubject: 'scrollDown',
19174
19144
  eventDescription: 'User scroll down',
19175
19145
  contentId: (_e = (_d = item === null || item === void 0 ? void 0 : item.video) === null || _d === void 0 ? void 0 : _d.itemId) !== null && _e !== void 0 ? _e : '',
19176
- sceneId: (_h = (_g = (_f = item === null || item === void 0 ? void 0 : item.video) === null || _f === void 0 ? void 0 : _f.scene) === null || _g === void 0 ? void 0 : _g.sceneId) !== null && _h !== void 0 ? _h : '',
19177
- productId: (_k = (_j = item === null || item === void 0 ? void 0 : item.product) === null || _j === void 0 ? void 0 : _j.itemId) !== null && _k !== void 0 ? _k : '',
19146
+ productId: (_g = (_f = item === null || item === void 0 ? void 0 : item.product) === null || _f === void 0 ? void 0 : _f.itemId) !== null && _g !== void 0 ? _g : '',
19178
19147
  requestId: null,
19179
- traceInfo: (_p = (_m = (_l = item === null || item === void 0 ? void 0 : item.video) === null || _l === void 0 ? void 0 : _l.traceInfo) !== null && _m !== void 0 ? _m : (_o = item === null || item === void 0 ? void 0 : item.product) === null || _o === void 0 ? void 0 : _o.traceInfo) !== null && _p !== void 0 ? _p : '',
19148
+ traceInfo: (_l = (_j = (_h = item === null || item === void 0 ? void 0 : item.video) === null || _h === void 0 ? void 0 : _h.traceInfo) !== null && _j !== void 0 ? _j : (_k = item === null || item === void 0 ? void 0 : item.product) === null || _k === void 0 ? void 0 : _k.traceInfo) !== null && _l !== void 0 ? _l : '',
19180
19149
  contentFormat,
19181
- position: ((_q = swiper.previousIndex) !== null && _q !== void 0 ? _q : 0) + ''
19150
+ position: ((_m = swiper.previousIndex) !== null && _m !== void 0 ? _m : 0) + ''
19182
19151
  }
19183
19152
  });
19184
19153
  // 如果上一个商品是图片集,需上报 浏览图片集结结束 事件
@@ -19190,13 +19159,12 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
19190
19159
  eventInfo: {
19191
19160
  eventSubject: 'scrollUp',
19192
19161
  eventDescription: 'User scroll up',
19193
- contentId: (_s = (_r = item === null || item === void 0 ? void 0 : item.video) === null || _r === void 0 ? void 0 : _r.itemId) !== null && _s !== void 0 ? _s : '',
19194
- sceneId: (_v = (_u = (_t = item === null || item === void 0 ? void 0 : item.video) === null || _t === void 0 ? void 0 : _t.scene) === null || _u === void 0 ? void 0 : _u.sceneId) !== null && _v !== void 0 ? _v : '',
19195
- productId: (_x = (_w = item.product) === null || _w === void 0 ? void 0 : _w.itemId) !== null && _x !== void 0 ? _x : '',
19162
+ contentId: (_p = (_o = item === null || item === void 0 ? void 0 : item.video) === null || _o === void 0 ? void 0 : _o.itemId) !== null && _p !== void 0 ? _p : '',
19163
+ productId: (_r = (_q = item.product) === null || _q === void 0 ? void 0 : _q.itemId) !== null && _r !== void 0 ? _r : '',
19196
19164
  requestId: null,
19197
- traceInfo: (_1 = (_z = (_y = item === null || item === void 0 ? void 0 : item.video) === null || _y === void 0 ? void 0 : _y.traceInfo) !== null && _z !== void 0 ? _z : (_0 = item === null || item === void 0 ? void 0 : item.product) === null || _0 === void 0 ? void 0 : _0.traceInfo) !== null && _1 !== void 0 ? _1 : '',
19165
+ 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 : '',
19198
19166
  contentFormat,
19199
- position: ((_2 = swiper.previousIndex) !== null && _2 !== void 0 ? _2 : 0) + ''
19167
+ position: ((_w = swiper.previousIndex) !== null && _w !== void 0 ? _w : 0) + ''
19200
19168
  }
19201
19169
  });
19202
19170
  // 如果上一个商品是图片集,需上报 浏览图片集结结束 事件
@@ -19222,7 +19190,7 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
19222
19190
  }
19223
19191
  }, [openHashtag, data, activeIndex]);
19224
19192
  const handleViewImageStartEvent = (activeIndex, imgInfo, enableCapi) => {
19225
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
19193
+ var _a, _b, _c, _d, _e, _f, _g, _h;
19226
19194
  const item = data[activeIndex];
19227
19195
  // 如果是图片集则上报事件
19228
19196
  if (!((_a = item === null || item === void 0 ? void 0 : item.video) === null || _a === void 0 ? void 0 : _a.url) && ((_b = item === null || item === void 0 ? void 0 : item.video) === null || _b === void 0 ? void 0 : _b.imgUrls)) {
@@ -19233,10 +19201,9 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
19233
19201
  eventSubject: 'viewImageCarouselStart',
19234
19202
  eventDescription: 'User start view the image carousel',
19235
19203
  contentId: (_d = (_c = item === null || item === void 0 ? void 0 : item.video) === null || _c === void 0 ? void 0 : _c.itemId) !== null && _d !== void 0 ? _d : '',
19236
- sceneId: (_g = (_f = (_e = item === null || item === void 0 ? void 0 : item.video) === null || _e === void 0 ? void 0 : _e.scene) === null || _f === void 0 ? void 0 : _f.sceneId) !== null && _g !== void 0 ? _g : '',
19237
- contentName: (_h = item === null || item === void 0 ? void 0 : item.video.title) !== null && _h !== void 0 ? _h : '',
19204
+ contentName: (_e = item === null || item === void 0 ? void 0 : item.video.title) !== null && _e !== void 0 ? _e : '',
19238
19205
  imageStartTime: `${startTime}`,
19239
- contentTags: JSON.stringify((_j = item === null || item === void 0 ? void 0 : item.video.tags) !== null && _j !== void 0 ? _j : []),
19206
+ contentTags: JSON.stringify((_f = item === null || item === void 0 ? void 0 : item.video.tags) !== null && _f !== void 0 ? _f : []),
19240
19207
  position: activeIndex + '',
19241
19208
  contentFormat: 'image',
19242
19209
  traceInfo: item === null || item === void 0 ? void 0 : item.video.traceInfo,
@@ -19246,11 +19213,11 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
19246
19213
  if (enableCapi) {
19247
19214
  bffFbReport === null || bffFbReport === void 0 ? void 0 : bffFbReport({
19248
19215
  eventName: 'ViewContent',
19249
- product: (_k = item === null || item === void 0 ? void 0 : item.video) === null || _k === void 0 ? void 0 : _k.bindProduct
19216
+ product: (_g = item === null || item === void 0 ? void 0 : item.video) === null || _g === void 0 ? void 0 : _g.bindProduct
19250
19217
  });
19251
19218
  bffFbReport === null || bffFbReport === void 0 ? void 0 : bffFbReport({
19252
19219
  eventName: 'PageView',
19253
- product: (_l = item === null || item === void 0 ? void 0 : item.video) === null || _l === void 0 ? void 0 : _l.bindProduct
19220
+ product: (_h = item === null || item === void 0 ? void 0 : item.video) === null || _h === void 0 ? void 0 : _h.bindProduct
19254
19221
  });
19255
19222
  }
19256
19223
  }
@@ -19342,20 +19309,15 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
19342
19309
  swiperRef.current.swiper.allowTouchMove = true;
19343
19310
  }, 500);
19344
19311
  }, onActiveIndexChange: (swiper) => {
19345
- var _a, _b;
19346
19312
  setActiveIndex(swiper.activeIndex);
19347
19313
  if (openHashtag)
19348
19314
  return;
19349
19315
  // 处理上滑下滑事件
19350
19316
  handleScrollEvent(swiper);
19351
- if (waterFallData || isEditor)
19317
+ if (waterFallData || isEditor || isDiyH5)
19352
19318
  return;
19353
19319
  if ((swiper === null || swiper === void 0 ? void 0 : swiper.activeIndex) + 1 >= (data === null || data === void 0 ? void 0 : data.length)) {
19354
19320
  if (!isLoadMore) {
19355
- if (isDiyH5) {
19356
- (_a = videoWidgetRef.current) === null || _a === void 0 ? void 0 : _a.setLoopPlay(false);
19357
- (_b = pictureGroupRef.current) === null || _b === void 0 ? void 0 : _b.setLoopPlay(false);
19358
- }
19359
19321
  setIsLoadMore(true);
19360
19322
  loadVideos === null || loadVideos === void 0 ? void 0 : loadVideos(pageNum).then((res) => {
19361
19323
  var _a;
@@ -19408,7 +19370,7 @@ const VideoWidget$2 = ({ rec, index, height, data, muted, activeIndex, videoPost
19408
19370
  }, []);
19409
19371
  const PAUSE_ICON = useIconLink('/pb_static/06f28a2025c74c1cb49be6767316d827.png');
19410
19372
  const handlePlaying = React.useCallback(() => {
19411
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
19373
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
19412
19374
  setIsPauseVideo(false);
19413
19375
  const item = data[index];
19414
19376
  if (item && ((_a = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _a === void 0 ? void 0 : _a.duration)) {
@@ -19421,15 +19383,14 @@ const VideoWidget$2 = ({ rec, index, height, data, muted, activeIndex, videoPost
19421
19383
  eventSubject: 'playVideo',
19422
19384
  eventDescription: 'User played the video',
19423
19385
  contentId: (_h = (_g = item === null || item === void 0 ? void 0 : item.video) === null || _g === void 0 ? void 0 : _g.itemId) !== null && _h !== void 0 ? _h : '',
19424
- sceneId: (_l = (_k = (_j = item === null || item === void 0 ? void 0 : item.video) === null || _j === void 0 ? void 0 : _j.scene) === null || _k === void 0 ? void 0 : _k.sceneId) !== null && _l !== void 0 ? _l : '',
19425
- contentName: (_o = (_m = item === null || item === void 0 ? void 0 : item.video) === null || _m === void 0 ? void 0 : _m.title) !== null && _o !== void 0 ? _o : '',
19386
+ contentName: (_k = (_j = item === null || item === void 0 ? void 0 : item.video) === null || _j === void 0 ? void 0 : _j.title) !== null && _k !== void 0 ? _k : '',
19426
19387
  playType,
19427
19388
  startTime: videoCurrentTime,
19428
19389
  videoDuration,
19429
- contentTags: JSON.stringify((_q = (_p = item === null || item === void 0 ? void 0 : item.video) === null || _p === void 0 ? void 0 : _p.tags) !== null && _q !== void 0 ? _q : []),
19390
+ contentTags: JSON.stringify((_m = (_l = item === null || item === void 0 ? void 0 : item.video) === null || _l === void 0 ? void 0 : _l.tags) !== null && _m !== void 0 ? _m : []),
19430
19391
  position: index + '',
19431
19392
  contentFormat: 'video',
19432
- traceInfo: (_r = item === null || item === void 0 ? void 0 : item.video) === null || _r === void 0 ? void 0 : _r.traceInfo
19393
+ traceInfo: (_o = item === null || item === void 0 ? void 0 : item.video) === null || _o === void 0 ? void 0 : _o.traceInfo
19433
19394
  }
19434
19395
  });
19435
19396
  setIsFirstPlay(false);
@@ -19468,7 +19429,7 @@ const VideoWidget$2 = ({ rec, index, height, data, muted, activeIndex, videoPost
19468
19429
  }
19469
19430
  }, [isLoadFinish]);
19470
19431
  const onPause = React.useCallback(() => {
19471
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
19432
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
19472
19433
  const item = data[index];
19473
19434
  const videoDuration = ((_b = (_a = videoRef.current) === null || _a === void 0 ? void 0 : _a.duration) !== null && _b !== void 0 ? _b : 0).toFixed(2);
19474
19435
  const videoCurrentTime = ((_d = (_c = videoRef.current) === null || _c === void 0 ? void 0 : _c.currentTime) !== null && _d !== void 0 ? _d : 0).toFixed(2);
@@ -19479,15 +19440,14 @@ const VideoWidget$2 = ({ rec, index, height, data, muted, activeIndex, videoPost
19479
19440
  eventSubject: 'playOverVideo',
19480
19441
  eventDescription: 'User finished playing the video',
19481
19442
  contentId: (_h = (_g = item === null || item === void 0 ? void 0 : item.video) === null || _g === void 0 ? void 0 : _g.itemId) !== null && _h !== void 0 ? _h : '',
19482
- sceneId: (_l = (_k = (_j = item === null || item === void 0 ? void 0 : item.video) === null || _j === void 0 ? void 0 : _j.scene) === null || _k === void 0 ? void 0 : _k.sceneId) !== null && _l !== void 0 ? _l : '',
19483
- contentName: (_o = (_m = item === null || item === void 0 ? void 0 : item.video) === null || _m === void 0 ? void 0 : _m.title) !== null && _o !== void 0 ? _o : '',
19443
+ contentName: (_k = (_j = item === null || item === void 0 ? void 0 : item.video) === null || _j === void 0 ? void 0 : _j.title) !== null && _k !== void 0 ? _k : '',
19484
19444
  endTime: videoCurrentTime,
19485
19445
  videoDuration,
19486
19446
  playDuration,
19487
- contentTags: JSON.stringify((_q = (_p = item === null || item === void 0 ? void 0 : item.video) === null || _p === void 0 ? void 0 : _p.tags) !== null && _q !== void 0 ? _q : []),
19447
+ contentTags: JSON.stringify((_m = (_l = item === null || item === void 0 ? void 0 : item.video) === null || _l === void 0 ? void 0 : _l.tags) !== null && _m !== void 0 ? _m : []),
19488
19448
  position: index + '',
19489
19449
  contentFormat: 'video',
19490
- traceInfo: (_r = item === null || item === void 0 ? void 0 : item.video) === null || _r === void 0 ? void 0 : _r.traceInfo
19450
+ traceInfo: (_o = item === null || item === void 0 ? void 0 : item.video) === null || _o === void 0 ? void 0 : _o.traceInfo
19491
19451
  }
19492
19452
  });
19493
19453
  }