@fonixtree/magic-design 2.0.101 → 2.0.103

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.
Files changed (45) hide show
  1. package/es/common/PopUpModal/index.js +9 -215
  2. package/es/common/PopUpModal/index.less +14 -0
  3. package/es/common/ProductFilterModal/components/FilterSearchModal/index.js +2 -5
  4. package/es/common/ProductFilterModal/components/FilterSearchModal/index.less +21 -6
  5. package/es/common/ProductFilterModal/index.js +4 -8
  6. package/es/common/ProductFilterModal/index.less +94 -53
  7. package/es/common/Tag/index.less +2 -2
  8. package/es/composite-comp/monpay/components/InterestProducts/mobile/ProductItem/index.js +1 -3
  9. package/es/composite-comp/monpay/components/InterestProducts/mobile/ProductItem/index.less +1 -6
  10. package/es/composite-comp/monpay/components/InterestProducts/mobile/index.js +29 -3
  11. package/es/composite-comp/monpay/components/MerchantSales/mobile/index.js +5 -8
  12. package/es/composite-comp/monpay/components/MonpayFlashDeal/mobile/index.js +1 -1
  13. package/es/composite-comp/monpay/components/MonpayFlashDeal/pc/index.js +1 -1
  14. package/es/composite-comp/monpay/components/MonpayRecommend/mobile/index.js +11 -8
  15. package/es/constants/index.js +1 -1
  16. package/es/locale/en/en.json +7 -2
  17. package/es/locale/es/es.json +7 -2
  18. package/es/locale/id/id.json +7 -2
  19. package/es/meta-comp/components/Button/editable.js +1 -1
  20. package/es/meta-comp/components/Button/editable.less +1 -1
  21. package/lib/common/PopUpModal/index.js +9 -215
  22. package/lib/common/PopUpModal/index.less +14 -0
  23. package/lib/common/ProductFilterModal/components/FilterSearchModal/index.js +2 -5
  24. package/lib/common/ProductFilterModal/components/FilterSearchModal/index.less +21 -6
  25. package/lib/common/ProductFilterModal/index.js +4 -8
  26. package/lib/common/ProductFilterModal/index.less +94 -53
  27. package/lib/common/Tag/index.less +2 -2
  28. package/lib/composite-comp/monpay/components/InterestProducts/mobile/ProductItem/index.js +1 -3
  29. package/lib/composite-comp/monpay/components/InterestProducts/mobile/ProductItem/index.less +1 -6
  30. package/lib/composite-comp/monpay/components/InterestProducts/mobile/index.js +29 -3
  31. package/lib/composite-comp/monpay/components/MerchantSales/mobile/index.js +5 -8
  32. package/lib/composite-comp/monpay/components/MonpayFlashDeal/mobile/index.js +1 -1
  33. package/lib/composite-comp/monpay/components/MonpayFlashDeal/pc/index.js +1 -1
  34. package/lib/composite-comp/monpay/components/MonpayRecommend/mobile/index.js +11 -8
  35. package/lib/constants/index.js +1 -1
  36. package/lib/locale/en/en.json +7 -2
  37. package/lib/locale/es/es.json +7 -2
  38. package/lib/locale/id/id.json +7 -2
  39. package/lib/meta-comp/components/Button/editable.js +1 -1
  40. package/lib/meta-comp/components/Button/editable.less +1 -1
  41. package/package.json +1 -1
  42. package/es/common/PopUpModal1/index.js +0 -164
  43. package/es/common/PopUpModal1/style.less +0 -56
  44. package/lib/common/PopUpModal1/index.js +0 -164
  45. package/lib/common/PopUpModal1/style.less +0 -56
@@ -15,8 +15,6 @@ var _propTypes = _interopRequireDefault(require("prop-types"));
15
15
 
16
16
  require("./index.less");
17
17
 
18
- var _Button = _interopRequireDefault(require("../Button"));
19
-
20
18
  var _coreUtil = require("../../utils/coreUtil");
21
19
 
22
20
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
@@ -51,149 +49,6 @@ var __extends = void 0 && (void 0).__extends || function () {
51
49
  };
52
50
  }();
53
51
 
54
- var __awaiter = void 0 && (void 0).__awaiter || function (thisArg, _arguments, P, generator) {
55
- function adopt(value) {
56
- return value instanceof P ? value : new P(function (resolve) {
57
- resolve(value);
58
- });
59
- }
60
-
61
- return new (P || (P = Promise))(function (resolve, reject) {
62
- function fulfilled(value) {
63
- try {
64
- step(generator.next(value));
65
- } catch (e) {
66
- reject(e);
67
- }
68
- }
69
-
70
- function rejected(value) {
71
- try {
72
- step(generator["throw"](value));
73
- } catch (e) {
74
- reject(e);
75
- }
76
- }
77
-
78
- function step(result) {
79
- result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
80
- }
81
-
82
- step((generator = generator.apply(thisArg, _arguments || [])).next());
83
- });
84
- };
85
-
86
- var __generator = void 0 && (void 0).__generator || function (thisArg, body) {
87
- var _ = {
88
- label: 0,
89
- sent: function sent() {
90
- if (t[0] & 1) throw t[1];
91
- return t[1];
92
- },
93
- trys: [],
94
- ops: []
95
- },
96
- f,
97
- y,
98
- t,
99
- g;
100
- return g = {
101
- next: verb(0),
102
- "throw": verb(1),
103
- "return": verb(2)
104
- }, typeof Symbol === "function" && (g[Symbol.iterator] = function () {
105
- return this;
106
- }), g;
107
-
108
- function verb(n) {
109
- return function (v) {
110
- return step([n, v]);
111
- };
112
- }
113
-
114
- function step(op) {
115
- if (f) throw new TypeError("Generator is already executing.");
116
-
117
- while (_) {
118
- try {
119
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
120
- if (y = 0, t) op = [op[0] & 2, t.value];
121
-
122
- switch (op[0]) {
123
- case 0:
124
- case 1:
125
- t = op;
126
- break;
127
-
128
- case 4:
129
- _.label++;
130
- return {
131
- value: op[1],
132
- done: false
133
- };
134
-
135
- case 5:
136
- _.label++;
137
- y = op[1];
138
- op = [0];
139
- continue;
140
-
141
- case 7:
142
- op = _.ops.pop();
143
-
144
- _.trys.pop();
145
-
146
- continue;
147
-
148
- default:
149
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) {
150
- _ = 0;
151
- continue;
152
- }
153
-
154
- if (op[0] === 3 && (!t || op[1] > t[0] && op[1] < t[3])) {
155
- _.label = op[1];
156
- break;
157
- }
158
-
159
- if (op[0] === 6 && _.label < t[1]) {
160
- _.label = t[1];
161
- t = op;
162
- break;
163
- }
164
-
165
- if (t && _.label < t[2]) {
166
- _.label = t[2];
167
-
168
- _.ops.push(op);
169
-
170
- break;
171
- }
172
-
173
- if (t[2]) _.ops.pop();
174
-
175
- _.trys.pop();
176
-
177
- continue;
178
- }
179
-
180
- op = body.call(thisArg, _);
181
- } catch (e) {
182
- op = [6, e];
183
- y = 0;
184
- } finally {
185
- f = t = 0;
186
- }
187
- }
188
-
189
- if (op[0] & 5) throw op[1];
190
- return {
191
- value: op[0] ? op[1] : void 0,
192
- done: true
193
- };
194
- }
195
- };
196
-
197
52
  var __rest = void 0 && (void 0).__rest || function (s, e) {
198
53
  var t = {};
199
54
 
@@ -207,8 +62,6 @@ var __rest = void 0 && (void 0).__rest || function (s, e) {
207
62
  return t;
208
63
  };
209
64
 
210
- var debug = require('debug')('worker:pop-up-modal');
211
-
212
65
  var AComponent =
213
66
  /** @class */
214
67
  function (_super) {
@@ -218,55 +71,6 @@ function (_super) {
218
71
  var _this = _super !== null && _super.apply(this, arguments) || this;
219
72
 
220
73
  _this.state = {};
221
-
222
- _this.onConfirm = function () {
223
- return __awaiter(_this, void 0, void 0, function () {
224
- var _a, onConfirm, onClose, error_1;
225
-
226
- return __generator(this, function (_b) {
227
- switch (_b.label) {
228
- case 0:
229
- _b.trys.push([0, 2,, 3]);
230
-
231
- _a = this.props, onConfirm = _a.onConfirm, onClose = _a.onClose;
232
- return [4
233
- /*yield*/
234
- , onConfirm()];
235
-
236
- case 1:
237
- _b.sent();
238
-
239
- onClose();
240
- return [3
241
- /*break*/
242
- , 3];
243
-
244
- case 2:
245
- error_1 = _b.sent();
246
- debug(error_1);
247
- return [3
248
- /*break*/
249
- , 3];
250
-
251
- case 3:
252
- return [2
253
- /*return*/
254
- ];
255
- }
256
- });
257
- });
258
- };
259
-
260
- _this.onCancel = function () {
261
- try {
262
- var onClose = _this.props.onClose;
263
- onCancel();
264
- onClose();
265
- } catch (error) {
266
- debug(error);
267
- }
268
- };
269
-
270
74
  return _this;
271
75
  }
272
76
 
@@ -274,19 +78,10 @@ function (_super) {
274
78
  var _a = this.props,
275
79
  title = _a.title,
276
80
  titleStyle = _a.titleStyle,
277
- message = _a.message,
278
- confirmText = _a.confirmText,
279
- cancelText = _a.cancelText,
81
+ children = _a.children,
280
82
  onClose = _a.onClose,
281
83
  visible = _a.visible,
282
- maskClosable = _a.maskClosable,
283
- rest = __rest(_a, ["title", "titleStyle", "message", "confirmText", "cancelText", "onClose", "visible", "maskClosable"]);
284
-
285
- var messageBox = message;
286
-
287
- if (message instanceof Function) {
288
- messageBox = message();
289
- }
84
+ rest = __rest(_a, ["title", "titleStyle", "children", "onClose", "visible"]);
290
85
 
291
86
  return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, visible && /*#__PURE__*/_react["default"].createElement("div", {
292
87
  className: (0, _classnames["default"])('popUpModal', rest.className),
@@ -295,20 +90,19 @@ function (_super) {
295
90
  }
296
91
  }, /*#__PURE__*/_react["default"].createElement("div", {
297
92
  className: "modal-shadow",
298
- onClick: maskClosable && onClose
93
+ onClick: onClose
299
94
  }), /*#__PURE__*/_react["default"].createElement("div", {
300
95
  className: "modal-content"
301
- }, title && /*#__PURE__*/_react["default"].createElement("div", {
96
+ }, /*#__PURE__*/_react["default"].createElement("div", {
97
+ className: "topLineWrap"
98
+ }, /*#__PURE__*/_react["default"].createElement("div", {
99
+ className: "topLine"
100
+ })), title && /*#__PURE__*/_react["default"].createElement("div", {
302
101
  className: "modal-title",
303
102
  style: titleStyle
304
103
  }, title), /*#__PURE__*/_react["default"].createElement("div", {
305
104
  className: "modal-btn-wrap"
306
- }, /*#__PURE__*/_react["default"].createElement(_Button["default"], {
307
- onClick: this.onConfirm,
308
- style: {
309
- flex: 'none'
310
- }
311
- }, confirmText)))));
105
+ }, children))));
312
106
  };
313
107
 
314
108
  return AComponent;
@@ -32,6 +32,7 @@
32
32
  right: 0;
33
33
  width: 100%;
34
34
  padding: 20px;
35
+ padding-top: 0;
35
36
  display: flex;
36
37
  flex-direction: column;
37
38
  background-color: #fff;
@@ -41,6 +42,19 @@
41
42
  max-height: 60%;
42
43
  border-radius: 10px 10px 0 0;
43
44
 
45
+ .topLineWrap {
46
+ text-align: center;
47
+ margin-bottom: 15px;
48
+
49
+ .topLine {
50
+ display: inline-block;
51
+ width: 42px;
52
+ height: 4px;
53
+ background: #e9e9e9;
54
+ border-radius: 2px;
55
+ }
56
+ }
57
+
44
58
  .modal-title {
45
59
  color: #000;
46
60
  font-size: 16px;
@@ -162,10 +162,6 @@ function (_super) {
162
162
  }) : list;
163
163
 
164
164
  return /*#__PURE__*/_react["default"].createElement(_PopUpModal["default"], {
165
- bodyStyle: {
166
- height: '80vh'
167
- },
168
- destroyOnClose: true,
169
165
  visible: visible
170
166
  }, /*#__PURE__*/_react["default"].createElement("div", {
171
167
  className: "classificationDetailModal"
@@ -179,7 +175,7 @@ function (_super) {
179
175
  _this.onClear();
180
176
  },
181
177
  size: 20,
182
- type: "icon-arrow-left"
178
+ type: "icon-outlined-left"
183
179
  }), /*#__PURE__*/_react["default"].createElement("div", {
184
180
  className: "headerTitle"
185
181
  }, title)), /*#__PURE__*/_react["default"].createElement("div", {
@@ -221,6 +217,7 @@ function (_super) {
221
217
  }), /*#__PURE__*/_react["default"].createElement("p", null, "Sorry, we couldn't find \"", searchValue, "\"")))), _list.length > 0 && /*#__PURE__*/_react["default"].createElement("div", {
222
218
  className: "bottomWrap"
223
219
  }, /*#__PURE__*/_react["default"].createElement(_Button["default"], {
220
+ className: "btn-confirm",
224
221
  onClick: this.onOkClick
225
222
  }, (0, _locale.i18n)('OK')))));
226
223
  };
@@ -1,9 +1,6 @@
1
1
  .classificationDetailModal {
2
- height: 100vh;
2
+ height: calc(80vh - 40px);
3
3
  width: 100%;
4
- position: absolute;
5
- z-index: 5;
6
- padding: 16px;
7
4
  background-color: #fff;
8
5
  box-sizing: border-box;
9
6
 
@@ -56,7 +53,7 @@
56
53
 
57
54
  .contentWrap {
58
55
  background: #ffffff;
59
- height: calc(100vh - 210px);
56
+ height: 300px;
60
57
  margin-top: 16px;
61
58
  overflow-y: scroll;
62
59
  overflow-x: hidden;
@@ -76,7 +73,7 @@
76
73
  font-size: 14px;
77
74
  text-align: center;
78
75
  color: #333333;
79
- margin: 25% auto;
76
+ margin: 0 auto;
80
77
  }
81
78
 
82
79
  :global {
@@ -124,6 +121,24 @@
124
121
  background: #fff;
125
122
  height: 78px;
126
123
  padding: 12px;
124
+
125
+ .btn-confirm {
126
+ display: flex;
127
+ flex: 1 1;
128
+ height: 54px;
129
+ align-items: center;
130
+ justify-content: center;
131
+ color: #fff;
132
+ border: 1px solid #FF8650;
133
+ background-color: #FF8650;
134
+ border-radius: 8px;
135
+ font-weight: 600;
136
+ font-size: 14px;
137
+
138
+ &:hover {
139
+ background-color: #FF8650;
140
+ }
141
+ }
127
142
  }
128
143
 
129
144
  }
@@ -230,10 +230,7 @@ function ProductFilterModal(props) {
230
230
  };
231
231
 
232
232
  return /*#__PURE__*/_react["default"].createElement(_PopUpModal["default"], {
233
- bodyStyle: {
234
- height: '80vh'
235
- },
236
- hideCloseBtn: true,
233
+ className: "productFilterModal",
237
234
  onClose: onClose,
238
235
  visible: visible
239
236
  }, /*#__PURE__*/_react["default"].createElement("div", {
@@ -329,13 +326,12 @@ function ProductFilterModal(props) {
329
326
  })), /*#__PURE__*/_react["default"].createElement("div", {
330
327
  className: "bottomWrap"
331
328
  }, /*#__PURE__*/_react["default"].createElement(_Button["default"], {
329
+ className: "btn-reset",
332
330
  onClick: onReset,
333
331
  plain: true
334
332
  }, (0, _locale.i18n)('RESET')), /*#__PURE__*/_react["default"].createElement(_Button["default"], {
335
- onClick: onApply,
336
- style: {
337
- marginLeft: '20px'
338
- }
333
+ className: "btn-confirm",
334
+ onClick: onApply
339
335
  }, (0, _locale.i18n)('APPLY'))), /*#__PURE__*/_react["default"].createElement(_FilterSearchModal["default"], {
340
336
  filterInfo: keyInfo[detailKey],
341
337
  onClose: function onClose() {
@@ -1,72 +1,113 @@
1
- .productFilterWrap {
2
- background: #ffffff;
3
- height: calc(80vh - 40px);
4
- overflow-y: scroll;
5
- overflow-x: hidden;
6
- padding: 0 20px 78px 20px;
7
- box-sizing: border-box;
1
+ .productFilterModal {
2
+ .productFilterWrap {
3
+ background: #ffffff;
4
+ height: calc(80vh - 40px);
5
+ overflow-y: scroll;
6
+ overflow-x: hidden;
7
+ box-sizing: border-box;
8
8
 
9
- .item {
10
- margin-top: 20px;
9
+ .item {
10
+ margin-top: 20px;
11
11
 
12
- .inputWrap {
13
- margin-top: 10px;
14
- display: flex;
15
- align-items: center;
16
- justify-content: space-between;
12
+ .inputWrap {
13
+ margin-top: 10px;
14
+ display: flex;
15
+ align-items: center;
16
+ justify-content: space-between;
17
+
18
+ .divider {
19
+ padding: 0 10px;
20
+ flex-shrink: 0;
21
+ height: 2px;
22
+ width: 11px;
23
+ background-color: #000;
24
+ }
25
+
26
+ input {
27
+ width: 45%;
28
+ height: 48px;
29
+ border: 1px solid #E4E4E4;
30
+ box-shadow: none;
31
+ padding: 12px;
32
+ border-radius: 4px;
33
+ outline: none;
34
+ }
35
+ }
17
36
 
18
- .divider {
19
- padding: 0 10px;
20
- flex-shrink: 0;
21
- height: 2px;
22
- width: 11px;
23
- background-color: #000;
37
+ .title {
38
+ line-height: 24px;
39
+ font-size: 16px;
40
+ font-weight: 600;
41
+ color: #000;
42
+ display: flex;
43
+ align-items: center;
44
+ justify-content: space-between;
24
45
  }
25
46
 
26
- input {
27
- width: 45%;
28
- height: 48px;
29
- border: 1px solid #E4E4E4;
30
- box-shadow: none;
31
- padding: 12px;
32
- border-radius: 4px;
33
- outline: none;
47
+ .accordionContentWrap {
48
+ display: flex;
49
+ flex-wrap: wrap;
50
+ align-items: center;
51
+ padding-bottom: 1px;
52
+
53
+ .btnMore {
54
+ font-weight: 600;
55
+ font-size: 14px;
56
+ color: #FF8650;
57
+ margin-top: 6px;
58
+ margin-left: 10px;
59
+ }
34
60
  }
35
61
  }
62
+ }
36
63
 
37
- .title {
38
- line-height: 24px;
39
- font-size: 16px;
40
- font-weight: 600;
41
- color: #000;
64
+ .bottomWrap {
65
+ position: fixed;
66
+ bottom: 0;
67
+ left: 0;
68
+ right: 0;
69
+ background: #fff;
70
+ width: 100%;
71
+ height: 78px;
72
+ padding: 12px 24px;
73
+ display: flex;
74
+ gap: 20px;
75
+ justify-content: space-between;
76
+
77
+ .btn-reset {
42
78
  display: flex;
79
+ flex: 1 1;
80
+ height: 54px;
43
81
  align-items: center;
44
- justify-content: space-between;
82
+ justify-content: center;
83
+ color: #FF8650;
84
+ border: 1px solid #FF8650;
85
+ background-color: #fff;
86
+ border-radius: 8px;
87
+ font-weight: 600;
88
+ font-size: 14px;
89
+
90
+ &:hover {
91
+ background-color: #fff;
92
+ }
45
93
  }
46
94
 
47
- .accordionContentWrap {
95
+ .btn-confirm {
48
96
  display: flex;
49
- flex-wrap: wrap;
97
+ flex: 1 1;
98
+ height: 54px;
50
99
  align-items: center;
51
- padding-bottom: 1px;
100
+ justify-content: center;
101
+ color: #fff;
102
+ border: 1px solid #FF8650;
103
+ background-color: #FF8650;
104
+ border-radius: 8px;
105
+ font-weight: 600;
106
+ font-size: 14px;
52
107
 
53
- .btnMore {
54
- font-weight: 600;
55
- font-size: 14px;
56
- color: var(--theme-color);
57
- margin-top: 6px;
58
- margin-left: 10px;
108
+ &:hover {
109
+ background-color: #FF8650;
59
110
  }
60
111
  }
61
112
  }
62
- }
63
-
64
- .bottomWrap {
65
- position: fixed;
66
- bottom: 0;
67
- background: #fff;
68
- width: 100%;
69
- height: 78px;
70
- padding: 12px 24px;
71
- display: flex;
72
113
  }
@@ -10,7 +10,7 @@
10
10
  margin-top: 8px;
11
11
 
12
12
  &.active {
13
- color: var(--theme-color);
14
- border-color: var(--theme-color);
13
+ color: #FF8650;
14
+ border-color: #FF8650;
15
15
  }
16
16
  }
@@ -164,8 +164,6 @@ function (_super) {
164
164
  }, oldPrice && /*#__PURE__*/_react["default"].createElement("div", {
165
165
  className: "old-price"
166
166
  }, oldPrice)), /*#__PURE__*/_react["default"].createElement("div", {
167
- className: "shipping-price"
168
- }, oldPrice), /*#__PURE__*/_react["default"].createElement("div", {
169
167
  className: "rate-sold-wrap"
170
168
  }, /*#__PURE__*/_react["default"].createElement("div", {
171
169
  className: "evaluation-score"
@@ -179,7 +177,7 @@ function (_super) {
179
177
  className: "line"
180
178
  }), /*#__PURE__*/_react["default"].createElement("div", {
181
179
  className: "sold"
182
- }, "Sold $", soldNumber, "+"))));
180
+ }, "Sold ", soldNumber || 0, "+"))));
183
181
  };
184
182
 
185
183
  ProductItem.defaultProps = {
@@ -102,15 +102,10 @@
102
102
  font-size: 0.24rem;
103
103
  color: #FA7373;
104
104
  }
105
- .monpay-interest-product-item-wrap .content-wrap .shipping-price {
106
- font-weight: 400;
107
- font-size: 0.24rem;
108
- color: #545454;
109
- margin-top: 0.16rem;
110
- }
111
105
  .monpay-interest-product-item-wrap .content-wrap .rate-sold-wrap {
112
106
  display: flex;
113
107
  align-items: center;
108
+ margin-top: 0.1rem;
114
109
  }
115
110
  .monpay-interest-product-item-wrap .content-wrap .rate-sold-wrap .evaluation-score {
116
111
  display: inline-flex;