@fonixtree/magic-design 1.0.170 → 1.0.172
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/es/composite-comp/bol/components/Video/components/VideoTag/index.js +16 -14
- package/es/composite-comp/bol/components/Video/defaultJSON.js +1 -1
- package/es/composite-comp/common/components/ProductItem/index.js +13 -5
- package/es/composite-comp/common/components/ProductItem/index.less +3 -1
- package/es/composite-comp/dito/components/Campaign/mobile/components/Bargain/index.js +1 -1
- package/es/composite-comp/dito/components/Campaign/mobile/components/FlashSale/index.js +4 -4
- package/es/composite-comp/dito/components/Campaign/mobile/components/GroupBuy/index.js +1 -1
- package/es/composite-comp/dito/components/Campaign/mobile/index.js +1 -1
- package/es/composite-comp/dito/components/Campaign/mobile/index.less +3 -0
- package/es/composite-comp/dito/components/SlideImage/pc/components/VideoItem/index.js +16 -16
- package/es/composite-comp/dito/components/SlideImage/pc/index.js +1 -1
- package/es/core/Designer/ConfigPanel/index.js +2 -2
- package/es/core/Designer/PageCompList/index.js +1 -1
- package/es/core/Designer/index.js +4 -2
- package/es/core/Renderer/index.js +4 -2
- package/es/meta-comp/config-panels/ImageConfig/index.js +0 -2
- package/lib/composite-comp/bol/components/Video/components/VideoTag/index.js +16 -14
- package/lib/composite-comp/bol/components/Video/defaultJSON.js +1 -1
- package/lib/composite-comp/common/components/ProductItem/index.js +13 -5
- package/lib/composite-comp/common/components/ProductItem/index.less +3 -1
- package/lib/composite-comp/dito/components/Campaign/mobile/components/Bargain/index.js +1 -1
- package/lib/composite-comp/dito/components/Campaign/mobile/components/FlashSale/index.js +4 -4
- package/lib/composite-comp/dito/components/Campaign/mobile/components/GroupBuy/index.js +1 -1
- package/lib/composite-comp/dito/components/Campaign/mobile/index.js +1 -1
- package/lib/composite-comp/dito/components/Campaign/mobile/index.less +3 -0
- package/lib/composite-comp/dito/components/SlideImage/pc/components/VideoItem/index.js +16 -16
- package/lib/composite-comp/dito/components/SlideImage/pc/index.js +1 -1
- package/lib/core/Designer/ConfigPanel/index.js +2 -2
- package/lib/core/Designer/PageCompList/index.js +1 -1
- package/lib/core/Designer/index.js +4 -2
- package/lib/core/Renderer/index.js +4 -2
- package/lib/meta-comp/config-panels/ImageConfig/index.js +0 -2
- package/package.json +1 -1
|
@@ -82,19 +82,21 @@ function (_super) {
|
|
|
82
82
|
}
|
|
83
83
|
|
|
84
84
|
VideoTag.prototype.render = function () {
|
|
85
|
-
var _a
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
85
|
+
var _a;
|
|
86
|
+
|
|
87
|
+
var _b = this.props,
|
|
88
|
+
onPlayClick = _b.onPlayClick,
|
|
89
|
+
data = _b.data,
|
|
90
|
+
_c = _b.position,
|
|
91
|
+
position = _c === void 0 ? 'absolute' : _c,
|
|
92
|
+
noShare = _b.noShare,
|
|
93
|
+
padding = _b.padding,
|
|
94
|
+
share = _b.share,
|
|
95
|
+
layout = _b.layout,
|
|
96
|
+
customize = _b.customize,
|
|
97
|
+
GAData = _b.GAData,
|
|
98
|
+
_d = _b.notVertical,
|
|
99
|
+
notVertical = _d === void 0 ? false : _d;
|
|
98
100
|
var align = customize.align,
|
|
99
101
|
vertical = customize.vertical;
|
|
100
102
|
var showBtn = data.video.playButton == 'Bottom Left' && !['h5-layout3', 'pc-layout4', 'pc-layout5'].includes(layout);
|
|
@@ -120,7 +122,7 @@ function (_super) {
|
|
|
120
122
|
position: position,
|
|
121
123
|
padding: padding
|
|
122
124
|
}, distanceObj))
|
|
123
|
-
}, showBtn && /*#__PURE__*/_react["default"].createElement("div", {
|
|
125
|
+
}, showBtn && ((_a = data === null || data === void 0 ? void 0 : data.playIcon) === null || _a === void 0 ? void 0 : _a.open) && /*#__PURE__*/_react["default"].createElement("div", {
|
|
124
126
|
className: "left-wrap"
|
|
125
127
|
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
126
128
|
className: "play-btn center",
|
|
@@ -157,14 +157,22 @@ function (_super) {
|
|
|
157
157
|
|
|
158
158
|
if (data.type === 'ad') {
|
|
159
159
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
160
|
-
className: "m-product-item-advertise"
|
|
161
|
-
}, data.url && /*#__PURE__*/_react["default"].createElement("img", {
|
|
162
|
-
alt: "welcome advertise",
|
|
160
|
+
className: "m-product-item-advertise",
|
|
163
161
|
onClick: function onClick() {
|
|
164
162
|
if (window.magicDesign.h5JumpUrlConfig) window.magicDesign.h5JumpUrlConfig(data.adObj, 'voucherRedeemed');
|
|
165
|
-
}
|
|
163
|
+
}
|
|
164
|
+
}, data.url && !data.url.includes('.mp4') && /*#__PURE__*/_react["default"].createElement("img", {
|
|
165
|
+
alt: "welcome advertise",
|
|
166
166
|
src: data.url
|
|
167
|
-
}))
|
|
167
|
+
}), data.url && data.url.includes('.mp4') && /*#__PURE__*/_react["default"].createElement("video", {
|
|
168
|
+
autoPlay: true,
|
|
169
|
+
loop: true,
|
|
170
|
+
muted: true,
|
|
171
|
+
playsinline: true
|
|
172
|
+
}, /*#__PURE__*/_react["default"].createElement("source", {
|
|
173
|
+
src: data.url,
|
|
174
|
+
type: "video/mp4"
|
|
175
|
+
})));
|
|
168
176
|
}
|
|
169
177
|
|
|
170
178
|
return /*#__PURE__*/_react["default"].createElement("div", _extends({
|
|
@@ -304,7 +304,7 @@ function (_super) {
|
|
|
304
304
|
key: item.id,
|
|
305
305
|
data: item,
|
|
306
306
|
onItemClick: function onItemClick() {
|
|
307
|
-
(0, _coreUtil.clickUrl)("proDetail
|
|
307
|
+
(0, _coreUtil.clickUrl)("proDetail-" + item.offerId + "-" + (item.sppProductId || ''));
|
|
308
308
|
}
|
|
309
309
|
});
|
|
310
310
|
}))));
|
|
@@ -256,7 +256,7 @@ function (_super) {
|
|
|
256
256
|
isWill: false
|
|
257
257
|
};
|
|
258
258
|
|
|
259
|
-
_this.getFlashData = function (pageSize, campaign) {
|
|
259
|
+
_this.getFlashData = function (pageSize, campaign, index, length) {
|
|
260
260
|
return __awaiter(_this, void 0, void 0, function () {
|
|
261
261
|
var res, pageId, _list;
|
|
262
262
|
|
|
@@ -278,7 +278,7 @@ function (_super) {
|
|
|
278
278
|
_list = ((res === null || res === void 0 ? void 0 : res.list) || []).slice(0, 2);
|
|
279
279
|
|
|
280
280
|
if (!(0, _coreUtil.isDesignMode)()) {
|
|
281
|
-
if (_list.length === 0) this.props.onEmpty();
|
|
281
|
+
if (_list.length === 0 && index === length - 1) this.props.onEmpty();
|
|
282
282
|
(0, _storeUtil.setMagicStore)("flashSale_" + pageId + "_" + this.props.panelProps.id, _list);
|
|
283
283
|
}
|
|
284
284
|
|
|
@@ -325,7 +325,7 @@ function (_super) {
|
|
|
325
325
|
_b = _a[_i], i = _b[0], s = _b[1];
|
|
326
326
|
return [4
|
|
327
327
|
/*yield*/
|
|
328
|
-
, this.getFlashData(2, s)];
|
|
328
|
+
, this.getFlashData(2, s, i, data.length)];
|
|
329
329
|
|
|
330
330
|
case 3:
|
|
331
331
|
v = _c.sent();
|
|
@@ -418,7 +418,7 @@ function (_super) {
|
|
|
418
418
|
salePercent: isWill ? 0 : item.salePercent
|
|
419
419
|
}),
|
|
420
420
|
onItemClick: function onItemClick() {
|
|
421
|
-
(0, _coreUtil.clickUrl)("proDetail
|
|
421
|
+
(0, _coreUtil.clickUrl)("proDetail-" + item.offerId + "-" + (item.sppProductId || ''));
|
|
422
422
|
}
|
|
423
423
|
});
|
|
424
424
|
}))));
|
|
@@ -301,7 +301,7 @@ function (_super) {
|
|
|
301
301
|
key: item.id,
|
|
302
302
|
data: item,
|
|
303
303
|
onItemClick: function onItemClick() {
|
|
304
|
-
(0, _coreUtil.clickUrl)("proDetail
|
|
304
|
+
(0, _coreUtil.clickUrl)("proDetail-" + item.offerId + "-" + (item.sppProductId || ''));
|
|
305
305
|
}
|
|
306
306
|
});
|
|
307
307
|
}))));
|
|
@@ -86,7 +86,7 @@ function (_super) {
|
|
|
86
86
|
}, !carouselHide && /*#__PURE__*/_react["default"].createElement("div", {
|
|
87
87
|
className: "campaign-left"
|
|
88
88
|
}, /*#__PURE__*/_react["default"].createElement(_antd.Carousel, {
|
|
89
|
-
autoplay:
|
|
89
|
+
autoplay: true,
|
|
90
90
|
autoplaySpeed: 2000
|
|
91
91
|
}, flashSale.open && !flashSaleHide && /*#__PURE__*/_react["default"].createElement(_FlashSale["default"], {
|
|
92
92
|
onEmpty: function onEmpty() {
|
|
@@ -20,6 +20,9 @@
|
|
|
20
20
|
.m-campaign-mobile .campaign-content .campaign-left .slick-track > div > div {
|
|
21
21
|
height: 100%;
|
|
22
22
|
}
|
|
23
|
+
.m-campaign-mobile .campaign-content .campaign-left .ant-carousel {
|
|
24
|
+
height: 100%;
|
|
25
|
+
}
|
|
23
26
|
.m-campaign-mobile .campaign-content .campaign-left .slick-dots {
|
|
24
27
|
height: 0.06rem;
|
|
25
28
|
display: flex !important;
|
|
@@ -118,16 +118,16 @@ function (_super) {
|
|
|
118
118
|
};
|
|
119
119
|
|
|
120
120
|
VideoItem.prototype.render = function () {
|
|
121
|
-
var _a, _b, _c, _d, _e, _f, _g;
|
|
122
|
-
|
|
123
|
-
var
|
|
124
|
-
data =
|
|
125
|
-
cursor =
|
|
126
|
-
onLoad =
|
|
127
|
-
moveIcon =
|
|
128
|
-
var
|
|
129
|
-
playing =
|
|
130
|
-
videoPoster =
|
|
121
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
122
|
+
|
|
123
|
+
var _j = this.props,
|
|
124
|
+
data = _j.data,
|
|
125
|
+
cursor = _j.cursor,
|
|
126
|
+
onLoad = _j.onLoad,
|
|
127
|
+
moveIcon = _j.moveIcon;
|
|
128
|
+
var _k = this.state,
|
|
129
|
+
playing = _k.playing,
|
|
130
|
+
videoPoster = _k.videoPoster;
|
|
131
131
|
var img = ((_b = (_a = data.overilay) === null || _a === void 0 ? void 0 : _a.content) === null || _b === void 0 ? void 0 : _b.pcImgSrc) || videoPoster;
|
|
132
132
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
133
133
|
ref: this.cardRef,
|
|
@@ -135,9 +135,9 @@ function (_super) {
|
|
|
135
135
|
onMouseEnter: this.onMouseEnter,
|
|
136
136
|
onMouseLeave: this.onMouseLeave,
|
|
137
137
|
style: {
|
|
138
|
-
cursor: cursor && moveIcon.open ? "url('" + moveIcon.content.pcImgSrc + "'), pointer" : 'unset'
|
|
138
|
+
cursor: cursor && (moveIcon === null || moveIcon === void 0 ? void 0 : moveIcon.open) ? "url('" + ((_c = moveIcon === null || moveIcon === void 0 ? void 0 : moveIcon.content) === null || _c === void 0 ? void 0 : _c.pcImgSrc) + "'), pointer" : 'unset'
|
|
139
139
|
}
|
|
140
|
-
}, ((
|
|
140
|
+
}, ((_d = data.video) === null || _d === void 0 ? void 0 : _d.sourceUrl) && /*#__PURE__*/_react["default"].createElement("video", {
|
|
141
141
|
ref: this.videoRef,
|
|
142
142
|
loop: true,
|
|
143
143
|
muted: true,
|
|
@@ -146,12 +146,12 @@ function (_super) {
|
|
|
146
146
|
visibility: playing ? 'visible' : 'hidden'
|
|
147
147
|
}
|
|
148
148
|
}, /*#__PURE__*/_react["default"].createElement("source", {
|
|
149
|
-
src: (
|
|
149
|
+
src: (_e = data.video) === null || _e === void 0 ? void 0 : _e.sourceUrl,
|
|
150
150
|
type: "video/mp4"
|
|
151
|
-
})), ((
|
|
151
|
+
})), ((_f = data.overilay) === null || _f === void 0 ? void 0 : _f.open) && img && /*#__PURE__*/_react["default"].createElement("img", {
|
|
152
152
|
alt: "",
|
|
153
153
|
className: (0, _classnames["default"])('video-img', {
|
|
154
|
-
cover: (
|
|
154
|
+
cover: (_g = data.video) === null || _g === void 0 ? void 0 : _g.sourceUrl
|
|
155
155
|
}),
|
|
156
156
|
onLoad: onLoad,
|
|
157
157
|
src: img,
|
|
@@ -160,7 +160,7 @@ function (_super) {
|
|
|
160
160
|
}
|
|
161
161
|
}), /*#__PURE__*/_react["default"].createElement("canvas", {
|
|
162
162
|
ref: this.canvasRef
|
|
163
|
-
}), ((
|
|
163
|
+
}), ((_h = data.background) === null || _h === void 0 ? void 0 : _h.image) && /*#__PURE__*/_react["default"].createElement("div", {
|
|
164
164
|
className: "hover-image",
|
|
165
165
|
style: {
|
|
166
166
|
backgroundImage: "url('" + data.background.image + "')"
|
|
@@ -59,7 +59,7 @@ function (_super) {
|
|
|
59
59
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
60
60
|
className: "m-slide-image-pc"
|
|
61
61
|
}, /*#__PURE__*/_react["default"].createElement(_ParallaxScroll["default"], {
|
|
62
|
-
moveIcon: content.moveIcon,
|
|
62
|
+
moveIcon: content === null || content === void 0 ? void 0 : content.moveIcon,
|
|
63
63
|
source: groupSource,
|
|
64
64
|
xGap: columnSpace,
|
|
65
65
|
yGap: lineSpace
|
|
@@ -381,8 +381,8 @@ function (_super) {
|
|
|
381
381
|
className: "config_header"
|
|
382
382
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
383
383
|
className: "title",
|
|
384
|
-
title: (_a = _constants.compInfoMap[selectedNode === null || selectedNode === void 0 ? void 0 : selectedNode.type]) === null || _a === void 0 ? void 0 : _a.name
|
|
385
|
-
}, (_b = _constants.compInfoMap[selectedNode === null || selectedNode === void 0 ? void 0 : selectedNode.type]) === null || _b === void 0 ? void 0 : _b.name), /*#__PURE__*/_react["default"].createElement("div", {
|
|
384
|
+
title: (selectedNode === null || selectedNode === void 0 ? void 0 : selectedNode.label) || ((_a = _constants.compInfoMap[selectedNode === null || selectedNode === void 0 ? void 0 : selectedNode.type]) === null || _a === void 0 ? void 0 : _a.name)
|
|
385
|
+
}, (selectedNode === null || selectedNode === void 0 ? void 0 : selectedNode.label) || ((_b = _constants.compInfoMap[selectedNode === null || selectedNode === void 0 ? void 0 : selectedNode.type]) === null || _b === void 0 ? void 0 : _b.name)), /*#__PURE__*/_react["default"].createElement("div", {
|
|
386
386
|
className: "right_wrap"
|
|
387
387
|
}, /*#__PURE__*/_react["default"].createElement(_TerminalSelect["default"], {
|
|
388
388
|
onChange: this.onTerminalChange,
|
|
@@ -293,7 +293,7 @@ function PageCompList(_a) {
|
|
|
293
293
|
type: "icon-drag"
|
|
294
294
|
}), /*#__PURE__*/_react["default"].createElement("span", {
|
|
295
295
|
className: "card-title ml16"
|
|
296
|
-
}, index + 1, ". ", (_b = _constants.compInfoMap[comp.type]) === null || _b === void 0 ? void 0 : _b.name)), pageType !== 'Menu' && /*#__PURE__*/_react["default"].createElement(_antd.Dropdown, {
|
|
296
|
+
}, index + 1, ". ", comp.label || ((_b = _constants.compInfoMap[comp.type]) === null || _b === void 0 ? void 0 : _b.name))), pageType !== 'Menu' && /*#__PURE__*/_react["default"].createElement(_antd.Dropdown, {
|
|
297
297
|
overlay: menu,
|
|
298
298
|
placement: "bottomRight",
|
|
299
299
|
trigger: ['click']
|
|
@@ -425,7 +425,8 @@ function (_super) {
|
|
|
425
425
|
|
|
426
426
|
_this.addComponent = function (_a) {
|
|
427
427
|
var type = _a.type,
|
|
428
|
-
terminalType = _a.terminalType
|
|
428
|
+
terminalType = _a.terminalType,
|
|
429
|
+
label = _a.label;
|
|
429
430
|
var MPageData = _this.state.MPageData;
|
|
430
431
|
var compType = _componentTypes.componentMap[type];
|
|
431
432
|
|
|
@@ -438,7 +439,8 @@ function (_super) {
|
|
|
438
439
|
|
|
439
440
|
var newData = __spreadArrays(MPageData, [__assign(__assign({}, compInst), {
|
|
440
441
|
terminalType: terminalType,
|
|
441
|
-
activeTerminal: terminalType
|
|
442
|
+
activeTerminal: terminalType,
|
|
443
|
+
label: label
|
|
442
444
|
})]);
|
|
443
445
|
|
|
444
446
|
_this.history.push(newData);
|
|
@@ -46,7 +46,8 @@ var setDesignConfig = function setDesignConfig(props) {
|
|
|
46
46
|
device = props.device,
|
|
47
47
|
isPreview = props.isPreview,
|
|
48
48
|
projectCode = props.projectCode,
|
|
49
|
-
showRecommendAds = props.showRecommendAds
|
|
49
|
+
showRecommendAds = props.showRecommendAds,
|
|
50
|
+
h5JumpUrlConfig = props.h5JumpUrlConfig;
|
|
50
51
|
window.magicDesign = __assign(__assign({
|
|
51
52
|
pageBackground: '#f2f2f2',
|
|
52
53
|
mode: 'renderer',
|
|
@@ -57,7 +58,8 @@ var setDesignConfig = function setDesignConfig(props) {
|
|
|
57
58
|
projectCode: projectCode,
|
|
58
59
|
compSpacing: Number(config.compSpacing),
|
|
59
60
|
compWidth: Number(config.compWidth),
|
|
60
|
-
showRecommendAds: showRecommendAds
|
|
61
|
+
showRecommendAds: showRecommendAds,
|
|
62
|
+
h5JumpUrlConfig: h5JumpUrlConfig
|
|
61
63
|
});
|
|
62
64
|
};
|
|
63
65
|
/**
|
|
@@ -360,8 +360,6 @@ function (_super) {
|
|
|
360
360
|
}];
|
|
361
361
|
|
|
362
362
|
if (needHover) {
|
|
363
|
-
console.log('needHover', needHover);
|
|
364
|
-
|
|
365
363
|
var HoverSetting = /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement(_common.Field, {
|
|
366
364
|
split: data.hover.backgroundType === 'new',
|
|
367
365
|
title: (0, _locale.i18n)('IMAGE')
|
|
@@ -82,19 +82,21 @@ function (_super) {
|
|
|
82
82
|
}
|
|
83
83
|
|
|
84
84
|
VideoTag.prototype.render = function () {
|
|
85
|
-
var _a
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
85
|
+
var _a;
|
|
86
|
+
|
|
87
|
+
var _b = this.props,
|
|
88
|
+
onPlayClick = _b.onPlayClick,
|
|
89
|
+
data = _b.data,
|
|
90
|
+
_c = _b.position,
|
|
91
|
+
position = _c === void 0 ? 'absolute' : _c,
|
|
92
|
+
noShare = _b.noShare,
|
|
93
|
+
padding = _b.padding,
|
|
94
|
+
share = _b.share,
|
|
95
|
+
layout = _b.layout,
|
|
96
|
+
customize = _b.customize,
|
|
97
|
+
GAData = _b.GAData,
|
|
98
|
+
_d = _b.notVertical,
|
|
99
|
+
notVertical = _d === void 0 ? false : _d;
|
|
98
100
|
var align = customize.align,
|
|
99
101
|
vertical = customize.vertical;
|
|
100
102
|
var showBtn = data.video.playButton == 'Bottom Left' && !['h5-layout3', 'pc-layout4', 'pc-layout5'].includes(layout);
|
|
@@ -120,7 +122,7 @@ function (_super) {
|
|
|
120
122
|
position: position,
|
|
121
123
|
padding: padding
|
|
122
124
|
}, distanceObj))
|
|
123
|
-
}, showBtn && /*#__PURE__*/_react["default"].createElement("div", {
|
|
125
|
+
}, showBtn && ((_a = data === null || data === void 0 ? void 0 : data.playIcon) === null || _a === void 0 ? void 0 : _a.open) && /*#__PURE__*/_react["default"].createElement("div", {
|
|
124
126
|
className: "left-wrap"
|
|
125
127
|
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
126
128
|
className: "play-btn center",
|
|
@@ -157,14 +157,22 @@ function (_super) {
|
|
|
157
157
|
|
|
158
158
|
if (data.type === 'ad') {
|
|
159
159
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
160
|
-
className: "m-product-item-advertise"
|
|
161
|
-
}, data.url && /*#__PURE__*/_react["default"].createElement("img", {
|
|
162
|
-
alt: "welcome advertise",
|
|
160
|
+
className: "m-product-item-advertise",
|
|
163
161
|
onClick: function onClick() {
|
|
164
162
|
if (window.magicDesign.h5JumpUrlConfig) window.magicDesign.h5JumpUrlConfig(data.adObj, 'voucherRedeemed');
|
|
165
|
-
}
|
|
163
|
+
}
|
|
164
|
+
}, data.url && !data.url.includes('.mp4') && /*#__PURE__*/_react["default"].createElement("img", {
|
|
165
|
+
alt: "welcome advertise",
|
|
166
166
|
src: data.url
|
|
167
|
-
}))
|
|
167
|
+
}), data.url && data.url.includes('.mp4') && /*#__PURE__*/_react["default"].createElement("video", {
|
|
168
|
+
autoPlay: true,
|
|
169
|
+
loop: true,
|
|
170
|
+
muted: true,
|
|
171
|
+
playsinline: true
|
|
172
|
+
}, /*#__PURE__*/_react["default"].createElement("source", {
|
|
173
|
+
src: data.url,
|
|
174
|
+
type: "video/mp4"
|
|
175
|
+
})));
|
|
168
176
|
}
|
|
169
177
|
|
|
170
178
|
return /*#__PURE__*/_react["default"].createElement("div", _extends({
|
|
@@ -304,7 +304,7 @@ function (_super) {
|
|
|
304
304
|
key: item.id,
|
|
305
305
|
data: item,
|
|
306
306
|
onItemClick: function onItemClick() {
|
|
307
|
-
(0, _coreUtil.clickUrl)("proDetail
|
|
307
|
+
(0, _coreUtil.clickUrl)("proDetail-" + item.offerId + "-" + (item.sppProductId || ''));
|
|
308
308
|
}
|
|
309
309
|
});
|
|
310
310
|
}))));
|
|
@@ -256,7 +256,7 @@ function (_super) {
|
|
|
256
256
|
isWill: false
|
|
257
257
|
};
|
|
258
258
|
|
|
259
|
-
_this.getFlashData = function (pageSize, campaign) {
|
|
259
|
+
_this.getFlashData = function (pageSize, campaign, index, length) {
|
|
260
260
|
return __awaiter(_this, void 0, void 0, function () {
|
|
261
261
|
var res, pageId, _list;
|
|
262
262
|
|
|
@@ -278,7 +278,7 @@ function (_super) {
|
|
|
278
278
|
_list = ((res === null || res === void 0 ? void 0 : res.list) || []).slice(0, 2);
|
|
279
279
|
|
|
280
280
|
if (!(0, _coreUtil.isDesignMode)()) {
|
|
281
|
-
if (_list.length === 0) this.props.onEmpty();
|
|
281
|
+
if (_list.length === 0 && index === length - 1) this.props.onEmpty();
|
|
282
282
|
(0, _storeUtil.setMagicStore)("flashSale_" + pageId + "_" + this.props.panelProps.id, _list);
|
|
283
283
|
}
|
|
284
284
|
|
|
@@ -325,7 +325,7 @@ function (_super) {
|
|
|
325
325
|
_b = _a[_i], i = _b[0], s = _b[1];
|
|
326
326
|
return [4
|
|
327
327
|
/*yield*/
|
|
328
|
-
, this.getFlashData(2, s)];
|
|
328
|
+
, this.getFlashData(2, s, i, data.length)];
|
|
329
329
|
|
|
330
330
|
case 3:
|
|
331
331
|
v = _c.sent();
|
|
@@ -418,7 +418,7 @@ function (_super) {
|
|
|
418
418
|
salePercent: isWill ? 0 : item.salePercent
|
|
419
419
|
}),
|
|
420
420
|
onItemClick: function onItemClick() {
|
|
421
|
-
(0, _coreUtil.clickUrl)("proDetail
|
|
421
|
+
(0, _coreUtil.clickUrl)("proDetail-" + item.offerId + "-" + (item.sppProductId || ''));
|
|
422
422
|
}
|
|
423
423
|
});
|
|
424
424
|
}))));
|
|
@@ -301,7 +301,7 @@ function (_super) {
|
|
|
301
301
|
key: item.id,
|
|
302
302
|
data: item,
|
|
303
303
|
onItemClick: function onItemClick() {
|
|
304
|
-
(0, _coreUtil.clickUrl)("proDetail
|
|
304
|
+
(0, _coreUtil.clickUrl)("proDetail-" + item.offerId + "-" + (item.sppProductId || ''));
|
|
305
305
|
}
|
|
306
306
|
});
|
|
307
307
|
}))));
|
|
@@ -86,7 +86,7 @@ function (_super) {
|
|
|
86
86
|
}, !carouselHide && /*#__PURE__*/_react["default"].createElement("div", {
|
|
87
87
|
className: "campaign-left"
|
|
88
88
|
}, /*#__PURE__*/_react["default"].createElement(_antd.Carousel, {
|
|
89
|
-
autoplay:
|
|
89
|
+
autoplay: true,
|
|
90
90
|
autoplaySpeed: 2000
|
|
91
91
|
}, flashSale.open && !flashSaleHide && /*#__PURE__*/_react["default"].createElement(_FlashSale["default"], {
|
|
92
92
|
onEmpty: function onEmpty() {
|
|
@@ -20,6 +20,9 @@
|
|
|
20
20
|
.m-campaign-mobile .campaign-content .campaign-left .slick-track > div > div {
|
|
21
21
|
height: 100%;
|
|
22
22
|
}
|
|
23
|
+
.m-campaign-mobile .campaign-content .campaign-left .ant-carousel {
|
|
24
|
+
height: 100%;
|
|
25
|
+
}
|
|
23
26
|
.m-campaign-mobile .campaign-content .campaign-left .slick-dots {
|
|
24
27
|
height: 0.06rem;
|
|
25
28
|
display: flex !important;
|
|
@@ -118,16 +118,16 @@ function (_super) {
|
|
|
118
118
|
};
|
|
119
119
|
|
|
120
120
|
VideoItem.prototype.render = function () {
|
|
121
|
-
var _a, _b, _c, _d, _e, _f, _g;
|
|
122
|
-
|
|
123
|
-
var
|
|
124
|
-
data =
|
|
125
|
-
cursor =
|
|
126
|
-
onLoad =
|
|
127
|
-
moveIcon =
|
|
128
|
-
var
|
|
129
|
-
playing =
|
|
130
|
-
videoPoster =
|
|
121
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
122
|
+
|
|
123
|
+
var _j = this.props,
|
|
124
|
+
data = _j.data,
|
|
125
|
+
cursor = _j.cursor,
|
|
126
|
+
onLoad = _j.onLoad,
|
|
127
|
+
moveIcon = _j.moveIcon;
|
|
128
|
+
var _k = this.state,
|
|
129
|
+
playing = _k.playing,
|
|
130
|
+
videoPoster = _k.videoPoster;
|
|
131
131
|
var img = ((_b = (_a = data.overilay) === null || _a === void 0 ? void 0 : _a.content) === null || _b === void 0 ? void 0 : _b.pcImgSrc) || videoPoster;
|
|
132
132
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
133
133
|
ref: this.cardRef,
|
|
@@ -135,9 +135,9 @@ function (_super) {
|
|
|
135
135
|
onMouseEnter: this.onMouseEnter,
|
|
136
136
|
onMouseLeave: this.onMouseLeave,
|
|
137
137
|
style: {
|
|
138
|
-
cursor: cursor && moveIcon.open ? "url('" + moveIcon.content.pcImgSrc + "'), pointer" : 'unset'
|
|
138
|
+
cursor: cursor && (moveIcon === null || moveIcon === void 0 ? void 0 : moveIcon.open) ? "url('" + ((_c = moveIcon === null || moveIcon === void 0 ? void 0 : moveIcon.content) === null || _c === void 0 ? void 0 : _c.pcImgSrc) + "'), pointer" : 'unset'
|
|
139
139
|
}
|
|
140
|
-
}, ((
|
|
140
|
+
}, ((_d = data.video) === null || _d === void 0 ? void 0 : _d.sourceUrl) && /*#__PURE__*/_react["default"].createElement("video", {
|
|
141
141
|
ref: this.videoRef,
|
|
142
142
|
loop: true,
|
|
143
143
|
muted: true,
|
|
@@ -146,12 +146,12 @@ function (_super) {
|
|
|
146
146
|
visibility: playing ? 'visible' : 'hidden'
|
|
147
147
|
}
|
|
148
148
|
}, /*#__PURE__*/_react["default"].createElement("source", {
|
|
149
|
-
src: (
|
|
149
|
+
src: (_e = data.video) === null || _e === void 0 ? void 0 : _e.sourceUrl,
|
|
150
150
|
type: "video/mp4"
|
|
151
|
-
})), ((
|
|
151
|
+
})), ((_f = data.overilay) === null || _f === void 0 ? void 0 : _f.open) && img && /*#__PURE__*/_react["default"].createElement("img", {
|
|
152
152
|
alt: "",
|
|
153
153
|
className: (0, _classnames["default"])('video-img', {
|
|
154
|
-
cover: (
|
|
154
|
+
cover: (_g = data.video) === null || _g === void 0 ? void 0 : _g.sourceUrl
|
|
155
155
|
}),
|
|
156
156
|
onLoad: onLoad,
|
|
157
157
|
src: img,
|
|
@@ -160,7 +160,7 @@ function (_super) {
|
|
|
160
160
|
}
|
|
161
161
|
}), /*#__PURE__*/_react["default"].createElement("canvas", {
|
|
162
162
|
ref: this.canvasRef
|
|
163
|
-
}), ((
|
|
163
|
+
}), ((_h = data.background) === null || _h === void 0 ? void 0 : _h.image) && /*#__PURE__*/_react["default"].createElement("div", {
|
|
164
164
|
className: "hover-image",
|
|
165
165
|
style: {
|
|
166
166
|
backgroundImage: "url('" + data.background.image + "')"
|
|
@@ -59,7 +59,7 @@ function (_super) {
|
|
|
59
59
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
60
60
|
className: "m-slide-image-pc"
|
|
61
61
|
}, /*#__PURE__*/_react["default"].createElement(_ParallaxScroll["default"], {
|
|
62
|
-
moveIcon: content.moveIcon,
|
|
62
|
+
moveIcon: content === null || content === void 0 ? void 0 : content.moveIcon,
|
|
63
63
|
source: groupSource,
|
|
64
64
|
xGap: columnSpace,
|
|
65
65
|
yGap: lineSpace
|
|
@@ -381,8 +381,8 @@ function (_super) {
|
|
|
381
381
|
className: "config_header"
|
|
382
382
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
383
383
|
className: "title",
|
|
384
|
-
title: (_a = _constants.compInfoMap[selectedNode === null || selectedNode === void 0 ? void 0 : selectedNode.type]) === null || _a === void 0 ? void 0 : _a.name
|
|
385
|
-
}, (_b = _constants.compInfoMap[selectedNode === null || selectedNode === void 0 ? void 0 : selectedNode.type]) === null || _b === void 0 ? void 0 : _b.name), /*#__PURE__*/_react["default"].createElement("div", {
|
|
384
|
+
title: (selectedNode === null || selectedNode === void 0 ? void 0 : selectedNode.label) || ((_a = _constants.compInfoMap[selectedNode === null || selectedNode === void 0 ? void 0 : selectedNode.type]) === null || _a === void 0 ? void 0 : _a.name)
|
|
385
|
+
}, (selectedNode === null || selectedNode === void 0 ? void 0 : selectedNode.label) || ((_b = _constants.compInfoMap[selectedNode === null || selectedNode === void 0 ? void 0 : selectedNode.type]) === null || _b === void 0 ? void 0 : _b.name)), /*#__PURE__*/_react["default"].createElement("div", {
|
|
386
386
|
className: "right_wrap"
|
|
387
387
|
}, /*#__PURE__*/_react["default"].createElement(_TerminalSelect["default"], {
|
|
388
388
|
onChange: this.onTerminalChange,
|
|
@@ -293,7 +293,7 @@ function PageCompList(_a) {
|
|
|
293
293
|
type: "icon-drag"
|
|
294
294
|
}), /*#__PURE__*/_react["default"].createElement("span", {
|
|
295
295
|
className: "card-title ml16"
|
|
296
|
-
}, index + 1, ". ", (_b = _constants.compInfoMap[comp.type]) === null || _b === void 0 ? void 0 : _b.name)), pageType !== 'Menu' && /*#__PURE__*/_react["default"].createElement(_antd.Dropdown, {
|
|
296
|
+
}, index + 1, ". ", comp.label || ((_b = _constants.compInfoMap[comp.type]) === null || _b === void 0 ? void 0 : _b.name))), pageType !== 'Menu' && /*#__PURE__*/_react["default"].createElement(_antd.Dropdown, {
|
|
297
297
|
overlay: menu,
|
|
298
298
|
placement: "bottomRight",
|
|
299
299
|
trigger: ['click']
|
|
@@ -425,7 +425,8 @@ function (_super) {
|
|
|
425
425
|
|
|
426
426
|
_this.addComponent = function (_a) {
|
|
427
427
|
var type = _a.type,
|
|
428
|
-
terminalType = _a.terminalType
|
|
428
|
+
terminalType = _a.terminalType,
|
|
429
|
+
label = _a.label;
|
|
429
430
|
var MPageData = _this.state.MPageData;
|
|
430
431
|
var compType = _componentTypes.componentMap[type];
|
|
431
432
|
|
|
@@ -438,7 +439,8 @@ function (_super) {
|
|
|
438
439
|
|
|
439
440
|
var newData = __spreadArrays(MPageData, [__assign(__assign({}, compInst), {
|
|
440
441
|
terminalType: terminalType,
|
|
441
|
-
activeTerminal: terminalType
|
|
442
|
+
activeTerminal: terminalType,
|
|
443
|
+
label: label
|
|
442
444
|
})]);
|
|
443
445
|
|
|
444
446
|
_this.history.push(newData);
|
|
@@ -46,7 +46,8 @@ var setDesignConfig = function setDesignConfig(props) {
|
|
|
46
46
|
device = props.device,
|
|
47
47
|
isPreview = props.isPreview,
|
|
48
48
|
projectCode = props.projectCode,
|
|
49
|
-
showRecommendAds = props.showRecommendAds
|
|
49
|
+
showRecommendAds = props.showRecommendAds,
|
|
50
|
+
h5JumpUrlConfig = props.h5JumpUrlConfig;
|
|
50
51
|
window.magicDesign = __assign(__assign({
|
|
51
52
|
pageBackground: '#f2f2f2',
|
|
52
53
|
mode: 'renderer',
|
|
@@ -57,7 +58,8 @@ var setDesignConfig = function setDesignConfig(props) {
|
|
|
57
58
|
projectCode: projectCode,
|
|
58
59
|
compSpacing: Number(config.compSpacing),
|
|
59
60
|
compWidth: Number(config.compWidth),
|
|
60
|
-
showRecommendAds: showRecommendAds
|
|
61
|
+
showRecommendAds: showRecommendAds,
|
|
62
|
+
h5JumpUrlConfig: h5JumpUrlConfig
|
|
61
63
|
});
|
|
62
64
|
};
|
|
63
65
|
/**
|
|
@@ -360,8 +360,6 @@ function (_super) {
|
|
|
360
360
|
}];
|
|
361
361
|
|
|
362
362
|
if (needHover) {
|
|
363
|
-
console.log('needHover', needHover);
|
|
364
|
-
|
|
365
363
|
var HoverSetting = /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement(_common.Field, {
|
|
366
364
|
split: data.hover.backgroundType === 'new',
|
|
367
365
|
title: (0, _locale.i18n)('IMAGE')
|