@fonixtree/magic-design 2.0.189 → 2.0.191
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/fonts/Roboto-Bold.ttf +0 -0
- package/es/assets/fonts/Roboto-Medium.ttf +0 -0
- package/es/assets/fonts/Roboto-Regular.ttf +0 -0
- package/es/assets/fonts/Roboto-SemiBold.ttf +0 -0
- package/es/assets/less/font.less +30 -0
- package/es/composite-comp/ashita/components/WalletAshita/defaultJSON.js +1 -1
- package/es/composite-comp/ashita/components/WalletAshita/index.js +1 -1
- package/es/composite-comp/common/components/MonpayProductItem/index.less +6 -2
- package/es/composite-comp/common/config-panels/InputField/index.js +1 -1
- package/es/composite-comp/dito/components/SearchBar/defaultJSON.js +66 -0
- package/es/composite-comp/dito/components/SearchBar/mobile/index.js +55 -20
- package/es/composite-comp/dito/components/SearchBar/mobile/index.less +1 -0
- package/es/composite-comp/dito/config-panels/PcNavigationConfig/TextOnlyFontConfig/index.js +1 -1
- package/es/composite-comp/dito/config-panels/SearchBarConfig/SearchBarConfigContent/index.js +6 -0
- package/es/composite-comp/monpay/components/MerchantSales/mobile/index.js +3 -1
- package/es/composite-comp/monpay/components/MonpayFlashDeal/mobile/index.js +29 -5
- package/es/composite-comp/public/components/Stores/defaultJSON.js +1 -3
- package/es/composite-comp/public/components/Stores/mobile/StoreItem/index.js +2 -2
- package/es/composite-comp/public/components/Stores/mobile/index.js +33 -9
- package/es/composite-comp/public/components/Wallet/defaultJSON.js +1 -1
- package/es/composite-comp/public/components/Wallet/index.js +1 -1
- package/es/composite-comp/public/config-panels/StoresConfig/ConfigContent/index.js +10 -2
- package/es/constants/index.js +6 -2
- package/es/core/Designer/ToolBarModal/index.js +1 -1
- package/es/decorator/compositeDecorator.js +5 -8
- package/es/locale/ar/ar.json +6 -0
- package/es/locale/en/en.json +6 -0
- package/es/locale/es/es.json +6 -0
- package/es/locale/mn/mn.json +7 -1
- package/es/meta-comp/config-panels/ButtonConfig/index.js +1 -1
- package/es/meta-comp/config-panels/TextConfig/index.js +1 -1
- package/es/utils/dateUtil.js +14 -0
- package/lib/assets/fonts/Roboto-Bold.ttf +0 -0
- package/lib/assets/fonts/Roboto-Medium.ttf +0 -0
- package/lib/assets/fonts/Roboto-Regular.ttf +0 -0
- package/lib/assets/fonts/Roboto-SemiBold.ttf +0 -0
- package/lib/assets/less/font.less +30 -0
- package/lib/composite-comp/ashita/components/WalletAshita/defaultJSON.js +1 -1
- package/lib/composite-comp/ashita/components/WalletAshita/index.js +1 -1
- package/lib/composite-comp/common/components/MonpayProductItem/index.less +6 -2
- package/lib/composite-comp/common/config-panels/InputField/index.js +1 -1
- package/lib/composite-comp/dito/components/SearchBar/defaultJSON.js +66 -0
- package/lib/composite-comp/dito/components/SearchBar/mobile/index.js +55 -20
- package/lib/composite-comp/dito/components/SearchBar/mobile/index.less +1 -0
- package/lib/composite-comp/dito/config-panels/PcNavigationConfig/TextOnlyFontConfig/index.js +1 -1
- package/lib/composite-comp/dito/config-panels/SearchBarConfig/SearchBarConfigContent/index.js +6 -0
- package/lib/composite-comp/monpay/components/MerchantSales/mobile/index.js +3 -1
- package/lib/composite-comp/monpay/components/MonpayFlashDeal/mobile/index.js +29 -5
- package/lib/composite-comp/public/components/Stores/defaultJSON.js +1 -3
- package/lib/composite-comp/public/components/Stores/mobile/StoreItem/index.js +2 -2
- package/lib/composite-comp/public/components/Stores/mobile/index.js +33 -9
- package/lib/composite-comp/public/components/Wallet/defaultJSON.js +1 -1
- package/lib/composite-comp/public/components/Wallet/index.js +1 -1
- package/lib/composite-comp/public/config-panels/StoresConfig/ConfigContent/index.js +10 -2
- package/lib/constants/index.js +6 -2
- package/lib/core/Designer/ToolBarModal/index.js +1 -1
- package/lib/decorator/compositeDecorator.js +5 -8
- package/lib/locale/ar/ar.json +6 -0
- package/lib/locale/en/en.json +6 -0
- package/lib/locale/es/es.json +6 -0
- package/lib/locale/mn/mn.json +7 -1
- package/lib/meta-comp/config-panels/ButtonConfig/index.js +1 -1
- package/lib/meta-comp/config-panels/TextConfig/index.js +1 -1
- package/lib/utils/dateUtil.js +14 -0
- package/package.json +2 -2
|
@@ -15,8 +15,6 @@ var _constants = require("../constants");
|
|
|
15
15
|
|
|
16
16
|
var _commonUtil = require("../utils/commonUtil");
|
|
17
17
|
|
|
18
|
-
var _androidUtil = require("../utils/androidUtil");
|
|
19
|
-
|
|
20
18
|
var _storeUtil = require("../utils/storeUtil");
|
|
21
19
|
|
|
22
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); }
|
|
@@ -289,13 +287,12 @@ function compositeDecorator(WrappedComponent) {
|
|
|
289
287
|
hoveredFloor: _mobx.store.hoveredFloor
|
|
290
288
|
});
|
|
291
289
|
});
|
|
292
|
-
this.getOuterWrapStyle();
|
|
290
|
+
this.getOuterWrapStyle(); // if (browserVersion().isDelivistaApp) {
|
|
293
291
|
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
}
|
|
292
|
+
window['switchLanguage'] = this.switchLanguage;
|
|
293
|
+
window['getUserAddress'] = this.getUserAddress; // switchLanguage();
|
|
294
|
+
// getUserAddress();
|
|
295
|
+
// }
|
|
299
296
|
};
|
|
300
297
|
|
|
301
298
|
Wrapper.prototype.componentWillUnmount = function () {
|
package/es/locale/ar/ar.json
CHANGED
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
{
|
|
2
|
+
"SELECT_STORES": "Select stores",
|
|
3
|
+
"HIGH_SALES_STORES": "High sales stores",
|
|
4
|
+
"NEW_STORES": "New stores",
|
|
5
|
+
"ALL_STORES": "All stores",
|
|
6
|
+
"ROBOTO": "Roboto",
|
|
7
|
+
"POINTS": "Points",
|
|
2
8
|
"CAN_BE_ADDED_AS_YOUR_ADDRESS": "Can be added as your address",
|
|
3
9
|
"GIFT": "Gift",
|
|
4
10
|
"SEARCH_FOR_PRODUCT_OR_SHOP": "Search for product or shop",
|
package/es/locale/en/en.json
CHANGED
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
{
|
|
2
|
+
"SELECT_STORES": "Select stores",
|
|
3
|
+
"HIGH_SALES_STORES": "High sales stores",
|
|
4
|
+
"NEW_STORES": "New stores",
|
|
5
|
+
"ALL_STORES": "All stores",
|
|
6
|
+
"ROBOTO": "Roboto",
|
|
7
|
+
"POINTS": "Points",
|
|
2
8
|
"CAN_BE_ADDED_AS_YOUR_ADDRESS": "Can be added as your address",
|
|
3
9
|
"GIFT": "Gift",
|
|
4
10
|
"SEARCH_FOR_PRODUCT_OR_SHOP": "Search for product or shop",
|
package/es/locale/es/es.json
CHANGED
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
{
|
|
2
|
+
"SELECT_STORES": "Select stores",
|
|
3
|
+
"HIGH_SALES_STORES": "High sales stores",
|
|
4
|
+
"NEW_STORES": "New stores",
|
|
5
|
+
"ALL_STORES": "All stores",
|
|
6
|
+
"ROBOTO": "Roboto",
|
|
7
|
+
"POINTS": "Points",
|
|
2
8
|
"CAN_BE_ADDED_AS_YOUR_ADDRESS": "Can be added as your address",
|
|
3
9
|
"GIFT": "Gift",
|
|
4
10
|
"SEARCH_FOR_PRODUCT_OR_SHOP": "Search for product or shop",
|
package/es/locale/mn/mn.json
CHANGED
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
{
|
|
2
|
+
"SELECT_STORES": "Select stores",
|
|
3
|
+
"HIGH_SALES_STORES": "High sales stores",
|
|
4
|
+
"NEW_STORES": "New stores",
|
|
5
|
+
"ALL_STORES": "All stores",
|
|
6
|
+
"ROBOTO": "Roboto",
|
|
7
|
+
"POINTS": "Points",
|
|
2
8
|
"CAN_BE_ADDED_AS_YOUR_ADDRESS": "Can be added as your address",
|
|
3
9
|
"GIFT": "Бэлэгтэй",
|
|
4
10
|
"SEARCH_FOR_PRODUCT_OR_SHOP": "Search for product or shop",
|
|
@@ -172,7 +178,7 @@
|
|
|
172
178
|
"COUPON": "Купон",
|
|
173
179
|
"HEADER_IMAGE": "Толгойн зураг",
|
|
174
180
|
"ACTIVITY_LABEL": "Үйл ажиллагааны шошго",
|
|
175
|
-
"STOCK": "
|
|
181
|
+
"STOCK": "Үлдэгдэл",
|
|
176
182
|
"DISCOUNT_LABEL": "Хөнгөлөлтийн шошго",
|
|
177
183
|
"SESSION_TIME": "Сеанс цаг",
|
|
178
184
|
"COUNTDOWN": "Countdown",
|
|
@@ -171,7 +171,7 @@ function (_super) {
|
|
|
171
171
|
|
|
172
172
|
var fontSizeKey = window.magicDesign.device == 'pc' ? 'pcFontSize' : 'fontSize';
|
|
173
173
|
|
|
174
|
-
var _fontWeightList = ((_a = data === null || data === void 0 ? void 0 : data.buttonText) === null || _a === void 0 ? void 0 : _a.fontFamily)
|
|
174
|
+
var _fontWeightList = ['Montserrat', 'Roboto'].includes((_a = data === null || data === void 0 ? void 0 : data.buttonText) === null || _a === void 0 ? void 0 : _a.fontFamily) ? _constants.fontWeightList : _constants.otherFontWeightList;
|
|
175
175
|
|
|
176
176
|
var ButtonTextSetting = function ButtonTextSetting(_data) {
|
|
177
177
|
return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement(_common.Field, {
|
|
@@ -187,7 +187,7 @@ function (_super) {
|
|
|
187
187
|
};
|
|
188
188
|
}
|
|
189
189
|
|
|
190
|
-
var _fontWeightList = textData.fontFamily
|
|
190
|
+
var _fontWeightList = ['Montserrat', 'Roboto'].includes(textData.fontFamily) ? _constants.fontWeightList : _constants.otherFontWeightList;
|
|
191
191
|
|
|
192
192
|
var source = [{
|
|
193
193
|
key: '1',
|
package/es/utils/dateUtil.js
CHANGED
|
@@ -6,6 +6,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.formatDateTime = exports.formatDateMinute = exports.formatDate = void 0;
|
|
7
7
|
exports.formatDayMonth = formatDayMonth;
|
|
8
8
|
exports.formatDayMonthTime = formatDayMonthTime;
|
|
9
|
+
exports.isToday = isToday;
|
|
10
|
+
exports.isTomorrow = isTomorrow;
|
|
9
11
|
exports.newDate = void 0;
|
|
10
12
|
|
|
11
13
|
var _moment = _interopRequireDefault(require("moment"));
|
|
@@ -80,4 +82,16 @@ function formatDayMonthTime(date, fmt) {
|
|
|
80
82
|
}
|
|
81
83
|
|
|
82
84
|
return (0, _moment["default"])(newDate(date)).format(fmt);
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
function isToday(date) {
|
|
88
|
+
var now = new Date();
|
|
89
|
+
var tomorrow = new Date(now.getFullYear(), now.getMonth(), now.getDate());
|
|
90
|
+
return date.getDate() === tomorrow.getDate() && date.getMonth() === tomorrow.getMonth() && date.getFullYear() === tomorrow.getFullYear();
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
function isTomorrow(date) {
|
|
94
|
+
var now = new Date();
|
|
95
|
+
var tomorrow = new Date(now.getFullYear(), now.getMonth(), now.getDate() + 1);
|
|
96
|
+
return date.getDate() === tomorrow.getDate() && date.getMonth() === tomorrow.getMonth() && date.getFullYear() === tomorrow.getFullYear();
|
|
83
97
|
}
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -88,4 +88,34 @@
|
|
|
88
88
|
src: url(../fonts/TruenoBd.otf);
|
|
89
89
|
font-weight: 600;
|
|
90
90
|
font-style: normal;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
|
|
94
|
+
@font-face {
|
|
95
|
+
font-family: 'Roboto';
|
|
96
|
+
src: url('../fonts/Roboto-Regular.ttf');
|
|
97
|
+
font-weight: 400;
|
|
98
|
+
font-style: normal;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
@font-face {
|
|
102
|
+
font-family: 'Roboto';
|
|
103
|
+
src: url(../fonts/Roboto-Medium.ttf);
|
|
104
|
+
font-weight: 500;
|
|
105
|
+
font-style: normal;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
|
|
109
|
+
@font-face {
|
|
110
|
+
font-family: 'Roboto';
|
|
111
|
+
src: url('../fonts/Roboto-SemiBold.ttf');
|
|
112
|
+
font-weight: 600;
|
|
113
|
+
font-style: normal;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
@font-face {
|
|
117
|
+
font-family: 'Roboto';
|
|
118
|
+
src: url(../fonts/Roboto-Bold.ttf);
|
|
119
|
+
font-weight: 700;
|
|
120
|
+
font-style: normal;
|
|
91
121
|
}
|
|
@@ -166,7 +166,7 @@ var getDefaultJSON = function getDefaultJSON() {
|
|
|
166
166
|
var defaultFontFamily = _constants.projectFontFamily[(_a = window.systemParams) === null || _a === void 0 ? void 0 : _a.projectCode] || 'Open Sans';
|
|
167
167
|
return {
|
|
168
168
|
id: groupId,
|
|
169
|
-
type: '
|
|
169
|
+
type: 'WALLET',
|
|
170
170
|
title: {
|
|
171
171
|
headline: {
|
|
172
172
|
id: (0, _uuid.v4)(),
|
|
@@ -7,16 +7,17 @@
|
|
|
7
7
|
position: relative;
|
|
8
8
|
margin-right: 16px;
|
|
9
9
|
border-radius: 8px;
|
|
10
|
+
border: 1px solid #E4E4E4;
|
|
10
11
|
|
|
11
12
|
.img-wrap {
|
|
12
13
|
position: relative;
|
|
13
|
-
border-radius: 8px;
|
|
14
|
+
border-radius: 8px 8px 0 0;
|
|
14
15
|
// overflow: hidden;
|
|
15
16
|
|
|
16
17
|
.product-img {
|
|
17
18
|
width: 140px;
|
|
18
19
|
height: 140px;
|
|
19
|
-
border-radius: 8px;
|
|
20
|
+
border-radius: 8px 8px 0 0;
|
|
20
21
|
object-fit: cover;
|
|
21
22
|
}
|
|
22
23
|
|
|
@@ -31,6 +32,7 @@
|
|
|
31
32
|
top: 15px;
|
|
32
33
|
left: 0;
|
|
33
34
|
}
|
|
35
|
+
|
|
34
36
|
.giftL-tag {
|
|
35
37
|
font-size: 12px;
|
|
36
38
|
font-weight: 700;
|
|
@@ -40,6 +42,7 @@
|
|
|
40
42
|
border-radius: 0 5px 5px 0;
|
|
41
43
|
display: flex;
|
|
42
44
|
align-items: center;
|
|
45
|
+
|
|
43
46
|
.icon {
|
|
44
47
|
margin-right: 4px;
|
|
45
48
|
}
|
|
@@ -47,6 +50,7 @@
|
|
|
47
50
|
}
|
|
48
51
|
|
|
49
52
|
.content-wrap {
|
|
53
|
+
padding: 0 0 8px 10px;
|
|
50
54
|
|
|
51
55
|
.promotions-wrap {
|
|
52
56
|
display: flex;
|
|
@@ -94,7 +94,7 @@ function (_super) {
|
|
|
94
94
|
inputLabel = _a.inputLabel;
|
|
95
95
|
var textData = data.content;
|
|
96
96
|
|
|
97
|
-
var _fontWeightList = textData.fontFamily
|
|
97
|
+
var _fontWeightList = ['Montserrat', 'Roboto'].includes(textData.fontFamily) ? _constants.fontWeightList : _constants.otherFontWeightList;
|
|
98
98
|
|
|
99
99
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
100
100
|
className: "m-text-config"
|
|
@@ -9,6 +9,8 @@ var _uuid = require("uuid");
|
|
|
9
9
|
|
|
10
10
|
var _constants = require("../../../../constants");
|
|
11
11
|
|
|
12
|
+
var _index = require("../../../../assets/images/base64/index");
|
|
13
|
+
|
|
12
14
|
var getDefaultJSON = function getDefaultJSON() {
|
|
13
15
|
var _a;
|
|
14
16
|
|
|
@@ -82,6 +84,70 @@ var getDefaultJSON = function getDefaultJSON() {
|
|
|
82
84
|
pc: false,
|
|
83
85
|
mobile: true
|
|
84
86
|
}
|
|
87
|
+
},
|
|
88
|
+
points: {
|
|
89
|
+
id: (0, _uuid.v4)(),
|
|
90
|
+
open: false,
|
|
91
|
+
type: 'BUTTON',
|
|
92
|
+
text: 0,
|
|
93
|
+
content: {
|
|
94
|
+
url: '',
|
|
95
|
+
backgroundColor: ''
|
|
96
|
+
},
|
|
97
|
+
buttonText: {
|
|
98
|
+
sizeType: 'Customize font styles',
|
|
99
|
+
fontFamily: defaultFontFamily,
|
|
100
|
+
fontWeight: 400,
|
|
101
|
+
fontSize: 14,
|
|
102
|
+
fontStyle: 'normal',
|
|
103
|
+
color: '#545454'
|
|
104
|
+
},
|
|
105
|
+
buttonBorder: {
|
|
106
|
+
open: true,
|
|
107
|
+
borderColor: '',
|
|
108
|
+
borderRadius: 4
|
|
109
|
+
},
|
|
110
|
+
buttonIcon: {
|
|
111
|
+
iconUrl: _index.starIcon,
|
|
112
|
+
layout: 'left'
|
|
113
|
+
},
|
|
114
|
+
spacing: {
|
|
115
|
+
pc: {
|
|
116
|
+
paddingTop: 4,
|
|
117
|
+
paddingBottom: 4,
|
|
118
|
+
paddingLeft: 10,
|
|
119
|
+
paddingRight: 10
|
|
120
|
+
},
|
|
121
|
+
mobile: {
|
|
122
|
+
paddingTop: 2,
|
|
123
|
+
paddingBottom: 2,
|
|
124
|
+
paddingLeft: 8,
|
|
125
|
+
paddingRight: 8
|
|
126
|
+
}
|
|
127
|
+
},
|
|
128
|
+
hover: {
|
|
129
|
+
open: false,
|
|
130
|
+
content: {
|
|
131
|
+
backgroundColor: '#E6EAF0'
|
|
132
|
+
},
|
|
133
|
+
buttonText: {
|
|
134
|
+
sizeType: 'Customize font styles',
|
|
135
|
+
fontFamily: defaultFontFamily,
|
|
136
|
+
fontWeight: 600,
|
|
137
|
+
fontSize: 14,
|
|
138
|
+
fontStyle: 'normal',
|
|
139
|
+
color: '#8493AF'
|
|
140
|
+
},
|
|
141
|
+
buttonBorder: {
|
|
142
|
+
open: true,
|
|
143
|
+
borderColor: '',
|
|
144
|
+
borderRadius: 4
|
|
145
|
+
},
|
|
146
|
+
buttonIcon: {
|
|
147
|
+
iconUrl: '',
|
|
148
|
+
layout: 'left'
|
|
149
|
+
}
|
|
150
|
+
}
|
|
85
151
|
}
|
|
86
152
|
},
|
|
87
153
|
spacing: {
|
|
@@ -11,6 +11,8 @@ var _antd = require("antd4");
|
|
|
11
11
|
|
|
12
12
|
require("./index.less");
|
|
13
13
|
|
|
14
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
15
|
+
|
|
14
16
|
var _components = require("../../../../../meta-comp/components");
|
|
15
17
|
|
|
16
18
|
var _common = require("../../../../../common");
|
|
@@ -219,7 +221,8 @@ function (_super) {
|
|
|
219
221
|
_this.state = {
|
|
220
222
|
messageNum: '',
|
|
221
223
|
cartNum: '',
|
|
222
|
-
editing: false
|
|
224
|
+
editing: false,
|
|
225
|
+
points: 0
|
|
223
226
|
};
|
|
224
227
|
|
|
225
228
|
_this.getCartNum = function () {
|
|
@@ -319,6 +322,29 @@ function (_super) {
|
|
|
319
322
|
}
|
|
320
323
|
};
|
|
321
324
|
|
|
325
|
+
_this.getPoints = function () {
|
|
326
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
327
|
+
var num;
|
|
328
|
+
return __generator(this, function (_a) {
|
|
329
|
+
switch (_a.label) {
|
|
330
|
+
case 0:
|
|
331
|
+
return [4
|
|
332
|
+
/*yield*/
|
|
333
|
+
, (0, _commonUtil.commonFetch)('/designer/v1/h5/points', {}, 'GET')];
|
|
334
|
+
|
|
335
|
+
case 1:
|
|
336
|
+
num = _a.sent();
|
|
337
|
+
this.setState({
|
|
338
|
+
points: num || 0
|
|
339
|
+
});
|
|
340
|
+
return [2
|
|
341
|
+
/*return*/
|
|
342
|
+
];
|
|
343
|
+
}
|
|
344
|
+
});
|
|
345
|
+
});
|
|
346
|
+
};
|
|
347
|
+
|
|
322
348
|
return _this;
|
|
323
349
|
}
|
|
324
350
|
|
|
@@ -327,6 +353,7 @@ function (_super) {
|
|
|
327
353
|
|
|
328
354
|
this.getMessageNum();
|
|
329
355
|
this.getCartNum();
|
|
356
|
+
this.getPoints();
|
|
330
357
|
|
|
331
358
|
if ((_c = (_b = (_a = this.props.data) === null || _a === void 0 ? void 0 : _a.content) === null || _b === void 0 ? void 0 : _b.keyword) === null || _c === void 0 ? void 0 : _c.open) {
|
|
332
359
|
this.setState({
|
|
@@ -352,25 +379,28 @@ function (_super) {
|
|
|
352
379
|
};
|
|
353
380
|
|
|
354
381
|
SearchMobile.prototype.render = function () {
|
|
355
|
-
var _a
|
|
382
|
+
var _a;
|
|
383
|
+
|
|
384
|
+
var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w;
|
|
356
385
|
|
|
357
386
|
var data = this.props.data;
|
|
358
|
-
var
|
|
359
|
-
messageNum =
|
|
360
|
-
cartNum =
|
|
361
|
-
value =
|
|
387
|
+
var _x = this.state,
|
|
388
|
+
messageNum = _x.messageNum,
|
|
389
|
+
cartNum = _x.cartNum,
|
|
390
|
+
value = _x.value,
|
|
391
|
+
points = _x.points;
|
|
362
392
|
|
|
363
|
-
var style = __assign({}, (0, _Text.contentStyle)(((
|
|
393
|
+
var style = __assign({}, (0, _Text.contentStyle)(((_b = data.content.keyword) === null || _b === void 0 ? void 0 : _b.content) || {}));
|
|
364
394
|
|
|
365
395
|
Reflect.deleteProperty(style, 'width');
|
|
366
396
|
|
|
367
|
-
var _placeholder = ((
|
|
397
|
+
var _placeholder = ((_c = data.content.placeholder) === null || _c === void 0 ? void 0 : _c.open) ? (_d = data.content.placeholder) === null || _d === void 0 ? void 0 : _d.text : '';
|
|
368
398
|
|
|
369
399
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
370
|
-
className: "m-search-bar
|
|
400
|
+
className: (0, _classnames["default"])('m-search-bar', (_a = {}, _a['reversed-layout'] = (0, _commonUtil.needReverse)(), _a))
|
|
371
401
|
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
372
402
|
className: "right"
|
|
373
|
-
}, data.content && ((
|
|
403
|
+
}, data.content && ((_e = data.content.box) === null || _e === void 0 ? void 0 : _e.open) && /*#__PURE__*/_react["default"].createElement("div", {
|
|
374
404
|
className: "search-input-wrap",
|
|
375
405
|
onClick: function onClick() {
|
|
376
406
|
return (0, _coreUtil.clickUrl)('/search-page', {
|
|
@@ -378,26 +408,31 @@ function (_super) {
|
|
|
378
408
|
});
|
|
379
409
|
},
|
|
380
410
|
style: {
|
|
381
|
-
borderColor: (
|
|
382
|
-
backgroundColor: (
|
|
411
|
+
borderColor: (_g = (_f = data.content.box) === null || _f === void 0 ? void 0 : _f.color) === null || _g === void 0 ? void 0 : _g.mobile,
|
|
412
|
+
backgroundColor: (_j = (_h = data.content.box) === null || _h === void 0 ? void 0 : _h.backgroundColor) === null || _j === void 0 ? void 0 : _j.mobile
|
|
383
413
|
}
|
|
384
414
|
}, /*#__PURE__*/_react["default"].createElement(_antd.Input, {
|
|
385
415
|
className: "search-input",
|
|
386
416
|
onBlur: this.onBlur,
|
|
387
417
|
onChange: this.onChange,
|
|
388
418
|
onFocus: this.onFocus,
|
|
419
|
+
placeholder: _placeholder,
|
|
420
|
+
readOnly: true,
|
|
389
421
|
style: (0, _commonUtil.pxToRem)(style),
|
|
390
422
|
type: "text",
|
|
391
|
-
value: value
|
|
392
|
-
placeholder: _placeholder
|
|
423
|
+
value: value
|
|
393
424
|
}), /*#__PURE__*/_react["default"].createElement(_common.Iconfont, {
|
|
394
|
-
color: (
|
|
425
|
+
color: (_l = (_k = data.content.box) === null || _k === void 0 ? void 0 : _k.color) === null || _l === void 0 ? void 0 : _l.mobile,
|
|
395
426
|
size: (0, _commonUtil.convertToRem)(24),
|
|
396
427
|
type: "icon-search2"
|
|
397
|
-
})), data.content && ((_m =
|
|
428
|
+
})), data.content && ((_m = data.content.points) === null || _m === void 0 ? void 0 : _m.open) && /*#__PURE__*/_react["default"].createElement(_components.MetaButton, {
|
|
429
|
+
data: __assign(__assign({}, data.content.points), {
|
|
430
|
+
text: points
|
|
431
|
+
})
|
|
432
|
+
}), data.content && ((_p = (_o = data.content.icon) === null || _o === void 0 ? void 0 : _o.cartIcon) === null || _p === void 0 ? void 0 : _p.mobile) && /*#__PURE__*/_react["default"].createElement("div", {
|
|
398
433
|
className: "message-wrap"
|
|
399
434
|
}, /*#__PURE__*/_react["default"].createElement(_common.Iconfont, {
|
|
400
|
-
color: (
|
|
435
|
+
color: (_r = (_q = data.content.icon) === null || _q === void 0 ? void 0 : _q.color) === null || _r === void 0 ? void 0 : _r.mobile,
|
|
401
436
|
onClick: function onClick() {
|
|
402
437
|
return (0, _coreUtil.clickUrl)('/main/cart');
|
|
403
438
|
},
|
|
@@ -408,10 +443,10 @@ function (_super) {
|
|
|
408
443
|
type: "icon-ShoppingCartSimple1"
|
|
409
444
|
}), !!cartNum && /*#__PURE__*/_react["default"].createElement("span", {
|
|
410
445
|
className: "num"
|
|
411
|
-
}, cartNum)), data.content && ((
|
|
446
|
+
}, cartNum)), data.content && ((_t = (_s = data.content.icon) === null || _s === void 0 ? void 0 : _s.messageIcon) === null || _t === void 0 ? void 0 : _t.mobile) && /*#__PURE__*/_react["default"].createElement("div", {
|
|
412
447
|
className: "message-wrap"
|
|
413
448
|
}, /*#__PURE__*/_react["default"].createElement(_common.Iconfont, {
|
|
414
|
-
color: (
|
|
449
|
+
color: (_v = (_u = data.content.icon) === null || _u === void 0 ? void 0 : _u.color) === null || _v === void 0 ? void 0 : _v.mobile,
|
|
415
450
|
onClick: function onClick() {
|
|
416
451
|
return (0, _coreUtil.clickUrl)('/message-center');
|
|
417
452
|
},
|
|
@@ -422,7 +457,7 @@ function (_super) {
|
|
|
422
457
|
type: "icon-message"
|
|
423
458
|
}), !!messageNum && /*#__PURE__*/_react["default"].createElement("span", {
|
|
424
459
|
className: "num"
|
|
425
|
-
}, messageNum))), data.content && ((
|
|
460
|
+
}, messageNum))), data.content && ((_w = data.content.logo) === null || _w === void 0 ? void 0 : _w.open) && /*#__PURE__*/_react["default"].createElement("div", {
|
|
426
461
|
className: "logo",
|
|
427
462
|
onClick: function onClick() {
|
|
428
463
|
var _a, _b;
|
package/lib/composite-comp/dito/config-panels/PcNavigationConfig/TextOnlyFontConfig/index.js
CHANGED
|
@@ -106,7 +106,7 @@ function (_super) {
|
|
|
106
106
|
};
|
|
107
107
|
}
|
|
108
108
|
|
|
109
|
-
var _fontWeightList = textData.fontFamily
|
|
109
|
+
var _fontWeightList = ['Montserrat', 'Roboto'].includes(textData.fontFamily) ? _constants.fontWeightList : _constants.otherFontWeightList;
|
|
110
110
|
|
|
111
111
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
112
112
|
className: "m-text-config"
|
package/lib/composite-comp/dito/config-panels/SearchBarConfig/SearchBarConfigContent/index.js
CHANGED
|
@@ -209,6 +209,12 @@ function (_super) {
|
|
|
209
209
|
}
|
|
210
210
|
})))),
|
|
211
211
|
metaOption: panelProps.icon
|
|
212
|
+
}, {
|
|
213
|
+
key: 'search6',
|
|
214
|
+
name: (0, _locale.i18n)('POINTS'),
|
|
215
|
+
toggleType: 'switch',
|
|
216
|
+
value: null,
|
|
217
|
+
metaOption: panelProps.points
|
|
212
218
|
}];
|
|
213
219
|
return /*#__PURE__*/_react["default"].createElement(_common.Collapse, {
|
|
214
220
|
headerSize: "middle",
|
|
@@ -247,7 +247,9 @@ function (_super) {
|
|
|
247
247
|
case 1:
|
|
248
248
|
res = _a.sent();
|
|
249
249
|
list = (0, _commonUtil.ensure)(function () {
|
|
250
|
-
|
|
250
|
+
var _a;
|
|
251
|
+
|
|
252
|
+
return (_a = res.storePage) === null || _a === void 0 ? void 0 : _a.list;
|
|
251
253
|
}, []);
|
|
252
254
|
this.setState({
|
|
253
255
|
list: list
|
|
@@ -11,8 +11,6 @@ require("./index.less");
|
|
|
11
11
|
|
|
12
12
|
var _defImg = _interopRequireDefault(require("./imgs/defImg.png"));
|
|
13
13
|
|
|
14
|
-
var _locale = require("../../../../../locale");
|
|
15
|
-
|
|
16
14
|
var _MonpayProductItem = _interopRequireDefault(require("../../../../common/components/MonpayProductItem"));
|
|
17
15
|
|
|
18
16
|
var _coreUtil = require("../../../../../utils/coreUtil");
|
|
@@ -23,6 +21,8 @@ var _commonUtil = require("../../../../../utils/commonUtil");
|
|
|
23
21
|
|
|
24
22
|
var _storeUtil = require("../../../../../utils/storeUtil");
|
|
25
23
|
|
|
24
|
+
var _constants = require("../../../../../constants");
|
|
25
|
+
|
|
26
26
|
var _dateUtil = require("../../../../../utils/dateUtil");
|
|
27
27
|
|
|
28
28
|
var _MonpayCountDown = _interopRequireDefault(require("../MonpayCountDown"));
|
|
@@ -364,6 +364,30 @@ function (_super) {
|
|
|
364
364
|
});
|
|
365
365
|
};
|
|
366
366
|
|
|
367
|
+
_this.toLocale = function (value) {
|
|
368
|
+
var locale = (0, _storeUtil.getStore)(_constants.STORAGE_KEY.FISHX_LOCALE) || (0, _storeUtil.getStore)(_constants.STORAGE_KEY.LOCALE);
|
|
369
|
+
|
|
370
|
+
if (locale === 'mn' || locale === 'id-ID') {
|
|
371
|
+
var time = (0, _dateUtil.newDate)(value);
|
|
372
|
+
|
|
373
|
+
var _hour = time.getHours() < 10 ? '0' + time.getHours() : time.getHours();
|
|
374
|
+
|
|
375
|
+
var _minutes = time.getMinutes() < 10 ? '0' + time.getMinutes() : time.getMinutes();
|
|
376
|
+
|
|
377
|
+
if ((0, _dateUtil.isTomorrow)(time)) {
|
|
378
|
+
return "\u041C\u0430\u0440\u0433\u0430\u0430\u0448, " + _hour + ":" + _minutes;
|
|
379
|
+
}
|
|
380
|
+
|
|
381
|
+
if ((0, _dateUtil.isToday)(time)) {
|
|
382
|
+
return "\u04E8\u043D\u04E9\u04E9\u0434\u04E9\u0440, " + _hour + ":" + _minutes;
|
|
383
|
+
} else {
|
|
384
|
+
return time.getMonth() + 1 + " \u0441\u0430\u0440\u044B\u043D " + time.getDate() + "-\u043D\u044B " + _hour + ":" + _minutes;
|
|
385
|
+
}
|
|
386
|
+
} else {
|
|
387
|
+
return (0, _dateUtil.formatDayMonthTime)(value);
|
|
388
|
+
}
|
|
389
|
+
};
|
|
390
|
+
|
|
367
391
|
return _this;
|
|
368
392
|
}
|
|
369
393
|
|
|
@@ -380,6 +404,8 @@ function (_super) {
|
|
|
380
404
|
};
|
|
381
405
|
|
|
382
406
|
FlashDealMobile.prototype.render = function () {
|
|
407
|
+
var _this = this;
|
|
408
|
+
|
|
383
409
|
var panelProps = this.props.panelProps;
|
|
384
410
|
var _a = this.state,
|
|
385
411
|
times = _a.times,
|
|
@@ -426,9 +452,7 @@ function (_super) {
|
|
|
426
452
|
}
|
|
427
453
|
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
428
454
|
className: "time"
|
|
429
|
-
},
|
|
430
|
-
className: "status"
|
|
431
|
-
}, item.cmpState === 'A' ? (0, _locale.i18n)('COMING_SOON') : (0, _locale.i18n)('ON_GOING')));
|
|
455
|
+
}, _this.toLocale(item.effDate)));
|
|
432
456
|
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
433
457
|
className: "flash-deal-list"
|
|
434
458
|
}, _list.map(function (item) {
|
|
@@ -12,10 +12,8 @@ var _constants = require("../../../../constants");
|
|
|
12
12
|
var _index = require("../../../../assets/images/base64/index");
|
|
13
13
|
|
|
14
14
|
var getDefaultJSON = function getDefaultJSON() {
|
|
15
|
-
var _a;
|
|
16
|
-
|
|
17
15
|
var groupId = (0, _uuid.v4)();
|
|
18
|
-
var defaultFontFamily = _constants.projectFontFamily[
|
|
16
|
+
var defaultFontFamily = _constants.projectFontFamily['ar'] || 'Open Sans';
|
|
19
17
|
return {
|
|
20
18
|
id: groupId,
|
|
21
19
|
type: 'STORES',
|
|
@@ -121,7 +121,7 @@ function (_super) {
|
|
|
121
121
|
}, /*#__PURE__*/_react["default"].createElement(_common.NewImg, {
|
|
122
122
|
className: "product-img",
|
|
123
123
|
lazy: true,
|
|
124
|
-
src:
|
|
124
|
+
src: data.storePosterUrl || data.storeLogoUrl
|
|
125
125
|
}), freeDeliveryLabel.open && data.freeShipping === 'Y' && /*#__PURE__*/_react["default"].createElement(_components.MetaButton, {
|
|
126
126
|
className: "flag",
|
|
127
127
|
data: freeDeliveryLabel
|
|
@@ -177,7 +177,7 @@ function (_super) {
|
|
|
177
177
|
}, /*#__PURE__*/_react["default"].createElement(_common.NewImg, {
|
|
178
178
|
className: "product-img",
|
|
179
179
|
lazy: true,
|
|
180
|
-
src:
|
|
180
|
+
src: data.storePosterUrl || data.storeLogoUrl
|
|
181
181
|
}), freeDeliveryLabel.open && data.freeShipping === 'Y' && /*#__PURE__*/_react["default"].createElement(_components.MetaButton, {
|
|
182
182
|
className: "flag",
|
|
183
183
|
data: freeDeliveryLabel
|