pb-sxp-ui 1.15.1 → 1.15.2

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.
@@ -8,7 +8,7 @@ const Navbar = ({ icon, styles, textStyle, onClose }) => {
8
8
  React.createElement("button", { className: 'clc-sxp-nav-left', role: 'button', "aria-label": 'back button', onClick: onClose },
9
9
  React.createElement("img", { src: icon, alt: 'back button' })),
10
10
  React.createElement("div", { className: 'clc-sxp-nav-title', style: Object.assign(Object.assign({}, textStyle), { paddingLeft: (textStyle === null || textStyle === void 0 ? void 0 : textStyle.textAlign) === 'left' ? '35px' : 0 }), dangerouslySetInnerHTML: {
11
- __html: setFontForText(`#${(_a = waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.hashTag) !== null && _a !== void 0 ? _a : 'title'}`, textStyle)
11
+ __html: setFontForText(`#${(_a = waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.hashTag) !== null && _a !== void 0 ? _a : '标题'}`, textStyle)
12
12
  } })));
13
13
  };
14
14
  export default memo(Navbar);
@@ -35,7 +35,7 @@ const AniLink = (_a) => {
35
35
  onClick === null || onClick === void 0 ? void 0 : onClick();
36
36
  }
37
37
  };
38
- const title = (cta === null || cta === void 0 ? void 0 : cta.enTitle) || 'Show More';
38
+ const title = (cta === null || cta === void 0 ? void 0 : cta.enTitle) || '查看详情';
39
39
  const aniTimStyle = useMemo(() => {
40
40
  var _a, _b;
41
41
  const ani = event === null || event === void 0 ? void 0 : event.animation;
@@ -35,7 +35,7 @@ const AniLinkPopup = (_a) => {
35
35
  onClick === null || onClick === void 0 ? void 0 : onClick();
36
36
  }
37
37
  };
38
- const title = (cta === null || cta === void 0 ? void 0 : cta.enTitle) || 'Show More';
38
+ const title = (cta === null || cta === void 0 ? void 0 : cta.enTitle) || '查看详情';
39
39
  const aniTimStyle = useMemo(() => {
40
40
  const ani = event === null || event === void 0 ? void 0 : event.animation;
41
41
  if (ani) {
@@ -12,10 +12,6 @@ export interface IIframeProps {
12
12
  submitButtonStyle?: CSSProperties;
13
13
  contentStyle?: CSSProperties;
14
14
  isTel?: boolean;
15
- iframe?: {
16
- src?: string;
17
- allow?: string;
18
- };
19
15
  }
20
16
  declare const _default: React.NamedExoticComponent<IIframeProps>;
21
17
  export default _default;
@@ -5,12 +5,11 @@ import './index.less';
5
5
  import { useSxpDataSource } from '../../../../core/hooks';
6
6
  const Iframe = (_a) => {
7
7
  var _b, _c;
8
- 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"]);
8
+ 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"]);
9
9
  const { popupDetailData } = useSxpDataSource();
10
- const { src, allow } = iframe || {};
11
- 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);
12
- return (React.createElement("div", Object.assign({ className: `${css(Object.assign(Object.assign({}, style), { overflow: 'hidden' }))}` }, props),
13
- React.createElement("iframe", { src: iframeUrl, allow: allow, scrolling: 'no', style: {
10
+ 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;
11
+ return (React.createElement("div", Object.assign({ className: `${css(Object.assign({}, style))}` }, props),
12
+ React.createElement("iframe", { src: iframeUrl, style: {
14
13
  width: '100%',
15
14
  height: 'calc(100% - 50px)',
16
15
  marginTop: '50px',
@@ -8,20 +8,5 @@ export default [
8
8
  name: ['style', 'backgroundColor']
9
9
  }
10
10
  ]
11
- },
12
- {
13
- title: 'iframe',
14
- child: [
15
- {
16
- type: 'TextArea',
17
- label: 'url',
18
- name: ['props', 'iframe', 'src']
19
- },
20
- {
21
- type: 'TextArea',
22
- label: 'allow',
23
- name: ['props', 'iframe', 'allow']
24
- }
25
- ]
26
11
  }
27
12
  ];
@@ -11,7 +11,7 @@ const Navbar = ({ icon, styles, textStyle, onClose }) => {
11
11
  react_1.default.createElement("button", { className: 'clc-sxp-nav-left', role: 'button', "aria-label": 'back button', onClick: onClose },
12
12
  react_1.default.createElement("img", { src: icon, alt: 'back button' })),
13
13
  react_1.default.createElement("div", { className: 'clc-sxp-nav-title', style: Object.assign(Object.assign({}, textStyle), { paddingLeft: (textStyle === null || textStyle === void 0 ? void 0 : textStyle.textAlign) === 'left' ? '35px' : 0 }), dangerouslySetInnerHTML: {
14
- __html: (0, tool_1.setFontForText)(`#${(_a = waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.hashTag) !== null && _a !== void 0 ? _a : 'title'}`, textStyle)
14
+ __html: (0, tool_1.setFontForText)(`#${(_a = waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.hashTag) !== null && _a !== void 0 ? _a : '标题'}`, textStyle)
15
15
  } })));
16
16
  };
17
17
  exports.default = (0, react_1.memo)(Navbar);
@@ -37,7 +37,7 @@ const AniLink = (_a) => {
37
37
  onClick === null || onClick === void 0 ? void 0 : onClick();
38
38
  }
39
39
  };
40
- const title = (cta === null || cta === void 0 ? void 0 : cta.enTitle) || 'Show More';
40
+ const title = (cta === null || cta === void 0 ? void 0 : cta.enTitle) || '查看详情';
41
41
  const aniTimStyle = (0, react_1.useMemo)(() => {
42
42
  var _a, _b;
43
43
  const ani = event === null || event === void 0 ? void 0 : event.animation;
@@ -37,7 +37,7 @@ const AniLinkPopup = (_a) => {
37
37
  onClick === null || onClick === void 0 ? void 0 : onClick();
38
38
  }
39
39
  };
40
- const title = (cta === null || cta === void 0 ? void 0 : cta.enTitle) || 'Show More';
40
+ const title = (cta === null || cta === void 0 ? void 0 : cta.enTitle) || '查看详情';
41
41
  const aniTimStyle = (0, react_1.useMemo)(() => {
42
42
  const ani = event === null || event === void 0 ? void 0 : event.animation;
43
43
  if (ani) {
@@ -12,10 +12,6 @@ export interface IIframeProps {
12
12
  submitButtonStyle?: CSSProperties;
13
13
  contentStyle?: CSSProperties;
14
14
  isTel?: boolean;
15
- iframe?: {
16
- src?: string;
17
- allow?: string;
18
- };
19
15
  }
20
16
  declare const _default: React.NamedExoticComponent<IIframeProps>;
21
17
  export default _default;
@@ -7,12 +7,11 @@ require("./index.less");
7
7
  const hooks_1 = require("../../../../core/hooks");
8
8
  const Iframe = (_a) => {
9
9
  var _b, _c;
10
- var { content, btnText, style, icon, isPopup, isExternalLink, onClose, onClick, submitButtonStyle, contentStyle, isTel, iframe } = _a, props = tslib_1.__rest(_a, ["content", "btnText", "style", "icon", "isPopup", "isExternalLink", "onClose", "onClick", "submitButtonStyle", "contentStyle", "isTel", "iframe"]);
10
+ var { content, btnText, style, icon, isPopup, isExternalLink, onClose, onClick, submitButtonStyle, contentStyle, isTel } = _a, props = tslib_1.__rest(_a, ["content", "btnText", "style", "icon", "isPopup", "isExternalLink", "onClose", "onClick", "submitButtonStyle", "contentStyle", "isTel"]);
11
11
  const { popupDetailData } = (0, hooks_1.useSxpDataSource)();
12
- const { src, allow } = iframe || {};
13
- 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);
14
- return (react_1.default.createElement("div", Object.assign({ className: `${(0, css_1.css)(Object.assign(Object.assign({}, style), { overflow: 'hidden' }))}` }, props),
15
- react_1.default.createElement("iframe", { src: iframeUrl, allow: allow, scrolling: 'no', style: {
12
+ 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;
13
+ return (react_1.default.createElement("div", Object.assign({ className: `${(0, css_1.css)(Object.assign({}, style))}` }, props),
14
+ react_1.default.createElement("iframe", { src: iframeUrl, style: {
16
15
  width: '100%',
17
16
  height: 'calc(100% - 50px)',
18
17
  marginTop: '50px',
@@ -10,20 +10,5 @@ exports.default = [
10
10
  name: ['style', 'backgroundColor']
11
11
  }
12
12
  ]
13
- },
14
- {
15
- title: 'iframe',
16
- child: [
17
- {
18
- type: 'TextArea',
19
- label: 'url',
20
- name: ['props', 'iframe', 'src']
21
- },
22
- {
23
- type: 'TextArea',
24
- label: 'allow',
25
- name: ['props', 'iframe', 'allow']
26
- }
27
- ]
28
13
  }
29
14
  ];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pb-sxp-ui",
3
- "version": "1.15.1",
3
+ "version": "1.15.2",
4
4
  "description": "React enterprise-class UI components",
5
5
  "main": "dist/index.cjs",
6
6
  "module": "dist/index.js",