pb-sxp-ui 1.9.7 → 1.10.0
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 +525 -167
- package/dist/index.cjs.map +1 -1
- package/dist/index.css +35 -0
- package/dist/index.js +525 -167
- package/dist/index.js.map +1 -1
- package/dist/index.min.cjs +7 -3
- package/dist/index.min.cjs.map +1 -1
- package/dist/index.min.js +7 -3
- package/dist/index.min.js.map +1 -1
- package/dist/pb-ui.js +525 -167
- package/dist/pb-ui.js.map +1 -1
- package/dist/pb-ui.min.js +7 -3
- package/dist/pb-ui.min.js.map +1 -1
- package/es/core/Pagebuilder/index.js +3 -4
- package/es/core/components/SxpPageCore/index.d.ts +1 -1
- package/es/core/components/SxpPageCore/index.js +7 -6
- package/es/core/components/SxpPageRender/NavBack.d.ts +9 -0
- package/es/core/components/SxpPageRender/NavBack.js +16 -0
- package/es/core/components/SxpPageRender/PictureGroup/index.js +3 -1
- package/es/core/components/SxpPageRender/index.d.ts +2 -0
- package/es/core/components/SxpPageRender/index.js +30 -22
- package/es/core/components/SxpPageRender/typing.d.ts +1 -0
- package/es/core/context/EditorContext.d.ts +2 -0
- package/es/core/context/EditorContext.js +9 -3
- package/es/core/context/EditorDataProvider.d.ts +2 -0
- package/es/core/context/EditorDataProvider.js +4 -1
- package/es/core/context/SxpDataSourceProvider.d.ts +4 -2
- package/es/core/context/SxpDataSourceProvider.js +83 -52
- package/es/core/utils/materials.d.ts +1 -1
- package/es/materials/sxp/MultiPosts/index.d.ts +26 -0
- package/es/materials/sxp/MultiPosts/index.js +98 -0
- package/es/materials/sxp/MultiPosts/interactionRender.d.ts +9 -0
- package/es/materials/sxp/MultiPosts/interactionRender.js +42 -0
- package/es/materials/sxp/MultiPosts/material.d.ts +2 -0
- package/es/materials/sxp/MultiPosts/material.js +22 -0
- package/es/materials/sxp/MultiPosts/settingRender.d.ts +73 -0
- package/es/materials/sxp/MultiPosts/settingRender.js +115 -0
- package/es/materials/sxp/index.d.ts +1 -0
- package/es/materials/sxp/index.js +1 -0
- package/es/materials/sxp/template/components/EventProvider.js +5 -5
- package/lib/core/Pagebuilder/index.js +3 -4
- package/lib/core/components/SxpPageCore/index.d.ts +1 -1
- package/lib/core/components/SxpPageCore/index.js +6 -5
- package/lib/core/components/SxpPageRender/NavBack.d.ts +9 -0
- package/lib/core/components/SxpPageRender/NavBack.js +19 -0
- package/lib/core/components/SxpPageRender/PictureGroup/index.js +3 -1
- package/lib/core/components/SxpPageRender/index.d.ts +2 -0
- package/lib/core/components/SxpPageRender/index.js +30 -22
- package/lib/core/components/SxpPageRender/typing.d.ts +1 -0
- package/lib/core/context/EditorContext.d.ts +2 -0
- package/lib/core/context/EditorContext.js +9 -3
- package/lib/core/context/EditorDataProvider.d.ts +2 -0
- package/lib/core/context/EditorDataProvider.js +4 -1
- package/lib/core/context/SxpDataSourceProvider.d.ts +4 -2
- package/lib/core/context/SxpDataSourceProvider.js +83 -52
- package/lib/core/utils/materials.d.ts +1 -1
- package/lib/materials/sxp/MultiPosts/index.d.ts +26 -0
- package/lib/materials/sxp/MultiPosts/index.js +100 -0
- package/lib/materials/sxp/MultiPosts/interactionRender.d.ts +9 -0
- package/lib/materials/sxp/MultiPosts/interactionRender.js +44 -0
- package/lib/materials/sxp/MultiPosts/material.d.ts +2 -0
- package/lib/materials/sxp/MultiPosts/material.js +26 -0
- package/lib/materials/sxp/MultiPosts/settingRender.d.ts +73 -0
- package/lib/materials/sxp/MultiPosts/settingRender.js +117 -0
- package/lib/materials/sxp/index.d.ts +1 -0
- package/lib/materials/sxp/index.js +1 -0
- package/lib/materials/sxp/template/components/EventProvider.js +5 -5
- package/package.json +1 -1
@@ -0,0 +1,117 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.default = [
|
4
|
+
{
|
5
|
+
title: '背景设置',
|
6
|
+
child: [
|
7
|
+
{
|
8
|
+
label: '背景图',
|
9
|
+
type: 'Upload',
|
10
|
+
name: ['props', 'bgImgUrl']
|
11
|
+
},
|
12
|
+
{
|
13
|
+
type: 'Group',
|
14
|
+
label: '返回按钮',
|
15
|
+
child: [
|
16
|
+
{
|
17
|
+
type: 'Switch',
|
18
|
+
name: ['props', 'backButton', 'enable']
|
19
|
+
},
|
20
|
+
{
|
21
|
+
type: 'Upload',
|
22
|
+
name: ['props', 'backButton', 'icon'],
|
23
|
+
text: '建议尺寸:100 * 76'
|
24
|
+
}
|
25
|
+
]
|
26
|
+
},
|
27
|
+
{
|
28
|
+
type: 'Group',
|
29
|
+
label: '',
|
30
|
+
child: [
|
31
|
+
{
|
32
|
+
type: 'Select',
|
33
|
+
name: ['props', 'backButton', 'xPosit'],
|
34
|
+
options: [
|
35
|
+
{
|
36
|
+
label: '相对左侧',
|
37
|
+
value: 'left'
|
38
|
+
},
|
39
|
+
{
|
40
|
+
label: '相对右侧',
|
41
|
+
value: 'right'
|
42
|
+
}
|
43
|
+
],
|
44
|
+
initialValue: 'left'
|
45
|
+
},
|
46
|
+
{
|
47
|
+
type: 'Number',
|
48
|
+
name: ['props', 'backButton', 'x'],
|
49
|
+
addonAfter: 'X'
|
50
|
+
}
|
51
|
+
]
|
52
|
+
},
|
53
|
+
{
|
54
|
+
type: 'Group',
|
55
|
+
label: '',
|
56
|
+
child: [
|
57
|
+
{
|
58
|
+
type: 'Select',
|
59
|
+
name: ['props', 'backButton', 'yPosit'],
|
60
|
+
options: [
|
61
|
+
{
|
62
|
+
label: '相对底部',
|
63
|
+
value: 'bottom'
|
64
|
+
},
|
65
|
+
{
|
66
|
+
label: '相对顶部',
|
67
|
+
value: 'top'
|
68
|
+
}
|
69
|
+
],
|
70
|
+
initialValue: 'top'
|
71
|
+
},
|
72
|
+
{
|
73
|
+
type: 'Number',
|
74
|
+
name: ['props', 'backButton', 'y'],
|
75
|
+
addonAfter: 'Y',
|
76
|
+
initialValue: 0
|
77
|
+
}
|
78
|
+
]
|
79
|
+
}
|
80
|
+
]
|
81
|
+
},
|
82
|
+
{
|
83
|
+
title: '按钮设置',
|
84
|
+
child: [
|
85
|
+
{
|
86
|
+
type: 'Group',
|
87
|
+
child: [
|
88
|
+
{
|
89
|
+
type: 'Upload',
|
90
|
+
name: ['props', 'button1Url'],
|
91
|
+
text: '按钮1'
|
92
|
+
},
|
93
|
+
{
|
94
|
+
type: 'Upload',
|
95
|
+
name: ['props', 'button2Url'],
|
96
|
+
text: '按钮2'
|
97
|
+
}
|
98
|
+
]
|
99
|
+
},
|
100
|
+
{
|
101
|
+
type: 'Group',
|
102
|
+
child: [
|
103
|
+
{
|
104
|
+
type: 'Upload',
|
105
|
+
name: ['props', 'button3Url'],
|
106
|
+
text: '按钮3'
|
107
|
+
},
|
108
|
+
{
|
109
|
+
type: 'Upload',
|
110
|
+
name: ['props', 'button4Url'],
|
111
|
+
text: '按钮4'
|
112
|
+
}
|
113
|
+
]
|
114
|
+
}
|
115
|
+
]
|
116
|
+
}
|
117
|
+
];
|
@@ -7,3 +7,4 @@ tslib_1.__exportStar(require("./HashTag/material"), exports);
|
|
7
7
|
tslib_1.__exportStar(require("./Consent/material"), exports);
|
8
8
|
tslib_1.__exportStar(require("./cta"), exports);
|
9
9
|
tslib_1.__exportStar(require("./consentPopup"), exports);
|
10
|
+
tslib_1.__exportStar(require("./MultiPosts/material"), exports);
|
@@ -13,9 +13,9 @@ const EventProvider = (_a) => {
|
|
13
13
|
const { jumpToWeb } = (0, useEventReport_1.useEventReport)();
|
14
14
|
const [element, setElement] = (0, react_1.useState)(null);
|
15
15
|
const handleClick = (0, lodash_1.throttle)((event) => {
|
16
|
-
var _a, _b, _c, _d, _e, _f
|
16
|
+
var _a, _b, _c, _d, _e, _f;
|
17
17
|
event.preventDefault();
|
18
|
-
const item =
|
18
|
+
const item = multItem ? multItem : (_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;
|
19
19
|
ctaEvent === null || ctaEvent === void 0 ? void 0 : ctaEvent({
|
20
20
|
eventSubject: 'clickCta',
|
21
21
|
eventDescription: 'User clicked the CTA'
|
@@ -24,10 +24,10 @@ const EventProvider = (_a) => {
|
|
24
24
|
? Object.assign(Object.assign({}, rec), { video: Object.assign(Object.assign({}, rec === null || rec === void 0 ? void 0 : rec.video), { bindProduct: multItem }), index, multiCheckIndex }) : Object.assign(Object.assign({}, rec), { index }));
|
25
25
|
setElement(ref === null || ref === void 0 ? void 0 : ref.current);
|
26
26
|
if (isExternalLink) {
|
27
|
-
const link = ((
|
27
|
+
const link = ((_d = (_c = rec === null || rec === void 0 ? void 0 : rec.video) === null || _c === void 0 ? void 0 : _c.bindProduct) === null || _d === void 0 ? void 0 : _d.link) || (multItem === null || multItem === void 0 ? void 0 : multItem.link);
|
28
28
|
if (jumpLink || link) {
|
29
|
-
const cta = ((
|
30
|
-
const product = ((
|
29
|
+
const cta = ((_e = rec === null || rec === void 0 ? void 0 : rec.video) === null || _e === void 0 ? void 0 : _e.bindCta) || (multItem === null || multItem === void 0 ? void 0 : multItem.bindCta);
|
30
|
+
const product = ((_f = rec === null || rec === void 0 ? void 0 : rec.video) === null || _f === void 0 ? void 0 : _f.bindProduct) || multItem;
|
31
31
|
jumpToWeb(rec, product, cta, index);
|
32
32
|
window.location.href = window.getJointUtmLink(jumpLink || link || '');
|
33
33
|
}
|