pb-sxp-ui 1.15.8 → 1.15.10
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 +35 -16
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +35 -16
- package/dist/index.js.map +1 -1
- package/dist/index.min.cjs +6 -6
- package/dist/index.min.cjs.map +1 -1
- package/dist/index.min.js +6 -6
- package/dist/index.min.js.map +1 -1
- package/dist/pb-ui.js +35 -16
- package/dist/pb-ui.js.map +1 -1
- package/dist/pb-ui.min.js +6 -6
- package/dist/pb-ui.min.js.map +1 -1
- package/es/core/components/SxpPageRender/WaterFall/List.js +3 -3
- package/es/core/components/SxpPageRender/WaterFall/index.js +2 -2
- package/es/core/context/SxpDataSourceProvider.js +19 -2
- package/es/materials/sxp/HashTag/index.d.ts +2 -4
- package/es/materials/sxp/HashTag/material.js +2 -1
- package/es/materials/sxp/HashTag/settingRender.js +1 -1
- package/es/materials/sxp/consentPopup/Click/material.js +1 -1
- package/es/materials/sxp/consentPopup/Swipe/material.js +1 -1
- package/lib/core/components/SxpPageRender/WaterFall/List.js +3 -3
- package/lib/core/components/SxpPageRender/WaterFall/index.js +2 -2
- package/lib/core/context/SxpDataSourceProvider.js +19 -2
- package/lib/materials/sxp/HashTag/index.d.ts +2 -4
- package/lib/materials/sxp/HashTag/material.js +2 -1
- package/lib/materials/sxp/HashTag/settingRender.js +1 -1
- package/lib/materials/sxp/consentPopup/Click/material.js +1 -1
- package/lib/materials/sxp/consentPopup/Swipe/material.js +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
@@ -759,6 +759,24 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
|
|
759
759
|
.then((res) => res.json())
|
760
760
|
.catch((err) => Promise.reject(err));
|
761
761
|
}, [bffDataSource, fakeUserId]);
|
762
|
+
// bff API admin 请求方法
|
763
|
+
const bffFetchAdmin = React.useCallback((path, options) => {
|
764
|
+
if (!bffDataSource)
|
765
|
+
return;
|
766
|
+
const url = bffDataSource.url;
|
767
|
+
if (options === null || options === void 0 ? void 0 : options.query) {
|
768
|
+
const queryString = qs.stringify(options.query);
|
769
|
+
path = `${path}?${queryString}`;
|
770
|
+
}
|
771
|
+
return window
|
772
|
+
.fetch(`${url}/admin/${path}`, {
|
773
|
+
headers: Object.assign({ 'Content-Type': 'application/json' }, bffDataSource.headers),
|
774
|
+
method: options.method,
|
775
|
+
body: JSON.stringify(options.body)
|
776
|
+
})
|
777
|
+
.then((res) => res.json())
|
778
|
+
.catch((err) => Promise.reject(err));
|
779
|
+
}, [bffDataSource]);
|
762
780
|
// 获取推荐视频数据
|
763
781
|
const getRecommendVideos = React.useCallback((query) => __awaiter(void 0, void 0, void 0, function* () {
|
764
782
|
var _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u;
|
@@ -787,7 +805,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
|
|
787
805
|
const recurveRecList = (query) => __awaiter(void 0, void 0, void 0, function* () {
|
788
806
|
var _v, _w, _x, _y, _z, _0;
|
789
807
|
query.pageNum = pageNum;
|
790
|
-
result = yield (
|
808
|
+
result = yield (bffFetchAdmin === null || bffFetchAdmin === void 0 ? void 0 : bffFetchAdmin('recommend/direct_page', { method: 'POST', body: query }));
|
791
809
|
if (!(result === null || result === void 0 ? void 0 : result.success)) {
|
792
810
|
return undefined;
|
793
811
|
}
|
@@ -827,7 +845,7 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
|
|
827
845
|
return Object.assign(Object.assign({}, result.data), { recList: list });
|
828
846
|
}
|
829
847
|
return result === null || result === void 0 ? void 0 : result.data;
|
830
|
-
}), [bffFetch, utmVal, maxSize, defaultSize, channelQueryList, channel, chatlabsId]);
|
848
|
+
}), [bffFetch, utmVal, maxSize, defaultSize, channelQueryList, channel, chatlabsId, bffFetchAdmin]);
|
831
849
|
const loadVideos = React.useCallback((pageNum) => __awaiter(void 0, void 0, void 0, function* () {
|
832
850
|
var _1, _2, _3, _4;
|
833
851
|
if (rtcList.length <= 0) {
|
@@ -13360,7 +13378,7 @@ const MultiCommodityDiroNew = createMaterial(MultiCommodityDiroNewComponent, {
|
|
13360
13378
|
* @Author: binruan@chatlabs.com
|
13361
13379
|
* @Date: 2024-04-07 14:07:12
|
13362
13380
|
* @LastEditors: binruan@chatlabs.com
|
13363
|
-
* @LastEditTime: 2025-02-
|
13381
|
+
* @LastEditTime: 2025-02-28 09:49:43
|
13364
13382
|
* @FilePath: \pb-sxp-ui\src\materials\sxp\HashTag\settingRender.tsx
|
13365
13383
|
*
|
13366
13384
|
*/
|
@@ -13387,7 +13405,7 @@ var settingRender$7 = [
|
|
13387
13405
|
{
|
13388
13406
|
type: 'HashTagFixedSize',
|
13389
13407
|
label: '固定宽高',
|
13390
|
-
name: ['props'
|
13408
|
+
name: ['props']
|
13391
13409
|
}
|
13392
13410
|
]
|
13393
13411
|
},
|
@@ -15195,7 +15213,7 @@ var img$6 = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeA
|
|
15195
15213
|
|
15196
15214
|
const WaterfallFlowItem = (props) => {
|
15197
15215
|
var _a;
|
15198
|
-
const { rec, index, list, reportTagsView, textStyles, space, openFixedSize } = props;
|
15216
|
+
const { rec, index, list, reportTagsView, textStyles, space, openFixedSize, fixedSizeRatio } = props;
|
15199
15217
|
const { swiperRef, setRtcList, setOpenHashtag, sxpParameter, globalConfig } = useSxpDataSource();
|
15200
15218
|
const [showVideo, setShowVideo] = React.useState(false);
|
15201
15219
|
const imgDom = React.useRef(null);
|
@@ -15304,11 +15322,11 @@ const WaterfallFlowItem = (props) => {
|
|
15304
15322
|
}, 0);
|
15305
15323
|
};
|
15306
15324
|
return (React.createElement("div", { ref: ref, className: 'list-content-listItem', key: index, onClick: handleClickToDetail, style: { marginBottom: space } },
|
15307
|
-
React.createElement("div", { className:
|
15325
|
+
React.createElement("div", { className: fixedSizeRatio === '1' ? 'list-content-listItem-picture' : 'list-content-listItem-picture1609' },
|
15308
15326
|
showVideo && (React.createElement("div", { style: { display: 'none' } },
|
15309
15327
|
React.createElement("video", { ref: videoDom, crossOrigin: 'anonymous', className: 'list-content-listItem-picture-img' }),
|
15310
15328
|
React.createElement("canvas", { ref: canvasRef }))),
|
15311
|
-
React.createElement(FormatImage$1, { loading: 'lazy', className:
|
15329
|
+
React.createElement(FormatImage$1, { loading: 'lazy', className: fixedSizeRatio === '1' ? 'list-content-listItem-picture-img' : 'list-content-listItem-picture1609-img', ref: imgDom })),
|
15312
15330
|
React.createElement("div", { className: 'list-content-listItem-info' },
|
15313
15331
|
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, dangerouslySetInnerHTML: {
|
15314
15332
|
__html: setFontForText(title, textStyles === null || textStyles === void 0 ? void 0 : textStyles.title)
|
@@ -15419,12 +15437,12 @@ function WaterfallList(_a) {
|
|
15419
15437
|
* @Author: binruan@chatlabs.com
|
15420
15438
|
* @Date: 2024-01-10 10:58:24
|
15421
15439
|
* @LastEditors: binruan@chatlabs.com
|
15422
|
-
* @LastEditTime: 2025-02-
|
15440
|
+
* @LastEditTime: 2025-02-28 10:00:31
|
15423
15441
|
* @FilePath: \pb-sxp-ui\src\core\components\SxpPageRender\WaterFall\index.tsx
|
15424
15442
|
*
|
15425
15443
|
*/
|
15426
15444
|
const WaterFall = (props) => {
|
15427
|
-
var _a
|
15445
|
+
var _a;
|
15428
15446
|
const { waterFallData, setOpenHashtag, openHashtag, swiperRef, setWaterFallData, cacheRtcList, setRtcList, cacheActiveIndex, rtcList, setCacheRtcList, setIsFromHashtag, isFromHashtag, bffEventReport, themeTag, selectTag, bffFbReport } = useSxpDataSource();
|
15429
15447
|
const { backMainFeed } = useEventReport();
|
15430
15448
|
const modalEleRef = React.useRef(null);
|
@@ -15513,7 +15531,7 @@ const WaterFall = (props) => {
|
|
15513
15531
|
display: openHashtag ? 'block' : 'none'
|
15514
15532
|
} },
|
15515
15533
|
React.createElement(Navbar$1, { icon: img$6, styles: { top: '32px' }, textStyle: (_a = props === null || props === void 0 ? void 0 : props.textStyles) === null || _a === void 0 ? void 0 : _a.hashTagTitle, onClose: handleClose }),
|
15516
|
-
(
|
15534
|
+
(props === null || props === void 0 ? void 0 : props.openFixedSize) || (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);
|
15517
15535
|
};
|
15518
15536
|
var WaterFall$1 = React.memo(WaterFall);
|
15519
15537
|
|
@@ -15521,7 +15539,7 @@ var WaterFall$1 = React.memo(WaterFall);
|
|
15521
15539
|
* @Author: binruan@chatlabs.com
|
15522
15540
|
* @Date: 2024-01-15 19:03:09
|
15523
15541
|
* @LastEditors: binruan@chatlabs.com
|
15524
|
-
* @LastEditTime: 2025-02-
|
15542
|
+
* @LastEditTime: 2025-02-28 09:59:36
|
15525
15543
|
* @FilePath: \pb-sxp-ui\src\materials\sxp\HashTag\index.tsx
|
15526
15544
|
*
|
15527
15545
|
*/
|
@@ -15594,7 +15612,8 @@ const HashTag = createMaterial(HashTagComponent, {
|
|
15594
15612
|
paddingRight: 20,
|
15595
15613
|
paddingBottom: 20
|
15596
15614
|
},
|
15597
|
-
openFixedSize:
|
15615
|
+
openFixedSize: true,
|
15616
|
+
fixedSizeRatio: '1'
|
15598
15617
|
}
|
15599
15618
|
},
|
15600
15619
|
w: 100,
|
@@ -16970,7 +16989,7 @@ var ClickComponent = React.memo(Click$1);
|
|
16970
16989
|
* @Author: binruan@chatlabs.com
|
16971
16990
|
* @Date: 2025-01-14 16:22:35
|
16972
16991
|
* @LastEditors: binruan@chatlabs.com
|
16973
|
-
* @LastEditTime: 2025-
|
16992
|
+
* @LastEditTime: 2025-02-26 11:44:00
|
16974
16993
|
* @FilePath: \pb-sxp-ui\src\materials\sxp\consentPopup\Click\material.tsx
|
16975
16994
|
*
|
16976
16995
|
*/
|
@@ -16985,7 +17004,7 @@ const Click = createMaterial(ClickComponent, {
|
|
16985
17004
|
},
|
16986
17005
|
defaulSetting: {
|
16987
17006
|
props: {
|
16988
|
-
content: '<p><strong><span style="font-size:14px"><span style="line-height:3">Your Cookie Preferences</span></span></strong></p><p>We use cookie, including third-party cookies, to ensure the proper functioning and security of this site, to analyse its use, and to show you personalised content. You can authorise the use of all cookies by clicking on "Accept all cookies". If you click on "Reject all cookies", we will only use cookies necessary for the proper functioning and security of this site. To personalise on adjust your preferences at any time, click on "Cookies Settings" below or at the bottom of any Fendi.com webpage. For more information, read our Cookie Policy.</p><p></p>',
|
17007
|
+
content: '<p><strong><span style="font-size:14px"><span style="line-height:3">Your Cookie Preferences</span></span></strong></p><p><span style="font-size:13px"><span style="line-height:1.7">We use cookie, including third-party cookies, to ensure the proper functioning and security of this site, to analyse its use, and to show you personalised content. You can authorise the use of all cookies by clicking on "Accept all cookies". If you click on "Reject all cookies", we will only use cookies necessary for the proper functioning and security of this site. To personalise on adjust your preferences at any time, click on "Cookies Settings" below or at the bottom of any Fendi.com webpage. For more information, read our Cookie Policy.</span></span></p><p></p>',
|
16989
17008
|
acceptButton: {
|
16990
17009
|
text: 'Accept all cookies',
|
16991
17010
|
style: {
|
@@ -17131,7 +17150,7 @@ var SwipeComponent = React.memo(Swipe$1);
|
|
17131
17150
|
* @Author: binruan@chatlabs.com
|
17132
17151
|
* @Date: 2025-01-14 16:22:35
|
17133
17152
|
* @LastEditors: binruan@chatlabs.com
|
17134
|
-
* @LastEditTime: 2025-02-
|
17153
|
+
* @LastEditTime: 2025-02-26 11:39:59
|
17135
17154
|
* @FilePath: \pb-sxp-ui\src\materials\sxp\consentPopup\Swipe\material.tsx
|
17136
17155
|
*
|
17137
17156
|
*/
|
@@ -17146,7 +17165,7 @@ const Swipe = createMaterial(SwipeComponent, {
|
|
17146
17165
|
},
|
17147
17166
|
defaulSetting: {
|
17148
17167
|
props: {
|
17149
|
-
content: '<p><span style="font-
|
17168
|
+
content: '<p><strong><span style="font-size:18px"><span style="line-height:1.7">Your Cookie Preferences</span></span></strong></p><p><span style="line-height:1.7"><span style="font-size:13px">We use cookie, including third-party cookies, to ensure the proper functioning and security of this site, to analyse its use, and to show you personalised content. You can authorise the use of all cookies by clicking on 'Accept all cookies'. If you click on 'Reject all cookies', we will only use cookies necessary for the proper functioning and security of this site. To personalise or adjust your preferences at any time, click on 'Cookies Settings' below or at the bottom of any Fendi.com webpage. For more information, <u>read our Cookie Policy</u>.</span></span></p>'
|
17150
17169
|
},
|
17151
17170
|
style: {
|
17152
17171
|
backgroundColor: '#fff',
|