pb-sxp-ui 1.1.2 → 1.2.1

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 (166) hide show
  1. package/dist/index.cjs +2264 -864
  2. package/dist/index.cjs.map +1 -1
  3. package/dist/index.css +356 -175
  4. package/dist/index.js +2264 -864
  5. package/dist/index.js.map +1 -1
  6. package/dist/index.min.cjs +3 -3
  7. package/dist/index.min.cjs.map +1 -1
  8. package/dist/index.min.js +3 -3
  9. package/dist/index.min.js.map +1 -1
  10. package/dist/pb-ui.js +2264 -864
  11. package/dist/pb-ui.js.map +1 -1
  12. package/dist/pb-ui.min.js +3 -3
  13. package/dist/pb-ui.min.js.map +1 -1
  14. package/es/core/Pagebuilder/type.d.ts +1 -0
  15. package/es/core/components/SxpPageRender/FingerSwipeTip/index.d.ts +0 -1
  16. package/es/core/components/SxpPageRender/FingerSwipeTip/index.js +3 -3
  17. package/es/core/components/SxpPageRender/Hashtag/index.js +1 -3
  18. package/es/core/components/SxpPageRender/Modal/index.d.ts +3 -0
  19. package/es/core/components/SxpPageRender/Modal/index.js +70 -6
  20. package/es/core/components/SxpPageRender/Navbar.js +1 -1
  21. package/es/core/components/SxpPageRender/Popup/index.js +1 -1
  22. package/es/core/components/SxpPageRender/RenderCard.d.ts +1 -0
  23. package/es/core/components/SxpPageRender/RenderCard.js +16 -12
  24. package/es/core/components/SxpPageRender/VideoWidget/index.js +10 -13
  25. package/es/core/components/SxpPageRender/WaterFall/List.js +1 -1
  26. package/es/core/components/SxpPageRender/WaterFall/WaterfallList.js +1 -1
  27. package/es/core/components/SxpPageRender/index.d.ts +3 -3
  28. package/es/core/components/SxpPageRender/index.js +51 -17
  29. package/es/core/components/SxpPageRender/typing.d.ts +1 -0
  30. package/es/core/context/SxpDataSourceProvider.d.ts +1 -0
  31. package/es/core/context/SxpDataSourceProvider.js +6 -4
  32. package/es/core/utils/localStore.d.ts +3 -0
  33. package/es/core/utils/localStore.js +8 -0
  34. package/es/materials/sxp/HashTag/material.js +1 -2
  35. package/es/materials/sxp/cta/AniLink/index.d.ts +14 -0
  36. package/es/materials/sxp/cta/AniLink/index.js +59 -0
  37. package/es/materials/sxp/cta/AniLink/interactionRender.d.ts +42 -0
  38. package/es/materials/sxp/cta/AniLink/interactionRender.js +50 -0
  39. package/es/materials/sxp/cta/AniLink/material.d.ts +2 -0
  40. package/es/materials/sxp/cta/AniLink/material.js +38 -0
  41. package/es/materials/sxp/cta/AniLink/settingRender.d.ts +73 -0
  42. package/es/materials/sxp/cta/AniLink/settingRender.js +103 -0
  43. package/es/materials/sxp/cta/AniLinkPopup/index.d.ts +17 -0
  44. package/es/materials/sxp/cta/AniLinkPopup/index.js +66 -0
  45. package/es/materials/sxp/cta/AniLinkPopup/interactionRender.d.ts +42 -0
  46. package/es/materials/sxp/cta/AniLinkPopup/interactionRender.js +50 -0
  47. package/es/materials/sxp/cta/AniLinkPopup/material.d.ts +2 -0
  48. package/es/materials/sxp/cta/AniLinkPopup/material.js +52 -0
  49. package/es/materials/sxp/cta/AniLinkPopup/settingRender.d.ts +176 -0
  50. package/es/materials/sxp/cta/AniLinkPopup/settingRender.js +249 -0
  51. package/es/materials/sxp/cta/index.d.ts +2 -0
  52. package/es/materials/sxp/cta/index.js +2 -0
  53. package/es/materials/sxp/index.d.ts +1 -0
  54. package/es/materials/sxp/index.js +1 -0
  55. package/es/materials/sxp/popup/AppointForm/Form.js +1 -1
  56. package/es/materials/sxp/popup/CommodityDetail/index.d.ts +5 -0
  57. package/es/materials/sxp/popup/CommodityDetail/index.js +43 -26
  58. package/es/materials/sxp/popup/CommodityDetail/interactionRender.d.ts +9 -0
  59. package/es/materials/sxp/popup/CommodityDetail/interactionRender.js +12 -0
  60. package/es/materials/sxp/popup/CommodityDetail/material.js +3 -1
  61. package/es/materials/sxp/popup/CommodityDetail/settingRender.d.ts +37 -0
  62. package/es/materials/sxp/popup/CommodityDetail/settingRender.js +41 -0
  63. package/es/materials/sxp/popup/CommodityDetailDiroNew/index.d.ts +5 -0
  64. package/es/materials/sxp/popup/CommodityDetailDiroNew/index.js +11 -25
  65. package/es/materials/sxp/popup/CommodityDetailDiroNew/interactionRender.d.ts +9 -0
  66. package/es/materials/sxp/popup/CommodityDetailDiroNew/interactionRender.js +12 -0
  67. package/es/materials/sxp/popup/CommodityDetailDiroNew/material.js +3 -1
  68. package/es/materials/sxp/popup/CommodityDetailDiroNew/settingRender.d.ts +37 -0
  69. package/es/materials/sxp/popup/CommodityDetailDiroNew/settingRender.js +41 -0
  70. package/es/materials/sxp/popup/CommodityList/index.d.ts +28 -0
  71. package/es/materials/sxp/popup/CommodityList/index.js +56 -0
  72. package/es/materials/sxp/popup/CommodityList/interactionRender.d.ts +8 -0
  73. package/es/materials/sxp/popup/CommodityList/interactionRender.js +11 -0
  74. package/es/materials/sxp/popup/CommodityList/material.d.ts +2 -0
  75. package/es/materials/sxp/popup/CommodityList/material.js +51 -0
  76. package/es/materials/sxp/popup/CommodityList/settingRender.d.ts +151 -0
  77. package/es/materials/sxp/popup/CommodityList/settingRender.js +207 -0
  78. package/es/materials/sxp/popup/index.d.ts +1 -0
  79. package/es/materials/sxp/popup/index.js +1 -0
  80. package/es/materials/sxp/template/Link/index.js +2 -2
  81. package/es/materials/sxp/template/MultiCommodity/index.js +2 -2
  82. package/es/materials/sxp/template/MultiCommodityDiro/index.js +2 -2
  83. package/es/materials/sxp/template/MultiCommodityDiroNew/index.js +5 -4
  84. package/es/materials/sxp/template/components/CommodityGroup.d.ts +14 -0
  85. package/es/materials/sxp/template/components/CommodityGroup.js +31 -0
  86. package/es/materials/sxp/template/components/Img.js +1 -1
  87. package/es/materials/sxp/template/components/Scroll.d.ts +2 -1
  88. package/es/materials/sxp/template/components/Scroll.js +10 -3
  89. package/es/materials/sxp/template/components/settingRender.js +0 -5
  90. package/lib/core/Pagebuilder/type.d.ts +1 -0
  91. package/lib/core/components/SxpPageRender/FingerSwipeTip/index.d.ts +0 -1
  92. package/lib/core/components/SxpPageRender/FingerSwipeTip/index.js +3 -3
  93. package/lib/core/components/SxpPageRender/Hashtag/index.js +1 -3
  94. package/lib/core/components/SxpPageRender/Modal/index.d.ts +3 -0
  95. package/lib/core/components/SxpPageRender/Modal/index.js +70 -6
  96. package/lib/core/components/SxpPageRender/Navbar.js +1 -1
  97. package/lib/core/components/SxpPageRender/Popup/index.js +1 -1
  98. package/lib/core/components/SxpPageRender/RenderCard.d.ts +1 -0
  99. package/lib/core/components/SxpPageRender/RenderCard.js +16 -12
  100. package/lib/core/components/SxpPageRender/VideoWidget/index.js +10 -13
  101. package/lib/core/components/SxpPageRender/WaterFall/List.js +1 -1
  102. package/lib/core/components/SxpPageRender/WaterFall/WaterfallList.js +1 -1
  103. package/lib/core/components/SxpPageRender/index.d.ts +3 -3
  104. package/lib/core/components/SxpPageRender/index.js +50 -16
  105. package/lib/core/components/SxpPageRender/typing.d.ts +1 -0
  106. package/lib/core/context/SxpDataSourceProvider.d.ts +1 -0
  107. package/lib/core/context/SxpDataSourceProvider.js +6 -4
  108. package/lib/core/utils/localStore.d.ts +3 -0
  109. package/lib/core/utils/localStore.js +11 -1
  110. package/lib/materials/sxp/HashTag/material.js +1 -2
  111. package/lib/materials/sxp/cta/AniLink/index.d.ts +14 -0
  112. package/lib/materials/sxp/cta/AniLink/index.js +61 -0
  113. package/lib/materials/sxp/cta/AniLink/interactionRender.d.ts +42 -0
  114. package/lib/materials/sxp/cta/AniLink/interactionRender.js +52 -0
  115. package/lib/materials/sxp/cta/AniLink/material.d.ts +2 -0
  116. package/lib/materials/sxp/cta/AniLink/material.js +42 -0
  117. package/lib/materials/sxp/cta/AniLink/settingRender.d.ts +73 -0
  118. package/lib/materials/sxp/cta/AniLink/settingRender.js +105 -0
  119. package/lib/materials/sxp/cta/AniLinkPopup/index.d.ts +17 -0
  120. package/lib/materials/sxp/cta/AniLinkPopup/index.js +68 -0
  121. package/lib/materials/sxp/cta/AniLinkPopup/interactionRender.d.ts +42 -0
  122. package/lib/materials/sxp/cta/AniLinkPopup/interactionRender.js +52 -0
  123. package/lib/materials/sxp/cta/AniLinkPopup/material.d.ts +2 -0
  124. package/lib/materials/sxp/cta/AniLinkPopup/material.js +56 -0
  125. package/lib/materials/sxp/cta/AniLinkPopup/settingRender.d.ts +176 -0
  126. package/lib/materials/sxp/cta/AniLinkPopup/settingRender.js +251 -0
  127. package/lib/materials/sxp/cta/index.d.ts +2 -0
  128. package/lib/materials/sxp/cta/index.js +5 -0
  129. package/lib/materials/sxp/index.d.ts +1 -0
  130. package/lib/materials/sxp/index.js +1 -0
  131. package/lib/materials/sxp/popup/AppointForm/Form.js +1 -1
  132. package/lib/materials/sxp/popup/CommodityDetail/index.d.ts +5 -0
  133. package/lib/materials/sxp/popup/CommodityDetail/index.js +43 -26
  134. package/lib/materials/sxp/popup/CommodityDetail/interactionRender.d.ts +9 -0
  135. package/lib/materials/sxp/popup/CommodityDetail/interactionRender.js +14 -0
  136. package/lib/materials/sxp/popup/CommodityDetail/material.js +3 -1
  137. package/lib/materials/sxp/popup/CommodityDetail/settingRender.d.ts +37 -0
  138. package/lib/materials/sxp/popup/CommodityDetail/settingRender.js +41 -0
  139. package/lib/materials/sxp/popup/CommodityDetailDiroNew/index.d.ts +5 -0
  140. package/lib/materials/sxp/popup/CommodityDetailDiroNew/index.js +11 -25
  141. package/lib/materials/sxp/popup/CommodityDetailDiroNew/interactionRender.d.ts +9 -0
  142. package/lib/materials/sxp/popup/CommodityDetailDiroNew/interactionRender.js +14 -0
  143. package/lib/materials/sxp/popup/CommodityDetailDiroNew/material.js +3 -1
  144. package/lib/materials/sxp/popup/CommodityDetailDiroNew/settingRender.d.ts +37 -0
  145. package/lib/materials/sxp/popup/CommodityDetailDiroNew/settingRender.js +41 -0
  146. package/lib/materials/sxp/popup/CommodityList/index.d.ts +28 -0
  147. package/lib/materials/sxp/popup/CommodityList/index.js +58 -0
  148. package/lib/materials/sxp/popup/CommodityList/interactionRender.d.ts +8 -0
  149. package/lib/materials/sxp/popup/CommodityList/interactionRender.js +13 -0
  150. package/lib/materials/sxp/popup/CommodityList/material.d.ts +2 -0
  151. package/lib/materials/sxp/popup/CommodityList/material.js +55 -0
  152. package/lib/materials/sxp/popup/CommodityList/settingRender.d.ts +151 -0
  153. package/lib/materials/sxp/popup/CommodityList/settingRender.js +209 -0
  154. package/lib/materials/sxp/popup/index.d.ts +1 -0
  155. package/lib/materials/sxp/popup/index.js +1 -0
  156. package/lib/materials/sxp/template/Link/index.js +2 -2
  157. package/lib/materials/sxp/template/MultiCommodity/index.js +2 -2
  158. package/lib/materials/sxp/template/MultiCommodityDiro/index.js +2 -2
  159. package/lib/materials/sxp/template/MultiCommodityDiroNew/index.js +5 -4
  160. package/lib/materials/sxp/template/components/CommodityGroup.d.ts +14 -0
  161. package/lib/materials/sxp/template/components/CommodityGroup.js +34 -0
  162. package/lib/materials/sxp/template/components/Img.js +1 -1
  163. package/lib/materials/sxp/template/components/Scroll.d.ts +2 -1
  164. package/lib/materials/sxp/template/components/Scroll.js +9 -2
  165. package/lib/materials/sxp/template/components/settingRender.js +0 -5
  166. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -405,8 +405,9 @@ const getFeSessionId = () => {
405
405
  };
406
406
 
407
407
  const FAKE_USER_KEY = 'SXP_FAKE_USER_ID';
408
- const FAKE_USER_STATE = 'FAKE_USER_STATE';
408
+ const FAKE_USER_STATE = 'FAKE_USER_STATE'; //新用户仅显示一次滑动提示
409
409
  const AGREE_POLICY = 'AGREE_POLICY';
410
+ const SLIDE_SKIP_STATE = 'SLIDE_SKIP_STATE'; //新用户滑动下一个视频跳转外链状态(触发过一次就不再触发)
410
411
  const storeAndLoadFeUserId = () => {
411
412
  let fakeUserId = window.localStorage.getItem(FAKE_USER_KEY);
412
413
  if (isEmpty(fakeUserId)) {
@@ -422,6 +423,13 @@ const getFeUserId = () => {
422
423
  }
423
424
  return isEmpty(fakeUserState);
424
425
  };
426
+ const getSlideSkipState = () => {
427
+ const slideSkipState = window.localStorage.getItem(SLIDE_SKIP_STATE);
428
+ return isEmpty(slideSkipState);
429
+ };
430
+ const setSlideSkipState = () => {
431
+ window.localStorage.setItem(SLIDE_SKIP_STATE, 'true');
432
+ };
425
433
 
426
434
  /*
427
435
  * @Author: binruan@chatlabs.com
@@ -523,7 +531,6 @@ var DataSourceType;
523
531
  (function (DataSourceType) {
524
532
  DataSourceType[DataSourceType["BFF"] = 5] = "BFF";
525
533
  })(DataSourceType || (DataSourceType = {}));
526
- const UTM_KEYS = ['utm_source', 'utm_medium', 'utm_campaign', 'utm_id', 'utm_content', 'cl_source'];
527
534
  const DEFAULT_TAG = 'FOR U';
528
535
  const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent = true, maxSize, defaultSize, isPreview = false, sxpParameter, appDomain, hashTagSize, loadingImage, isOpenHashTag = false, enabledMetaConversionApi = false, consentHeight, consentWidth, isShowTag = true, isOpenConsent = false, globalConfig, isEditor = false }) => {
529
536
  var _a, _b, _c;
@@ -605,8 +612,9 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
605
612
  };
606
613
  if (utmVal) {
607
614
  const val = (_h = (_g = (_f = utmVal === null || utmVal === void 0 ? void 0 : utmVal.split('&')) === null || _f === void 0 ? void 0 : _f.filter((val) => {
615
+ var _a, _b;
608
616
  const key = val.split('=')[0];
609
- return UTM_KEYS.includes(key);
617
+ return (_b = ((_a = sxpParameter === null || sxpParameter === void 0 ? void 0 : sxpParameter.channels) !== null && _a !== void 0 ? _a : [])) === null || _b === void 0 ? void 0 : _b.includes(key);
610
618
  })) === null || _g === void 0 ? void 0 : _g.join('&')) !== null && _h !== void 0 ? _h : '';
611
619
  query = Object.assign(Object.assign({}, query), { channel: decodeURIComponent(val) });
612
620
  }
@@ -699,8 +707,9 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
699
707
  return;
700
708
  try {
701
709
  const val = (_o = (_m = (_l = utmVal === null || utmVal === void 0 ? void 0 : utmVal.split('&')) === null || _l === void 0 ? void 0 : _l.filter((val) => {
710
+ var _a, _b;
702
711
  const key = val.split('=')[0];
703
- return UTM_KEYS.includes(key);
712
+ return (_b = ((_a = sxpParameter === null || sxpParameter === void 0 ? void 0 : sxpParameter.channels) !== null && _a !== void 0 ? _a : [])) === null || _b === void 0 ? void 0 : _b.includes(key);
704
713
  })) === null || _m === void 0 ? void 0 : _m.join('&')) !== null && _o !== void 0 ? _o : '';
705
714
  const result = yield (bffFetch === null || bffFetch === void 0 ? void 0 : bffFetch('/tag/list', { method: 'GET', query: { channel: decodeURIComponent(val) } }));
706
715
  setTagList((_q = (_p = result === null || result === void 0 ? void 0 : result.data) === null || _p === void 0 ? void 0 : _p.tags) !== null && _q !== void 0 ? _q : []);
@@ -838,7 +847,8 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
838
847
  themeTag,
839
848
  isShowConsent,
840
849
  selectTag,
841
- setSelectTag
850
+ setSelectTag,
851
+ globalConfig
842
852
  } }, isShowConsent ? (React.createElement(Consent$3, Object.assign({}, (_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))) : (render({
843
853
  rtcList,
844
854
  mutateLike: bffMutateLike,
@@ -1075,7 +1085,7 @@ var index$2 = /*#__PURE__*/Object.freeze({
1075
1085
  EditorCore: EditorCore
1076
1086
  });
1077
1087
 
1078
- var interactionRender$8 = [
1088
+ var interactionRender$d = [
1079
1089
  {
1080
1090
  title: '点击事件',
1081
1091
  child: [
@@ -1095,7 +1105,7 @@ var interactionRender$8 = [
1095
1105
  * @FilePath: \pb-sxp-ui\src\materials\sxp\popup\AppointForm\settingRender.tsx
1096
1106
  *
1097
1107
  */
1098
- var settingRender$6 = [
1108
+ var settingRender$9 = [
1099
1109
  {
1100
1110
  type: 'Text',
1101
1111
  label: '组件名称',
@@ -1347,14 +1357,14 @@ function useEventReport() {
1347
1357
  * @Author: binruan@chatlabs.com
1348
1358
  * @Date: 2024-06-27 16:22:34
1349
1359
  * @LastEditors: binruan@chatlabs.com
1350
- * @LastEditTime: 2024-07-02 10:34:34
1360
+ * @LastEditTime: 2024-07-05 14:55:25
1351
1361
  * @FilePath: \pb-sxp-ui\src\materials\sxp\popup\AppointForm\Form.tsx
1352
1362
  *
1353
1363
  */
1354
1364
  const Form = ({ layout, columns, onChange }) => {
1355
1365
  return (React.createElement(React.Fragment, null, columns === null || columns === void 0 ? void 0 : columns.map((item, index) => (React.createElement("div", { key: index, className: 'pb-appoint-form-container-item', style: { flexDirection: layout === 'horizontal' ? 'row' : 'column' } },
1356
1366
  layout !== 'inline' && React.createElement("label", { className: 'pb-appoint-form-container-label' }, item === null || item === void 0 ? void 0 : item.title),
1357
- (item === null || item === void 0 ? void 0 : item.valueType) === 'text' && (React.createElement("input", { className: 'pb-appoint-form-container-input', type: 'text', placeholder: layout === 'inline' ? item === null || item === void 0 ? void 0 : item.title : '请输入', name: item === null || item === void 0 ? void 0 : item.dataIndex, onChange: onChange })))))));
1367
+ (item === null || item === void 0 ? void 0 : item.valueType) === 'text' && (React.createElement("input", Object.assign({ className: 'pb-appoint-form-container-input', type: 'text', placeholder: layout === 'inline' ? item === null || item === void 0 ? void 0 : item.title : '请输入', name: item === null || item === void 0 ? void 0 : item.dataIndex }, (onChange && { onChange: onChange })))))))));
1358
1368
  };
1359
1369
  var Form$1 = memo(Form);
1360
1370
 
@@ -1461,9 +1471,9 @@ const AppointForm = createMaterial(AppointFormComponent, {
1461
1471
  category: 'popup',
1462
1472
  type: 'AppointForm',
1463
1473
  related: {
1464
- settingRender: settingRender$6,
1474
+ settingRender: settingRender$9,
1465
1475
  bindableProps: [],
1466
- interactionRender: interactionRender$8
1476
+ interactionRender: interactionRender$d
1467
1477
  },
1468
1478
  defaulSetting: {
1469
1479
  name: '表单',
@@ -1486,7 +1496,7 @@ const AppointForm = createMaterial(AppointFormComponent, {
1486
1496
  sort: 2
1487
1497
  });
1488
1498
 
1489
- var settingRender$5 = [
1499
+ var settingRender$8 = [
1490
1500
  {
1491
1501
  title: '商品图片',
1492
1502
  child: [
@@ -1525,6 +1535,47 @@ var settingRender$5 = [
1525
1535
  }
1526
1536
  ]
1527
1537
  },
1538
+ {
1539
+ title: '多商品切换器',
1540
+ child: [
1541
+ {
1542
+ type: 'Switch',
1543
+ name: ['props', 'commodityGroup', 'open'],
1544
+ label: '快速切换开关'
1545
+ },
1546
+ {
1547
+ type: 'Group',
1548
+ child: [
1549
+ {
1550
+ label: '居中垂直偏移',
1551
+ type: 'Number',
1552
+ name: ['props', 'commodityGroup', 'translateY'],
1553
+ min: -1000,
1554
+ addonAfter: '%',
1555
+ initialValue: 0
1556
+ }
1557
+ ]
1558
+ },
1559
+ {
1560
+ type: 'Group',
1561
+ child: [
1562
+ {
1563
+ label: '上边距',
1564
+ name: ['props', 'commodityGroup', 'style', 'marginTop'],
1565
+ type: 'Number',
1566
+ addonAfter: 'px',
1567
+ initialValue: 20
1568
+ },
1569
+ {
1570
+ label: '下边距',
1571
+ name: ['props', 'commodityGroup', 'style', 'marginBottom'],
1572
+ type: 'Number',
1573
+ addonAfter: 'px'
1574
+ }
1575
+ ]
1576
+ }
1577
+ ]
1578
+ },
1528
1579
  {
1529
1580
  title: '商品文本',
1530
1581
  child: [
@@ -8532,15 +8583,24 @@ SwiperSlide.displayName = 'SwiperSlide';
8532
8583
  * @Author: binruan@chatlabs.com
8533
8584
  * @Date: 2023-11-02 18:34:34
8534
8585
  * @LastEditors: binruan@chatlabs.com
8535
- * @LastEditTime: 2024-04-12 11:23:00
8586
+ * @LastEditTime: 2024-07-19 18:39:54
8536
8587
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\Modal\index.tsx
8537
8588
  *
8538
8589
  */
8539
- const closeIcon = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAjhJREFUWEfFlztOw0AQhmeWiJ4CCmpQ5DiRQsIJyAWg5A0lR0AIChDiCJS8ER0cADgBeRSxt4CCDgkaKiq8i+zYeWx2413HEWmiJJv9v535Z2aN8M8vFPT9z3zETD0aAUChUJjwvPFHAJhBhB3Hqd6OAsK2yyucwykAvP38eJX398Z3AJDLlVYR8ToU9Rhj25TWr9KEsKy5dULIGQCMtfZly45TvwsAstm56UwG6wA4FUFwzrdctxZBDcWSy5XWEPG8I84/GcMipdWPtgcsaz5PCHtKG0IuTiqUvjT9U/WYMG2IOPE+AP+LtCB0xKUAAyA2Xbd2o2OG0NQXvTnvhL17D7EPtH9TRCIWwkRcGYGIQgYBABuqPuHXOQBc6pw80lBGwBQiiXhsBHQhkoprA6iM6acjhDQKu5YJZW6XeOI3XJdpvfsdTu52VfXEekD8owQiXGIubpSCbhDbLu8DwKEAd+A41SOdPpE4BS0viFOtvV2iKWqUgn5x/tmS70xR01GuDSCKc86/OCcLgTyyZ0ScDGNhFAktAJV4NFJ9YyaFiAWIE+9uVkkgBgLoig8DMWAa9ro9ynkUdlW5maZDCmB6clmz0k1HH4Cs1Ezbq2p2yEpUuBOKTSZZex00RUWIrltxuuK6EOGDSbGIOPZicpMx6fny650377qNRgBgWeVFQuA+6UjVgREhGIMlSqsPUQqIbZdOOIdZQmCv2axRnU1N1+TzJYsxOEaEV8ep7frPZ7Gd0FTEdP0ft0/kMNdg0eoAAAAASUVORK5CYII=';
8540
- const Modal = ({ visible, onClose, children, modalStyle, padding, popup }) => {
8541
- var _a;
8590
+ const closeIcon$1 = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAjhJREFUWEfFlztOw0AQhmeWiJ4CCmpQ5DiRQsIJyAWg5A0lR0AIChDiCJS8ER0cADgBeRSxt4CCDgkaKiq8i+zYeWx2413HEWmiJJv9v535Z2aN8M8vFPT9z3zETD0aAUChUJjwvPFHAJhBhB3Hqd6OAsK2yyucwykAvP38eJX398Z3AJDLlVYR8ToU9Rhj25TWr9KEsKy5dULIGQCMtfZly45TvwsAstm56UwG6wA4FUFwzrdctxZBDcWSy5XWEPG8I84/GcMipdWPtgcsaz5PCHtKG0IuTiqUvjT9U/WYMG2IOPE+AP+LtCB0xKUAAyA2Xbd2o2OG0NQXvTnvhL17D7EPtH9TRCIWwkRcGYGIQgYBABuqPuHXOQBc6pw80lBGwBQiiXhsBHQhkoprA6iM6acjhDQKu5YJZW6XeOI3XJdpvfsdTu52VfXEekD8owQiXGIubpSCbhDbLu8DwKEAd+A41SOdPpE4BS0viFOtvV2iKWqUgn5x/tmS70xR01GuDSCKc86/OCcLgTyyZ0ScDGNhFAktAJV4NFJ9YyaFiAWIE+9uVkkgBgLoig8DMWAa9ro9ynkUdlW5maZDCmB6clmz0k1HH4Cs1Ezbq2p2yEpUuBOKTSZZex00RUWIrltxuuK6EOGDSbGIOPZicpMx6fny650377qNRgBgWeVFQuA+6UjVgREhGIMlSqsPUQqIbZdOOIdZQmCv2axRnU1N1+TzJYsxOEaEV8ep7frPZ7Gd0FTEdP0ft0/kMNdg0eoAAAAASUVORK5CYII=';
8591
+ const Modal = ({ visible, onClose, children, modalStyle, padding, popup, schema, fullHeight = window.innerHeight, isFullScreen = false }) => {
8592
+ var _a, _b;
8593
+ const touchRef = useRef(null);
8594
+ const fTouchRef = useRef(null);
8595
+ const touchMoveRef = useRef(null);
8596
+ const ref = useRef(null);
8597
+ const MODAL_DEF_TRANS = fullHeight * 0.2;
8598
+ const MODAL_DEF_CON_H = isFullScreen ? fullHeight : fullHeight * 0.8;
8599
+ const [modalTrans, setModalTrans] = useState(MODAL_DEF_TRANS);
8542
8600
  const [isShow, setIsShow] = useState(false);
8543
8601
  const modalEleRef = useRef(null);
8602
+ const { globalConfig, popupDetailData } = useSxpDataSource();
8603
+ const { schema: _schema } = useEditor();
8544
8604
  useEffect(() => {
8545
8605
  const parentNode = document.getElementById('sxp-render');
8546
8606
  const node = document.getElementById('pb-modal');
@@ -8556,6 +8616,12 @@ const Modal = ({ visible, onClose, children, modalStyle, padding, popup }) => {
8556
8616
  const isOpen = useMemo(() => {
8557
8617
  return ((popup === null || popup === void 0 ? void 0 : popup.id) && (popup === null || popup === void 0 ? void 0 : popup.id) !== '') || visible;
8558
8618
  }, [visible, popup]);
8619
+ const isScrollFullScreen = useMemo(() => {
8620
+ var _a, _b, _c, _d, _e;
8621
+ const schemaData = schema !== null && schema !== void 0 ? schema : _schema;
8622
+ const value = (_c = (_b = (_a = schemaData === null || schemaData === void 0 ? void 0 : schemaData.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) => (value === null || value === void 0 ? void 0 : value.id) === (popup === null || popup === void 0 ? void 0 : popup.id));
8623
+ return ((_e = (_d = value === null || value === void 0 ? void 0 : value.item) === null || _d === void 0 ? void 0 : _d.event) === null || _e === void 0 ? void 0 : _e.isScrollFullScreen) || false;
8624
+ }, [popup, schema, _schema]);
8559
8625
  useEffect(() => {
8560
8626
  if (isOpen) {
8561
8627
  setIsShow(true);
@@ -8563,6 +8629,7 @@ const Modal = ({ visible, onClose, children, modalStyle, padding, popup }) => {
8563
8629
  else {
8564
8630
  setTimeout(() => {
8565
8631
  setIsShow(false);
8632
+ setModalTrans(MODAL_DEF_TRANS);
8566
8633
  }, popup === null || popup === void 0 ? void 0 : popup.duration);
8567
8634
  }
8568
8635
  }, [isOpen, popup]);
@@ -8571,14 +8638,61 @@ const Modal = ({ visible, onClose, children, modalStyle, padding, popup }) => {
8571
8638
  const handleClose = debounce(() => {
8572
8639
  onClose === null || onClose === void 0 ? void 0 : onClose();
8573
8640
  }, 300);
8641
+ const handleTouchStart = (event) => {
8642
+ event.stopPropagation();
8643
+ touchRef.current = event.touches[0].clientY;
8644
+ fTouchRef.current = event.touches[0].clientY;
8645
+ touchMoveRef.current = true;
8646
+ };
8647
+ const handleTouchMove = (event) => {
8648
+ event.stopPropagation();
8649
+ requestAnimationFrame(() => {
8650
+ var _a;
8651
+ if (touchMoveRef.current && ((_a = ref === null || ref === void 0 ? void 0 : ref.current) === null || _a === void 0 ? void 0 : _a.scrollTop) === 0) {
8652
+ const currentY = event.touches[0].clientY;
8653
+ const diff = touchRef.current - currentY;
8654
+ touchRef.current = currentY;
8655
+ const ts = modalTrans - diff;
8656
+ if (ts > 0) {
8657
+ setModalTrans(ts);
8658
+ }
8659
+ }
8660
+ });
8661
+ };
8662
+ const handleTouchEnd = (event) => {
8663
+ var _a;
8664
+ event.stopPropagation();
8665
+ if (touchMoveRef.current && ((_a = ref === null || ref === void 0 ? void 0 : ref.current) === null || _a === void 0 ? void 0 : _a.scrollTop) === 0) {
8666
+ const diff = fTouchRef.current - touchRef.current;
8667
+ if (diff > 0) {
8668
+ setModalTrans(0);
8669
+ }
8670
+ else if (modalTrans < MODAL_DEF_TRANS && diff < 0) {
8671
+ setModalTrans(MODAL_DEF_TRANS);
8672
+ }
8673
+ else if (modalTrans >= MODAL_DEF_TRANS && diff < 0) {
8674
+ onClose === null || onClose === void 0 ? void 0 : onClose();
8675
+ }
8676
+ }
8677
+ touchMoveRef.current = false;
8678
+ };
8574
8679
  return ReactDOM.createPortal(React.createElement(React.Fragment, null, isShow && (React.createElement("div", { className: 'modal-bg', style: Object.assign({ display: 'flex', backgroundColor: isOpen ? 'rgba(0, 0, 0, 0.7)' : 'rgba(0, 0, 0, 0)' }, modalStyle), onClick: handleClose },
8575
- React.createElement("div", { className: `modal-container ${isOpen ? 'modal-popIn' : 'modal-popOut'}`, style: { padding, animationDuration: ((_a = popup === null || popup === void 0 ? void 0 : popup.duration) !== null && _a !== void 0 ? _a : 0) / 1000 + 's' }, onClick: (e) => {
8680
+ React.createElement("div", Object.assign({ className: `modal-container ${isOpen ? 'modal-popIn' : 'modal-popOut'}`, style: Object.assign({ padding, animationDuration: ((_a = popup === null || popup === void 0 ? void 0 : popup.duration) !== null && _a !== void 0 ? _a : 0) / 1000 + 's' }, (isScrollFullScreen && {
8681
+ transform: `translateY(${modalTrans}px)`
8682
+ })), onClick: (e) => {
8576
8683
  e.stopPropagation();
8577
8684
  e.preventDefault();
8578
- } },
8685
+ } }, (isScrollFullScreen && {
8686
+ onTouchMove: handleTouchMove,
8687
+ onTouchStart: handleTouchStart,
8688
+ onTouchEnd: handleTouchEnd
8689
+ })),
8579
8690
  React.createElement("div", { onClick: onClose, className: 'modal-icon-wrapper' },
8580
- React.createElement("img", { src: closeIcon, alt: 'close', className: 'modal-icon' })),
8581
- children)))), modalEleRef.current);
8691
+ React.createElement("img", { src: (_b = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.popupCloseIcon) !== null && _b !== void 0 ? _b : closeIcon$1, alt: 'close', className: 'modal-icon' })),
8692
+ React.createElement("div", { ref: ref, style: {
8693
+ height: isScrollFullScreen ? fullHeight : MODAL_DEF_CON_H,
8694
+ overflow: (isScrollFullScreen && modalTrans <= 0) || !isScrollFullScreen ? 'auto' : 'hidden'
8695
+ } }, children))))), modalEleRef.current);
8582
8696
  };
8583
8697
  var Modal$1 = memo(Modal);
8584
8698
 
@@ -8702,14 +8816,52 @@ const FormatImage = forwardRef((props, ref) => {
8702
8816
  });
8703
8817
  var FormatImage$1 = memo(FormatImage);
8704
8818
 
8819
+ const Scroll = ({ children, isPadding = true, style }) => {
8820
+ const ref = useRef();
8821
+ const { popupDetailData } = useSxpDataSource();
8822
+ useEffect(() => {
8823
+ var _a;
8824
+ (_a = ref === null || ref === void 0 ? void 0 : ref.current) === null || _a === void 0 ? void 0 : _a.swiper.slideTo(popupDetailData === null || popupDetailData === void 0 ? void 0 : popupDetailData.multiCheckIndex);
8825
+ }, [popupDetailData]);
8826
+ return (React.createElement(Swiper, { ref: ref, direction: 'horizontal', slidesPerView: 'auto', freeMode: true, mousewheel: true, modules: [freeMode, Scrollbar, Mousewheel], style: Object.assign({ padding: isPadding ? '0 12px 0 20px' : 0 }, style) }, children));
8827
+ };
8828
+ var Scroll$1 = memo(Scroll);
8829
+
8830
+ const CommodityGroup = ({ products, data, defImg, style }) => {
8831
+ var _a, _b;
8832
+ const { setPopupDetailData, popupDetailData } = useSxpDataSource();
8833
+ const [check, setCheck] = useState((_a = popupDetailData === null || popupDetailData === void 0 ? void 0 : popupDetailData.multiCheckIndex) !== null && _a !== void 0 ? _a : 0);
8834
+ const handleClick = useCallback((index) => {
8835
+ setPopupDetailData === null || setPopupDetailData === void 0 ? void 0 : setPopupDetailData((val) => (Object.assign(Object.assign({}, val), { video: Object.assign(Object.assign({}, val === null || val === void 0 ? void 0 : val.video), { bindProduct: products === null || products === void 0 ? void 0 : products[index] }), multiCheckIndex: index })));
8836
+ }, []);
8837
+ return (React.createElement(React.Fragment, null, (data === null || data === void 0 ? void 0 : data.open) && ((products && (products === null || products === void 0 ? void 0 : products.length) > 0) || !popupDetailData) && (React.createElement(Scroll$1, { isPadding: false, style: Object.assign(Object.assign({}, style), data === null || data === void 0 ? void 0 : data.style) }, (_b = (popupDetailData ? products : [0, 1, 2, 3])) === null || _b === void 0 ? void 0 : _b.map((item, index) => {
8838
+ var _a, _b, _c;
8839
+ return (React.createElement(SwiperSlide, { className: css({
8840
+ width: '50px',
8841
+ height: '50px',
8842
+ marginRight: '10px'
8843
+ }), onClick: () => handleClick(index), key: index },
8844
+ React.createElement(FormatImage$1, { style: {
8845
+ height: '100%',
8846
+ width: '100%',
8847
+ objectFit: 'cover',
8848
+ display: 'block',
8849
+ objectPosition: `50% ${(data === null || data === void 0 ? void 0 : data.translateY) ? -(data === null || data === void 0 ? void 0 : data.translateY) + 50 : 50}%`,
8850
+ border: check === index ? '1px solid #000' : '1px solid #f2f2f2'
8851
+ }, src: (_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 : defImg })));
8852
+ })))));
8853
+ };
8854
+ var CommodityGroup$1 = memo(CommodityGroup);
8855
+
8705
8856
  const CommodityDetail$1 = (_a) => {
8706
8857
  var _b, _c, _d, _e, _f, _g, _h, _j, _k;
8707
- var { content, style, bgImg, onClick, schema, isDefault, bottom_image, tipText, isPost, viewTime, rec, swiper, commodityStyles, buttonStyle, index } = _a, props = __rest(_a, ["content", "style", "bgImg", "onClick", "schema", "isDefault", "bottom_image", "tipText", "isPost", "viewTime", "rec", "swiper", "commodityStyles", "buttonStyle", "index"]);
8858
+ var { content, style, bgImg, onClick, schema, isDefault, bottom_image, tipText, isPost, viewTime, rec, swiper, commodityStyles, buttonStyle, index, commodityGroup } = _a, props = __rest(_a, ["content", "style", "bgImg", "onClick", "schema", "isDefault", "bottom_image", "tipText", "isPost", "viewTime", "rec", "swiper", "commodityStyles", "buttonStyle", "index", "commodityGroup"]);
8708
8859
  const { sxpParameter } = useSxpDataSource();
8709
8860
  const { popupDetailData, bffEventReport, isPreview, bffFbReport } = useSxpDataSource();
8710
8861
  const { jumpToWeb, productView } = useEventReport();
8711
8862
  const curTimeRef = useRef(null);
8712
8863
  const [showModal, setShowModal] = useState(false);
8864
+ const [show3DModal, setShow3DModal] = useState(false);
8713
8865
  const data = isPost ? rec : popupDetailData;
8714
8866
  const product = isPost ? data === null || data === void 0 ? void 0 : data.product : (_b = data === null || data === void 0 ? void 0 : data.video) === null || _b === void 0 ? void 0 : _b.bindProduct;
8715
8867
  const cta = isPost ? (_c = data === null || data === void 0 ? void 0 : data.product) === null || _c === void 0 ? void 0 : _c.bindCta : (_e = (_d = data === null || data === void 0 ? void 0 : data.video) === null || _d === void 0 ? void 0 : _d.bindProduct) === null || _e === void 0 ? void 0 : _e.bindCta;
@@ -8784,31 +8936,39 @@ const CommodityDetail$1 = (_a) => {
8784
8936
  }
8785
8937
  return style;
8786
8938
  }, []);
8787
- return (React.createElement("div", { className: 'pb-commondity' },
8939
+ const renderCommodityGroup = useCallback(() => {
8940
+ var _a, _b, _c;
8941
+ if (isPost)
8942
+ return;
8943
+ return (React.createElement(CommodityGroup$1, { products: (_a = data === null || data === void 0 ? void 0 : data.video) === null || _a === void 0 ? void 0 : _a.bindProducts, data: commodityGroup, defImg: (_c = (_b = sxpParameter === null || sxpParameter === void 0 ? void 0 : sxpParameter.bottom_image) !== null && _b !== void 0 ? _b : bottom_image) !== null && _c !== void 0 ? _c : '', style: { padding: '0 19px' } }));
8944
+ }, []);
8945
+ return (React.createElement(React.Fragment, null,
8788
8946
  React.createElement("div", Object.assign({ className: css(Object.assign({}, style)) }, props),
8789
- product && ((_g = product === null || product === void 0 ? void 0 : product.homePage) === null || _g === void 0 ? void 0 : _g.length) > 0 && (React.createElement(Swiper, { height: width, modules: [Pagination, Autoplay], pagination: {
8790
- clickable: true,
8791
- bulletActiveClass: 'swipe-item-active-bullet',
8792
- clickableClass: (swiper === null || swiper === void 0 ? void 0 : swiper.dotsAlign) === 'left'
8793
- ? 'commondityDetail-swiper-clickable-left'
8794
- : 'commondityDetail-swiper-clickable-center'
8795
- }, loop: true, autoplay: {
8796
- delay: (swiper === null || swiper === void 0 ? void 0 : swiper.delay) * 1000
8797
- } }, (_h = product === null || product === void 0 ? void 0 : product.homePage) === null || _h === void 0 ? void 0 : _h.map((src) => {
8798
- return (React.createElement(SwiperSlide, { key: src },
8799
- React.createElement("div", { style: {
8800
- overflow: 'hidden',
8801
- width,
8802
- height: width
8803
- } },
8804
- React.createElement(FormatImage$1, { style: {
8805
- height: '100%',
8806
- width: '100%',
8807
- objectFit: 'cover',
8808
- display: 'block',
8809
- objectPosition: `50% ${(swiper === null || swiper === void 0 ? void 0 : swiper.translateY) ? (swiper === null || swiper === void 0 ? void 0 : swiper.translateY) + 50 : 50}%`
8810
- }, src: src }))));
8811
- }))),
8947
+ product && ((_g = product === null || product === void 0 ? void 0 : product.homePage) === null || _g === void 0 ? void 0 : _g.length) > 0 && (React.createElement("div", { style: { position: 'relative' } },
8948
+ React.createElement(Swiper, { height: width, modules: [Pagination, Autoplay], pagination: {
8949
+ clickable: true,
8950
+ bulletActiveClass: 'swipe-item-active-bullet',
8951
+ clickableClass: (swiper === null || swiper === void 0 ? void 0 : swiper.dotsAlign) === 'left'
8952
+ ? 'commondityDetail-swiper-clickable-left'
8953
+ : 'commondityDetail-swiper-clickable-center'
8954
+ }, loop: true, autoplay: {
8955
+ delay: (swiper === null || swiper === void 0 ? void 0 : swiper.delay) * 1000
8956
+ } },
8957
+ React.createElement(React.Fragment, null, (_h = product === null || product === void 0 ? void 0 : product.homePage) === null || _h === void 0 ? void 0 : _h.map((src) => {
8958
+ return (React.createElement(SwiperSlide, { key: src },
8959
+ React.createElement("div", { style: {
8960
+ overflow: 'hidden',
8961
+ width,
8962
+ height: width
8963
+ } },
8964
+ React.createElement(FormatImage$1, { style: {
8965
+ height: '100%',
8966
+ width: '100%',
8967
+ objectFit: 'cover',
8968
+ display: 'block',
8969
+ objectPosition: `50% ${(swiper === null || swiper === void 0 ? void 0 : swiper.translateY) ? -(swiper === null || swiper === void 0 ? void 0 : swiper.translateY) + 50 : 50}%`
8970
+ }, src: src }))));
8971
+ }))))),
8812
8972
  !((_j = product === null || product === void 0 ? void 0 : product.homePage) === null || _j === void 0 ? void 0 : _j.length) && (React.createElement("div", { className: css({
8813
8973
  position: 'relative',
8814
8974
  height: 0,
@@ -8823,19 +8983,55 @@ const CommodityDetail$1 = (_a) => {
8823
8983
  objectFit: 'cover',
8824
8984
  width: '100%'
8825
8985
  }), src: (_k = sxpParameter === null || sxpParameter === void 0 ? void 0 : sxpParameter.bottom_image) !== null && _k !== void 0 ? _k : bottom_image, alt: 'pdp image' }))),
8986
+ renderCommodityGroup(),
8826
8987
  React.createElement("div", { className: 'pb-commondity-content' }, renderContent({ isPost }))),
8827
8988
  renderBtn(),
8828
8989
  React.createElement(Modal$1, { visible: showModal, onClose: () => setShowModal(false) },
8829
8990
  React.createElement("div", { style: { paddingBottom: '80px' } }, renderContent({ isPost: false })),
8830
- renderBtn())));
8991
+ renderBtn()),
8992
+ React.createElement(Modal$1, { visible: show3DModal, padding: 0, isFullScreen: true, onClose: () => setShow3DModal(false) },
8993
+ React.createElement("iframe", { src: 'https://rimowa.threedium.co.uk/product-experience/latest/?sku=92573974&lang=en', style: {
8994
+ width: '100%',
8995
+ height: 'calc(100% - 40px)',
8996
+ marginTop: '40px'
8997
+ } }))));
8831
8998
  };
8832
8999
  var CommodityDetailComponent = memo(CommodityDetail$1);
8833
9000
 
9001
+ /*
9002
+ * @Author: binruan@chatlabs.com
9003
+ * @Date: 2024-07-09 14:35:10
9004
+ * @LastEditors: binruan@chatlabs.com
9005
+ * @LastEditTime: 2024-07-12 17:53:02
9006
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\popup\CommodityDetail\interactionRender.tsx
9007
+ *
9008
+ */
9009
+ /*
9010
+ * @Author: binruan@chatlabs.com
9011
+ * @Date: 2024-07-05 14:08:41
9012
+ * @LastEditors: binruan@chatlabs.com
9013
+ * @LastEditTime: 2024-07-09 14:34:49
9014
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\cta\AniLink\interactionRender.tsx
9015
+ *
9016
+ */
9017
+ var interactionRender$c = [
9018
+ {
9019
+ title: '滑动事件',
9020
+ child: [
9021
+ {
9022
+ type: 'Switch',
9023
+ label: '滑动铺满全屏',
9024
+ name: ['isScrollFullScreen']
9025
+ }
9026
+ ]
9027
+ }
9028
+ ];
9029
+
8834
9030
  /*
8835
9031
  * @Author: binruan@chatlabs.com
8836
9032
  * @Date: 2023-07-28 18:29:57
8837
9033
  * @LastEditors: binruan@chatlabs.com
8838
- * @LastEditTime: 2024-04-02 18:13:10
9034
+ * @LastEditTime: 2024-07-12 17:40:06
8839
9035
  * @FilePath: \pb-sxp-ui\src\materials\sxp\popup\CommodityDetail\material.tsx
8840
9036
  *
8841
9037
  */
@@ -8845,7 +9041,8 @@ const CommodityDetail = createMaterial(CommodityDetailComponent, {
8845
9041
  category: 'popup',
8846
9042
  type: 'CommodityDetail',
8847
9043
  related: {
8848
- settingRender: settingRender$5
9044
+ settingRender: settingRender$8,
9045
+ interactionRender: interactionRender$c
8849
9046
  },
8850
9047
  defaulSetting: {
8851
9048
  props: {
@@ -8890,7 +9087,7 @@ const CommodityDetail = createMaterial(CommodityDetailComponent, {
8890
9087
  sort: 1
8891
9088
  });
8892
9089
 
8893
- var interactionRender$7 = [
9090
+ var interactionRender$b = [
8894
9091
  {
8895
9092
  title: '点击事件',
8896
9093
  child: [
@@ -8910,7 +9107,7 @@ var interactionRender$7 = [
8910
9107
  * @FilePath: \pb-sxp-ui\src\materials\sxp\popup\Prompt\settingRender.tsx
8911
9108
  *
8912
9109
  */
8913
- var settingRender$4 = [
9110
+ var settingRender$7 = [
8914
9111
  {
8915
9112
  title: '',
8916
9113
  child: [
@@ -9080,9 +9277,9 @@ const Prompt = createMaterial(PromptComponent, {
9080
9277
  category: 'popup',
9081
9278
  type: 'Prompt',
9082
9279
  related: {
9083
- settingRender: settingRender$4,
9280
+ settingRender: settingRender$7,
9084
9281
  bindableProps: [],
9085
- interactionRender: interactionRender$7
9282
+ interactionRender: interactionRender$b
9086
9283
  },
9087
9284
  defaulSetting: {
9088
9285
  props: {
@@ -9101,11 +9298,11 @@ const Prompt = createMaterial(PromptComponent, {
9101
9298
  * @Author: binruan@chatlabs.com
9102
9299
  * @Date: 2024-03-26 16:50:25
9103
9300
  * @LastEditors: binruan@chatlabs.com
9104
- * @LastEditTime: 2024-06-27 09:54:23
9301
+ * @LastEditTime: 2024-07-12 14:44:50
9105
9302
  * @FilePath: \pb-sxp-ui\src\materials\sxp\popup\CommodityDetailDiroNew\settingRender.tsx
9106
9303
  *
9107
9304
  */
9108
- var settingRender$3 = [
9305
+ var settingRender$6 = [
9109
9306
  {
9110
9307
  title: '商品图片',
9111
9308
  child: [
@@ -9144,6 +9341,47 @@ var settingRender$3 = [
9144
9341
  }
9145
9342
  ]
9146
9343
  },
9344
+ {
9345
+ title: '多商品切换器',
9346
+ child: [
9347
+ {
9348
+ type: 'Switch',
9349
+ name: ['props', 'commodityGroup', 'open'],
9350
+ label: '快速切换开关'
9351
+ },
9352
+ {
9353
+ type: 'Group',
9354
+ child: [
9355
+ {
9356
+ label: '居中垂直偏移',
9357
+ type: 'Number',
9358
+ name: ['props', 'commodityGroup', 'translateY'],
9359
+ min: -1000,
9360
+ addonAfter: '%',
9361
+ initialValue: 0
9362
+ }
9363
+ ]
9364
+ },
9365
+ {
9366
+ type: 'Group',
9367
+ child: [
9368
+ {
9369
+ label: '上边距',
9370
+ name: ['props', 'commodityGroup', 'style', 'marginTop'],
9371
+ type: 'Number',
9372
+ addonAfter: 'px',
9373
+ initialValue: 20
9374
+ },
9375
+ {
9376
+ label: '下边距',
9377
+ name: ['props', 'commodityGroup', 'style', 'marginBottom'],
9378
+ type: 'Number',
9379
+ addonAfter: 'px'
9380
+ }
9381
+ ]
9382
+ }
9383
+ ]
9384
+ },
9147
9385
  {
9148
9386
  title: '商品文本',
9149
9387
  child: [
@@ -9314,14 +9552,11 @@ var settingRender$3 = [
9314
9552
 
9315
9553
  const CommodityDetailDiroNew$1 = (_a) => {
9316
9554
  var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
9317
- var { style, isDefault, rec, viewTime, isPost, bottom_image, tipText, swiper, commodityStyles, buttonStyle, index } = _a, props = __rest(_a, ["style", "isDefault", "rec", "viewTime", "isPost", "bottom_image", "tipText", "swiper", "commodityStyles", "buttonStyle", "index"]);
9555
+ var { style, isDefault, rec, viewTime, isPost, bottom_image, tipText, swiper, commodityStyles, buttonStyle, index, commodityGroup } = _a, props = __rest(_a, ["style", "isDefault", "rec", "viewTime", "isPost", "bottom_image", "tipText", "swiper", "commodityStyles", "buttonStyle", "index", "commodityGroup"]);
9318
9556
  useState(true);
9319
9557
  const { sxpParameter } = useSxpDataSource();
9320
9558
  const { popupDetailData, bffEventReport, isPreview, swiperRef, bffFbReport } = useSxpDataSource();
9321
9559
  const { jumpToWeb, productView } = useEventReport();
9322
- const scrollRef = useRef(null);
9323
- useRef(null);
9324
- useRef(null);
9325
9560
  useState(false);
9326
9561
  useState(false);
9327
9562
  useState(true);
@@ -9369,6 +9604,56 @@ const CommodityDetailDiroNew$1 = (_a) => {
9369
9604
  }
9370
9605
  }, [product === null || product === void 0 ? void 0 : product.price, product === null || product === void 0 ? void 0 : product.currency]);
9371
9606
  const width = isPreview ? 375 : (_f = style === null || style === void 0 ? void 0 : style.width) !== null && _f !== void 0 ? _f : window.innerWidth;
9607
+ // useEffect(() => {
9608
+ // console.log(scrollRef?.current?.scrollHeight, window.innerHeight);
9609
+ // if (scrollRef?.current && scrollRef?.current?.scrollHeight > window.innerHeight) {
9610
+ // setStopSlide(true);
9611
+ // }
9612
+ // }, [scrollRef]);
9613
+ // useEffect(() => {
9614
+ // const handleScroll = () => {
9615
+ // if (scrollRef?.current) {
9616
+ // const { scrollTop, scrollHeight, clientHeight } = scrollRef.current;
9617
+ // const isBottom = scrollTop + clientHeight === scrollHeight;
9618
+ // if (isBottom) {
9619
+ // setIsBottom(true);
9620
+ // } else {
9621
+ // setIsBottom(false);
9622
+ // }
9623
+ // if (scrollTop === 0) {
9624
+ // setIsTop(true);
9625
+ // } else {
9626
+ // setIsTop(false);
9627
+ // }
9628
+ // }
9629
+ // };
9630
+ // if (scrollRef.current) {
9631
+ // scrollRef.current.addEventListener('scroll', handleScroll);
9632
+ // }
9633
+ // return () => {
9634
+ // if (scrollRef.current) {
9635
+ // scrollRef.current.removeEventListener('scroll', handleScroll);
9636
+ // }
9637
+ // };
9638
+ // }, [scrollRef]);
9639
+ // const handleTouchStart = (event: any) => {
9640
+ // event.stopPropagation();
9641
+ // touchRef.current = event.touches[0].clientY;
9642
+ // touchMoveRef.current = true;
9643
+ // };
9644
+ // const handleTouchMove = (event: any) => {
9645
+ // event.stopPropagation();
9646
+ // if (touchMoveRef.current) {
9647
+ // touchMoveRef.current = false;
9648
+ // const currentY = event.touches[0].clientY;
9649
+ // const diff = touchRef.current - currentY;
9650
+ // if (diff > 0 && (isBottom || !stopSlide)) {
9651
+ // swiperRef?.current?.swiper?.slideNext();
9652
+ // } else if (diff < 0 && (isTop || !stopSlide)) {
9653
+ // swiperRef?.current?.swiper?.slidePrev();
9654
+ // }
9655
+ // }
9656
+ // };
9372
9657
  const productInfoText = ({ isPost }) => {
9373
9658
  return (React.createElement("div", { hidden: !!product && (!(product === null || product === void 0 ? void 0 : product.info) || (product === null || product === void 0 ? void 0 : product.info) === '') },
9374
9659
  React.createElement(ExpandableText$1, { isPost: isPost, onClick: () => setShowModal(true), className: 'pb-commondityDiroNew-info', style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.info, foldText: tipText === null || tipText === void 0 ? void 0 : tipText.foldText, unfoldText: tipText === null || tipText === void 0 ? void 0 : tipText.unfoldText, text: (product === null || product === void 0 ? void 0 : product.info) ||
@@ -9381,8 +9666,14 @@ Made in Italy` })));
9381
9666
  }
9382
9667
  return style;
9383
9668
  }, []);
9669
+ const renderCommodityGroup = useCallback(() => {
9670
+ var _a, _b, _c;
9671
+ if (isPost)
9672
+ return;
9673
+ return (React.createElement(CommodityGroup$1, { products: (_a = data === null || data === void 0 ? void 0 : data.video) === null || _a === void 0 ? void 0 : _a.bindProducts, data: commodityGroup, defImg: (_c = (_b = sxpParameter === null || sxpParameter === void 0 ? void 0 : sxpParameter.bottom_image) !== null && _b !== void 0 ? _b : bottom_image) !== null && _c !== void 0 ? _c : '', style: { padding: '0 19px' } }));
9674
+ }, []);
9384
9675
  return (React.createElement("div", { className: 'pb-commondityDiroNew' },
9385
- React.createElement("div", Object.assign({ ref: scrollRef, className: css(Object.assign({}, style)) }, props),
9676
+ React.createElement("div", Object.assign({ className: css(Object.assign({}, style)) }, props),
9386
9677
  product && ((_g = product === null || product === void 0 ? void 0 : product.homePage) === null || _g === void 0 ? void 0 : _g.length) > 0 && (React.createElement(Swiper, { height: width, modules: [Pagination, Autoplay], pagination: {
9387
9678
  clickable: true,
9388
9679
  bulletActiveClass: 'commondityDiroNew-swipe-item-active-bullet',
@@ -9403,7 +9694,7 @@ Made in Italy` })));
9403
9694
  width: '100%',
9404
9695
  objectFit: 'cover',
9405
9696
  display: 'block',
9406
- objectPosition: `50% ${(swiper === null || swiper === void 0 ? void 0 : swiper.translateY) ? (swiper === null || swiper === void 0 ? void 0 : swiper.translateY) + 50 : 50}%`
9697
+ objectPosition: `50% ${(swiper === null || swiper === void 0 ? void 0 : swiper.translateY) ? -(swiper === null || swiper === void 0 ? void 0 : swiper.translateY) + 50 : 50}%`
9407
9698
  }, src: src }))));
9408
9699
  }))),
9409
9700
  !((_j = product === null || product === void 0 ? void 0 : product.homePage) === null || _j === void 0 ? void 0 : _j.length) && (React.createElement("div", { className: css({
@@ -9420,6 +9711,7 @@ Made in Italy` })));
9420
9711
  objectFit: 'cover',
9421
9712
  width: '100%'
9422
9713
  }), src: (_k = sxpParameter === null || sxpParameter === void 0 ? void 0 : sxpParameter.bottom_image) !== null && _k !== void 0 ? _k : bottom_image, alt: 'pdp image' }))),
9714
+ renderCommodityGroup(),
9423
9715
  React.createElement("div", { className: 'pb-commondityDiroNew-content' },
9424
9716
  React.createElement("div", { className: 'pb-commondityDiroNew-content-top' },
9425
9717
  React.createElement("div", { className: 'pb-commondityDiroNew-content-top-left' },
@@ -9445,11 +9737,40 @@ Made in Italy` })));
9445
9737
  };
9446
9738
  var CommodityDetailDiroNewComponent = memo(CommodityDetailDiroNew$1);
9447
9739
 
9740
+ /*
9741
+ * @Author: binruan@chatlabs.com
9742
+ * @Date: 2024-07-09 14:35:10
9743
+ * @LastEditors: binruan@chatlabs.com
9744
+ * @LastEditTime: 2024-07-12 17:53:02
9745
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\popup\CommodityDetail\interactionRender.tsx
9746
+ *
9747
+ */
9748
+ /*
9749
+ * @Author: binruan@chatlabs.com
9750
+ * @Date: 2024-07-05 14:08:41
9751
+ * @LastEditors: binruan@chatlabs.com
9752
+ * @LastEditTime: 2024-07-09 14:34:49
9753
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\cta\AniLink\interactionRender.tsx
9754
+ *
9755
+ */
9756
+ var interactionRender$a = [
9757
+ {
9758
+ title: '滑动事件',
9759
+ child: [
9760
+ {
9761
+ type: 'Switch',
9762
+ label: '滑动铺满全屏',
9763
+ name: ['isScrollFullScreen']
9764
+ }
9765
+ ]
9766
+ }
9767
+ ];
9768
+
9448
9769
  /*
9449
9770
  * @Author: binruan@chatlabs.com
9450
9771
  * @Date: 2024-03-20 10:27:31
9451
9772
  * @LastEditors: binruan@chatlabs.com
9452
- * @LastEditTime: 2024-04-09 16:25:44
9773
+ * @LastEditTime: 2024-07-12 18:17:31
9453
9774
  * @FilePath: \pb-sxp-ui\src\materials\sxp\popup\CommodityDetailDiroNew\material.tsx
9454
9775
  *
9455
9776
  */
@@ -9459,7 +9780,8 @@ const CommodityDetailDiroNew = createMaterial(CommodityDetailDiroNewComponent, {
9459
9780
  category: 'popup',
9460
9781
  type: 'CommodityDetailDiroNew',
9461
9782
  related: {
9462
- settingRender: settingRender$3
9783
+ settingRender: settingRender$6,
9784
+ interactionRender: interactionRender$a
9463
9785
  },
9464
9786
  defaulSetting: {
9465
9787
  props: {
@@ -9515,66 +9837,11 @@ const CommodityDetailDiroNew = createMaterial(CommodityDetailDiroNewComponent, {
9515
9837
  * @Author: binruan@chatlabs.com
9516
9838
  * @Date: 2024-03-26 16:50:25
9517
9839
  * @LastEditors: binruan@chatlabs.com
9518
- * @LastEditTime: 2024-07-04 17:47:52
9519
- * @FilePath: \pb-sxp-ui\src\materials\sxp\template\components\settingRender.tsx
9840
+ * @LastEditTime: 2024-07-09 10:37:45
9841
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\popup\CommodityList\settingRender.tsx
9520
9842
  *
9521
9843
  */
9522
- var settingRender$2 = [
9523
- {
9524
- title: '主题样式',
9525
- child: [
9526
- {
9527
- type: 'Group',
9528
- label: '尺寸',
9529
- child: [
9530
- {
9531
- type: 'Number',
9532
- name: ['style', 'width'],
9533
- addonAfter: 'W'
9534
- },
9535
- {
9536
- type: 'Number',
9537
- name: ['style', 'height'],
9538
- addonAfter: 'H'
9539
- }
9540
- ]
9541
- },
9542
- {
9543
- type: 'Group',
9544
- label: '圆角',
9545
- child: [
9546
- {
9547
- type: 'Slider',
9548
- name: ['style', 'borderRadius'],
9549
- max: 100
9550
- },
9551
- {
9552
- type: 'Number',
9553
- name: ['style', 'borderRadius'],
9554
- addonAfter: 'px',
9555
- max: 100
9556
- }
9557
- ]
9558
- },
9559
- {
9560
- type: 'Color',
9561
- label: '背景色',
9562
- name: ['style', 'backgroundColor']
9563
- },
9564
- {
9565
- label: '内边距',
9566
- type: 'Number',
9567
- name: ['style', 'padding'],
9568
- addonAfter: 'px'
9569
- },
9570
- {
9571
- label: '与Post描述边距',
9572
- type: 'Number',
9573
- name: ['style', 'marginBottom'],
9574
- addonAfter: 'px'
9575
- }
9576
- ]
9577
- },
9844
+ var settingRender$5 = [
9578
9845
  {
9579
9846
  title: '商品图片',
9580
9847
  child: [
@@ -9584,12 +9851,12 @@ var settingRender$2 = [
9584
9851
  child: [
9585
9852
  {
9586
9853
  type: 'Number',
9587
- name: ['props', 'ctaTempStyles', 'img', 'width'],
9854
+ name: ['props', 'commodityPicture', 'width'],
9588
9855
  addonAfter: 'W'
9589
9856
  },
9590
9857
  {
9591
9858
  type: 'Number',
9592
- name: ['props', 'ctaTempStyles', 'img', 'height'],
9859
+ name: ['props', 'commodityPicture', 'height'],
9593
9860
  addonAfter: 'H'
9594
9861
  }
9595
9862
  ]
@@ -9600,12 +9867,12 @@ var settingRender$2 = [
9600
9867
  child: [
9601
9868
  {
9602
9869
  type: 'Slider',
9603
- name: ['props', 'ctaTempStyles', 'img', 'borderRadius'],
9870
+ name: ['props', 'commodityPicture', 'borderRadius'],
9604
9871
  max: 100
9605
9872
  },
9606
9873
  {
9607
9874
  type: 'Number',
9608
- name: ['props', 'ctaTempStyles', 'img', 'borderRadius'],
9875
+ name: ['props', 'commodityPicture', 'borderRadius'],
9609
9876
  addonAfter: 'px',
9610
9877
  max: 100
9611
9878
  }
@@ -9615,7 +9882,7 @@ var settingRender$2 = [
9615
9882
  type: 'Number',
9616
9883
  label: '与右侧边距',
9617
9884
  addonAfter: 'px',
9618
- name: ['props', 'ctaTempStyles', 'img', 'marginRight']
9885
+ name: ['props', 'commodityPicture', 'marginRight']
9619
9886
  },
9620
9887
  {
9621
9888
  label: '居中垂直偏移',
@@ -9628,72 +9895,90 @@ var settingRender$2 = [
9628
9895
  ]
9629
9896
  },
9630
9897
  {
9631
- title: '商品标题文本',
9632
- type: 'commodityTitle',
9898
+ title: '商品文本',
9633
9899
  child: [
9634
9900
  {
9635
- type: 'Group',
9636
- label: '字体',
9901
+ name: ['props', 'commodityStyles'],
9902
+ type: 'SelectLinkage',
9637
9903
  child: [
9638
9904
  {
9905
+ label: '字段',
9639
9906
  type: 'Select',
9640
- name: ['props', 'ctaTempStyles', 'title', 'fontFamily-cn'],
9641
- bottomText: '中文字体'
9907
+ options: [
9908
+ {
9909
+ label: '商品名称',
9910
+ value: 'title'
9911
+ },
9912
+ {
9913
+ label: '系列名称',
9914
+ value: 'collection'
9915
+ },
9916
+ {
9917
+ label: '价格',
9918
+ value: 'price'
9919
+ }
9920
+ ],
9921
+ name: ['props', 'commodityStyles', 'field'],
9922
+ initialValue: 'title'
9642
9923
  },
9643
9924
  {
9644
- type: 'Select',
9645
- name: ['props', 'ctaTempStyles', 'title', 'fontFamily-en'],
9646
- bottomText: '英文/其他字体'
9647
- }
9648
- ]
9649
- },
9650
- {
9651
- type: 'Group',
9652
- label: '',
9653
- child: [
9925
+ type: 'Group',
9926
+ label: '标题字体',
9927
+ child: [
9928
+ {
9929
+ type: 'Select',
9930
+ name: ['fontFamily-cn'],
9931
+ bottomText: '中文字体'
9932
+ },
9933
+ {
9934
+ type: 'Select',
9935
+ name: ['fontFamily-en'],
9936
+ bottomText: '英文/其他字体'
9937
+ }
9938
+ ]
9939
+ },
9654
9940
  {
9655
- type: 'Color',
9656
- name: ['props', 'ctaTempStyles', 'title', 'color']
9941
+ type: 'Group',
9942
+ label: '',
9943
+ child: [
9944
+ {
9945
+ type: 'Color',
9946
+ name: ['color']
9947
+ },
9948
+ {
9949
+ type: 'Number',
9950
+ addonAfter: 'px',
9951
+ name: ['fontSize']
9952
+ }
9953
+ ]
9657
9954
  },
9658
9955
  {
9659
- type: 'Number',
9660
- addonAfter: 'px',
9661
- name: ['props', 'ctaTempStyles', 'title', 'fontSize']
9956
+ label: '标题样式',
9957
+ type: 'TextStyle'
9958
+ },
9959
+ {
9960
+ label: '标题对齐',
9961
+ type: 'TextAlign'
9662
9962
  }
9663
9963
  ]
9664
- },
9665
- {
9666
- label: '样式',
9667
- type: 'TextStyle',
9668
- name: ['props', 'ctaTempStyles', 'title']
9669
- },
9670
- {
9671
- label: '对齐',
9672
- type: 'TextAlign',
9673
- name: ['props', 'ctaTempStyles', 'title']
9674
- },
9675
- {
9676
- label: '间距',
9677
- type: 'TextSpace',
9678
- name: ['props', 'ctaTempStyles', 'title']
9679
9964
  }
9680
9965
  ]
9681
9966
  },
9682
9967
  {
9683
- title: 'CTA标题',
9968
+ title: '按钮样式',
9684
9969
  child: [
9970
+ {
9971
+ type: 'Color',
9972
+ label: '背景色',
9973
+ name: ['props', 'buttonStyle', 'backgroundColor']
9974
+ },
9685
9975
  {
9686
9976
  type: 'Group',
9687
9977
  label: '尺寸',
9688
9978
  child: [
9689
9979
  {
9690
9980
  type: 'Number',
9691
- name: ['props', 'ctaTempStyles', 'ctaTitle', 'width'],
9692
- addonAfter: 'W'
9693
- },
9694
- {
9695
- type: 'Number',
9696
- name: ['props', 'ctaTempStyles', 'ctaTitle', 'height'],
9981
+ name: ['props', 'buttonStyle', 'height'],
9697
9982
  addonAfter: 'H'
9698
9983
  }
9699
9984
  ]
@@ -9704,21 +9989,20 @@ var settingRender$2 = [
9704
9989
  child: [
9705
9990
  {
9706
9991
  type: 'Slider',
9707
- name: ['props', 'ctaTempStyles', 'ctaTitle', 'borderRadius'],
9992
+ name: ['props', 'buttonStyle', 'borderRadius'],
9708
9993
  max: 100
9709
9994
  },
9710
9995
  {
9711
9996
  type: 'Number',
9712
- name: ['props', 'ctaTempStyles', 'ctaTitle', 'borderRadius'],
9997
+ name: ['props', 'buttonStyle', 'borderRadius'],
9713
9998
  addonAfter: 'px',
9714
9999
  max: 100
9715
10000
  }
9716
10001
  ]
9717
10002
  },
9718
10003
  {
9719
- type: 'Color',
9720
- label: '背景色',
9721
- name: ['props', 'ctaTempStyles', 'ctaTitle', 'backgroundColor']
10004
+ type: 'TextSpace',
10005
+ name: ['props', 'buttonStyle']
9722
10006
  },
9723
10007
  {
9724
10008
  type: 'Group',
@@ -9726,12 +10010,12 @@ var settingRender$2 = [
9726
10010
  child: [
9727
10011
  {
9728
10012
  type: 'Select',
9729
- name: ['props', 'ctaTempStyles', 'ctaTitle', 'fontFamily-cn'],
10013
+ name: ['props', 'buttonStyle', 'fontFamily-cn'],
9730
10014
  bottomText: '中文字体'
9731
10015
  },
9732
10016
  {
9733
10017
  type: 'Select',
9734
- name: ['props', 'ctaTempStyles', 'ctaTitle', 'fontFamily-en'],
10018
+ name: ['props', 'buttonStyle', 'fontFamily-en'],
9735
10019
  bottomText: '英文/其他字体'
9736
10020
  }
9737
10021
  ]
@@ -9742,78 +10026,29 @@ var settingRender$2 = [
9742
10026
  child: [
9743
10027
  {
9744
10028
  type: 'Color',
9745
- name: ['props', 'ctaTempStyles', 'ctaTitle', 'color']
10029
+ name: ['props', 'buttonStyle', 'color']
9746
10030
  },
9747
10031
  {
9748
10032
  type: 'Number',
9749
10033
  addonAfter: 'px',
9750
- name: ['props', 'ctaTempStyles', 'ctaTitle', 'fontSize']
10034
+ name: ['props', 'buttonStyle', 'fontSize']
9751
10035
  }
9752
10036
  ]
9753
10037
  },
9754
10038
  {
9755
10039
  label: '样式',
9756
10040
  type: 'TextStyle',
9757
- name: ['props', 'ctaTempStyles', 'ctaTitle']
10041
+ name: ['props', 'buttonStyle']
9758
10042
  },
9759
10043
  {
9760
10044
  label: '对齐',
9761
10045
  type: 'TextAlign',
9762
- name: ['props', 'ctaTempStyles', 'ctaTitle']
9763
- },
9764
- {
9765
- label: '间距',
9766
- type: 'TextSpace',
9767
- name: ['props', 'ctaTempStyles', 'ctaTitle']
9768
- }
9769
- ]
9770
- }
9771
- ];
9772
-
9773
- var interactionRender$6 = [
9774
- {
9775
- title: '点击事件',
9776
- child: [
9777
- {
9778
- type: 'link',
9779
- name: 'onClick'
10046
+ name: ['props', 'buttonStyle']
9780
10047
  }
9781
10048
  ]
9782
10049
  }
9783
10050
  ];
9784
10051
 
9785
- const EventProvider = (_a) => {
9786
- var { rec, children, className, onClick, style, isExternalLink = false, index } = _a; __rest(_a, ["rec", "children", "className", "onClick", "style", "isExternalLink", "index"]);
9787
- const ref = useRef(null);
9788
- const { popup } = useEditor();
9789
- const { setPopupDetailData, ctaEvent } = useSxpDataSource();
9790
- const { jumpToWeb } = useEventReport();
9791
- const handleClick = throttle(() => {
9792
- var _a, _b, _c, _d, _e, _f, _g, _h;
9793
- const item = (_b = (_a = rec === null || rec === void 0 ? void 0 : rec.video) === null || _a === void 0 ? void 0 : _a.bindProduct) !== null && _b !== void 0 ? _b : rec === null || rec === void 0 ? void 0 : rec.video;
9794
- ctaEvent === null || ctaEvent === void 0 ? void 0 : ctaEvent({
9795
- eventSubject: 'clickCta',
9796
- eventDescription: 'User clicked the CTA'
9797
- }, rec, item, index);
9798
- setPopupDetailData === null || setPopupDetailData === void 0 ? void 0 : setPopupDetailData(Object.assign(Object.assign({}, rec), { index }));
9799
- if (isExternalLink) {
9800
- if ((_d = (_c = rec === null || rec === void 0 ? void 0 : rec.video) === null || _c === void 0 ? void 0 : _c.bindProduct) === null || _d === void 0 ? void 0 : _d.link) {
9801
- const cta = (_e = rec === null || rec === void 0 ? void 0 : rec.video) === null || _e === void 0 ? void 0 : _e.bindCta;
9802
- const product = (_f = rec === null || rec === void 0 ? void 0 : rec.video) === null || _f === void 0 ? void 0 : _f.bindProduct;
9803
- jumpToWeb(rec, product, cta, index);
9804
- window.location.href = window.getJointUtmLink((_h = (_g = rec === null || rec === void 0 ? void 0 : rec.video) === null || _g === void 0 ? void 0 : _g.bindProduct) === null || _h === void 0 ? void 0 : _h.link);
9805
- }
9806
- }
9807
- else {
9808
- onClick === null || onClick === void 0 ? void 0 : onClick();
9809
- }
9810
- }, popup === null || popup === void 0 ? void 0 : popup.duration);
9811
- return (React.createElement("div", { ref: ref, className: className, style: style, onClick: handleClick }, children));
9812
- };
9813
- var EventProvider$1 = memo(EventProvider);
9814
-
9815
- var styles$6 = {"tow-line-ellipsis":"index-module_tow-line-ellipsis__3bKKx"};
9816
-
9817
10052
  /*
9818
10053
  * @Author: binruan@chatlabs.com
9819
10054
  * @Date: 2023-04-12 09:58:58
@@ -9845,7 +10080,7 @@ function useOnScreen(ref) {
9845
10080
  * @Author: binruan@chatlabs.com
9846
10081
  * @Date: 2024-01-16 14:50:13
9847
10082
  * @LastEditors: binruan@chatlabs.com
9848
- * @LastEditTime: 2024-07-04 18:13:23
10083
+ * @LastEditTime: 2024-06-24 18:13:14
9849
10084
  * @FilePath: \pb-sxp-ui\src\materials\sxp\template\components\Img.tsx
9850
10085
  *
9851
10086
  */
@@ -9866,92 +10101,106 @@ const Img = ({ src, rec, item, index, style, translateY, imgStyle }) => {
9866
10101
  }, [src]);
9867
10102
  return (React.createElement("div", { className: css(Object.assign({ overflow: 'hidden', flexShrink: 0, backgroundColor: '#f2f2f2' }, imgStyle)) },
9868
10103
  React.createElement("div", { ref: ref, hidden: !src, className: css({ width: '100%', height: '100%' }) },
9869
- React.createElement(FormatImage$1, { className: css(Object.assign({ width: '100%', objectFit: 'cover', height: '100%', display: 'block', objectPosition: `50% ${translateY ? translateY + 50 : 50}%` }, style)), src: src }))));
10104
+ React.createElement(FormatImage$1, { className: css(Object.assign({ width: '100%', objectFit: 'cover', height: '100%', display: 'block', objectPosition: `50% ${translateY ? -translateY + 50 : 50}%` }, style)), src: src }))));
9870
10105
  };
9871
10106
  var Img$1 = memo(Img);
9872
10107
 
9873
- const Commodity$1 = (_a) => {
9874
- var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
9875
- 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"]);
10108
+ const EventProvider = (_a) => {
10109
+ var { rec, children, className, onClick, style, isExternalLink = false, index } = _a; __rest(_a, ["rec", "children", "className", "onClick", "style", "isExternalLink", "index"]);
10110
+ const ref = useRef(null);
10111
+ const { popup } = useEditor();
10112
+ const { setPopupDetailData, ctaEvent } = useSxpDataSource();
10113
+ const { jumpToWeb } = useEventReport();
10114
+ const handleClick = throttle(() => {
10115
+ var _a, _b, _c, _d, _e, _f, _g, _h;
10116
+ const item = (_b = (_a = rec === null || rec === void 0 ? void 0 : rec.video) === null || _a === void 0 ? void 0 : _a.bindProduct) !== null && _b !== void 0 ? _b : rec === null || rec === void 0 ? void 0 : rec.video;
10117
+ ctaEvent === null || ctaEvent === void 0 ? void 0 : ctaEvent({
10118
+ eventSubject: 'clickCta',
10119
+ eventDescription: 'User clicked the CTA'
10120
+ }, rec, item, index);
10121
+ setPopupDetailData === null || setPopupDetailData === void 0 ? void 0 : setPopupDetailData(Object.assign(Object.assign({}, rec), { index }));
10122
+ if (isExternalLink) {
10123
+ if ((_d = (_c = rec === null || rec === void 0 ? void 0 : rec.video) === null || _c === void 0 ? void 0 : _c.bindProduct) === null || _d === void 0 ? void 0 : _d.link) {
10124
+ const cta = (_e = rec === null || rec === void 0 ? void 0 : rec.video) === null || _e === void 0 ? void 0 : _e.bindCta;
10125
+ const product = (_f = rec === null || rec === void 0 ? void 0 : rec.video) === null || _f === void 0 ? void 0 : _f.bindProduct;
10126
+ jumpToWeb(rec, product, cta, index);
10127
+ window.location.href = window.getJointUtmLink((_h = (_g = rec === null || rec === void 0 ? void 0 : rec.video) === null || _g === void 0 ? void 0 : _g.bindProduct) === null || _h === void 0 ? void 0 : _h.link);
10128
+ }
10129
+ }
10130
+ else {
10131
+ onClick === null || onClick === void 0 ? void 0 : onClick();
10132
+ }
10133
+ }, popup === null || popup === void 0 ? void 0 : popup.duration);
10134
+ return (React.createElement("div", { ref: ref, className: className, style: style, onClick: handleClick }, children));
10135
+ };
10136
+ var EventProvider$1 = memo(EventProvider);
10137
+
10138
+ const CommodityList$1 = (_a) => {
10139
+ var _b, _c;
10140
+ var { style, isDefault, rec, viewTime, isPost, bottom_image, commodityStyles, buttonStyle, index, translateY = 0, commodityPicture, isExternalLink } = _a, props = __rest(_a, ["style", "isDefault", "rec", "viewTime", "isPost", "bottom_image", "commodityStyles", "buttonStyle", "index", "translateY", "commodityPicture", "isExternalLink"]);
9876
10141
  const { sxpParameter } = useSxpDataSource();
9877
- const product = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindProduct;
9878
- 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;
9879
- return (React.createElement(EventProvider$1, Object.assign({ isExternalLink: isExternalLink, rec: recData, className: css(Object.assign({}, style)), style: { display: 'flex' }, index: index }, props),
9880
- 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 }),
9881
- React.createElement("div", { className: css({
9882
- color: '#fff',
9883
- display: 'flex',
9884
- flexDirection: 'column',
9885
- justifyContent: 'space-between',
9886
- width: '100%',
9887
- overflow: 'hidden'
9888
- }) },
9889
- React.createElement("div", { className: styles$6['tow-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
9890
- __html: setFontForText((_j = product === null || product === void 0 ? void 0 : product.title) !== null && _j !== void 0 ? _j : 'Product Name', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title)
9891
- } }),
9892
- React.createElement("div", { className: css(Object.assign({ padding: '0 7px', textOverflow: 'ellipsis', overflow: 'hidden', whiteSpace: 'nowrap', lineHeight: ((_k = ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle) === null || _k === void 0 ? void 0 : _k.height) + 'px' }, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)), dangerouslySetInnerHTML: {
9893
- __html: setFontForText((_m = (_l = product === null || product === void 0 ? void 0 : product.bindCta) === null || _l === void 0 ? void 0 : _l.enTitle) !== null && _m !== void 0 ? _m : 'Shop Now', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
9894
- } }))));
10142
+ const { popupDetailData, bffEventReport, isPreview, swiperRef, bffFbReport } = useSxpDataSource();
10143
+ const recData = isPost ? rec : popupDetailData;
10144
+ const product = (_c = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindProducts) !== null && _c !== void 0 ? _c : [null, null, null, null];
10145
+ const priceText = useCallback((product) => {
10146
+ var _a, _b, _c, _d, _e;
10147
+ if ((product === null || product === void 0 ? void 0 : product.currency) && (product === null || product === void 0 ? void 0 : product.price)) {
10148
+ return `${(_c = (_b = (_a = product === null || product === void 0 ? void 0 : product.currency) === null || _a === void 0 ? void 0 : _a.split('-')[1]) === null || _b === void 0 ? void 0 : _b.toUpperCase()) !== null && _c !== void 0 ? _c : ''}${(_e = (_d = product === null || product === void 0 ? void 0 : product.price) === null || _d === void 0 ? void 0 : _d.toLocaleString('zh', {
10149
+ minimumFractionDigits: 0
10150
+ })) !== null && _e !== void 0 ? _e : ''}`;
10151
+ }
10152
+ else {
10153
+ return '$7,000';
10154
+ }
10155
+ }, []);
10156
+ return (React.createElement("div", { className: css(Object.assign(Object.assign({}, style), { display: 'flex', flexDirection: 'column', gap: '10px', padding: '0 20px', marginTop: '50px' })) }, product === null || product === void 0 ? void 0 : product.map((item, index) => {
10157
+ var _a, _b, _c, _d, _e, _f, _g, _h;
10158
+ return (React.createElement(EventProvider$1, Object.assign({ key: index, isExternalLink: isExternalLink, rec: recData, index: index }, props, { className: css({
10159
+ display: 'flex'
10160
+ }) }),
10161
+ React.createElement(Img$1, { 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: commodityPicture }),
10162
+ React.createElement("div", { style: { flex: 1, display: 'flex', flexDirection: 'column', justifyContent: 'space-between' } },
10163
+ React.createElement("div", null,
10164
+ React.createElement("div", { style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.title, hidden: !!item && !(item === null || item === void 0 ? void 0 : item.title), dangerouslySetInnerHTML: {
10165
+ __html: setFontForText((_e = item === null || item === void 0 ? void 0 : item.title) !== null && _e !== void 0 ? _e : 'Pendant in Yellow Gold with Diamonds, Medium', commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.title)
10166
+ } }),
10167
+ React.createElement("div", { style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.collection, hidden: !!item && (!(item === null || item === void 0 ? void 0 : item.collection) || (item === null || item === void 0 ? void 0 : item.collection) === ''), dangerouslySetInnerHTML: {
10168
+ __html: setFontForText((_f = item === null || item === void 0 ? void 0 : item.collection) !== null && _f !== void 0 ? _f : 'Tiffany Lock', commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.collection)
10169
+ } })),
10170
+ React.createElement("div", { className: css({
10171
+ display: 'flex',
10172
+ alignItems: 'flex-end',
10173
+ justifyContent: 'space-between',
10174
+ width: '100%',
10175
+ overflow: 'hidden'
10176
+ }) },
10177
+ React.createElement("div", { style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.price, hidden: !!item && !(item === null || item === void 0 ? void 0 : item.price), dangerouslySetInnerHTML: {
10178
+ __html: setFontForText(priceText(item), commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.price)
10179
+ } }),
10180
+ React.createElement("div", { className: 'one-line-ellipsis', style: Object.assign(Object.assign({}, buttonStyle), { padding: '0 15px', maxWidth: '100px' }), dangerouslySetInnerHTML: {
10181
+ __html: setFontForText((_h = (_g = item === null || item === void 0 ? void 0 : item.bindCta) === null || _g === void 0 ? void 0 : _g.enTitle) !== null && _h !== void 0 ? _h : 'Shop Now', buttonStyle)
10182
+ } })))));
10183
+ })));
9895
10184
  };
9896
- var CommodityComponent = memo(Commodity$1);
10185
+ var CommodityListComponent = memo(CommodityList$1);
9897
10186
 
9898
10187
  /*
9899
10188
  * @Author: binruan@chatlabs.com
9900
- * @Date: 2023-07-28 18:29:57
10189
+ * @Date: 2024-07-09 14:35:10
9901
10190
  * @LastEditors: binruan@chatlabs.com
9902
- * @LastEditTime: 2024-03-29 16:39:54
9903
- * @FilePath: \pb-sxp-ui\src\materials\sxp\template\Commodity\material.tsx
10191
+ * @LastEditTime: 2024-07-09 14:35:18
10192
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\popup\CommodityList\interactionRender.tsx
9904
10193
  *
9905
10194
  */
9906
- const Commodity = createMaterial(CommodityComponent, {
9907
- displayName: '推荐单商品-透明底',
9908
- icon: '',
9909
- category: 'template',
9910
- type: 'Commodity',
9911
- related: {
9912
- interactionRender: interactionRender$6,
9913
- bindableProps: [],
9914
- settingRender: settingRender$2
9915
- },
9916
- defaulSetting: {
9917
- props: {
9918
- ctaTempStyles: {
9919
- img: {
9920
- borderRadius: 3,
9921
- width: 60,
9922
- height: 60,
9923
- marginRight: 8
9924
- },
9925
- title: {
9926
- fontSize: 12,
9927
- color: '#fff',
9928
- textAlign: 'left'
9929
- },
9930
- ctaTitle: {
9931
- fontSize: 10,
9932
- color: '#fff',
9933
- textAlign: 'center',
9934
- width: 130,
9935
- height: 20,
9936
- backgroundColor: 'rgba(0,0,0,.5)'
9937
- }
9938
- }
9939
- },
9940
- style: {
9941
- padding: 7,
9942
- width: 236,
9943
- height: 74,
9944
- borderRadius: 3,
9945
- backgroundColor: 'rgba(0,0,0,.3)',
9946
- marginBottom: 8
9947
- }
9948
- },
9949
- w: 100,
9950
- h: 40,
9951
- sort: 1
9952
- });
9953
-
9954
- var interactionRender$5 = [
10195
+ /*
10196
+ * @Author: binruan@chatlabs.com
10197
+ * @Date: 2024-07-05 14:08:41
10198
+ * @LastEditors: binruan@chatlabs.com
10199
+ * @LastEditTime: 2024-07-09 14:34:49
10200
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\cta\AniLink\interactionRender.tsx
10201
+ *
10202
+ */
10203
+ var interactionRender$9 = [
9955
10204
  {
9956
10205
  title: '点击事件',
9957
10206
  child: [
@@ -9963,104 +10212,140 @@ var interactionRender$5 = [
9963
10212
  }
9964
10213
  ];
9965
10214
 
9966
- const Appoint$1 = (_a) => {
9967
- var _b, _c, _d, _e, _f, _g;
9968
- var { content, style, bgImg, recData, bottom_image, ctaTempStyles, isExternalLink, index } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "bottom_image", "ctaTempStyles", "isExternalLink", "index"]);
9969
- const { sxpParameter } = useSxpDataSource();
9970
- const cta = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindCta;
9971
- 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;
9972
- return (React.createElement(EventProvider$1, Object.assign({ isExternalLink: isExternalLink, rec: recData, className: css(Object.assign({ alignItems: 'center' }, style)), style: { display: 'flex' }, index: index }, props),
9973
- 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 }),
9974
- React.createElement("div", { className: css(Object.assign({ overflow: 'hidden', textOverflow: 'ellipsis' }, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)), dangerouslySetInnerHTML: {
9975
- __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)
9976
- } })));
9977
- };
9978
- var AppointComponent = memo(Appoint$1);
9979
-
9980
10215
  /*
9981
10216
  * @Author: binruan@chatlabs.com
9982
- * @Date: 2023-07-28 18:29:57
10217
+ * @Date: 2024-03-20 10:27:31
9983
10218
  * @LastEditors: binruan@chatlabs.com
9984
- * @LastEditTime: 2024-04-09 21:42:21
9985
- * @FilePath: \pb-sxp-ui\src\materials\sxp\template\Appoint\material.tsx
10219
+ * @LastEditTime: 2024-07-09 16:04:28
10220
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\popup\CommodityList\material.tsx
9986
10221
  *
9987
10222
  */
9988
- const Appoint = createMaterial(AppointComponent, {
9989
- displayName: '预约表单',
10223
+ const CommodityList = createMaterial(CommodityListComponent, {
10224
+ displayName: '商品列表',
9990
10225
  icon: '',
9991
- category: 'template',
9992
- type: 'Appoint',
10226
+ category: 'popup',
10227
+ type: 'CommodityList',
9993
10228
  related: {
9994
- interactionRender: interactionRender$5,
9995
- settingRender: settingRender$2 === null || settingRender$2 === void 0 ? void 0 : settingRender$2.filter((i) => i.type !== 'commodityTitle'),
9996
- bindableProps: []
10229
+ settingRender: settingRender$5,
10230
+ interactionRender: interactionRender$9
9997
10231
  },
9998
10232
  defaulSetting: {
9999
10233
  props: {
10000
- ctaTempStyles: {
10001
- img: {
10002
- borderRadius: 3,
10003
- width: 30,
10004
- height: 30,
10005
- marginRight: 8
10234
+ commodityPicture: {
10235
+ width: 100,
10236
+ height: 100,
10237
+ marginRight: 10
10238
+ },
10239
+ commodityStyles: {
10240
+ price: {
10241
+ color: '#000',
10242
+ fontWeight: 'bold',
10243
+ fontSize: 14
10006
10244
  },
10007
- ctaTitle: {
10008
- fontSize: 12,
10009
- color: '#fff',
10010
- textAlign: 'left',
10011
- width: 130,
10012
- height: 20
10245
+ title: {
10246
+ color: '#000',
10247
+ fontSize: 14
10248
+ },
10249
+ collection: {
10250
+ color: '#757575',
10251
+ fontSize: 12
10013
10252
  }
10253
+ },
10254
+ buttonStyle: {
10255
+ backgroundColor: '#000',
10256
+ fontSize: 12,
10257
+ height: 30,
10258
+ textAlign: 'center',
10259
+ color: '#fff',
10260
+ lineHeight: 2.5
10014
10261
  }
10015
10262
  },
10016
- style: {
10017
- padding: 7,
10018
- width: 236,
10019
- height: 44,
10020
- borderRadius: 3,
10021
- backgroundColor: 'rgba(0,0,0,.3)',
10022
- marginBottom: 8
10023
- }
10263
+ style: {}
10024
10264
  },
10025
10265
  w: 100,
10026
10266
  h: 40,
10027
- sort: 6
10267
+ sort: 1
10028
10268
  });
10029
10269
 
10030
10270
  /*
10031
10271
  * @Author: binruan@chatlabs.com
10032
- * @Date: 2024-07-02 14:51:32
10272
+ * @Date: 2024-03-26 16:50:25
10033
10273
  * @LastEditors: binruan@chatlabs.com
10034
- * @LastEditTime: 2024-07-02 16:44:34
10035
- * @FilePath: \pb-sxp-ui\src\materials\sxp\template\Link\settingRender.tsx
10274
+ * @LastEditTime: 2024-06-27 09:55:59
10275
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\template\components\settingRender.tsx
10036
10276
  *
10037
10277
  */
10038
- var linkSettingRender = [
10278
+ var settingRender$4 = [
10039
10279
  {
10040
- title: '自定义标题',
10280
+ title: '主题样式',
10041
10281
  child: [
10042
10282
  {
10043
- type: 'Switch',
10044
- label: '自定义标题开关',
10045
- name: ['props', 'customTitle', 'display']
10283
+ type: 'Group',
10284
+ label: '尺寸',
10285
+ child: [
10286
+ {
10287
+ type: 'Number',
10288
+ name: ['style', 'width'],
10289
+ addonAfter: 'W'
10290
+ },
10291
+ {
10292
+ type: 'Number',
10293
+ name: ['style', 'height'],
10294
+ addonAfter: 'H'
10295
+ }
10296
+ ]
10046
10297
  },
10047
10298
  {
10048
- type: 'Text',
10049
- label: '标题文案',
10050
- name: ['props', 'customTitle', 'text']
10299
+ type: 'Group',
10300
+ label: '圆角',
10301
+ child: [
10302
+ {
10303
+ type: 'Slider',
10304
+ name: ['style', 'borderRadius'],
10305
+ max: 100
10306
+ },
10307
+ {
10308
+ type: 'Number',
10309
+ name: ['style', 'borderRadius'],
10310
+ addonAfter: 'px',
10311
+ max: 100
10312
+ }
10313
+ ]
10314
+ },
10315
+ {
10316
+ type: 'Color',
10317
+ label: '背景色',
10318
+ name: ['style', 'backgroundColor']
10051
10319
  },
10320
+ {
10321
+ label: '内边距',
10322
+ type: 'Number',
10323
+ name: ['style', 'padding'],
10324
+ addonAfter: 'px'
10325
+ },
10326
+ {
10327
+ label: '与Post描述边距',
10328
+ type: 'Number',
10329
+ name: ['style', 'marginBottom'],
10330
+ addonAfter: 'px'
10331
+ }
10332
+ ]
10333
+ },
10334
+ {
10335
+ title: '商品图片',
10336
+ child: [
10052
10337
  {
10053
10338
  type: 'Group',
10054
10339
  label: '尺寸',
10055
10340
  child: [
10056
10341
  {
10057
10342
  type: 'Number',
10058
- name: ['props', 'customTitle', 'style', 'width'],
10343
+ name: ['props', 'ctaTempStyles', 'img', 'width'],
10059
10344
  addonAfter: 'W'
10060
10345
  },
10061
10346
  {
10062
10347
  type: 'Number',
10063
- name: ['props', 'customTitle', 'style', 'height'],
10348
+ name: ['props', 'ctaTempStyles', 'img', 'height'],
10064
10349
  addonAfter: 'H'
10065
10350
  }
10066
10351
  ]
@@ -10071,34 +10356,49 @@ var linkSettingRender = [
10071
10356
  child: [
10072
10357
  {
10073
10358
  type: 'Slider',
10074
- name: ['props', 'customTitle', 'style', 'borderRadius'],
10359
+ name: ['props', 'ctaTempStyles', 'img', 'borderRadius'],
10075
10360
  max: 100
10076
10361
  },
10077
10362
  {
10078
10363
  type: 'Number',
10079
- name: ['props', 'customTitle', 'style', 'borderRadius'],
10364
+ name: ['props', 'ctaTempStyles', 'img', 'borderRadius'],
10080
10365
  addonAfter: 'px',
10081
10366
  max: 100
10082
10367
  }
10083
10368
  ]
10084
10369
  },
10085
10370
  {
10086
- type: 'Color',
10087
- label: '背景色',
10088
- name: ['props', 'customTitle', 'style', 'backgroundColor']
10371
+ type: 'Number',
10372
+ label: '与右侧边距',
10373
+ addonAfter: 'px',
10374
+ name: ['props', 'ctaTempStyles', 'img', 'marginRight']
10089
10375
  },
10376
+ {
10377
+ label: '居中垂直偏移',
10378
+ type: 'Number',
10379
+ name: ['props', 'translateY'],
10380
+ min: -1000,
10381
+ addonAfter: '%',
10382
+ initialValue: 0
10383
+ }
10384
+ ]
10385
+ },
10386
+ {
10387
+ title: '商品标题文本',
10388
+ type: 'commodityTitle',
10389
+ child: [
10090
10390
  {
10091
10391
  type: 'Group',
10092
10392
  label: '字体',
10093
10393
  child: [
10094
10394
  {
10095
10395
  type: 'Select',
10096
- name: ['props', 'customTitle', 'style', 'fontFamily-cn'],
10396
+ name: ['props', 'ctaTempStyles', 'title', 'fontFamily-cn'],
10097
10397
  bottomText: '中文字体'
10098
10398
  },
10099
10399
  {
10100
10400
  type: 'Select',
10101
- name: ['props', 'customTitle', 'style', 'fontFamily-en'],
10401
+ name: ['props', 'ctaTempStyles', 'title', 'fontFamily-en'],
10102
10402
  bottomText: '英文/其他字体'
10103
10403
  }
10104
10404
  ]
@@ -10109,124 +10409,119 @@ var linkSettingRender = [
10109
10409
  child: [
10110
10410
  {
10111
10411
  type: 'Color',
10112
- name: ['props', 'customTitle', 'style', 'color']
10412
+ name: ['props', 'ctaTempStyles', 'title', 'color']
10113
10413
  },
10114
10414
  {
10115
10415
  type: 'Number',
10116
10416
  addonAfter: 'px',
10117
- name: ['props', 'customTitle', 'style', 'fontSize']
10417
+ name: ['props', 'ctaTempStyles', 'title', 'fontSize']
10118
10418
  }
10119
10419
  ]
10120
10420
  },
10121
10421
  {
10122
10422
  label: '样式',
10123
10423
  type: 'TextStyle',
10124
- name: ['props', 'customTitle', 'style']
10424
+ name: ['props', 'ctaTempStyles', 'title']
10125
10425
  },
10126
10426
  {
10127
10427
  label: '对齐',
10128
10428
  type: 'TextAlign',
10129
- name: ['props', 'customTitle', 'style']
10429
+ name: ['props', 'ctaTempStyles', 'title']
10130
10430
  },
10131
10431
  {
10132
- label: '上边距',
10133
- type: 'Number',
10134
- name: ['props', 'customTitle', 'style', 'marginTop'],
10135
- addonAfter: 'px'
10432
+ label: '间距',
10433
+ type: 'TextSpace',
10434
+ name: ['props', 'ctaTempStyles', 'title']
10136
10435
  }
10137
10436
  ]
10138
- }
10139
- ];
10140
-
10141
- var styles$5 = {"tow-line-ellipsis":"index-module_tow-line-ellipsis__nkBlU","one-line-ellipsis":"index-module_one-line-ellipsis__buFw1"};
10142
-
10143
- const Link$1 = (_a) => {
10144
- var _b, _c, _d, _e, _f, _g, _h, _j;
10145
- var { content, style, bgImg, recData, bottom_image, ctaTempStyles, index, customTitle } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "bottom_image", "ctaTempStyles", "index", "customTitle"]);
10146
- const { sxpParameter, bffEventReport } = useSxpDataSource();
10147
- const { jumpToWeb } = useEventReport();
10148
- const cta = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindCta;
10149
- const product = (_c = recData === null || recData === void 0 ? void 0 : recData.video) === null || _c === void 0 ? void 0 : _c.bindProduct;
10150
- const handleTo = () => {
10151
- if (cta === null || cta === void 0 ? void 0 : cta.link) {
10152
- jumpToWeb(recData, product, cta, index);
10153
- window.location.href = window.getJointUtmLink(cta.link);
10154
- }
10155
- };
10156
- 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;
10157
- return (React.createElement(EventProvider$1, Object.assign({ index: index, rec: recData, className: css(Object.assign({ alignItems: 'center' }, style)), style: { display: 'flex' } }, props, { onClick: handleTo }),
10158
- React.createElement(Img$1, { src: src, rec: recData, item: (_g = (_f = recData === null || recData === void 0 ? void 0 : recData.video) === null || _f === void 0 ? void 0 : _f.bindProduct) !== null && _g !== void 0 ? _g : recData === null || recData === void 0 ? void 0 : recData.video, index: index, imgStyle: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img }),
10159
- React.createElement("div", { className: css({
10160
- display: 'flex',
10161
- alignItems: 'center',
10162
- width: '100%',
10163
- overflow: 'hidden'
10164
- }) },
10165
- React.createElement("div", null,
10166
- React.createElement("div", { className: styles$5['tow-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle, dangerouslySetInnerHTML: {
10167
- __html: setFontForText((_h = cta === null || cta === void 0 ? void 0 : cta.enTitle) !== null && _h !== void 0 ? _h : 'Product Name', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
10168
- } }),
10169
- (customTitle === null || customTitle === void 0 ? void 0 : customTitle.display) && (React.createElement("div", { style: Object.assign(Object.assign({}, customTitle === null || customTitle === void 0 ? void 0 : customTitle.style), { lineHeight: ((_j = customTitle === null || customTitle === void 0 ? void 0 : customTitle.style) === null || _j === void 0 ? void 0 : _j.height) + 'px' }), className: styles$5['one-line-ellipsis'], dangerouslySetInnerHTML: {
10170
- __html: setFontForText(customTitle === null || customTitle === void 0 ? void 0 : customTitle.text, customTitle === null || customTitle === void 0 ? void 0 : customTitle.style)
10171
- } }))))));
10172
- };
10173
- var LinkComponent = memo(Link$1);
10174
-
10175
- var _a;
10176
- const Link = createMaterial(LinkComponent, {
10177
- displayName: '跳转指引',
10178
- icon: '',
10179
- category: 'template',
10180
- type: 'Link',
10181
- related: {
10182
- settingRender: (_a = settingRender$2 === null || settingRender$2 === void 0 ? void 0 : settingRender$2.filter((i) => i.type !== 'commodityTitle')) === null || _a === void 0 ? void 0 : _a.concat(linkSettingRender),
10183
- bindableProps: []
10184
10437
  },
10185
- defaulSetting: {
10186
- props: {
10187
- ctaTempStyles: {
10188
- img: {
10189
- borderRadius: 3,
10190
- width: 60,
10191
- height: 60,
10192
- marginRight: 8
10193
- },
10194
- ctaTitle: {
10195
- fontSize: 12,
10196
- color: '#fff',
10197
- textAlign: 'left',
10198
- width: 130,
10199
- height: 20
10200
- }
10438
+ {
10439
+ title: 'CTA标题',
10440
+ child: [
10441
+ {
10442
+ type: 'Group',
10443
+ label: '尺寸',
10444
+ child: [
10445
+ {
10446
+ type: 'Number',
10447
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'width'],
10448
+ addonAfter: 'W'
10449
+ },
10450
+ {
10451
+ type: 'Number',
10452
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'height'],
10453
+ addonAfter: 'H'
10454
+ }
10455
+ ]
10201
10456
  },
10202
- customTitle: {
10203
- style: {
10204
- textAlign: 'left',
10205
- textDecoration: 'underline',
10206
- fontWeight: 'bold',
10207
- width: 130,
10208
- height: 20,
10209
- fontSize: 12,
10210
- color: '#000'
10211
- },
10212
- text: '探索更多'
10457
+ {
10458
+ type: 'Group',
10459
+ label: '圆角',
10460
+ child: [
10461
+ {
10462
+ type: 'Slider',
10463
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'borderRadius'],
10464
+ max: 100
10465
+ },
10466
+ {
10467
+ type: 'Number',
10468
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'borderRadius'],
10469
+ addonAfter: 'px',
10470
+ max: 100
10471
+ }
10472
+ ]
10473
+ },
10474
+ {
10475
+ type: 'Color',
10476
+ label: '背景色',
10477
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'backgroundColor']
10478
+ },
10479
+ {
10480
+ type: 'Group',
10481
+ label: '字体',
10482
+ child: [
10483
+ {
10484
+ type: 'Select',
10485
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'fontFamily-cn'],
10486
+ bottomText: '中文字体'
10487
+ },
10488
+ {
10489
+ type: 'Select',
10490
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'fontFamily-en'],
10491
+ bottomText: '英文/其他字体'
10492
+ }
10493
+ ]
10494
+ },
10495
+ {
10496
+ type: 'Group',
10497
+ label: '',
10498
+ child: [
10499
+ {
10500
+ type: 'Color',
10501
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'color']
10502
+ },
10503
+ {
10504
+ type: 'Number',
10505
+ addonAfter: 'px',
10506
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'fontSize']
10507
+ }
10508
+ ]
10509
+ },
10510
+ {
10511
+ label: '样式',
10512
+ type: 'TextStyle',
10513
+ name: ['props', 'ctaTempStyles', 'ctaTitle']
10514
+ },
10515
+ {
10516
+ label: '对齐',
10517
+ type: 'TextAlign',
10518
+ name: ['props', 'ctaTempStyles', 'ctaTitle']
10213
10519
  }
10214
- },
10215
- style: {
10216
- padding: 7,
10217
- width: 236,
10218
- height: 74,
10219
- borderRadius: 3,
10220
- backgroundColor: 'rgba(0,0,0,.3)',
10221
- marginBottom: 8
10222
- }
10223
- },
10224
- w: 100,
10225
- h: 40,
10226
- sort: 5
10227
- });
10520
+ ]
10521
+ }
10522
+ ];
10228
10523
 
10229
- var interactionRender$4 = [
10524
+ var interactionRender$8 = [
10230
10525
  {
10231
10526
  title: '点击事件',
10232
10527
  child: [
@@ -10238,9 +10533,9 @@ var interactionRender$4 = [
10238
10533
  }
10239
10534
  ];
10240
10535
 
10241
- var styles$4 = {"tow-line-ellipsis":"index-module_tow-line-ellipsis__yyHVb"};
10536
+ var styles$8 = {"tow-line-ellipsis":"index-module_tow-line-ellipsis__3bKKx"};
10242
10537
 
10243
- const CommodityDiro$1 = (_a) => {
10538
+ const Commodity$1 = (_a) => {
10244
10539
  var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
10245
10540
  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"]);
10246
10541
  const { sxpParameter } = useSxpDataSource();
@@ -10256,32 +10551,32 @@ const CommodityDiro$1 = (_a) => {
10256
10551
  width: '100%',
10257
10552
  overflow: 'hidden'
10258
10553
  }) },
10259
- React.createElement("div", { className: styles$4['tow-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
10554
+ React.createElement("div", { className: styles$8['tow-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
10260
10555
  __html: setFontForText((_j = product === null || product === void 0 ? void 0 : product.title) !== null && _j !== void 0 ? _j : 'Product Name', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title)
10261
10556
  } }),
10262
- React.createElement("div", { className: css(Object.assign({ padding: '0 7px', textOverflow: 'ellipsis', overflow: 'hidden', borderRadius: '25px', whiteSpace: 'nowrap', lineHeight: ((_k = ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle) === null || _k === void 0 ? void 0 : _k.height) + 'px' }, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)), dangerouslySetInnerHTML: {
10557
+ React.createElement("div", { className: css(Object.assign({ padding: '0 7px', textOverflow: 'ellipsis', overflow: 'hidden', whiteSpace: 'nowrap', lineHeight: ((_k = ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle) === null || _k === void 0 ? void 0 : _k.height) + 'px' }, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)), dangerouslySetInnerHTML: {
10263
10558
  __html: setFontForText((_m = (_l = product === null || product === void 0 ? void 0 : product.bindCta) === null || _l === void 0 ? void 0 : _l.enTitle) !== null && _m !== void 0 ? _m : 'Shop Now', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
10264
10559
  } }))));
10265
10560
  };
10266
- var CommodityDiroComponent = memo(CommodityDiro$1);
10561
+ var CommodityComponent = memo(Commodity$1);
10267
10562
 
10268
10563
  /*
10269
10564
  * @Author: binruan@chatlabs.com
10270
10565
  * @Date: 2023-07-28 18:29:57
10271
10566
  * @LastEditors: binruan@chatlabs.com
10272
- * @LastEditTime: 2024-03-29 16:07:28
10273
- * @FilePath: \pb-sxp-ui\src\materials\sxp\template\CommodityDiro\material.tsx
10567
+ * @LastEditTime: 2024-03-29 16:39:54
10568
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\template\Commodity\material.tsx
10274
10569
  *
10275
10570
  */
10276
- const CommodityDiro = createMaterial(CommodityDiroComponent, {
10277
- displayName: '推荐单商品-白底圆角按钮',
10571
+ const Commodity = createMaterial(CommodityComponent, {
10572
+ displayName: '推荐单商品-透明底',
10278
10573
  icon: '',
10279
10574
  category: 'template',
10280
- type: 'CommodityDiro',
10575
+ type: 'Commodity',
10281
10576
  related: {
10282
- interactionRender: interactionRender$4,
10283
- settingRender: settingRender$2,
10284
- bindableProps: []
10577
+ interactionRender: interactionRender$8,
10578
+ bindableProps: [],
10579
+ settingRender: settingRender$4
10285
10580
  },
10286
10581
  defaulSetting: {
10287
10582
  props: {
@@ -10294,16 +10589,16 @@ const CommodityDiro = createMaterial(CommodityDiroComponent, {
10294
10589
  },
10295
10590
  title: {
10296
10591
  fontSize: 12,
10297
- color: '#000',
10592
+ color: '#fff',
10298
10593
  textAlign: 'left'
10299
10594
  },
10300
10595
  ctaTitle: {
10301
10596
  fontSize: 10,
10302
10597
  color: '#fff',
10303
10598
  textAlign: 'center',
10304
- width: 80,
10599
+ width: 130,
10305
10600
  height: 20,
10306
- backgroundColor: 'rgba(0,0,0,1)'
10601
+ backgroundColor: 'rgba(0,0,0,.5)'
10307
10602
  }
10308
10603
  }
10309
10604
  },
@@ -10312,16 +10607,16 @@ const CommodityDiro = createMaterial(CommodityDiroComponent, {
10312
10607
  width: 236,
10313
10608
  height: 74,
10314
10609
  borderRadius: 3,
10315
- backgroundColor: '#fff',
10610
+ backgroundColor: 'rgba(0,0,0,.3)',
10316
10611
  marginBottom: 8
10317
10612
  }
10318
10613
  },
10319
10614
  w: 100,
10320
10615
  h: 40,
10321
- sort: 2
10616
+ sort: 1
10322
10617
  });
10323
10618
 
10324
- var interactionRender$3 = [
10619
+ var interactionRender$7 = [
10325
10620
  {
10326
10621
  title: '点击事件',
10327
10622
  child: [
@@ -10333,171 +10628,224 @@ var interactionRender$3 = [
10333
10628
  }
10334
10629
  ];
10335
10630
 
10336
- var styles$3 = {"tow-line-ellipsis":"index-module_tow-line-ellipsis__I-yCC"};
10337
-
10338
- const CommodityDiroNew$1 = (_a) => {
10339
- var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
10340
- 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"]);
10631
+ const Appoint$1 = (_a) => {
10632
+ var _b, _c, _d, _e, _f, _g;
10633
+ var { content, style, bgImg, recData, bottom_image, ctaTempStyles, isExternalLink, index } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "bottom_image", "ctaTempStyles", "isExternalLink", "index"]);
10341
10634
  const { sxpParameter } = useSxpDataSource();
10342
- const product = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindProduct;
10343
- 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;
10344
- return (React.createElement(EventProvider$1, Object.assign({ isExternalLink: isExternalLink, rec: recData, className: css(Object.assign({}, style)), style: { display: 'flex' }, index: index }, props),
10345
- 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 }),
10346
- React.createElement("div", { className: css({
10347
- color: '#fff',
10348
- display: 'flex',
10349
- flexDirection: 'column',
10350
- justifyContent: 'center',
10351
- width: '100%',
10352
- overflow: 'hidden'
10353
- }) },
10354
- React.createElement("div", { className: styles$3['tow-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
10355
- __html: setFontForText((_j = product === null || product === void 0 ? void 0 : product.title) !== null && _j !== void 0 ? _j : 'Product Name', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title)
10356
- } }),
10357
- React.createElement("div", { className: css(Object.assign({ textOverflow: 'ellipsis', overflow: 'hidden', whiteSpace: 'nowrap' }, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)), dangerouslySetInnerHTML: {
10358
- __html: setFontForText((_l = (_k = product === null || product === void 0 ? void 0 : product.bindCta) === null || _k === void 0 ? void 0 : _k.enTitle) !== null && _l !== void 0 ? _l : 'Shop Now', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
10359
- } }))));
10635
+ const cta = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindCta;
10636
+ 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;
10637
+ return (React.createElement(EventProvider$1, Object.assign({ isExternalLink: isExternalLink, rec: recData, className: css(Object.assign({ alignItems: 'center' }, style)), style: { display: 'flex' }, index: index }, props),
10638
+ 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 }),
10639
+ React.createElement("div", { className: css(Object.assign({ overflow: 'hidden', textOverflow: 'ellipsis' }, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)), dangerouslySetInnerHTML: {
10640
+ __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)
10641
+ } })));
10360
10642
  };
10361
- var CommodityDiroNewComponent = memo(CommodityDiroNew$1);
10643
+ var AppointComponent = memo(Appoint$1);
10362
10644
 
10363
10645
  /*
10364
10646
  * @Author: binruan@chatlabs.com
10365
10647
  * @Date: 2023-07-28 18:29:57
10366
10648
  * @LastEditors: binruan@chatlabs.com
10367
- * @LastEditTime: 2024-04-09 11:54:27
10368
- * @FilePath: \pb-sxp-ui\src\materials\sxp\template\CommodityDiroNew\material.tsx
10649
+ * @LastEditTime: 2024-04-09 21:42:21
10650
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\template\Appoint\material.tsx
10369
10651
  *
10370
10652
  */
10371
- const CommodityDiroNew = createMaterial(CommodityDiroNewComponent, {
10372
- displayName: '推荐单商品-白底下划线按钮',
10653
+ const Appoint = createMaterial(AppointComponent, {
10654
+ displayName: '预约表单',
10373
10655
  icon: '',
10374
10656
  category: 'template',
10375
- type: 'CommodityDiroNew',
10657
+ type: 'Appoint',
10376
10658
  related: {
10377
- interactionRender: interactionRender$3,
10378
- bindableProps: [],
10379
- settingRender: settingRender$2
10659
+ interactionRender: interactionRender$7,
10660
+ settingRender: settingRender$4 === null || settingRender$4 === void 0 ? void 0 : settingRender$4.filter((i) => i.type !== 'commodityTitle'),
10661
+ bindableProps: []
10380
10662
  },
10381
10663
  defaulSetting: {
10382
10664
  props: {
10383
10665
  ctaTempStyles: {
10384
10666
  img: {
10385
- borderRadius: 8,
10386
- width: 78,
10387
- height: 78,
10388
- marginRight: 16
10389
- },
10390
- title: {
10391
- fontSize: 13,
10392
- color: '#000',
10393
- textAlign: 'left'
10667
+ borderRadius: 3,
10668
+ width: 30,
10669
+ height: 30,
10670
+ marginRight: 8
10394
10671
  },
10395
10672
  ctaTitle: {
10396
- textDecoration: 'underline',
10397
- fontSize: 14,
10398
- fontWeight: 'bold',
10399
- color: '#000',
10673
+ fontSize: 12,
10674
+ color: '#fff',
10400
10675
  textAlign: 'left',
10401
- width: 150,
10676
+ width: 130,
10402
10677
  height: 20
10403
10678
  }
10404
10679
  }
10405
10680
  },
10406
10681
  style: {
10407
- borderRadius: 4,
10408
- width: 260,
10409
- height: 86,
10410
- padding: 4,
10411
- backgroundColor: 'rgba(255,255,255,0.75)',
10682
+ padding: 7,
10683
+ width: 236,
10684
+ height: 44,
10685
+ borderRadius: 3,
10686
+ backgroundColor: 'rgba(0,0,0,.3)',
10412
10687
  marginBottom: 8
10413
10688
  }
10414
10689
  },
10415
10690
  w: 100,
10416
10691
  h: 40,
10417
- sort: 2
10692
+ sort: 6
10418
10693
  });
10419
10694
 
10420
- var interactionRender$2 = [
10695
+ /*
10696
+ * @Author: binruan@chatlabs.com
10697
+ * @Date: 2024-07-02 14:51:32
10698
+ * @LastEditors: binruan@chatlabs.com
10699
+ * @LastEditTime: 2024-07-02 16:44:34
10700
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\template\Link\settingRender.tsx
10701
+ *
10702
+ */
10703
+ var linkSettingRender = [
10421
10704
  {
10422
- title: '点击事件',
10705
+ title: '自定义标题',
10423
10706
  child: [
10424
10707
  {
10425
- type: 'link',
10426
- name: 'onClick'
10427
- }
10428
- ]
10708
+ type: 'Switch',
10709
+ label: '自定义标题开关',
10710
+ name: ['props', 'customTitle', 'display']
10711
+ },
10712
+ {
10713
+ type: 'Text',
10714
+ label: '标题文案',
10715
+ name: ['props', 'customTitle', 'text']
10716
+ },
10717
+ {
10718
+ type: 'Group',
10719
+ label: '尺寸',
10720
+ child: [
10721
+ {
10722
+ type: 'Number',
10723
+ name: ['props', 'customTitle', 'style', 'width'],
10724
+ addonAfter: 'W'
10725
+ },
10726
+ {
10727
+ type: 'Number',
10728
+ name: ['props', 'customTitle', 'style', 'height'],
10729
+ addonAfter: 'H'
10730
+ }
10731
+ ]
10732
+ },
10733
+ {
10734
+ type: 'Group',
10735
+ label: '圆角',
10736
+ child: [
10737
+ {
10738
+ type: 'Slider',
10739
+ name: ['props', 'customTitle', 'style', 'borderRadius'],
10740
+ max: 100
10741
+ },
10742
+ {
10743
+ type: 'Number',
10744
+ name: ['props', 'customTitle', 'style', 'borderRadius'],
10745
+ addonAfter: 'px',
10746
+ max: 100
10747
+ }
10748
+ ]
10749
+ },
10750
+ {
10751
+ type: 'Color',
10752
+ label: '背景色',
10753
+ name: ['props', 'customTitle', 'style', 'backgroundColor']
10754
+ },
10755
+ {
10756
+ type: 'Group',
10757
+ label: '字体',
10758
+ child: [
10759
+ {
10760
+ type: 'Select',
10761
+ name: ['props', 'customTitle', 'style', 'fontFamily-cn'],
10762
+ bottomText: '中文字体'
10763
+ },
10764
+ {
10765
+ type: 'Select',
10766
+ name: ['props', 'customTitle', 'style', 'fontFamily-en'],
10767
+ bottomText: '英文/其他字体'
10768
+ }
10769
+ ]
10770
+ },
10771
+ {
10772
+ type: 'Group',
10773
+ label: '',
10774
+ child: [
10775
+ {
10776
+ type: 'Color',
10777
+ name: ['props', 'customTitle', 'style', 'color']
10778
+ },
10779
+ {
10780
+ type: 'Number',
10781
+ addonAfter: 'px',
10782
+ name: ['props', 'customTitle', 'style', 'fontSize']
10783
+ }
10784
+ ]
10785
+ },
10786
+ {
10787
+ label: '样式',
10788
+ type: 'TextStyle',
10789
+ name: ['props', 'customTitle', 'style']
10790
+ },
10791
+ {
10792
+ label: '对齐',
10793
+ type: 'TextAlign',
10794
+ name: ['props', 'customTitle', 'style']
10795
+ },
10796
+ {
10797
+ label: '上边距',
10798
+ type: 'Number',
10799
+ name: ['props', 'customTitle', 'style', 'marginTop'],
10800
+ addonAfter: 'px'
10801
+ }
10802
+ ]
10429
10803
  }
10430
10804
  ];
10431
10805
 
10432
- const Scroll = ({ children, isPadding = true }) => {
10433
- return (React.createElement(Swiper, { direction: 'horizontal', slidesPerView: 'auto', freeMode: true, mousewheel: true, modules: [freeMode, Scrollbar, Mousewheel], style: { padding: isPadding ? '0 12px 0 20px' : 0 } }, children));
10434
- };
10435
- var Scroll$1 = memo(Scroll);
10436
-
10437
- var styles$2 = {"two-line-ellipsis":"index-module_two-line-ellipsis__SFQwJ"};
10806
+ var styles$7 = {"tow-line-ellipsis":"index-module_tow-line-ellipsis__nkBlU","one-line-ellipsis":"index-module_one-line-ellipsis__buFw1"};
10438
10807
 
10439
- const MultiCommodityDiro$1 = (_a) => {
10440
- var _b, _c;
10441
- var { content, style, bgImg, recData, onClick, bottom_image, ctaTempStyles, isExternalLink, index, translateY = 0 } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "onClick", "bottom_image", "ctaTempStyles", "isExternalLink", "index", "translateY"]);
10442
- const { ctaEvent, setPopupDetailData, sxpParameter } = useSxpDataSource();
10443
- const { popup } = useEditor();
10808
+ const Link$1 = (_a) => {
10809
+ var _b, _c, _d, _e, _f, _g, _h, _j;
10810
+ var { content, style, bgImg, recData, bottom_image, ctaTempStyles, index, customTitle } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "bottom_image", "ctaTempStyles", "index", "customTitle"]);
10811
+ const { sxpParameter, bffEventReport } = useSxpDataSource();
10444
10812
  const { jumpToWeb } = useEventReport();
10445
- const [products, setProducts] = 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]);
10446
- const handleClick = throttle((item) => {
10447
- ctaEvent === null || ctaEvent === void 0 ? void 0 : ctaEvent({
10448
- eventSubject: 'clickCta',
10449
- eventDescription: 'User clicked the CTA'
10450
- }, recData, item, index);
10451
- setPopupDetailData === null || setPopupDetailData === void 0 ? void 0 : setPopupDetailData(Object.assign(Object.assign({}, recData), { video: Object.assign(Object.assign({}, recData === null || recData === void 0 ? void 0 : recData.video), { bindProduct: item }), index }));
10452
- if (isExternalLink) {
10453
- if (item === null || item === void 0 ? void 0 : item.link) {
10454
- jumpToWeb(recData, item, item.bindCta, index);
10455
- window.location.href = window.getJointUtmLink(item.link);
10456
- }
10457
- }
10458
- else {
10459
- onClick === null || onClick === void 0 ? void 0 : onClick();
10813
+ const cta = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindCta;
10814
+ const product = (_c = recData === null || recData === void 0 ? void 0 : recData.video) === null || _c === void 0 ? void 0 : _c.bindProduct;
10815
+ const handleTo = () => {
10816
+ if (cta === null || cta === void 0 ? void 0 : cta.link) {
10817
+ jumpToWeb(recData, product, cta, index);
10818
+ window.location.href = window.getJointUtmLink(cta.link);
10460
10819
  }
10461
- }, popup === null || popup === void 0 ? void 0 : popup.duration);
10462
- return (React.createElement(Scroll$1, { isPadding: !!recData }, products === null || products === void 0 ? void 0 : products.map((item) => {
10463
- var _a, _b, _c, _d, _e, _f, _g, _h;
10464
- return (React.createElement(React.Fragment, null, recData && !(item === null || item === void 0 ? void 0 : item.bindCta) ? null : (React.createElement(SwiperSlide, Object.assign({ key: item === null || item === void 0 ? void 0 : item.itemId, className: css(Object.assign(Object.assign({}, style), { display: 'flex', flexShrink: 0, marginLeft: 0, marginRight: '8px' })) }, props, { onClick: () => handleClick(item) }),
10465
- React.createElement(Img$1, { 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 }),
10466
- React.createElement("div", { className: css({
10467
- color: '#000',
10468
- display: 'flex',
10469
- flexDirection: 'column',
10470
- justifyContent: 'space-between',
10471
- width: '100%',
10472
- overflow: 'hidden'
10473
- }) },
10474
- React.createElement("div", { className: styles$2['two-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
10475
- __html: setFontForText((_e = item === null || item === void 0 ? void 0 : item.title) !== null && _e !== void 0 ? _e : 'Product Name', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title)
10820
+ };
10821
+ 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;
10822
+ return (React.createElement(EventProvider$1, Object.assign({ index: index, rec: recData, className: css(Object.assign({ alignItems: 'center' }, style)), style: { display: 'flex' } }, props, { onClick: handleTo }),
10823
+ React.createElement(Img$1, { src: src, rec: recData, item: (_g = (_f = recData === null || recData === void 0 ? void 0 : recData.video) === null || _f === void 0 ? void 0 : _f.bindProduct) !== null && _g !== void 0 ? _g : recData === null || recData === void 0 ? void 0 : recData.video, index: index, imgStyle: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img }),
10824
+ React.createElement("div", { className: css({
10825
+ display: 'flex',
10826
+ alignItems: 'center',
10827
+ width: '100%',
10828
+ overflow: 'hidden'
10829
+ }) },
10830
+ React.createElement("div", null,
10831
+ React.createElement("div", { className: (customTitle === null || customTitle === void 0 ? void 0 : customTitle.display) ? styles$7['one-line-ellipsis'] : styles$7['tow-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle, dangerouslySetInnerHTML: {
10832
+ __html: setFontForText((_h = cta === null || cta === void 0 ? void 0 : cta.enTitle) !== null && _h !== void 0 ? _h : 'Product Name', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
10476
10833
  } }),
10477
- React.createElement("div", { className: css(Object.assign({ padding: '0 7px', textOverflow: 'ellipsis', overflow: 'hidden', borderRadius: '25px', whiteSpace: 'nowrap', lineHeight: ((_f = ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle) === null || _f === void 0 ? void 0 : _f.height) + 'px' }, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)), dangerouslySetInnerHTML: {
10478
- __html: setFontForText((_h = (_g = item === null || item === void 0 ? void 0 : item.bindCta) === null || _g === void 0 ? void 0 : _g.enTitle) !== null && _h !== void 0 ? _h : 'Shop Now', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
10834
+ (customTitle === null || customTitle === void 0 ? void 0 : customTitle.display) && (React.createElement("div", { style: Object.assign(Object.assign({}, customTitle === null || customTitle === void 0 ? void 0 : customTitle.style), { lineHeight: ((_j = customTitle === null || customTitle === void 0 ? void 0 : customTitle.style) === null || _j === void 0 ? void 0 : _j.height) + 'px' }), className: styles$7['one-line-ellipsis'], dangerouslySetInnerHTML: {
10835
+ __html: setFontForText(customTitle === null || customTitle === void 0 ? void 0 : customTitle.text, customTitle === null || customTitle === void 0 ? void 0 : customTitle.style)
10479
10836
  } }))))));
10480
- })));
10481
10837
  };
10482
- var MultiCommodityDiroComponent = memo(MultiCommodityDiro$1);
10838
+ var LinkComponent = memo(Link$1);
10483
10839
 
10484
- /*
10485
- * @Author: binruan@chatlabs.com
10486
- * @Date: 2023-07-28 18:29:57
10487
- * @LastEditors: binruan@chatlabs.com
10488
- * @LastEditTime: 2024-03-29 16:27:22
10489
- * @FilePath: \pb-sxp-ui\src\materials\sxp\template\MultiCommodityDiro\material.tsx
10490
- *
10491
- */
10492
- const MultiCommodityDiro = createMaterial(MultiCommodityDiroComponent, {
10493
- displayName: '推荐多商品-白底圆角按钮',
10840
+ var _a;
10841
+ const Link = createMaterial(LinkComponent, {
10842
+ displayName: '跳转指引',
10494
10843
  icon: '',
10495
10844
  category: 'template',
10496
- type: 'MultiCommodityDiro',
10845
+ type: 'Link',
10497
10846
  related: {
10498
- interactionRender: interactionRender$2,
10499
- bindableProps: [],
10500
- settingRender: settingRender$2
10847
+ settingRender: (_a = settingRender$4 === null || settingRender$4 === void 0 ? void 0 : settingRender$4.filter((i) => i.type !== 'commodityTitle')) === null || _a === void 0 ? void 0 : _a.concat(linkSettingRender),
10848
+ bindableProps: []
10501
10849
  },
10502
10850
  defaulSetting: {
10503
10851
  props: {
@@ -10508,19 +10856,25 @@ const MultiCommodityDiro = createMaterial(MultiCommodityDiroComponent, {
10508
10856
  height: 60,
10509
10857
  marginRight: 8
10510
10858
  },
10511
- title: {
10512
- fontSize: 12,
10513
- color: '#000',
10514
- textAlign: 'left'
10515
- },
10516
10859
  ctaTitle: {
10517
- fontSize: 10,
10860
+ fontSize: 12,
10518
10861
  color: '#fff',
10519
- textAlign: 'center',
10520
- width: 80,
10521
- height: 20,
10522
- backgroundColor: 'rgba(0,0,0,1)'
10862
+ textAlign: 'left',
10863
+ width: 130,
10864
+ height: 20
10523
10865
  }
10866
+ },
10867
+ customTitle: {
10868
+ style: {
10869
+ textAlign: 'left',
10870
+ textDecoration: 'underline',
10871
+ fontWeight: 'bold',
10872
+ width: 130,
10873
+ height: 20,
10874
+ fontSize: 12,
10875
+ color: '#000'
10876
+ },
10877
+ text: '探索更多'
10524
10878
  }
10525
10879
  },
10526
10880
  style: {
@@ -10528,16 +10882,16 @@ const MultiCommodityDiro = createMaterial(MultiCommodityDiroComponent, {
10528
10882
  width: 236,
10529
10883
  height: 74,
10530
10884
  borderRadius: 3,
10531
- backgroundColor: '#fff',
10885
+ backgroundColor: 'rgba(0,0,0,.3)',
10532
10886
  marginBottom: 8
10533
10887
  }
10534
10888
  },
10535
10889
  w: 100,
10536
10890
  h: 40,
10537
- sort: 4
10891
+ sort: 5
10538
10892
  });
10539
10893
 
10540
- var interactionRender$1 = [
10894
+ var interactionRender$6 = [
10541
10895
  {
10542
10896
  title: '点击事件',
10543
10897
  child: [
@@ -10549,70 +10903,49 @@ var interactionRender$1 = [
10549
10903
  }
10550
10904
  ];
10551
10905
 
10552
- var styles$1 = {"two-line-ellipsis":"index-module_two-line-ellipsis__mdzn0"};
10906
+ var styles$6 = {"tow-line-ellipsis":"index-module_tow-line-ellipsis__yyHVb"};
10553
10907
 
10554
- const MultiCommodity$1 = (_a) => {
10555
- var _b, _c;
10556
- var { content, style, bgImg, recData, onClick, bottom_image, ctaTempStyles, isExternalLink, index, translateY = 0 } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "onClick", "bottom_image", "ctaTempStyles", "isExternalLink", "index", "translateY"]);
10908
+ const CommodityDiro$1 = (_a) => {
10909
+ var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
10910
+ 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"]);
10557
10911
  const { sxpParameter } = useSxpDataSource();
10558
- const { ctaEvent, setPopupDetailData } = useSxpDataSource();
10559
- const { popup } = useEditor();
10560
- const [products, setProducts] = 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]);
10561
- const { jumpToWeb } = useEventReport();
10562
- const handleClick = throttle((item) => {
10563
- ctaEvent === null || ctaEvent === void 0 ? void 0 : ctaEvent({
10564
- eventSubject: 'clickCta',
10565
- eventDescription: 'User clicked the CTA'
10566
- }, recData, item, index);
10567
- setPopupDetailData === null || setPopupDetailData === void 0 ? void 0 : setPopupDetailData(Object.assign(Object.assign({}, recData), { video: Object.assign(Object.assign({}, recData === null || recData === void 0 ? void 0 : recData.video), { bindProduct: item }), index }));
10568
- if (isExternalLink) {
10569
- if (item === null || item === void 0 ? void 0 : item.link) {
10570
- jumpToWeb(recData, item, item.bindCta, index);
10571
- window.location.href = window.getJointUtmLink(item.link);
10572
- }
10573
- }
10574
- else {
10575
- onClick === null || onClick === void 0 ? void 0 : onClick();
10576
- }
10577
- }, popup === null || popup === void 0 ? void 0 : popup.duration);
10578
- return (React.createElement(Scroll$1, { isPadding: !!recData }, products === null || products === void 0 ? void 0 : products.map((item) => {
10579
- var _a, _b, _c, _d, _e, _f, _g, _h;
10580
- return (React.createElement(React.Fragment, null, recData && !(item === null || item === void 0 ? void 0 : item.bindCta) ? null : (React.createElement(SwiperSlide, Object.assign({ key: item.itemId, className: css(Object.assign(Object.assign({}, style), { display: 'flex', flexShrink: 0, marginLeft: 0, marginRight: '8px' })) }, props, { onClick: () => handleClick(item) }),
10581
- React.createElement(Img$1, { 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 }),
10582
- React.createElement("div", { className: css({
10583
- color: '#fff',
10584
- display: 'flex',
10585
- flexDirection: 'column',
10586
- justifyContent: 'space-between',
10587
- width: '100%',
10588
- overflow: 'hidden'
10589
- }) },
10590
- React.createElement("div", { className: styles$1['two-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
10591
- __html: setFontForText((_e = item === null || item === void 0 ? void 0 : item.title) !== null && _e !== void 0 ? _e : 'Product Name', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title)
10592
- } }),
10593
- React.createElement("div", { className: css(Object.assign({ padding: '0 7px', textOverflow: 'ellipsis', overflow: 'hidden', whiteSpace: 'nowrap', lineHeight: ((_f = ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle) === null || _f === void 0 ? void 0 : _f.height) + 'px' }, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)), dangerouslySetInnerHTML: {
10594
- __html: setFontForText((_h = (_g = item === null || item === void 0 ? void 0 : item.bindCta) === null || _g === void 0 ? void 0 : _g.enTitle) !== null && _h !== void 0 ? _h : 'Shop Now', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
10595
- } }))))));
10596
- })));
10597
- };
10598
- var MultiCommodityComponent = memo(MultiCommodity$1);
10599
-
10600
- /*
10601
- * @Author: binruan@chatlabs.com
10912
+ const product = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindProduct;
10913
+ 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;
10914
+ return (React.createElement(EventProvider$1, Object.assign({ isExternalLink: isExternalLink, rec: recData, className: css(Object.assign({}, style)), style: { display: 'flex' }, index: index }, props),
10915
+ 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 }),
10916
+ React.createElement("div", { className: css({
10917
+ color: '#fff',
10918
+ display: 'flex',
10919
+ flexDirection: 'column',
10920
+ justifyContent: 'space-between',
10921
+ width: '100%',
10922
+ overflow: 'hidden'
10923
+ }) },
10924
+ React.createElement("div", { className: styles$6['tow-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
10925
+ __html: setFontForText((_j = product === null || product === void 0 ? void 0 : product.title) !== null && _j !== void 0 ? _j : 'Product Name', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title)
10926
+ } }),
10927
+ React.createElement("div", { className: css(Object.assign({ padding: '0 7px', textOverflow: 'ellipsis', overflow: 'hidden', borderRadius: '25px', whiteSpace: 'nowrap', lineHeight: ((_k = ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle) === null || _k === void 0 ? void 0 : _k.height) + 'px' }, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)), dangerouslySetInnerHTML: {
10928
+ __html: setFontForText((_m = (_l = product === null || product === void 0 ? void 0 : product.bindCta) === null || _l === void 0 ? void 0 : _l.enTitle) !== null && _m !== void 0 ? _m : 'Shop Now', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
10929
+ } }))));
10930
+ };
10931
+ var CommodityDiroComponent = memo(CommodityDiro$1);
10932
+
10933
+ /*
10934
+ * @Author: binruan@chatlabs.com
10602
10935
  * @Date: 2023-07-28 18:29:57
10603
10936
  * @LastEditors: binruan@chatlabs.com
10604
- * @LastEditTime: 2024-03-29 16:43:35
10605
- * @FilePath: \pb-sxp-ui\src\materials\sxp\template\MultiCommodity\material.tsx
10937
+ * @LastEditTime: 2024-03-29 16:07:28
10938
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\template\CommodityDiro\material.tsx
10606
10939
  *
10607
10940
  */
10608
- const MultiCommodity = createMaterial(MultiCommodityComponent, {
10609
- displayName: '推荐多商品-透明底',
10941
+ const CommodityDiro = createMaterial(CommodityDiroComponent, {
10942
+ displayName: '推荐单商品-白底圆角按钮',
10610
10943
  icon: '',
10611
10944
  category: 'template',
10612
- type: 'MultiCommodity',
10945
+ type: 'CommodityDiro',
10613
10946
  related: {
10614
- interactionRender: interactionRender$1,
10615
- settingRender: settingRender$2,
10947
+ interactionRender: interactionRender$6,
10948
+ settingRender: settingRender$4,
10616
10949
  bindableProps: []
10617
10950
  },
10618
10951
  defaulSetting: {
@@ -10626,16 +10959,16 @@ const MultiCommodity = createMaterial(MultiCommodityComponent, {
10626
10959
  },
10627
10960
  title: {
10628
10961
  fontSize: 12,
10629
- color: '#fff',
10962
+ color: '#000',
10630
10963
  textAlign: 'left'
10631
10964
  },
10632
10965
  ctaTitle: {
10633
10966
  fontSize: 10,
10634
10967
  color: '#fff',
10635
10968
  textAlign: 'center',
10636
- width: 130,
10969
+ width: 80,
10637
10970
  height: 20,
10638
- backgroundColor: 'rgba(0,0,0,.5)'
10971
+ backgroundColor: 'rgba(0,0,0,1)'
10639
10972
  }
10640
10973
  }
10641
10974
  },
@@ -10644,16 +10977,16 @@ const MultiCommodity = createMaterial(MultiCommodityComponent, {
10644
10977
  width: 236,
10645
10978
  height: 74,
10646
10979
  borderRadius: 3,
10647
- backgroundColor: 'rgba(0,0,0,.3)',
10980
+ backgroundColor: '#fff',
10648
10981
  marginBottom: 8
10649
10982
  }
10650
10983
  },
10651
10984
  w: 100,
10652
10985
  h: 40,
10653
- sort: 3
10986
+ sort: 2
10654
10987
  });
10655
10988
 
10656
- var interactionRender = [
10989
+ var interactionRender$5 = [
10657
10990
  {
10658
10991
  title: '点击事件',
10659
10992
  child: [
@@ -10665,9 +10998,105 @@ var interactionRender = [
10665
10998
  }
10666
10999
  ];
10667
11000
 
10668
- var styles = {"tow-line-ellipsis":"index-module_tow-line-ellipsis__fselR"};
11001
+ var styles$5 = {"tow-line-ellipsis":"index-module_tow-line-ellipsis__I-yCC"};
10669
11002
 
10670
- const MultiCommodityDiroNew$1 = (_a) => {
11003
+ const CommodityDiroNew$1 = (_a) => {
11004
+ var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
11005
+ 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"]);
11006
+ const { sxpParameter } = useSxpDataSource();
11007
+ const product = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindProduct;
11008
+ 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;
11009
+ return (React.createElement(EventProvider$1, Object.assign({ isExternalLink: isExternalLink, rec: recData, className: css(Object.assign({}, style)), style: { display: 'flex' }, index: index }, props),
11010
+ 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 }),
11011
+ React.createElement("div", { className: css({
11012
+ color: '#fff',
11013
+ display: 'flex',
11014
+ flexDirection: 'column',
11015
+ justifyContent: 'center',
11016
+ width: '100%',
11017
+ overflow: 'hidden'
11018
+ }) },
11019
+ React.createElement("div", { className: styles$5['tow-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
11020
+ __html: setFontForText((_j = product === null || product === void 0 ? void 0 : product.title) !== null && _j !== void 0 ? _j : 'Product Name', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title)
11021
+ } }),
11022
+ React.createElement("div", { className: css(Object.assign({ textOverflow: 'ellipsis', overflow: 'hidden', whiteSpace: 'nowrap' }, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)), dangerouslySetInnerHTML: {
11023
+ __html: setFontForText((_l = (_k = product === null || product === void 0 ? void 0 : product.bindCta) === null || _k === void 0 ? void 0 : _k.enTitle) !== null && _l !== void 0 ? _l : 'Shop Now', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
11024
+ } }))));
11025
+ };
11026
+ var CommodityDiroNewComponent = memo(CommodityDiroNew$1);
11027
+
11028
+ /*
11029
+ * @Author: binruan@chatlabs.com
11030
+ * @Date: 2023-07-28 18:29:57
11031
+ * @LastEditors: binruan@chatlabs.com
11032
+ * @LastEditTime: 2024-04-09 11:54:27
11033
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\template\CommodityDiroNew\material.tsx
11034
+ *
11035
+ */
11036
+ const CommodityDiroNew = createMaterial(CommodityDiroNewComponent, {
11037
+ displayName: '推荐单商品-白底下划线按钮',
11038
+ icon: '',
11039
+ category: 'template',
11040
+ type: 'CommodityDiroNew',
11041
+ related: {
11042
+ interactionRender: interactionRender$5,
11043
+ bindableProps: [],
11044
+ settingRender: settingRender$4
11045
+ },
11046
+ defaulSetting: {
11047
+ props: {
11048
+ ctaTempStyles: {
11049
+ img: {
11050
+ borderRadius: 8,
11051
+ width: 78,
11052
+ height: 78,
11053
+ marginRight: 16
11054
+ },
11055
+ title: {
11056
+ fontSize: 13,
11057
+ color: '#000',
11058
+ textAlign: 'left'
11059
+ },
11060
+ ctaTitle: {
11061
+ textDecoration: 'underline',
11062
+ fontSize: 14,
11063
+ fontWeight: 'bold',
11064
+ color: '#000',
11065
+ textAlign: 'left',
11066
+ width: 150,
11067
+ height: 20
11068
+ }
11069
+ }
11070
+ },
11071
+ style: {
11072
+ borderRadius: 4,
11073
+ width: 260,
11074
+ height: 86,
11075
+ padding: 4,
11076
+ backgroundColor: 'rgba(255,255,255,0.75)',
11077
+ marginBottom: 8
11078
+ }
11079
+ },
11080
+ w: 100,
11081
+ h: 40,
11082
+ sort: 2
11083
+ });
11084
+
11085
+ var interactionRender$4 = [
11086
+ {
11087
+ title: '点击事件',
11088
+ child: [
11089
+ {
11090
+ type: 'link',
11091
+ name: 'onClick'
11092
+ }
11093
+ ]
11094
+ }
11095
+ ];
11096
+
11097
+ var styles$4 = {"two-line-ellipsis":"index-module_two-line-ellipsis__SFQwJ"};
11098
+
11099
+ const MultiCommodityDiro$1 = (_a) => {
10671
11100
  var _b, _c;
10672
11101
  var { content, style, bgImg, recData, onClick, bottom_image, ctaTempStyles, isExternalLink, index, translateY = 0 } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "onClick", "bottom_image", "ctaTempStyles", "isExternalLink", "index", "translateY"]);
10673
11102
  const { ctaEvent, setPopupDetailData, sxpParameter } = useSxpDataSource();
@@ -10690,55 +11119,54 @@ const MultiCommodityDiroNew$1 = (_a) => {
10690
11119
  onClick === null || onClick === void 0 ? void 0 : onClick();
10691
11120
  }
10692
11121
  }, popup === null || popup === void 0 ? void 0 : popup.duration);
10693
- return (React.createElement(Scroll$1, { isPadding: !!recData }, products === null || products === void 0 ? void 0 : products.map((item) => {
10694
- var _a, _b, _c, _d, _e, _f, _g;
10695
- return (React.createElement(React.Fragment, null, recData && !(item === null || item === void 0 ? void 0 : item.bindCta) ? null : (React.createElement(SwiperSlide, Object.assign({ key: item === null || item === void 0 ? void 0 : item.itemId, className: css(Object.assign(Object.assign({}, style), { display: 'flex', flexShrink: 0, marginLeft: 0, marginRight: '8px' })) }, props, { onClick: () => handleClick(item) }),
11122
+ return (React.createElement(Scroll$1, { isPadding: !!recData }, products === null || products === void 0 ? void 0 : products.map((item, index) => {
11123
+ var _a, _b, _c, _d, _e, _f, _g, _h;
11124
+ return (React.createElement(React.Fragment, null, recData && !(item === null || item === void 0 ? void 0 : item.bindCta) ? null : (React.createElement(SwiperSlide, Object.assign({ key: index, className: css(Object.assign(Object.assign({}, style), { display: 'flex', flexShrink: 0, marginLeft: 0, marginRight: '8px' })) }, props, { onClick: () => handleClick(item) }),
10696
11125
  React.createElement(Img$1, { 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 }),
10697
11126
  React.createElement("div", { className: css({
10698
- color: '#fff',
11127
+ color: '#000',
10699
11128
  display: 'flex',
10700
11129
  flexDirection: 'column',
10701
- justifyContent: 'center',
11130
+ justifyContent: 'space-between',
10702
11131
  width: '100%',
10703
- overflow: 'hidden',
10704
- lineHeight: '20px'
11132
+ overflow: 'hidden'
10705
11133
  }) },
10706
- React.createElement("div", { className: styles['tow-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
11134
+ React.createElement("div", { className: styles$4['two-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
10707
11135
  __html: setFontForText((_e = item === null || item === void 0 ? void 0 : item.title) !== null && _e !== void 0 ? _e : 'Product Name', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title)
10708
11136
  } }),
10709
- React.createElement("div", { className: css(Object.assign({ textOverflow: 'ellipsis', overflow: 'hidden', whiteSpace: 'nowrap' }, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)), dangerouslySetInnerHTML: {
10710
- __html: setFontForText((_g = (_f = item === null || item === void 0 ? void 0 : item.bindCta) === null || _f === void 0 ? void 0 : _f.enTitle) !== null && _g !== void 0 ? _g : 'Shop Now', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
11137
+ React.createElement("div", { className: css(Object.assign({ padding: '0 7px', textOverflow: 'ellipsis', overflow: 'hidden', borderRadius: '25px', whiteSpace: 'nowrap', lineHeight: ((_f = ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle) === null || _f === void 0 ? void 0 : _f.height) + 'px' }, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)), dangerouslySetInnerHTML: {
11138
+ __html: setFontForText((_h = (_g = item === null || item === void 0 ? void 0 : item.bindCta) === null || _g === void 0 ? void 0 : _g.enTitle) !== null && _h !== void 0 ? _h : 'Shop Now', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
10711
11139
  } }))))));
10712
11140
  })));
10713
11141
  };
10714
- var MultiCommodityDiroNewComponent = memo(MultiCommodityDiroNew$1);
11142
+ var MultiCommodityDiroComponent = memo(MultiCommodityDiro$1);
10715
11143
 
10716
11144
  /*
10717
11145
  * @Author: binruan@chatlabs.com
10718
11146
  * @Date: 2023-07-28 18:29:57
10719
11147
  * @LastEditors: binruan@chatlabs.com
10720
- * @LastEditTime: 2024-05-21 16:44:00
10721
- * @FilePath: \pb-sxp-ui\src\materials\sxp\template\MultiCommodityDiroNew\material.tsx
11148
+ * @LastEditTime: 2024-03-29 16:27:22
11149
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\template\MultiCommodityDiro\material.tsx
10722
11150
  *
10723
11151
  */
10724
- const MultiCommodityDiroNew = createMaterial(MultiCommodityDiroNewComponent, {
10725
- displayName: '推荐多商品-白底下划线按钮',
11152
+ const MultiCommodityDiro = createMaterial(MultiCommodityDiroComponent, {
11153
+ displayName: '推荐多商品-白底圆角按钮',
10726
11154
  icon: '',
10727
11155
  category: 'template',
10728
- type: 'MultiCommodityDiroNew',
11156
+ type: 'MultiCommodityDiro',
10729
11157
  related: {
10730
- interactionRender,
11158
+ interactionRender: interactionRender$4,
10731
11159
  bindableProps: [],
10732
- settingRender: settingRender$2
11160
+ settingRender: settingRender$4
10733
11161
  },
10734
11162
  defaulSetting: {
10735
11163
  props: {
10736
11164
  ctaTempStyles: {
10737
11165
  img: {
10738
- borderRadius: 8,
10739
- width: 78,
10740
- height: 78,
10741
- marginRight: 16
11166
+ borderRadius: 3,
11167
+ width: 60,
11168
+ height: 60,
11169
+ marginRight: 8
10742
11170
  },
10743
11171
  title: {
10744
11172
  fontSize: 12,
@@ -10746,22 +11174,21 @@ const MultiCommodityDiroNew = createMaterial(MultiCommodityDiroNewComponent, {
10746
11174
  textAlign: 'left'
10747
11175
  },
10748
11176
  ctaTitle: {
10749
- textDecoration: 'underline',
10750
- fontSize: 12,
10751
- fontWeight: 'bold',
10752
- color: '#000',
10753
- textAlign: 'left',
10754
- width: 150,
10755
- height: 20
11177
+ fontSize: 10,
11178
+ color: '#fff',
11179
+ textAlign: 'center',
11180
+ width: 80,
11181
+ height: 20,
11182
+ backgroundColor: 'rgba(0,0,0,1)'
10756
11183
  }
10757
11184
  }
10758
11185
  },
10759
11186
  style: {
10760
- borderRadius: 4,
10761
- width: 260,
10762
- height: 86,
10763
- padding: 4,
10764
- backgroundColor: 'rgba(255,255,255,0.75)',
11187
+ padding: 7,
11188
+ width: 236,
11189
+ height: 74,
11190
+ borderRadius: 3,
11191
+ backgroundColor: '#fff',
10765
11192
  marginBottom: 8
10766
11193
  }
10767
11194
  },
@@ -10770,42 +11197,276 @@ const MultiCommodityDiroNew = createMaterial(MultiCommodityDiroNewComponent, {
10770
11197
  sort: 4
10771
11198
  });
10772
11199
 
10773
- /*
10774
- * @Author: binruan@chatlabs.com
10775
- * @Date: 2024-04-07 14:07:12
10776
- * @LastEditors: binruan@chatlabs.com
10777
- * @LastEditTime: 2024-06-27 09:49:19
10778
- * @FilePath: \pb-sxp-ui\src\materials\sxp\HashTag\settingRender.tsx
10779
- *
10780
- */
10781
- var settingRender$1 = [
11200
+ var interactionRender$3 = [
10782
11201
  {
10783
- title: 'Banner',
11202
+ title: '点击事件',
10784
11203
  child: [
10785
11204
  {
10786
- type: 'Switch',
10787
- label: 'Banner图开关',
10788
- name: ['props', 'showBanner']
11205
+ type: 'link',
11206
+ name: 'onClick'
10789
11207
  }
10790
11208
  ]
10791
- },
10792
- {
10793
- title: '卡片样式',
10794
- child: [
10795
- {
10796
- type: 'Number',
10797
- label: '上下边距',
10798
- name: ['props', 'space'],
10799
- addonAfter: 'px'
10800
- },
10801
- {
10802
- type: 'Switch',
10803
- label: '固定宽高',
10804
- name: ['props', 'openFixedSize'],
10805
- initialValue: true
11209
+ }
11210
+ ];
11211
+
11212
+ var styles$3 = {"two-line-ellipsis":"index-module_two-line-ellipsis__mdzn0"};
11213
+
11214
+ const MultiCommodity$1 = (_a) => {
11215
+ var _b, _c;
11216
+ var { content, style, bgImg, recData, onClick, bottom_image, ctaTempStyles, isExternalLink, index, translateY = 0 } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "onClick", "bottom_image", "ctaTempStyles", "isExternalLink", "index", "translateY"]);
11217
+ const { sxpParameter } = useSxpDataSource();
11218
+ const { ctaEvent, setPopupDetailData } = useSxpDataSource();
11219
+ const { popup } = useEditor();
11220
+ const [products, setProducts] = 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]);
11221
+ const { jumpToWeb } = useEventReport();
11222
+ const handleClick = throttle((item) => {
11223
+ ctaEvent === null || ctaEvent === void 0 ? void 0 : ctaEvent({
11224
+ eventSubject: 'clickCta',
11225
+ eventDescription: 'User clicked the CTA'
11226
+ }, recData, item, index);
11227
+ setPopupDetailData === null || setPopupDetailData === void 0 ? void 0 : setPopupDetailData(Object.assign(Object.assign({}, recData), { video: Object.assign(Object.assign({}, recData === null || recData === void 0 ? void 0 : recData.video), { bindProduct: item }), index }));
11228
+ if (isExternalLink) {
11229
+ if (item === null || item === void 0 ? void 0 : item.link) {
11230
+ jumpToWeb(recData, item, item.bindCta, index);
11231
+ window.location.href = window.getJointUtmLink(item.link);
10806
11232
  }
10807
- ]
10808
- },
11233
+ }
11234
+ else {
11235
+ onClick === null || onClick === void 0 ? void 0 : onClick();
11236
+ }
11237
+ }, popup === null || popup === void 0 ? void 0 : popup.duration);
11238
+ return (React.createElement(Scroll$1, { isPadding: !!recData }, products === null || products === void 0 ? void 0 : products.map((item, index) => {
11239
+ var _a, _b, _c, _d, _e, _f, _g, _h;
11240
+ return (React.createElement(React.Fragment, null, recData && !(item === null || item === void 0 ? void 0 : item.bindCta) ? null : (React.createElement(SwiperSlide, Object.assign({ key: index, className: css(Object.assign(Object.assign({}, style), { display: 'flex', flexShrink: 0, marginLeft: 0, marginRight: '8px' })) }, props, { onClick: () => handleClick(item) }),
11241
+ React.createElement(Img$1, { 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 }),
11242
+ React.createElement("div", { className: css({
11243
+ color: '#fff',
11244
+ display: 'flex',
11245
+ flexDirection: 'column',
11246
+ justifyContent: 'space-between',
11247
+ width: '100%',
11248
+ overflow: 'hidden'
11249
+ }) },
11250
+ React.createElement("div", { className: styles$3['two-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
11251
+ __html: setFontForText((_e = item === null || item === void 0 ? void 0 : item.title) !== null && _e !== void 0 ? _e : 'Product Name', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title)
11252
+ } }),
11253
+ React.createElement("div", { className: css(Object.assign({ padding: '0 7px', textOverflow: 'ellipsis', overflow: 'hidden', whiteSpace: 'nowrap', lineHeight: ((_f = ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle) === null || _f === void 0 ? void 0 : _f.height) + 'px' }, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)), dangerouslySetInnerHTML: {
11254
+ __html: setFontForText((_h = (_g = item === null || item === void 0 ? void 0 : item.bindCta) === null || _g === void 0 ? void 0 : _g.enTitle) !== null && _h !== void 0 ? _h : 'Shop Now', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
11255
+ } }))))));
11256
+ })));
11257
+ };
11258
+ var MultiCommodityComponent = memo(MultiCommodity$1);
11259
+
11260
+ /*
11261
+ * @Author: binruan@chatlabs.com
11262
+ * @Date: 2023-07-28 18:29:57
11263
+ * @LastEditors: binruan@chatlabs.com
11264
+ * @LastEditTime: 2024-03-29 16:43:35
11265
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\template\MultiCommodity\material.tsx
11266
+ *
11267
+ */
11268
+ const MultiCommodity = createMaterial(MultiCommodityComponent, {
11269
+ displayName: '推荐多商品-透明底',
11270
+ icon: '',
11271
+ category: 'template',
11272
+ type: 'MultiCommodity',
11273
+ related: {
11274
+ interactionRender: interactionRender$3,
11275
+ settingRender: settingRender$4,
11276
+ bindableProps: []
11277
+ },
11278
+ defaulSetting: {
11279
+ props: {
11280
+ ctaTempStyles: {
11281
+ img: {
11282
+ borderRadius: 3,
11283
+ width: 60,
11284
+ height: 60,
11285
+ marginRight: 8
11286
+ },
11287
+ title: {
11288
+ fontSize: 12,
11289
+ color: '#fff',
11290
+ textAlign: 'left'
11291
+ },
11292
+ ctaTitle: {
11293
+ fontSize: 10,
11294
+ color: '#fff',
11295
+ textAlign: 'center',
11296
+ width: 130,
11297
+ height: 20,
11298
+ backgroundColor: 'rgba(0,0,0,.5)'
11299
+ }
11300
+ }
11301
+ },
11302
+ style: {
11303
+ padding: 7,
11304
+ width: 236,
11305
+ height: 74,
11306
+ borderRadius: 3,
11307
+ backgroundColor: 'rgba(0,0,0,.3)',
11308
+ marginBottom: 8
11309
+ }
11310
+ },
11311
+ w: 100,
11312
+ h: 40,
11313
+ sort: 3
11314
+ });
11315
+
11316
+ var interactionRender$2 = [
11317
+ {
11318
+ title: '点击事件',
11319
+ child: [
11320
+ {
11321
+ type: 'link',
11322
+ name: 'onClick'
11323
+ }
11324
+ ]
11325
+ }
11326
+ ];
11327
+
11328
+ var styles$2 = {"tow-line-ellipsis":"index-module_tow-line-ellipsis__fselR"};
11329
+
11330
+ const MultiCommodityDiroNew$1 = (_a) => {
11331
+ var _b, _c;
11332
+ var { content, style, bgImg, recData, onClick, bottom_image, ctaTempStyles, isExternalLink, index, translateY = 0 } = _a, props = __rest(_a, ["content", "style", "bgImg", "recData", "onClick", "bottom_image", "ctaTempStyles", "isExternalLink", "index", "translateY"]);
11333
+ const { ctaEvent, setPopupDetailData, sxpParameter } = useSxpDataSource();
11334
+ const { popup } = useEditor();
11335
+ const { jumpToWeb } = useEventReport();
11336
+ const [products, setProducts] = 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]);
11337
+ const handleClick = throttle((item, multiCheckIndex) => {
11338
+ ctaEvent === null || ctaEvent === void 0 ? void 0 : ctaEvent({
11339
+ eventSubject: 'clickCta',
11340
+ eventDescription: 'User clicked the CTA'
11341
+ }, recData, item, index);
11342
+ setPopupDetailData === null || setPopupDetailData === void 0 ? void 0 : setPopupDetailData(Object.assign(Object.assign({}, recData), { video: Object.assign(Object.assign({}, recData === null || recData === void 0 ? void 0 : recData.video), { bindProduct: item }), index,
11343
+ multiCheckIndex }));
11344
+ if (isExternalLink) {
11345
+ if (item === null || item === void 0 ? void 0 : item.link) {
11346
+ jumpToWeb(recData, item, item.bindCta, index);
11347
+ window.location.href = window.getJointUtmLink(item.link);
11348
+ }
11349
+ }
11350
+ else {
11351
+ onClick === null || onClick === void 0 ? void 0 : onClick();
11352
+ }
11353
+ }, popup === null || popup === void 0 ? void 0 : popup.duration);
11354
+ return (React.createElement(Scroll$1, { isPadding: !!recData }, products === null || products === void 0 ? void 0 : products.map((item, index) => {
11355
+ var _a, _b, _c, _d, _e, _f, _g;
11356
+ return (React.createElement(React.Fragment, null, recData && !(item === null || item === void 0 ? void 0 : item.bindCta) ? null : (React.createElement(SwiperSlide, Object.assign({ key: index, className: css(Object.assign(Object.assign({}, style), { display: 'flex', flexShrink: 0, marginLeft: 0, marginRight: '8px' })) }, props, { onClick: () => handleClick(item, index) }),
11357
+ React.createElement(Img$1, { 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 }),
11358
+ React.createElement("div", { className: css({
11359
+ color: '#fff',
11360
+ display: 'flex',
11361
+ flexDirection: 'column',
11362
+ justifyContent: 'center',
11363
+ width: '100%',
11364
+ overflow: 'hidden',
11365
+ lineHeight: '20px'
11366
+ }) },
11367
+ React.createElement("div", { className: styles$2['tow-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
11368
+ __html: setFontForText((_e = item === null || item === void 0 ? void 0 : item.title) !== null && _e !== void 0 ? _e : 'Product Name', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title)
11369
+ } }),
11370
+ React.createElement("div", { className: css(Object.assign({ textOverflow: 'ellipsis', overflow: 'hidden', whiteSpace: 'nowrap' }, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)), dangerouslySetInnerHTML: {
11371
+ __html: setFontForText((_g = (_f = item === null || item === void 0 ? void 0 : item.bindCta) === null || _f === void 0 ? void 0 : _f.enTitle) !== null && _g !== void 0 ? _g : 'Shop Now', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
11372
+ } }))))));
11373
+ })));
11374
+ };
11375
+ var MultiCommodityDiroNewComponent = memo(MultiCommodityDiroNew$1);
11376
+
11377
+ /*
11378
+ * @Author: binruan@chatlabs.com
11379
+ * @Date: 2023-07-28 18:29:57
11380
+ * @LastEditors: binruan@chatlabs.com
11381
+ * @LastEditTime: 2024-05-21 16:44:00
11382
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\template\MultiCommodityDiroNew\material.tsx
11383
+ *
11384
+ */
11385
+ const MultiCommodityDiroNew = createMaterial(MultiCommodityDiroNewComponent, {
11386
+ displayName: '推荐多商品-白底下划线按钮',
11387
+ icon: '',
11388
+ category: 'template',
11389
+ type: 'MultiCommodityDiroNew',
11390
+ related: {
11391
+ interactionRender: interactionRender$2,
11392
+ bindableProps: [],
11393
+ settingRender: settingRender$4
11394
+ },
11395
+ defaulSetting: {
11396
+ props: {
11397
+ ctaTempStyles: {
11398
+ img: {
11399
+ borderRadius: 8,
11400
+ width: 78,
11401
+ height: 78,
11402
+ marginRight: 16
11403
+ },
11404
+ title: {
11405
+ fontSize: 12,
11406
+ color: '#000',
11407
+ textAlign: 'left'
11408
+ },
11409
+ ctaTitle: {
11410
+ textDecoration: 'underline',
11411
+ fontSize: 12,
11412
+ fontWeight: 'bold',
11413
+ color: '#000',
11414
+ textAlign: 'left',
11415
+ width: 150,
11416
+ height: 20
11417
+ }
11418
+ }
11419
+ },
11420
+ style: {
11421
+ borderRadius: 4,
11422
+ width: 260,
11423
+ height: 86,
11424
+ padding: 4,
11425
+ backgroundColor: 'rgba(255,255,255,0.75)',
11426
+ marginBottom: 8
11427
+ }
11428
+ },
11429
+ w: 100,
11430
+ h: 40,
11431
+ sort: 4
11432
+ });
11433
+
11434
+ /*
11435
+ * @Author: binruan@chatlabs.com
11436
+ * @Date: 2024-04-07 14:07:12
11437
+ * @LastEditors: binruan@chatlabs.com
11438
+ * @LastEditTime: 2024-06-27 09:49:19
11439
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\HashTag\settingRender.tsx
11440
+ *
11441
+ */
11442
+ var settingRender$3 = [
11443
+ {
11444
+ title: 'Banner',
11445
+ child: [
11446
+ {
11447
+ type: 'Switch',
11448
+ label: 'Banner图开关',
11449
+ name: ['props', 'showBanner']
11450
+ }
11451
+ ]
11452
+ },
11453
+ {
11454
+ title: '卡片样式',
11455
+ child: [
11456
+ {
11457
+ type: 'Number',
11458
+ label: '上下边距',
11459
+ name: ['props', 'space'],
11460
+ addonAfter: 'px'
11461
+ },
11462
+ {
11463
+ type: 'Switch',
11464
+ label: '固定宽高',
11465
+ name: ['props', 'openFixedSize'],
11466
+ initialValue: true
11467
+ }
11468
+ ]
11469
+ },
10809
11470
  {
10810
11471
  title: '文本设置',
10811
11472
  child: [
@@ -10995,7 +11656,7 @@ var settingRender$1 = [
10995
11656
  * @Author: binruan@chatlabs.com
10996
11657
  * @Date: 2023-12-26 16:11:34
10997
11658
  * @LastEditors: binruan@chatlabs.com
10998
- * @LastEditTime: 2024-07-04 18:34:18
11659
+ * @LastEditTime: 2024-06-27 10:19:28
10999
11660
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\Navbar.tsx
11000
11661
  *
11001
11662
  */
@@ -11004,7 +11665,7 @@ const Navbar = ({ icon, styles, textStyle, onClose }) => {
11004
11665
  const { waterFallData, setOpenHashtag } = useSxpDataSource();
11005
11666
  return (React.createElement("div", { className: 'clc-sxp-nav', style: styles },
11006
11667
  React.createElement("img", { className: 'clc-sxp-nav-left', src: icon, alt: 'back button', onClick: onClose }),
11007
- 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: {
11668
+ React.createElement("div", { className: 'clc-sxp-nav-title', style: textStyle, dangerouslySetInnerHTML: {
11008
11669
  __html: setFontForText(`#${(_a = waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.hashTag) !== null && _a !== void 0 ? _a : '标题'}`, textStyle)
11009
11670
  } })));
11010
11671
  };
@@ -12599,7 +13260,7 @@ function WaterfallList$1(_a) {
12599
13260
  var _a, _b;
12600
13261
  if ((_a = data === null || data === void 0 ? void 0 : data.tag) === null || _a === void 0 ? void 0 : _a.link) {
12601
13262
  reportTagsView();
12602
- window.location.href = window.getJointUtmLink((_b = data === null || data === void 0 ? void 0 : data.tag) === null || _b === void 0 ? void 0 : _b.link);
13263
+ window.location.href = (_b = data === null || data === void 0 ? void 0 : data.tag) === null || _b === void 0 ? void 0 : _b.link;
12603
13264
  }
12604
13265
  };
12605
13266
  return (React.createElement(React.Fragment, null, isLoadingData ? (React.createElement("div", { style: { height: '100%', width: '100%', display: 'flex', justifyContent: 'center', alignItems: 'center' } },
@@ -12834,7 +13495,7 @@ function WaterfallList(_a) {
12834
13495
  var _a, _b;
12835
13496
  if ((_a = data === null || data === void 0 ? void 0 : data.tag) === null || _a === void 0 ? void 0 : _a.link) {
12836
13497
  reportTagsView();
12837
- window.location.href = window.getJointUtmLink((_b = data === null || data === void 0 ? void 0 : data.tag) === null || _b === void 0 ? void 0 : _b.link);
13498
+ window.location.href = (_b = data === null || data === void 0 ? void 0 : data.tag) === null || _b === void 0 ? void 0 : _b.link;
12838
13499
  }
12839
13500
  };
12840
13501
  return (React.createElement(React.Fragment, null, isLoadingData ? (React.createElement("div", { style: { height: '100%', width: '100%', display: 'flex', justifyContent: 'center', alignItems: 'center' } },
@@ -12987,7 +13648,7 @@ var HashTagComponent = memo(HashTag$1);
12987
13648
  * @Author: binruan@chatlabs.com
12988
13649
  * @Date: 2023-07-28 18:29:57
12989
13650
  * @LastEditors: binruan@chatlabs.com
12990
- * @LastEditTime: 2024-07-04 18:38:10
13651
+ * @LastEditTime: 2024-04-30 10:13:13
12991
13652
  * @FilePath: \pb-sxp-ui\src\materials\sxp\HashTag\material.tsx
12992
13653
  *
12993
13654
  */
@@ -12997,7 +13658,7 @@ const HashTag = createMaterial(HashTagComponent, {
12997
13658
  category: 'base',
12998
13659
  type: 'HashTag',
12999
13660
  related: {
13000
- settingRender: settingRender$1,
13661
+ settingRender: settingRender$3,
13001
13662
  bindableProps: []
13002
13663
  },
13003
13664
  defaulSetting: {
@@ -13007,8 +13668,7 @@ const HashTag = createMaterial(HashTagComponent, {
13007
13668
  textStyles: {
13008
13669
  hashTagTitle: {
13009
13670
  fontSize: 16,
13010
- color: '#000',
13011
- textAlign: 'center'
13671
+ color: '#000'
13012
13672
  },
13013
13673
  hashTagDesc: {
13014
13674
  fontSize: 12,
@@ -13031,106 +13691,807 @@ const HashTag = createMaterial(HashTagComponent, {
13031
13691
  color: '#000'
13032
13692
  }
13033
13693
  },
13034
- buttonStyle: {
13035
- backgroundColor: '#000',
13036
- fontSize: 12,
13037
- height: 52,
13038
- fontWeight: 'bold',
13039
- textAlign: 'center',
13040
- color: '#fff',
13041
- borderRadius: 25
13694
+ buttonStyle: {
13695
+ backgroundColor: '#000',
13696
+ fontSize: 12,
13697
+ height: 52,
13698
+ fontWeight: 'bold',
13699
+ textAlign: 'center',
13700
+ color: '#fff',
13701
+ borderRadius: 25
13702
+ },
13703
+ buttonBgStyle: {
13704
+ backgroundColor: '#fff',
13705
+ height: 52,
13706
+ paddingTop: 20,
13707
+ paddingLeft: 20,
13708
+ paddingRight: 20,
13709
+ paddingBottom: 20
13710
+ }
13711
+ }
13712
+ },
13713
+ w: 100,
13714
+ h: 40,
13715
+ sort: 2
13716
+ });
13717
+
13718
+ /*
13719
+ * @Author: binruan@chatlabs.com
13720
+ * @Date: 2024-06-13 10:08:32
13721
+ * @LastEditors: binruan@chatlabs.com
13722
+ * @LastEditTime: 2024-06-13 17:42:50
13723
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\Consent\settingRender.tsx
13724
+ *
13725
+ */
13726
+ var settingRender$2 = [
13727
+ {
13728
+ title: '协议详情',
13729
+ child: [
13730
+ {
13731
+ type: 'Switch',
13732
+ label: '必须同意用户协议',
13733
+ name: ['props', 'privacy_necessity'],
13734
+ extra: '当新用户进入页面时,会出现用户协议弹窗,用户需要先同意协议后才能访问内容。'
13735
+ },
13736
+ {
13737
+ type: 'Text',
13738
+ label: '弹窗标题',
13739
+ name: ['props', 'privacy_title']
13740
+ },
13741
+ {
13742
+ type: 'TextArea',
13743
+ label: '用户协议弹窗内容',
13744
+ name: ['props', 'privacy_context']
13745
+ },
13746
+ {
13747
+ type: 'Group',
13748
+ label: '隐私政策',
13749
+ child: [
13750
+ {
13751
+ type: 'Text',
13752
+ name: ['props', 'privacy_policy_title']
13753
+ },
13754
+ {
13755
+ type: 'Text',
13756
+ name: ['props', 'privacy_policy_url'],
13757
+ addonBefore: 'https://'
13758
+ }
13759
+ ],
13760
+ extra: '当用户点击更多信息按钮时,将会跳转至设置的链接查看政策内容'
13761
+ }
13762
+ ]
13763
+ }
13764
+ ];
13765
+
13766
+ const Consent$1 = (props) => {
13767
+ return React.createElement(Consent$1, Object.assign({}, props));
13768
+ };
13769
+ var ConsentComponent = memo(Consent$1);
13770
+
13771
+ /*
13772
+ * @Author: binruan@chatlabs.com
13773
+ * @Date: 2023-07-28 18:29:57
13774
+ * @LastEditors: binruan@chatlabs.com
13775
+ * @LastEditTime: 2024-07-03 15:43:24
13776
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\Consent\material.tsx
13777
+ *
13778
+ */
13779
+ const Consent = createMaterial(ConsentComponent, {
13780
+ displayName: 'Consent',
13781
+ icon: '',
13782
+ category: 'base',
13783
+ type: 'Consent',
13784
+ related: {
13785
+ settingRender: settingRender$2
13786
+ },
13787
+ defaulSetting: {
13788
+ props: {},
13789
+ style: {}
13790
+ },
13791
+ w: 100,
13792
+ h: 40,
13793
+ sort: 1
13794
+ });
13795
+
13796
+ /*
13797
+ * @Author: binruan@chatlabs.com
13798
+ * @Date: 2024-07-02 14:51:32
13799
+ * @LastEditors: binruan@chatlabs.com
13800
+ * @LastEditTime: 2024-07-05 19:09:41
13801
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\cta\AniLink\settingRender.tsx
13802
+ *
13803
+ */
13804
+ var settingRender$1 = [
13805
+ {
13806
+ title: '主题样式',
13807
+ child: [
13808
+ {
13809
+ type: 'Group',
13810
+ label: '尺寸',
13811
+ child: [
13812
+ {
13813
+ type: 'Number',
13814
+ name: ['style', 'width'],
13815
+ addonAfter: 'W'
13816
+ },
13817
+ {
13818
+ type: 'Number',
13819
+ name: ['style', 'height'],
13820
+ addonAfter: 'H'
13821
+ }
13822
+ ]
13823
+ },
13824
+ {
13825
+ type: 'Group',
13826
+ label: '圆角',
13827
+ child: [
13828
+ {
13829
+ type: 'Slider',
13830
+ name: ['style', 'borderRadius'],
13831
+ max: 100
13832
+ },
13833
+ {
13834
+ type: 'Number',
13835
+ name: ['style', 'borderRadius'],
13836
+ addonAfter: 'px',
13837
+ max: 100
13838
+ }
13839
+ ]
13840
+ },
13841
+ {
13842
+ type: 'Color',
13843
+ label: '背景色',
13844
+ name: ['style', 'backgroundColor']
13845
+ },
13846
+ {
13847
+ type: 'TextMargin',
13848
+ name: ['style'],
13849
+ label: '上下边距',
13850
+ direction: 'vertical'
13851
+ },
13852
+ {
13853
+ type: 'TextPadding',
13854
+ name: ['style'],
13855
+ label: '内边距',
13856
+ direction: 'horizontal'
13857
+ }
13858
+ ]
13859
+ },
13860
+ {
13861
+ title: 'CTA标题',
13862
+ child: [
13863
+ {
13864
+ type: 'Group',
13865
+ label: '字体',
13866
+ child: [
13867
+ {
13868
+ type: 'Select',
13869
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'fontFamily-cn'],
13870
+ bottomText: '中文字体'
13871
+ },
13872
+ {
13873
+ type: 'Select',
13874
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'fontFamily-en'],
13875
+ bottomText: '英文/其他字体'
13876
+ }
13877
+ ]
13878
+ },
13879
+ {
13880
+ type: 'Group',
13881
+ label: '',
13882
+ child: [
13883
+ {
13884
+ type: 'Color',
13885
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'color']
13886
+ },
13887
+ {
13888
+ type: 'Number',
13889
+ addonAfter: 'px',
13890
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'fontSize']
13891
+ }
13892
+ ]
13893
+ },
13894
+ {
13895
+ label: '样式',
13896
+ type: 'TextStyle',
13897
+ name: ['props', 'ctaTempStyles', 'ctaTitle']
13898
+ },
13899
+ {
13900
+ label: '对齐',
13901
+ type: 'TextAlign',
13902
+ name: ['props', 'ctaTempStyles', 'ctaTitle']
13903
+ }
13904
+ ]
13905
+ }
13906
+ ];
13907
+
13908
+ var styles$1 = {"animated-button":"index-module_animated-button__lqTbg","gradientCover":"index-module_gradientCover__5iUag"};
13909
+
13910
+ const AniLink$1 = (_a) => {
13911
+ var _b, _c, _d, _e, _f, _g, _h, _j, _k;
13912
+ var { style, recData, ctaTempStyles, index, event, onClick, isExternalLink = false } = _a, props = __rest(_a, ["style", "recData", "ctaTempStyles", "index", "event", "onClick", "isExternalLink"]);
13913
+ const { ctaEvent, setPopupDetailData } = useSxpDataSource();
13914
+ const { jumpToWeb } = useEventReport();
13915
+ const ref = useRef(null);
13916
+ const isOnScreen = useOnScreen(ref);
13917
+ const cta = ((_d = (_c = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindProducts) === null || _c === void 0 ? void 0 : _c[0]) === null || _d === void 0 ? void 0 : _d.bindCta) || ((_f = (_e = recData === null || recData === void 0 ? void 0 : recData.video) === null || _e === void 0 ? void 0 : _e.bindProduct) === null || _f === void 0 ? void 0 : _f.bindCta) || ((_g = recData === null || recData === void 0 ? void 0 : recData.video) === null || _g === void 0 ? void 0 : _g.bindCta);
13918
+ const product = ((_j = (_h = recData === null || recData === void 0 ? void 0 : recData.video) === null || _h === void 0 ? void 0 : _h.bindProducts) === null || _j === void 0 ? void 0 : _j[0]) || ((_k = recData === null || recData === void 0 ? void 0 : recData.video) === null || _k === void 0 ? void 0 : _k.bindProduct);
13919
+ const handleTo = () => {
13920
+ var _a, _b, _c;
13921
+ const item = ((_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);
13922
+ ctaEvent === null || ctaEvent === void 0 ? void 0 : ctaEvent({
13923
+ eventSubject: 'clickCta',
13924
+ eventDescription: 'User clicked the CTA'
13925
+ }, recData, item, index);
13926
+ setPopupDetailData === null || setPopupDetailData === void 0 ? void 0 : setPopupDetailData(Object.assign(Object.assign({}, recData), { index }));
13927
+ if (isExternalLink) {
13928
+ jumpToWeb(recData, product, cta, index);
13929
+ }
13930
+ onClick === null || onClick === void 0 ? void 0 : onClick();
13931
+ };
13932
+ const title = (cta === null || cta === void 0 ? void 0 : cta.title) || '查看详情 >';
13933
+ const aniStyle = useMemo(() => {
13934
+ var _a, _b;
13935
+ const ani = event === null || event === void 0 ? void 0 : event.animation;
13936
+ if (ani) {
13937
+ const { delay, duration, backgroundColor } = ani;
13938
+ return {
13939
+ ':after': {
13940
+ animationDelay: `${(_a = delay / 1000) !== null && _a !== void 0 ? _a : 0}s`,
13941
+ animationDuration: `${(_b = duration / 1000) !== null && _b !== void 0 ? _b : 0}s`,
13942
+ backgroundColor: `${backgroundColor !== null && backgroundColor !== void 0 ? backgroundColor : 'transparent'}`
13943
+ }
13944
+ };
13945
+ }
13946
+ }, [event === null || event === void 0 ? void 0 : event.animation]);
13947
+ useEffect(() => {
13948
+ if (isOnScreen && (ref === null || ref === void 0 ? void 0 : ref.current)) {
13949
+ ctaEvent === null || ctaEvent === void 0 ? void 0 : ctaEvent({
13950
+ eventSubject: 'ctaExposure',
13951
+ eventDescription: 'The cta was shown to the user'
13952
+ }, recData, product, index);
13953
+ }
13954
+ }, [isOnScreen]);
13955
+ return (React.createElement("div", Object.assign({ ref: ref, style: Object.assign(Object.assign({}, style), { display: 'flex', alignItems: 'center' }) }, props, { className: `${styles$1['animated-button']} ${css(aniStyle)}`, onClick: handleTo }),
13956
+ React.createElement("div", { className: 'one-line-ellipsis', style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle, dangerouslySetInnerHTML: {
13957
+ __html: setFontForText(title, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
13958
+ } })));
13959
+ };
13960
+ var AniLinkComponent = memo(AniLink$1);
13961
+
13962
+ /*
13963
+ * @Author: binruan@chatlabs.com
13964
+ * @Date: 2024-07-05 14:08:41
13965
+ * @LastEditors: binruan@chatlabs.com
13966
+ * @LastEditTime: 2024-07-09 14:34:49
13967
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\cta\AniLink\interactionRender.tsx
13968
+ *
13969
+ */
13970
+ var interactionRender$1 = [
13971
+ {
13972
+ title: '点击事件',
13973
+ child: [
13974
+ {
13975
+ type: 'link',
13976
+ name: 'onClick'
13977
+ }
13978
+ ]
13979
+ },
13980
+ {
13981
+ title: '动画效果',
13982
+ child: [
13983
+ {
13984
+ type: 'Color',
13985
+ name: ['animation', 'backgroundColor'],
13986
+ label: '动画颜色'
13987
+ },
13988
+ {
13989
+ type: 'Select',
13990
+ name: ['animation', 'name'],
13991
+ label: '动画',
13992
+ options: [
13993
+ {
13994
+ label: '由左向右/中间扩散',
13995
+ value: 1
13996
+ }
13997
+ ],
13998
+ initialValue: 1,
13999
+ fieldProps: {
14000
+ style: {
14001
+ width: '100%'
14002
+ }
14003
+ }
14004
+ },
14005
+ {
14006
+ type: 'Number',
14007
+ label: '动画启动时间',
14008
+ name: ['animation', 'delay'],
14009
+ addonAfter: 'ms'
14010
+ },
14011
+ {
14012
+ type: 'Number',
14013
+ label: '动画持续时间',
14014
+ name: ['animation', 'duration'],
14015
+ addonAfter: 'ms'
14016
+ }
14017
+ ]
14018
+ }
14019
+ ];
14020
+
14021
+ /*
14022
+ * @Author: binruan@chatlabs.com
14023
+ * @Date: 2023-07-28 18:29:57
14024
+ * @LastEditors: binruan@chatlabs.com
14025
+ * @LastEditTime: 2024-07-05 19:27:54
14026
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\cta\AniLink\material.tsx
14027
+ *
14028
+ */
14029
+ const AniLink = createMaterial(AniLinkComponent, {
14030
+ displayName: '纯色动效CTA',
14031
+ icon: '',
14032
+ category: 'cta',
14033
+ type: 'AniLink',
14034
+ related: {
14035
+ settingRender: settingRender$1,
14036
+ bindableProps: [],
14037
+ interactionRender: interactionRender$1
14038
+ },
14039
+ defaulSetting: {
14040
+ props: {
14041
+ ctaTempStyles: {
14042
+ ctaTitle: {
14043
+ fontSize: 15,
14044
+ color: '#fff',
14045
+ textAlign: 'left'
14046
+ }
14047
+ }
14048
+ },
14049
+ style: {
14050
+ width: 236,
14051
+ height: 44,
14052
+ borderRadius: 3,
14053
+ backgroundColor: 'rgba(0,0,0,.3)',
14054
+ paddingLeft: 7,
14055
+ paddingRight: 7
14056
+ }
14057
+ },
14058
+ w: 100,
14059
+ h: 40,
14060
+ sort: 1
14061
+ });
14062
+
14063
+ /*
14064
+ * @Author: binruan@chatlabs.com
14065
+ * @Date: 2024-03-26 16:50:25
14066
+ * @LastEditors: binruan@chatlabs.com
14067
+ * @LastEditTime: 2024-07-08 11:01:24
14068
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\cta\AniLinkPopup\settingRender.tsx
14069
+ *
14070
+ */
14071
+ var settingRender = [
14072
+ {
14073
+ title: '主题样式',
14074
+ child: [
14075
+ {
14076
+ type: 'Group',
14077
+ label: '尺寸',
14078
+ child: [
14079
+ {
14080
+ type: 'Number',
14081
+ name: ['style', 'width'],
14082
+ addonAfter: 'W'
14083
+ },
14084
+ {
14085
+ type: 'Number',
14086
+ name: ['style', 'height'],
14087
+ addonAfter: 'H'
14088
+ }
14089
+ ]
14090
+ },
14091
+ {
14092
+ type: 'Group',
14093
+ label: '圆角',
14094
+ child: [
14095
+ {
14096
+ type: 'Slider',
14097
+ name: ['style', 'borderRadius'],
14098
+ max: 100
14099
+ },
14100
+ {
14101
+ type: 'Number',
14102
+ name: ['style', 'borderRadius'],
14103
+ addonAfter: 'px',
14104
+ max: 100
14105
+ }
14106
+ ]
14107
+ },
14108
+ {
14109
+ type: 'Color',
14110
+ label: '背景色',
14111
+ name: ['style', 'backgroundColor']
14112
+ },
14113
+ {
14114
+ label: '外边距',
14115
+ type: 'Number',
14116
+ name: ['style', 'margin'],
14117
+ addonAfter: 'px'
14118
+ },
14119
+ {
14120
+ label: '内边距',
14121
+ type: 'Number',
14122
+ name: ['style', 'padding'],
14123
+ addonAfter: 'px'
14124
+ }
14125
+ ]
14126
+ },
14127
+ {
14128
+ title: '商品图片',
14129
+ child: [
14130
+ {
14131
+ type: 'Group',
14132
+ label: '尺寸',
14133
+ child: [
14134
+ {
14135
+ type: 'Number',
14136
+ name: ['props', 'ctaTempStyles', 'img', 'width'],
14137
+ addonAfter: 'W'
14138
+ },
14139
+ {
14140
+ type: 'Number',
14141
+ name: ['props', 'ctaTempStyles', 'img', 'height'],
14142
+ addonAfter: 'H'
14143
+ }
14144
+ ]
14145
+ },
14146
+ {
14147
+ type: 'Group',
14148
+ label: '圆角',
14149
+ child: [
14150
+ {
14151
+ type: 'Slider',
14152
+ name: ['props', 'ctaTempStyles', 'img', 'borderRadius'],
14153
+ max: 100
14154
+ },
14155
+ {
14156
+ type: 'Number',
14157
+ name: ['props', 'ctaTempStyles', 'img', 'borderRadius'],
14158
+ addonAfter: 'px',
14159
+ max: 100
14160
+ }
14161
+ ]
14162
+ },
14163
+ {
14164
+ type: 'Number',
14165
+ label: '与下边边距',
14166
+ addonAfter: 'px',
14167
+ name: ['props', 'ctaTempStyles', 'img', 'marginBottom']
14168
+ },
14169
+ {
14170
+ label: '居中垂直偏移',
14171
+ type: 'Number',
14172
+ name: ['props', 'translateY'],
14173
+ min: -1000,
14174
+ addonAfter: '%',
14175
+ initialValue: 0
14176
+ }
14177
+ ]
14178
+ },
14179
+ {
14180
+ title: '商品标题文本',
14181
+ type: 'commodityTitle',
14182
+ child: [
14183
+ {
14184
+ type: 'Group',
14185
+ label: '字体',
14186
+ child: [
14187
+ {
14188
+ type: 'Select',
14189
+ name: ['props', 'ctaTempStyles', 'title', 'fontFamily-cn'],
14190
+ bottomText: '中文字体'
14191
+ },
14192
+ {
14193
+ type: 'Select',
14194
+ name: ['props', 'ctaTempStyles', 'title', 'fontFamily-en'],
14195
+ bottomText: '英文/其他字体'
14196
+ }
14197
+ ]
14198
+ },
14199
+ {
14200
+ type: 'Group',
14201
+ label: '',
14202
+ child: [
14203
+ {
14204
+ type: 'Color',
14205
+ name: ['props', 'ctaTempStyles', 'title', 'color']
14206
+ },
14207
+ {
14208
+ type: 'Number',
14209
+ addonAfter: 'px',
14210
+ name: ['props', 'ctaTempStyles', 'title', 'fontSize']
14211
+ }
14212
+ ]
14213
+ },
14214
+ {
14215
+ label: '样式',
14216
+ type: 'TextStyle',
14217
+ name: ['props', 'ctaTempStyles', 'title']
13042
14218
  },
13043
- buttonBgStyle: {
13044
- backgroundColor: '#fff',
13045
- height: 52,
13046
- paddingTop: 20,
13047
- paddingLeft: 20,
13048
- paddingRight: 20,
13049
- paddingBottom: 20
14219
+ {
14220
+ label: '对齐',
14221
+ type: 'TextAlign',
14222
+ name: ['props', 'ctaTempStyles', 'title']
14223
+ },
14224
+ {
14225
+ label: '间距',
14226
+ type: 'TextSpace',
14227
+ name: ['props', 'ctaTempStyles', 'title']
13050
14228
  }
13051
- }
14229
+ ]
13052
14230
  },
13053
- w: 100,
13054
- h: 40,
13055
- sort: 2
13056
- });
13057
-
13058
- /*
13059
- * @Author: binruan@chatlabs.com
13060
- * @Date: 2024-06-13 10:08:32
13061
- * @LastEditors: binruan@chatlabs.com
13062
- * @LastEditTime: 2024-06-13 17:42:50
13063
- * @FilePath: \pb-sxp-ui\src\materials\sxp\Consent\settingRender.tsx
13064
- *
13065
- */
13066
- var settingRender = [
13067
14231
  {
13068
- title: '协议详情',
14232
+ title: 'CTA标题',
13069
14233
  child: [
13070
14234
  {
13071
- type: 'Switch',
13072
- label: '必须同意用户协议',
13073
- name: ['props', 'privacy_necessity'],
13074
- extra: '当新用户进入页面时,会出现用户协议弹窗,用户需要先同意协议后才能访问内容。'
14235
+ type: 'Group',
14236
+ label: '尺寸',
14237
+ child: [
14238
+ {
14239
+ type: 'Number',
14240
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'width'],
14241
+ addonAfter: 'W'
14242
+ },
14243
+ {
14244
+ type: 'Number',
14245
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'height'],
14246
+ addonAfter: 'H'
14247
+ }
14248
+ ]
13075
14249
  },
13076
14250
  {
13077
- type: 'Text',
13078
- label: '弹窗标题',
13079
- name: ['props', 'privacy_title']
14251
+ type: 'Group',
14252
+ label: '圆角',
14253
+ child: [
14254
+ {
14255
+ type: 'Slider',
14256
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'borderRadius'],
14257
+ max: 100
14258
+ },
14259
+ {
14260
+ type: 'Number',
14261
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'borderRadius'],
14262
+ addonAfter: 'px',
14263
+ max: 100
14264
+ }
14265
+ ]
13080
14266
  },
13081
14267
  {
13082
- type: 'TextArea',
13083
- label: '用户协议弹窗内容',
13084
- name: ['props', 'privacy_context']
14268
+ type: 'TextSpace',
14269
+ name: ['props', 'ctaTempStyles', 'title']
14270
+ },
14271
+ {
14272
+ type: 'Color',
14273
+ label: '背景色',
14274
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'backgroundColor']
13085
14275
  },
13086
14276
  {
13087
14277
  type: 'Group',
13088
- label: '隐私政策',
14278
+ label: '字体',
13089
14279
  child: [
13090
14280
  {
13091
- type: 'Text',
13092
- name: ['props', 'privacy_policy_title']
14281
+ type: 'Select',
14282
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'fontFamily-cn'],
14283
+ bottomText: '中文字体'
13093
14284
  },
13094
14285
  {
13095
- type: 'Text',
13096
- name: ['props', 'privacy_policy_url'],
13097
- addonBefore: 'https://'
14286
+ type: 'Select',
14287
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'fontFamily-en'],
14288
+ bottomText: '英文/其他字体'
13098
14289
  }
13099
- ],
13100
- extra: '当用户点击更多信息按钮时,将会跳转至设置的链接查看政策内容'
14290
+ ]
14291
+ },
14292
+ {
14293
+ type: 'Group',
14294
+ label: '',
14295
+ child: [
14296
+ {
14297
+ type: 'Color',
14298
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'color']
14299
+ },
14300
+ {
14301
+ type: 'Number',
14302
+ addonAfter: 'px',
14303
+ name: ['props', 'ctaTempStyles', 'ctaTitle', 'fontSize']
14304
+ }
14305
+ ]
14306
+ },
14307
+ {
14308
+ label: '样式',
14309
+ type: 'TextStyle',
14310
+ name: ['props', 'ctaTempStyles', 'ctaTitle']
14311
+ },
14312
+ {
14313
+ label: '对齐',
14314
+ type: 'TextAlign',
14315
+ name: ['props', 'ctaTempStyles', 'ctaTitle']
13101
14316
  }
13102
14317
  ]
13103
14318
  }
13104
14319
  ];
13105
14320
 
13106
- const Consent$1 = (props) => {
13107
- return React.createElement(Consent$1, Object.assign({}, props));
14321
+ var styles = {"animated-button":"index-module_animated-button__qI1lz","gradientCover":"index-module_gradientCover__nD6d9","tow-line-ellipsis":"index-module_tow-line-ellipsis__GKFXr","modal-icon-wrapper":"index-module_modal-icon-wrapper__tu3BY","modal-icon-wrapper-img":"index-module_modal-icon-wrapper-img__4b7qZ"};
14322
+
14323
+ const closeIcon = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAjhJREFUWEfFlztOw0AQhmeWiJ4CCmpQ5DiRQsIJyAWg5A0lR0AIChDiCJS8ER0cADgBeRSxt4CCDgkaKiq8i+zYeWx2413HEWmiJJv9v535Z2aN8M8vFPT9z3zETD0aAUChUJjwvPFHAJhBhB3Hqd6OAsK2yyucwykAvP38eJX398Z3AJDLlVYR8ToU9Rhj25TWr9KEsKy5dULIGQCMtfZly45TvwsAstm56UwG6wA4FUFwzrdctxZBDcWSy5XWEPG8I84/GcMipdWPtgcsaz5PCHtKG0IuTiqUvjT9U/WYMG2IOPE+AP+LtCB0xKUAAyA2Xbd2o2OG0NQXvTnvhL17D7EPtH9TRCIWwkRcGYGIQgYBABuqPuHXOQBc6pw80lBGwBQiiXhsBHQhkoprA6iM6acjhDQKu5YJZW6XeOI3XJdpvfsdTu52VfXEekD8owQiXGIubpSCbhDbLu8DwKEAd+A41SOdPpE4BS0viFOtvV2iKWqUgn5x/tmS70xR01GuDSCKc86/OCcLgTyyZ0ScDGNhFAktAJV4NFJ9YyaFiAWIE+9uVkkgBgLoig8DMWAa9ro9ynkUdlW5maZDCmB6clmz0k1HH4Cs1Ezbq2p2yEpUuBOKTSZZex00RUWIrltxuuK6EOGDSbGIOPZicpMx6fny650377qNRgBgWeVFQuA+6UjVgREhGIMlSqsPUQqIbZdOOIdZQmCv2axRnU1N1+TzJYsxOEaEV8ep7frPZ7Gd0FTEdP0ft0/kMNdg0eoAAAAASUVORK5CYII=';
14324
+ const AniLinkPopup$1 = (_a) => {
14325
+ var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z;
14326
+ var { style, recData, ctaTempStyles, index, event, bottom_image, translateY, isTel, onClick, isExternalLink = false } = _a, props = __rest(_a, ["style", "recData", "ctaTempStyles", "index", "event", "bottom_image", "translateY", "isTel", "onClick", "isExternalLink"]);
14327
+ const { sxpParameter, globalConfig, ctaEvent, setPopupDetailData } = useSxpDataSource();
14328
+ const { jumpToWeb } = useEventReport();
14329
+ const [visible, setVisible] = useState(true);
14330
+ const cta = ((_d = (_c = (_b = recData === null || recData === void 0 ? void 0 : recData.video) === null || _b === void 0 ? void 0 : _b.bindProducts) === null || _c === void 0 ? void 0 : _c[0]) === null || _d === void 0 ? void 0 : _d.bindCta) || ((_f = (_e = recData === null || recData === void 0 ? void 0 : recData.video) === null || _e === void 0 ? void 0 : _e.bindProduct) === null || _f === void 0 ? void 0 : _f.bindCta) || ((_g = recData === null || recData === void 0 ? void 0 : recData.video) === null || _g === void 0 ? void 0 : _g.bindCta);
14331
+ const product = ((_j = (_h = recData === null || recData === void 0 ? void 0 : recData.video) === null || _h === void 0 ? void 0 : _h.bindProducts) === null || _j === void 0 ? void 0 : _j[0]) || ((_k = recData === null || recData === void 0 ? void 0 : recData.video) === null || _k === void 0 ? void 0 : _k.bindProduct);
14332
+ const handleTo = () => {
14333
+ var _a, _b, _c;
14334
+ const item = ((_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);
14335
+ ctaEvent === null || ctaEvent === void 0 ? void 0 : ctaEvent({
14336
+ eventSubject: 'clickCta',
14337
+ eventDescription: 'User clicked the CTA'
14338
+ }, recData, item, index);
14339
+ setPopupDetailData === null || setPopupDetailData === void 0 ? void 0 : setPopupDetailData(Object.assign(Object.assign({}, recData), { index }));
14340
+ if (isExternalLink) {
14341
+ jumpToWeb(recData, product, cta, index);
14342
+ }
14343
+ onClick === null || onClick === void 0 ? void 0 : onClick();
14344
+ };
14345
+ const title = (cta === null || cta === void 0 ? void 0 : cta.title) || '查看详情 >';
14346
+ const aniStyle = useMemo(() => {
14347
+ var _a, _b;
14348
+ const ani = event === null || event === void 0 ? void 0 : event.animation;
14349
+ if (ani) {
14350
+ const { delay, duration, backgroundColor } = ani;
14351
+ return {
14352
+ ':after': {
14353
+ animationDelay: `${(_a = delay / 1000) !== null && _a !== void 0 ? _a : 0}s`,
14354
+ animationDuration: `${(_b = duration / 1000) !== null && _b !== void 0 ? _b : 0}s`,
14355
+ backgroundColor: `${backgroundColor !== null && backgroundColor !== void 0 ? backgroundColor : 'transparent'}`
14356
+ }
14357
+ };
14358
+ }
14359
+ }, [event === null || event === void 0 ? void 0 : event.animation]);
14360
+ const src = (_q = (_p = (_o = (_l = product === null || product === void 0 ? void 0 : product.cover) !== null && _l !== void 0 ? _l : (_m = product === null || product === void 0 ? void 0 : product.homePage) === null || _m === void 0 ? void 0 : _m[0]) !== null && _o !== void 0 ? _o : cta === null || cta === void 0 ? void 0 : cta.icon) !== null && _p !== void 0 ? _p : sxpParameter === null || sxpParameter === void 0 ? void 0 : sxpParameter.bottom_image) !== null && _q !== void 0 ? _q : bottom_image;
14361
+ const onClose = (event) => {
14362
+ event.stopPropagation();
14363
+ setVisible(false);
14364
+ };
14365
+ return (React.createElement(React.Fragment, null, isTel ? (React.createElement("div", { style: {
14366
+ height: '40px',
14367
+ lineHeight: '40px',
14368
+ paddingLeft: '6px'
14369
+ } }, "Cta Title")) : (React.createElement("div", Object.assign({ style: Object.assign(Object.assign({}, style), { position: 'absolute', right: 0, bottom: 0, zIndex: 1000, display: visible ? 'block' : 'none' }) }, props, { className: `${styles['animated-button']} ${css(aniStyle)}`, onClick: handleTo }),
14370
+ React.createElement("div", { onClick: onClose, className: styles['modal-icon-wrapper'], style: { padding: (_r = style === null || style === void 0 ? void 0 : style['padding']) !== null && _r !== void 0 ? _r : 0 } },
14371
+ React.createElement("img", { src: (_s = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.popupCloseIcon) !== null && _s !== void 0 ? _s : closeIcon, alt: 'close', className: styles['modal-icon-wrapper-img'] })),
14372
+ React.createElement(Img$1, { src: src, rec: recData, item: (_x = (_v = (_u = (_t = recData === null || recData === void 0 ? void 0 : recData.video) === null || _t === void 0 ? void 0 : _t.bindProducts) === null || _u === void 0 ? void 0 : _u[0]) !== null && _v !== void 0 ? _v : (_w = recData === null || recData === void 0 ? void 0 : recData.video) === null || _w === void 0 ? void 0 : _w.bindProduct) !== null && _x !== void 0 ? _x : recData === null || recData === void 0 ? void 0 : recData.video, index: index, translateY: translateY, imgStyle: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.img }),
14373
+ React.createElement("div", { hidden: !!recData && !(product === null || product === void 0 ? void 0 : product.title), className: styles['tow-line-ellipsis'], style: ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title, dangerouslySetInnerHTML: {
14374
+ __html: setFontForText((_y = product === null || product === void 0 ? void 0 : product.title) !== null && _y !== void 0 ? _y : 'Product Name', ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.title)
14375
+ } }),
14376
+ React.createElement("div", { className: 'one-line-ellipsis', style: Object.assign(Object.assign({}, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle), { lineHeight: ((_z = ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle) === null || _z === void 0 ? void 0 : _z.height) + 'px' }), dangerouslySetInnerHTML: {
14377
+ __html: setFontForText(title, ctaTempStyles === null || ctaTempStyles === void 0 ? void 0 : ctaTempStyles.ctaTitle)
14378
+ } })))));
13108
14379
  };
13109
- var ConsentComponent = memo(Consent$1);
14380
+ var AniLinkPopupComponent = memo(AniLinkPopup$1);
14381
+
14382
+ /*
14383
+ * @Author: binruan@chatlabs.com
14384
+ * @Date: 2024-07-04 15:28:39
14385
+ * @LastEditors: binruan@chatlabs.com
14386
+ * @LastEditTime: 2024-07-05 17:46:42
14387
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\cta\AniLinkPopup\interactionRender.tsx
14388
+ *
14389
+ */
14390
+ var interactionRender = [
14391
+ {
14392
+ title: '点击事件',
14393
+ child: [
14394
+ {
14395
+ type: 'link',
14396
+ name: 'onClick'
14397
+ }
14398
+ ]
14399
+ },
14400
+ {
14401
+ title: '动画效果',
14402
+ child: [
14403
+ {
14404
+ type: 'Color',
14405
+ name: ['animation', 'backgroundColor'],
14406
+ label: '动画颜色'
14407
+ },
14408
+ {
14409
+ type: 'Select',
14410
+ name: ['animation', 'name'],
14411
+ label: '动画',
14412
+ options: [
14413
+ {
14414
+ label: '由左向右/中间扩散',
14415
+ value: 1
14416
+ }
14417
+ ],
14418
+ initialValue: 1,
14419
+ fieldProps: {
14420
+ style: {
14421
+ width: '100%'
14422
+ }
14423
+ }
14424
+ },
14425
+ {
14426
+ type: 'Number',
14427
+ label: '动画启动时间',
14428
+ name: ['animation', 'delay'],
14429
+ addonAfter: 'ms'
14430
+ },
14431
+ {
14432
+ type: 'Number',
14433
+ label: '动画持续时间',
14434
+ name: ['animation', 'duration'],
14435
+ addonAfter: 'ms'
14436
+ }
14437
+ ]
14438
+ }
14439
+ ];
13110
14440
 
13111
14441
  /*
13112
14442
  * @Author: binruan@chatlabs.com
13113
14443
  * @Date: 2023-07-28 18:29:57
13114
14444
  * @LastEditors: binruan@chatlabs.com
13115
- * @LastEditTime: 2024-06-13 17:32:17
13116
- * @FilePath: \pb-sxp-ui\src\materials\sxp\Consent\material.tsx
14445
+ * @LastEditTime: 2024-07-08 14:36:05
14446
+ * @FilePath: \pb-sxp-ui\src\materials\sxp\cta\AniLinkPopup\material.tsx
13117
14447
  *
13118
14448
  */
13119
- const Consent = createMaterial(ConsentComponent, {
13120
- displayName: 'Consent',
14449
+ const AniLinkPopup = createMaterial(AniLinkPopupComponent, {
14450
+ displayName: '竖版弹窗CTA',
13121
14451
  icon: '',
13122
- category: 'base',
13123
- type: 'Consent',
14452
+ category: 'cta',
14453
+ type: 'AniLinkPopup',
13124
14454
  related: {
13125
- settingRender
14455
+ settingRender: settingRender,
14456
+ bindableProps: [],
14457
+ interactionRender
13126
14458
  },
13127
14459
  defaulSetting: {
13128
- props: {},
13129
- style: {}
14460
+ props: {
14461
+ ctaTempStyles: {
14462
+ img: {
14463
+ borderRadius: 3,
14464
+ width: 76,
14465
+ height: 76,
14466
+ marginBottom: 10
14467
+ },
14468
+ title: {
14469
+ fontSize: 12,
14470
+ color: '#000',
14471
+ textAlign: 'left'
14472
+ },
14473
+ ctaTitle: {
14474
+ fontSize: 10,
14475
+ color: '#fff',
14476
+ textAlign: 'center',
14477
+ width: 76,
14478
+ height: 20,
14479
+ backgroundColor: 'rgba(0,0,0,1)'
14480
+ }
14481
+ }
14482
+ },
14483
+ style: {
14484
+ width: 90,
14485
+ height: 160,
14486
+ borderRadius: 3,
14487
+ backgroundColor: 'rgba(255,255,255,1)',
14488
+ padding: 7,
14489
+ margin: 10
14490
+ }
13130
14491
  },
13131
14492
  w: 100,
13132
14493
  h: 40,
13133
- sort: 1
14494
+ sort: 2
13134
14495
  });
13135
14496
 
13136
14497
  /*
@@ -13144,6 +14505,8 @@ const Consent = createMaterial(ConsentComponent, {
13144
14505
 
13145
14506
  var _materials_ = /*#__PURE__*/Object.freeze({
13146
14507
  __proto__: null,
14508
+ AniLink: AniLink,
14509
+ AniLinkPopup: AniLinkPopup,
13147
14510
  Appoint: Appoint,
13148
14511
  AppointForm: AppointForm,
13149
14512
  Commodity: Commodity,
@@ -13151,6 +14514,7 @@ var _materials_ = /*#__PURE__*/Object.freeze({
13151
14514
  CommodityDetailDiroNew: CommodityDetailDiroNew,
13152
14515
  CommodityDiro: CommodityDiro,
13153
14516
  CommodityDiroNew: CommodityDiroNew,
14517
+ CommodityList: CommodityList,
13154
14518
  Consent: Consent,
13155
14519
  HashTag: HashTag,
13156
14520
  Link: Link,
@@ -13455,23 +14819,20 @@ const VideoWidget$2 = ({ rec, index, height, data, muted, activeIndex, videoPost
13455
14819
  (_j = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _j === void 0 ? void 0 : _j.addEventListener('canplay', handlePlay);
13456
14820
  (_k = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _k === void 0 ? void 0 : _k.addEventListener('waiting', handleWaiting);
13457
14821
  return () => {
13458
- var _a, _b, _c, _d, _e, _f, _g, _h, _j;
13459
- const isPause = (_a = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _a === void 0 ? void 0 : _a.paused;
13460
- if (!isPause)
13461
- handlePause();
14822
+ var _a, _b, _c, _d, _e, _f, _g, _h;
13462
14823
  if (hls)
13463
14824
  hls === null || hls === void 0 ? void 0 : hls.destroy();
13464
14825
  setIsLoadFinish(false);
13465
- (_b = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _b === void 0 ? void 0 : _b.removeEventListener('loadedmetadata', handleLoadedmetadata);
13466
- (_c = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _c === void 0 ? void 0 : _c.removeEventListener('loadeddata', handLoadeddata);
13467
- (_d = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _d === void 0 ? void 0 : _d.removeEventListener('play', handleStartPlay);
13468
- (_e = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _e === void 0 ? void 0 : _e.removeEventListener('playing', handlePlaying);
13469
- (_f = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _f === void 0 ? void 0 : _f.removeEventListener('pause', handlePause);
13470
- (_g = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _g === void 0 ? void 0 : _g.removeEventListener('ended', handlePlay);
13471
- (_h = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _h === void 0 ? void 0 : _h.removeEventListener('canplay', handlePlay);
13472
- (_j = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _j === void 0 ? void 0 : _j.removeEventListener('waiting', handleWaiting);
14826
+ (_a = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _a === void 0 ? void 0 : _a.removeEventListener('loadedmetadata', handleLoadedmetadata);
14827
+ (_b = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _b === void 0 ? void 0 : _b.removeEventListener('loadeddata', handLoadeddata);
14828
+ (_c = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _c === void 0 ? void 0 : _c.removeEventListener('play', handleStartPlay);
14829
+ (_d = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _d === void 0 ? void 0 : _d.removeEventListener('playing', handlePlaying);
14830
+ (_e = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _e === void 0 ? void 0 : _e.removeEventListener('pause', handlePause);
14831
+ (_f = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _f === void 0 ? void 0 : _f.removeEventListener('ended', handlePlay);
14832
+ (_g = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _g === void 0 ? void 0 : _g.removeEventListener('canplay', handlePlay);
14833
+ (_h = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _h === void 0 ? void 0 : _h.removeEventListener('waiting', handleWaiting);
13473
14834
  };
13474
- }, [isActive, videoId, rec, handlePause]);
14835
+ }, [isActive, videoId, rec]);
13475
14836
  useEffect(() => {
13476
14837
  var _a, _b;
13477
14838
  if (!(videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) || !isLoadFinish)
@@ -13617,23 +14978,23 @@ var ToggleButton$1 = memo(ToggleButton);
13617
14978
  * @Author: binruan@chatlabs.com
13618
14979
  * @Date: 2024-01-15 19:03:09
13619
14980
  * @LastEditors: binruan@chatlabs.com
13620
- * @LastEditTime: 2024-07-11 18:19:29
14981
+ * @LastEditTime: 2024-03-13 10:53:56
13621
14982
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\FingerSwipeTip\index.tsx
13622
14983
  *
13623
14984
  */
13624
- const FingerSwipeTip = ({ imageUrl, style, duration = 2000 }) => {
14985
+ const FingerSwipeTip = ({ imageUrl, style }) => {
13625
14986
  const [show, setShow] = useState(true);
13626
14987
  useEditor();
13627
14988
  useEffect(() => {
13628
14989
  setTimeout(() => {
13629
14990
  setShow(false);
13630
- }, duration);
14991
+ }, 2000);
13631
14992
  }, []);
13632
14993
  const FINGER_SWIPE_ICON = useIconLink('/pb_static/finger-swipe-tip.29dc3a48a3c746c906ea..png');
13633
14994
  const animationCls = useMemo(() => {
13634
14995
  return show ? 'pb-fadeIn' : 'pb-fadeOut';
13635
14996
  }, [show]);
13636
- return (React.createElement("div", { hidden: !show, className: `pb-finger-wrap ${animationCls}`, style: Object.assign(Object.assign({}, style), { animationDuration: `${duration / 1000}s` }) },
14997
+ return (React.createElement("div", { hidden: !show, className: `pb-finger-wrap ${animationCls}`, style: style },
13637
14998
  React.createElement("img", { src: imageUrl || FINGER_SWIPE_ICON, alt: 'finger swiper' })));
13638
14999
  };
13639
15000
 
@@ -13737,12 +15098,11 @@ var PictureGroup$3 = memo(PictureGroup$2);
13737
15098
  * @Author: binruan@chatlabs.com
13738
15099
  * @Date: 2024-01-15 19:03:09
13739
15100
  * @LastEditors: binruan@chatlabs.com
13740
- * @LastEditTime: 2024-07-09 18:47:05
15101
+ * @LastEditTime: 2024-06-26 18:52:46
13741
15102
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\Hashtag\index.tsx
13742
15103
  *
13743
15104
  */
13744
15105
  const Hashtag = ({ tags, itemId, itemType, index, rec, hashTagStyle }) => {
13745
- var _a;
13746
15106
  const [isShowMore, setIsShowMore] = useState(false);
13747
15107
  const { setWaterFallData, setOpenHashtag, setCacheActiveIndex, waterFallData, setIsFromHashtag } = useSxpDataSource();
13748
15108
  const handleClickTag = (data) => {
@@ -13774,8 +15134,7 @@ const Hashtag = ({ tags, itemId, itemType, index, rec, hashTagStyle }) => {
13774
15134
  }
13775
15135
  return (React.createElement("span", { style: { textDecoration: 'underline', cursor: 'pointer', color: '#fff' }, onClick: () => setIsShowMore(!isShowMore) }, isShowMore ? 'show less' : 'show more'));
13776
15136
  }, [isShowMore, tags]);
13777
- console.log(hashTagStyle, '111');
13778
- return (React.createElement("div", { className: 'clc-sxp-bottom-hashtag', style: { marginTop: `${(_a = hashTagStyle === null || hashTagStyle === void 0 ? void 0 : hashTagStyle.marginTop) !== null && _a !== void 0 ? _a : 16}px` } },
15137
+ return (React.createElement("div", { className: 'clc-sxp-bottom-hashtag' },
13779
15138
  React.createElement(Scroll$1, null, tags === null || tags === void 0 ? void 0 : tags.map((item, index) => (React.createElement(SwiperSlide, { key: index, hidden: !isShowMore ? index >= 6 : false, className: 'clc-sxp-bottom-hashtag-item', style: hashTagStyle, onClick: () => handleClickTag(item) },
13780
15139
  React.createElement("div", { dangerouslySetInnerHTML: { __html: setFontForText(`#${item}`, hashTagStyle) } })))))));
13781
15140
  };
@@ -13845,14 +15204,14 @@ function withBindDataSource(Component) {
13845
15204
  * @Author: binruan@chatlabs.com
13846
15205
  * @Date: 2023-12-26 16:11:34
13847
15206
  * @LastEditors: binruan@chatlabs.com
13848
- * @LastEditTime: 2024-04-18 14:36:53
15207
+ * @LastEditTime: 2024-07-17 18:54:33
13849
15208
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\RenderCard.tsx
13850
15209
  *
13851
15210
  */
13852
- const RenderCard = ({ rec, index, tempMap, resolver }) => {
15211
+ const RenderCard = ({ rec, index, tempMap, resolver, includesCtaType }) => {
13853
15212
  const { schema } = useEditor();
13854
15213
  const renderComp = useMemo(() => {
13855
- 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, _4, _5, _6;
15214
+ 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, _4, _5, _6, _7, _8;
13856
15215
  if (!(rec === null || rec === void 0 ? void 0 : rec.video))
13857
15216
  return null;
13858
15217
  let cta = null;
@@ -13866,20 +15225,27 @@ const RenderCard = ({ rec, index, tempMap, resolver }) => {
13866
15225
  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;
13867
15226
  }
13868
15227
  const value = tempMap === null || tempMap === void 0 ? void 0 : tempMap[cta];
13869
- if ((((_f = value === null || value === void 0 ? void 0 : value.item) === null || _f === void 0 ? void 0 : _f.type) === 'CommodityDiro' && !((_g = rec === null || rec === void 0 ? void 0 : rec.video) === null || _g === void 0 ? void 0 : _g.bindProduct)) ||
13870
- (((_h = value === null || value === void 0 ? void 0 : value.item) === null || _h === void 0 ? void 0 : _h.type) === 'Commodity' && !((_j = rec === null || rec === void 0 ? void 0 : rec.video) === null || _j === void 0 ? void 0 : _j.bindProduct)) ||
13871
- (((_k = value === null || value === void 0 ? void 0 : value.item) === null || _k === void 0 ? void 0 : _k.type) === 'CommodityDiroNew' && !((_l = rec === null || rec === void 0 ? void 0 : rec.video) === null || _l === void 0 ? void 0 : _l.bindProduct)) ||
13872
- (((_m = value === null || value === void 0 ? void 0 : value.item) === null || _m === void 0 ? void 0 : _m.type) === 'MultiCommodity' && !((_p = (_o = rec === null || rec === void 0 ? void 0 : rec.video) === null || _o === void 0 ? void 0 : _o.bindProducts) === null || _p === void 0 ? void 0 : _p.length)) ||
13873
- (((_q = value === null || value === void 0 ? void 0 : value.item) === null || _q === void 0 ? void 0 : _q.type) === 'MultiCommodityDiro' && !((_s = (_r = rec === null || rec === void 0 ? void 0 : rec.video) === null || _r === void 0 ? void 0 : _r.bindProducts) === null || _s === void 0 ? void 0 : _s.length)) ||
13874
- (((_t = value === null || value === void 0 ? void 0 : value.item) === null || _t === void 0 ? void 0 : _t.type) === 'MultiCommodityDiroNew' && !((_v = (_u = rec === null || rec === void 0 ? void 0 : rec.video) === null || _u === void 0 ? void 0 : _u.bindProducts) === null || _v === void 0 ? void 0 : _v.length))) {
15228
+ //如果includesCtaType有值,则只渲染includesCtaType包含的cta类型组件,用于在页面某处只显示某一组件
15229
+ if (includesCtaType && !(includesCtaType === null || includesCtaType === void 0 ? void 0 : includesCtaType.includes((_f = value === null || value === void 0 ? void 0 : value.item) === null || _f === void 0 ? void 0 : _f.type)))
15230
+ return;
15231
+ //默认不渲染category为cta类型的组件,该类型的组件只用于某一处
15232
+ if (!includesCtaType && ((_g = value === null || value === void 0 ? void 0 : value.item) === null || _g === void 0 ? void 0 : _g.category) === 'cta')
15233
+ return;
15234
+ if ((((_h = value === null || value === void 0 ? void 0 : value.item) === null || _h === void 0 ? void 0 : _h.type) === 'CommodityDiro' && !((_j = rec === null || rec === void 0 ? void 0 : rec.video) === null || _j === void 0 ? void 0 : _j.bindProduct)) ||
15235
+ (((_k = value === null || value === void 0 ? void 0 : value.item) === null || _k === void 0 ? void 0 : _k.type) === 'Commodity' && !((_l = rec === null || rec === void 0 ? void 0 : rec.video) === null || _l === void 0 ? void 0 : _l.bindProduct)) ||
15236
+ (((_m = value === null || value === void 0 ? void 0 : value.item) === null || _m === void 0 ? void 0 : _m.type) === 'CommodityDiroNew' && !((_o = rec === null || rec === void 0 ? void 0 : rec.video) === null || _o === void 0 ? void 0 : _o.bindProduct)) ||
15237
+ (((_p = value === null || value === void 0 ? void 0 : value.item) === null || _p === void 0 ? void 0 : _p.type) === 'MultiCommodity' && !((_r = (_q = rec === null || rec === void 0 ? void 0 : rec.video) === null || _q === void 0 ? void 0 : _q.bindProducts) === null || _r === void 0 ? void 0 : _r.length)) ||
15238
+ (((_s = value === null || value === void 0 ? void 0 : value.item) === null || _s === void 0 ? void 0 : _s.type) === 'MultiCommodityDiro' && !((_u = (_t = rec === null || rec === void 0 ? void 0 : rec.video) === null || _t === void 0 ? void 0 : _t.bindProducts) === null || _u === void 0 ? void 0 : _u.length)) ||
15239
+ (((_v = value === null || value === void 0 ? void 0 : value.item) === null || _v === void 0 ? void 0 : _v.type) === 'MultiCommodityDiroNew' && !((_x = (_w = rec === null || rec === void 0 ? void 0 : rec.video) === null || _w === void 0 ? void 0 : _w.bindProducts) === null || _x === void 0 ? void 0 : _x.length))) {
15240
+ //
13875
15241
  return null;
13876
15242
  }
13877
15243
  if (value && resolver) {
13878
- const t = resolver[(_w = value === null || value === void 0 ? void 0 : value.item) === null || _w === void 0 ? void 0 : _w.type];
15244
+ const t = resolver[(_y = value === null || value === void 0 ? void 0 : value.item) === null || _y === void 0 ? void 0 : _y.type];
13879
15245
  const Component = withBindDataSource(t);
13880
- const defaulSetting = (_x = t === null || t === void 0 ? void 0 : t.extend) === null || _x === void 0 ? void 0 : _x.defaulSetting;
13881
- const isExternalLink = ((_0 = (_z = (_y = value === null || value === void 0 ? void 0 : value.item) === null || _y === void 0 ? void 0 : _y.event) === null || _z === void 0 ? void 0 : _z.onClick) === null || _0 === void 0 ? void 0 : _0.linkType) === 'externalLink';
13882
- return (React.createElement(Component, Object.assign({ style: Object.assign(Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.style), (_1 = value === null || value === void 0 ? void 0 : value.item) === null || _1 === void 0 ? void 0 : _1.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), (_2 = value === null || value === void 0 ? void 0 : value.item) === null || _2 === void 0 ? void 0 : _2.textStyle), bindDatas: (_4 = (_3 = value === null || value === void 0 ? void 0 : value.item) === null || _3 === void 0 ? void 0 : _3.bindDatas) !== null && _4 !== void 0 ? _4 : [] }, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.props, (_5 = value === null || value === void 0 ? void 0 : value.item) === null || _5 === void 0 ? void 0 : _5.props, { event: ((_6 = value === null || value === void 0 ? void 0 : value.item) === null || _6 === void 0 ? void 0 : _6.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 })));
15246
+ const defaulSetting = (_z = t === null || t === void 0 ? void 0 : t.extend) === null || _z === void 0 ? void 0 : _z.defaulSetting;
15247
+ const isExternalLink = ((_2 = (_1 = (_0 = value === null || value === void 0 ? void 0 : value.item) === null || _0 === void 0 ? void 0 : _0.event) === null || _1 === void 0 ? void 0 : _1.onClick) === null || _2 === void 0 ? void 0 : _2.linkType) === 'externalLink';
15248
+ return (React.createElement(Component, Object.assign({ style: Object.assign(Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.style), (_3 = value === null || value === void 0 ? void 0 : value.item) === null || _3 === void 0 ? void 0 : _3.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), (_4 = value === null || value === void 0 ? void 0 : value.item) === null || _4 === void 0 ? void 0 : _4.textStyle), bindDatas: (_6 = (_5 = value === null || value === void 0 ? void 0 : value.item) === null || _5 === void 0 ? void 0 : _5.bindDatas) !== null && _6 !== void 0 ? _6 : [] }, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.props, (_7 = value === null || value === void 0 ? void 0 : value.item) === null || _7 === void 0 ? void 0 : _7.props, { event: ((_8 = value === null || value === void 0 ? void 0 : value.item) === null || _8 === void 0 ? void 0 : _8.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 })));
13883
15249
  }
13884
15250
  else {
13885
15251
  return null;
@@ -13972,7 +15338,7 @@ var Tagbar$1 = memo(Tagbar);
13972
15338
  * @Author: binruan@chatlabs.com
13973
15339
  * @Date: 2024-01-15 19:03:09
13974
15340
  * @LastEditors: binruan@chatlabs.com
13975
- * @LastEditTime: 2024-07-09 18:11:21
15341
+ * @LastEditTime: 2024-07-22 15:57:31
13976
15342
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\index.tsx
13977
15343
  *
13978
15344
  */
@@ -13985,7 +15351,7 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
13985
15351
  const viewTime = useRef();
13986
15352
  const [isLoadMore, setIsLoadMore] = useState(false);
13987
15353
  const [isShowMore, setIsShowMore] = useState(false);
13988
- const { loadVideos, bffEventReport, loading, setPopupDetailData, ctaEvent, swiperRef, waterFallData, setOpenHashtag, appDomain, openHashtag, loadingImage, isFromHashtag, popupDetailData, bffFbReport, curTime, h5EnterLink, isShowConsent, selectTag } = useSxpDataSource();
15354
+ const { loadVideos, bffEventReport, loading, setPopupDetailData, ctaEvent, swiperRef, waterFallData, setOpenHashtag, appDomain, openHashtag, loadingImage, isFromHashtag, popupDetailData, bffFbReport, curTime, h5EnterLink, isShowConsent, selectTag, isPreview } = useSxpDataSource();
13989
15355
  const { backMainFeed } = useEventReport();
13990
15356
  const { productView } = useEventReport();
13991
15357
  const isShowFingerTip = useMemo(() => {
@@ -14033,7 +15399,7 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
14033
15399
  useEffect(() => {
14034
15400
  const item = data === null || data === void 0 ? void 0 : data[activeIndex];
14035
15401
  const visibleChange = () => {
14036
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
15402
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
14037
15403
  const repCond = !openHashtag && !isShowConsent;
14038
15404
  if (document.visibilityState === 'hidden') {
14039
15405
  // 当用户导航到新页面、切换标签页、关闭标签页、最小化或关闭浏览器、刷新原页面(即离开原页面时),或者在移动设备上从浏览器切换到不同的应用程序时
@@ -14072,7 +15438,8 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
14072
15438
  position: activeIndex + '',
14073
15439
  fromKName,
14074
15440
  fromKPage: location === null || location === void 0 ? void 0 : location.href,
14075
- ctatId: (_r = (_q = (_p = item === null || item === void 0 ? void 0 : item.video) === null || _p === void 0 ? void 0 : _p.bindCta) === null || _q === void 0 ? void 0 : _q.itemId) !== null && _r !== void 0 ? _r : ''
15441
+ ctatId: (_r = (_q = (_p = item === null || item === void 0 ? void 0 : item.video) === null || _p === void 0 ? void 0 : _p.bindCta) === null || _q === void 0 ? void 0 : _q.itemId) !== null && _r !== void 0 ? _r : '',
15442
+ traceInfo: (_t = (_s = item === null || item === void 0 ? void 0 : item.video) === null || _s === void 0 ? void 0 : _s.traceInfo) !== null && _t !== void 0 ? _t : ''
14076
15443
  }
14077
15444
  });
14078
15445
  }
@@ -14177,17 +15544,19 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
14177
15544
  };
14178
15545
  }, [isShowMore]);
14179
15546
  const renderBottom = useCallback((rec, index) => {
14180
- var _a, _b, _c, _d, _e, _f, _g, _h;
15547
+ var _a, _b, _c, _d, _e, _f, _g;
14181
15548
  if (rec === null || rec === void 0 ? void 0 : rec.video) {
14182
15549
  return (React.createElement(React.Fragment, null,
14183
15550
  ((_a = rec === null || rec === void 0 ? void 0 : rec.video) === null || _a === void 0 ? void 0 : _a.title) && !isShowMore && React.createElement("div", { className: 'clc-sxp-bottom-shadow' }),
14184
- React.createElement("div", { className: 'clc-sxp-bottom', style: { paddingBottom: `${(_b = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.bottomInfoDist) !== null && _b !== void 0 ? _b : 40}px` } },
15551
+ React.createElement("div", { className: 'clc-sxp-bottom' },
14185
15552
  React.createElement(Nudge, { nudge: nudge }),
14186
15553
  (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.isShowCTA) === undefined || (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.isShowCTA) ? (React.createElement("div", { className: 'clc-sxp-bottom-card' },
14187
15554
  React.createElement(RenderCard$1, { rec: rec, index: index, tempMap: tempMap, resolver: resolver }))) : null,
14188
15555
  React.createElement("div", null,
14189
- 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 }),
14190
- 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 })))));
15556
+ 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: (_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' }), onChange: onExpandableChange }),
15557
+ React.createElement(RenderCard$1, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, includesCtaType: ['AniLink'] }),
15558
+ React.createElement(Hashtag$1, { index: activeIndex, 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 }))),
15559
+ React.createElement(RenderCard$1, { rec: rec, index: index, tempMap: tempMap, resolver: resolver, includesCtaType: ['AniLinkPopup'] })));
14191
15560
  }
14192
15561
  return null;
14193
15562
  }, [
@@ -14240,8 +15609,36 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
14240
15609
  });
14241
15610
  }
14242
15611
  };
15612
+ const handleSlideSkip = (item, position) => {
15613
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
15614
+ if (isPreview)
15615
+ return;
15616
+ const t = new Date() - curTime.current;
15617
+ if ((globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.openSlideSkip) && t >= ((_a = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.slideSkipStartTime) !== null && _a !== void 0 ? _a : 0) && getSlideSkipState() && item) {
15618
+ const link = ((_c = (_b = item === null || item === void 0 ? void 0 : item.video) === null || _b === void 0 ? void 0 : _b.bindProduct) === null || _c === void 0 ? void 0 : _c.link) || ((_f = (_e = (_d = item === null || item === void 0 ? void 0 : item.video) === null || _d === void 0 ? void 0 : _d.bindProducts) === null || _e === void 0 ? void 0 : _e[0]) === null || _f === void 0 ? void 0 : _f.link) || ((_g = item === null || item === void 0 ? void 0 : item.product) === null || _g === void 0 ? void 0 : _g.link);
15619
+ const product = (item === null || item === void 0 ? void 0 : item.product) || ((_h = item === null || item === void 0 ? void 0 : item.video) === null || _h === void 0 ? void 0 : _h.bindProduct) || ((_k = (_j = item === null || item === void 0 ? void 0 : item.video) === null || _j === void 0 ? void 0 : _j.bindProducts) === null || _k === void 0 ? void 0 : _k[0]);
15620
+ if (link) {
15621
+ bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
15622
+ eventInfo: {
15623
+ eventSubject: 'swipeToWeb',
15624
+ eventDescription: 'User swiped to web',
15625
+ productId: (_l = product === null || product === void 0 ? void 0 : product.itemId) !== null && _l !== void 0 ? _l : '',
15626
+ productName: (_m = product === null || product === void 0 ? void 0 : product.title) !== null && _m !== void 0 ? _m : '',
15627
+ price: (product === null || product === void 0 ? void 0 : product.price) ? (product === null || product === void 0 ? void 0 : product.price) + '' : '0',
15628
+ productCollection: (_o = product === null || product === void 0 ? void 0 : product.collection) !== null && _o !== void 0 ? _o : '',
15629
+ contentTags: (product === null || product === void 0 ? void 0 : product.tags) ? JSON.stringify(product === null || product === void 0 ? void 0 : product.tags) : '',
15630
+ position: position + '',
15631
+ contentId: (_q = (_p = item === null || item === void 0 ? void 0 : item.video) === null || _p === void 0 ? void 0 : _p.itemId) !== null && _q !== void 0 ? _q : '',
15632
+ traceInfo: (_r = product === null || product === void 0 ? void 0 : product.traceInfo) !== null && _r !== void 0 ? _r : ''
15633
+ }
15634
+ });
15635
+ setSlideSkipState();
15636
+ window.location.href = window.getJointUtmLink(link);
15637
+ }
15638
+ }
15639
+ };
14243
15640
  const handleScrollEvent = (swiper) => {
14244
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
15641
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
14245
15642
  viewTime.current = new Date();
14246
15643
  const item = data[swiper.previousIndex];
14247
15644
  if (!item)
@@ -14253,20 +15650,23 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
14253
15650
  eventDescription: 'User scroll down',
14254
15651
  contentId: (_b = (_a = item === null || item === void 0 ? void 0 : item.video) === null || _a === void 0 ? void 0 : _a.itemId) !== null && _b !== void 0 ? _b : '',
14255
15652
  productId: (_d = (_c = item === null || item === void 0 ? void 0 : item.product) === null || _c === void 0 ? void 0 : _c.itemId) !== null && _d !== void 0 ? _d : '',
14256
- requestId: null
15653
+ requestId: null,
15654
+ traceInfo: (_f = (_e = item === null || item === void 0 ? void 0 : item.video) === null || _e === void 0 ? void 0 : _e.traceInfo) !== null && _f !== void 0 ? _f : ''
14257
15655
  }
14258
15656
  });
14259
15657
  // 如果上一个商品是图片集,需上报 浏览图片集结结束 事件
14260
15658
  handleReportViewImageEnd(item);
15659
+ handleSlideSkip(item, swiper.previousIndex);
14261
15660
  }
14262
15661
  else {
14263
15662
  bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
14264
15663
  eventInfo: {
14265
15664
  eventSubject: 'scrollUp',
14266
15665
  eventDescription: 'User scroll up',
14267
- contentId: (_f = (_e = item === null || item === void 0 ? void 0 : item.video) === null || _e === void 0 ? void 0 : _e.itemId) !== null && _f !== void 0 ? _f : '',
14268
- productId: (_h = (_g = item.product) === null || _g === void 0 ? void 0 : _g.itemId) !== null && _h !== void 0 ? _h : '',
14269
- requestId: null
15666
+ contentId: (_h = (_g = item === null || item === void 0 ? void 0 : item.video) === null || _g === void 0 ? void 0 : _g.itemId) !== null && _h !== void 0 ? _h : '',
15667
+ productId: (_k = (_j = item.product) === null || _j === void 0 ? void 0 : _j.itemId) !== null && _k !== void 0 ? _k : '',
15668
+ requestId: null,
15669
+ traceInfo: (_m = (_l = item === null || item === void 0 ? void 0 : item.video) === null || _l === void 0 ? void 0 : _l.traceInfo) !== null && _m !== void 0 ? _m : ''
14270
15670
  }
14271
15671
  });
14272
15672
  // 如果上一个商品是图片集,需上报 浏览图片集结结束 事件
@@ -14275,7 +15675,7 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
14275
15675
  // 商品浏览事件
14276
15676
  handleReportProductView(item);
14277
15677
  const curItem = data[swiper.activeIndex];
14278
- if (!((_j = curItem === null || curItem === void 0 ? void 0 : curItem.video) === null || _j === void 0 ? void 0 : _j.url) && !((_k = curItem === null || curItem === void 0 ? void 0 : curItem.video) === null || _k === void 0 ? void 0 : _k.imgUrls) && (curItem === null || curItem === void 0 ? void 0 : curItem.product)) {
15678
+ if (!((_o = curItem === null || curItem === void 0 ? void 0 : curItem.video) === null || _o === void 0 ? void 0 : _o.url) && !((_p = curItem === null || curItem === void 0 ? void 0 : curItem.video) === null || _p === void 0 ? void 0 : _p.imgUrls) && (curItem === null || curItem === void 0 ? void 0 : curItem.product)) {
14279
15679
  bffFbReport === null || bffFbReport === void 0 ? void 0 : bffFbReport({
14280
15680
  eventName: 'ProductView'
14281
15681
  });
@@ -14360,7 +15760,7 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
14360
15760
  React.createElement(Tagbar$1, { tagList: tagList, setActiveIndex: setActiveIndex, style: {
14361
15761
  top: minusHeight
14362
15762
  } }),
14363
- isShowFingerTip ? (React.createElement(FingerSwipeTip, { imageUrl: globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.swipeTipIcon, style: { top: `${50 - ((_a = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.swipeTipOffset) !== null && _a !== void 0 ? _a : 0)}%` }, duration: globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.swiperTipAniDur })) : null,
15763
+ isShowFingerTip ? (React.createElement(FingerSwipeTip, { imageUrl: globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.swipeTipIcon, style: { top: `${50 + ((_a = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.swipeTipOffset) !== null && _a !== void 0 ? _a : 0)}%` } })) : null,
14364
15764
  React.createElement(Swiper, { style: {
14365
15765
  marginTop: tagHeight
14366
15766
  }, ref: swiperRef, onSlideChange: () => {
@@ -14385,13 +15785,13 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
14385
15785
  }
14386
15786
  }
14387
15787
  }, direction: 'vertical', height: height },
14388
- ((globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.isShowMute) === undefined || (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.isShowMute) === true) && (React.createElement(ToggleButton$1, { style: {
15788
+ React.createElement(ToggleButton$1, { style: {
14389
15789
  position: 'fixed',
14390
15790
  visibility: ((_c = (_b = data === null || data === void 0 ? void 0 : data[activeIndex]) === null || _b === void 0 ? void 0 : _b.video) === null || _c === void 0 ? void 0 : _c.url) ? 'visible' : 'hidden',
14391
15791
  zIndex: 999,
14392
15792
  [(_d = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.muteIconXPosit) !== null && _d !== void 0 ? _d : 'right']: (_e = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.muteIconX) !== null && _e !== void 0 ? _e : 0,
14393
15793
  [(_f = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.muteIconYPosit) !== null && _f !== void 0 ? _f : 'bottom']: (_g = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.muteIconY) !== null && _g !== void 0 ? _g : 23
14394
- }, defaultValue: isMuted, activeIcon: (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.unMuteIcon) ? globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.unMuteIcon : mutedIcon, unactiveIcon: (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.muteIcon) ? globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.muteIcon : unmutedIcon, onChange: setIsMuted })),
15794
+ }, defaultValue: isMuted, activeIcon: (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.unMuteIcon) ? globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.unMuteIcon : mutedIcon, unactiveIcon: (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.muteIcon) ? globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.muteIcon : unmutedIcon, onChange: setIsMuted }),
14395
15795
  renderView),
14396
15796
  React.createElement(WaterFall$1, Object.assign({}, (_k = (_j = (_h = globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.hashTag) === null || _h === void 0 ? void 0 : _h[0]) === null || _j === void 0 ? void 0 : _j.item) === null || _k === void 0 ? void 0 : _k.props))));
14397
15797
  };
@@ -14760,7 +16160,7 @@ var index$1 = memo(DiyPortalPreview);
14760
16160
  * @Author: binruan@chatlabs.com
14761
16161
  * @Date: 2023-10-31 10:56:01
14762
16162
  * @LastEditors: binruan@chatlabs.com
14763
- * @LastEditTime: 2024-05-27 18:19:31
16163
+ * @LastEditTime: 2024-07-19 18:06:14
14764
16164
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\Popup\index.tsx
14765
16165
  *
14766
16166
  */
@@ -14813,7 +16213,7 @@ const Popup = () => {
14813
16213
  const isExternalLink = ((_d = (_c = (_b = value === null || value === void 0 ? void 0 : value.item) === null || _b === void 0 ? void 0 : _b.event) === null || _c === void 0 ? void 0 : _c.onClick) === null || _d === void 0 ? void 0 : _d.linkType) === 'externalLink';
14814
16214
  const isPopup = ((_g = (_f = (_e = value === null || value === void 0 ? void 0 : value.item) === null || _e === void 0 ? void 0 : _e.event) === null || _f === void 0 ? void 0 : _f.onClick) === null || _g === void 0 ? void 0 : _g.linkType) === 'popup';
14815
16215
  const defaulSetting = (_h = t === null || t === void 0 ? void 0 : t.extend) === null || _h === void 0 ? void 0 : _h.defaulSetting;
14816
- return (React.createElement(Component, Object.assign({ key: index, style: Object.assign(Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.style), (_j = value === null || value === void 0 ? void 0 : value.item) === null || _j === void 0 ? void 0 : _j.style), { width: (_k = window.innerWidth) !== null && _k !== void 0 ? _k : '100vw', height: '80vh', overflow: 'auto' }), textStyle: Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.textStyle), (_l = value === null || value === void 0 ? void 0 : value.item) === null || _l === void 0 ? void 0 : _l.textStyle), bindDatas: (_o = (_m = value === null || value === void 0 ? void 0 : value.item) === null || _m === void 0 ? void 0 : _m.bindDatas) !== null && _o !== void 0 ? _o : [] }, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.props, (_p = value === null || value === void 0 ? void 0 : value.item) === null || _p === void 0 ? void 0 : _p.props, { event: ((_q = value === null || value === void 0 ? void 0 : value.item) === null || _q === void 0 ? void 0 : _q.event) || {}, schema: schema, id: value === null || value === void 0 ? void 0 : value.id, isExternalLink: isExternalLink, isPopup: isPopup, onClose: handleClose })));
16216
+ return (React.createElement(Component, Object.assign({ key: index, style: Object.assign(Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.style), (_j = value === null || value === void 0 ? void 0 : value.item) === null || _j === void 0 ? void 0 : _j.style), { width: (_k = window.innerWidth) !== null && _k !== void 0 ? _k : '100vw' }), textStyle: Object.assign(Object.assign({}, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.textStyle), (_l = value === null || value === void 0 ? void 0 : value.item) === null || _l === void 0 ? void 0 : _l.textStyle), bindDatas: (_o = (_m = value === null || value === void 0 ? void 0 : value.item) === null || _m === void 0 ? void 0 : _m.bindDatas) !== null && _o !== void 0 ? _o : [] }, defaulSetting === null || defaulSetting === void 0 ? void 0 : defaulSetting.props, (_p = value === null || value === void 0 ? void 0 : value.item) === null || _p === void 0 ? void 0 : _p.props, { event: ((_q = value === null || value === void 0 ? void 0 : value.item) === null || _q === void 0 ? void 0 : _q.event) || {}, schema: schema, id: value === null || value === void 0 ? void 0 : value.id, isExternalLink: isExternalLink, isPopup: isPopup, onClose: handleClose })));
14817
16217
  }
14818
16218
  else {
14819
16219
  return React.createElement(React.Fragment, null);