pb-sxp-ui 1.0.77 → 1.0.78

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
@@ -10338,29 +10338,19 @@ var _a, _b;
10338
10338
  *
10339
10339
  */
10340
10340
  var settingRender = [
10341
- {
10342
- title: 'Banner',
10343
- child: [
10344
- {
10345
- type: 'Switch',
10346
- label: 'Banner图开关',
10347
- name: ['props', 'showBanner']
10348
- }
10349
- ]
10350
- },
10351
10341
  {
10352
10342
  title: '卡片样式',
10353
10343
  child: [
10344
+ // {
10345
+ // type: 'Number',
10346
+ // label: '文本行数',
10347
+ // name: ['props', 'lineClamp']
10348
+ // },
10354
10349
  {
10355
10350
  type: 'Number',
10356
10351
  label: '上下边距',
10357
10352
  name: ['props', 'space'],
10358
10353
  addonAfter: 'px'
10359
- },
10360
- {
10361
- type: 'Switch',
10362
- label: '固定宽高',
10363
- name: ['props', 'isWaterfallFlow']
10364
10354
  }
10365
10355
  ]
10366
10356
  },
@@ -11830,14 +11820,9 @@ var previewData = {
11830
11820
  };
11831
11821
 
11832
11822
  const WaterfallFlowItem = (props) => {
11833
- const { rec, style = {}, sizeChange = () => { }, unitWidth, index, showBorder, list, reportTagsView, textStyles, space } = props;
11834
- const { swiperRef, setRtcList, setOpenHashtag, sxpParameter } = useSxpDataSource();
11823
+ const { rec, index, list, reportTagsView, textStyles, space } = props;
11824
+ const { swiperRef, setRtcList, setOpenHashtag, bffEventReport, sxpParameter } = useSxpDataSource();
11835
11825
  const [showVideo, setShowVideo] = useState(false);
11836
- const [isLoading, setIsLoading] = useState(false);
11837
- const [imgInfo, setImgInfo] = useState({
11838
- height: 1,
11839
- width: 1
11840
- });
11841
11826
  const imgDom = useRef(null);
11842
11827
  const ref = useRef(null);
11843
11828
  const videoDom = useRef(null);
@@ -11862,26 +11847,6 @@ const WaterfallFlowItem = (props) => {
11862
11847
  var _a, _b;
11863
11848
  return ((_a = rec === null || rec === void 0 ? void 0 : rec.product) === null || _a === void 0 ? void 0 : _a.title) || ((_b = rec === null || rec === void 0 ? void 0 : rec.video) === null || _b === void 0 ? void 0 : _b.title) || null;
11864
11849
  }, [rec]);
11865
- /** 离父亲上边框的距离 */
11866
- const top = useMemo(() => {
11867
- var _a;
11868
- const y = style.transform
11869
- ? Number((_a = style.transform) === null || _a === void 0 ? void 0 : _a.substring(style.transform.indexOf(',', 0) + 1, style.transform.length - 3))
11870
- : undefined;
11871
- return y;
11872
- }, [style]);
11873
- /** 是否加载图片 */
11874
- const isImgShow = useMemo(() => {
11875
- if (top === undefined) {
11876
- return false;
11877
- }
11878
- if (top <= showBorder) {
11879
- return true;
11880
- }
11881
- else {
11882
- return false;
11883
- }
11884
- }, [top, showBorder]);
11885
11850
  const priceText = useMemo(() => {
11886
11851
  var _a, _b, _c, _d, _e, _f, _g, _h, _j;
11887
11852
  if (((_a = rec === null || rec === void 0 ? void 0 : rec.product) === null || _a === void 0 ? void 0 : _a.currency) && ((_b = rec === null || rec === void 0 ? void 0 : rec.product) === null || _b === void 0 ? void 0 : _b.price)) {
@@ -11894,55 +11859,42 @@ const WaterfallFlowItem = (props) => {
11894
11859
  }
11895
11860
  }, [rec]);
11896
11861
  // useEffect(() => {
11897
- // const observer = new IntersectionObserver((entries) => {
11898
- // entries.forEach((entry) => {
11899
- // if (entry.isIntersecting) {
11900
- // if (ref.current === null || src === '') {
11901
- // return;
11902
- // }
11903
- // if (showVideo && firstFrameSrc) {
11904
- // imgDom.current.setSrc(firstFrameSrc);
11905
- // } else {
11906
- // imgDom.current.setSrc(src);
11907
- // }
11908
- // observer.unobserve(ref.current);
11909
- // }
11910
- // });
11911
- // });
11912
- // observer.observe(ref.current);
11913
- // return () => {
11914
- // observer.disconnect();
11915
- // };
11862
+ // if (imgDom.current === null || src === '') {
11863
+ // return;
11864
+ // }
11865
+ // const img = new Image();
11866
+ // if (showVideo && firstFrameSrc) {
11867
+ // img.src = firstFrameSrc;
11868
+ // } else {
11869
+ // img.src = src;
11870
+ // }
11871
+ // // img.onload = () => {
11872
+ // // setIsLoading(true);
11873
+ // // };
11874
+ // imgDom.current.src = img.src;
11916
11875
  // }, [src, showVideo, firstFrameSrc]);
11917
11876
  useEffect(() => {
11918
- if (imgDom.current === null || src === '' || isImgShow === false) {
11919
- return;
11920
- }
11921
- const img = new Image();
11922
- if (showVideo && firstFrameSrc) {
11923
- img.src = firstFrameSrc;
11924
- }
11925
- else {
11926
- img.src = src;
11927
- }
11928
- img.onload = () => {
11929
- setImgInfo({
11930
- height: img.height,
11931
- width: img.width
11877
+ const observer = new IntersectionObserver((entries) => {
11878
+ entries.forEach((entry) => {
11879
+ if (entry.isIntersecting) {
11880
+ if (ref.current === null || src === '') {
11881
+ return;
11882
+ }
11883
+ if (showVideo && firstFrameSrc) {
11884
+ imgDom.current.setSrc(firstFrameSrc);
11885
+ }
11886
+ else {
11887
+ imgDom.current.setSrc(src);
11888
+ }
11889
+ observer.unobserve(ref.current);
11890
+ }
11932
11891
  });
11933
- setIsLoading(true);
11892
+ });
11893
+ observer.observe(ref.current);
11894
+ return () => {
11895
+ observer.disconnect();
11934
11896
  };
11935
- // imgDom.current.setSrc(img.src);
11936
- imgDom.current.src = img.src;
11937
- }, [src, showVideo, firstFrameSrc, isImgShow]);
11938
- useEffect(() => {
11939
- // 通过宽度比例获取图片高度
11940
- const height = imgInfo.height * (unitWidth / imgInfo.width);
11941
- if (isLoading) {
11942
- // 加40是因为下方文字部分高度为40,可以自己设置
11943
- sizeChange(height + 76 + space, index);
11944
- }
11945
- }, [imgInfo, index, unitWidth, isLoading, space]); /* 增加sizeChange依赖项会导致在admin预览编辑时无限刷新 */
11897
+ }, [src, showVideo, firstFrameSrc]);
11946
11898
  const calculateHeightForWidth = (videoWidth, videoHeight, targetWidth) => {
11947
11899
  const aspectRatio = videoWidth / videoHeight;
11948
11900
  const targetHeight = targetWidth / aspectRatio;
@@ -11980,135 +11932,40 @@ const WaterfallFlowItem = (props) => {
11980
11932
  setOpenHashtag === null || setOpenHashtag === void 0 ? void 0 : setOpenHashtag(false);
11981
11933
  }, 0);
11982
11934
  };
11983
- return (React.createElement("div", { ref: ref, style: Object.assign({}, style), className: 'waterFallList-content-listItem', key: index, onClick: handleClickToDetail },
11984
- React.createElement("div", { className: 'waterFallList-content-listItem-picture' },
11935
+ return (React.createElement("div", { ref: ref, className: 'list-content-listItem', key: index, onClick: handleClickToDetail, style: { marginBottom: space } },
11936
+ React.createElement("div", { className: 'list-content-listItem-picture' },
11985
11937
  showVideo && (React.createElement("div", { style: { display: 'none' } },
11986
- React.createElement("video", { ref: videoDom, src: src, crossOrigin: 'anonymous', className: 'waterFallList-content-listItem-picture-img' }),
11938
+ React.createElement("video", { ref: videoDom, crossOrigin: 'anonymous', className: 'list-content-listItem-picture-img' }),
11987
11939
  React.createElement("canvas", { ref: canvasRef }))),
11988
- React.createElement("img", { loading: 'lazy', className: 'waterFallList-content-listItem-picture-img', ref: imgDom })),
11989
- React.createElement("div", { className: 'waterFallList-content-listItem-info' },
11990
- React.createElement("div", { className: `${'waterFallList-content-listItem-info-title'} ${priceText ? 'waterFallList-content-listItem-info-nowrap' : ''}`, style: Object.assign({}, textStyles === null || textStyles === void 0 ? void 0 : textStyles.title) }, title && title),
11991
- React.createElement("div", { className: 'waterFallList-content-listItem-info-price', hidden: !priceText, style: textStyles.price }, priceText))));
11940
+ React.createElement(FormatImage$1, { loading: 'lazy', className: 'list-content-listItem-picture-img', ref: imgDom })),
11941
+ React.createElement("div", { className: 'list-content-listItem-info' },
11942
+ React.createElement("div", { className: `${'list-content-listItem-info-title'} ${priceText ? 'list-content-listItem-info-nowrap' : ''}`, style: textStyles === null || textStyles === void 0 ? void 0 : textStyles.title }, title && title),
11943
+ React.createElement("div", { className: 'list-content-listItem-info-price', style: textStyles === null || textStyles === void 0 ? void 0 : textStyles.price, hidden: !priceText }, priceText))));
11992
11944
  };
11993
11945
  function WaterfallList(_a) {
11994
- var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
11946
+ var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
11995
11947
  var { reportTagsView } = _a, props = __rest(_a, ["reportTagsView"]);
11996
11948
  const { waterFallData, getRecommendVideos, hashTagSize, loadingImage, isOpenHashTag } = useSxpDataSource();
11997
- /** 滚动的父元素 */
11998
- const scrollParent = useRef(null);
11999
- /** 向上滚动的距离 */
12000
- const [scrollTop, setScrollTop] = useState(0);
12001
- /** 数据列表 */
11949
+ const [list, setList] = useState();
12002
11950
  const [data, setData] = useState();
12003
- const waterfallFlowDom = useRef(null);
12004
- /** 样式列表 */
12005
- const [styleList, setStyleList] = useState([]);
12006
- const styleListRef = useRef();
12007
- /** 自定义骨架屏高度 */
12008
- const heightList = [170, 230, 300];
12009
- /** 到达底部 */
12010
11951
  const [isLoadingData, setIsLoadingData] = useState(false);
12011
- const [list, setList] = useState([]);
12012
- const buttonRef = useRef();
12013
- /** 生成随机数 */
12014
- const createRandomNum = useCallback((min, max) => {
12015
- return Math.floor(Math.random() * (max - min + 1)) + min;
12016
- }, []);
12017
- const waterfallFlowListInfo = useRef([]);
12018
- /** 当前容器信息 */
12019
- const [frameInfo, setFrameInfoInfo] = useState({ width: 0 });
12020
- /** 每行个数 */
12021
- const rowsNum = useMemo(() => {
12022
- const width = frameInfo.width || 0;
12023
- if (width >= 1200) {
12024
- return 6;
12025
- }
12026
- else if (width >= 768 && width <= 1199) {
12027
- return 4;
12028
- }
12029
- else {
12030
- return 2;
12031
- }
12032
- }, [frameInfo]);
12033
- /** 每一个的宽度 */
12034
- const unitWidth = useMemo(() => {
12035
- return frameInfo.width / rowsNum - 2;
12036
- }, [rowsNum, frameInfo]);
12037
- /** 获取位置 */
12038
- const getStyleList = useCallback(() => {
12039
- var _a;
12040
- const temporaryStyleList = (_a = styleListRef.current) !== null && _a !== void 0 ? _a : [];
12041
- /** 目前最下一行的index */
12042
- const bottomItemIndex = [];
12043
- for (let i = 0; i < (list === null || list === void 0 ? void 0 : list.length); i++) {
12044
- // 原本应对应的行数
12045
- const currentRow = Math.floor(i / rowsNum);
12046
- //
12047
- const remainder = (i % rowsNum) + 1;
12048
- // 最低item下标
12049
- let minHeightInd = 0;
12050
- // 最低高度
12051
- let minHeight = 9999999999;
12052
- // 寻找最低高度的下标
12053
- if (currentRow === 0) {
12054
- bottomItemIndex[i] = i;
12055
- }
12056
- else {
12057
- for (let j = 0; j < bottomItemIndex.length; j++) {
12058
- if (waterfallFlowListInfo.current[bottomItemIndex[j]].top +
12059
- waterfallFlowListInfo.current[bottomItemIndex[j]].height <
12060
- minHeight) {
12061
- minHeightInd = j;
12062
- minHeight =
12063
- waterfallFlowListInfo.current[bottomItemIndex[j]].top +
12064
- waterfallFlowListInfo.current[bottomItemIndex[j]].height;
12065
- }
12066
- }
12067
- bottomItemIndex[minHeightInd] = i;
12068
- }
12069
- if (waterfallFlowListInfo.current[i] === undefined) {
12070
- waterfallFlowListInfo.current[i] = {};
12071
- }
12072
- // 第一行特殊处理,一定是从左到右铺的
12073
- if (currentRow === 0) {
12074
- if (remainder === 1) {
12075
- waterfallFlowListInfo.current[i].left = 0;
12076
- }
12077
- else {
12078
- waterfallFlowListInfo.current[i].left = waterfallFlowListInfo.current[i - 1].left + unitWidth + 4;
12079
- }
12080
- waterfallFlowListInfo.current[i].top = 0;
12081
- }
12082
- // 剩下的行数,铺在当前最低高度下面
12083
- else {
12084
- waterfallFlowListInfo.current[i].left = waterfallFlowListInfo.current[minHeightInd].left;
12085
- waterfallFlowListInfo.current[i].top = minHeight;
12086
- }
12087
- // 是否已经有高度,有高度使用已有高度,否则随机生成
12088
- waterfallFlowListInfo.current[i].height =
12089
- waterfallFlowListInfo.current[i].height || heightList[createRandomNum(0, 2)];
12090
- temporaryStyleList[i] = {
12091
- transform: `translate(${waterfallFlowListInfo.current[i].left}px,${waterfallFlowListInfo.current[i].top}px)`,
12092
- width: `${unitWidth}px`,
12093
- height: waterfallFlowListInfo.current[i].height
12094
- };
12095
- }
12096
- setStyleList([...temporaryStyleList]);
12097
- return [...temporaryStyleList];
12098
- }, [unitWidth, rowsNum, heightList, createRandomNum, list]);
12099
- /** 图片加载完更新高度 */
12100
- const onSizeChange = useCallback((height, index) => {
12101
- if (waterfallFlowListInfo.current[index] === undefined) {
12102
- waterfallFlowListInfo.current[index] = {};
12103
- }
12104
- waterfallFlowListInfo.current[index].height = height;
12105
- styleListRef.current = getStyleList();
12106
- }, [getStyleList]);
12107
- /** 大小、数量发生变化时触发 */
12108
- useEffect(() => {
12109
- styleListRef.current = getStyleList();
12110
- }, [unitWidth, rowsNum, list]); /* 增加getStyleList依赖项会导致在admin预览编辑时无限刷新 */
12111
- /** 初始化请求数据 */
11952
+ const containerRef = useRef(null);
11953
+ const [isLoadMore, setIsLoadMore] = useState(false);
11954
+ useCallback(() => {
11955
+ if (isLoadMore)
11956
+ return;
11957
+ setIsLoadMore(true);
11958
+ waterFallData &&
11959
+ (getRecommendVideos === null || getRecommendVideos === void 0 ? void 0 : getRecommendVideos({
11960
+ hashTag: waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.hashTag,
11961
+ 'itemFilter.itemId': waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.itemId,
11962
+ 'itemFilter.itemType': waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.itemType
11963
+ }).then((res) => {
11964
+ var _a;
11965
+ setList(list === null || list === void 0 ? void 0 : list.concat((_a = res === null || res === void 0 ? void 0 : res.recList) !== null && _a !== void 0 ? _a : []));
11966
+ setIsLoadMore(false);
11967
+ }));
11968
+ }, [waterFallData, getRecommendVideos, list, isLoadMore]);
12112
11969
  useEffect(() => {
12113
11970
  var _a, _b;
12114
11971
  setIsLoadingData(true);
@@ -12132,60 +11989,22 @@ function WaterfallList(_a) {
12132
11989
  setIsLoadingData(false);
12133
11990
  }
12134
11991
  }, [waterFallData, getRecommendVideos, hashTagSize, isOpenHashTag]);
12135
- const onResize = useCallback(() => {
12136
- if (waterfallFlowDom.current === null) {
12137
- return;
12138
- }
12139
- setFrameInfoInfo({
12140
- width: waterfallFlowDom.current.getBoundingClientRect().width
12141
- });
12142
- }, []);
12143
- /** 监听列表容器大小变化 */
12144
- useEffect(() => {
12145
- if (waterfallFlowDom.current === null) {
12146
- return;
12147
- }
12148
- const resizeObserver = new ResizeObserver((entries) => {
12149
- onResize();
12150
- });
12151
- resizeObserver.observe(waterfallFlowDom.current);
12152
- return () => {
12153
- resizeObserver.disconnect();
12154
- };
12155
- }, [onResize]);
12156
- useCallback(() => {
12157
- setIsLoadingData(true);
12158
- waterFallData &&
12159
- (getRecommendVideos === null || getRecommendVideos === void 0 ? void 0 : getRecommendVideos({
12160
- hashTag: waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.hashTag,
12161
- 'itemFilter.itemId': waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.itemId,
12162
- 'itemFilter.itemType': waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.itemType
12163
- }).then((res) => {
12164
- var _a, _b;
12165
- setList(list === null || list === void 0 ? void 0 : list.concat((_b = (_a = res === null || res === void 0 ? void 0 : res.recList) === null || _a === void 0 ? void 0 : _a.filter((item) => !(item === null || item === void 0 ? void 0 : item.video))) !== null && _b !== void 0 ? _b : []));
12166
- setIsLoadingData(false);
12167
- }));
12168
- }, [waterFallData, getRecommendVideos, list]);
12169
- const onScroll = useCallback(() => {
12170
- // 记录滚动值
12171
- setScrollTop(scrollParent.current.scrollTop);
12172
- // const top = (scrollParent.current as any).scrollTop;
12173
- // const clientHeight = (scrollParent.current as any).clientHeight;
12174
- // const scrollHeight = (scrollParent.current as any).scrollHeight;
12175
- // // 做底部加载
12176
- // if (scrollHeight <= top + clientHeight && !isLoadingData) {
12177
- // loadMoreData();
12178
- // }
12179
- }, []);
12180
- /** 监听滚动 */
12181
- useEffect(() => {
12182
- var _a;
12183
- (_a = scrollParent === null || scrollParent === void 0 ? void 0 : scrollParent.current) === null || _a === void 0 ? void 0 : _a.addEventListener('scroll', onScroll);
12184
- return () => {
12185
- var _a;
12186
- (_a = scrollParent === null || scrollParent === void 0 ? void 0 : scrollParent.current) === null || _a === void 0 ? void 0 : _a.removeEventListener('scroll', onScroll);
12187
- };
12188
- }, [onScroll, scrollParent]);
11992
+ // useEffect(() => {
11993
+ // const container = containerRef?.current;
11994
+ // if (!container) return;
11995
+ // const handleScroll = () => {
11996
+ // const top = (container as any)?.scrollTop;
11997
+ // const clientHeight = (container as any)?.clientHeight;
11998
+ // const scrollHeight = (container as any)?.scrollHeight;
11999
+ // if (scrollHeight <= top + clientHeight && !isLoadingData) {
12000
+ // loadMoreData();
12001
+ // }
12002
+ // };
12003
+ // container?.addEventListener('scroll', handleScroll);
12004
+ // return () => {
12005
+ // container?.removeEventListener('scroll', handleScroll); // 在组件卸载时移除事件监听器
12006
+ // };
12007
+ // }, [isLoadingData, containerRef, loadMoreData]);
12189
12008
  const handleClickLink = () => {
12190
12009
  var _a, _b;
12191
12010
  if ((_a = data === null || data === void 0 ? void 0 : data.tag) === null || _a === void 0 ? void 0 : _a.link) {
@@ -12194,27 +12013,20 @@ function WaterfallList(_a) {
12194
12013
  }
12195
12014
  };
12196
12015
  return (React.createElement(React.Fragment, null, isLoadingData ? (React.createElement("div", { style: { height: '100%', width: '100%', display: 'flex', justifyContent: 'center', alignItems: 'center' } },
12197
- React.createElement("img", { width: 64, height: 64, src: loadingImage, alt: 'loading...', style: { objectFit: 'contain' } }))) : (React.createElement("div", { className: 'waterFallList', ref: waterfallFlowDom },
12198
- React.createElement("div", { className: 'waterFallList-scroll', ref: scrollParent },
12199
- React.createElement("div", { className: 'waterFallList-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),
12200
- React.createElement("div", { hidden: !((_d = data === null || data === void 0 ? void 0 : data.tag) === null || _d === void 0 ? void 0 : _d.link), className: 'waterFallList-collection', style: Object.assign({}, (_e = props === null || props === void 0 ? void 0 : props.textStyles) === null || _e === void 0 ? void 0 : _e.hashTagLink), onClick: handleClickLink }, ((_f = data === null || data === void 0 ? void 0 : data.tag) === null || _f === void 0 ? void 0 : _f.linkTitle) || 'Shop the collection'),
12201
- React.createElement("div", { className: 'waterFallList-content' }, list === null || list === void 0 ? void 0 :
12202
- list.map((item, ind) => {
12203
- var _a;
12204
- return (React.createElement(WaterfallFlowItem, Object.assign({ key: ind, index: ind, rec: item, list: list, showBorder: scrollTop + ((_a = scrollParent === null || scrollParent === void 0 ? void 0 : scrollParent.current) === null || _a === void 0 ? void 0 : _a.clientHeight), style: styleList[ind], sizeChange: onSizeChange, unitWidth: unitWidth, reportTagsView: reportTagsView }, props)));
12205
- }),
12206
- React.createElement("div", { hidden: !((_g = data === null || data === void 0 ? void 0 : data.tag) === null || _g === void 0 ? void 0 : _g.link), style: {
12207
- position: 'absolute',
12208
- width: '100%',
12209
- transform: `translate(0px,${(_m = ((_j = waterfallFlowListInfo === null || waterfallFlowListInfo === void 0 ? void 0 : waterfallFlowListInfo.current[((_h = waterfallFlowListInfo === null || waterfallFlowListInfo === void 0 ? void 0 : waterfallFlowListInfo.current) === null || _h === void 0 ? void 0 : _h.length) - 1]) === null || _j === void 0 ? void 0 : _j.top) +
12210
- ((_l = waterfallFlowListInfo === null || waterfallFlowListInfo === void 0 ? void 0 : waterfallFlowListInfo.current[((_k = waterfallFlowListInfo === null || waterfallFlowListInfo === void 0 ? void 0 : waterfallFlowListInfo.current) === null || _k === void 0 ? void 0 : _k.length) - 1]) === null || _l === void 0 ? void 0 : _l.height)) !== null && _m !== void 0 ? _m : 0}px)`,
12211
- height: ((_o = data === null || data === void 0 ? void 0 : data.tag) === null || _o === void 0 ? void 0 : _o.link)
12212
- ? ((_p = buttonRef === null || buttonRef === void 0 ? void 0 : buttonRef.current) === null || _p === void 0 ? void 0 : _p.offsetHeight) || ((_q = props === null || props === void 0 ? void 0 : props.buttonBgStyle) === null || _q === void 0 ? void 0 : _q.height) || '100px'
12213
- : 0
12214
- } }))),
12215
- React.createElement("div", { className: 'waterFallList-bottom', hidden: !((_r = data === null || data === void 0 ? void 0 : data.tag) === null || _r === void 0 ? void 0 : _r.link), style: props === null || props === void 0 ? void 0 : props.buttonBgStyle }),
12216
- React.createElement("div", { ref: buttonRef, hidden: !((_s = data === null || data === void 0 ? void 0 : data.tag) === null || _s === void 0 ? void 0 : _s.link), className: 'waterFallList-btn-wrap', style: Object.assign(Object.assign({}, props === null || props === void 0 ? void 0 : props.buttonBgStyle), { height: 'auto', backgroundColor: 'transparent' }) },
12217
- React.createElement("button", { className: 'waterFallList-btn', style: props === null || props === void 0 ? void 0 : props.buttonStyle, onClick: handleClickLink }, ((_t = data === null || data === void 0 ? void 0 : data.tag) === null || _t === void 0 ? void 0 : _t.linkTitle) || 'Shop the collection'))))));
12016
+ React.createElement("img", { width: 64, height: 64, src: loadingImage, alt: 'loading...', style: { objectFit: 'contain' } }))) : (React.createElement("div", { className: 'list' },
12017
+ React.createElement("div", { className: 'list-scroll', ref: containerRef },
12018
+ 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),
12019
+ 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'),
12020
+ React.createElement("div", { className: 'list-content' }, list === null || list === void 0 ? void 0 : list.map((item, ind) => {
12021
+ return (React.createElement(WaterfallFlowItem, Object.assign({ key: ind, index: ind, rec: item, list: list, reportTagsView: reportTagsView }, props)));
12022
+ })),
12023
+ React.createElement("div", { hidden: !isLoadMore, style: { textAlign: 'center' } }, "loading..."),
12024
+ React.createElement("div", { hidden: !((_g = data === null || data === void 0 ? void 0 : data.tag) === null || _g === void 0 ? void 0 : _g.link), style: {
12025
+ height: ((_h = data === null || data === void 0 ? void 0 : data.tag) === null || _h === void 0 ? void 0 : _h.link) ? ((_j = props === null || props === void 0 ? void 0 : props.buttonBgStyle) === null || _j === void 0 ? void 0 : _j.height) || ((_k = props === null || props === void 0 ? void 0 : props.buttonStyle) === null || _k === void 0 ? void 0 : _k.height) || '100px' : 0
12026
+ } })),
12027
+ React.createElement("div", { className: 'list-bottom', hidden: !((_l = data === null || data === void 0 ? void 0 : data.tag) === null || _l === void 0 ? void 0 : _l.link), style: props === null || props === void 0 ? void 0 : props.buttonBgStyle }),
12028
+ React.createElement("div", { hidden: !((_m = data === null || data === void 0 ? void 0 : data.tag) === null || _m === void 0 ? void 0 : _m.link), className: 'list-btn-wrap', style: Object.assign(Object.assign({}, props === null || props === void 0 ? void 0 : props.buttonBgStyle), { height: 'auto', backgroundColor: 'transparent' }) },
12029
+ React.createElement("button", { className: 'list-btn', style: props === null || props === void 0 ? void 0 : props.buttonStyle, onClick: handleClickLink }, ((_o = data === null || data === void 0 ? void 0 : data.tag) === null || _o === void 0 ? void 0 : _o.linkTitle) || 'Shop the collection'))))));
12218
12030
  }
12219
12031
 
12220
12032
  var img$1 = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAAAXNSR0IArs4c6QAAAaZJREFUeF7t2jFKBEEQRuG3mSJeQTARURDMTL2EqXfwAnoKD6FHMDEzNVIw2tzQC2gFggyDrExX1V92T7wz9PumFnqbXdH5teq8nwEwJqBzgfEVKDYAW8Ae8NZq3ZUm4Aa4AnaBR+C8BUIVAIu/ngSfAs9LESoAWLgB/LzWwP7SeLtfHWAu3tZ9Adz/dwD3eOUJCIlXBQiLVwQIjVcDCI9XAkiJVwFIi1cASI3PBpjb3jbd5GyyUcraCUrEZ02ATHwGgFR8NIBcfCSAZHwUgGx8BIB0vDeAfLwnQIl4L4Ay8R4ApeJbA2wD78DOZA/e7ABzk739Xz/T8rfAIfA6WYCd3BqA7NUSwCKfgLNKCK0BjoC7rzP74yoIrQGsuxSCB0ApBC+AMgieACUQvAHkESIApBGiAGQRIgEkEaIB5BAyAKQQsgBkEDIBJBCyAdIRFABSEVQA0hCUAFIQ1ADCERQBQhFUAcIQlAFCENQBfkOwg9eXpeftFQDmEOzv8ifARy8A3wiXwAHwANwujbf7q0xAi9bZZwwAN9oiDx4TUORFuS2z+wn4BAiAaEHnKChjAAAAAElFTkSuQmCC";
@@ -12223,7 +12035,7 @@ var img$1 = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeA
12223
12035
  * @Author: binruan@chatlabs.com
12224
12036
  * @Date: 2024-01-10 10:58:24
12225
12037
  * @LastEditors: binruan@chatlabs.com
12226
- * @LastEditTime: 2024-06-06 17:19:25
12038
+ * @LastEditTime: 2024-04-15 17:57:59
12227
12039
  * @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\WaterFall\index.tsx
12228
12040
  *
12229
12041
  */