pb-sxp-ui 1.2.2 → 1.2.4

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 (40) hide show
  1. package/dist/index.cjs +79 -49
  2. package/dist/index.cjs.map +1 -1
  3. package/dist/index.css +36 -1
  4. package/dist/index.js +79 -49
  5. package/dist/index.js.map +1 -1
  6. package/dist/index.min.cjs +3 -3
  7. package/dist/index.min.cjs.map +1 -1
  8. package/dist/index.min.js +3 -3
  9. package/dist/index.min.js.map +1 -1
  10. package/dist/pb-ui.js +79 -49
  11. package/dist/pb-ui.js.map +1 -1
  12. package/dist/pb-ui.min.js +3 -3
  13. package/dist/pb-ui.min.js.map +1 -1
  14. package/es/core/Pagebuilder/type.d.ts +1 -0
  15. package/es/core/components/SxpPageCore/index.js +1 -1
  16. package/es/core/components/SxpPageRender/Hashtag/index.js +0 -1
  17. package/es/core/components/SxpPageRender/Modal/index.js +16 -8
  18. package/es/core/components/SxpPageRender/Popup/index.js +1 -1
  19. package/es/core/components/SxpPageRender/RenderCard.js +15 -2
  20. package/es/core/components/SxpPageRender/index.js +1 -1
  21. package/es/core/context/SxpDataSourceProvider.d.ts +1 -0
  22. package/es/core/context/SxpDataSourceProvider.js +3 -3
  23. package/es/materials/sxp/cta/AniLink/index.js +4 -1
  24. package/es/materials/sxp/cta/AniLinkPopup/index.js +9 -6
  25. package/es/materials/sxp/cta/AniLinkPopup/settingRender.js +1 -1
  26. package/es/materials/sxp/popup/CommodityList/index.js +13 -7
  27. package/lib/core/Pagebuilder/type.d.ts +1 -0
  28. package/lib/core/components/SxpPageCore/index.js +1 -1
  29. package/lib/core/components/SxpPageRender/Hashtag/index.js +0 -1
  30. package/lib/core/components/SxpPageRender/Modal/index.js +16 -8
  31. package/lib/core/components/SxpPageRender/Popup/index.js +1 -1
  32. package/lib/core/components/SxpPageRender/RenderCard.js +15 -2
  33. package/lib/core/components/SxpPageRender/index.js +1 -1
  34. package/lib/core/context/SxpDataSourceProvider.d.ts +1 -0
  35. package/lib/core/context/SxpDataSourceProvider.js +3 -3
  36. package/lib/materials/sxp/cta/AniLink/index.js +4 -1
  37. package/lib/materials/sxp/cta/AniLinkPopup/index.js +9 -6
  38. package/lib/materials/sxp/cta/AniLinkPopup/settingRender.js +1 -1
  39. package/lib/materials/sxp/popup/CommodityList/index.js +13 -7
  40. package/package.json +1 -1
package/dist/index.cjs CHANGED
@@ -554,7 +554,7 @@ var DataSourceType;
554
554
  DataSourceType[DataSourceType["BFF"] = 5] = "BFF";
555
555
  })(DataSourceType || (DataSourceType = {}));
556
556
  const DEFAULT_TAG = 'FOR U';
557
- const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent = true, maxSize, defaultSize, isPreview = false, sxpParameter, appDomain, hashTagSize, loadingImage, isOpenHashTag = false, enabledMetaConversionApi = false, consentHeight, consentWidth, isShowTag = true, isOpenConsent = false, globalConfig, isEditor = false }) => {
557
+ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent = true, maxSize, defaultSize, isPreview = false, sxpParameter, appDomain, hashTagSize, loadingImage, isOpenHashTag = false, enabledMetaConversionApi = false, consentHeight, consentWidth, isShowTag = true, isOpenConsent = false, globalConfig, isEditor = false, utmParameter }) => {
558
558
  var _a, _b, _c;
559
559
  const [rtcList, setRtcList] = React.useState([]);
560
560
  const [tagList, setTagList] = React.useState([]);
@@ -636,7 +636,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
636
636
  const val = (_h = (_g = (_f = utmVal === null || utmVal === void 0 ? void 0 : utmVal.split('&')) === null || _f === void 0 ? void 0 : _f.filter((val) => {
637
637
  var _a, _b;
638
638
  const key = val.split('=')[0];
639
- return (_b = ((_a = sxpParameter === null || sxpParameter === void 0 ? void 0 : sxpParameter.channels) !== null && _a !== void 0 ? _a : [])) === null || _b === void 0 ? void 0 : _b.includes(key);
639
+ return (_b = ((_a = utmParameter === null || utmParameter === void 0 ? void 0 : utmParameter.channels) !== null && _a !== void 0 ? _a : [])) === null || _b === void 0 ? void 0 : _b.includes(key);
640
640
  })) === null || _g === void 0 ? void 0 : _g.join('&')) !== null && _h !== void 0 ? _h : '';
641
641
  query = Object.assign(Object.assign({}, query), { channel: decodeURIComponent(val) });
642
642
  }
@@ -731,7 +731,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
731
731
  const val = (_o = (_m = (_l = utmVal === null || utmVal === void 0 ? void 0 : utmVal.split('&')) === null || _l === void 0 ? void 0 : _l.filter((val) => {
732
732
  var _a, _b;
733
733
  const key = val.split('=')[0];
734
- return (_b = ((_a = sxpParameter === null || sxpParameter === void 0 ? void 0 : sxpParameter.channels) !== null && _a !== void 0 ? _a : [])) === null || _b === void 0 ? void 0 : _b.includes(key);
734
+ return (_b = ((_a = utmParameter === null || utmParameter === void 0 ? void 0 : utmParameter.channels) !== null && _a !== void 0 ? _a : [])) === null || _b === void 0 ? void 0 : _b.includes(key);
735
735
  })) === null || _m === void 0 ? void 0 : _m.join('&')) !== null && _o !== void 0 ? _o : '';
736
736
  const result = yield (bffFetch === null || bffFetch === void 0 ? void 0 : bffFetch('/tag/list', { method: 'GET', query: { channel: decodeURIComponent(val) } }));
737
737
  setTagList((_q = (_p = result === null || result === void 0 ? void 0 : result.data) === null || _p === void 0 ? void 0 : _p.tags) !== null && _q !== void 0 ? _q : []);
@@ -8605,7 +8605,7 @@ SwiperSlide.displayName = 'SwiperSlide';
8605
8605
  * @Author: binruan@chatlabs.com
8606
8606
  * @Date: 2023-11-02 18:34:34
8607
8607
  * @LastEditors: binruan@chatlabs.com
8608
- * @LastEditTime: 2024-07-19 18:39:54
8608
+ * @LastEditTime: 2024-07-25 17:05:20
8609
8609
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\Modal\index.tsx
8610
8610
  *
8611
8611
  */
@@ -8661,19 +8661,25 @@ const Modal = ({ visible, onClose, children, modalStyle, padding, popup, schema,
8661
8661
  onClose === null || onClose === void 0 ? void 0 : onClose();
8662
8662
  }, 300);
8663
8663
  const handleTouchStart = (event) => {
8664
- event.stopPropagation();
8665
- touchRef.current = event.touches[0].clientY;
8666
- fTouchRef.current = event.touches[0].clientY;
8664
+ // event.stopPropagation();
8665
+ touchRef.current = event.touches[0];
8666
+ fTouchRef.current = event.touches[0];
8667
8667
  touchMoveRef.current = true;
8668
8668
  };
8669
8669
  const handleTouchMove = (event) => {
8670
- event.stopPropagation();
8670
+ // event.stopPropagation();
8671
8671
  requestAnimationFrame(() => {
8672
8672
  var _a;
8673
8673
  if (touchMoveRef.current && ((_a = ref === null || ref === void 0 ? void 0 : ref.current) === null || _a === void 0 ? void 0 : _a.scrollTop) === 0) {
8674
8674
  const currentY = event.touches[0].clientY;
8675
- const diff = touchRef.current - currentY;
8676
- touchRef.current = currentY;
8675
+ const currentX = event.touches[0].clientX;
8676
+ const diff = touchRef.current.clientY - currentY;
8677
+ touchRef.current = event.touches[0];
8678
+ const diffY = currentY - fTouchRef.current.clientY;
8679
+ const diffX = currentX - fTouchRef.current.clientX;
8680
+ if (Math.abs(diffX) > Math.abs(diffY)) {
8681
+ return;
8682
+ }
8677
8683
  const ts = modalTrans - diff;
8678
8684
  if (ts > 0) {
8679
8685
  setModalTrans(ts);
@@ -8683,9 +8689,14 @@ const Modal = ({ visible, onClose, children, modalStyle, padding, popup, schema,
8683
8689
  };
8684
8690
  const handleTouchEnd = (event) => {
8685
8691
  var _a;
8686
- event.stopPropagation();
8692
+ // event.stopPropagation();
8687
8693
  if (touchMoveRef.current && ((_a = ref === null || ref === void 0 ? void 0 : ref.current) === null || _a === void 0 ? void 0 : _a.scrollTop) === 0) {
8688
- const diff = fTouchRef.current - touchRef.current;
8694
+ const diffY = event.changedTouches[0].clientY - fTouchRef.current.clientY;
8695
+ const diffX = event.changedTouches[0].clientX - fTouchRef.current.clientX;
8696
+ if (Math.abs(diffX) > Math.abs(diffY)) {
8697
+ return;
8698
+ }
8699
+ const diff = fTouchRef.current.clientY - touchRef.current.clientY;
8689
8700
  if (diff > 0) {
8690
8701
  setModalTrans(0);
8691
8702
  }
@@ -10176,18 +10187,24 @@ const CommodityList$1 = (_a) => {
10176
10187
  }
10177
10188
  }, []);
10178
10189
  return (React.createElement("div", { className: css.css(Object.assign(Object.assign({}, style), { display: 'flex', flexDirection: 'column', gap: '10px', padding: '0 20px', marginTop: '50px' })) }, product === null || product === void 0 ? void 0 : product.map((item, index) => {
10179
- var _a, _b, _c, _d, _e, _f, _g, _h;
10190
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
10180
10191
  return (React.createElement(EventProvider$1, Object.assign({ key: index, isExternalLink: isExternalLink, rec: recData, index: index }, props, { className: css.css({
10181
10192
  display: 'flex'
10182
10193
  }) }),
10183
10194
  React.createElement(Img$1, { src: (_d = (_c = (_a = item === null || item === void 0 ? void 0 : item.cover) !== null && _a !== void 0 ? _a : (_b = item === null || item === void 0 ? void 0 : item.homePage) === null || _b === void 0 ? void 0 : _b[0]) !== null && _c !== void 0 ? _c : sxpParameter === null || sxpParameter === void 0 ? void 0 : sxpParameter.bottom_image) !== null && _d !== void 0 ? _d : bottom_image, rec: recData, item: item, index: index, translateY: translateY, imgStyle: commodityPicture }),
10184
- React.createElement("div", { style: { flex: 1, display: 'flex', flexDirection: 'column', justifyContent: 'space-between' } },
10195
+ React.createElement("div", { style: {
10196
+ flex: 1,
10197
+ width: `calc(100% - ${(_e = commodityPicture === null || commodityPicture === void 0 ? void 0 : commodityPicture.width) !== null && _e !== void 0 ? _e : 0}px - ${(_f = commodityPicture === null || commodityPicture === void 0 ? void 0 : commodityPicture.marginRight) !== null && _f !== void 0 ? _f : 0}px - ${(_g = style === null || style === void 0 ? void 0 : style.padding) !== null && _g !== void 0 ? _g : 0}px)`,
10198
+ display: 'flex',
10199
+ flexDirection: 'column',
10200
+ justifyContent: 'space-between'
10201
+ } },
10185
10202
  React.createElement("div", null,
10186
- React.createElement("div", { style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.title, hidden: !!item && !(item === null || item === void 0 ? void 0 : item.title), dangerouslySetInnerHTML: {
10187
- __html: setFontForText((_e = item === null || item === void 0 ? void 0 : item.title) !== null && _e !== void 0 ? _e : 'Pendant in Yellow Gold with Diamonds, Medium', commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.title)
10203
+ React.createElement("div", { className: 'one-line-ellipsis', style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.title, hidden: !!item && !(item === null || item === void 0 ? void 0 : item.title), dangerouslySetInnerHTML: {
10204
+ __html: setFontForText((_h = item === null || item === void 0 ? void 0 : item.title) !== null && _h !== void 0 ? _h : 'Pendant in Yellow Gold with Diamonds, Medium', commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.title)
10188
10205
  } }),
10189
- React.createElement("div", { style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.collection, hidden: !!item && (!(item === null || item === void 0 ? void 0 : item.collection) || (item === null || item === void 0 ? void 0 : item.collection) === ''), dangerouslySetInnerHTML: {
10190
- __html: setFontForText((_f = item === null || item === void 0 ? void 0 : item.collection) !== null && _f !== void 0 ? _f : 'Tiffany Lock', commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.collection)
10206
+ React.createElement("div", { className: 'two-line-ellipsis', style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.collection, hidden: !!item && (!(item === null || item === void 0 ? void 0 : item.collection) || (item === null || item === void 0 ? void 0 : item.collection) === ''), dangerouslySetInnerHTML: {
10207
+ __html: setFontForText((_j = item === null || item === void 0 ? void 0 : item.collection) !== null && _j !== void 0 ? _j : 'Tiffany Lock', commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.collection)
10191
10208
  } })),
10192
10209
  React.createElement("div", { className: css.css({
10193
10210
  display: 'flex',
@@ -10200,7 +10217,7 @@ const CommodityList$1 = (_a) => {
10200
10217
  __html: setFontForText(priceText(item), commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.price)
10201
10218
  } }),
10202
10219
  React.createElement("div", { className: 'one-line-ellipsis', style: Object.assign(Object.assign({}, buttonStyle), { padding: '0 15px', maxWidth: '100px' }), dangerouslySetInnerHTML: {
10203
- __html: setFontForText((_h = (_g = item === null || item === void 0 ? void 0 : item.bindCta) === null || _g === void 0 ? void 0 : _g.enTitle) !== null && _h !== void 0 ? _h : 'Shop Now', buttonStyle)
10220
+ __html: setFontForText((_l = (_k = item === null || item === void 0 ? void 0 : item.bindCta) === null || _k === void 0 ? void 0 : _k.enTitle) !== null && _l !== void 0 ? _l : 'Shop Now', buttonStyle)
10204
10221
  } })))));
10205
10222
  })));
10206
10223
  };
@@ -13933,7 +13950,7 @@ var settingRender$1 = [
13933
13950
  }
13934
13951
  ];
13935
13952
 
13936
- var styles$1 = {"animated-button":"index-module_animated-button__lqTbg","gradientCover":"index-module_gradientCover__5iUag"};
13953
+ var styles$1 = {"animated-button":"index-module_animated-button__lqTbg","gradientCover":"index-module_gradientCover__5iUag","one-line-ellipsis":"index-module_one-line-ellipsis__HutE0","two-line-ellipsis":"index-module_two-line-ellipsis__c8gRJ"};
13937
13954
 
13938
13955
  const AniLink$1 = (_a) => {
13939
13956
  var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
@@ -13991,13 +14008,16 @@ const AniLink$1 = (_a) => {
13991
14008
  if (isOnScreen) {
13992
14009
  setVisible(true);
13993
14010
  }
14011
+ else {
14012
+ setVisible(false);
14013
+ }
13994
14014
  }, [isOnScreen]);
13995
14015
  const aniNamStyle = React.useMemo(() => {
13996
14016
  if (!visible)
13997
14017
  return null;
13998
14018
  return styles$1['animated-button'];
13999
14019
  }, [visible]);
14000
- return (React.createElement("div", Object.assign({ ref: ref, style: Object.assign(Object.assign(Object.assign({}, style), ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle), { lineHeight: `${(_l = style === null || style === void 0 ? void 0 : style.height) !== null && _l !== void 0 ? _l : 0}px` }) }, props, { className: `${aniNamStyle} ${css.css(aniTimStyle)} one-line-ellipsis`, onClick: handleTo, dangerouslySetInnerHTML: {
14020
+ return (React.createElement("div", Object.assign({ ref: ref, style: Object.assign(Object.assign(Object.assign({}, style), ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle), { lineHeight: `${(_l = style === null || style === void 0 ? void 0 : style.height) !== null && _l !== void 0 ? _l : 0}px` }) }, props, { className: `${aniNamStyle} ${css.css(aniTimStyle)} ${styles$1['one-line-ellipsis']}`, onClick: handleTo, dangerouslySetInnerHTML: {
14001
14021
  __html: setFontForText(title, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
14002
14022
  } })));
14003
14023
  };
@@ -14108,7 +14128,7 @@ const AniLink = createMaterial(AniLinkComponent, {
14108
14128
  * @Author: binruan@chatlabs.com
14109
14129
  * @Date: 2024-03-26 16:50:25
14110
14130
  * @LastEditors: binruan@chatlabs.com
14111
- * @LastEditTime: 2024-07-08 11:01:24
14131
+ * @LastEditTime: 2024-07-25 15:02:45
14112
14132
  * @FilePath: \pb-sxp-ui\src\materials\sxp\cta\AniLinkPopup\settingRender.tsx
14113
14133
  *
14114
14134
  */
@@ -14310,7 +14330,7 @@ var settingRender = [
14310
14330
  },
14311
14331
  {
14312
14332
  type: 'TextSpace',
14313
- name: ['props', 'ctaTempStyles', 'title']
14333
+ name: ['props', 'ctaTempStyles', 'ctaTitle']
14314
14334
  },
14315
14335
  {
14316
14336
  type: 'Color',
@@ -14362,7 +14382,7 @@ var settingRender = [
14362
14382
  }
14363
14383
  ];
14364
14384
 
14365
- var styles = {"aniLinkPopup":"index-module_aniLinkPopup__YT7kj","animated-fadeIn":"index-module_animated-fadeIn__8ZCbq","fadeIn":"index-module_fadeIn__2E-dk","animated-fadeOut":"index-module_animated-fadeOut__iK4oc","fadeOut":"index-module_fadeOut__MgevT","tow-line-ellipsis":"index-module_tow-line-ellipsis__GKFXr","modal-icon-wrapper":"index-module_modal-icon-wrapper__tu3BY","modal-icon-wrapper-img":"index-module_modal-icon-wrapper-img__4b7qZ"};
14385
+ var styles = {"aniLinkPopup":"index-module_aniLinkPopup__YT7kj","animated-fadeIn":"index-module_animated-fadeIn__8ZCbq","fadeIn":"index-module_fadeIn__2E-dk","animated-fadeOut":"index-module_animated-fadeOut__iK4oc","fadeOut":"index-module_fadeOut__MgevT","one-line-ellipsis":"index-module_one-line-ellipsis__NRiVV","two-line-ellipsis":"index-module_two-line-ellipsis__k-YGB","modal-icon-wrapper":"index-module_modal-icon-wrapper__tu3BY","modal-icon-wrapper-img":"index-module_modal-icon-wrapper-img__4b7qZ"};
14366
14386
 
14367
14387
  const closeIcon = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAjhJREFUWEfFlztOw0AQhmeWiJ4CCmpQ5DiRQsIJyAWg5A0lR0AIChDiCJS8ER0cADgBeRSxt4CCDgkaKiq8i+zYeWx2413HEWmiJJv9v535Z2aN8M8vFPT9z3zETD0aAUChUJjwvPFHAJhBhB3Hqd6OAsK2yyucwykAvP38eJX398Z3AJDLlVYR8ToU9Rhj25TWr9KEsKy5dULIGQCMtfZly45TvwsAstm56UwG6wA4FUFwzrdctxZBDcWSy5XWEPG8I84/GcMipdWPtgcsaz5PCHtKG0IuTiqUvjT9U/WYMG2IOPE+AP+LtCB0xKUAAyA2Xbd2o2OG0NQXvTnvhL17D7EPtH9TRCIWwkRcGYGIQgYBABuqPuHXOQBc6pw80lBGwBQiiXhsBHQhkoprA6iM6acjhDQKu5YJZW6XeOI3XJdpvfsdTu52VfXEekD8owQiXGIubpSCbhDbLu8DwKEAd+A41SOdPpE4BS0viFOtvV2iKWqUgn5x/tmS70xR01GuDSCKc86/OCcLgTyyZ0ScDGNhFAktAJV4NFJ9YyaFiAWIE+9uVkkgBgLoig8DMWAa9ro9ynkUdlW5maZDCmB6clmz0k1HH4Cs1Ezbq2p2yEpUuBOKTSZZex00RUWIrltxuuK6EOGDSbGIOPZicpMx6fny650377qNRgBgWeVFQuA+6UjVgREhGIMlSqsPUQqIbZdOOIdZQmCv2axRnU1N1+TzJYsxOEaEV8ep7frPZ7Gd0FTEdP0ft0/kMNdg0eoAAAAASUVORK5CYII=';
14368
14388
  const AniLinkPopup$1 = (_a) => {
@@ -14416,26 +14436,29 @@ const AniLinkPopup$1 = (_a) => {
14416
14436
  if (isOnScreen) {
14417
14437
  setVisible(true);
14418
14438
  }
14439
+ else {
14440
+ setVisible(false);
14441
+ }
14419
14442
  }, [isOnScreen]);
14420
14443
  const aniNamStyle = React.useMemo(() => {
14421
14444
  if (!visible)
14422
14445
  return null;
14423
- return startAni ? styles['animated-fadeIn'] : styles['animated-fadeOut'];
14446
+ return startAni ? styles['animated-fadeIn'] : null;
14424
14447
  }, [visible, startAni]);
14425
14448
  return (React.createElement(React.Fragment, null, isTel ? (React.createElement("div", { style: {
14426
14449
  height: '40px',
14427
14450
  lineHeight: '40px',
14428
14451
  paddingLeft: '6px'
14429
- } }, "Cta Title")) : (React.createElement("div", Object.assign({ ref: ref }, 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 }),
14452
+ } }, "Cta Title")) : (React.createElement(React.Fragment, null, aniNamStyle ? (React.createElement("div", Object.assign({ ref: ref }, 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 }),
14430
14453
  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 } },
14431
14454
  React.createElement("img", { src: (_t = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.popupCloseIcon) !== null && _t !== void 0 ? _t : closeIcon, alt: 'close', className: styles['modal-icon-wrapper-img'] })),
14432
14455
  React.createElement(Img$1, { src: src, rec: recData, item: (_y = (_w = (_v = (_u = recData === null || recData === void 0 ? void 0 : recData.video) === null || _u === void 0 ? void 0 : _u.bindProducts) === null || _v === void 0 ? void 0 : _v[0]) !== null && _w !== void 0 ? _w : (_x = recData === null || recData === void 0 ? void 0 : recData.video) === null || _x === void 0 ? void 0 : _x.bindProduct) !== null && _y !== void 0 ? _y : recData === null || recData === void 0 ? void 0 : recData.video, index: index, translateY: translateY, imgStyle: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img }),
14433
- React.createElement("div", { hidden: !!recData && !(product === null || product === void 0 ? void 0 : product.title), className: styles['tow-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
14456
+ (!recData || (product === null || product === void 0 ? void 0 : product.title)) && (React.createElement("div", { className: styles['two-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
14434
14457
  __html: setFontForText((_z = product === null || product === void 0 ? void 0 : product.title) !== null && _z !== void 0 ? _z : 'Product Name', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title)
14435
- } }),
14436
- React.createElement("div", { className: 'one-line-ellipsis', style: Object.assign(Object.assign({}, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle), { lineHeight: ((_0 = ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle) === null || _0 === void 0 ? void 0 : _0.height) + 'px' }), dangerouslySetInnerHTML: {
14458
+ } })),
14459
+ React.createElement("div", { className: styles['one-line-ellipsis'], style: Object.assign(Object.assign({}, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle), { lineHeight: ((_0 = ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle) === null || _0 === void 0 ? void 0 : _0.height) + 'px' }), dangerouslySetInnerHTML: {
14437
14460
  __html: setFontForText(title, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
14438
- } })))));
14461
+ } }))) : (React.createElement("div", { ref: ref, style: { position: 'absolute', height: '50px', width: '50px', bottom: 0, right: 0, zIndex: 1000 } }))))));
14439
14462
  };
14440
14463
  var AniLinkPopupComponent = React.memo(AniLinkPopup$1);
14441
14464
 
@@ -15161,7 +15184,7 @@ var PictureGroup$3 = React.memo(PictureGroup$2);
15161
15184
  * @Author: binruan@chatlabs.com
15162
15185
  * @Date: 2024-01-15 19:03:09
15163
15186
  * @LastEditors: binruan@chatlabs.com
15164
- * @LastEditTime: 2024-07-09 18:47:05
15187
+ * @LastEditTime: 2024-07-25 18:14:29
15165
15188
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\Hashtag\index.tsx
15166
15189
  *
15167
15190
  */
@@ -15198,7 +15221,6 @@ const Hashtag = ({ tags, itemId, itemType, index, rec, hashTagStyle }) => {
15198
15221
  }
15199
15222
  return (React.createElement("span", { style: { textDecoration: 'underline', cursor: 'pointer', color: '#fff' }, onClick: () => setIsShowMore(!isShowMore) }, isShowMore ? 'show less' : 'show more'));
15200
15223
  }, [isShowMore, tags]);
15201
- console.log(hashTagStyle, '111');
15202
15224
  return (React.createElement("div", { className: 'clc-sxp-bottom-hashtag', style: { marginTop: `${(_a = hashTagStyle === null || hashTagStyle === void 0 ? void 0 : hashTagStyle.marginTop) !== null && _a !== void 0 ? _a : 16}px` } },
15203
15225
  React.createElement(Scroll$1, null, tags === null || tags === void 0 ? void 0 : tags.map((item, index) => (React.createElement(SwiperSlide, { key: index, hidden: !isShowMore ? index >= 6 : false, className: 'clc-sxp-bottom-hashtag-item', style: hashTagStyle, onClick: () => handleClickTag(item) },
15204
15226
  React.createElement("div", { dangerouslySetInnerHTML: { __html: setFontForText(`#${item}`, hashTagStyle) } })))))));
@@ -15269,27 +15291,35 @@ function withBindDataSource(Component) {
15269
15291
  * @Author: binruan@chatlabs.com
15270
15292
  * @Date: 2023-12-26 16:11:34
15271
15293
  * @LastEditors: binruan@chatlabs.com
15272
- * @LastEditTime: 2024-07-17 18:54:33
15294
+ * @LastEditTime: 2024-07-25 18:47:37
15273
15295
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\RenderCard.tsx
15274
15296
  *
15275
15297
  */
15276
15298
  const RenderCard = ({ rec, index, tempMap, resolver, includesCtaType }) => {
15299
+ var _a, _b, _c, _d, _e;
15277
15300
  const { schema } = useEditor();
15301
+ if (!(rec === null || rec === void 0 ? void 0 : rec.video))
15302
+ return null;
15303
+ let cta = null;
15304
+ 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) {
15305
+ cta = '多商品CTA';
15306
+ }
15307
+ else if ((_c = rec === null || rec === void 0 ? void 0 : rec.video) === null || _c === void 0 ? void 0 : _c.bindProduct) {
15308
+ cta = '商品CTA';
15309
+ }
15310
+ else {
15311
+ 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;
15312
+ }
15313
+ const value = tempMap === null || tempMap === void 0 ? void 0 : tempMap[cta];
15278
15314
  const renderComp = React.useMemo(() => {
15279
15315
  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;
15280
15316
  if (!(rec === null || rec === void 0 ? void 0 : rec.video))
15281
15317
  return null;
15282
- let cta = null;
15283
- 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) {
15284
- cta = '多商品CTA';
15285
- }
15286
- else if ((_c = rec === null || rec === void 0 ? void 0 : rec.video) === null || _c === void 0 ? void 0 : _c.bindProduct) {
15287
- cta = '商品CTA';
15288
- }
15318
+ 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) ;
15319
+ else if ((_c = rec === null || rec === void 0 ? void 0 : rec.video) === null || _c === void 0 ? void 0 : _c.bindProduct) ;
15289
15320
  else {
15290
- 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;
15321
+ (_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;
15291
15322
  }
15292
- const value = tempMap === null || tempMap === void 0 ? void 0 : tempMap[cta];
15293
15323
  //如果includesCtaType有值,则只渲染includesCtaType包含的cta类型组件,用于在页面某处只显示某一组件
15294
15324
  if (includesCtaType && !(includesCtaType === null || includesCtaType === void 0 ? void 0 : includesCtaType.includes((_f = value === null || value === void 0 ? void 0 : value.item) === null || _f === void 0 ? void 0 : _f.type)))
15295
15325
  return;
@@ -15315,7 +15345,7 @@ const RenderCard = ({ rec, index, tempMap, resolver, includesCtaType }) => {
15315
15345
  else {
15316
15346
  return null;
15317
15347
  }
15318
- }, [rec, resolver, tempMap, schema]);
15348
+ }, [rec, resolver, tempMap, schema, value === null || value === void 0 ? void 0 : value.id]);
15319
15349
  return React.createElement(React.Fragment, null, renderComp);
15320
15350
  };
15321
15351
  var RenderCard$1 = React.memo(RenderCard);
@@ -15403,7 +15433,7 @@ var Tagbar$1 = React.memo(Tagbar);
15403
15433
  * @Author: binruan@chatlabs.com
15404
15434
  * @Date: 2024-01-15 19:03:09
15405
15435
  * @LastEditors: binruan@chatlabs.com
15406
- * @LastEditTime: 2024-07-24 14:59:23
15436
+ * @LastEditTime: 2024-07-25 17:10:01
15407
15437
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\index.tsx
15408
15438
  *
15409
15439
  */
@@ -15680,7 +15710,7 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
15680
15710
  return;
15681
15711
  const t = new Date() - curTime.current;
15682
15712
  if ((globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.openSlideSkip) && t >= ((_a = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.slideSkipStartTime) !== null && _a !== void 0 ? _a : 0) && getSlideSkipState() && item) {
15683
- const link = ((_c = (_b = item === null || item === void 0 ? void 0 : item.video) === null || _b === void 0 ? void 0 : _b.bindProduct) === null || _c === void 0 ? void 0 : _c.link) || ((_f = (_e = (_d = item === null || item === void 0 ? void 0 : item.video) === null || _d === void 0 ? void 0 : _d.bindProducts) === null || _e === void 0 ? void 0 : _e[0]) === null || _f === void 0 ? void 0 : _f.link) || ((_g = item === null || item === void 0 ? void 0 : item.product) === null || _g === void 0 ? void 0 : _g.link);
15713
+ const link = ((_d = (_c = (_b = item === null || item === void 0 ? void 0 : item.video) === null || _b === void 0 ? void 0 : _b.bindProducts) === null || _c === void 0 ? void 0 : _c[0]) === null || _d === void 0 ? void 0 : _d.link) || ((_f = (_e = item === null || item === void 0 ? void 0 : item.video) === null || _e === void 0 ? void 0 : _e.bindProduct) === null || _f === void 0 ? void 0 : _f.link) || ((_g = item === null || item === void 0 ? void 0 : item.product) === null || _g === void 0 ? void 0 : _g.link);
15684
15714
  const product = (item === null || item === void 0 ? void 0 : item.product) || ((_h = item === null || item === void 0 ? void 0 : item.video) === null || _h === void 0 ? void 0 : _h.bindProduct) || ((_k = (_j = item === null || item === void 0 ? void 0 : item.video) === null || _j === void 0 ? void 0 : _j.bindProducts) === null || _k === void 0 ? void 0 : _k[0]);
15685
15715
  if (link) {
15686
15716
  bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
@@ -16225,7 +16255,7 @@ var index$1 = React.memo(DiyPortalPreview);
16225
16255
  * @Author: binruan@chatlabs.com
16226
16256
  * @Date: 2023-10-31 10:56:01
16227
16257
  * @LastEditors: binruan@chatlabs.com
16228
- * @LastEditTime: 2024-07-19 18:06:14
16258
+ * @LastEditTime: 2024-07-25 17:15:36
16229
16259
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\Popup\index.tsx
16230
16260
  *
16231
16261
  */
@@ -16278,7 +16308,7 @@ const Popup = () => {
16278
16308
  const isExternalLink = ((_d = (_c = (_b = value === null || value === void 0 ? void 0 : value.item) === null || _b === void 0 ? void 0 : _b.event) === null || _c === void 0 ? void 0 : _c.onClick) === null || _d === void 0 ? void 0 : _d.linkType) === 'externalLink';
16279
16309
  const isPopup = ((_g = (_f = (_e = value === null || value === void 0 ? void 0 : value.item) === null || _e === void 0 ? void 0 : _e.event) === null || _f === void 0 ? void 0 : _f.onClick) === null || _g === void 0 ? void 0 : _g.linkType) === 'popup';
16280
16310
  const defaulSetting = (_h = t === null || t === void 0 ? void 0 : t.extend) === null || _h === void 0 ? void 0 : _h.defaulSetting;
16281
- return (React.createElement(Component, Object.assign({ key: index, style: Object.assign(Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.style), (_j = value === null || value === void 0 ? void 0 : value.item) === null || _j === void 0 ? void 0 : _j.style), { width: (_k = window.innerWidth) !== null && _k !== void 0 ? _k : '100vw' }), textStyle: Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.textStyle), (_l = value === null || value === void 0 ? void 0 : value.item) === null || _l === void 0 ? void 0 : _l.textStyle), bindDatas: (_o = (_m = value === null || value === void 0 ? void 0 : value.item) === null || _m === void 0 ? void 0 : _m.bindDatas) !== null && _o !== void 0 ? _o : [] }, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.props, (_p = value === null || value === void 0 ? void 0 : value.item) === null || _p === void 0 ? void 0 : _p.props, { event: ((_q = value === null || value === void 0 ? void 0 : value.item) === null || _q === void 0 ? void 0 : _q.event) || {}, schema: schema, id: value === null || value === void 0 ? void 0 : value.id, isExternalLink: isExternalLink, isPopup: isPopup, onClose: handleClose })));
16311
+ return (React.createElement(Component, Object.assign({ key: index, style: Object.assign(Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.style), (_j = value === null || value === void 0 ? void 0 : value.item) === null || _j === void 0 ? void 0 : _j.style), { width: (_k = window.innerWidth) !== null && _k !== void 0 ? _k : '100vw', height: '100%' }), textStyle: Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.textStyle), (_l = value === null || value === void 0 ? void 0 : value.item) === null || _l === void 0 ? void 0 : _l.textStyle), bindDatas: (_o = (_m = value === null || value === void 0 ? void 0 : value.item) === null || _m === void 0 ? void 0 : _m.bindDatas) !== null && _o !== void 0 ? _o : [] }, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.props, (_p = value === null || value === void 0 ? void 0 : value.item) === null || _p === void 0 ? void 0 : _p.props, { event: ((_q = value === null || value === void 0 ? void 0 : value.item) === null || _q === void 0 ? void 0 : _q.event) || {}, schema: schema, id: value === null || value === void 0 ? void 0 : value.id, isExternalLink: isExternalLink, isPopup: isPopup, onClose: handleClose })));
16282
16312
  }
16283
16313
  else {
16284
16314
  return React.createElement(React.Fragment, null);
@@ -16292,7 +16322,7 @@ const Popup = () => {
16292
16322
  * @Author: binruan@chatlabs.com
16293
16323
  * @Date: 2024-01-15 19:03:09
16294
16324
  * @LastEditors: binruan@chatlabs.com
16295
- * @LastEditTime: 2024-06-13 14:54:12
16325
+ * @LastEditTime: 2024-07-24 16:35:44
16296
16326
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageCore\index.tsx
16297
16327
  *
16298
16328
  */
@@ -16316,7 +16346,7 @@ const SxpPageCore = ({ data, maxSize = 10, defaultSize = 10, hashTagSize = 20, l
16316
16346
  return searchParams;
16317
16347
  }, []);
16318
16348
  return (React.createElement(EditorCore, { resolver: RESOLVER, enableDataSource: false, schema: data === null || data === void 0 ? void 0 : data.data, utmVal: utmVal },
16319
- React.createElement(SxpDataSourceProvider$1, { utmVal: utmVal, dataSources: data === null || data === void 0 ? void 0 : data.data_sources, sxpParameter: data === null || data === void 0 ? void 0 : data.sxp_parameter, maxSize: (_b = (_a = data === null || data === void 0 ? void 0 : data.sxp_parameter) === null || _a === void 0 ? void 0 : _a.personalized_recommend) !== null && _b !== void 0 ? _b : maxSize, defaultSize: (_d = (_c = data === null || data === void 0 ? void 0 : data.sxp_parameter) === null || _c === void 0 ? void 0 : _c.default_recommend) !== null && _d !== void 0 ? _d : defaultSize, hashTagSize: (_f = (_e = data === null || data === void 0 ? void 0 : data.sxp_parameter) === null || _e === void 0 ? void 0 : _e.hash_tag_size) !== null && _f !== void 0 ? _f : hashTagSize, loadingImage: loadingImage, appDomain: appDomain, enabledMetaConversionApi: enabledMetaConversionApi, isShowTag: (_j = (_h = (_g = data === null || data === void 0 ? void 0 : data.data) === null || _g === void 0 ? void 0 : _g.sxpPageConf) === null || _h === void 0 ? void 0 : _h.globalConfig) === null || _j === void 0 ? void 0 : _j.isShowTag, globalConfig: (_l = (_k = data === null || data === void 0 ? void 0 : data.data) === null || _k === void 0 ? void 0 : _k.sxpPageConf) === null || _l === void 0 ? void 0 : _l.globalConfig, render: ({ rtcList, tagList }) => {
16349
+ React.createElement(SxpDataSourceProvider$1, { utmVal: utmVal, dataSources: data === null || data === void 0 ? void 0 : data.data_sources, sxpParameter: data === null || data === void 0 ? void 0 : data.sxp_parameter, maxSize: (_b = (_a = data === null || data === void 0 ? void 0 : data.sxp_parameter) === null || _a === void 0 ? void 0 : _a.personalized_recommend) !== null && _b !== void 0 ? _b : maxSize, defaultSize: (_d = (_c = data === null || data === void 0 ? void 0 : data.sxp_parameter) === null || _c === void 0 ? void 0 : _c.default_recommend) !== null && _d !== void 0 ? _d : defaultSize, hashTagSize: (_f = (_e = data === null || data === void 0 ? void 0 : data.sxp_parameter) === null || _e === void 0 ? void 0 : _e.hash_tag_size) !== null && _f !== void 0 ? _f : hashTagSize, loadingImage: loadingImage, appDomain: appDomain, enabledMetaConversionApi: enabledMetaConversionApi, isShowTag: (_j = (_h = (_g = data === null || data === void 0 ? void 0 : data.data) === null || _g === void 0 ? void 0 : _g.sxpPageConf) === null || _h === void 0 ? void 0 : _h.globalConfig) === null || _j === void 0 ? void 0 : _j.isShowTag, globalConfig: (_l = (_k = data === null || data === void 0 ? void 0 : data.data) === null || _k === void 0 ? void 0 : _k.sxpPageConf) === null || _l === void 0 ? void 0 : _l.globalConfig, utmParameter: data === null || data === void 0 ? void 0 : data.utm_parameter, render: ({ rtcList, tagList }) => {
16320
16350
  var _a;
16321
16351
  return (React.createElement(React.Fragment, null,
16322
16352
  React.createElement(SxpPageRender, Object.assign({}, (_a = data === null || data === void 0 ? void 0 : data.data) === null || _a === void 0 ? void 0 : _a.sxpPageConf, { tagList: tagList, data: rtcList, resolver: RESOLVER, licenseUrl: licenseUrl })),