pb-sxp-ui 1.6.1 → 1.6.3

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 (43) hide show
  1. package/dist/index.cjs +27 -26
  2. package/dist/index.cjs.map +1 -1
  3. package/dist/index.js +27 -26
  4. package/dist/index.js.map +1 -1
  5. package/dist/index.min.cjs +3 -3
  6. package/dist/index.min.cjs.map +1 -1
  7. package/dist/index.min.js +3 -3
  8. package/dist/index.min.js.map +1 -1
  9. package/dist/pb-ui.js +27 -26
  10. package/dist/pb-ui.js.map +1 -1
  11. package/dist/pb-ui.min.js +3 -3
  12. package/dist/pb-ui.min.js.map +1 -1
  13. package/es/core/components/SxpPageRender/index.js +9 -8
  14. package/es/materials/sxp/cta/AniLink/index.d.ts +1 -0
  15. package/es/materials/sxp/cta/AniLink/index.js +3 -3
  16. package/es/materials/sxp/cta/AniLinkPopup/index.js +1 -1
  17. package/es/materials/sxp/template/Appoint/index.d.ts +1 -0
  18. package/es/materials/sxp/template/Appoint/index.js +2 -2
  19. package/es/materials/sxp/template/Commodity/index.d.ts +1 -0
  20. package/es/materials/sxp/template/Commodity/index.js +2 -2
  21. package/es/materials/sxp/template/CommodityDiro/index.d.ts +1 -0
  22. package/es/materials/sxp/template/CommodityDiro/index.js +2 -2
  23. package/es/materials/sxp/template/CommodityDiroNew/index.d.ts +1 -0
  24. package/es/materials/sxp/template/CommodityDiroNew/index.js +2 -2
  25. package/es/materials/sxp/template/Link/index.d.ts +1 -0
  26. package/es/materials/sxp/template/Link/index.js +2 -2
  27. package/es/materials/sxp/template/components/Img.js +2 -2
  28. package/lib/core/components/SxpPageRender/index.js +9 -8
  29. package/lib/materials/sxp/cta/AniLink/index.d.ts +1 -0
  30. package/lib/materials/sxp/cta/AniLink/index.js +3 -3
  31. package/lib/materials/sxp/cta/AniLinkPopup/index.js +1 -1
  32. package/lib/materials/sxp/template/Appoint/index.d.ts +1 -0
  33. package/lib/materials/sxp/template/Appoint/index.js +2 -2
  34. package/lib/materials/sxp/template/Commodity/index.d.ts +1 -0
  35. package/lib/materials/sxp/template/Commodity/index.js +2 -2
  36. package/lib/materials/sxp/template/CommodityDiro/index.d.ts +1 -0
  37. package/lib/materials/sxp/template/CommodityDiro/index.js +2 -2
  38. package/lib/materials/sxp/template/CommodityDiroNew/index.d.ts +1 -0
  39. package/lib/materials/sxp/template/CommodityDiroNew/index.js +2 -2
  40. package/lib/materials/sxp/template/Link/index.d.ts +1 -0
  41. package/lib/materials/sxp/template/Link/index.js +2 -2
  42. package/lib/materials/sxp/template/components/Img.js +2 -2
  43. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -10816,7 +10816,7 @@ function useOnScreen(ref) {
10816
10816
  * @Author: binruan@chatlabs.com
10817
10817
  * @Date: 2024-01-16 14:50:13
10818
10818
  * @LastEditors: binruan@chatlabs.com
10819
- * @LastEditTime: 2024-10-12 18:04:36
10819
+ * @LastEditTime: 2024-10-12 18:31:19
10820
10820
  * @FilePath: \pb-sxp-ui\src\materials\sxp\template\components\Img.tsx
10821
10821
  *
10822
10822
  */
@@ -10826,14 +10826,14 @@ const Img = ({ src, rec, item, index, style, translateY, imgStyle, enableEventRe
10826
10826
  const { ctaEvent } = useSxpDataSource();
10827
10827
  const [visible, setVisible] = useState(false);
10828
10828
  useEffect(() => {
10829
- if (isOnScreen && src && (ref === null || ref === void 0 ? void 0 : ref.current) && enableEventReport && !visible) {
10829
+ if (isOnScreen && src && (ref === null || ref === void 0 ? void 0 : ref.current) && enableEventReport && !visible && isActive) {
10830
10830
  setVisible(true);
10831
10831
  ctaEvent === null || ctaEvent === void 0 ? void 0 : ctaEvent({
10832
10832
  eventSubject: 'ctaExposure',
10833
10833
  eventDescription: 'The cta was shown to the user'
10834
10834
  }, rec, item, index);
10835
10835
  }
10836
- }, [isOnScreen, src, ref, rec, ctaEvent, item, index, enableEventReport, visible]);
10836
+ }, [isOnScreen, src, ref, rec, ctaEvent, item, index, enableEventReport, visible, isActive]);
10837
10837
  useMemo(() => {
10838
10838
  return (src === null || src === void 0 ? void 0 : src.includes('.avif')) ? src : `${src}?imrquality/rquality/20`;
10839
10839
  }, [src]);
@@ -11357,12 +11357,12 @@ var styles$8 = {"tow-line-ellipsis":"index-module_tow-line-ellipsis__3bKKx"};
11357
11357
 
11358
11358
  const Commodity$1 = (_a) => {
11359
11359
  var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
11360
- var { content, style, bgImg, recData, bottom_image, ctaTempStyles, isExternalLink, translateY = 0, index } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "bottom_image", "ctaTempStyles", "isExternalLink", "translateY", "index"]);
11360
+ var { content, style, bgImg, recData, bottom_image, ctaTempStyles, isExternalLink, translateY = 0, index, isActive } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "bottom_image", "ctaTempStyles", "isExternalLink", "translateY", "index", "isActive"]);
11361
11361
  const { sxpParameter } = useSxpDataSource();
11362
11362
  const product = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindProduct;
11363
11363
  const src = (_f = (_e = (_c = product === null || product === void 0 ? void 0 : product.cover) !== null && _c !== void 0 ? _c : (_d = product === null || product === void 0 ? void 0 : product.homePage) === null || _d === void 0 ? void 0 : _d[0]) !== null && _e !== void 0 ? _e : sxpParameter === null || sxpParameter === void 0 ? void 0 : sxpParameter.bottom_image) !== null && _f !== void 0 ? _f : bottom_image;
11364
11364
  return (React.createElement(EventProvider$1, Object.assign({ isExternalLink: isExternalLink, rec: recData, className: css(Object.assign({}, style)), style: { display: 'flex' }, index: index }, props),
11365
- React.createElement(Img$1, { src: src, rec: recData, item: (_h = (_g = recData === null || recData === void 0 ? void 0 : recData.video) === null || _g === void 0 ? void 0 : _g.bindProduct) !== null && _h !== void 0 ? _h : recData === null || recData === void 0 ? void 0 : recData.video, index: index, translateY: translateY, imgStyle: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img }),
11365
+ React.createElement(Img$1, { src: src, rec: recData, item: (_h = (_g = recData === null || recData === void 0 ? void 0 : recData.video) === null || _g === void 0 ? void 0 : _g.bindProduct) !== null && _h !== void 0 ? _h : recData === null || recData === void 0 ? void 0 : recData.video, index: index, translateY: translateY, imgStyle: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img, isActive: isActive }),
11366
11366
  React.createElement("div", { className: css({
11367
11367
  color: '#fff',
11368
11368
  display: 'flex',
@@ -11451,12 +11451,12 @@ var interactionRender$8 = [
11451
11451
 
11452
11452
  const Appoint$1 = (_a) => {
11453
11453
  var _b, _c, _d, _e, _f, _g;
11454
- var { content, style, bgImg, recData, bottom_image, ctaTempStyles, isExternalLink, index } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "bottom_image", "ctaTempStyles", "isExternalLink", "index"]);
11454
+ var { content, style, bgImg, recData, bottom_image, ctaTempStyles, isExternalLink, index, isActive } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "bottom_image", "ctaTempStyles", "isExternalLink", "index", "isActive"]);
11455
11455
  const { sxpParameter } = useSxpDataSource();
11456
11456
  const cta = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindCta;
11457
11457
  const src = (_d = (_c = cta === null || cta === void 0 ? void 0 : cta.icon) !== null && _c !== void 0 ? _c : sxpParameter === null || sxpParameter === void 0 ? void 0 : sxpParameter.bottom_image) !== null && _d !== void 0 ? _d : bottom_image;
11458
11458
  return (React.createElement(EventProvider$1, Object.assign({ isExternalLink: isExternalLink, rec: recData, className: css(Object.assign({ alignItems: 'center' }, style)), style: { display: 'flex' }, index: index }, props),
11459
- React.createElement(Img$1, { src: src, rec: recData, item: (_f = (_e = recData === null || recData === void 0 ? void 0 : recData.video) === null || _e === void 0 ? void 0 : _e.bindProduct) !== null && _f !== void 0 ? _f : recData === null || recData === void 0 ? void 0 : recData.video, index: index, imgStyle: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img }),
11459
+ React.createElement(Img$1, { src: src, rec: recData, item: (_f = (_e = recData === null || recData === void 0 ? void 0 : recData.video) === null || _e === void 0 ? void 0 : _e.bindProduct) !== null && _f !== void 0 ? _f : recData === null || recData === void 0 ? void 0 : recData.video, index: index, imgStyle: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img, isActive: isActive }),
11460
11460
  React.createElement("div", { className: css(Object.assign({ overflow: 'hidden', textOverflow: 'ellipsis' }, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)), dangerouslySetInnerHTML: {
11461
11461
  __html: setFontForText((_g = cta === null || cta === void 0 ? void 0 : cta.enTitle) !== null && _g !== void 0 ? _g : 'Product Name', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
11462
11462
  } })));
@@ -11633,14 +11633,14 @@ var styles$7 = {"tow-line-ellipsis":"index-module_tow-line-ellipsis__nkBlU","one
11633
11633
 
11634
11634
  const Link$1 = (_a) => {
11635
11635
  var _b, _c, _d, _e, _f, _g, _h, _j, _k;
11636
- var { content, style, bgImg, recData, bottom_image, ctaTempStyles, index, customTitle } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "bottom_image", "ctaTempStyles", "index", "customTitle"]);
11636
+ var { content, style, bgImg, recData, bottom_image, ctaTempStyles, index, customTitle, isActive } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "bottom_image", "ctaTempStyles", "index", "customTitle", "isActive"]);
11637
11637
  const { sxpParameter, bffEventReport } = useSxpDataSource();
11638
11638
  useEventReport();
11639
11639
  const cta = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindCta;
11640
11640
  (_c = recData === null || recData === void 0 ? void 0 : recData.video) === null || _c === void 0 ? void 0 : _c.bindProduct;
11641
11641
  const src = (_e = (_d = cta === null || cta === void 0 ? void 0 : cta.icon) !== null && _d !== void 0 ? _d : sxpParameter === null || sxpParameter === void 0 ? void 0 : sxpParameter.bottom_image) !== null && _e !== void 0 ? _e : bottom_image;
11642
11642
  return (React.createElement(EventProvider$1, Object.assign({ index: index, rec: recData, className: css(Object.assign({ alignItems: 'center' }, style)), style: { display: 'flex' } }, props, { jumpLink: (_f = cta === null || cta === void 0 ? void 0 : cta.link) !== null && _f !== void 0 ? _f : '' }),
11643
- React.createElement(Img$1, { src: src, rec: recData, item: (_h = (_g = recData === null || recData === void 0 ? void 0 : recData.video) === null || _g === void 0 ? void 0 : _g.bindProduct) !== null && _h !== void 0 ? _h : recData === null || recData === void 0 ? void 0 : recData.video, index: index, imgStyle: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img }),
11643
+ React.createElement(Img$1, { src: src, rec: recData, item: (_h = (_g = recData === null || recData === void 0 ? void 0 : recData.video) === null || _g === void 0 ? void 0 : _g.bindProduct) !== null && _h !== void 0 ? _h : recData === null || recData === void 0 ? void 0 : recData.video, index: index, imgStyle: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img, isActive: isActive }),
11644
11644
  React.createElement("div", { className: css({
11645
11645
  display: 'flex',
11646
11646
  alignItems: 'center',
@@ -11750,12 +11750,12 @@ var styles$6 = {"tow-line-ellipsis":"index-module_tow-line-ellipsis__yyHVb"};
11750
11750
 
11751
11751
  const CommodityDiro$1 = (_a) => {
11752
11752
  var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
11753
- var { content, style, bgImg, recData, bottom_image, ctaTempStyles, isExternalLink, translateY = 0, index } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "bottom_image", "ctaTempStyles", "isExternalLink", "translateY", "index"]);
11753
+ var { content, style, bgImg, recData, bottom_image, ctaTempStyles, isExternalLink, translateY = 0, index, isActive } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "bottom_image", "ctaTempStyles", "isExternalLink", "translateY", "index", "isActive"]);
11754
11754
  const { sxpParameter } = useSxpDataSource();
11755
11755
  const product = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindProduct;
11756
11756
  const src = (_f = (_e = (_c = product === null || product === void 0 ? void 0 : product.cover) !== null && _c !== void 0 ? _c : (_d = product === null || product === void 0 ? void 0 : product.homePage) === null || _d === void 0 ? void 0 : _d[0]) !== null && _e !== void 0 ? _e : sxpParameter === null || sxpParameter === void 0 ? void 0 : sxpParameter.bottom_image) !== null && _f !== void 0 ? _f : bottom_image;
11757
11757
  return (React.createElement(EventProvider$1, Object.assign({ isExternalLink: isExternalLink, rec: recData, className: css(Object.assign({}, style)), style: { display: 'flex' }, index: index }, props),
11758
- React.createElement(Img$1, { src: src, rec: recData, item: (_h = (_g = recData === null || recData === void 0 ? void 0 : recData.video) === null || _g === void 0 ? void 0 : _g.bindProduct) !== null && _h !== void 0 ? _h : recData === null || recData === void 0 ? void 0 : recData.video, index: index, translateY: translateY, imgStyle: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img }),
11758
+ React.createElement(Img$1, { src: src, rec: recData, item: (_h = (_g = recData === null || recData === void 0 ? void 0 : recData.video) === null || _g === void 0 ? void 0 : _g.bindProduct) !== null && _h !== void 0 ? _h : recData === null || recData === void 0 ? void 0 : recData.video, index: index, translateY: translateY, imgStyle: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img, isActive: isActive }),
11759
11759
  React.createElement("div", { className: css({
11760
11760
  color: '#fff',
11761
11761
  display: 'flex',
@@ -11846,12 +11846,12 @@ var styles$5 = {"tow-line-ellipsis":"index-module_tow-line-ellipsis__I-yCC"};
11846
11846
 
11847
11847
  const CommodityDiroNew$1 = (_a) => {
11848
11848
  var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
11849
- var { content, style, bgImg, recData, bottom_image, ctaTempStyles, isExternalLink, translateY = 0, index } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "bottom_image", "ctaTempStyles", "isExternalLink", "translateY", "index"]);
11849
+ var { content, style, bgImg, recData, bottom_image, ctaTempStyles, isExternalLink, translateY = 0, index, isActive } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "bottom_image", "ctaTempStyles", "isExternalLink", "translateY", "index", "isActive"]);
11850
11850
  const { sxpParameter } = useSxpDataSource();
11851
11851
  const product = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindProduct;
11852
11852
  const src = (_f = (_e = (_c = product === null || product === void 0 ? void 0 : product.cover) !== null && _c !== void 0 ? _c : (_d = product === null || product === void 0 ? void 0 : product.homePage) === null || _d === void 0 ? void 0 : _d[0]) !== null && _e !== void 0 ? _e : sxpParameter === null || sxpParameter === void 0 ? void 0 : sxpParameter.bottom_image) !== null && _f !== void 0 ? _f : bottom_image;
11853
11853
  return (React.createElement(EventProvider$1, Object.assign({ isExternalLink: isExternalLink, rec: recData, className: css(Object.assign({}, style)), style: { display: 'flex' }, index: index }, props),
11854
- React.createElement(Img$1, { src: src, rec: recData, item: (_h = (_g = recData === null || recData === void 0 ? void 0 : recData.video) === null || _g === void 0 ? void 0 : _g.bindProduct) !== null && _h !== void 0 ? _h : recData === null || recData === void 0 ? void 0 : recData.video, index: index, translateY: translateY, imgStyle: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img }),
11854
+ React.createElement(Img$1, { src: src, rec: recData, item: (_h = (_g = recData === null || recData === void 0 ? void 0 : recData.video) === null || _g === void 0 ? void 0 : _g.bindProduct) !== null && _h !== void 0 ? _h : recData === null || recData === void 0 ? void 0 : recData.video, index: index, translateY: translateY, imgStyle: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img, isActive: isActive }),
11855
11855
  React.createElement("div", { className: css({
11856
11856
  color: '#fff',
11857
11857
  display: 'flex',
@@ -14779,7 +14779,7 @@ var styles$1 = {"animated-button":"index-module_animated-button__lqTbg","gradien
14779
14779
 
14780
14780
  const AniLink$1 = (_a) => {
14781
14781
  var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
14782
- var { style, recData, ctaTempStyles, index, event, onClick, isExternalLink = false } = _a, props = __rest(_a, ["style", "recData", "ctaTempStyles", "index", "event", "onClick", "isExternalLink"]);
14782
+ var { style, recData, ctaTempStyles, index, event, onClick, isExternalLink = false, isActive } = _a, props = __rest(_a, ["style", "recData", "ctaTempStyles", "index", "event", "onClick", "isExternalLink", "isActive"]);
14783
14783
  const { ctaEvent, setPopupDetailData } = useSxpDataSource();
14784
14784
  const { jumpToWeb } = useEventReport();
14785
14785
  const [visible, setVisible] = useState(false);
@@ -14823,13 +14823,13 @@ const AniLink$1 = (_a) => {
14823
14823
  }, [event === null || event === void 0 ? void 0 : event.animation]);
14824
14824
  useEffect(() => {
14825
14825
  var _a, _b, _c;
14826
- if (isOnScreen && (ref === null || ref === void 0 ? void 0 : ref.current)) {
14826
+ if (isOnScreen && (ref === null || ref === void 0 ? void 0 : ref.current) && isActive) {
14827
14827
  ctaEvent === null || ctaEvent === void 0 ? void 0 : ctaEvent({
14828
14828
  eventSubject: 'ctaExposure',
14829
14829
  eventDescription: 'The cta was shown to the user'
14830
14830
  }, recData, ((_b = (_a = recData === null || recData === void 0 ? void 0 : recData.video) === null || _a === void 0 ? void 0 : _a.bindProducts) === null || _b === void 0 ? void 0 : _b[0]) || ((_c = recData === null || recData === void 0 ? void 0 : recData.video) === null || _c === void 0 ? void 0 : _c.bindProduct) || (recData === null || recData === void 0 ? void 0 : recData.video), index);
14831
14831
  }
14832
- }, [isOnScreen]);
14832
+ }, [isOnScreen, isActive]);
14833
14833
  useEffect(() => {
14834
14834
  if (isOnScreen) {
14835
14835
  setVisible(true);
@@ -15278,7 +15278,7 @@ const AniLinkPopup$1 = (_a) => {
15278
15278
  } }, "Cta Title")) : (React.createElement("div", Object.assign({}, props, { className: `${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(aniTimStyle)}`, onClick: handleTo }),
15279
15279
  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 } },
15280
15280
  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'] })),
15281
- 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 }),
15281
+ 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, isActive: isActive }),
15282
15282
  (!recData || (product === null || product === void 0 ? void 0 : product.title)) && (React.createElement("div", { className: styles['one-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
15283
15283
  __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)
15284
15284
  } })),
@@ -16295,12 +16295,12 @@ var Tagbar$1 = memo(Tagbar);
16295
16295
  * @Author: binruan@chatlabs.com
16296
16296
  * @Date: 2024-01-15 19:03:09
16297
16297
  * @LastEditors: binruan@chatlabs.com
16298
- * @LastEditTime: 2024-10-12 15:27:17
16298
+ * @LastEditTime: 2024-10-15 14:37:11
16299
16299
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\index.tsx
16300
16300
  *
16301
16301
  */
16302
16302
  const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.innerHeight, containerWidth = window.innerWidth, tempMap, resolver, data = [], ctaType, tipText, nudge, _schema, hashTagStyle, tagList = [], licenseUrl }) => {
16303
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v;
16303
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w;
16304
16304
  const mutedIcon = useIconLink('/pb_static/5beaaa5ce7f3477b99db3838619cc471.png');
16305
16305
  const unmutedIcon = useIconLink('/pb_static/fea8668a8a894e4aa3a86bcc775e895e.png');
16306
16306
  const { schema } = useEditor();
@@ -16456,10 +16456,10 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
16456
16456
  minusHeight += 56;
16457
16457
  }
16458
16458
  return minusHeight;
16459
- }, []);
16459
+ }, [globalConfig]);
16460
16460
  const height = useMemo(() => {
16461
16461
  return containerHeight - minusHeight - tagHeight;
16462
- }, [globalConfig, containerHeight, tagHeight]);
16462
+ }, [minusHeight, containerHeight, tagHeight]);
16463
16463
  const visList = useMemo(() => {
16464
16464
  var _a;
16465
16465
  const list = activeIndex === 0 && !waterFallData && !isEditor
@@ -16552,7 +16552,7 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
16552
16552
  React.createElement(RenderCard$1, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, isActive: index === activeIndex }))) : null,
16553
16553
  React.createElement("div", null,
16554
16554
  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: (_d = (_c = rec === null || rec === void 0 ? void 0 : rec.video) === null || _c === void 0 ? void 0 : _c.title) !== null && _d !== void 0 ? _d : '', 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 }),
16555
- React.createElement(RenderCard$1, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, includesCtaType: ['AniLink'] }),
16555
+ React.createElement(RenderCard$1, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, includesCtaType: ['AniLink'], isActive: index === activeIndex }),
16556
16556
  React.createElement(Hashtag$1, { index: activeIndex, tags: (_f = (_e = rec === null || rec === void 0 ? void 0 : rec.video) === null || _e === void 0 ? void 0 : _e.hashTags) !== null && _f !== void 0 ? _f : [], itemId: (_g = rec === null || rec === void 0 ? void 0 : rec.video) === null || _g === void 0 ? void 0 : _g.itemId, itemType: ((_h = rec === null || rec === void 0 ? void 0 : rec.video) === null || _h === void 0 ? void 0 : _h.itemId) ? 'VIDEO' : null, rec: rec, hashTagStyle: hashTagStyle }))),
16557
16557
  React.createElement(RenderCard$1, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, includesCtaType: ['AniLinkPopup'], isActive: index === activeIndex })));
16558
16558
  }
@@ -16796,14 +16796,15 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
16796
16796
  ((_f = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.backButton) === null || _f === void 0 ? void 0 : _f.enable) && (React.createElement("button", { style: {
16797
16797
  position: 'absolute',
16798
16798
  [(_h = (_g = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.backButton) === null || _g === void 0 ? void 0 : _g.xPosit) !== null && _h !== void 0 ? _h : 'left']: (_k = (_j = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.backButton) === null || _j === void 0 ? void 0 : _j.x) !== null && _k !== void 0 ? _k : 0,
16799
- [(_m = (_l = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.backButton) === null || _l === void 0 ? void 0 : _l.yPosit) !== null && _m !== void 0 ? _m : 'top']: (_p = (_o = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.backButton) === null || _o === void 0 ? void 0 : _o.y) !== null && _p !== void 0 ? _p : 0,
16799
+ [(_m = (_l = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.backButton) === null || _l === void 0 ? void 0 : _l.yPosit) !== null && _m !== void 0 ? _m : 'top']: (((_o = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.backButton) === null || _o === void 0 ? void 0 : _o.yPosit) == 'top' ? minusHeight + tagHeight : 0) +
16800
+ ((_q = (_p = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.backButton) === null || _p === void 0 ? void 0 : _p.y) !== null && _q !== void 0 ? _q : 0),
16800
16801
  zIndex: 8,
16801
16802
  border: 'none',
16802
16803
  padding: 0,
16803
16804
  background: 'transparent'
16804
16805
  }, role: 'button', "aria-label": 'back button', onClick: () => history === null || history === void 0 ? void 0 : history.back() },
16805
- React.createElement("img", { src: (_r = (_q = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.backButton) === null || _q === void 0 ? void 0 : _q.icon) !== null && _r !== void 0 ? _r : img, alt: 'back button', width: 50, style: { objectFit: 'cover' } }))),
16806
- isShowFingerTip ? (React.createElement(FingerSwipeTip, { imageUrl: globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.swipeTipIcon, style: { top: `${50 - ((_s = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.swipeTipOffset) !== null && _s !== void 0 ? _s : 0)}%` }, duration: globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.swiperTipAniDur })) : null,
16806
+ React.createElement("img", { src: (_s = (_r = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.backButton) === null || _r === void 0 ? void 0 : _r.icon) !== null && _s !== void 0 ? _s : img, alt: 'back button', width: 50, style: { objectFit: 'cover' } }))),
16807
+ isShowFingerTip ? (React.createElement(FingerSwipeTip, { imageUrl: globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.swipeTipIcon, style: { top: `${50 - ((_t = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.swipeTipOffset) !== null && _t !== void 0 ? _t : 0)}%` }, duration: globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.swiperTipAniDur })) : null,
16807
16808
  React.createElement(Swiper, { style: {
16808
16809
  marginTop: tagHeight
16809
16810
  }, ref: swiperRef, onSlideChange: () => {
@@ -16835,7 +16836,7 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
16835
16836
  renderLikeButton(visList[activeIndex], activeIndex, !!(globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.likeIconFixed)),
16836
16837
  renderToggleButton(!!(globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.muteIconFixed)),
16837
16838
  renderView),
16838
- React.createElement(WaterFall$1, Object.assign({}, (_v = (_u = (_t = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.hashTag) === null || _t === void 0 ? void 0 : _t[0]) === null || _u === void 0 ? void 0 : _u.item) === null || _v === void 0 ? void 0 : _v.props))));
16839
+ React.createElement(WaterFall$1, Object.assign({}, (_w = (_v = (_u = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.hashTag) === null || _u === void 0 ? void 0 : _u[0]) === null || _v === void 0 ? void 0 : _v.item) === null || _w === void 0 ? void 0 : _w.props))));
16839
16840
  };
16840
16841
 
16841
16842
  const PictureGroup = ({ imgUrls, width, height, imgUrlsPostConfig, rec, index }) => {