pb-sxp-ui 1.0.45 → 1.0.46

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/pb-ui.js CHANGED
@@ -10076,7 +10076,7 @@ Made in Italy` })));
10076
10076
  * @Author: binruan@chatlabs.com
10077
10077
  * @Date: 2024-04-07 14:07:12
10078
10078
  * @LastEditors: binruan@chatlabs.com
10079
- * @LastEditTime: 2024-04-12 17:39:45
10079
+ * @LastEditTime: 2024-04-29 19:55:53
10080
10080
  * @FilePath: \pb-sxp-ui\src\materials\sxp\HashTag\settingRender.tsx
10081
10081
  *
10082
10082
  */
@@ -10116,6 +10116,10 @@ Made in Italy` })));
10116
10116
  label: 'hashtag描述',
10117
10117
  value: 'hashTagDesc'
10118
10118
  },
10119
+ {
10120
+ label: 'hashtag描述超链',
10121
+ value: 'hashTagLink'
10122
+ },
10119
10123
  {
10120
10124
  label: '标题',
10121
10125
  value: 'title'
@@ -10199,8 +10203,8 @@ Made in Italy` })));
10199
10203
  ]
10200
10204
  },
10201
10205
  {
10202
- type: 'TextMargin',
10203
- name: ['props', 'buttonStyle']
10206
+ type: 'TextPadding',
10207
+ name: ['props', 'buttonBgStyle']
10204
10208
  },
10205
10209
  {
10206
10210
  type: 'Group',
@@ -10233,6 +10237,28 @@ Made in Italy` })));
10233
10237
  name: ['props', 'buttonStyle']
10234
10238
  }
10235
10239
  ]
10240
+ },
10241
+ {
10242
+ title: '按钮背景样式',
10243
+ child: [
10244
+ {
10245
+ type: 'Color',
10246
+ label: '背景色',
10247
+ name: ['props', 'buttonBgStyle', 'backgroundColor'],
10248
+ initialValue: '#fff'
10249
+ },
10250
+ {
10251
+ type: 'Group',
10252
+ label: '尺寸',
10253
+ child: [
10254
+ {
10255
+ type: 'Number',
10256
+ name: ['props', 'buttonBgStyle', 'height'],
10257
+ addonAfter: 'H'
10258
+ }
10259
+ ]
10260
+ }
10261
+ ]
10236
10262
  }
10237
10263
  ];
10238
10264
 
@@ -11664,7 +11690,7 @@ Made in Italy` })));
11664
11690
  React.createElement("div", { className: 'list-content-listItem-info-price', style: textStyles === null || textStyles === void 0 ? void 0 : textStyles.price, hidden: !priceText }, priceText))));
11665
11691
  };
11666
11692
  function WaterfallList(_a) {
11667
- var _b, _c, _d, _e, _f, _g, _h;
11693
+ var _b, _c, _d, _e, _f, _g, _h, _j, _k;
11668
11694
  var { reportTagsView } = _a, props = __rest(_a, ["reportTagsView"]);
11669
11695
  const { waterFallData, getRecommendVideos, hashTagSize, loadingImage, isOpenHashTag } = useSxpDataSource();
11670
11696
  const [list, setList] = React.useState();
@@ -11734,17 +11760,23 @@ Made in Italy` })));
11734
11760
  };
11735
11761
  return (React.createElement(React.Fragment, null, isLoadingData ? (React.createElement("div", { style: { height: '100%', width: '100%', display: 'flex', justifyContent: 'center', alignItems: 'center' } },
11736
11762
  React.createElement("img", { width: 64, height: 64, src: loadingImage, alt: 'loading...', style: { objectFit: 'contain' } }))) : (React.createElement("div", { className: 'list' },
11737
- React.createElement("div", { className: 'list-scroll', ref: containerRef, style: {
11738
- bottom: ((_b = data === null || data === void 0 ? void 0 : data.tag) === null || _b === void 0 ? void 0 : _b.link) ? '100px' : 0
11739
- } },
11740
- React.createElement("div", { className: 'list-info', style: (_c = props === null || props === void 0 ? void 0 : props.textStyles) === null || _c === void 0 ? void 0 : _c.hashTagDesc }, (_d = data === null || data === void 0 ? void 0 : data.tag) === null || _d === void 0 ? void 0 : _d.info),
11741
- React.createElement("div", { hidden: !((_e = data === null || data === void 0 ? void 0 : data.tag) === null || _e === void 0 ? void 0 : _e.link), className: 'list-collection', onClick: handleClickLink, style: { marginBottom: props === null || props === void 0 ? void 0 : props.space } }, ((_f = data === null || data === void 0 ? void 0 : data.tag) === null || _f === void 0 ? void 0 : _f.linkTitle) || 'Shop the collection'),
11763
+ React.createElement("div", { className: 'list-scroll', ref: containerRef },
11764
+ React.createElement("div", { className: 'list-info', style: (_b = props === null || props === void 0 ? void 0 : props.textStyles) === null || _b === void 0 ? void 0 : _b.hashTagDesc }, (_c = data === null || data === void 0 ? void 0 : data.tag) === null || _c === void 0 ? void 0 : _c.info),
11765
+ React.createElement("div", { hidden: !((_d = data === null || data === void 0 ? void 0 : data.tag) === null || _d === void 0 ? void 0 : _d.link), className: 'list-collection', onClick: handleClickLink, style: Object.assign(Object.assign({}, (_e = props === null || props === void 0 ? void 0 : props.textStyles) === null || _e === void 0 ? void 0 : _e.hashTagLink), { marginBottom: props === null || props === void 0 ? void 0 : props.space }) }, ((_f = data === null || data === void 0 ? void 0 : data.tag) === null || _f === void 0 ? void 0 : _f.linkTitle) || 'Shop the collection'),
11742
11766
  React.createElement("div", { className: 'list-content' }, list === null || list === void 0 ? void 0 : list.map((item, ind) => {
11743
11767
  return (React.createElement(WaterfallFlowItem, Object.assign({ key: ind, index: ind, rec: item, list: list, reportTagsView: reportTagsView }, props)));
11744
11768
  })),
11745
- React.createElement("div", { hidden: !isLoadMore, style: { textAlign: 'center' } }, "loading...")),
11746
- React.createElement("div", { className: 'list-bottom', hidden: !((_g = data === null || data === void 0 ? void 0 : data.tag) === null || _g === void 0 ? void 0 : _g.link) },
11747
- React.createElement("button", { className: 'list-bottom-btn', style: props === null || props === void 0 ? void 0 : props.buttonStyle, onClick: handleClickLink }, ((_h = data === null || data === void 0 ? void 0 : data.tag) === null || _h === void 0 ? void 0 : _h.linkTitle) || 'Shop the collection'))))));
11769
+ React.createElement("div", { hidden: !isLoadMore, style: { textAlign: 'center' } }, "loading..."),
11770
+ React.createElement("div", {
11771
+ // hidden={!data?.tag?.link}
11772
+ style: {
11773
+ height: ((_g = data === null || data === void 0 ? void 0 : data.tag) === null || _g === void 0 ? void 0 : _g.link) ? ((_h = props === null || props === void 0 ? void 0 : props.buttonBgStyle) === null || _h === void 0 ? void 0 : _h.height) || ((_j = props === null || props === void 0 ? void 0 : props.buttonStyle) === null || _j === void 0 ? void 0 : _j.height) || '100px' : 0
11774
+ } })),
11775
+ React.createElement("div", { className: 'list-bottom', style: props === null || props === void 0 ? void 0 : props.buttonBgStyle }),
11776
+ React.createElement("div", {
11777
+ // hidden={!data?.tag?.link}
11778
+ className: 'list-btn-wrap', style: Object.assign(Object.assign({}, props === null || props === void 0 ? void 0 : props.buttonBgStyle), { height: 'auto', backgroundColor: 'transparent' }) },
11779
+ React.createElement("button", { className: 'list-btn', style: props === null || props === void 0 ? void 0 : props.buttonStyle, onClick: handleClickLink }, ((_k = data === null || data === void 0 ? void 0 : data.tag) === null || _k === void 0 ? void 0 : _k.linkTitle) || 'Shop the collection'))))));
11748
11780
  }
11749
11781
 
11750
11782
  var img$1 = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAAAXNSR0IArs4c6QAAAaZJREFUeF7t2jFKBEEQRuG3mSJeQTARURDMTL2EqXfwAnoKD6FHMDEzNVIw2tzQC2gFggyDrExX1V92T7wz9PumFnqbXdH5teq8nwEwJqBzgfEVKDYAW8Ae8NZq3ZUm4Aa4AnaBR+C8BUIVAIu/ngSfAs9LESoAWLgB/LzWwP7SeLtfHWAu3tZ9Adz/dwD3eOUJCIlXBQiLVwQIjVcDCI9XAkiJVwFIi1cASI3PBpjb3jbd5GyyUcraCUrEZ02ATHwGgFR8NIBcfCSAZHwUgGx8BIB0vDeAfLwnQIl4L4Ay8R4ApeJbA2wD78DOZA/e7ABzk739Xz/T8rfAIfA6WYCd3BqA7NUSwCKfgLNKCK0BjoC7rzP74yoIrQGsuxSCB0ApBC+AMgieACUQvAHkESIApBGiAGQRIgEkEaIB5BAyAKQQsgBkEDIBJBCyAdIRFABSEVQA0hCUAFIQ1ADCERQBQhFUAcIQlAFCENQBfkOwg9eXpeftFQDmEOzv8ifARy8A3wiXwAHwANwujbf7q0xAi9bZZwwAN9oiDx4TUORFuS2z+wn4BAiAaEHnKChjAAAAAElFTkSuQmCC";
@@ -11855,7 +11887,7 @@ Made in Italy` })));
11855
11887
  * @Author: binruan@chatlabs.com
11856
11888
  * @Date: 2024-01-15 19:03:09
11857
11889
  * @LastEditors: binruan@chatlabs.com
11858
- * @LastEditTime: 2024-04-07 15:42:10
11890
+ * @LastEditTime: 2024-04-29 19:08:34
11859
11891
  * @FilePath: \pb-sxp-ui\src\materials\sxp\HashTag\index.tsx
11860
11892
  *
11861
11893
  */
@@ -11868,7 +11900,7 @@ Made in Italy` })));
11868
11900
  * @Author: binruan@chatlabs.com
11869
11901
  * @Date: 2023-07-28 18:29:57
11870
11902
  * @LastEditors: binruan@chatlabs.com
11871
- * @LastEditTime: 2024-04-07 16:22:28
11903
+ * @LastEditTime: 2024-04-30 10:13:13
11872
11904
  * @FilePath: \pb-sxp-ui\src\materials\sxp\HashTag\material.tsx
11873
11905
  *
11874
11906
  */
@@ -11895,6 +11927,12 @@ Made in Italy` })));
11895
11927
  textAlign: 'center',
11896
11928
  color: '#000'
11897
11929
  },
11930
+ hashTagLink: {
11931
+ textAlign: 'center',
11932
+ color: '#757575',
11933
+ fontSize: 12,
11934
+ textDecoration: 'underline'
11935
+ },
11898
11936
  title: {
11899
11937
  fontSize: 12,
11900
11938
  color: '#000'
@@ -11913,6 +11951,14 @@ Made in Italy` })));
11913
11951
  textAlign: 'center',
11914
11952
  color: '#fff',
11915
11953
  borderRadius: 25
11954
+ },
11955
+ buttonBgStyle: {
11956
+ backgroundColor: '#fff',
11957
+ height: 52,
11958
+ paddingTop: 20,
11959
+ paddingLeft: 20,
11960
+ paddingRight: 20,
11961
+ paddingBottom: 20
11916
11962
  }
11917
11963
  }
11918
11964
  },
@@ -12144,11 +12190,25 @@ Made in Italy` })));
12144
12190
  var _a;
12145
12191
  return ((_a = rec === null || rec === void 0 ? void 0 : rec.video) === null || _a === void 0 ? void 0 : _a.cover) || firstFrameSrc;
12146
12192
  }, [firstFrameSrc, rec]);
12193
+ const blurStyle = React.useMemo(() => {
12194
+ return blur
12195
+ ? {
12196
+ filter: 'blur(10px)',
12197
+ transform: 'translate3d(0px, 0px, 0px) scale(1.2)'
12198
+ }
12199
+ : {};
12200
+ }, [blur]);
12201
+ const isBgColor = React.useMemo(() => {
12202
+ return (videoPostConfig === null || videoPostConfig === void 0 ? void 0 : videoPostConfig.bgWay) === '1';
12203
+ }, [videoPostConfig]);
12204
+ const bgStyle = React.useMemo(() => {
12205
+ return isBgColor && (videoPostConfig === null || videoPostConfig === void 0 ? void 0 : videoPostConfig.bgColor) ? { backgroundColor: videoPostConfig === null || videoPostConfig === void 0 ? void 0 : videoPostConfig.bgColor } : {};
12206
+ }, [videoPostConfig, isBgColor]);
12147
12207
  const handLoadeddata = React.useCallback(() => {
12148
12208
  var _a;
12149
- if (!videoRef)
12209
+ if (!videoRef || isBgColor)
12150
12210
  return;
12151
- const videoDomRef = document.getElementById(`${videoId}_html5_api`);
12211
+ const videoDomRef = document.getElementById('player-container-id_html5_api');
12152
12212
  if (((_a = rec === null || rec === void 0 ? void 0 : rec.video) === null || _a === void 0 ? void 0 : _a.cover) || !canvasRef || !videoDomRef || !canvasRef.current)
12153
12213
  return;
12154
12214
  const setFrameImg = () => {
@@ -12166,7 +12226,7 @@ Made in Italy` })));
12166
12226
  setTimeout(() => {
12167
12227
  setFrameImg();
12168
12228
  }, 500);
12169
- }, [videoRef]);
12229
+ }, [videoRef, isBgColor, rec]);
12170
12230
  React.useEffect(() => {
12171
12231
  if (!isActive || !videoRef)
12172
12232
  return;
@@ -12253,24 +12313,11 @@ Made in Italy` })));
12253
12313
  window.removeEventListener('beforeunload', handleBeforeUnload);
12254
12314
  };
12255
12315
  }, [activeIndex, index, rec, videoRef, handleClickVideo, isPauseVideo]);
12256
- const blurStyle = React.useMemo(() => {
12257
- return blur
12258
- ? {
12259
- filter: 'blur(10px)',
12260
- transform: 'translate3d(0px, 0px, 0px) scale(1.2)'
12261
- }
12262
- : {};
12263
- }, [blur]);
12264
12316
  if (!rec.video) {
12265
12317
  return null;
12266
12318
  }
12267
- return (React.createElement(React.Fragment, null, blur ? (React.createElement("div", { className: 'video-container', key: rec.video.itemId, onClick: handleClickVideo(), style: {
12268
- position: 'relative',
12269
- width: '100%',
12270
- height,
12271
- overflow: 'hidden'
12272
- } },
12273
- React.createElement(FormatImage$1, { src: blurBgSrc, style: Object.assign({ height: '100%', width: '100%', objectFit: 'cover' }, blurStyle) }),
12319
+ return (React.createElement(React.Fragment, null, blur ? (React.createElement("div", { className: 'video-container', key: rec.video.itemId, onClick: handleClickVideo(), style: Object.assign({ position: 'relative', width: '100%', height, overflow: 'hidden' }, bgStyle) },
12320
+ !isBgColor && (React.createElement(FormatImage$1, { src: blurBgSrc, style: Object.assign({ height: '100%', width: '100%', objectFit: 'cover' }, blurStyle) })),
12274
12321
  React.createElement("canvas", { ref: canvasRef, style: { display: 'none' } }),
12275
12322
  React.createElement("div", { style: {
12276
12323
  position: 'absolute',
@@ -12345,7 +12392,7 @@ Made in Italy` })));
12345
12392
  * @Author: binruan@chatlabs.com
12346
12393
  * @Date: 2024-03-20 10:27:31
12347
12394
  * @LastEditors: binruan@chatlabs.com
12348
- * @LastEditTime: 2024-04-26 14:33:25
12395
+ * @LastEditTime: 2024-04-29 18:57:05
12349
12396
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\PictureGroup\Picture.tsx
12350
12397
  *
12351
12398
  */
@@ -12368,13 +12415,14 @@ Made in Italy` })));
12368
12415
  }
12369
12416
  : {};
12370
12417
  }, [blur]);
12371
- return (React.createElement("div", { style: {
12372
- overflow: 'hidden',
12373
- height,
12374
- width: '100%',
12375
- position: 'relative'
12376
- } },
12377
- React.createElement(FormatImage$1, { src: src, style: Object.assign({ height: '100%', width: '100%', objectFit: 'cover' }, blurStyle) }),
12418
+ const isBgColor = React.useMemo(() => {
12419
+ return (imgUrlsPostConfig === null || imgUrlsPostConfig === void 0 ? void 0 : imgUrlsPostConfig.bgWay) === '1';
12420
+ }, [imgUrlsPostConfig]);
12421
+ const bgStyle = React.useMemo(() => {
12422
+ return isBgColor && (imgUrlsPostConfig === null || imgUrlsPostConfig === void 0 ? void 0 : imgUrlsPostConfig.bgColor) ? { backgroundColor: imgUrlsPostConfig === null || imgUrlsPostConfig === void 0 ? void 0 : imgUrlsPostConfig.bgColor } : {};
12423
+ }, [imgUrlsPostConfig, isBgColor]);
12424
+ return (React.createElement("div", { style: Object.assign({ overflow: 'hidden', height, width: '100%', position: 'relative' }, bgStyle) },
12425
+ !isBgColor && (React.createElement(FormatImage$1, { src: src, style: Object.assign({ height: '100%', width: '100%', objectFit: 'cover' }, blurStyle) })),
12378
12426
  blur && (React.createElement(FormatImage$1, { src: src, style: {
12379
12427
  width: '100%',
12380
12428
  height: '100%',