pb-sxp-ui 1.3.5 → 1.3.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. package/dist/index.cjs +40 -16
  2. package/dist/index.cjs.map +1 -1
  3. package/dist/index.js +40 -16
  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 +40 -16
  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/Popup/index.js +15 -1
  14. package/es/materials/sxp/popup/CommodityDetail/index.d.ts +1 -0
  15. package/es/materials/sxp/popup/CommodityDetail/index.js +4 -4
  16. package/es/materials/sxp/popup/CommodityDetail/settingRender.d.ts +7 -2
  17. package/es/materials/sxp/popup/CommodityDetail/settingRender.js +6 -1
  18. package/es/materials/sxp/popup/CommodityDetailDiroNew/index.d.ts +1 -0
  19. package/es/materials/sxp/popup/CommodityDetailDiroNew/index.js +4 -4
  20. package/es/materials/sxp/popup/CommodityDetailDiroNew/settingRender.d.ts +7 -2
  21. package/es/materials/sxp/popup/CommodityDetailDiroNew/settingRender.js +6 -1
  22. package/es/materials/sxp/popup/Iframe/index.js +2 -2
  23. package/lib/core/components/SxpPageRender/Popup/index.js +15 -1
  24. package/lib/materials/sxp/popup/CommodityDetail/index.d.ts +1 -0
  25. package/lib/materials/sxp/popup/CommodityDetail/index.js +4 -4
  26. package/lib/materials/sxp/popup/CommodityDetail/settingRender.d.ts +7 -2
  27. package/lib/materials/sxp/popup/CommodityDetail/settingRender.js +6 -1
  28. package/lib/materials/sxp/popup/CommodityDetailDiroNew/index.d.ts +1 -0
  29. package/lib/materials/sxp/popup/CommodityDetailDiroNew/index.js +4 -4
  30. package/lib/materials/sxp/popup/CommodityDetailDiroNew/settingRender.d.ts +7 -2
  31. package/lib/materials/sxp/popup/CommodityDetailDiroNew/settingRender.js +6 -1
  32. package/lib/materials/sxp/popup/Iframe/index.js +2 -2
  33. package/package.json +1 -1
package/dist/pb-ui.js CHANGED
@@ -1992,7 +1992,12 @@
1992
1992
  label: '弹窗按钮',
1993
1993
  type: 'Upload',
1994
1994
  name: ['props', 'iframeIcon'],
1995
- text: '建议尺寸:106 * 41'
1995
+ text: '建议尺寸:72 * 30'
1996
+ },
1997
+ {
1998
+ label: '背景色',
1999
+ type: 'Color',
2000
+ name: ['props', 'iframeBgColor']
1996
2001
  }
1997
2002
  ]
1998
2003
  }
@@ -9124,7 +9129,7 @@
9124
9129
 
9125
9130
  const CommodityDetail$1 = (_a) => {
9126
9131
  var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z;
9127
- var { content, style, bgImg, onClick, schema, isDefault, bottom_image, tipText, isPost, viewTime, rec, swiper, commodityStyles, buttonStyle, index, commodityGroup, popupBg, iframeIcon, commodityImgRatio, isTel } = _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"]);
9132
+ var { content, style, bgImg, onClick, schema, isDefault, bottom_image, tipText, isPost, viewTime, rec, swiper, commodityStyles, buttonStyle, index, commodityGroup, popupBg, iframeIcon, commodityImgRatio, isTel, iframeBgColor } = _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"]);
9128
9133
  const { sxpParameter, popupDetailData, isPreview, bffFbReport, popupCurTimeRef, checkCommodityIndexRef } = useSxpDataSource();
9129
9134
  const { jumpToWeb, productView } = useEventReport();
9130
9135
  const curTimeRef = React.useRef(null);
@@ -9290,7 +9295,7 @@
9290
9295
  background: '#fff',
9291
9296
  borderRadius: '3px'
9292
9297
  }, onClick: () => setShow3DModal(true) },
9293
- React.createElement("img", { src: iframeIcon, alt: '3d', width: '60px' })))),
9298
+ React.createElement("img", { src: iframeIcon, alt: '3d', width: '72px' })))),
9294
9299
  renderCommodityGroup(),
9295
9300
  React.createElement("div", { className: 'pb-commondity-content' }, renderContent({ isPost }))),
9296
9301
  renderBtn(),
@@ -9298,10 +9303,10 @@
9298
9303
  React.createElement("div", { style: { paddingBottom: '80px' } }, renderContent({ isPost: false })),
9299
9304
  renderBtn()),
9300
9305
  React.createElement(Modal$1, { visible: show3DModal, padding: 0, isFullScreen: true, onClose: () => setShow3DModal(false) },
9301
- React.createElement("div", { style: { height: window.innerHeight } },
9306
+ React.createElement("div", { style: { backgroundColor: iframeBgColor, height: '100%' } },
9302
9307
  React.createElement("iframe", { src: iframeUrl, style: {
9303
9308
  width: '100%',
9304
- height: isTel ? `${664 - 50}px` : `${window.innerHeight - 50}px`,
9309
+ height: 'calc(100% - 50px)',
9305
9310
  marginTop: '50px',
9306
9311
  border: 'none'
9307
9312
  } })))));
@@ -9643,7 +9648,7 @@
9643
9648
  * @Author: binruan@chatlabs.com
9644
9649
  * @Date: 2024-03-26 16:50:25
9645
9650
  * @LastEditors: binruan@chatlabs.com
9646
- * @LastEditTime: 2024-08-20 15:50:06
9651
+ * @LastEditTime: 2024-08-23 10:58:38
9647
9652
  * @FilePath: \pb-sxp-ui\src\materials\sxp\popup\CommodityDetailDiroNew\settingRender.tsx
9648
9653
  *
9649
9654
  */
@@ -9950,7 +9955,12 @@
9950
9955
  label: '弹窗按钮',
9951
9956
  type: 'Upload',
9952
9957
  name: ['props', 'iframeIcon'],
9953
- text: '建议尺寸:106 * 41'
9958
+ text: '建议尺寸:72 * 30'
9959
+ },
9960
+ {
9961
+ label: '背景色',
9962
+ type: 'Color',
9963
+ name: ['props', 'iframeBgColor']
9954
9964
  }
9955
9965
  ]
9956
9966
  }
@@ -9958,7 +9968,7 @@
9958
9968
 
9959
9969
  const CommodityDetailDiroNew$1 = (_a) => {
9960
9970
  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;
9961
- var { style, isDefault, rec, viewTime, isPost, bottom_image, tipText, swiper, commodityStyles, buttonStyle, index, commodityGroup, popupBg, iframeIcon, commodityImgRatio, isTel } = _a, props = __rest(_a, ["style", "isDefault", "rec", "viewTime", "isPost", "bottom_image", "tipText", "swiper", "commodityStyles", "buttonStyle", "index", "commodityGroup", "popupBg", "iframeIcon", "commodityImgRatio", "isTel"]);
9971
+ var { style, isDefault, rec, viewTime, isPost, bottom_image, tipText, swiper, commodityStyles, buttonStyle, index, commodityGroup, popupBg, iframeIcon, commodityImgRatio, isTel, iframeBgColor } = _a, props = __rest(_a, ["style", "isDefault", "rec", "viewTime", "isPost", "bottom_image", "tipText", "swiper", "commodityStyles", "buttonStyle", "index", "commodityGroup", "popupBg", "iframeIcon", "commodityImgRatio", "isTel", "iframeBgColor"]);
9962
9972
  React.useState(true);
9963
9973
  const { sxpParameter, popupCurTimeRef, popupDetailData, isPreview, bffFbReport, checkCommodityIndexRef } = useSxpDataSource();
9964
9974
  const { jumpToWeb, productView } = useEventReport();
@@ -10154,7 +10164,7 @@ Made in Italy` })));
10154
10164
  background: '#fff',
10155
10165
  borderRadius: '3px'
10156
10166
  }, onClick: () => setShow3DModal(true) },
10157
- React.createElement("img", { src: iframeIcon, alt: '3d', width: '60px' })))),
10167
+ React.createElement("img", { src: iframeIcon, alt: '3d', width: '72px' })))),
10158
10168
  renderCommodityGroup(),
10159
10169
  React.createElement("div", { className: 'pb-commondityDiroNew-content' },
10160
10170
  React.createElement("div", { className: 'pb-commondityDiroNew-content-top' },
@@ -10179,10 +10189,10 @@ Made in Italy` })));
10179
10189
  productInfoText({ isPost }))),
10180
10190
  React.createElement(Modal$1, { visible: showModal, onClose: () => setShowModal(false) }, productInfoText({ isPost: false })),
10181
10191
  React.createElement(Modal$1, { visible: show3DModal, padding: 0, isFullScreen: true, onClose: () => setShow3DModal(false) },
10182
- React.createElement("div", { style: { height: window.innerHeight } },
10192
+ React.createElement("div", { style: { backgroundColor: iframeBgColor, height: '100%' } },
10183
10193
  React.createElement("iframe", { src: iframeUrl, style: {
10184
10194
  width: '100%',
10185
- height: isTel ? `${664 - 50}px` : `${window.innerHeight - 50}px`,
10195
+ height: 'calc(100% - 50px)',
10186
10196
  marginTop: '50px',
10187
10197
  border: 'none'
10188
10198
  } })))));
@@ -10778,11 +10788,11 @@ Made in Italy` })));
10778
10788
  var { content, btnText, style, icon, isPopup, isExternalLink, onClose, onClick, submitButtonStyle, contentStyle, isTel } = _a, props = __rest(_a, ["content", "btnText", "style", "icon", "isPopup", "isExternalLink", "onClose", "onClick", "submitButtonStyle", "contentStyle", "isTel"]);
10779
10789
  const { popupDetailData } = useSxpDataSource();
10780
10790
  const iframeUrl = (_c = (_b = popupDetailData === null || popupDetailData === void 0 ? void 0 : popupDetailData.video) === null || _b === void 0 ? void 0 : _b.bindCta) === null || _c === void 0 ? void 0 : _c.remark;
10781
- return (React.createElement("div", Object.assign({ className: `${css.css(Object.assign(Object.assign({}, style), { height: isTel ? 664 : window === null || window === void 0 ? void 0 : window.innerHeight }))}` }, props),
10791
+ return (React.createElement("div", Object.assign({ className: `${css.css(Object.assign({}, style))}` }, props),
10782
10792
  React.createElement("iframe", { src: iframeUrl, style: {
10783
10793
  width: '100%',
10784
10794
  height: 'calc(100% - 50px)',
10785
- marginTop: '40px',
10795
+ marginTop: '50px',
10786
10796
  border: 'none'
10787
10797
  } })));
10788
10798
  };
@@ -16019,7 +16029,7 @@ Made in Italy` })));
16019
16029
  * @Author: binruan@chatlabs.com
16020
16030
  * @Date: 2024-01-15 19:03:09
16021
16031
  * @LastEditors: binruan@chatlabs.com
16022
- * @LastEditTime: 2024-08-22 18:34:01
16032
+ * @LastEditTime: 2024-08-23 11:35:02
16023
16033
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\index.tsx
16024
16034
  *
16025
16035
  */
@@ -16888,7 +16898,7 @@ Made in Italy` })));
16888
16898
  * @Author: binruan@chatlabs.com
16889
16899
  * @Date: 2023-10-31 10:56:01
16890
16900
  * @LastEditors: binruan@chatlabs.com
16891
- * @LastEditTime: 2024-08-06 17:15:56
16901
+ * @LastEditTime: 2024-08-23 10:28:15
16892
16902
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\Popup\index.tsx
16893
16903
  *
16894
16904
  */
@@ -16913,6 +16923,20 @@ Made in Italy` })));
16913
16923
  setVisible(popup);
16914
16924
  }
16915
16925
  }, [popup]);
16926
+ const isFullScreen = React.useMemo(() => {
16927
+ var _a, _b, _c, _d;
16928
+ const valueItem = (_c = (_b = (_a = schema === null || schema === void 0 ? void 0 : schema.sxpPageConf) === null || _a === void 0 ? void 0 : _a.globalConfig) === null || _b === void 0 ? void 0 : _b.popupList) === null || _c === void 0 ? void 0 : _c.find((value, index) => {
16929
+ if ((value === null || value === void 0 ? void 0 : value.id) === (popup === null || popup === void 0 ? void 0 : popup.id)) {
16930
+ return value;
16931
+ }
16932
+ });
16933
+ if (valueItem !== -1 && ((_d = valueItem === null || valueItem === void 0 ? void 0 : valueItem.item) === null || _d === void 0 ? void 0 : _d.type) === 'Iframe') {
16934
+ return true;
16935
+ }
16936
+ else {
16937
+ return false;
16938
+ }
16939
+ }, [popup, schema]);
16916
16940
  const handleClose = () => {
16917
16941
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
16918
16942
  if (!popup ||
@@ -16961,7 +16985,7 @@ Made in Italy` })));
16961
16985
  }
16962
16986
  });
16963
16987
  }, [schema, popup, resolver, handleClose]);
16964
- return (React.createElement(Modal$1, { popup: visible, onClose: handleClose, padding: 0, modalStyle: { position: 'fixed' } }, renderPopupDetail));
16988
+ return (React.createElement(Modal$1, { popup: visible, onClose: handleClose, padding: 0, modalStyle: { position: 'fixed' }, isFullScreen: isFullScreen }, renderPopupDetail));
16965
16989
  };
16966
16990
 
16967
16991
  /*