pb-sxp-ui 1.10.11 → 1.10.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.
package/dist/index.js CHANGED
@@ -9763,7 +9763,7 @@ SwiperSlide.displayName = 'SwiperSlide';
9763
9763
  * @Author: binruan@chatlabs.com
9764
9764
  * @Date: 2023-11-02 18:34:34
9765
9765
  * @LastEditors: binruan@chatlabs.com
9766
- * @LastEditTime: 2024-11-20 18:37:10
9766
+ * @LastEditTime: 2024-12-12 16:35:54
9767
9767
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\Modal\index.tsx
9768
9768
  *
9769
9769
  */
@@ -9821,7 +9821,7 @@ const Modal = ({ visible, onClose, children, modalStyle, padding, popup, schema,
9821
9821
  }, [isOpen, popup]);
9822
9822
  const child = useCallback(() => {
9823
9823
  return children;
9824
- }, [_popup, openState, globalConfig]);
9824
+ }, [_popup, openState, globalConfig, schema]);
9825
9825
  useEffect(() => {
9826
9826
  const trapFocus = (element) => {
9827
9827
  var focusableEls = element === null || element === void 0 ? void 0 : element.querySelectorAll('[role="button"],a, a[href]:not([disabled]), button:not([disabled]), textarea:not([disabled]), input[type="text"]:not([disabled]), input[type="radio"]:not([disabled]), input[type="checkbox"]:not([disabled]), select:not([disabled])');
@@ -11981,7 +11981,7 @@ const CommodityList = createMaterial(CommodityListComponent, {
11981
11981
  * @Author: binruan@chatlabs.com
11982
11982
  * @Date: 2023-10-27 14:06:35
11983
11983
  * @LastEditors: binruan@chatlabs.com
11984
- * @LastEditTime: 2024-08-08 17:32:11
11984
+ * @LastEditTime: 2024-12-12 15:12:57
11985
11985
  * @FilePath: \pb-sxp-ui\src\materials\sxp\popup\Iframe\settingRender.tsx
11986
11986
  *
11987
11987
  */
@@ -11995,16 +11995,32 @@ var settingRender$8 = [
11995
11995
  name: ['style', 'backgroundColor']
11996
11996
  }
11997
11997
  ]
11998
+ },
11999
+ {
12000
+ title: 'iframe',
12001
+ child: [
12002
+ {
12003
+ type: 'TextArea',
12004
+ label: 'url',
12005
+ name: ['props', 'iframe', 'src']
12006
+ },
12007
+ {
12008
+ type: 'TextArea',
12009
+ label: 'allow',
12010
+ name: ['props', 'iframe', 'allow']
12011
+ }
12012
+ ]
11998
12013
  }
11999
12014
  ];
12000
12015
 
12001
12016
  const Iframe$1 = (_a) => {
12002
12017
  var _b, _c;
12003
- 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"]);
12018
+ var { content, btnText, style, icon, isPopup, isExternalLink, onClose, onClick, submitButtonStyle, contentStyle, isTel, iframe } = _a, props = __rest(_a, ["content", "btnText", "style", "icon", "isPopup", "isExternalLink", "onClose", "onClick", "submitButtonStyle", "contentStyle", "isTel", "iframe"]);
12004
12019
  const { popupDetailData } = useSxpDataSource();
12005
- 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;
12006
- return (React.createElement("div", Object.assign({ className: `${css(Object.assign({}, style))}` }, props),
12007
- React.createElement("iframe", { src: iframeUrl, style: {
12020
+ const { src, allow } = iframe || {};
12021
+ const iframeUrl = src || ((_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);
12022
+ return (React.createElement("div", Object.assign({ className: `${css(Object.assign(Object.assign({}, style), { overflow: 'hidden' }))}` }, props),
12023
+ React.createElement("iframe", { src: iframeUrl, allow: allow, scrolling: 'no', style: {
12008
12024
  width: '100%',
12009
12025
  height: 'calc(100% - 50px)',
12010
12026
  marginTop: '50px',
@@ -18885,7 +18901,7 @@ var index$1 = memo(DiyPortalPreview);
18885
18901
  * @Author: binruan@chatlabs.com
18886
18902
  * @Date: 2023-10-31 10:56:01
18887
18903
  * @LastEditors: binruan@chatlabs.com
18888
- * @LastEditTime: 2024-10-23 15:07:29
18904
+ * @LastEditTime: 2024-12-12 14:48:31
18889
18905
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\Popup\index.tsx
18890
18906
  *
18891
18907
  */