@fonixtree/magic-design 2.0.204 → 2.0.206
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/assets/images/layout-icon/campaignLayout1.png +0 -0
- package/es/assets/images/layout-icon/imageGalleryLayout3.png +0 -0
- package/es/assets/images/layout-icon/imageGalleryLayout4.png +0 -0
- package/es/common/Collapse/index.js +3 -1
- package/es/common/Field/index.js +5 -4
- package/es/common/Field/index.less +4 -0
- package/es/composite-comp/bol/components/ImageGallery/mobile/index.js +33 -2
- package/es/composite-comp/bol/components/ImageGallery/mobile/index.less +15 -0
- package/es/composite-comp/bol/components/Video/defaultJSON.js +1 -0
- package/es/composite-comp/bol/components/Video/mobile/Layout1/index.js +2 -1
- package/es/composite-comp/bol/components/Video/mobile/Layout1/index.less +1 -0
- package/es/composite-comp/bol/components/Video/mobile/Layout2/index.js +2 -1
- package/es/composite-comp/bol/components/Video/mobile/Layout2/index.less +1 -0
- package/es/composite-comp/bol/components/Video/mobile/Layout3/index.js +2 -1
- package/es/composite-comp/bol/components/Video/mobile/Layout3/index.less +1 -0
- package/es/composite-comp/bol/components/Video/pc/Layout1/index.js +2 -1
- package/es/composite-comp/bol/components/Video/pc/Layout1/index.less +1 -0
- package/es/composite-comp/bol/components/Video/pc/Layout2/index.js +8 -2
- package/es/composite-comp/bol/components/Video/pc/Layout2/index.less +2 -0
- package/es/composite-comp/bol/components/Video/pc/Layout3/index.js +4 -1
- package/es/composite-comp/bol/components/Video/pc/Layout3/index.less +1 -0
- package/es/composite-comp/bol/components/Video/pc/Layout4/index.js +2 -1
- package/es/composite-comp/bol/components/Video/pc/Layout4/index.less +1 -0
- package/es/composite-comp/bol/components/Video/pc/Layout5/index.js +2 -1
- package/es/composite-comp/bol/components/Video/pc/Layout5/index.less +1 -0
- package/es/composite-comp/bol/config-panels/ImageGalleryConfig/ImageGalleryConfigImageGroup/index.js +1 -0
- package/es/composite-comp/bol/config-panels/ImageGalleryConfig/index.js +1 -1
- package/es/composite-comp/bol/config-panels/VideoConfig/index.js +12 -0
- package/es/composite-comp/common/components/ProductItem/index.js +1 -1
- package/es/composite-comp/dito/components/Campaign/defaultJSON.js +112 -0
- package/es/composite-comp/dito/components/Campaign/index.js +88 -0
- package/es/composite-comp/dito/components/Campaign/mobile/components/Bargain/index.js +320 -0
- package/es/composite-comp/dito/components/Campaign/mobile/components/Bargain/index.less +20 -0
- package/es/composite-comp/dito/components/Campaign/mobile/components/CountDown/index.js +180 -0
- package/es/composite-comp/dito/components/Campaign/mobile/components/CountDown/index.less +26 -0
- package/es/composite-comp/dito/components/Campaign/mobile/components/FlashSale/index.js +434 -0
- package/es/composite-comp/dito/components/Campaign/mobile/components/FlashSale/index.less +20 -0
- package/es/composite-comp/dito/components/Campaign/mobile/components/GroupBuy/index.js +317 -0
- package/es/composite-comp/dito/components/Campaign/mobile/components/GroupBuy/index.less +20 -0
- package/es/composite-comp/dito/components/Campaign/mobile/components/ProductItem/index.js +115 -0
- package/es/composite-comp/dito/components/Campaign/mobile/components/ProductItem/index.less +14 -0
- package/es/composite-comp/dito/components/Campaign/mobile/imgs/defImg.png +0 -0
- package/es/composite-comp/dito/components/Campaign/mobile/index.js +125 -0
- package/es/composite-comp/dito/components/Campaign/mobile/index.less +57 -0
- package/es/composite-comp/dito/components/GroupedCarousel/pc/index.js +8 -2
- package/es/composite-comp/dito/components/SearchDITO/pc/components/ConfirmModal/index.js +1 -1
- package/es/composite-comp/dito/components/SearchDITO/pc/components/Header/index.js +2 -2
- 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/composite-comp/dito/config-panels/CampaignConfig/ConfigContent/index.js +143 -0
- package/es/composite-comp/dito/config-panels/CampaignConfig/ConfigTitle/index.js +93 -0
- package/es/composite-comp/dito/config-panels/CampaignConfig/index.js +69 -0
- package/es/composite-comp/dito/second-config-panels/CampaignSecondConfig/index.js +109 -0
- package/es/constants/component-types.js +9 -3
- package/es/constants/index.js +4 -0
- package/es/constants/layout.js +32 -2
- package/es/core/Designer/ConfigPanel/index.js +6 -2
- package/es/core/Designer/PageCompList/index.js +1 -1
- package/es/core/Designer/index.js +4 -2
- package/es/meta-comp/config-panels/ImageConfig/index.js +0 -2
- package/es/meta-comp/config-panels/TextConfig/index.js +17 -7
- package/es/meta-comp/config-panels/TextConfig/index.less +7 -0
- package/es/utils/commonUtil.js +59 -89
- package/lib/assets/images/layout-icon/campaignLayout1.png +0 -0
- package/lib/assets/images/layout-icon/imageGalleryLayout3.png +0 -0
- package/lib/assets/images/layout-icon/imageGalleryLayout4.png +0 -0
- package/lib/common/Collapse/index.js +3 -1
- package/lib/common/Field/index.js +5 -4
- package/lib/common/Field/index.less +4 -0
- package/lib/composite-comp/bol/components/ImageGallery/mobile/index.js +33 -2
- package/lib/composite-comp/bol/components/ImageGallery/mobile/index.less +15 -0
- package/lib/composite-comp/bol/components/Video/defaultJSON.js +1 -0
- package/lib/composite-comp/bol/components/Video/mobile/Layout1/index.js +2 -1
- package/lib/composite-comp/bol/components/Video/mobile/Layout1/index.less +1 -0
- package/lib/composite-comp/bol/components/Video/mobile/Layout2/index.js +2 -1
- package/lib/composite-comp/bol/components/Video/mobile/Layout2/index.less +1 -0
- package/lib/composite-comp/bol/components/Video/mobile/Layout3/index.js +2 -1
- package/lib/composite-comp/bol/components/Video/mobile/Layout3/index.less +1 -0
- package/lib/composite-comp/bol/components/Video/pc/Layout1/index.js +2 -1
- package/lib/composite-comp/bol/components/Video/pc/Layout1/index.less +1 -0
- package/lib/composite-comp/bol/components/Video/pc/Layout2/index.js +8 -2
- package/lib/composite-comp/bol/components/Video/pc/Layout2/index.less +2 -0
- package/lib/composite-comp/bol/components/Video/pc/Layout3/index.js +4 -1
- package/lib/composite-comp/bol/components/Video/pc/Layout3/index.less +1 -0
- package/lib/composite-comp/bol/components/Video/pc/Layout4/index.js +2 -1
- package/lib/composite-comp/bol/components/Video/pc/Layout4/index.less +1 -0
- package/lib/composite-comp/bol/components/Video/pc/Layout5/index.js +2 -1
- package/lib/composite-comp/bol/components/Video/pc/Layout5/index.less +1 -0
- package/lib/composite-comp/bol/config-panels/ImageGalleryConfig/ImageGalleryConfigImageGroup/index.js +1 -0
- package/lib/composite-comp/bol/config-panels/ImageGalleryConfig/index.js +1 -1
- package/lib/composite-comp/bol/config-panels/VideoConfig/index.js +12 -0
- package/lib/composite-comp/common/components/ProductItem/index.js +1 -1
- package/lib/composite-comp/dito/components/Campaign/defaultJSON.js +112 -0
- package/lib/composite-comp/dito/components/Campaign/index.js +88 -0
- package/lib/composite-comp/dito/components/Campaign/mobile/components/Bargain/index.js +320 -0
- package/lib/composite-comp/dito/components/Campaign/mobile/components/Bargain/index.less +20 -0
- package/lib/composite-comp/dito/components/Campaign/mobile/components/CountDown/index.js +180 -0
- package/lib/composite-comp/dito/components/Campaign/mobile/components/CountDown/index.less +26 -0
- package/lib/composite-comp/dito/components/Campaign/mobile/components/FlashSale/index.js +434 -0
- package/lib/composite-comp/dito/components/Campaign/mobile/components/FlashSale/index.less +20 -0
- package/lib/composite-comp/dito/components/Campaign/mobile/components/GroupBuy/index.js +317 -0
- package/lib/composite-comp/dito/components/Campaign/mobile/components/GroupBuy/index.less +20 -0
- package/lib/composite-comp/dito/components/Campaign/mobile/components/ProductItem/index.js +115 -0
- package/lib/composite-comp/dito/components/Campaign/mobile/components/ProductItem/index.less +14 -0
- package/lib/composite-comp/dito/components/Campaign/mobile/imgs/defImg.png +0 -0
- package/lib/composite-comp/dito/components/Campaign/mobile/index.js +125 -0
- package/lib/composite-comp/dito/components/Campaign/mobile/index.less +57 -0
- package/lib/composite-comp/dito/components/GroupedCarousel/pc/index.js +8 -2
- package/lib/composite-comp/dito/components/SearchDITO/pc/components/ConfirmModal/index.js +1 -1
- package/lib/composite-comp/dito/components/SearchDITO/pc/components/Header/index.js +2 -2
- 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/composite-comp/dito/config-panels/CampaignConfig/ConfigContent/index.js +143 -0
- package/lib/composite-comp/dito/config-panels/CampaignConfig/ConfigTitle/index.js +93 -0
- package/lib/composite-comp/dito/config-panels/CampaignConfig/index.js +69 -0
- package/lib/composite-comp/dito/second-config-panels/CampaignSecondConfig/index.js +109 -0
- package/lib/constants/component-types.js +9 -3
- package/lib/constants/index.js +4 -0
- package/lib/constants/layout.js +32 -2
- package/lib/core/Designer/ConfigPanel/index.js +6 -2
- package/lib/core/Designer/PageCompList/index.js +1 -1
- package/lib/core/Designer/index.js +4 -2
- package/lib/meta-comp/config-panels/ImageConfig/index.js +0 -2
- package/lib/meta-comp/config-panels/TextConfig/index.js +17 -7
- package/lib/meta-comp/config-panels/TextConfig/index.less +7 -0
- package/lib/utils/commonUtil.js +59 -89
- package/package.json +1 -1
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -267,7 +267,8 @@ function (_super) {
|
|
|
267
267
|
_this.getHeader = function (panel) {
|
|
268
268
|
var activeKey = _this.state.activeKey;
|
|
269
269
|
var name = panel.name,
|
|
270
|
-
key = panel.key
|
|
270
|
+
key = panel.key,
|
|
271
|
+
onClick = panel.onClick;
|
|
271
272
|
var _a = _this.props,
|
|
272
273
|
headerStyle = _a.headerStyle,
|
|
273
274
|
showActiveColor = _a.showActiveColor;
|
|
@@ -277,6 +278,7 @@ function (_super) {
|
|
|
277
278
|
} : {};
|
|
278
279
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
279
280
|
className: "header_wrap",
|
|
281
|
+
onClick: onClick,
|
|
280
282
|
onMouseEnter: function onMouseEnter() {
|
|
281
283
|
return _this.headerMouseEnter(panel);
|
|
282
284
|
},
|
package/es/common/Field/index.js
CHANGED
|
@@ -72,13 +72,14 @@ function (_super) {
|
|
|
72
72
|
topSplit = _a.topSplit,
|
|
73
73
|
rest = __rest(_a, ["title", "children", "layout", "split", "topSplit"]);
|
|
74
74
|
|
|
75
|
-
return /*#__PURE__*/_react["default"].createElement("div", _extends({
|
|
76
|
-
className: (0, _classnames["default"])('m-field', {
|
|
75
|
+
return /*#__PURE__*/_react["default"].createElement("div", _extends({}, rest, {
|
|
76
|
+
className: (0, _classnames["default"])('m-field', "" + rest.className, {
|
|
77
77
|
split: split,
|
|
78
78
|
topSplit: topSplit,
|
|
79
|
-
bold: split === 'bold'
|
|
79
|
+
bold: split === 'bold',
|
|
80
|
+
solid: split === 'solid'
|
|
80
81
|
})
|
|
81
|
-
}
|
|
82
|
+
}), /*#__PURE__*/_react["default"].createElement("div", {
|
|
82
83
|
className: (0, _classnames["default"])('field-item', {
|
|
83
84
|
horizontal: layout === 'horizontal'
|
|
84
85
|
})
|
|
@@ -114,6 +114,7 @@ function (_super) {
|
|
|
114
114
|
var data = this.props.data;
|
|
115
115
|
var GAData = (0, _commonUtil.getGAData)(data);
|
|
116
116
|
var isHorizontal = data.customize.layout.h5Layout === 'layout2';
|
|
117
|
+
var isFluidLayout = data.customize.layout.h5Layout === 'layout3' || data.customize.layout.h5Layout === 'layout4';
|
|
117
118
|
var colNum = isHorizontal ? data.customize.rowNum : 1;
|
|
118
119
|
var newData = data.groupSource.reduce(function (prev, curr, index) {
|
|
119
120
|
var i = Math.floor(index / colNum);
|
|
@@ -122,7 +123,7 @@ function (_super) {
|
|
|
122
123
|
}, []);
|
|
123
124
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
124
125
|
className: "m-image-gallery-mobile"
|
|
125
|
-
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
126
|
+
}, !isFluidLayout && /*#__PURE__*/_react["default"].createElement("div", {
|
|
126
127
|
className: "content"
|
|
127
128
|
}, newData.map(function (arr, index) {
|
|
128
129
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
@@ -150,7 +151,37 @@ function (_super) {
|
|
|
150
151
|
maxWidth: "100%"
|
|
151
152
|
}));
|
|
152
153
|
}));
|
|
153
|
-
}))
|
|
154
|
+
})), data.customize.layout.h5Layout === 'layout3' && /*#__PURE__*/_react["default"].createElement("div", {
|
|
155
|
+
className: "fluid-content"
|
|
156
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
157
|
+
className: "left-img"
|
|
158
|
+
}, /*#__PURE__*/_react["default"].createElement(_components.MetaImage, {
|
|
159
|
+
data: data.groupSource[0].image,
|
|
160
|
+
maxWidth: "100%"
|
|
161
|
+
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
162
|
+
className: "right-img"
|
|
163
|
+
}, /*#__PURE__*/_react["default"].createElement(_components.MetaImage, {
|
|
164
|
+
data: data.groupSource[1].image,
|
|
165
|
+
maxWidth: "100%"
|
|
166
|
+
}), /*#__PURE__*/_react["default"].createElement(_components.MetaImage, {
|
|
167
|
+
data: data.groupSource[2].image,
|
|
168
|
+
maxWidth: "100%"
|
|
169
|
+
}))), data.customize.layout.h5Layout === 'layout4' && /*#__PURE__*/_react["default"].createElement("div", {
|
|
170
|
+
className: "fluid-content"
|
|
171
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
172
|
+
className: "left-img"
|
|
173
|
+
}, /*#__PURE__*/_react["default"].createElement(_components.MetaImage, {
|
|
174
|
+
data: data.groupSource[0].image,
|
|
175
|
+
maxWidth: "100%"
|
|
176
|
+
}), /*#__PURE__*/_react["default"].createElement(_components.MetaImage, {
|
|
177
|
+
data: data.groupSource[1].image,
|
|
178
|
+
maxWidth: "100%"
|
|
179
|
+
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
180
|
+
className: "right-img"
|
|
181
|
+
}, /*#__PURE__*/_react["default"].createElement(_components.MetaImage, {
|
|
182
|
+
data: data.groupSource[2].image,
|
|
183
|
+
maxWidth: "100%"
|
|
184
|
+
}))));
|
|
154
185
|
};
|
|
155
186
|
|
|
156
187
|
ImageGalleryMobile.defaultProps = {
|
|
@@ -16,3 +16,18 @@
|
|
|
16
16
|
align-items: center;
|
|
17
17
|
justify-content: center;
|
|
18
18
|
}
|
|
19
|
+
.m-image-gallery-mobile .fluid-content {
|
|
20
|
+
display: flex;
|
|
21
|
+
}
|
|
22
|
+
.m-image-gallery-mobile .fluid-content > div {
|
|
23
|
+
width: calc((100% - 0.4rem) / 2);
|
|
24
|
+
}
|
|
25
|
+
.m-image-gallery-mobile .fluid-content .left-img > div:nth-child(2) {
|
|
26
|
+
margin-top: 0.2rem;
|
|
27
|
+
}
|
|
28
|
+
.m-image-gallery-mobile .fluid-content .right-img {
|
|
29
|
+
margin-left: 0.4rem;
|
|
30
|
+
}
|
|
31
|
+
.m-image-gallery-mobile .fluid-content .right-img > div:nth-child(2) {
|
|
32
|
+
margin-top: 0.2rem;
|
|
33
|
+
}
|
|
@@ -124,7 +124,8 @@ function (_super) {
|
|
|
124
124
|
key: group.id,
|
|
125
125
|
className: "video-item-wrap",
|
|
126
126
|
style: (0, _commonUtil.pxToRem)({
|
|
127
|
-
height: data.mobileHeight
|
|
127
|
+
height: data.mobileHeight,
|
|
128
|
+
borderRadius: data.arc
|
|
128
129
|
})
|
|
129
130
|
}, /*#__PURE__*/_react["default"].createElement(_common.Video, {
|
|
130
131
|
ref: function ref(el) {
|
|
@@ -156,7 +156,8 @@ function (_super) {
|
|
|
156
156
|
key: group.id,
|
|
157
157
|
className: "video-item-wrap",
|
|
158
158
|
style: (0, _commonUtil.pxToRem)({
|
|
159
|
-
height: data.mobileHeight
|
|
159
|
+
height: data.mobileHeight,
|
|
160
|
+
borderRadius: data.arc
|
|
160
161
|
})
|
|
161
162
|
}, /*#__PURE__*/_react["default"].createElement(_common.Video, {
|
|
162
163
|
ref: function ref(el) {
|
|
@@ -126,7 +126,8 @@ function (_super) {
|
|
|
126
126
|
key: group.id,
|
|
127
127
|
className: "video-item-wrap",
|
|
128
128
|
style: (0, _commonUtil.pxToRem)({
|
|
129
|
-
height: data.mobileHeight
|
|
129
|
+
height: data.mobileHeight,
|
|
130
|
+
borderRadius: data.arc
|
|
130
131
|
})
|
|
131
132
|
}, /*#__PURE__*/_react["default"].createElement(_common.Video, {
|
|
132
133
|
ref: function ref(el) {
|
|
@@ -123,7 +123,8 @@ function (_super) {
|
|
|
123
123
|
key: group.id,
|
|
124
124
|
className: "video-item-wrap",
|
|
125
125
|
style: {
|
|
126
|
-
height: data.pcHeight
|
|
126
|
+
height: data.pcHeight,
|
|
127
|
+
borderRadius: data.arc
|
|
127
128
|
}
|
|
128
129
|
}, /*#__PURE__*/_react["default"].createElement(_common.Video, {
|
|
129
130
|
ref: function ref(el) {
|
|
@@ -128,7 +128,10 @@ function (_super) {
|
|
|
128
128
|
}
|
|
129
129
|
}, firstGroup && /*#__PURE__*/_react["default"].createElement("div", {
|
|
130
130
|
key: firstGroup.id,
|
|
131
|
-
className: "video-left-wrap"
|
|
131
|
+
className: "video-left-wrap",
|
|
132
|
+
style: {
|
|
133
|
+
borderRadius: data.arc
|
|
134
|
+
}
|
|
132
135
|
}, /*#__PURE__*/_react["default"].createElement(_common.Video, {
|
|
133
136
|
ref: function ref(el) {
|
|
134
137
|
if (!_this.videoRefMap[firstGroup.id]) {
|
|
@@ -181,7 +184,10 @@ function (_super) {
|
|
|
181
184
|
var isPlaying = !!((_a = _this.videoRefMap[group.id]) === null || _a === void 0 ? void 0 : _a.playing);
|
|
182
185
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
183
186
|
key: group.id,
|
|
184
|
-
className: "video-item-wrap"
|
|
187
|
+
className: "video-item-wrap",
|
|
188
|
+
style: {
|
|
189
|
+
borderRadius: data.arc
|
|
190
|
+
}
|
|
185
191
|
}, /*#__PURE__*/_react["default"].createElement(_common.Video, {
|
|
186
192
|
ref: function ref(el) {
|
|
187
193
|
if (!_this.videoRefMap[group.id]) {
|
|
@@ -24,6 +24,7 @@
|
|
|
24
24
|
height: 100%;
|
|
25
25
|
position: relative;
|
|
26
26
|
width: 50%;
|
|
27
|
+
overflow: hidden;
|
|
27
28
|
|
|
28
29
|
.play-btn {
|
|
29
30
|
position: absolute;
|
|
@@ -48,6 +49,7 @@
|
|
|
48
49
|
flex-direction: column;
|
|
49
50
|
flex: 1;
|
|
50
51
|
width: 100%;
|
|
52
|
+
overflow: hidden;
|
|
51
53
|
|
|
52
54
|
.play-btn {
|
|
53
55
|
position: absolute;
|
|
@@ -133,7 +133,10 @@ function (_super) {
|
|
|
133
133
|
var isPlaying = !!((_a = _this.videoRefMap[group.id]) === null || _a === void 0 ? void 0 : _a.playing);
|
|
134
134
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
135
135
|
key: group.id,
|
|
136
|
-
className: "video-item-wrap"
|
|
136
|
+
className: "video-item-wrap",
|
|
137
|
+
style: {
|
|
138
|
+
borderRadius: data.arc
|
|
139
|
+
}
|
|
137
140
|
}, /*#__PURE__*/_react["default"].createElement(_common.Video, {
|
|
138
141
|
ref: function ref(el) {
|
|
139
142
|
if (!_this.videoRefMap[group.id]) {
|
|
@@ -126,7 +126,8 @@ function (_super) {
|
|
|
126
126
|
key: group.id,
|
|
127
127
|
className: "video-item-wrap",
|
|
128
128
|
style: {
|
|
129
|
-
height: data.pcHeight
|
|
129
|
+
height: data.pcHeight,
|
|
130
|
+
borderRadius: data.arc
|
|
130
131
|
}
|
|
131
132
|
}, /*#__PURE__*/_react["default"].createElement(_common.Video, {
|
|
132
133
|
ref: function ref(el) {
|
|
@@ -126,7 +126,8 @@ function (_super) {
|
|
|
126
126
|
key: group.id,
|
|
127
127
|
className: "video-item-wrap",
|
|
128
128
|
style: {
|
|
129
|
-
height: data.pcHeight
|
|
129
|
+
height: data.pcHeight,
|
|
130
|
+
borderRadius: data.arc
|
|
130
131
|
}
|
|
131
132
|
}, /*#__PURE__*/_react["default"].createElement(_common.Video, {
|
|
132
133
|
ref: function ref(el) {
|
package/es/composite-comp/bol/config-panels/ImageGalleryConfig/ImageGalleryConfigImageGroup/index.js
CHANGED
|
@@ -131,6 +131,7 @@ function (_super) {
|
|
|
131
131
|
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
132
132
|
className: "btn_wrap"
|
|
133
133
|
}, /*#__PURE__*/_react["default"].createElement(_Button["default"], {
|
|
134
|
+
disabled: source.length >= 3,
|
|
134
135
|
icon: "icon-add",
|
|
135
136
|
onClick: this.onAddClick,
|
|
136
137
|
type: "primary"
|
|
@@ -58,7 +58,7 @@ function ImageGalleryConfig(props) {
|
|
|
58
58
|
component: "imageGallery",
|
|
59
59
|
data: data.customize,
|
|
60
60
|
isHideAlign: true,
|
|
61
|
-
layoutSource: _layout.imageGalleryLayout,
|
|
61
|
+
layoutSource: (0, _coreUtil.isPc)() ? _layout.imageGalleryPcLayout : _layout.imageGalleryLayout,
|
|
62
62
|
selectedLayoutFun: function selectedLayoutFun(v) {
|
|
63
63
|
return getLayout(v);
|
|
64
64
|
}
|
|
@@ -128,6 +128,18 @@ function (_super) {
|
|
|
128
128
|
},
|
|
129
129
|
unit: "px",
|
|
130
130
|
value: data[(0, _coreUtil.isPc)() ? 'pcHeight' : 'mobileHeight']
|
|
131
|
+
})), /*#__PURE__*/_react["default"].createElement(_common.Field, {
|
|
132
|
+
title: "Arc"
|
|
133
|
+
}, /*#__PURE__*/_react["default"].createElement(_common.Slider, {
|
|
134
|
+
onChange: function onChange(_a) {
|
|
135
|
+
var count = _a.count;
|
|
136
|
+
data.arc = count;
|
|
137
|
+
|
|
138
|
+
_this.selfRender();
|
|
139
|
+
},
|
|
140
|
+
value: {
|
|
141
|
+
count: data.arc
|
|
142
|
+
}
|
|
131
143
|
})))
|
|
132
144
|
}, {
|
|
133
145
|
key: 'Spacing',
|
|
@@ -163,7 +163,7 @@ function (_super) {
|
|
|
163
163
|
}, data.url && /*#__PURE__*/_react["default"].createElement("img", {
|
|
164
164
|
alt: "welcome advertise",
|
|
165
165
|
onClick: function onClick() {
|
|
166
|
-
(
|
|
166
|
+
if (window.magicDesign.h5JumpUrlConfig) window.magicDesign.h5JumpUrlConfig(data.adObj, 'voucherRedeemed');
|
|
167
167
|
},
|
|
168
168
|
src: data.url
|
|
169
169
|
}));
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.groupSourceJSON = exports.getDefaultJSON = void 0;
|
|
7
|
+
|
|
8
|
+
var _uuid = require("uuid");
|
|
9
|
+
|
|
10
|
+
var groupSourceJSON = function groupSourceJSON(parentId, type) {
|
|
11
|
+
var groupId = (0, _uuid.v4)();
|
|
12
|
+
return {
|
|
13
|
+
id: groupId,
|
|
14
|
+
parentId: parentId,
|
|
15
|
+
type: type,
|
|
16
|
+
open: true,
|
|
17
|
+
groupName: {
|
|
18
|
+
parentId: groupId,
|
|
19
|
+
id: (0, _uuid.v4)(),
|
|
20
|
+
open: true,
|
|
21
|
+
type: 'TEXT',
|
|
22
|
+
specialContent: [],
|
|
23
|
+
text: 'PAYDAY SALE!',
|
|
24
|
+
content: {
|
|
25
|
+
sizeType: 'Customize font styles',
|
|
26
|
+
fontWeight: 700,
|
|
27
|
+
fontSize: 10,
|
|
28
|
+
color: '#0038A7'
|
|
29
|
+
},
|
|
30
|
+
underline: {
|
|
31
|
+
open: false,
|
|
32
|
+
textDecorationColor: '',
|
|
33
|
+
textDecorationStyle: 'solid'
|
|
34
|
+
},
|
|
35
|
+
vertical: {}
|
|
36
|
+
}
|
|
37
|
+
};
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
exports.groupSourceJSON = groupSourceJSON;
|
|
41
|
+
|
|
42
|
+
var getDefaultJSON = function getDefaultJSON() {
|
|
43
|
+
var groupId = (0, _uuid.v4)();
|
|
44
|
+
return {
|
|
45
|
+
id: (0, _uuid.v4)(),
|
|
46
|
+
type: 'CAMPAIGN',
|
|
47
|
+
title: {
|
|
48
|
+
headline: {
|
|
49
|
+
id: (0, _uuid.v4)(),
|
|
50
|
+
open: true,
|
|
51
|
+
type: 'TEXT',
|
|
52
|
+
specialContent: [],
|
|
53
|
+
text: 'Lorem Ipsum',
|
|
54
|
+
content: {
|
|
55
|
+
sizeType: 'Customize font styles',
|
|
56
|
+
fontWeight: 600,
|
|
57
|
+
fontSize: 14,
|
|
58
|
+
color: '#000000'
|
|
59
|
+
},
|
|
60
|
+
underline: {
|
|
61
|
+
open: false,
|
|
62
|
+
textDecorationColor: '',
|
|
63
|
+
textDecorationStyle: 'solid'
|
|
64
|
+
},
|
|
65
|
+
vertical: {
|
|
66
|
+
open: false,
|
|
67
|
+
lineHeight: 18
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
content: {
|
|
72
|
+
image: {
|
|
73
|
+
id: (0, _uuid.v4)(),
|
|
74
|
+
open: true,
|
|
75
|
+
type: 'IMAGE',
|
|
76
|
+
content: {
|
|
77
|
+
h5Name: 'name2',
|
|
78
|
+
pcName: 'name2',
|
|
79
|
+
h5ImgSrc: '',
|
|
80
|
+
pcImgSrc: '',
|
|
81
|
+
clickUrl: ''
|
|
82
|
+
},
|
|
83
|
+
hover: {
|
|
84
|
+
open: false,
|
|
85
|
+
backgroundType: 'enlarge',
|
|
86
|
+
magnification: 1.5,
|
|
87
|
+
pcImgHoverUrl: '',
|
|
88
|
+
h5ImgHoverUrl: ''
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
},
|
|
92
|
+
groupSource: [groupSourceJSON(groupId, 'Flash Sale'), groupSourceJSON(groupId, 'Group Buy'), groupSourceJSON(groupId, 'Bargain')],
|
|
93
|
+
spacing: {
|
|
94
|
+
mobile: {
|
|
95
|
+
paddingTop: 0,
|
|
96
|
+
paddingBottom: 0,
|
|
97
|
+
marginBottom: 0
|
|
98
|
+
}
|
|
99
|
+
},
|
|
100
|
+
customize: {
|
|
101
|
+
layout: 'layout1'
|
|
102
|
+
},
|
|
103
|
+
background: {
|
|
104
|
+
opacity: 100,
|
|
105
|
+
color: '#fff',
|
|
106
|
+
image: '',
|
|
107
|
+
bgType: 'color'
|
|
108
|
+
}
|
|
109
|
+
};
|
|
110
|
+
};
|
|
111
|
+
|
|
112
|
+
exports.getDefaultJSON = getDefaultJSON;
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = void 0;
|
|
7
|
+
|
|
8
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
9
|
+
|
|
10
|
+
var _mobile = _interopRequireDefault(require("./mobile"));
|
|
11
|
+
|
|
12
|
+
var _defaultJSON = require("./defaultJSON");
|
|
13
|
+
|
|
14
|
+
var _coreUtil = require("../../../../utils/coreUtil");
|
|
15
|
+
|
|
16
|
+
var _compositeDecorator = _interopRequireDefault(require("../../../../decorator/compositeDecorator"));
|
|
17
|
+
|
|
18
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
19
|
+
|
|
20
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
21
|
+
|
|
22
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
23
|
+
|
|
24
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
25
|
+
|
|
26
|
+
var __extends = void 0 && (void 0).__extends || function () {
|
|
27
|
+
var _extendStatics = function extendStatics(d, b) {
|
|
28
|
+
_extendStatics = Object.setPrototypeOf || {
|
|
29
|
+
__proto__: []
|
|
30
|
+
} instanceof Array && function (d, b) {
|
|
31
|
+
d.__proto__ = b;
|
|
32
|
+
} || function (d, b) {
|
|
33
|
+
for (var p in b) {
|
|
34
|
+
if (b.hasOwnProperty(p)) d[p] = b[p];
|
|
35
|
+
}
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
return _extendStatics(d, b);
|
|
39
|
+
};
|
|
40
|
+
|
|
41
|
+
return function (d, b) {
|
|
42
|
+
_extendStatics(d, b);
|
|
43
|
+
|
|
44
|
+
function __() {
|
|
45
|
+
this.constructor = d;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
49
|
+
};
|
|
50
|
+
}();
|
|
51
|
+
|
|
52
|
+
var __decorate = void 0 && (void 0).__decorate || function (decorators, target, key, desc) {
|
|
53
|
+
var c = arguments.length,
|
|
54
|
+
r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc,
|
|
55
|
+
d;
|
|
56
|
+
if ((typeof Reflect === "undefined" ? "undefined" : _typeof(Reflect)) === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) {
|
|
57
|
+
if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
58
|
+
}
|
|
59
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
60
|
+
};
|
|
61
|
+
|
|
62
|
+
var Campaign =
|
|
63
|
+
/** @class */
|
|
64
|
+
function (_super) {
|
|
65
|
+
__extends(Campaign, _super);
|
|
66
|
+
|
|
67
|
+
function Campaign() {
|
|
68
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
Campaign.prototype.render = function () {
|
|
72
|
+
var nodeData = this.props.nodeData;
|
|
73
|
+
return /*#__PURE__*/_react["default"].createElement("div", null, (0, _coreUtil.isPc)() ? null : /*#__PURE__*/_react["default"].createElement(_mobile["default"], {
|
|
74
|
+
panelProps: nodeData
|
|
75
|
+
}));
|
|
76
|
+
};
|
|
77
|
+
|
|
78
|
+
Campaign.defaultProps = {
|
|
79
|
+
nodeData: (0, _defaultJSON.getDefaultJSON)()
|
|
80
|
+
};
|
|
81
|
+
Campaign.type = 'CAMPAIGN';
|
|
82
|
+
Campaign.getDefaultJSON = _defaultJSON.getDefaultJSON;
|
|
83
|
+
Campaign = __decorate([_compositeDecorator["default"]], Campaign);
|
|
84
|
+
return Campaign;
|
|
85
|
+
}(_react.Component);
|
|
86
|
+
|
|
87
|
+
var _default = Campaign;
|
|
88
|
+
exports["default"] = _default;
|