@fonixtree/magic-design 2.0.30 → 2.0.32
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/less/modal.less +1 -1
- package/es/common/ImageLazy/index.js +6 -5
- package/es/common/LinkModal/FilteredProductModal/index.js +7 -3
- package/es/common/LinkModal/FilteredProductModal/index.less +1 -1
- package/es/common/LinkModal/index.js +1 -1
- package/es/common/ProductModal/index.js +23 -30
- package/es/composite-comp/bol/components/Banner/mobile/index.js +6 -0
- package/es/composite-comp/bol/components/Carousel/index.js +16 -23
- package/es/composite-comp/bol/components/Carousel/mobile/index.js +7 -18
- package/es/composite-comp/bol/components/Video/defaultJSON.js +24 -0
- package/es/composite-comp/bol/config-panels/TagCompConfig/imgs/layout1.png +0 -0
- package/es/composite-comp/bol/second-config-panels/VideoSecondConfig/index.js +0 -1
- package/es/composite-comp/common/components/ProductItem/index.js +4 -2
- package/es/composite-comp/common/components/ProductItem/index.less +9 -0
- package/es/composite-comp/dito/components/Recommend/defaultJSON.js +1 -1
- package/es/composite-comp/dito/components/Recommend/mobile/index.js +14 -2
- package/es/composite-comp/dito/components/SignBoard/defaultJSON.js +41 -37
- package/es/composite-comp/dito/components/SignBoard/mobile/index.js +32 -27
- package/es/composite-comp/dito/components/SignBoard/mobile/index.less +0 -14
- package/es/composite-comp/dito/components/SignBoard/pc/index.js +8 -11
- package/es/composite-comp/dito/config-panels/SignBoardConfig/SignBoardConfigContent/index.js +9 -47
- package/es/composite-comp/dito/config-panels/SignBoardConfig/index.js +9 -2
- package/es/composite-comp/dito/second-config-panels/RecommendSecondConfig/AIRecommendation/index.js +3 -3
- package/es/composite-comp/dito/second-config-panels/RecommendSecondConfig/index.js +14 -2
- package/es/core/Designer/ToolBarModal/index.js +16 -4
- package/es/core/Designer/index.js +3 -0
- package/es/decorator/index.js +38 -1
- package/es/decorator/lazyLoadDecorator.js +75 -0
- package/es/locale/en/en.json +1 -1
- package/es/locale/es/es.json +1 -1
- package/es/locale/id/id.json +1 -1
- package/es/meta-comp/components/Button/index.js +7 -0
- package/es/meta-comp/components/Text/formats/fontStyle.js +58 -0
- package/es/meta-comp/components/Text/index.js +9 -0
- package/es/meta-comp/config-panels/ButtonConfig/index.js +30 -28
- package/es/utils/commonUtil.js +17 -3
- package/es/utils/currencyUtil.js +29 -10
- package/lib/assets/less/modal.less +1 -1
- package/lib/common/ImageLazy/index.js +6 -5
- package/lib/common/LinkModal/FilteredProductModal/index.js +7 -3
- package/lib/common/LinkModal/FilteredProductModal/index.less +1 -1
- package/lib/common/LinkModal/index.js +1 -1
- package/lib/common/ProductModal/index.js +23 -30
- package/lib/composite-comp/bol/components/Banner/mobile/index.js +6 -0
- package/lib/composite-comp/bol/components/Carousel/index.js +16 -23
- package/lib/composite-comp/bol/components/Carousel/mobile/index.js +7 -18
- package/lib/composite-comp/bol/components/Video/defaultJSON.js +24 -0
- package/lib/composite-comp/bol/config-panels/TagCompConfig/imgs/layout1.png +0 -0
- package/lib/composite-comp/bol/second-config-panels/VideoSecondConfig/index.js +0 -1
- package/lib/composite-comp/common/components/ProductItem/index.js +4 -2
- package/lib/composite-comp/common/components/ProductItem/index.less +9 -0
- package/lib/composite-comp/dito/components/Recommend/defaultJSON.js +1 -1
- package/lib/composite-comp/dito/components/Recommend/mobile/index.js +14 -2
- package/lib/composite-comp/dito/components/SignBoard/defaultJSON.js +41 -37
- package/lib/composite-comp/dito/components/SignBoard/mobile/index.js +32 -27
- package/lib/composite-comp/dito/components/SignBoard/mobile/index.less +0 -14
- package/lib/composite-comp/dito/components/SignBoard/pc/index.js +8 -11
- package/lib/composite-comp/dito/config-panels/SignBoardConfig/SignBoardConfigContent/index.js +9 -47
- package/lib/composite-comp/dito/config-panels/SignBoardConfig/index.js +9 -2
- package/lib/composite-comp/dito/second-config-panels/RecommendSecondConfig/AIRecommendation/index.js +3 -3
- package/lib/composite-comp/dito/second-config-panels/RecommendSecondConfig/index.js +14 -2
- package/lib/core/Designer/ToolBarModal/index.js +16 -4
- package/lib/core/Designer/index.js +3 -0
- package/lib/decorator/index.js +38 -1
- package/lib/decorator/lazyLoadDecorator.js +75 -0
- package/lib/locale/en/en.json +1 -1
- package/lib/locale/es/es.json +1 -1
- package/lib/locale/id/id.json +1 -1
- package/lib/meta-comp/components/Button/index.js +7 -0
- package/lib/meta-comp/components/Text/formats/fontStyle.js +58 -0
- package/lib/meta-comp/components/Text/index.js +9 -0
- package/lib/meta-comp/config-panels/ButtonConfig/index.js +30 -28
- package/lib/utils/commonUtil.js +17 -3
- package/lib/utils/currencyUtil.js +29 -10
- package/package.json +1 -1
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/components/AlignPicker/AlignSelectPicker/index.js +0 -99
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/components/AlignPicker/AlignSelectPicker/index.less +0 -54
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/components/AlignPicker/images/AlignCenterSVG.js +0 -27
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/components/AlignPicker/images/AlignLeftSVG.js +0 -27
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/components/AlignPicker/images/AlignRightSVG.js +0 -27
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/components/AlignPicker/index.js +0 -96
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/components/AlignPicker/index.less +0 -26
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/components/ColorPickerBtn/index.js +0 -101
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/components/ColorPickerBtn/index.less +0 -26
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/components/LinkBtn/LinkInputPicker/index.js +0 -99
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/components/LinkBtn/LinkInputPicker/index.less +0 -39
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/components/LinkBtn/index.js +0 -93
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/components/LinkBtn/index.less +0 -26
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/images/BackgroundSVG.js +0 -27
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/images/BoldSVG.js +0 -29
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/images/FontColorSVG.js +0 -49
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/images/ItalicSVG.js +0 -29
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/images/LinkSVG.js +0 -26
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/images/OrderSVG.js +0 -27
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/images/StrikeSVG.js +0 -31
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/images/UnderlineSVG.js +0 -34
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/images/UnorderSVG.js +0 -41
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/index.js +0 -136
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/index.less +0 -25
- package/es/core/Designer/TextEditModal/ToolBar/ToolBtn/type.js +0 -1
- package/es/core/Designer/TextEditModal/ToolBar/index.js +0 -219
- package/es/core/Designer/TextEditModal/ToolBar/index.less +0 -19
- package/es/core/Designer/TextEditModal/index.js +0 -100
- package/es/core/Designer/TextEditModal/index.less +0 -4
- package/es/core/Designer/TextEditModal_old/index.js +0 -142
- package/es/core/Designer/TextEditModal_old/index.less +0 -25
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/components/AlignPicker/AlignSelectPicker/index.js +0 -99
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/components/AlignPicker/AlignSelectPicker/index.less +0 -54
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/components/AlignPicker/images/AlignCenterSVG.js +0 -27
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/components/AlignPicker/images/AlignLeftSVG.js +0 -27
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/components/AlignPicker/images/AlignRightSVG.js +0 -27
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/components/AlignPicker/index.js +0 -96
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/components/AlignPicker/index.less +0 -26
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/components/ColorPickerBtn/index.js +0 -101
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/components/ColorPickerBtn/index.less +0 -26
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/components/LinkBtn/LinkInputPicker/index.js +0 -99
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/components/LinkBtn/LinkInputPicker/index.less +0 -39
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/components/LinkBtn/index.js +0 -93
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/components/LinkBtn/index.less +0 -26
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/images/BackgroundSVG.js +0 -27
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/images/BoldSVG.js +0 -29
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/images/FontColorSVG.js +0 -49
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/images/ItalicSVG.js +0 -29
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/images/LinkSVG.js +0 -26
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/images/OrderSVG.js +0 -27
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/images/StrikeSVG.js +0 -31
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/images/UnderlineSVG.js +0 -34
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/images/UnorderSVG.js +0 -41
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/index.js +0 -136
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/index.less +0 -25
- package/lib/core/Designer/TextEditModal/ToolBar/ToolBtn/type.js +0 -1
- package/lib/core/Designer/TextEditModal/ToolBar/index.js +0 -219
- package/lib/core/Designer/TextEditModal/ToolBar/index.less +0 -19
- package/lib/core/Designer/TextEditModal/index.js +0 -100
- package/lib/core/Designer/TextEditModal/index.less +0 -4
- package/lib/core/Designer/TextEditModal_old/index.js +0 -142
- package/lib/core/Designer/TextEditModal_old/index.less +0 -25
|
@@ -133,7 +133,7 @@ function (_super) {
|
|
|
133
133
|
}
|
|
134
134
|
|
|
135
135
|
var pricePrefix = (0, _commonUtil.ensure)(function () {
|
|
136
|
-
return window.
|
|
136
|
+
return window.systemParams.prefix;
|
|
137
137
|
}, 'Rp');
|
|
138
138
|
|
|
139
139
|
var _price = pricePrefix + " " + integerPart + " " + (decimalPart ? '.' + decimalPart : '');
|
|
@@ -226,7 +226,9 @@ function (_super) {
|
|
|
226
226
|
style: {
|
|
227
227
|
width: salePercent + "%"
|
|
228
228
|
}
|
|
229
|
-
})))
|
|
229
|
+
}))), !showProgress && data.salesCnt > 0 && /*#__PURE__*/_react["default"].createElement("div", {
|
|
230
|
+
className: "sold-count"
|
|
231
|
+
}, (0, _commonUtil.convertCount)(data.salesCnt), " sold")));
|
|
230
232
|
};
|
|
231
233
|
|
|
232
234
|
ProductItem.defaultProps = {
|
|
@@ -635,7 +635,14 @@ function (_super) {
|
|
|
635
635
|
layout: layout === 'layout2' ? 'horizontal' : 'vertical' // onItemClick={() => clickUrl(`/product/detail/${item.offerId}?productId=${item.sppProductId || item.productId || ''}`)}
|
|
636
636
|
,
|
|
637
637
|
onItemClick: function onItemClick() {
|
|
638
|
-
|
|
638
|
+
/** PTO 定制GA */
|
|
639
|
+
if (window.magicDesign.pushGA) {
|
|
640
|
+
window.magicDesign.pushGA(item, 'select_item', {
|
|
641
|
+
event_action: 'Select Item'
|
|
642
|
+
});
|
|
643
|
+
}
|
|
644
|
+
|
|
645
|
+
(0, _coreUtil.clickUrl)("proDetail-" + item.offerId + "-" + (item.sppProductId || item.productId || ''));
|
|
639
646
|
},
|
|
640
647
|
panelProps: panelProps.content,
|
|
641
648
|
showProgress: false
|
|
@@ -661,7 +668,12 @@ function (_super) {
|
|
|
661
668
|
imgWidth: imgWidth // onItemClick={() => clickUrl(`/product/detail/${item.offerId}?productId=${item.sppProductId || item.productId || ''}`)}
|
|
662
669
|
,
|
|
663
670
|
onItemClick: function onItemClick() {
|
|
664
|
-
|
|
671
|
+
/** PTO 定制GA */
|
|
672
|
+
if (window.magicDesign.pushGA) {
|
|
673
|
+
window.magicDesign.pushGA({}, 'select_item', item);
|
|
674
|
+
}
|
|
675
|
+
|
|
676
|
+
(0, _coreUtil.clickUrl)("proDetail-" + item.offerId + "-" + (item.sppProductId || item.productId || ''));
|
|
665
677
|
},
|
|
666
678
|
panelProps: panelProps.content,
|
|
667
679
|
showProgress: false
|
|
@@ -11,43 +11,47 @@ var getDefaultJSON = function getDefaultJSON() {
|
|
|
11
11
|
return {
|
|
12
12
|
id: (0, _uuid.v4)(),
|
|
13
13
|
type: 'SIGN_BOARD',
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
14
|
+
content: {
|
|
15
|
+
logo: {
|
|
16
|
+
id: (0, _uuid.v4)(),
|
|
17
|
+
open: true,
|
|
18
|
+
type: 'IMAGE',
|
|
19
|
+
content: {
|
|
20
|
+
h5Name: 'name2',
|
|
21
|
+
pcName: 'name2',
|
|
22
|
+
h5ImgSrc: '',
|
|
23
|
+
pcImgSrc: '',
|
|
24
|
+
clickUrl: ''
|
|
25
|
+
},
|
|
26
|
+
hover: {
|
|
27
|
+
open: false,
|
|
28
|
+
backgroundType: 'enlarge',
|
|
29
|
+
magnification: 1.5,
|
|
30
|
+
pcImgHoverUrl: '',
|
|
31
|
+
h5ImgHoverUrl: ''
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
title: {
|
|
35
|
+
id: (0, _uuid.v4)(),
|
|
36
|
+
open: true,
|
|
37
|
+
type: 'TEXT',
|
|
38
|
+
specialContent: [],
|
|
39
|
+
text: 'Title',
|
|
40
|
+
content: {
|
|
41
|
+
sizeType: 'Customize font styles',
|
|
42
|
+
fontFamily: 'Open Sans',
|
|
43
|
+
fontWeight: 600,
|
|
44
|
+
fontSize: 16,
|
|
45
|
+
color: '#070707'
|
|
46
|
+
},
|
|
47
|
+
underline: {
|
|
48
|
+
open: false,
|
|
49
|
+
textDecorationColor: '',
|
|
50
|
+
textDecorationStyle: 'solid'
|
|
51
|
+
},
|
|
52
|
+
vertical: {}
|
|
53
|
+
}
|
|
54
|
+
},
|
|
51
55
|
spacing: {
|
|
52
56
|
pc: {
|
|
53
57
|
paddingTop: 20,
|
|
@@ -13,8 +13,6 @@ var _antd = require("antd");
|
|
|
13
13
|
|
|
14
14
|
var _common = require("../../../../../common");
|
|
15
15
|
|
|
16
|
-
var _storeLogo = _interopRequireDefault(require("../imgs/storeLogo.png"));
|
|
17
|
-
|
|
18
16
|
var _coreUtil = require("../../../../../utils/coreUtil");
|
|
19
17
|
|
|
20
18
|
var _star = _interopRequireDefault(require("../imgs/star.svg"));
|
|
@@ -23,6 +21,8 @@ var _commonUtil = require("../../../../../utils/commonUtil");
|
|
|
23
21
|
|
|
24
22
|
var _locale = require("../../../../../locale");
|
|
25
23
|
|
|
24
|
+
var _components = require("../../../../../meta-comp/components");
|
|
25
|
+
|
|
26
26
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
27
27
|
|
|
28
28
|
var __extends = void 0 && (void 0).__extends || function () {
|
|
@@ -210,10 +210,9 @@ function (_super) {
|
|
|
210
210
|
|
|
211
211
|
_this.getStoreInfo = function () {
|
|
212
212
|
return __awaiter(_this, void 0, void 0, function () {
|
|
213
|
-
var storeId,
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
switch (_b.label) {
|
|
213
|
+
var storeId, storeDetailInfo;
|
|
214
|
+
return __generator(this, function (_a) {
|
|
215
|
+
switch (_a.label) {
|
|
217
216
|
case 0:
|
|
218
217
|
storeId = window.magicDesign.storeId;
|
|
219
218
|
if (!storeId) return [3
|
|
@@ -221,17 +220,15 @@ function (_super) {
|
|
|
221
220
|
, 2];
|
|
222
221
|
return [4
|
|
223
222
|
/*yield*/
|
|
224
|
-
,
|
|
225
|
-
storeId: storeId
|
|
226
|
-
})])];
|
|
223
|
+
, (0, _commonUtil.commonFetch)("/designer/v1/h5/store/detail/" + storeId, {}, 'GET')];
|
|
227
224
|
|
|
228
225
|
case 1:
|
|
229
|
-
|
|
226
|
+
storeDetailInfo = _a.sent();
|
|
230
227
|
this.setState({
|
|
231
|
-
storeInfo:
|
|
232
|
-
isFollow:
|
|
228
|
+
storeInfo: storeDetailInfo,
|
|
229
|
+
isFollow: storeDetailInfo.userHasFollowed == 'Y'
|
|
233
230
|
});
|
|
234
|
-
|
|
231
|
+
_a.label = 2;
|
|
235
232
|
|
|
236
233
|
case 2:
|
|
237
234
|
return [2
|
|
@@ -320,8 +317,8 @@ function (_super) {
|
|
|
320
317
|
action: 'operation',
|
|
321
318
|
params: {
|
|
322
319
|
type: 'CHAT',
|
|
323
|
-
storeId: storeInfo.storeId,
|
|
324
|
-
sysAccount: storeInfo.sysAccount
|
|
320
|
+
storeId: storeInfo === null || storeInfo === void 0 ? void 0 : storeInfo.storeId,
|
|
321
|
+
sysAccount: storeInfo === null || storeInfo === void 0 ? void 0 : storeInfo.sysAccount
|
|
325
322
|
}
|
|
326
323
|
};
|
|
327
324
|
window.magicDesign.handleAction(params);
|
|
@@ -335,14 +332,16 @@ function (_super) {
|
|
|
335
332
|
};
|
|
336
333
|
|
|
337
334
|
SignBoardMobile.prototype.render = function () {
|
|
338
|
-
var _this = this;
|
|
339
|
-
|
|
335
|
+
var _this = this;
|
|
336
|
+
|
|
337
|
+
var _a, _b;
|
|
340
338
|
|
|
339
|
+
var data = this.props.data; // console.log('--SignBoard', data);
|
|
341
340
|
|
|
342
|
-
var
|
|
343
|
-
storeInfo =
|
|
344
|
-
isFollow =
|
|
345
|
-
inputVal =
|
|
341
|
+
var _c = this.state,
|
|
342
|
+
storeInfo = _c.storeInfo,
|
|
343
|
+
isFollow = _c.isFollow,
|
|
344
|
+
inputVal = _c.inputVal;
|
|
346
345
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
347
346
|
className: "m-sign-board-bar"
|
|
348
347
|
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
@@ -367,12 +366,18 @@ function (_super) {
|
|
|
367
366
|
type: "icon-search2"
|
|
368
367
|
}))), /*#__PURE__*/_react["default"].createElement("div", {
|
|
369
368
|
className: "store-info-wrap"
|
|
370
|
-
}, /*#__PURE__*/_react["default"].createElement("
|
|
371
|
-
className: "
|
|
372
|
-
|
|
369
|
+
}, data.content && ((_a = data.content.logo) === null || _a === void 0 ? void 0 : _a.open) && /*#__PURE__*/_react["default"].createElement("div", {
|
|
370
|
+
className: "logo"
|
|
371
|
+
}, /*#__PURE__*/_react["default"].createElement(_components.MetaImage, {
|
|
372
|
+
data: data.content.logo,
|
|
373
|
+
style: {
|
|
374
|
+
height: 44,
|
|
375
|
+
width: 44
|
|
376
|
+
}
|
|
377
|
+
})), data.content && ((_b = data.content.title) === null || _b === void 0 ? void 0 : _b.open) && /*#__PURE__*/_react["default"].createElement(_components.MetaText, {
|
|
378
|
+
className: "card-text",
|
|
379
|
+
data: data.content.title
|
|
373
380
|
}), /*#__PURE__*/_react["default"].createElement("div", {
|
|
374
|
-
className: "store-name"
|
|
375
|
-
}, (storeInfo === null || storeInfo === void 0 ? void 0 : storeInfo.storeName) || 'Compraqui'), /*#__PURE__*/_react["default"].createElement("div", {
|
|
376
381
|
onClick: this.clickCollect
|
|
377
382
|
}, /*#__PURE__*/_react["default"].createElement(_common.Iconfont, {
|
|
378
383
|
color: isFollow ? '#F1600F' : '#333333',
|
|
@@ -387,7 +392,7 @@ function (_super) {
|
|
|
387
392
|
src: _star["default"]
|
|
388
393
|
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
389
394
|
className: "number"
|
|
390
|
-
}, /*#__PURE__*/_react["default"].createElement("span", null, (storeInfo === null || storeInfo === void 0 ? void 0 : storeInfo.userCollectionNum) ||
|
|
395
|
+
}, /*#__PURE__*/_react["default"].createElement("span", null, (storeInfo === null || storeInfo === void 0 ? void 0 : storeInfo.userCollectionNum) || 0, " "), " ", (0, _locale.i18n)('FOLLOWERS')), (storeInfo === null || storeInfo === void 0 ? void 0 : storeInfo.hasCustomerService) === 'Y' && /*#__PURE__*/_react["default"].createElement("div", {
|
|
391
396
|
className: "chat-btn",
|
|
392
397
|
onClick: this.toChat
|
|
393
398
|
}, (0, _locale.i18n)('CHAT'))));
|
|
@@ -62,17 +62,3 @@
|
|
|
62
62
|
text-transform: uppercase;
|
|
63
63
|
color: #333333;
|
|
64
64
|
}
|
|
65
|
-
.m-sign-board-bar .store-info-wrap .store-logo {
|
|
66
|
-
width: 0.88rem;
|
|
67
|
-
height: 0.88rem;
|
|
68
|
-
border-radius: 50%;
|
|
69
|
-
}
|
|
70
|
-
.m-sign-board-bar .store-info-wrap .store-name {
|
|
71
|
-
flex: 1;
|
|
72
|
-
margin-left: 0.24rem;
|
|
73
|
-
font-weight: 500;
|
|
74
|
-
font-size: 0.32rem;
|
|
75
|
-
line-height: 0.4rem;
|
|
76
|
-
color: #070707;
|
|
77
|
-
font-family: 'Montserrat';
|
|
78
|
-
}
|
|
@@ -212,10 +212,9 @@ function (_super) {
|
|
|
212
212
|
|
|
213
213
|
_this.getStoreInfo = function () {
|
|
214
214
|
return __awaiter(_this, void 0, void 0, function () {
|
|
215
|
-
var storeId,
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
switch (_b.label) {
|
|
215
|
+
var storeId, storeDetailInfo;
|
|
216
|
+
return __generator(this, function (_a) {
|
|
217
|
+
switch (_a.label) {
|
|
219
218
|
case 0:
|
|
220
219
|
storeId = window.magicDesign.storeId;
|
|
221
220
|
if (!storeId) return [3
|
|
@@ -223,17 +222,15 @@ function (_super) {
|
|
|
223
222
|
, 2];
|
|
224
223
|
return [4
|
|
225
224
|
/*yield*/
|
|
226
|
-
,
|
|
227
|
-
storeId: storeId
|
|
228
|
-
})])];
|
|
225
|
+
, (0, _commonUtil.commonFetch)("/designer/v1/h5/store/detail/" + storeId, {}, 'GET')];
|
|
229
226
|
|
|
230
227
|
case 1:
|
|
231
|
-
|
|
228
|
+
storeDetailInfo = _a.sent();
|
|
232
229
|
this.setState({
|
|
233
|
-
storeInfo:
|
|
234
|
-
isFollow:
|
|
230
|
+
storeInfo: storeDetailInfo,
|
|
231
|
+
isFollow: storeDetailInfo.userHasFollowed == 'Y'
|
|
235
232
|
});
|
|
236
|
-
|
|
233
|
+
_a.label = 2;
|
|
237
234
|
|
|
238
235
|
case 2:
|
|
239
236
|
return [2
|
package/lib/composite-comp/dito/config-panels/SignBoardConfig/SignBoardConfigContent/index.js
CHANGED
|
@@ -15,6 +15,8 @@ var _ImageConfig = _interopRequireDefault(require("../../../../../meta-comp/conf
|
|
|
15
15
|
|
|
16
16
|
var _coreUtil = require("../../../../../utils/coreUtil");
|
|
17
17
|
|
|
18
|
+
var _TextConfig = _interopRequireDefault(require("../../../../../meta-comp/config-panels/TextConfig"));
|
|
19
|
+
|
|
18
20
|
var _locale = require("../../../../../locale");
|
|
19
21
|
|
|
20
22
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
@@ -67,11 +69,9 @@ function (_super) {
|
|
|
67
69
|
}
|
|
68
70
|
|
|
69
71
|
SignBoardConfigContent.prototype.render = function () {
|
|
70
|
-
var _this = this;
|
|
71
|
-
|
|
72
72
|
var panelProps = this.props.panelProps;
|
|
73
73
|
var source = [{
|
|
74
|
-
key: '
|
|
74
|
+
key: 'logo',
|
|
75
75
|
name: (0, _locale.i18n)('LOGO'),
|
|
76
76
|
value: /*#__PURE__*/_react["default"].createElement(_ImageConfig["default"], {
|
|
77
77
|
data: panelProps.logo
|
|
@@ -79,50 +79,12 @@ function (_super) {
|
|
|
79
79
|
metaOption: panelProps.logo,
|
|
80
80
|
toggleType: 'switch'
|
|
81
81
|
}, {
|
|
82
|
-
key: '
|
|
83
|
-
name: (0, _locale.i18n)('
|
|
84
|
-
value: /*#__PURE__*/_react["default"].createElement(
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
title: (0, _locale.i18n)('COLOR')
|
|
89
|
-
}, /*#__PURE__*/_react["default"].createElement(_common.ColorPickerInput, {
|
|
90
|
-
colorType: "rgba",
|
|
91
|
-
onChange: function onChange(v) {
|
|
92
|
-
if ((0, _coreUtil.isPc)()) {
|
|
93
|
-
panelProps.box.color.pc = v;
|
|
94
|
-
} else {
|
|
95
|
-
panelProps.box.color.mobile = v;
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
_this.selfRender();
|
|
99
|
-
},
|
|
100
|
-
value: (0, _coreUtil.isPc)() ? panelProps.box.color.pc : panelProps.box.color.mobile
|
|
101
|
-
})),
|
|
102
|
-
metaOption: panelProps.box,
|
|
103
|
-
toggleType: 'switch'
|
|
104
|
-
}, {
|
|
105
|
-
key: 'search3',
|
|
106
|
-
name: (0, _locale.i18n)('ICON'),
|
|
107
|
-
value: /*#__PURE__*/_react["default"].createElement(_common.Field, {
|
|
108
|
-
style: {
|
|
109
|
-
marginTop: 20
|
|
110
|
-
},
|
|
111
|
-
title: (0, _locale.i18n)('COLOR')
|
|
112
|
-
}, /*#__PURE__*/_react["default"].createElement(_common.ColorPickerInput, {
|
|
113
|
-
colorType: "rgba",
|
|
114
|
-
onChange: function onChange(v) {
|
|
115
|
-
if ((0, _coreUtil.isPc)()) {
|
|
116
|
-
panelProps.icon.color.pc = v;
|
|
117
|
-
} else {
|
|
118
|
-
panelProps.icon.color.mobile = v;
|
|
119
|
-
}
|
|
120
|
-
|
|
121
|
-
_this.selfRender();
|
|
122
|
-
},
|
|
123
|
-
value: (0, _coreUtil.isPc)() ? panelProps.icon.color.pc : panelProps.icon.color.mobile
|
|
124
|
-
})),
|
|
125
|
-
metaOption: panelProps.icon,
|
|
82
|
+
key: 'title',
|
|
83
|
+
name: (0, _locale.i18n)('TITLE'),
|
|
84
|
+
value: /*#__PURE__*/_react["default"].createElement(_TextConfig["default"], {
|
|
85
|
+
data: panelProps.title
|
|
86
|
+
}),
|
|
87
|
+
metaOption: panelProps.title,
|
|
126
88
|
toggleType: 'switch'
|
|
127
89
|
}];
|
|
128
90
|
return /*#__PURE__*/_react["default"].createElement(_common.Collapse, {
|
|
@@ -7,6 +7,8 @@ exports["default"] = void 0;
|
|
|
7
7
|
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
9
|
|
|
10
|
+
var _SignBoardConfigContent = _interopRequireDefault(require("./SignBoardConfigContent"));
|
|
11
|
+
|
|
10
12
|
var _locale = require("../../../../locale");
|
|
11
13
|
|
|
12
14
|
var _common = require("../../../../common");
|
|
@@ -57,8 +59,13 @@ function (_super) {
|
|
|
57
59
|
return /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement(_common.Collapse, {
|
|
58
60
|
divider: "bold",
|
|
59
61
|
headerSize: "large",
|
|
60
|
-
source: [
|
|
61
|
-
|
|
62
|
+
source: [{
|
|
63
|
+
key: 'signBoard1',
|
|
64
|
+
name: (0, _locale.i18n)('CONTENT'),
|
|
65
|
+
value: /*#__PURE__*/_react["default"].createElement(_SignBoardConfigContent["default"], {
|
|
66
|
+
panelProps: data.content
|
|
67
|
+
})
|
|
68
|
+
}, {
|
|
62
69
|
key: 'signBoard4',
|
|
63
70
|
name: (0, _locale.i18n)('SPACING'),
|
|
64
71
|
value: /*#__PURE__*/_react["default"].createElement(_SpacingConfig["default"], {
|
package/lib/composite-comp/dito/second-config-panels/RecommendSecondConfig/AIRecommendation/index.js
CHANGED
|
@@ -228,8 +228,8 @@ function (_super) {
|
|
|
228
228
|
this.setState({
|
|
229
229
|
intelligentType: type,
|
|
230
230
|
intelligentValue: []
|
|
231
|
-
});
|
|
232
|
-
|
|
231
|
+
}); // this.getTypeData(type);
|
|
232
|
+
|
|
233
233
|
this.props.onChange({
|
|
234
234
|
intelligentType: type,
|
|
235
235
|
intelligentValue: []
|
|
@@ -255,7 +255,7 @@ function (_super) {
|
|
|
255
255
|
];
|
|
256
256
|
return [4
|
|
257
257
|
/*yield*/
|
|
258
|
-
, (0, _commonUtil.commonFetch)("/designer/v1/" + window.magicDesign.MBaseUrl + "/offercatgs/list")];
|
|
258
|
+
, (0, _commonUtil.commonFetch)("/designer/v1/" + window.magicDesign.MBaseUrl + "/designer/resource/offercatgs/list")];
|
|
259
259
|
|
|
260
260
|
case 1:
|
|
261
261
|
res = _a.sent();
|
|
@@ -81,6 +81,18 @@ function (_super) {
|
|
|
81
81
|
|
|
82
82
|
_this.state = {};
|
|
83
83
|
|
|
84
|
+
_this.hasSource = function (type) {
|
|
85
|
+
if (!window.systemParams || !window.systemParams.recommendSource) {
|
|
86
|
+
return true;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
if (window.systemParams.recommendSource && window.systemParams.recommendSource.includes(type)) {
|
|
90
|
+
return true;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
return false;
|
|
94
|
+
};
|
|
95
|
+
|
|
84
96
|
_this.getContentPanel = function () {
|
|
85
97
|
var panelProps = _this.props.panelProps;
|
|
86
98
|
|
|
@@ -95,9 +107,9 @@ function (_super) {
|
|
|
95
107
|
_this.selfRender();
|
|
96
108
|
},
|
|
97
109
|
value: panelProps.sourceType
|
|
98
|
-
}, /*#__PURE__*/_react["default"].createElement(_antd.Select.Option, {
|
|
110
|
+
}, _this.hasSource('P') && /*#__PURE__*/_react["default"].createElement(_antd.Select.Option, {
|
|
99
111
|
value: "select"
|
|
100
|
-
}, (0, _locale.i18n)('SELECT_PRODUCT')), /*#__PURE__*/_react["default"].createElement(_antd.Select.Option, {
|
|
112
|
+
}, (0, _locale.i18n)('SELECT_PRODUCT')), _this.hasSource('A') && /*#__PURE__*/_react["default"].createElement(_antd.Select.Option, {
|
|
101
113
|
value: "recommend"
|
|
102
114
|
}, (0, _locale.i18n)('AI_RECOMMENDATION')))), /*#__PURE__*/_react["default"].createElement("div", {
|
|
103
115
|
className: "greyBg"
|
|
@@ -146,18 +146,30 @@ function (_super) {
|
|
|
146
146
|
_this.props.quillRef.format('font', value);
|
|
147
147
|
} else if (type == 'font-weight') {
|
|
148
148
|
_this.props.quillRef.format('font-weight', value);
|
|
149
|
+
} else if (type == 'font-style') {
|
|
150
|
+
_this.props.quillRef.format('font-style', 'italic' === quillFormat['font-style'] ? '' : 'italic');
|
|
149
151
|
} else if (type == 'font-family') {
|
|
150
152
|
_this.props.quillRef.format('font-family', value);
|
|
151
153
|
} else if (type == 'text-decoration-style') {
|
|
154
|
+
_this.props.quillRef.format('underline', true);
|
|
155
|
+
|
|
152
156
|
_this.props.quillRef.format('text-decoration-style', value);
|
|
153
157
|
} else if (type == 'bullet') {
|
|
154
158
|
_this.props.quillRef.format('list-style-type', value);
|
|
155
159
|
|
|
156
|
-
|
|
160
|
+
if (value === quillFormat['list-style-type']) {
|
|
161
|
+
_this.props.quillRef.format('list', '');
|
|
162
|
+
} else {
|
|
163
|
+
_this.props.quillRef.format('list', 'bullet');
|
|
164
|
+
}
|
|
157
165
|
} else if (type == 'ordered') {
|
|
158
166
|
_this.props.quillRef.format('list-style-type', value);
|
|
159
167
|
|
|
160
|
-
|
|
168
|
+
if (value === quillFormat['list-style-type']) {
|
|
169
|
+
_this.props.quillRef.format('list', '');
|
|
170
|
+
} else {
|
|
171
|
+
_this.props.quillRef.format('list', 'ordered');
|
|
172
|
+
}
|
|
161
173
|
} else if (type == 'text-decoration-color') {
|
|
162
174
|
if (value) {
|
|
163
175
|
_this.props.quillRef.format('underline', true);
|
|
@@ -269,9 +281,9 @@ function (_super) {
|
|
|
269
281
|
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
270
282
|
className: "tool-item"
|
|
271
283
|
}, /*#__PURE__*/_react["default"].createElement(_ToolBtn["default"], {
|
|
272
|
-
active: quillFormat['italic'
|
|
284
|
+
active: quillFormat['font-style'] === 'italic',
|
|
273
285
|
onChange: function onChange() {
|
|
274
|
-
_this.onToolBtnClick('
|
|
286
|
+
_this.onToolBtnClick('font-style');
|
|
275
287
|
},
|
|
276
288
|
type: "italic"
|
|
277
289
|
})), /*#__PURE__*/_react["default"].createElement("div", {
|
package/lib/decorator/index.js
CHANGED
|
@@ -9,12 +9,25 @@ Object.defineProperty(exports, "compositeDecorator", {
|
|
|
9
9
|
return _compositeDecorator["default"];
|
|
10
10
|
}
|
|
11
11
|
});
|
|
12
|
+
Object.defineProperty(exports, "lazy", {
|
|
13
|
+
enumerable: true,
|
|
14
|
+
get: function get() {
|
|
15
|
+
return _lazyLoadDecorator.lazy;
|
|
16
|
+
}
|
|
17
|
+
});
|
|
18
|
+
Object.defineProperty(exports, "lazyDestroy", {
|
|
19
|
+
enumerable: true,
|
|
20
|
+
get: function get() {
|
|
21
|
+
return _lazyLoadDecorator.lazyDestroy;
|
|
22
|
+
}
|
|
23
|
+
});
|
|
12
24
|
Object.defineProperty(exports, "metaDecorator", {
|
|
13
25
|
enumerable: true,
|
|
14
26
|
get: function get() {
|
|
15
27
|
return _metaDecorator["default"];
|
|
16
28
|
}
|
|
17
29
|
});
|
|
30
|
+
exports.shouldUpdate = shouldUpdate;
|
|
18
31
|
Object.defineProperty(exports, "updateConfigDecorator", {
|
|
19
32
|
enumerable: true,
|
|
20
33
|
get: function get() {
|
|
@@ -28,4 +41,28 @@ var _metaDecorator = _interopRequireDefault(require("./metaDecorator"));
|
|
|
28
41
|
|
|
29
42
|
var _updateConfigDecorator = _interopRequireDefault(require("./updateConfigDecorator"));
|
|
30
43
|
|
|
31
|
-
|
|
44
|
+
var _lazyLoadDecorator = require("./lazyLoadDecorator");
|
|
45
|
+
|
|
46
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
47
|
+
|
|
48
|
+
/* eslint-disable @typescript-eslint/no-unused-expressions */
|
|
49
|
+
|
|
50
|
+
/** props 和 state 改变时才会render */
|
|
51
|
+
function shouldUpdate() {
|
|
52
|
+
return function (target, name, descriptor) {
|
|
53
|
+
var fn = descriptor.value;
|
|
54
|
+
|
|
55
|
+
descriptor.value = function (nextProps, nextState) {
|
|
56
|
+
var nowPropsJson = JSON.stringify(nextProps);
|
|
57
|
+
var nowStateJson = JSON.stringify(nextState);
|
|
58
|
+
var should1 = nowPropsJson != this.preProps;
|
|
59
|
+
var should2 = nowStateJson != this.preState;
|
|
60
|
+
this.preProps = nowPropsJson;
|
|
61
|
+
this.preState = nowStateJson;
|
|
62
|
+
var result = should1 || should2;
|
|
63
|
+
return result && fn.apply(this, {
|
|
64
|
+
nextProps: nextProps
|
|
65
|
+
});
|
|
66
|
+
};
|
|
67
|
+
};
|
|
68
|
+
}
|