pb-sxp-ui 1.19.0-alpha.1 → 1.19.0-alpha.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.
Files changed (68) hide show
  1. package/dist/index.cjs +220 -195
  2. package/dist/index.cjs.map +1 -1
  3. package/dist/index.css +7 -15
  4. package/dist/index.js +220 -195
  5. package/dist/index.js.map +1 -1
  6. package/dist/index.min.cjs +6 -6
  7. package/dist/index.min.cjs.map +1 -1
  8. package/dist/index.min.js +6 -6
  9. package/dist/index.min.js.map +1 -1
  10. package/dist/pb-ui.js +220 -195
  11. package/dist/pb-ui.js.map +1 -1
  12. package/dist/pb-ui.min.js +6 -6
  13. package/dist/pb-ui.min.js.map +1 -1
  14. package/es/core/components/DiyPortalPreview/index.js +3 -5
  15. package/es/core/components/DiyStoryPreview/index.js +18 -7
  16. package/es/core/components/SxpPageRender/RenderCard.d.ts +1 -0
  17. package/es/core/components/SxpPageRender/RenderCard.js +2 -14
  18. package/es/core/components/SxpPageRender/index.js +35 -4
  19. package/es/core/context/SxpDataSourceProvider.d.ts +2 -0
  20. package/es/core/context/SxpDataSourceProvider.js +20 -37
  21. package/es/materials/sxp/consentPopup/Display/index.js +1 -1
  22. package/es/materials/sxp/cta/AniLinkPopup/material.js +3 -2
  23. package/es/materials/sxp/popup/CommodityDetail/material.js +2 -1
  24. package/es/materials/sxp/popup/CommodityList/index.js +5 -4
  25. package/es/materials/sxp/popup/CommodityList/material.js +1 -1
  26. package/es/materials/sxp/popup/CommodityList/settingRender.js +1 -1
  27. package/es/materials/sxp/template/Appoint/material.js +2 -1
  28. package/es/materials/sxp/template/Commodity/material.js +3 -2
  29. package/es/materials/sxp/template/CommodityDiro/material.js +3 -2
  30. package/es/materials/sxp/template/CommodityDiroNew/material.js +4 -2
  31. package/es/materials/sxp/template/Link/material.js +4 -2
  32. package/es/materials/sxp/template/MultiCommodity/index.js +2 -2
  33. package/es/materials/sxp/template/MultiCommodity/material.js +2 -1
  34. package/es/materials/sxp/template/MultiCommodityDiro/index.js +2 -2
  35. package/es/materials/sxp/template/MultiCommodityDiro/material.js +3 -2
  36. package/es/materials/sxp/template/MultiCommodityDiroNew/index.js +2 -2
  37. package/es/materials/sxp/template/MultiCommodityDiroNew/material.js +4 -2
  38. package/es/materials/sxp/template/NineCommodity/material.js +3 -2
  39. package/es/materials/sxp/template/components/CommodityGroup.js +1 -1
  40. package/es/materials/sxp/template/components/settingRender.js +1 -1
  41. package/lib/core/components/DiyPortalPreview/index.js +3 -5
  42. package/lib/core/components/DiyStoryPreview/index.js +18 -7
  43. package/lib/core/components/SxpPageRender/RenderCard.d.ts +1 -0
  44. package/lib/core/components/SxpPageRender/RenderCard.js +2 -14
  45. package/lib/core/components/SxpPageRender/index.js +35 -4
  46. package/lib/core/context/SxpDataSourceProvider.d.ts +2 -0
  47. package/lib/core/context/SxpDataSourceProvider.js +19 -36
  48. package/lib/materials/sxp/consentPopup/Display/index.js +1 -1
  49. package/lib/materials/sxp/cta/AniLinkPopup/material.js +2 -1
  50. package/lib/materials/sxp/popup/CommodityDetail/material.js +2 -1
  51. package/lib/materials/sxp/popup/CommodityList/index.js +5 -4
  52. package/lib/materials/sxp/popup/CommodityList/material.js +1 -1
  53. package/lib/materials/sxp/popup/CommodityList/settingRender.js +1 -1
  54. package/lib/materials/sxp/template/Appoint/material.js +2 -1
  55. package/lib/materials/sxp/template/Commodity/material.js +3 -2
  56. package/lib/materials/sxp/template/CommodityDiro/material.js +3 -2
  57. package/lib/materials/sxp/template/CommodityDiroNew/material.js +4 -2
  58. package/lib/materials/sxp/template/Link/material.js +4 -2
  59. package/lib/materials/sxp/template/MultiCommodity/index.js +2 -2
  60. package/lib/materials/sxp/template/MultiCommodity/material.js +2 -1
  61. package/lib/materials/sxp/template/MultiCommodityDiro/index.js +2 -2
  62. package/lib/materials/sxp/template/MultiCommodityDiro/material.js +3 -2
  63. package/lib/materials/sxp/template/MultiCommodityDiroNew/index.js +2 -2
  64. package/lib/materials/sxp/template/MultiCommodityDiroNew/material.js +4 -2
  65. package/lib/materials/sxp/template/NineCommodity/material.js +3 -2
  66. package/lib/materials/sxp/template/components/CommodityGroup.js +1 -1
  67. package/lib/materials/sxp/template/components/settingRender.js +1 -1
  68. package/package.json +1 -1
@@ -4,10 +4,10 @@ import React, { memo, useState } from 'react';
4
4
  import { SwiperSlide } from 'swiper/react';
5
5
  import Img from '../components/Img';
6
6
  import Scroll from '../components/Scroll';
7
- import EventProvider from '../components/EventProvider';
8
7
  import styles from './index.module.less';
9
8
  import { useSxpDataSource } from '../../../../core/hooks';
10
9
  import { setFontForText } from '../../../../core/utils/tool';
10
+ import EventProvider from '../components/EventProvider';
11
11
  const MultiCommodity = (_a) => {
12
12
  var _b, _c;
13
13
  var { content, style, bgImg, recData, bottom_image, ctaTempStyles, translateY = 0, isActive, index } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "bottom_image", "ctaTempStyles", "translateY", "isActive", "index"]);
@@ -15,7 +15,7 @@ const MultiCommodity = (_a) => {
15
15
  const [products] = useState((_c = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindProducts) !== null && _c !== void 0 ? _c : [1, 2]);
16
16
  return (React.createElement(Scroll, { isPadding: !!recData }, products === null || products === void 0 ? void 0 : products.map((item, itemIndex) => {
17
17
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
18
- return (React.createElement(React.Fragment, null, recData && !(item === null || item === void 0 ? void 0 : item.bindCta) ? null : (React.createElement(SwiperSlide, { key: itemIndex, className: css(Object.assign(Object.assign({}, style), { flexShrink: 0, marginInlineStart: 0, marginInlineEnd: '8px' })), tag: 'li', role: 'listitem' },
18
+ return (React.createElement(React.Fragment, null, recData && !(item === null || item === void 0 ? void 0 : item.bindCta) ? null : (React.createElement(SwiperSlide, { key: itemIndex, className: css(Object.assign(Object.assign({}, style), { flexShrink: 0, marginLeft: 0, marginRight: '8px' })), tag: 'li', role: 'listitem' },
19
19
  React.createElement(EventProvider, Object.assign({ rec: recData, multItem: item, multiCheckIndex: itemIndex, index: index }, props),
20
20
  React.createElement(Img, { 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: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img, isActive: isActive }),
21
21
  React.createElement("div", { className: css({
@@ -19,11 +19,12 @@ const MultiCommodity = createMaterial(MultiCommodityComponent, {
19
19
  borderRadius: 3,
20
20
  width: 60,
21
21
  height: 60,
22
- marginInlineEnd: 8
22
+ marginRight: 8
23
23
  },
24
24
  title: {
25
25
  fontSize: 12,
26
26
  color: '#fff',
27
+ textAlign: 'left'
27
28
  },
28
29
  ctaTitle: {
29
30
  fontSize: 10,
@@ -4,10 +4,10 @@ import React, { memo, useState } from 'react';
4
4
  import { SwiperSlide } from 'swiper/react';
5
5
  import Scroll from '../components/Scroll';
6
6
  import Img from '../components/Img';
7
- import EventProvider from '../components/EventProvider';
8
7
  import styles from './index.module.less';
9
8
  import { useSxpDataSource } from '../../../../core/hooks';
10
9
  import { setFontForText } from '../../../../core/utils/tool';
10
+ import EventProvider from '../components/EventProvider';
11
11
  const MultiCommodityDiro = (_a) => {
12
12
  var _b, _c;
13
13
  var { content, style, bgImg, recData, bottom_image, ctaTempStyles, translateY = 0, isActive, index } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "bottom_image", "ctaTempStyles", "translateY", "isActive", "index"]);
@@ -15,7 +15,7 @@ const MultiCommodityDiro = (_a) => {
15
15
  const [products] = useState((_c = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindProducts) !== null && _c !== void 0 ? _c : [1, 2]);
16
16
  return (React.createElement(Scroll, { isPadding: !!recData }, products === null || products === void 0 ? void 0 : products.map((item, itemIndex) => {
17
17
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
18
- return (React.createElement(React.Fragment, null, recData && !(item === null || item === void 0 ? void 0 : item.bindCta) ? null : (React.createElement(SwiperSlide, { key: itemIndex, className: css(Object.assign(Object.assign({}, style), { flexShrink: 0, marginInlineStart: 0, marginInlineEnd: '8px' })), tag: 'li', role: 'listitem' },
18
+ return (React.createElement(React.Fragment, null, recData && !(item === null || item === void 0 ? void 0 : item.bindCta) ? null : (React.createElement(SwiperSlide, { key: itemIndex, className: css(Object.assign(Object.assign({}, style), { flexShrink: 0, marginLeft: 0, marginRight: '8px' })), tag: 'li', role: 'listitem' },
19
19
  React.createElement(EventProvider, Object.assign({ rec: recData, multItem: item, multiCheckIndex: itemIndex, index: index }, props),
20
20
  React.createElement(Img, { 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: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img, isActive: isActive }),
21
21
  React.createElement("div", { className: css({
@@ -19,11 +19,12 @@ const MultiCommodityDiro = createMaterial(MultiCommodityDiroComponent, {
19
19
  borderRadius: 3,
20
20
  width: 60,
21
21
  height: 60,
22
- marginInlineEnd: 8
22
+ marginRight: 8
23
23
  },
24
24
  title: {
25
25
  fontSize: 12,
26
- color: '#000'
26
+ color: '#000',
27
+ textAlign: 'left'
27
28
  },
28
29
  ctaTitle: {
29
30
  fontSize: 10,
@@ -4,10 +4,10 @@ import React, { memo, useState } from 'react';
4
4
  import { SwiperSlide } from 'swiper/react';
5
5
  import Scroll from '../components/Scroll';
6
6
  import Img from '../components/Img';
7
- import EventProvider from '../components/EventProvider';
8
7
  import styles from './index.module.less';
9
8
  import { useSxpDataSource } from '../../../../core/hooks';
10
9
  import { setFontForText } from '../../../../core/utils/tool';
10
+ import EventProvider from '../components/EventProvider';
11
11
  const MultiCommodityDiroNew = (_a) => {
12
12
  var _b, _c;
13
13
  var { content, style, bgImg, recData, bottom_image, ctaTempStyles, translateY = 0, isActive, index } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "bottom_image", "ctaTempStyles", "translateY", "isActive", "index"]);
@@ -15,7 +15,7 @@ const MultiCommodityDiroNew = (_a) => {
15
15
  const [products] = useState((_c = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindProducts) !== null && _c !== void 0 ? _c : [1, 2]);
16
16
  return (React.createElement(Scroll, { isPadding: !!recData }, products === null || products === void 0 ? void 0 : products.map((item, itemIndex) => {
17
17
  var _a, _b, _c, _d, _e, _f, _g, _h, _j;
18
- return (React.createElement(React.Fragment, null, recData && !(item === null || item === void 0 ? void 0 : item.bindCta) ? null : (React.createElement(SwiperSlide, { key: itemIndex, className: css(Object.assign(Object.assign({}, style), { flexShrink: 0, marginInlineStart: 0, marginInlineEnd: '8px' })), tag: 'li', role: 'listitem' },
18
+ return (React.createElement(React.Fragment, null, recData && !(item === null || item === void 0 ? void 0 : item.bindCta) ? null : (React.createElement(SwiperSlide, { key: itemIndex, className: css(Object.assign(Object.assign({}, style), { flexShrink: 0, marginLeft: 0, marginRight: '8px' })), tag: 'li', role: 'listitem' },
19
19
  React.createElement(EventProvider, Object.assign({ rec: recData, multItem: item, multiCheckIndex: itemIndex, index: index }, props),
20
20
  React.createElement(Img, { 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: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img, isActive: isActive }),
21
21
  React.createElement("div", { className: css({
@@ -19,17 +19,19 @@ const MultiCommodityDiroNew = createMaterial(MultiCommodityDiroNewComponent, {
19
19
  borderRadius: 8,
20
20
  width: 78,
21
21
  height: 78,
22
- marginInlineEnd: 16
22
+ marginRight: 16
23
23
  },
24
24
  title: {
25
25
  fontSize: 12,
26
- color: '#000'
26
+ color: '#000',
27
+ textAlign: 'left'
27
28
  },
28
29
  ctaTitle: {
29
30
  textDecoration: 'underline',
30
31
  fontSize: 12,
31
32
  fontWeight: 'bold',
32
33
  color: '#000',
34
+ textAlign: 'left',
33
35
  width: 150,
34
36
  height: 20
35
37
  }
@@ -19,11 +19,12 @@ const NineCommodity = createMaterial(NineCommodityComponent, {
19
19
  borderRadius: 3,
20
20
  width: 60,
21
21
  height: 60,
22
- marginInlineEnd: 8
22
+ marginRight: 8
23
23
  },
24
24
  title: {
25
25
  fontSize: 12,
26
- color: '#fff'
26
+ color: '#fff',
27
+ textAlign: 'left'
27
28
  },
28
29
  ctaTitle: {
29
30
  fontSize: 10,
@@ -21,7 +21,7 @@ const CommodityGroup = ({ products, data, defImg, style, onCLick, popupDetailDat
21
21
  return (React.createElement(React.Fragment, null, (item === null || item === void 0 ? void 0 : item.bindCta) ? (React.createElement(SwiperSlide, { className: css({
22
22
  width: '50px',
23
23
  height: '50px',
24
- marginInlineEnd: '10px'
24
+ marginRight: '10px'
25
25
  }), onClick: () => {
26
26
  handleClick(item, index);
27
27
  }, key: index },
@@ -100,7 +100,7 @@ export default [
100
100
  type: 'Number',
101
101
  label: '与右侧边距',
102
102
  addonAfter: 'px',
103
- name: ['props', 'ctaTempStyles', 'img', 'marginInlineEnd']
103
+ name: ['props', 'ctaTempStyles', 'img', 'marginRight']
104
104
  },
105
105
  {
106
106
  label: '居中垂直偏移',
@@ -62,7 +62,7 @@ const DiyPortalPreview = ({ data = [], globalConfig, tipText, nudge, tempMap, de
62
62
  const CTA = (rec, index) => {
63
63
  if ((globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.isShowCTA) === undefined || (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.isShowCTA)) {
64
64
  return (react_1.default.createElement("div", { className: 'clc-sxp-bottom-card' },
65
- react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: RESOLVER, isActive: true })));
65
+ react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: RESOLVER })));
66
66
  }
67
67
  return null;
68
68
  };
@@ -75,10 +75,8 @@ const DiyPortalPreview = ({ data = [], globalConfig, tipText, nudge, tempMap, de
75
75
  react_1.default.createElement(Nudge_1.default, { nudge: nudge }),
76
76
  CTA(rec, index),
77
77
  react_1.default.createElement("div", null,
78
- react_1.default.createElement(ExpandableText_1.default, { 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: (_c = (_b = rec === null || rec === void 0 ? void 0 : rec.video) === null || _b === void 0 ? void 0 : _b.title) !== null && _c !== void 0 ? _c : '', 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' }) }),
79
- react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: RESOLVER, includesCtaType: ['AniLink'], isActive: true })),
80
- react_1.default.createElement(Hashtag_1.default, { index: index, tags: (_e = (_d = rec === null || rec === void 0 ? void 0 : rec.video) === null || _d === void 0 ? void 0 : _d.hashTags) !== null && _e !== void 0 ? _e : [], itemId: (_f = rec === null || rec === void 0 ? void 0 : rec.video) === null || _f === void 0 ? void 0 : _f.itemId, itemType: ((_g = rec === null || rec === void 0 ? void 0 : rec.video) === null || _g === void 0 ? void 0 : _g.itemId) ? 'VIDEO' : null, rec: rec, hashTagStyle: hashTagStyle })),
81
- react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: RESOLVER, includesCtaType: ['AniLinkPopup'], isActive: true })));
78
+ react_1.default.createElement(ExpandableText_1.default, { 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: (_c = (_b = rec === null || rec === void 0 ? void 0 : rec.video) === null || _b === void 0 ? void 0 : _b.title) !== null && _c !== void 0 ? _c : '', 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' }) })),
79
+ react_1.default.createElement(Hashtag_1.default, { index: index, tags: (_e = (_d = rec === null || rec === void 0 ? void 0 : rec.video) === null || _d === void 0 ? void 0 : _d.hashTags) !== null && _e !== void 0 ? _e : [], itemId: (_f = rec === null || rec === void 0 ? void 0 : rec.video) === null || _f === void 0 ? void 0 : _f.itemId, itemType: ((_g = rec === null || rec === void 0 ? void 0 : rec.video) === null || _g === void 0 ? void 0 : _g.itemId) ? 'VIDEO' : null, rec: rec, hashTagStyle: hashTagStyle }))));
82
80
  }
83
81
  return null;
84
82
  };
@@ -84,10 +84,21 @@ const DiyStoryPreview = (0, react_1.forwardRef)(({ data = [], globalConfig, tipT
84
84
  return null;
85
85
  }, [globalConfig]);
86
86
  const renderBottom = (rec, index) => {
87
- var _a, _b, _c, _d;
87
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j;
88
88
  if (rec === null || rec === void 0 ? void 0 : rec.video) {
89
+ let cta = null;
90
+ 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) {
91
+ cta = '多商品CTA';
92
+ }
93
+ else if ((_c = rec === null || rec === void 0 ? void 0 : rec.video) === null || _c === void 0 ? void 0 : _c.bindProduct) {
94
+ cta = '商品CTA';
95
+ }
96
+ else {
97
+ 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;
98
+ }
99
+ const value = tempMap === null || tempMap === void 0 ? void 0 : tempMap[cta];
89
100
  return (react_1.default.createElement(react_1.default.Fragment, null,
90
- ((_a = rec === null || rec === void 0 ? void 0 : rec.video) === null || _a === void 0 ? void 0 : _a.title) && (react_1.default.createElement("div", { style: {
101
+ ((_f = rec === null || rec === void 0 ? void 0 : rec.video) === null || _f === void 0 ? void 0 : _f.title) && (react_1.default.createElement("div", { style: {
91
102
  background: 'repeating-linear-gradient(0deg, rgba(26, 26, 25, 0.7), hsla(0, 0%, 100%, 0))',
92
103
  height: '130px',
93
104
  position: 'absolute',
@@ -98,7 +109,7 @@ const DiyStoryPreview = (0, react_1.forwardRef)(({ data = [], globalConfig, tipT
98
109
  pointerEvents
99
110
  } })),
100
111
  react_1.default.createElement("div", { style: {
101
- marginBottom: `${(_b = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.bottomInfoDist) !== null && _b !== void 0 ? _b : 40}px`,
112
+ marginBottom: `${(_g = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.bottomInfoDist) !== null && _g !== void 0 ? _g : 40}px`,
102
113
  zIndex: 999,
103
114
  position: 'absolute',
104
115
  bottom: 0,
@@ -107,11 +118,11 @@ const DiyStoryPreview = (0, react_1.forwardRef)(({ data = [], globalConfig, tipT
107
118
  paddingTop: '20px'
108
119
  } },
109
120
  (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.isShowCTA) === undefined || (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.isShowCTA) ? (react_1.default.createElement("div", { style: {} },
110
- react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: RESOLVER, isActive: index === activeIndex }))) : null,
121
+ react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: RESOLVER, isActive: index === activeIndex, value: value }))) : null,
111
122
  react_1.default.createElement("div", null,
112
- react_1.default.createElement(ExpandableText_1.default, { 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', padding: '0 20px', fontSize: '12px' }) }),
113
- react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: RESOLVER, includesCtaType: ['AniLink'], isActive: index === activeIndex }))),
114
- react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: RESOLVER, includesCtaType: ['AniLinkPopup'], isActive: index === activeIndex })));
123
+ react_1.default.createElement(ExpandableText_1.default, { isPost: true, foldText: tipText === null || tipText === void 0 ? void 0 : tipText.foldText, unfoldText: tipText === null || tipText === void 0 ? void 0 : tipText.unfoldText, text: (_j = (_h = rec === null || rec === void 0 ? void 0 : rec.video) === null || _h === void 0 ? void 0 : _h.title) !== null && _j !== void 0 ? _j : '', 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', padding: '0 20px', fontSize: '12px' }) }),
124
+ react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: RESOLVER, includesCtaType: ['AniLink'], isActive: index === activeIndex, value: value }))),
125
+ react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: RESOLVER, includesCtaType: ['AniLinkPopup'], isActive: index === activeIndex, value: value })));
115
126
  }
116
127
  return null;
117
128
  };
@@ -8,6 +8,7 @@ interface IRenderCardProps {
8
8
  resolver: any;
9
9
  includesCtaType?: string[];
10
10
  isActive?: boolean;
11
+ value?: any;
11
12
  isNineProduct?: boolean;
12
13
  }
13
14
  declare const _default: React.NamedExoticComponent<IRenderCardProps>;
@@ -6,22 +6,10 @@ require("./index.less");
6
6
  const lodash_1 = require("lodash");
7
7
  const withBindDataSource_1 = tslib_1.__importDefault(require("../../../core/hoc/withBindDataSource"));
8
8
  const hooks_1 = require("../../../core/hooks");
9
- const RenderCard = ({ rec, index, tempMap, resolver, includesCtaType, isActive, isNineProduct }) => {
10
- var _a, _b, _c, _d, _e;
9
+ const RenderCard = ({ rec, index, tempMap, resolver, includesCtaType, isActive, value, isNineProduct }) => {
11
10
  const { schema } = (0, hooks_1.useEditor)();
12
11
  if (!(rec === null || rec === void 0 ? void 0 : rec.video))
13
12
  return null;
14
- let cta = null;
15
- 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) {
16
- cta = '多商品CTA';
17
- }
18
- else if ((_c = rec === null || rec === void 0 ? void 0 : rec.video) === null || _c === void 0 ? void 0 : _c.bindProduct) {
19
- cta = '商品CTA';
20
- }
21
- else {
22
- 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;
23
- }
24
- const value = tempMap === null || tempMap === void 0 ? void 0 : tempMap[cta];
25
13
  const renderComp = (0, react_1.useMemo)(() => {
26
14
  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;
27
15
  if (includesCtaType && !(includesCtaType === null || includesCtaType === void 0 ? void 0 : includesCtaType.includes((_a = value === null || value === void 0 ? void 0 : value.item) === null || _a === void 0 ? void 0 : _a.type)))
@@ -46,7 +34,7 @@ const RenderCard = ({ rec, index, tempMap, resolver, includesCtaType, isActive,
46
34
  const sbf = style.backdropFilter;
47
35
  style.backdropFilter = `blur(${sbf !== null && sbf !== void 0 ? sbf : 0}px)`;
48
36
  }
49
- return (react_1.default.createElement(Component, Object.assign({ style: Object.assign(Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.style), style), { zIndex: 50, marginInlineStart: '20px', boxSizing: 'border-box', transform: 'translate3d(0px, 0px, 0px)' }), textStyle: Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.textStyle), (_z = value === null || value === void 0 ? void 0 : value.item) === null || _z === void 0 ? void 0 : _z.textStyle), bindDatas: (_1 = (_0 = value === null || value === void 0 ? void 0 : value.item) === null || _0 === void 0 ? void 0 : _0.bindDatas) !== null && _1 !== void 0 ? _1 : [] }, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.props, (_2 = value === null || value === void 0 ? void 0 : value.item) === null || _2 === void 0 ? void 0 : _2.props, { event: ((_3 = value === null || value === void 0 ? void 0 : value.item) === null || _3 === void 0 ? void 0 : _3.event) || {}, schema: schema, id: value === null || value === void 0 ? void 0 : value.id, key: value === null || value === void 0 ? void 0 : value.id, recData: rec, isExternalLink: isExternalLink, index: index, isActive: isActive })));
37
+ return (react_1.default.createElement(Component, Object.assign({ style: Object.assign(Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.style), style), { zIndex: 50, marginLeft: '20px', boxSizing: 'border-box', transform: 'translate3d(0px, 0px, 0px)' }), textStyle: Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.textStyle), (_z = value === null || value === void 0 ? void 0 : value.item) === null || _z === void 0 ? void 0 : _z.textStyle), bindDatas: (_1 = (_0 = value === null || value === void 0 ? void 0 : value.item) === null || _0 === void 0 ? void 0 : _0.bindDatas) !== null && _1 !== void 0 ? _1 : [] }, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.props, (_2 = value === null || value === void 0 ? void 0 : value.item) === null || _2 === void 0 ? void 0 : _2.props, { event: ((_3 = value === null || value === void 0 ? void 0 : value.item) === null || _3 === void 0 ? void 0 : _3.event) || {}, schema: schema, id: value === null || value === void 0 ? void 0 : value.id, key: value === null || value === void 0 ? void 0 : value.id, recData: rec, isExternalLink: isExternalLink, index: index, isActive: isActive })));
50
38
  }
51
39
  else {
52
40
  return null;
@@ -29,6 +29,7 @@ const ConsentPopup_1 = tslib_1.__importDefault(require("./ConsentPopup"));
29
29
  const MultiPosts_1 = tslib_1.__importDefault(require("../../../materials/sxp/MultiPosts"));
30
30
  const EditorDataProvider_1 = require("../../../core/context/EditorDataProvider");
31
31
  const NavBack_1 = tslib_1.__importDefault(require("./NavBack"));
32
+ const tool_1 = require("../../../core/utils/tool");
32
33
  const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.innerHeight, containerWidth = window.innerWidth, tempMap, resolver, data = [], ctaType, tipText, nudge, _schema, hashTagStyle, hashTagRightMargin, tagList = [], defaultData }) => {
33
34
  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;
34
35
  const mutedIcon = (0, useIconLink_1.useIconLink)('/pb_static/5beaaa5ce7f3477b99db3838619cc471.png');
@@ -45,6 +46,7 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
45
46
  const skipLinkRef = (0, react_1.useRef)(false);
46
47
  const [pageNum, setPageNum] = (0, react_1.useState)(2);
47
48
  const videoWidgetRef = (0, react_1.useRef)(null);
49
+ const fbcRef = (0, react_1.useRef)('');
48
50
  const { loadVideos, bffEventReport, loading, setPopupDetailData, ctaEvent, swiperRef, waterFallData, setOpenHashtag, appDomain, openHashtag, loadingImage, isFromHashtag, popupDetailData, bffFbReport, curTime, h5EnterLink, isShowConsent, selectTag, isPreview, isEditor, cacheRtcList, setRtcList, cacheActiveIndex, rtcList, isNoMoreData, channel, refreshFeSession, isDiyH5 } = (0, hooks_1.useSxpDataSource)();
49
51
  const { backMainFeed, productView, jumpToWeb } = (0, useEventReport_1.useEventReport)();
50
52
  const isShowFingerTip = (0, react_1.useMemo)(() => {
@@ -317,17 +319,17 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
317
319
  index === ((rtcList === null || rtcList === void 0 ? void 0 : rtcList[0]) === 'organic menu' ? 2 : 1) &&
318
320
  ((_f = ['MultiCommodity', 'MultiCommodityDiro', 'MultiCommodityDiroNew']) === null || _f === void 0 ? void 0 : _f.includes((_g = value === null || value === void 0 ? void 0 : value.item) === null || _g === void 0 ? void 0 : _g.type));
319
321
  return (react_1.default.createElement(react_1.default.Fragment, null,
320
- isNineProduct && (react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, isActive: index === activeIndex, isNineProduct: isNineProduct })),
322
+ isNineProduct && (react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, isActive: index === activeIndex, value: value, isNineProduct: isNineProduct })),
321
323
  ((_h = rec === null || rec === void 0 ? void 0 : rec.video) === null || _h === void 0 ? void 0 : _h.title) && !isShowMore && react_1.default.createElement("div", { className: 'clc-sxp-bottom-shadow' }),
322
324
  react_1.default.createElement("div", { className: 'clc-sxp-bottom', style: { marginBottom: `${(_j = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.bottomInfoDist) !== null && _j !== void 0 ? _j : 40}px` } },
323
325
  react_1.default.createElement(Nudge_1.default, { nudge: nudge }),
324
326
  ((globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.isShowCTA) === undefined || (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.isShowCTA)) && !isNineProduct ? (react_1.default.createElement("div", { className: 'clc-sxp-bottom-card' },
325
- react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, isActive: index === activeIndex }))) : null,
327
+ react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, isActive: index === activeIndex, value: value }))) : null,
326
328
  react_1.default.createElement("div", { style: { display: 'flex', flexDirection: 'column' } },
327
329
  react_1.default.createElement(ExpandableText_1.default, { 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: (_l = (_k = rec === null || rec === void 0 ? void 0 : rec.video) === null || _k === void 0 ? void 0 : _k.title) !== null && _l !== void 0 ? _l : '', 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 }),
328
- react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, includesCtaType: ['AniLink'], isActive: index === activeIndex }),
330
+ react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, includesCtaType: ['AniLink'], isActive: index === activeIndex, value: value }),
329
331
  react_1.default.createElement(Hashtag_1.default, { index: activeIndex, tags: (_o = (_m = rec === null || rec === void 0 ? void 0 : rec.video) === null || _m === void 0 ? void 0 : _m.hashTags) !== null && _o !== void 0 ? _o : [], itemId: (_p = rec === null || rec === void 0 ? void 0 : rec.video) === null || _p === void 0 ? void 0 : _p.itemId, itemType: ((_q = rec === null || rec === void 0 ? void 0 : rec.video) === null || _q === void 0 ? void 0 : _q.itemId) ? 'VIDEO' : null, rec: rec, hashTagStyle: hashTagStyle, hashTagRightMargin: containerWidth - (hashTagRightMargin !== null && hashTagRightMargin !== void 0 ? hashTagRightMargin : 0) }))),
330
- react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, includesCtaType: ['AniLinkPopup'], isActive: index === activeIndex })));
332
+ react_1.default.createElement(RenderCard_1.default, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, includesCtaType: ['AniLinkPopup'], isActive: index === activeIndex, value: value })));
331
333
  }
332
334
  return null;
333
335
  }, [
@@ -482,6 +484,35 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
482
484
  viewTime.current = new Date();
483
485
  }
484
486
  }, [openHashtag, data, activeIndex]);
487
+ (0, react_1.useEffect)(() => {
488
+ if (!(globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.enableCookieSetting))
489
+ return;
490
+ window.OptanonWrapper = function () {
491
+ var _a, _b;
492
+ const activeGroups = window === null || window === void 0 ? void 0 : window.OnetrustActiveGroups;
493
+ if (!activeGroups)
494
+ return;
495
+ if (activeGroups === null || activeGroups === void 0 ? void 0 : activeGroups.includes('4')) {
496
+ if (fbcRef.current) {
497
+ (0, tool_1.setCookie)('_fbc', fbcRef.current, 90);
498
+ }
499
+ }
500
+ else {
501
+ fbcRef.current = (0, tool_1.getCookie)('_fbc');
502
+ (0, tool_1.deleteCookie)('_fbc');
503
+ const item = data[activeIndex];
504
+ const traceInfo = ((_a = item === null || item === void 0 ? void 0 : item.video) === null || _a === void 0 ? void 0 : _a.traceInfo) || ((_b = item === null || item === void 0 ? void 0 : item.product) === null || _b === void 0 ? void 0 : _b.traceInfo) || '';
505
+ bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
506
+ eventInfo: {
507
+ eventSubject: 'refuseCookie',
508
+ eventDescription: 'refuseCookie',
509
+ traceInfo
510
+ },
511
+ isActiveTargetingCookie: false
512
+ });
513
+ }
514
+ };
515
+ }, [globalConfig, bffEventReport, data, activeIndex]);
485
516
  const handleViewImageStartEvent = (activeIndex, imgInfo, enableCapi) => {
486
517
  var _a, _b, _c, _d, _e, _f, _g, _h;
487
518
  const item = data[activeIndex];
@@ -43,6 +43,8 @@ export interface ISxpDataSourceContext {
43
43
  bffEventReport?: (body: {
44
44
  userInfo?: object;
45
45
  eventInfo: object;
46
+ reportLayId?: boolean;
47
+ isActiveTargetingCookie?: boolean;
46
48
  }) => Promise<any> | undefined | boolean;
47
49
  isPreview?: boolean;
48
50
  loading?: boolean;
@@ -53,7 +53,6 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
53
53
  const [chatlabsId, setChatlabsId] = (0, react_1.useState)();
54
54
  const finalPageData = (0, react_1.useMemo)(() => pageData !== null && pageData !== void 0 ? pageData : data, [pageData, data]);
55
55
  const pixelPvStatusRef = (0, react_1.useRef)(false);
56
- const fbcRef = (0, react_1.useRef)('');
57
56
  const isShowConsent = (0, react_1.useMemo)(() => {
58
57
  var _a, _b, _c, _d;
59
58
  return (((((_d = (_c = (_b = (_a = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.consent) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.item) === null || _c === void 0 ? void 0 : _c.props) === null || _d === void 0 ? void 0 : _d.privacy_necessity) && !isAgreePolicy && !isEditor) || isOpenConsent) &&
@@ -109,23 +108,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
109
108
  var _a;
110
109
  return ((_a = bffDataSource === null || bffDataSource === void 0 ? void 0 : bffDataSource.headers) === null || _a === void 0 ? void 0 : _a['x-app-id']) + (0, localStore_1.storeAndLoadFeUserId)();
111
110
  }, [bffDataSource]);
112
- (0, react_1.useEffect)(() => {
113
- if (!(globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.enableCookieSetting))
114
- return;
115
- fbcRef.current = (0, tool_1.getCookie)('_fbc');
116
- window.OptanonWrapper = function () {
117
- const activeGroups = window === null || window === void 0 ? void 0 : window.OnetrustActiveGroups;
118
- if (!activeGroups)
119
- return;
120
- if (!(activeGroups === null || activeGroups === void 0 ? void 0 : activeGroups.includes('4'))) {
121
- (0, tool_1.deleteCookie)('_fbc');
122
- }
123
- else if (fbcRef.current) {
124
- (0, tool_1.setCookie)('_fbc', fbcRef.current, 90);
125
- }
126
- };
127
- }, [globalConfig]);
128
- const isActiveTargetingCookie = (0, react_1.useMemo)(() => {
111
+ const getTargetingCookie = () => {
129
112
  var _a;
130
113
  function isTargetingRejected(cookieValue) {
131
114
  const groupsMatch = cookieValue.match(/groups=([^&]+)/);
@@ -151,11 +134,12 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
151
134
  return '';
152
135
  }
153
136
  const OptanonConsent = decodeURIComponent((_a = getCookie('OptanonConsent')) !== null && _a !== void 0 ? _a : '');
154
- if (((globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.enableCookieSetting) && (window === null || window === void 0 ? void 0 : window.OnetrustActiveGroups) && !(window === null || window === void 0 ? void 0 : window.OnetrustActiveGroups.includes('4')))) {
137
+ console.log('OptanonConsent:', window === null || window === void 0 ? void 0 : window.OnetrustActiveGroups);
138
+ if (((window === null || window === void 0 ? void 0 : window.OnetrustActiveGroups) && !(window === null || window === void 0 ? void 0 : window.OnetrustActiveGroups.includes('4')))) {
155
139
  return true;
156
140
  }
157
141
  return false;
158
- }, [globalConfig]);
142
+ };
159
143
  const bffFetch = (0, react_1.useCallback)((path, options, isBota = true) => {
160
144
  var _a;
161
145
  if (!bffDataSource)
@@ -183,7 +167,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
183
167
  }, [bffDataSource, fakeUserId]);
184
168
  const bffCollectEvent = (0, react_1.useCallback)((params) => {
185
169
  var _a;
186
- if (isActiveTargetingCookie)
170
+ if (getTargetingCookie())
187
171
  return Promise.resolve();
188
172
  const body = {
189
173
  eventName: params === null || params === void 0 ? void 0 : params.eventName,
@@ -194,7 +178,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
194
178
  body,
195
179
  type: 'beacon'
196
180
  }, false);
197
- }, [bffFetch, bffDataSource, isActiveTargetingCookie]);
181
+ }, [bffFetch, bffDataSource]);
198
182
  (0, react_1.useEffect)(() => {
199
183
  const OriginalImage = window.Image;
200
184
  window.Image = function () {
@@ -202,7 +186,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
202
186
  const originalSrcDescriptor = Object.getOwnPropertyDescriptor(HTMLImageElement.prototype, 'src');
203
187
  Object.defineProperty(img, 'src', {
204
188
  set(value) {
205
- if (isActiveTargetingCookie && (value.includes('https://www.facebook.com/privacy_sandbox/pixel/register/trigger/') || value.includes('https://www.facebook.com/tr'))) {
189
+ if (getTargetingCookie() && (value.includes('https://www.facebook.com/privacy_sandbox/pixel/register/trigger/') || value.includes('https://www.facebook.com/tr'))) {
206
190
  return;
207
191
  }
208
192
  originalSrcDescriptor.set.call(this, value);
@@ -222,7 +206,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
222
206
  });
223
207
  return img;
224
208
  };
225
- }, [bffCollectEvent, isActiveTargetingCookie]);
209
+ }, [bffCollectEvent]);
226
210
  (0, react_1.useEffect)(() => {
227
211
  const navigatorWithBeacon = navigator;
228
212
  if (!navigatorWithBeacon.sendBeacon) {
@@ -232,7 +216,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
232
216
  const originalSendBeacon = navigatorWithBeacon.sendBeacon.bind(navigatorWithBeacon);
233
217
  navigatorWithBeacon.sendBeacon = function (url, data) {
234
218
  const urlString = url instanceof URL ? url.href : url.toString();
235
- if (isActiveTargetingCookie && (urlString.includes('https://tr.snapchat.com/p') || urlString.includes('https://analytics.tiktok.com/api/v2/pixel'))) {
219
+ if (getTargetingCookie() && (urlString.includes('https://tr.snapchat.com/p') || urlString.includes('https://analytics.tiktok.com/api/v2/pixel'))) {
236
220
  return true;
237
221
  }
238
222
  const success = originalSendBeacon(url, data);
@@ -280,7 +264,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
280
264
  return () => {
281
265
  navigatorWithBeacon.sendBeacon = originalSendBeacon;
282
266
  };
283
- }, [bffCollectEvent, isActiveTargetingCookie]);
267
+ }, [bffCollectEvent]);
284
268
  (0, react_1.useEffect)(() => {
285
269
  const _originalFetch = window.fetch;
286
270
  window.fetch = function (input, init) {
@@ -300,7 +284,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
300
284
  return _originalFetch.apply(this, arguments_1);
301
285
  }
302
286
  try {
303
- if (isActiveTargetingCookie && (url.includes('https://www.google-analytics.com/g/collect') || url.includes('https://arms-retcode.aliyuncs.com/r.png'))) {
287
+ if (getTargetingCookie() && (url.includes('https://www.google-analytics.com/g/collect') || url.includes('https://arms-retcode.aliyuncs.com/r.png'))) {
304
288
  return Promise.resolve(new Response(''));
305
289
  }
306
290
  const response = _originalFetch.apply(this, arguments_1);
@@ -344,7 +328,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
344
328
  }
345
329
  });
346
330
  };
347
- }, [bffCollectEvent, isActiveTargetingCookie]);
331
+ }, [bffCollectEvent]);
348
332
  (0, react_1.useEffect)(() => {
349
333
  const originalOpen = XMLHttpRequest.prototype.open;
350
334
  const originalSend = XMLHttpRequest.prototype.send;
@@ -354,7 +338,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
354
338
  };
355
339
  XMLHttpRequest.prototype.send = function (body) {
356
340
  var _a;
357
- if (isActiveTargetingCookie && this._url && typeof this._url === 'string' && (this._url.includes('https://rumcollector.uptime.com') || this._url.includes('https://arms-retcode.aliyuncs.com/r.png') || this._url.includes('https://i.giesswein.com/nb-collector'))) {
341
+ if (getTargetingCookie() && this._url && typeof this._url === 'string' && (this._url.includes('https://rumcollector.uptime.com') || this._url.includes('https://arms-retcode.aliyuncs.com/r.png') || this._url.includes('https://i.giesswein.com/nb-collector'))) {
358
342
  return;
359
343
  }
360
344
  if (this._url && typeof this._url === 'string' && this._url.includes('https://i.giesswein.com/nb-collector')) {
@@ -382,7 +366,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
382
366
  XMLHttpRequest.prototype.open = originalOpen;
383
367
  XMLHttpRequest.prototype.send = originalSend;
384
368
  };
385
- }, [bffCollectEvent, isActiveTargetingCookie]);
369
+ }, [bffCollectEvent]);
386
370
  (0, react_1.useEffect)(() => {
387
371
  if (typeof (window === null || window === void 0 ? void 0 : window.fbq) === 'function') {
388
372
  window === null || window === void 0 ? void 0 : window.fbq('track', 'PageView');
@@ -507,9 +491,9 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
507
491
  }
508
492
  return expire;
509
493
  }, [data]);
510
- const bffEventReport = (0, react_1.useCallback)(({ userInfo, eventInfo, reportLayId = true }) => {
494
+ const bffEventReport = (0, react_1.useCallback)(({ userInfo, eventInfo, reportLayId = true, isActiveTargetingCookie = true }) => {
511
495
  var _a, _b;
512
- if (!enableReportEvent || (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.enablePreview) || isActiveTargetingCookie) {
496
+ if (!enableReportEvent || (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.enablePreview) || (isActiveTargetingCookie && getTargetingCookie())) {
513
497
  return;
514
498
  }
515
499
  if (!userInfo) {
@@ -546,8 +530,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
546
530
  layoutVariantId,
547
531
  globalConfig,
548
532
  playbookType,
549
- bffDataSource,
550
- isActiveTargetingCookie
533
+ bffDataSource
551
534
  ]);
552
535
  const getEventParamsByJson = (0, react_1.useCallback)((json, product) => {
553
536
  var _a, _b, _c;
@@ -612,7 +595,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
612
595
  }, [fakeUserId]);
613
596
  const bffFbReport = (0, react_1.useCallback)(({ eventName, product }) => {
614
597
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
615
- if (!enableReportEvent || (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.enablePreview) || isActiveTargetingCookie) {
598
+ if (!enableReportEvent || (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.enablePreview) || getTargetingCookie()) {
616
599
  return;
617
600
  }
618
601
  let isPushState = false;
@@ -678,7 +661,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
678
661
  type: 'beacon'
679
662
  });
680
663
  }
681
- }, [bffFetch, enableReportEvent, enabledMetaConversionApi, globalConfig, bffDataSource, getEventParamsByJson, isActiveTargetingCookie]);
664
+ }, [bffFetch, enableReportEvent, enabledMetaConversionApi, globalConfig, bffDataSource, getEventParamsByJson]);
682
665
  const bffMutateLike = (0, react_1.useCallback)((body) => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
683
666
  const res = yield (bffFetch === null || bffFetch === void 0 ? void 0 : bffFetch('v1/recommend/like', { method: 'POST', body }));
684
667
  return res === null || res === void 0 ? void 0 : res.success;
@@ -28,7 +28,7 @@ const Display = (_a) => {
28
28
  react_1.default.createElement("span", { style: content === null || content === void 0 ? void 0 : content.style, dangerouslySetInnerHTML: {
29
29
  __html: (0, tool_1.setFontForText)((_b = content === null || content === void 0 ? void 0 : content.text) === null || _b === void 0 ? void 0 : _b.replace(/\n/g, '</br>'), content === null || content === void 0 ? void 0 : content.style)
30
30
  } }),
31
- react_1.default.createElement("span", { style: Object.assign(Object.assign({}, interaction === null || interaction === void 0 ? void 0 : interaction.style), { marginInlineStart: '5px' }), dangerouslySetInnerHTML: {
31
+ react_1.default.createElement("span", { style: Object.assign(Object.assign({}, interaction === null || interaction === void 0 ? void 0 : interaction.style), { marginLeft: '5px' }), dangerouslySetInnerHTML: {
32
32
  __html: (0, tool_1.setFontForText)((_c = interaction === null || interaction === void 0 ? void 0 : interaction.text) === null || _c === void 0 ? void 0 : _c.replace(/\n/g, '</br>'), interaction === null || interaction === void 0 ? void 0 : interaction.style)
33
33
  }, onClick: handleClick })),
34
34
  isShowClose && (react_1.default.createElement("button", { "aria-label": 'close', className: 'consentPopupDisplay-close', onClick: handleClickClose },
@@ -3,9 +3,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.AniLinkPopup = void 0;
4
4
  const tslib_1 = require("tslib");
5
5
  const settingRender_1 = tslib_1.__importDefault(require("./settingRender"));
6
- const interactionRender_1 = tslib_1.__importDefault(require("./interactionRender"));
7
6
  const _1 = tslib_1.__importDefault(require("."));
8
7
  const create_1 = require("../../../../core/create");
8
+ const interactionRender_1 = tslib_1.__importDefault(require("./interactionRender"));
9
9
  const AniLinkPopup = (0, create_1.createMaterial)(_1.default, {
10
10
  displayName: '竖版弹窗CTA',
11
11
  icon: '',
@@ -28,6 +28,7 @@ const AniLinkPopup = (0, create_1.createMaterial)(_1.default, {
28
28
  title: {
29
29
  fontSize: 14,
30
30
  color: '#000',
31
+ textAlign: 'left',
31
32
  lineHeight: 2.6
32
33
  },
33
34
  ctaTitle: {
@@ -3,9 +3,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.CommodityDetail = void 0;
4
4
  const tslib_1 = require("tslib");
5
5
  const settingRender_1 = tslib_1.__importDefault(require("./settingRender"));
6
- const interactionRender_1 = tslib_1.__importDefault(require("./interactionRender"));
7
6
  const _1 = tslib_1.__importDefault(require("."));
8
7
  const create_1 = require("../../../../core/create");
8
+ const interactionRender_1 = tslib_1.__importDefault(require("./interactionRender"));
9
9
  const CommodityDetail = (0, create_1.createMaterial)(_1.default, {
10
10
  displayName: '商品详情',
11
11
  icon: '',
@@ -44,6 +44,7 @@ const CommodityDetail = (0, create_1.createMaterial)(_1.default, {
44
44
  taxInfo: {
45
45
  color: '#000',
46
46
  fontSize: 13,
47
+ textAlign: 'left',
47
48
  marginBottom: '10px'
48
49
  }
49
50
  },