pb-sxp-ui 1.0.79 → 1.0.80

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -617,6 +617,30 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
617
617
  eventInfo: Object.assign(Object.assign({}, eventInfo), { ctaId: (_h = cta === null || cta === void 0 ? void 0 : cta.itemId) !== null && _h !== void 0 ? _h : '', ctaName: (_j = cta === null || cta === void 0 ? void 0 : cta.title) !== null && _j !== void 0 ? _j : '', contentTags: JSON.stringify(cta === null || cta === void 0 ? void 0 : cta.tags), position: position + '', contentId: (_l = (_k = rec === null || rec === void 0 ? void 0 : rec.video) === null || _k === void 0 ? void 0 : _k.itemId) !== null && _l !== void 0 ? _l : '', productId: isProd ? product === null || product === void 0 ? void 0 : product.itemId : '', traceInfo: (_m = cta === null || cta === void 0 ? void 0 : cta.traceInfo) !== null && _m !== void 0 ? _m : '', fromKName })
618
618
  });
619
619
  }, [bffEventReport, isFromHashtag]);
620
+ useEffect(() => {
621
+ var _a, _b;
622
+ const queryString = location.search.slice(1);
623
+ const params = qs.parse(queryString.replace(/\+/g, '%2B'));
624
+ for (const key in params) {
625
+ params[key] = params[key].replace(/%2B/g, '+');
626
+ }
627
+ const getVal = (key) => { var _a; return (_a = params[key]) !== null && _a !== void 0 ? _a : ''; };
628
+ bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
629
+ eventInfo: {
630
+ eventSubject: 'h5LinkEnterFeed',
631
+ eventDescription: 'User enter h5 link',
632
+ utmSource: getVal('utm_source'),
633
+ utmMedium: getVal('utm_medium'),
634
+ utmCampaign: getVal('utm_campaign'),
635
+ utmId: getVal('utm_id'),
636
+ utmContent: getVal('utm_content'),
637
+ enterTime: `${Date.now()}`,
638
+ requestId: null,
639
+ enterUrl: (_b = (_a = window === null || window === void 0 ? void 0 : window.location) === null || _a === void 0 ? void 0 : _a.href) !== null && _b !== void 0 ? _b : '',
640
+ clSource: getVal('cl_sourc')
641
+ }
642
+ });
643
+ }, []);
620
644
  useEffect(() => {
621
645
  setLoading(true);
622
646
  bffGetTagList();
@@ -10339,7 +10363,7 @@ var _a, _b;
10339
10363
  * @Author: binruan@chatlabs.com
10340
10364
  * @Date: 2024-04-07 14:07:12
10341
10365
  * @LastEditors: binruan@chatlabs.com
10342
- * @LastEditTime: 2024-05-23 11:03:15
10366
+ * @LastEditTime: 2024-06-07 15:51:49
10343
10367
  * @FilePath: \pb-sxp-ui\src\materials\sxp\HashTag\settingRender.tsx
10344
10368
  *
10345
10369
  */
@@ -10366,7 +10390,8 @@ var settingRender = [
10366
10390
  {
10367
10391
  type: 'Switch',
10368
10392
  label: '固定宽高',
10369
- name: ['props', 'isWaterfallFlow']
10393
+ name: ['props', 'isWaterfallFlow'],
10394
+ initialValue: true
10370
10395
  }
10371
10396
  ]
10372
10397
  },
@@ -12417,7 +12442,7 @@ function WaterfallList(_a) {
12417
12442
  * @Author: binruan@chatlabs.com
12418
12443
  * @Date: 2024-01-10 10:58:24
12419
12444
  * @LastEditors: binruan@chatlabs.com
12420
- * @LastEditTime: 2024-06-07 10:35:35
12445
+ * @LastEditTime: 2024-06-07 15:57:29
12421
12446
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\WaterFall\index.tsx
12422
12447
  *
12423
12448
  */
@@ -12511,7 +12536,7 @@ const WaterFall = (props) => {
12511
12536
  display: openHashtag ? 'block' : 'none'
12512
12537
  } },
12513
12538
  React.createElement(Navbar$1, { icon: img$1, styles: { top: '32px' }, textStyle: (_a = props === null || props === void 0 ? void 0 : props.textStyles) === null || _a === void 0 ? void 0 : _a.hashTagTitle, onClose: handleClose }),
12514
- (props === null || props === void 0 ? void 0 : props.isWaterfallFlow) ? (React.createElement(WaterfallList$1, Object.assign({ reportTagsView: reportTagsView }, props))) : (React.createElement(WaterfallList, Object.assign({ reportTagsView: reportTagsView }, props)))), modalEleRef.current);
12539
+ (props === null || props === void 0 ? void 0 : props.isWaterfallFlow) === true || (props === null || props === void 0 ? void 0 : props.isWaterfallFlow) === undefined ? (React.createElement(WaterfallList, Object.assign({ reportTagsView: reportTagsView }, props))) : (React.createElement(WaterfallList$1, Object.assign({ reportTagsView: reportTagsView }, props)))), modalEleRef.current);
12515
12540
  };
12516
12541
  var WaterFall$1 = memo(WaterFall);
12517
12542
 
@@ -13353,39 +13378,15 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
13353
13378
  return data.length > 0 && !loading && getFeUserId();
13354
13379
  }, [data, loading]);
13355
13380
  const handleH5EnterLink = useCallback(() => {
13356
- var _a, _b;
13357
13381
  if (data.length <= 0) {
13358
13382
  return;
13359
13383
  }
13360
13384
  initTime();
13361
- // 刷新 sessionId
13362
- // refreshFeSessionId();
13363
- const queryString = location.search.slice(1);
13364
- const params = qs.parse(queryString.replace(/\+/g, '%2B'));
13365
- for (const key in params) {
13366
- params[key] = params[key].replace(/%2B/g, '+');
13367
- }
13368
- const getVal = (key) => { var _a; return (_a = params[key]) !== null && _a !== void 0 ? _a : ''; };
13369
- bffEventReport === null || bffEventReport === void 0 ? void 0 : bffEventReport({
13370
- eventInfo: {
13371
- eventSubject: 'h5LinkEnterFeed',
13372
- eventDescription: 'User enter h5 link',
13373
- utmSource: getVal('utm_source'),
13374
- utmMedium: getVal('utm_medium'),
13375
- utmCampaign: getVal('utm_campaign'),
13376
- utmId: getVal('utm_id'),
13377
- utmContent: getVal('utm_content'),
13378
- enterTime: `${Date.now()}`,
13379
- requestId: null,
13380
- enterUrl: (_b = (_a = window === null || window === void 0 ? void 0 : window.location) === null || _a === void 0 ? void 0 : _a.href) !== null && _b !== void 0 ? _b : '',
13381
- clSource: getVal('cl_sourc')
13382
- }
13383
- });
13384
13385
  bffFbReport === null || bffFbReport === void 0 ? void 0 : bffFbReport({
13385
13386
  eventName: 'PageView'
13386
13387
  });
13387
13388
  setIsInit(true);
13388
- }, [bffEventReport, data.length, bffFbReport]);
13389
+ }, [data.length, bffFbReport]);
13389
13390
  const initTime = () => {
13390
13391
  curTime.current = new Date();
13391
13392
  viewTime.current = new Date();