pb-sxp-ui 1.0.61 → 1.0.63
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/LICENSE +21 -21
- package/README.md +111 -111
- package/dist/index.cjs +44 -24
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +44 -24
- 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 +47 -27
- 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/Tagbar.js +4 -2
- package/es/core/components/SxpPageRender/index.js +4 -1
- package/es/core/context/SxpDataSourceProvider.js +22 -5
- package/es/core/utils/event.d.ts +2 -1
- package/es/core/utils/event.js +1 -0
- package/es/materials/sxp/popup/CommodityDetail/index.js +4 -4
- package/es/materials/sxp/popup/CommodityDetailDiroNew/index.js +1 -1
- package/es/materials/sxp/template/components/EventProvider.js +2 -3
- package/lib/core/components/SxpPageRender/Tagbar.js +4 -2
- package/lib/core/components/SxpPageRender/index.js +4 -1
- package/lib/core/context/SxpDataSourceProvider.js +22 -5
- package/lib/core/utils/event.d.ts +2 -1
- package/lib/core/utils/event.js +1 -0
- package/lib/materials/sxp/popup/CommodityDetail/index.js +4 -4
- package/lib/materials/sxp/popup/CommodityDetailDiroNew/index.js +1 -1
- package/lib/materials/sxp/template/components/EventProvider.js +2 -3
- package/package.json +115 -115
package/LICENSE
CHANGED
@@ -1,21 +1,21 @@
|
|
1
|
-
MIT License
|
2
|
-
|
3
|
-
Copyright (c) 2023 ChatLabs
|
4
|
-
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
7
|
-
in the Software without restriction, including without limitation the rights
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
10
|
-
furnished to do so, subject to the following conditions:
|
11
|
-
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
13
|
-
copies or substantial portions of the Software.
|
14
|
-
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
21
|
-
SOFTWARE.
|
1
|
+
MIT License
|
2
|
+
|
3
|
+
Copyright (c) 2023 ChatLabs
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
13
|
+
copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
@@ -1,111 +1,111 @@
|
|
1
|
-
<!--
|
2
|
-
* @Author : haocanweng@chatlabs.cn
|
3
|
-
* @Date : 2023-08-23 18:25:31
|
4
|
-
* @LastEditors: binruan@chatlabs.com
|
5
|
-
* @LastEditTime: 2024-03-20 16:26:29
|
6
|
-
* @FilePath: \pb-sxp-ui\README.md
|
7
|
-
-->
|
8
|
-
<h1 align="center">Page Builder SXP UI</h1>
|
9
|
-
|
10
|
-
<div align="center">
|
11
|
-
React enterprise-class UI components
|
12
|
-
</div>
|
13
|
-
|
14
|
-
## 📦 安装
|
15
|
-
|
16
|
-
```bash
|
17
|
-
npm install pb-sxp-ui
|
18
|
-
# or
|
19
|
-
yarn add pb-sxp-ui
|
20
|
-
```
|
21
|
-
|
22
|
-
## 🔨 使用
|
23
|
-
以 Next.js 框架为例子:
|
24
|
-
|
25
|
-
```jsx
|
26
|
-
import { GetServerSideProps } from 'next';
|
27
|
-
import React, { FC } from 'react'
|
28
|
-
import Pagebuilder, { PageView } from 'pb-sxp-ui';
|
29
|
-
|
30
|
-
// 初始化 PageBuilder 配置
|
31
|
-
Pagebuilder.init({
|
32
|
-
tenantId: 'xxxxxxxxxx',
|
33
|
-
appId: 'xxxxxxxxx',
|
34
|
-
env: 'live' // 可选参数,默认是 live 环境
|
35
|
-
});
|
36
|
-
|
37
|
-
|
38
|
-
interface IProps {
|
39
|
-
path: string;
|
40
|
-
data: any
|
41
|
-
}
|
42
|
-
|
43
|
-
const ContentPage: FC<IProps> = ({ data ,path}) => {
|
44
|
-
return (
|
45
|
-
<PageView data={data?.data} isSsr path={path}/>
|
46
|
-
)
|
47
|
-
}
|
48
|
-
|
49
|
-
export const getServerSideProps: GetServerSideProps<IProps> = async (
|
50
|
-
context
|
51
|
-
) => {
|
52
|
-
// 接收传来的路径
|
53
|
-
const path = context.query.path as string;
|
54
|
-
// 获取页面数据
|
55
|
-
const result = await Pagebuilder.getDetail(path)
|
56
|
-
return {
|
57
|
-
props: {
|
58
|
-
path,
|
59
|
-
data: result.data
|
60
|
-
},
|
61
|
-
};
|
62
|
-
};
|
63
|
-
|
64
|
-
export default ContentPage;
|
65
|
-
|
66
|
-
```
|
67
|
-
|
68
|
-
## ⌨️ 本地调试
|
69
|
-
|
70
|
-
### 运行开发环境
|
71
|
-
|
72
|
-
```bash
|
73
|
-
$ npm install
|
74
|
-
$ npm run start
|
75
|
-
```
|
76
|
-
|
77
|
-
### 生成本地开发全局链接
|
78
|
-
|
79
|
-
```bash
|
80
|
-
npm link
|
81
|
-
# or
|
82
|
-
yarn link
|
83
|
-
```
|
84
|
-
|
85
|
-
### 在使用该包的项目中安装调试
|
86
|
-
|
87
|
-
```bash
|
88
|
-
npm link pb-sxp-ui
|
89
|
-
# or
|
90
|
-
yarn link pb-sxp-ui
|
91
|
-
```
|
92
|
-
|
93
|
-
## 👾 发布
|
94
|
-
|
95
|
-
### 打包线上安装包
|
96
|
-
|
97
|
-
```bash
|
98
|
-
npm run package
|
99
|
-
# or
|
100
|
-
yarn package
|
101
|
-
```
|
102
|
-
|
103
|
-
### 发布 npm
|
104
|
-
|
105
|
-
```bash
|
106
|
-
$ npm version patch|minor|major
|
107
|
-
$ npm publish
|
108
|
-
|
109
|
-
# 自动化发布包
|
110
|
-
$ npm run pub patch|minor|major|xx.xx.xx
|
111
|
-
```
|
1
|
+
<!--
|
2
|
+
* @Author : haocanweng@chatlabs.cn
|
3
|
+
* @Date : 2023-08-23 18:25:31
|
4
|
+
* @LastEditors: binruan@chatlabs.com
|
5
|
+
* @LastEditTime: 2024-03-20 16:26:29
|
6
|
+
* @FilePath: \pb-sxp-ui\README.md
|
7
|
+
-->
|
8
|
+
<h1 align="center">Page Builder SXP UI</h1>
|
9
|
+
|
10
|
+
<div align="center">
|
11
|
+
React enterprise-class UI components
|
12
|
+
</div>
|
13
|
+
|
14
|
+
## 📦 安装
|
15
|
+
|
16
|
+
```bash
|
17
|
+
npm install pb-sxp-ui
|
18
|
+
# or
|
19
|
+
yarn add pb-sxp-ui
|
20
|
+
```
|
21
|
+
|
22
|
+
## 🔨 使用
|
23
|
+
以 Next.js 框架为例子:
|
24
|
+
|
25
|
+
```jsx
|
26
|
+
import { GetServerSideProps } from 'next';
|
27
|
+
import React, { FC } from 'react'
|
28
|
+
import Pagebuilder, { PageView } from 'pb-sxp-ui';
|
29
|
+
|
30
|
+
// 初始化 PageBuilder 配置
|
31
|
+
Pagebuilder.init({
|
32
|
+
tenantId: 'xxxxxxxxxx',
|
33
|
+
appId: 'xxxxxxxxx',
|
34
|
+
env: 'live' // 可选参数,默认是 live 环境
|
35
|
+
});
|
36
|
+
|
37
|
+
|
38
|
+
interface IProps {
|
39
|
+
path: string;
|
40
|
+
data: any
|
41
|
+
}
|
42
|
+
|
43
|
+
const ContentPage: FC<IProps> = ({ data ,path}) => {
|
44
|
+
return (
|
45
|
+
<PageView data={data?.data} isSsr path={path}/>
|
46
|
+
)
|
47
|
+
}
|
48
|
+
|
49
|
+
export const getServerSideProps: GetServerSideProps<IProps> = async (
|
50
|
+
context
|
51
|
+
) => {
|
52
|
+
// 接收传来的路径
|
53
|
+
const path = context.query.path as string;
|
54
|
+
// 获取页面数据
|
55
|
+
const result = await Pagebuilder.getDetail(path)
|
56
|
+
return {
|
57
|
+
props: {
|
58
|
+
path,
|
59
|
+
data: result.data
|
60
|
+
},
|
61
|
+
};
|
62
|
+
};
|
63
|
+
|
64
|
+
export default ContentPage;
|
65
|
+
|
66
|
+
```
|
67
|
+
|
68
|
+
## ⌨️ 本地调试
|
69
|
+
|
70
|
+
### 运行开发环境
|
71
|
+
|
72
|
+
```bash
|
73
|
+
$ npm install
|
74
|
+
$ npm run start
|
75
|
+
```
|
76
|
+
|
77
|
+
### 生成本地开发全局链接
|
78
|
+
|
79
|
+
```bash
|
80
|
+
npm link
|
81
|
+
# or
|
82
|
+
yarn link
|
83
|
+
```
|
84
|
+
|
85
|
+
### 在使用该包的项目中安装调试
|
86
|
+
|
87
|
+
```bash
|
88
|
+
npm link pb-sxp-ui
|
89
|
+
# or
|
90
|
+
yarn link pb-sxp-ui
|
91
|
+
```
|
92
|
+
|
93
|
+
## 👾 发布
|
94
|
+
|
95
|
+
### 打包线上安装包
|
96
|
+
|
97
|
+
```bash
|
98
|
+
npm run package
|
99
|
+
# or
|
100
|
+
yarn package
|
101
|
+
```
|
102
|
+
|
103
|
+
### 发布 npm
|
104
|
+
|
105
|
+
```bash
|
106
|
+
$ npm version patch|minor|major
|
107
|
+
$ npm publish
|
108
|
+
|
109
|
+
# 自动化发布包
|
110
|
+
$ npm run pub patch|minor|major|xx.xx.xx
|
111
|
+
```
|
package/dist/index.cjs
CHANGED
@@ -7,10 +7,10 @@ var uuid$1 = require('uuid');
|
|
7
7
|
var pako = require('pako');
|
8
8
|
var React = require('react');
|
9
9
|
var qs = require('qs');
|
10
|
+
var EventEmitter = require('eventemitter3');
|
10
11
|
var css = require('@emotion/css');
|
11
12
|
var proComponents = require('@ant-design/pro-components');
|
12
13
|
var ReactDOM = require('react-dom');
|
13
|
-
var EventEmitter = require('eventemitter3');
|
14
14
|
var Hls = require('hls.js');
|
15
15
|
|
16
16
|
function _interopNamespaceDefault(e) {
|
@@ -430,6 +430,14 @@ function useIconLink(path, domain) {
|
|
430
430
|
}, [appDomain, path, domain]);
|
431
431
|
}
|
432
432
|
|
433
|
+
const SXP_EVENT_BUS = new EventEmitter();
|
434
|
+
var SXP_EVENT_TYPE;
|
435
|
+
(function (SXP_EVENT_TYPE) {
|
436
|
+
SXP_EVENT_TYPE["PAGE_DID_SHOW"] = "pageDidShow";
|
437
|
+
SXP_EVENT_TYPE["PAGE_DID_HIDE"] = "pageDidHide";
|
438
|
+
SXP_EVENT_TYPE["CHANGE_THEME_TAG"] = "changeThemeTag";
|
439
|
+
})(SXP_EVENT_TYPE || (SXP_EVENT_TYPE = {}));
|
440
|
+
|
433
441
|
const SxpDataSourceContext = React.createContext({
|
434
442
|
rtcList: [],
|
435
443
|
tagList: []
|
@@ -454,6 +462,16 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
|
|
454
462
|
const [cacheActiveIndex, setCacheActiveIndex] = React.useState(0);
|
455
463
|
const [isFromHashtag, setIsFromHashtag] = React.useState(false);
|
456
464
|
const [videoRef, setVideoRef] = React.useState(null);
|
465
|
+
const themeTag = React.useRef();
|
466
|
+
React.useEffect(() => {
|
467
|
+
const handleChangeThemeTag = (tag) => {
|
468
|
+
themeTag.current = tag;
|
469
|
+
};
|
470
|
+
SXP_EVENT_BUS.on(SXP_EVENT_TYPE.CHANGE_THEME_TAG, handleChangeThemeTag);
|
471
|
+
return () => {
|
472
|
+
SXP_EVENT_BUS.off(SXP_EVENT_TYPE.CHANGE_THEME_TAG, handleChangeThemeTag);
|
473
|
+
};
|
474
|
+
}, []);
|
457
475
|
React.useEffect(() => {
|
458
476
|
setOpenHashtag(isOpenHashTag);
|
459
477
|
}, [isOpenHashTag]);
|
@@ -496,7 +514,8 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
|
|
496
514
|
'itemFilter.itemId': query === null || query === void 0 ? void 0 : query['itemFilter.itemId'],
|
497
515
|
'itemFilter.itemType': query === null || query === void 0 ? void 0 : query['itemFilter.itemType'],
|
498
516
|
hashTag: query === null || query === void 0 ? void 0 : query.hashTag,
|
499
|
-
traceInfo: query === null || query === void 0 ? void 0 : query.traceInfo
|
517
|
+
traceInfo: query === null || query === void 0 ? void 0 : query.traceInfo,
|
518
|
+
themeTag: query === null || query === void 0 ? void 0 : query.themeTag
|
500
519
|
};
|
501
520
|
if (utmVal) {
|
502
521
|
const val = (_e = (_d = (_c = utmVal === null || utmVal === void 0 ? void 0 : utmVal.split('&')) === null || _c === void 0 ? void 0 : _c.filter((val) => {
|
@@ -521,7 +540,8 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
|
|
521
540
|
const data = yield getRecommendVideos({
|
522
541
|
hashTag: waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.hashTag,
|
523
542
|
'itemFilter.itemId': waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.itemId,
|
524
|
-
'itemFilter.itemType': waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.itemType
|
543
|
+
'itemFilter.itemType': waterFallData === null || waterFallData === void 0 ? void 0 : waterFallData.itemType,
|
544
|
+
themeTag: themeTag.current
|
525
545
|
});
|
526
546
|
setRtcList(rtcList.concat((_f = data === null || data === void 0 ? void 0 : data.recList) !== null && _f !== void 0 ? _f : []));
|
527
547
|
setCacheRtcList(cacheRtcList.concat((_g = data === null || data === void 0 ? void 0 : data.recList) !== null && _g !== void 0 ? _g : []));
|
@@ -580,12 +600,16 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
|
|
580
600
|
}), [bffFetch]);
|
581
601
|
// 获取 Tag
|
582
602
|
const bffGetTagList = React.useCallback(() => __awaiter(void 0, void 0, void 0, function* () {
|
583
|
-
var _h, _j;
|
603
|
+
var _h, _j, _k, _l, _m;
|
584
604
|
if (!utmVal)
|
585
605
|
return;
|
586
606
|
try {
|
587
|
-
const
|
588
|
-
|
607
|
+
const val = (_k = (_j = (_h = utmVal === null || utmVal === void 0 ? void 0 : utmVal.split('&')) === null || _h === void 0 ? void 0 : _h.filter((val) => {
|
608
|
+
const key = val.split('=')[0];
|
609
|
+
return UTM_KEYS.includes(key);
|
610
|
+
})) === null || _j === void 0 ? void 0 : _j.join('&')) !== null && _k !== void 0 ? _k : '';
|
611
|
+
const result = yield (bffFetch === null || bffFetch === void 0 ? void 0 : bffFetch('/tag/list', { method: 'GET', query: { channel: decodeURIComponent(val) } }));
|
612
|
+
setTagList((_m = (_l = result === null || result === void 0 ? void 0 : result.data) === null || _l === void 0 ? void 0 : _l.tags) !== null && _m !== void 0 ? _m : []);
|
589
613
|
}
|
590
614
|
catch (e) {
|
591
615
|
console.log('e', e);
|
@@ -8452,10 +8476,10 @@ const CommodityDetail$1 = (_a) => {
|
|
8452
8476
|
React.createElement("div", { className: 'pb-commondity-content-title', style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.title, hidden: !!product && !(product === null || product === void 0 ? void 0 : product.title) }, (_b = product === null || product === void 0 ? void 0 : product.title) !== null && _b !== void 0 ? _b : 'Pendant in Yellow Gold with Diamonds, Medium'),
|
8453
8477
|
React.createElement("div", { className: 'pb-commondity-content-price', style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.price, hidden: !!product && !(product === null || product === void 0 ? void 0 : product.price) }, priceText),
|
8454
8478
|
React.createElement("div", { hidden: !!product && (!(product === null || product === void 0 ? void 0 : product.info) || (product === null || product === void 0 ? void 0 : product.info) === '') },
|
8455
|
-
React.createElement(ExpandableText$1, { foldText: tipText === null || tipText === void 0 ? void 0 : tipText.foldText, unfoldText: tipText === null || tipText === void 0 ? void 0 : tipText.unfoldText, onClick: () => setShowModal(true), isPost: isPost, text: (_c = product === null || product === void 0 ? void 0 : product.info) !== null && _c !== void 0 ? _c : `The design inspiration of Tiffany Lock series comes from the power of connection and inclusiveness, and the
|
8456
|
-
bold and avant-garde visual design interprets the emotional bond connecting my heart. The Tiffany Lock
|
8457
|
-
collection is unisex and is inspired by the padlock pattern found in the Tiffany Antique Collection. This
|
8458
|
-
necklace features a stylish and eye-catching oval clasp chain decorated with a lock pattern. Crafted from
|
8479
|
+
React.createElement(ExpandableText$1, { foldText: tipText === null || tipText === void 0 ? void 0 : tipText.foldText, unfoldText: tipText === null || tipText === void 0 ? void 0 : tipText.unfoldText, onClick: () => setShowModal(true), isPost: isPost, text: (_c = product === null || product === void 0 ? void 0 : product.info) !== null && _c !== void 0 ? _c : `The design inspiration of Tiffany Lock series comes from the power of connection and inclusiveness, and the
|
8480
|
+
bold and avant-garde visual design interprets the emotional bond connecting my heart. The Tiffany Lock
|
8481
|
+
collection is unisex and is inspired by the padlock pattern found in the Tiffany Antique Collection. This
|
8482
|
+
necklace features a stylish and eye-catching oval clasp chain decorated with a lock pattern. Crafted from
|
8459
8483
|
18-karat gold, this necklace is embellished with hand-set diamonds.`, maxStr: 79, className: 'pb-commondity-content-info', style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.info }))));
|
8460
8484
|
};
|
8461
8485
|
const renderBtn = () => {
|
@@ -8925,7 +8949,7 @@ const CommodityDetailDiroNew$1 = (_a) => {
|
|
8925
8949
|
const productInfoText = ({ isPost }) => {
|
8926
8950
|
return (React.createElement("div", { hidden: !!product && (!(product === null || product === void 0 ? void 0 : product.info) || (product === null || product === void 0 ? void 0 : product.info) === '') },
|
8927
8951
|
React.createElement(ExpandableText$1, { isPost: isPost, onClick: () => setShowModal(true), className: 'pb-commondityDiroNew-info', style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.info, foldText: tipText === null || tipText === void 0 ? void 0 : tipText.foldText, unfoldText: tipText === null || tipText === void 0 ? void 0 : tipText.unfoldText, text: (product === null || product === void 0 ? void 0 : product.info) ||
|
8928
|
-
`Unveiled at the Spring-Summer 2023 fashion show, the Dior Toujours bag is distinguished by a casual and practical design. Crafted in black calfskin with Macrocannage topstitching, it showcases a spacious interior compartment with a matching pouch to organize essentials. Its leather strap closure keeps items secure while the D of the CD Lock closure twists to adjust the sides and enhance the bag's silhouette. The leather handles can be adjusted using the small notches in order to be able to carry the large bag by hand or wear it over the shoulder. CD Lock and strap closures D.I.O.R. charms Removable interior pouch Adjustable leather handles Dust bag included
|
8952
|
+
`Unveiled at the Spring-Summer 2023 fashion show, the Dior Toujours bag is distinguished by a casual and practical design. Crafted in black calfskin with Macrocannage topstitching, it showcases a spacious interior compartment with a matching pouch to organize essentials. Its leather strap closure keeps items secure while the D of the CD Lock closure twists to adjust the sides and enhance the bag's silhouette. The leather handles can be adjusted using the small notches in order to be able to carry the large bag by hand or wear it over the shoulder. CD Lock and strap closures D.I.O.R. charms Removable interior pouch Adjustable leather handles Dust bag included
|
8929
8953
|
Made in Italy` })));
|
8930
8954
|
};
|
8931
8955
|
return (React.createElement("div", { className: 'pb-commondityDiroNew' },
|
@@ -9325,7 +9349,7 @@ const EventProvider = (_a) => {
|
|
9325
9349
|
}
|
9326
9350
|
}, [isOnScreen, ref, rec, ctaEvent, index]);
|
9327
9351
|
const handleClick = lodash.throttle(() => {
|
9328
|
-
var _a, _b, _c, _d, _e, _f, _g, _h
|
9352
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
9329
9353
|
const item = (_b = (_a = rec === null || rec === void 0 ? void 0 : rec.video) === null || _a === void 0 ? void 0 : _a.bindProduct) !== null && _b !== void 0 ? _b : rec === null || rec === void 0 ? void 0 : rec.video;
|
9330
9354
|
ctaEvent === null || ctaEvent === void 0 ? void 0 : ctaEvent({
|
9331
9355
|
eventSubject: 'clickCta',
|
@@ -9337,8 +9361,7 @@ const EventProvider = (_a) => {
|
|
9337
9361
|
const cta = (_e = rec === null || rec === void 0 ? void 0 : rec.video) === null || _e === void 0 ? void 0 : _e.bindCta;
|
9338
9362
|
const product = (_f = rec === null || rec === void 0 ? void 0 : rec.video) === null || _f === void 0 ? void 0 : _f.bindProduct;
|
9339
9363
|
jumpToWeb(rec, product, cta, index);
|
9340
|
-
window.location.href = (_h = (_g = rec === null || rec === void 0 ? void 0 : rec.video) === null || _g === void 0 ? void 0 : _g.bindProduct) === null || _h === void 0 ? void 0 : _h.link;
|
9341
|
-
window.location.href = window.getJointUtmLink((_k = (_j = rec === null || rec === void 0 ? void 0 : rec.video) === null || _j === void 0 ? void 0 : _j.bindProduct) === null || _k === void 0 ? void 0 : _k.link);
|
9364
|
+
window.location.href = window.getJointUtmLink((_h = (_g = rec === null || rec === void 0 ? void 0 : rec.video) === null || _g === void 0 ? void 0 : _g.bindProduct) === null || _h === void 0 ? void 0 : _h.link);
|
9342
9365
|
}
|
9343
9366
|
}
|
9344
9367
|
else {
|
@@ -12109,13 +12132,6 @@ const LikeButton = (_a) => {
|
|
12109
12132
|
};
|
12110
12133
|
var LikeButton$1 = React.memo(LikeButton);
|
12111
12134
|
|
12112
|
-
const SXP_EVENT_BUS = new EventEmitter();
|
12113
|
-
var SXP_EVENT_TYPE;
|
12114
|
-
(function (SXP_EVENT_TYPE) {
|
12115
|
-
SXP_EVENT_TYPE["PAGE_DID_SHOW"] = "pageDidShow";
|
12116
|
-
SXP_EVENT_TYPE["PAGE_DID_HIDE"] = "pageDidHide";
|
12117
|
-
})(SXP_EVENT_TYPE || (SXP_EVENT_TYPE = {}));
|
12118
|
-
|
12119
12135
|
const VideoWidget$2 = ({ rec, index, height, data, muted, activeIndex, videoPostConfig, videoRef }) => {
|
12120
12136
|
const [isPauseVideo, setIsPauseVideo] = React.useState(false);
|
12121
12137
|
const { bffEventReport, sxpParameter, waterFallData, openHashtag, bffFbReport } = useSxpDataSource();
|
@@ -12723,7 +12739,7 @@ const Nudge = ({ nudge }) => {
|
|
12723
12739
|
const DEFAULT_TAG = 'FOR U';
|
12724
12740
|
const Tagbar = ({ tagList = [], setActiveIndex }) => {
|
12725
12741
|
const [selectTag, setSelectTag] = React.useState(DEFAULT_TAG);
|
12726
|
-
const { getRecommendVideos, setRtcList, setCacheRtcList, setCacheActiveIndex, setLoading, swiperRef } = useSxpDataSource();
|
12742
|
+
const { getRecommendVideos, setRtcList, setCacheRtcList, setCacheActiveIndex, setLoading, swiperRef, waterFallData } = useSxpDataSource();
|
12727
12743
|
const realTagList = React.useMemo(() => {
|
12728
12744
|
return [DEFAULT_TAG, ...tagList];
|
12729
12745
|
}, [tagList]);
|
@@ -12737,6 +12753,7 @@ const Tagbar = ({ tagList = [], setActiveIndex }) => {
|
|
12737
12753
|
setLoading === null || setLoading === void 0 ? void 0 : setLoading(true);
|
12738
12754
|
getRecommendVideos === null || getRecommendVideos === void 0 ? void 0 : getRecommendVideos({ themeTag }).then((res) => {
|
12739
12755
|
var _a, _b, _c, _d;
|
12756
|
+
SXP_EVENT_BUS.emit(SXP_EVENT_TYPE.CHANGE_THEME_TAG, themeTag);
|
12740
12757
|
setRtcList === null || setRtcList === void 0 ? void 0 : setRtcList((_a = res === null || res === void 0 ? void 0 : res.recList) !== null && _a !== void 0 ? _a : []);
|
12741
12758
|
setCacheRtcList === null || setCacheRtcList === void 0 ? void 0 : setCacheRtcList((_b = res === null || res === void 0 ? void 0 : res.recList) !== null && _b !== void 0 ? _b : []);
|
12742
12759
|
setActiveIndex === null || setActiveIndex === void 0 ? void 0 : setActiveIndex(0);
|
@@ -12747,7 +12764,7 @@ const Tagbar = ({ tagList = [], setActiveIndex }) => {
|
|
12747
12764
|
});
|
12748
12765
|
setSelectTag(tag);
|
12749
12766
|
};
|
12750
|
-
if (tagList.length <= 0)
|
12767
|
+
if (waterFallData || tagList.length <= 0)
|
12751
12768
|
return null;
|
12752
12769
|
return (React.createElement("div", { className: 'clc-sxp-tagbar' },
|
12753
12770
|
React.createElement("ul", { className: 'clc-sxp-tagbar-list', style: { margin: 'auto', gap: 24 } }, realTagList.map((tag) => {
|
@@ -12939,9 +12956,12 @@ const SxpPageRender = ({ globalConfig, descStyle, containerHeight = window.inner
|
|
12939
12956
|
}
|
12940
12957
|
if (tagList.length > 0) {
|
12941
12958
|
minusHeight += 45;
|
12959
|
+
if (waterFallData) {
|
12960
|
+
minusHeight -= 45;
|
12961
|
+
}
|
12942
12962
|
}
|
12943
12963
|
return containerHeight - minusHeight;
|
12944
|
-
}, [globalConfig, containerHeight, tagList]);
|
12964
|
+
}, [globalConfig, containerHeight, tagList, waterFallData]);
|
12945
12965
|
const renderLogo = React.useMemo(() => {
|
12946
12966
|
if ((globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.logoUrl) && (globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.isShowLogo)) {
|
12947
12967
|
return (React.createElement("div", { className: 'clc-sxp-logo-banner', style: { backgroundColor: globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.color } },
|