pb-sxp-ui 1.10.7 → 1.10.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -871,7 +871,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
871
871
  };
872
872
  }
873
873
  const sessionID = storeAndLoadFeSessionId();
874
- const ef = Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({ sessionID, rtc: curReqInfo.rtc, requestId: curReqInfo.requestId }, { playbookType }), eventInfo), (getDevice$1() && { sxpDevice: getDevice$1() })), (getSystem() && { sxpSystem: getSystem() })), (getBrowserInfo() && { sxpBrowser: getBrowserInfo() })), (layoutVariantId && reportLayId && { layoutVariantId })), ((eventInfo === null || eventInfo === void 0 ? void 0 : eventInfo.position) && channel && { position: Number(eventInfo === null || eventInfo === void 0 ? void 0 : eventInfo.position) + 1 + '' }));
874
+ const ef = Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({ sessionID, rtc: curReqInfo.rtc, requestId: curReqInfo.requestId }, { playbookType }), (layoutVariantId && reportLayId && { layoutVariantId })), eventInfo), (getDevice$1() && { sxpDevice: getDevice$1() })), (getSystem() && { sxpSystem: getSystem() })), (getBrowserInfo() && { sxpBrowser: getBrowserInfo() })), ((eventInfo === null || eventInfo === void 0 ? void 0 : eventInfo.position) && channel && { position: Number(eventInfo === null || eventInfo === void 0 ? void 0 : eventInfo.position) + 1 + '' }));
875
875
  const realUserInfo = Object.entries(userInfo).map(([k, v]) => ({ name: k, value: v }));
876
876
  const realEventInfo = Object.entries(ef)
877
877
  .map(([k, v]) => v && { name: k, value: v })
@@ -1095,23 +1095,10 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
1095
1095
  const item = list === null || list === void 0 ? void 0 : list[0];
1096
1096
  const traceInfo = ((_k = item === null || item === void 0 ? void 0 : item.video) === null || _k === void 0 ? void 0 : _k.traceInfo) || ((_l = item === null || item === void 0 ? void 0 : item.product) === null || _l === void 0 ? void 0 : _l.traceInfo) || '';
1097
1097
  bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
1098
- eventInfo: {
1099
- eventSubject: 'multiPostClick',
1100
- eventDescription: 'multiPostClick',
1101
- traceInfo,
1102
- branchfeed: channel
1103
- }
1098
+ eventInfo: Object.assign({ eventSubject: 'multiPostClick', eventDescription: 'multiPostClick', traceInfo, branchfeed: channel }, (layId && { layoutVariantId: layId }))
1104
1099
  });
1105
1100
  bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
1106
- eventInfo: {
1107
- eventSubject: 'endMultiPost',
1108
- eventDescription: 'endMultiPost',
1109
- contentFormat: 'image',
1110
- position: '0',
1111
- traceInfo,
1112
- nextStep: 'multipostClick',
1113
- timeOnSite: Math.floor((new Date() - (multiPostTimeRef === null || multiPostTimeRef === void 0 ? void 0 : multiPostTimeRef.current)) / 1000) + ''
1114
- }
1101
+ eventInfo: Object.assign({ eventSubject: 'endMultiPost', eventDescription: 'endMultiPost', contentFormat: 'image', position: '0', traceInfo, nextStep: 'multipostClick', timeOnSite: Math.floor((new Date() - (multiPostTimeRef === null || multiPostTimeRef === void 0 ? void 0 : multiPostTimeRef.current)) / 1000) + '' }, (layId && { layoutVariantId: layId }))
1115
1102
  });
1116
1103
  }
1117
1104
  }
@@ -12411,7 +12398,7 @@ const EventProvider = (_a) => {
12411
12398
  eventSubject: 'clickCta',
12412
12399
  eventDescription: 'User clicked the CTA'
12413
12400
  }, rec, item, index);
12414
- setPopupDetailData === null || setPopupDetailData === void 0 ? void 0 : setPopupDetailData(multItem && multiCheckIndex
12401
+ setPopupDetailData === null || setPopupDetailData === void 0 ? void 0 : setPopupDetailData(multItem && multiCheckIndex !== undefined && multiCheckIndex >= 0
12415
12402
  ? Object.assign(Object.assign({}, rec), { video: Object.assign(Object.assign({}, rec === null || rec === void 0 ? void 0 : rec.video), { bindProduct: multItem }), index, multiCheckIndex }) : Object.assign(Object.assign({}, rec), { index }));
12416
12403
  setElement(ref === null || ref === void 0 ? void 0 : ref.current);
12417
12404
  if (isExternalLink) {
@@ -14935,7 +14922,7 @@ const WaterfallFlowItem$1 = (props) => {
14935
14922
  const imgLoad = React.useCallback((img) => {
14936
14923
  setTimeout(() => {
14937
14924
  var _a;
14938
- const height = (_a = pictRef === null || pictRef === void 0 ? void 0 : pictRef.current) === null || _a === void 0 ? void 0 : _a.offsetHeight;
14925
+ const height = (img === null || img === void 0 ? void 0 : img.clientHeight) || ((_a = pictRef === null || pictRef === void 0 ? void 0 : pictRef.current) === null || _a === void 0 ? void 0 : _a.offsetHeight);
14939
14926
  // 加56是因为下方文字部分高度为56,可以自己设置
14940
14927
  sizeChange(height + 56 + space, index);
14941
14928
  }, 0);
@@ -15425,7 +15412,7 @@ function WaterfallList(_a) {
15425
15412
  * @Author: binruan@chatlabs.com
15426
15413
  * @Date: 2024-01-10 10:58:24
15427
15414
  * @LastEditors: binruan@chatlabs.com
15428
- * @LastEditTime: 2024-10-23 16:58:01
15415
+ * @LastEditTime: 2024-12-09 11:18:32
15429
15416
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\WaterFall\index.tsx
15430
15417
  *
15431
15418
  */
@@ -15433,7 +15420,6 @@ const WaterFall = (props) => {
15433
15420
  var _a;
15434
15421
  const { waterFallData, setOpenHashtag, openHashtag, swiperRef, setWaterFallData, cacheRtcList, setRtcList, cacheActiveIndex, rtcList, setCacheRtcList, setIsFromHashtag, isFromHashtag, bffEventReport, themeTag, selectTag, bffFbReport } = useSxpDataSource();
15435
15422
  const { backMainFeed } = useEventReport();
15436
- React.useRef(null);
15437
15423
  const modalEleRef = React.useRef(null);
15438
15424
  const [viewTime, setViewTime] = React.useState();
15439
15425
  React.useEffect(() => {
@@ -15450,20 +15436,12 @@ const WaterFall = (props) => {
15450
15436
  }, []);
15451
15437
  const handleClose = () => {
15452
15438
  var _a, _b;
15453
- // const isEq = isEqual(rtcList, cacheRtcList);
15454
- // if (!isEq && cacheRtcList && cacheRtcList?.length) {
15455
- // setRtcList?.(cacheRtcList);
15456
- // }
15457
15439
  backMainFeed('branch', selectTag, undefined, waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.hashTag);
15458
15440
  reportTagsView();
15459
15441
  setWaterFallData === null || setWaterFallData === void 0 ? void 0 : setWaterFallData(undefined);
15460
15442
  setIsFromHashtag === null || setIsFromHashtag === void 0 ? void 0 : setIsFromHashtag(false);
15461
- // setTimeout(() => {
15462
- // if (!isEq) {
15463
15443
  (_b = (_a = swiperRef === null || swiperRef === void 0 ? void 0 : swiperRef.current) === null || _a === void 0 ? void 0 : _a.swiper) === null || _b === void 0 ? void 0 : _b.slideTo(cacheActiveIndex, 0, false);
15464
- // }
15465
15444
  setOpenHashtag === null || setOpenHashtag === void 0 ? void 0 : setOpenHashtag(false);
15466
- // }, 0);
15467
15445
  };
15468
15446
  const [recData, setRecData] = React.useState();
15469
15447
  React.useEffect(() => {
@@ -15528,7 +15506,7 @@ const WaterFall = (props) => {
15528
15506
  display: openHashtag ? 'block' : 'none'
15529
15507
  } },
15530
15508
  React.createElement(Navbar$1, { icon: img$4, styles: { top: '32px' }, textStyle: (_a = props === null || props === void 0 ? void 0 : props.textStyles) === null || _a === void 0 ? void 0 : _a.hashTagTitle, onClose: handleClose }),
15531
- (props === null || props === void 0 ? void 0 : props.openFixedSize) === true || (props === null || props === void 0 ? void 0 : props.openFixedSize) === undefined ? (React.createElement(WaterfallList, Object.assign({ reportTagsView: reportTagsView }, props))) : (React.createElement(WaterfallList$1, Object.assign({ reportTagsView: reportTagsView }, props)))), modalEleRef.current);
15509
+ (props === null || props === void 0 ? void 0 : props.openFixedSize) === true || (props === null || props === void 0 ? void 0 : props.openFixedSize) === undefined ? (React.createElement(WaterfallList, Object.assign({ key: waterFallData, reportTagsView: reportTagsView }, props))) : (React.createElement(WaterfallList$1, Object.assign({ key: waterFallData, reportTagsView: reportTagsView }, props)))), modalEleRef.current);
15532
15510
  };
15533
15511
  var WaterFall$1 = React.memo(WaterFall);
15534
15512
 
@@ -16767,7 +16745,7 @@ const Display = createMaterial(DisplayComponent, {
16767
16745
  * @Author: binruan@chatlabs.com
16768
16746
  * @Date: 2024-06-13 10:08:32
16769
16747
  * @LastEditors: binruan@chatlabs.com
16770
- * @LastEditTime: 2024-11-26 11:42:08
16748
+ * @LastEditTime: 2024-12-10 13:55:37
16771
16749
  * @FilePath: \pb-sxp-ui\src\materials\sxp\MultiPosts\settingRender.tsx
16772
16750
  *
16773
16751
  */
@@ -16778,7 +16756,8 @@ var settingRender = [
16778
16756
  {
16779
16757
  label: '背景图',
16780
16758
  type: 'Upload',
16781
- name: ['props', 'bgImgUrl']
16759
+ name: ['props', 'bgImgUrl'],
16760
+ text: '建议尺寸:720 * 1280'
16782
16761
  },
16783
16762
  {
16784
16763
  type: 'Group',
@@ -16851,7 +16830,7 @@ var settingRender = [
16851
16830
  ]
16852
16831
  },
16853
16832
  {
16854
- title: '按钮设置',
16833
+ title: '按钮设置 (建议尺寸:500 * 500)',
16855
16834
  child: [
16856
16835
  {
16857
16836
  type: 'Group',