pb-sxp-ui 1.0.100 → 1.0.101
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 +23 -14
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +23 -14
- package/dist/index.js.map +1 -1
- package/dist/index.min.cjs +3 -3
- package/dist/index.min.cjs.map +1 -1
- package/dist/index.min.js +3 -3
- package/dist/index.min.js.map +1 -1
- package/dist/pb-ui.js +23 -14
- package/dist/pb-ui.js.map +1 -1
- package/dist/pb-ui.min.js +3 -3
- package/dist/pb-ui.min.js.map +1 -1
- package/es/core/components/SxpPageRender/ExpandableText.js +3 -1
- package/es/core/components/SxpPageRender/Tagbar.d.ts +1 -0
- package/es/core/components/SxpPageRender/Tagbar.js +2 -2
- package/es/core/components/SxpPageRender/index.js +7 -2
- package/es/materials/sxp/popup/CommodityDetail/index.js +4 -3
- package/es/materials/sxp/popup/CommodityDetailDiroNew/index.js +4 -3
- package/lib/core/components/SxpPageRender/ExpandableText.js +3 -1
- package/lib/core/components/SxpPageRender/Tagbar.d.ts +1 -0
- package/lib/core/components/SxpPageRender/Tagbar.js +2 -2
- package/lib/core/components/SxpPageRender/index.js +7 -2
- package/lib/materials/sxp/popup/CommodityDetail/index.js +4 -3
- package/lib/materials/sxp/popup/CommodityDetailDiroNew/index.js +4 -3
- package/package.json +1 -1
package/dist/pb-ui.js
CHANGED
@@ -8601,7 +8601,7 @@
|
|
8601
8601
|
* @Author: binruan@chatlabs.com
|
8602
8602
|
* @Date: 2023-12-26 16:11:34
|
8603
8603
|
* @LastEditors: binruan@chatlabs.com
|
8604
|
-
* @LastEditTime: 2024-06-
|
8604
|
+
* @LastEditTime: 2024-06-28 15:17:10
|
8605
8605
|
* @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\ExpandableText.tsx
|
8606
8606
|
*
|
8607
8607
|
*/
|
@@ -8656,7 +8656,9 @@
|
|
8656
8656
|
wordBreak: 'break-word'
|
8657
8657
|
}, dangerouslySetInnerHTML: { __html: setFontForText(text === null || text === void 0 ? void 0 : text.replace(/\n/g, '</br>'), style) } }),
|
8658
8658
|
React.createElement("div", { ref: multiRowCopy, dangerouslySetInnerHTML: { __html: setFontForText(text === null || text === void 0 ? void 0 : text.replace(/\n/g, '</br>'), style) } }),
|
8659
|
-
text && isPost && isShow && (React.createElement("span", { style: { textDecoration: 'underline', cursor: 'pointer' }, onClick: onClick !== null && onClick !== void 0 ? onClick : handleClick
|
8659
|
+
text && isPost && isShow && (React.createElement("span", { style: { textDecoration: 'underline', cursor: 'pointer' }, onClick: onClick !== null && onClick !== void 0 ? onClick : handleClick, dangerouslySetInnerHTML: {
|
8660
|
+
__html: setFontForText(isShowMore ? unfoldText || 'show less' : foldText || 'show more', style)
|
8661
|
+
} }))));
|
8660
8662
|
};
|
8661
8663
|
var ExpandableText$1 = React.memo(ExpandableText);
|
8662
8664
|
|
@@ -8786,9 +8788,10 @@
|
|
8786
8788
|
};
|
8787
8789
|
const renderBtn = () => {
|
8788
8790
|
var _a, _b;
|
8789
|
-
return (React.createElement(React.Fragment, null, (isDefault || (product === null || product === void 0 ? void 0 : product.link)) && (React.createElement("button", { "aria-label": (_a = cta === null || cta === void 0 ? void 0 : cta.enTitle) !== null && _a !== void 0 ? _a : 'Purchase on Website', onClick: handleLink, className: 'pb-commondity-btn', style: buttonStyle,
|
8790
|
-
|
8791
|
-
|
8791
|
+
return (React.createElement(React.Fragment, null, (isDefault || (product === null || product === void 0 ? void 0 : product.link)) && (React.createElement("button", { "aria-label": (_a = cta === null || cta === void 0 ? void 0 : cta.enTitle) !== null && _a !== void 0 ? _a : 'Purchase on Website', onClick: handleLink, className: 'pb-commondity-btn', style: buttonStyle },
|
8792
|
+
React.createElement("span", { dangerouslySetInnerHTML: {
|
8793
|
+
__html: setFontForText((_b = cta === null || cta === void 0 ? void 0 : cta.enTitle) !== null && _b !== void 0 ? _b : 'Purchase on Website', buttonStyle)
|
8794
|
+
} })))));
|
8792
8795
|
};
|
8793
8796
|
const getStyle = React.useCallback((style) => {
|
8794
8797
|
if (style === null || style === void 0 ? void 0 : style.lineClamp) {
|
@@ -9417,9 +9420,10 @@ Made in Italy` })));
|
|
9417
9420
|
React.createElement("div", { className: 'pb-commondityDiroNew-content-top-right-price', hidden: !!product && !(product === null || product === void 0 ? void 0 : product.taxInfo), style: getStyle(commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.taxInfo), dangerouslySetInnerHTML: {
|
9418
9421
|
__html: setFontForText((_m = product === null || product === void 0 ? void 0 : product.taxInfo) !== null && _m !== void 0 ? _m : '税费', commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.taxInfo)
|
9419
9422
|
} }))),
|
9420
|
-
(!product || (product === null || product === void 0 ? void 0 : product.link)) && (React.createElement("button", { "aria-label": (_o = cta === null || cta === void 0 ? void 0 : cta.enTitle) !== null && _o !== void 0 ? _o : 'Shop now', onClick: handleLink, className: 'pb-commondityDiroNew-btn', style: buttonStyle,
|
9421
|
-
|
9422
|
-
|
9423
|
+
(!product || (product === null || product === void 0 ? void 0 : product.link)) && (React.createElement("button", { "aria-label": (_o = cta === null || cta === void 0 ? void 0 : cta.enTitle) !== null && _o !== void 0 ? _o : 'Shop now', onClick: handleLink, className: 'pb-commondityDiroNew-btn', style: buttonStyle },
|
9424
|
+
React.createElement("span", { dangerouslySetInnerHTML: {
|
9425
|
+
__html: setFontForText((_p = cta === null || cta === void 0 ? void 0 : cta.enTitle) !== null && _p !== void 0 ? _p : 'Shop now', buttonStyle)
|
9426
|
+
} }))),
|
9423
9427
|
productInfoText({ isPost }))),
|
9424
9428
|
React.createElement(Modal$1, { visible: showModal, onClose: () => setShowModal(false) }, productInfoText({ isPost: false }))));
|
9425
9429
|
};
|
@@ -13727,11 +13731,11 @@ Made in Italy` })));
|
|
13727
13731
|
* @Author: binruan@chatlabs.com
|
13728
13732
|
* @Date: 2024-04-29 16:32:21
|
13729
13733
|
* @LastEditors: binruan@chatlabs.com
|
13730
|
-
* @LastEditTime: 2024-06-
|
13734
|
+
* @LastEditTime: 2024-06-28 18:03:50
|
13731
13735
|
* @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\Tagbar.tsx
|
13732
13736
|
*
|
13733
13737
|
*/
|
13734
|
-
const Tagbar = ({ tagList = [], setActiveIndex }) => {
|
13738
|
+
const Tagbar = ({ tagList = [], setActiveIndex, style }) => {
|
13735
13739
|
const { getRecommendVideos, setRtcList, setCacheRtcList, setCacheActiveIndex, setLoading, swiperRef, waterFallData, bffEventReport, selectTag, setSelectTag } = useSxpDataSource();
|
13736
13740
|
const { backMainFeed } = useEventReport();
|
13737
13741
|
const realTagList = React.useMemo(() => {
|
@@ -13772,7 +13776,7 @@ Made in Italy` })));
|
|
13772
13776
|
};
|
13773
13777
|
if (waterFallData || tagList.length <= 0)
|
13774
13778
|
return null;
|
13775
|
-
return (React.createElement("div", { className: 'clc-sxp-tagbar' },
|
13779
|
+
return (React.createElement("div", { className: 'clc-sxp-tagbar', style: style },
|
13776
13780
|
React.createElement("ul", { className: 'clc-sxp-tagbar-list', style: { margin: 'auto', gap: 24 } }, realTagList.map((tag) => {
|
13777
13781
|
return (React.createElement("li", { className: `clc-sxp-tagbar-list-item ${tag === selectTag ? 'clc-sxp-tagbar-list-item-active' : ''}`, key: tag, onClick: handleSelectTag(tag) }, tag));
|
13778
13782
|
}))));
|
@@ -13783,7 +13787,7 @@ Made in Italy` })));
|
|
13783
13787
|
* @Author: binruan@chatlabs.com
|
13784
13788
|
* @Date: 2024-01-15 19:03:09
|
13785
13789
|
* @LastEditors: binruan@chatlabs.com
|
13786
|
-
* @LastEditTime: 2024-06-
|
13790
|
+
* @LastEditTime: 2024-06-28 14:53:42
|
13787
13791
|
* @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\index.tsx
|
13788
13792
|
*
|
13789
13793
|
*/
|
@@ -13937,11 +13941,14 @@ Made in Italy` })));
|
|
13937
13941
|
}
|
13938
13942
|
return h;
|
13939
13943
|
}, [tagList, waterFallData]);
|
13940
|
-
const
|
13944
|
+
const minusHeight = React.useMemo(() => {
|
13941
13945
|
let minusHeight = 0;
|
13942
13946
|
if ((globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.logoUrl) && (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.isShowLogo)) {
|
13943
13947
|
minusHeight += 45;
|
13944
13948
|
}
|
13949
|
+
return minusHeight;
|
13950
|
+
}, []);
|
13951
|
+
const height = React.useMemo(() => {
|
13945
13952
|
return containerHeight - minusHeight - tagHeight;
|
13946
13953
|
}, [globalConfig, containerHeight, tagHeight]);
|
13947
13954
|
const renderLogo = React.useMemo(() => {
|
@@ -14178,7 +14185,9 @@ Made in Italy` })));
|
|
14178
14185
|
setOpenHashtag === null || setOpenHashtag === void 0 ? void 0 : setOpenHashtag(true);
|
14179
14186
|
} })),
|
14180
14187
|
renderLogo,
|
14181
|
-
React.createElement(Tagbar$1, { tagList: tagList, setActiveIndex: setActiveIndex
|
14188
|
+
React.createElement(Tagbar$1, { tagList: tagList, setActiveIndex: setActiveIndex, style: {
|
14189
|
+
top: minusHeight
|
14190
|
+
} }),
|
14182
14191
|
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,
|
14183
14192
|
React.createElement(Swiper, { style: {
|
14184
14193
|
marginTop: tagHeight
|