@nutui/nutui-react-taro 3.0.19-cpp.22-3 → 3.0.19-cpp.22-4

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 (136) hide show
  1. package/dist/cjs/hooks/taro/use-custom-event.js +5 -5
  2. package/dist/cjs/hooks/use-ref-state.js +3 -3
  3. package/dist/cjs/hooks/use-touch.js +2 -1
  4. package/dist/cjs/packages/address/utils.js +3 -3
  5. package/dist/cjs/packages/avatarcropper/avatarcropper.js +28 -16
  6. package/dist/cjs/packages/badge/badge.js +7 -4
  7. package/dist/cjs/packages/barrage/barrage.js +24 -14
  8. package/dist/cjs/packages/calendar/style/calendar.scss +32 -1
  9. package/dist/cjs/packages/calendar/style/style.css +21 -1
  10. package/dist/cjs/packages/calendar/style/style.harmony.css +21 -1
  11. package/dist/cjs/packages/calendar/style-jmapp/calendar.scss +32 -1
  12. package/dist/cjs/packages/calendar/style-jmapp/style.css +21 -1
  13. package/dist/cjs/packages/calendar/style-jrkf/calendar.scss +32 -1
  14. package/dist/cjs/packages/calendar/style-jrkf/style.css +21 -1
  15. package/dist/cjs/packages/calendar/utils.js +8 -8
  16. package/dist/cjs/packages/calendarcard/icon.js +9 -15
  17. package/dist/cjs/packages/calendarcard/style/calendarcard.scss +13 -0
  18. package/dist/cjs/packages/calendarcard/style/style.css +8 -0
  19. package/dist/cjs/packages/calendarcard/style/style.harmony.css +8 -0
  20. package/dist/cjs/packages/calendarcard/style-jmapp/calendarcard.scss +13 -0
  21. package/dist/cjs/packages/calendarcard/style-jmapp/style.css +8 -0
  22. package/dist/cjs/packages/calendarcard/style-jrkf/calendarcard.scss +13 -0
  23. package/dist/cjs/packages/calendarcard/style-jrkf/style.css +8 -0
  24. package/dist/cjs/packages/calendarcard/utils.js +6 -6
  25. package/dist/cjs/packages/cascader/cascader.js +21 -12
  26. package/dist/cjs/packages/cascader/utils.js +3 -3
  27. package/dist/cjs/packages/collapseitem/collapseitem.js +7 -4
  28. package/dist/cjs/packages/configprovider/configprovider.js +7 -7
  29. package/dist/cjs/packages/configprovider/index.js +6 -6
  30. package/dist/cjs/packages/countdown/countdown.js +2 -1
  31. package/dist/cjs/packages/datepicker/utils.js +9 -9
  32. package/dist/cjs/packages/dialog/content.js +3 -3
  33. package/dist/cjs/packages/dialog/dialog.js +11 -8
  34. package/dist/cjs/packages/drag/drag.js +7 -4
  35. package/dist/cjs/packages/elevator/elevator.js +10 -7
  36. package/dist/cjs/packages/ellipsis/ellipsis.js +30 -17
  37. package/dist/cjs/packages/form/index.js +2 -0
  38. package/dist/cjs/packages/form/useform.js +57 -50
  39. package/dist/cjs/packages/infiniteloading/infiniteloading.js +14 -8
  40. package/dist/cjs/packages/inputnumber/inputnumber.js +28 -16
  41. package/dist/cjs/packages/lottie/types.js +2 -0
  42. package/dist/cjs/packages/menuitem/menuitem.js +22 -24
  43. package/dist/cjs/packages/noticebar/noticebar.js +70 -74
  44. package/dist/cjs/packages/notify/notify.js +4 -4
  45. package/dist/cjs/packages/nutui.react.build.js +105 -105
  46. package/dist/cjs/packages/nutui.react.js +105 -105
  47. package/dist/cjs/packages/overlay/overlay.js +3 -3
  48. package/dist/cjs/packages/pickerview/pickerroller.js +7 -4
  49. package/dist/cjs/packages/pickerview/pickerview.js +2 -1
  50. package/dist/cjs/packages/pickerview/utils.js +3 -3
  51. package/dist/cjs/packages/popover/popover.js +77 -75
  52. package/dist/cjs/packages/popup/popup.js +14 -8
  53. package/dist/cjs/packages/pulltorefresh/pulltorefresh.js +56 -52
  54. package/dist/cjs/packages/radio/index.js +2 -0
  55. package/dist/cjs/packages/range/range.js +28 -16
  56. package/dist/cjs/packages/shortpassword/shortpassword.js +3 -3
  57. package/dist/cjs/packages/sticky/sticky.js +7 -4
  58. package/dist/cjs/packages/swipe/swipe.js +14 -8
  59. package/dist/cjs/packages/swiper/index.js +1 -0
  60. package/dist/cjs/packages/switch/switch.js +7 -4
  61. package/dist/cjs/packages/toast/toast.js +4 -4
  62. package/dist/cjs/packages/uploader/uploader.js +51 -38
  63. package/dist/cjs/packages/virtuallist/utils.js +6 -6
  64. package/dist/cjs/packages/watermark/watermark.js +8 -4
  65. package/dist/cjs/types/spec/address/base.js +2 -0
  66. package/dist/cjs/utils/date.js +5 -5
  67. package/dist/cjs/utils/event-mocker.js +18 -10
  68. package/dist/cjs/utils/get-rect.js +4 -4
  69. package/dist/cjs/utils/get-scroll-parent.js +3 -3
  70. package/dist/cjs/utils/merge-props.js +3 -3
  71. package/dist/cjs/utils/merge.js +6 -6
  72. package/dist/cjs/utils/raf.js +3 -3
  73. package/dist/cjs/utils/render.js +9 -5
  74. package/dist/cjs/utils/rubberband.js +3 -3
  75. package/dist/cjs/utils/should-render-price-raw.js +3 -3
  76. package/dist/cjs/utils/taro/get-rect.js +24 -14
  77. package/dist/cjs/utils/taro/get-system-info.js +4 -4
  78. package/dist/cjs/utils/taro/platform.js +5 -5
  79. package/dist/es/hooks/use-touch.js +1 -1
  80. package/dist/es/packages/avatarcropper/avatarcropper.js +28 -16
  81. package/dist/es/packages/badge/badge.js +7 -4
  82. package/dist/es/packages/barrage/barrage.js +24 -14
  83. package/dist/es/packages/calendar/style/calendar.scss +32 -1
  84. package/dist/es/packages/calendar/style/style.css +21 -1
  85. package/dist/es/packages/calendar/style/style.harmony.css +21 -1
  86. package/dist/es/packages/calendar/style-jmapp/calendar.scss +32 -1
  87. package/dist/es/packages/calendar/style-jmapp/style.css +21 -1
  88. package/dist/es/packages/calendar/style-jrkf/calendar.scss +32 -1
  89. package/dist/es/packages/calendar/style-jrkf/style.css +21 -1
  90. package/dist/es/packages/calendarcard/icon.js +5 -11
  91. package/dist/es/packages/calendarcard/style/calendarcard.scss +13 -0
  92. package/dist/es/packages/calendarcard/style/style.css +8 -0
  93. package/dist/es/packages/calendarcard/style/style.harmony.css +8 -0
  94. package/dist/es/packages/calendarcard/style-jmapp/calendarcard.scss +13 -0
  95. package/dist/es/packages/calendarcard/style-jmapp/style.css +8 -0
  96. package/dist/es/packages/calendarcard/style-jrkf/calendarcard.scss +13 -0
  97. package/dist/es/packages/calendarcard/style-jrkf/style.css +8 -0
  98. package/dist/es/packages/cascader/cascader.js +21 -12
  99. package/dist/es/packages/collapseitem/collapseitem.js +7 -4
  100. package/dist/es/packages/countdown/countdown.js +2 -1
  101. package/dist/es/packages/dialog/dialog.js +7 -4
  102. package/dist/es/packages/drag/drag.js +7 -4
  103. package/dist/es/packages/elevator/elevator.js +7 -4
  104. package/dist/es/packages/ellipsis/ellipsis.js +30 -17
  105. package/dist/es/packages/form/index.js +1 -0
  106. package/dist/es/packages/form/useform.js +53 -46
  107. package/dist/es/packages/infiniteloading/infiniteloading.js +14 -8
  108. package/dist/es/packages/inputnumber/inputnumber.js +28 -16
  109. package/dist/es/packages/lottie/types.js +1 -1
  110. package/dist/es/packages/menuitem/menuitem.js +22 -24
  111. package/dist/es/packages/noticebar/noticebar.js +70 -74
  112. package/dist/es/packages/pickerview/pickerroller.js +7 -4
  113. package/dist/es/packages/pickerview/pickerview.js +2 -1
  114. package/dist/es/packages/popover/popover.js +77 -75
  115. package/dist/es/packages/popup/popup.js +14 -8
  116. package/dist/es/packages/pulltorefresh/pulltorefresh.js +56 -52
  117. package/dist/es/packages/radio/index.js +1 -0
  118. package/dist/es/packages/range/range.js +28 -16
  119. package/dist/es/packages/sticky/sticky.js +7 -4
  120. package/dist/es/packages/swipe/swipe.js +14 -8
  121. package/dist/es/packages/swiper/index.js +1 -0
  122. package/dist/es/packages/switch/switch.js +7 -4
  123. package/dist/es/packages/uploader/uploader.js +51 -38
  124. package/dist/es/packages/watermark/watermark.js +8 -4
  125. package/dist/es/types/spec/address/base.js +1 -1
  126. package/dist/es/utils/event-mocker.js +12 -4
  127. package/dist/es/utils/render.js +6 -2
  128. package/dist/es/utils/taro/get-rect.js +20 -10
  129. package/dist/nutui.react.umd.js +860 -656
  130. package/dist/style-jmapp.css +1 -1
  131. package/dist/style-jmapp.scss +41 -41
  132. package/dist/style-jrkf.css +1 -1
  133. package/dist/style-jrkf.scss +32 -32
  134. package/dist/style.css +1 -1
  135. package/dist/style.scss +34 -34
  136. package/package.json +1 -1
@@ -50,8 +50,8 @@ var Drag = function Drag(props) {
50
50
  var translateX = (0, _react.useRef)(0);
51
51
  var translateY = (0, _react.useRef)(0);
52
52
  var middleLine = (0, _react.useRef)(0);
53
- var getInfo = function getInfo() {
54
- return (0, _async_to_generator._)(function() {
53
+ var getInfo = /*#__PURE__*/ function() {
54
+ var _ref = (0, _async_to_generator._)(function() {
55
55
  var el, top, left, bottom, right, _getWindowInfo, screenWidth, windowHeight, _ref, width, height, dragTop, dragLeft;
56
56
  return (0, _ts_generator._)(this, function(_state) {
57
57
  switch(_state.label){
@@ -83,8 +83,11 @@ var Drag = function Drag(props) {
83
83
  ];
84
84
  }
85
85
  });
86
- })();
87
- };
86
+ });
87
+ return function getInfo() {
88
+ return _ref.apply(this, arguments);
89
+ };
90
+ }();
88
91
  var touchStart = function touchStart(e) {
89
92
  onDragStart === null || onDragStart === void 0 ? void 0 : onDragStart();
90
93
  var touches = e.touches[0];
@@ -5,14 +5,14 @@ Object.defineProperty(exports, "__esModule", {
5
5
  function _export(target, all) {
6
6
  for(var name in all)Object.defineProperty(target, name, {
7
7
  enumerable: true,
8
- get: Object.getOwnPropertyDescriptor(all, name).get
8
+ get: all[name]
9
9
  });
10
10
  }
11
11
  _export(exports, {
12
- get Elevator () {
12
+ Elevator: function() {
13
13
  return Elevator;
14
14
  },
15
- get elevatorContext () {
15
+ elevatorContext: function() {
16
16
  return elevatorContext;
17
17
  }
18
18
  });
@@ -113,8 +113,8 @@ var Elevator = function Elevator(props) {
113
113
  }
114
114
  });
115
115
  };
116
- var scrollTo = function scrollTo(index) {
117
- return (0, _async_to_generator._)(function() {
116
+ var scrollTo = /*#__PURE__*/ function() {
117
+ var _ref = (0, _async_to_generator._)(function(index) {
118
118
  var cacheIndex, scrollTop;
119
119
  return (0, _ts_generator._)(this, function(_state) {
120
120
  switch(_state.label){
@@ -154,8 +154,11 @@ var Elevator = function Elevator(props) {
154
154
  ];
155
155
  }
156
156
  });
157
- })();
158
- };
157
+ });
158
+ return function scrollTo(index) {
159
+ return _ref.apply(this, arguments);
160
+ };
161
+ }();
159
162
  var touchMove = function touchMove(e) {
160
163
  var firstTouch = e.touches[0];
161
164
  touchState.current.y2 = firstTouch.pageY;
@@ -102,8 +102,8 @@ var Ellipsis = function Ellipsis(props) {
102
102
  content
103
103
  ]);
104
104
  // 获取省略号宽度
105
- var getSymbolInfo = function getSymbolInfo() {
106
- return (0, _async_to_generator._)(function() {
105
+ var getSymbolInfo = /*#__PURE__*/ function() {
106
+ var _ref = (0, _async_to_generator._)(function() {
107
107
  var refe;
108
108
  return (0, _ts_generator._)(this, function(_state) {
109
109
  switch(_state.label){
@@ -120,16 +120,19 @@ var Ellipsis = function Ellipsis(props) {
120
120
  ];
121
121
  }
122
122
  });
123
- })();
124
- };
123
+ });
124
+ return function getSymbolInfo() {
125
+ return _ref.apply(this, arguments);
126
+ };
127
+ }();
125
128
  var symbolText = function symbolText() {
126
129
  if (direction === 'end' || direction === 'middle') {
127
130
  return "".concat(symbol).concat(expandText);
128
131
  }
129
132
  return "".concat(symbol).concat(expandText).concat(symbol);
130
133
  };
131
- var getReference = function getReference() {
132
- return (0, _async_to_generator._)(function() {
134
+ var getReference = /*#__PURE__*/ function() {
135
+ var _ref = (0, _async_to_generator._)(function() {
133
136
  var query;
134
137
  return (0, _ts_generator._)(this, function(_state) {
135
138
  query = (0, _taro.createSelectorQuery)();
@@ -166,11 +169,14 @@ var Ellipsis = function Ellipsis(props) {
166
169
  2
167
170
  ];
168
171
  });
169
- })();
170
- };
172
+ });
173
+ return function getReference() {
174
+ return _ref.apply(this, arguments);
175
+ };
176
+ }();
171
177
  // 计算省略号的位置
172
- var calcEllipse = function calcEllipse() {
173
- return (0, _async_to_generator._)(function() {
178
+ var calcEllipse = /*#__PURE__*/ function() {
179
+ var _ref = (0, _async_to_generator._)(function() {
174
180
  var refe, rowNum, end, end1, start;
175
181
  return (0, _ts_generator._)(this, function(_state) {
176
182
  switch(_state.label){
@@ -185,7 +191,8 @@ var Ellipsis = function Ellipsis(props) {
185
191
  setExceeded(false);
186
192
  setCacled(true);
187
193
  } else {
188
- rowNum = Math.floor(content.length / (originHeight.current / lineH.current - 1)); // 每行的字数
194
+ rowNum = Math.floor(content.length / (originHeight.current / lineH.current - 1)) // 每行的字数
195
+ ;
189
196
  if (direction === 'middle') {
190
197
  end = content.length;
191
198
  ellipsis.current.leading = tailorContent(0, rowNum * (Number(rows) + 0.5), 'end');
@@ -208,11 +215,14 @@ var Ellipsis = function Ellipsis(props) {
208
215
  ];
209
216
  }
210
217
  });
211
- })();
212
- };
218
+ });
219
+ return function calcEllipse() {
220
+ return _ref.apply(this, arguments);
221
+ };
222
+ }();
213
223
  // 验证省略号
214
- var verifyEllipsis = function verifyEllipsis1() {
215
- return (0, _async_to_generator._)(function() {
224
+ var verifyEllipsis = /*#__PURE__*/ function() {
225
+ var _ref = (0, _async_to_generator._)(function() {
216
226
  var refe, _ellipsis_current_leading, _ellipsis_current, _ellipsis_current_leading1, _ellipsis_current1, _ellipsis_current2, _ellipsis_current_tailing, _ellipsis_current3;
217
227
  return (0, _ts_generator._)(this, function(_state) {
218
228
  switch(_state.label){
@@ -241,8 +251,11 @@ var Ellipsis = function Ellipsis(props) {
241
251
  ];
242
252
  }
243
253
  });
244
- })();
245
- };
254
+ });
255
+ return function verifyEllipsis() {
256
+ return _ref.apply(this, arguments);
257
+ };
258
+ }();
246
259
  var assignContent = function assignContent() {
247
260
  var _ellipsis_current, _ellipsis_current1, _ellipsis_current2, _ellipsis_current3;
248
261
  var newContent = "".concat(((_ellipsis_current = ellipsis.current) === null || _ellipsis_current === void 0 ? void 0 : _ellipsis_current.leading) || '').concat(((_ellipsis_current1 = ellipsis.current) === null || _ellipsis_current1 === void 0 ? void 0 : _ellipsis_current1.leading) ? symbol : '').concat(expandText || '').concat(((_ellipsis_current2 = ellipsis.current) === null || _ellipsis_current2 === void 0 ? void 0 : _ellipsis_current2.tailing) ? symbol : '').concat(((_ellipsis_current3 = ellipsis.current) === null || _ellipsis_current3 === void 0 ? void 0 : _ellipsis_current3.tailing) || '');
@@ -8,6 +8,8 @@ Object.defineProperty(exports, "default", {
8
8
  return _default;
9
9
  }
10
10
  });
11
+ var _interop_require_default = require("@swc/helpers/_/_interop_require_default");
12
+ var _react = /*#__PURE__*/ _interop_require_default._(require("react"));
11
13
  var _form = require("./form");
12
14
  var _formitem = require("../formitem/formitem");
13
15
  var _useform = require("./useform");
@@ -5,17 +5,17 @@ Object.defineProperty(exports, "__esModule", {
5
5
  function _export(target, all) {
6
6
  for(var name in all)Object.defineProperty(target, name, {
7
7
  enumerable: true,
8
- get: Object.getOwnPropertyDescriptor(all, name).get
8
+ get: all[name]
9
9
  });
10
10
  }
11
11
  _export(exports, {
12
- get SECRET () {
12
+ SECRET: function() {
13
13
  return SECRET;
14
14
  },
15
- get useForm () {
15
+ useForm: function() {
16
16
  return useForm;
17
17
  },
18
- get useWatch () {
18
+ useWatch: function() {
19
19
  return useWatch;
20
20
  }
21
21
  });
@@ -40,6 +40,7 @@ var SECRET = 'NUT_FORM_INTERNAL';
40
40
  var _this = this;
41
41
  var _this1 = this;
42
42
  (0, _class_call_check._)(this, FormStore);
43
+ var _this2 = this;
43
44
  // 初始化数据
44
45
  (0, _define_property._)(this, "initialValues", {});
45
46
  (0, _define_property._)(this, "updateList", []);
@@ -127,8 +128,8 @@ var SECRET = 'NUT_FORM_INTERNAL';
127
128
  (0, _define_property._)(this, "setCallback", function(callback) {
128
129
  _this.callbacks = (0, _object_spread._)({}, _this.callbacks, callback);
129
130
  });
130
- (0, _define_property._)(this, "validateEntities", function(entity, errs) {
131
- return (0, _async_to_generator._)(function() {
131
+ (0, _define_property._)(this, "validateEntities", /*#__PURE__*/ function() {
132
+ var _ref = (0, _async_to_generator._)(function(entity, errs) {
132
133
  var _entity_props, name, _entity_props_rules, rules, descriptor, validator, _this_store, param, errors, _errs;
133
134
  return (0, _ts_generator._)(this, function(_state) {
134
135
  switch(_state.label){
@@ -163,7 +164,7 @@ var SECRET = 'NUT_FORM_INTERNAL';
163
164
  ]);
164
165
  return [
165
166
  4,
166
- validator.validate((0, _define_property._)({}, name, (_this_store = this.store) === null || _this_store === void 0 ? void 0 : _this_store[name]))
167
+ validator.validate((0, _define_property._)({}, name, (_this_store = _this2.store) === null || _this_store === void 0 ? void 0 : _this_store[name]))
167
168
  ];
168
169
  case 2:
169
170
  _state.sent();
@@ -177,7 +178,7 @@ var SECRET = 'NUT_FORM_INTERNAL';
177
178
  if (errors) {
178
179
  ;
179
180
  (_errs = errs).push.apply(_errs, (0, _to_consumable_array._)(errors));
180
- this.errors[name] = errors;
181
+ _this2.errors[name] = errors;
181
182
  }
182
183
  return [
183
184
  3,
@@ -185,7 +186,7 @@ var SECRET = 'NUT_FORM_INTERNAL';
185
186
  ];
186
187
  case 4:
187
188
  if (!errs || errs.length === 0) {
188
- this.errors[name] = [];
189
+ _this2.errors[name] = [];
189
190
  }
190
191
  return [
191
192
  7
@@ -197,21 +198,23 @@ var SECRET = 'NUT_FORM_INTERNAL';
197
198
  ];
198
199
  }
199
200
  });
200
- }).call(_this);
201
- });
202
- (0, _define_property._)(this, "validateFields", function(nameList) {
203
- return (0, _async_to_generator._)(function() {
204
- var _this, filterEntities, errs;
201
+ });
202
+ return function(entity, errs) {
203
+ return _ref.apply(this, arguments);
204
+ };
205
+ }());
206
+ (0, _define_property._)(this, "validateFields", /*#__PURE__*/ function() {
207
+ var _ref = (0, _async_to_generator._)(function(nameList) {
208
+ var filterEntities, errs;
205
209
  return (0, _ts_generator._)(this, function(_state) {
206
210
  switch(_state.label){
207
211
  case 0:
208
- _this = this;
209
212
  filterEntities = [];
210
213
  // this.errors.length = 0
211
214
  if (!nameList || nameList.length === 0) {
212
- filterEntities = this.fieldEntities;
215
+ filterEntities = _this2.fieldEntities;
213
216
  } else {
214
- filterEntities = this.fieldEntities.filter(function(param) {
217
+ filterEntities = _this2.fieldEntities.filter(function(param) {
215
218
  var name = param.props.name;
216
219
  return nameList.includes(name);
217
220
  });
@@ -219,14 +222,14 @@ var SECRET = 'NUT_FORM_INTERNAL';
219
222
  errs = [];
220
223
  return [
221
224
  4,
222
- Promise.all(filterEntities.map(function(entity) {
223
- return (0, _async_to_generator._)(function() {
225
+ Promise.all(filterEntities.map(/*#__PURE__*/ function() {
226
+ var _ref = (0, _async_to_generator._)(function(entity) {
224
227
  return (0, _ts_generator._)(this, function(_state) {
225
228
  switch(_state.label){
226
229
  case 0:
227
230
  return [
228
231
  4,
229
- this.validateEntities(entity, errs)
232
+ _this2.validateEntities(entity, errs)
230
233
  ];
231
234
  case 1:
232
235
  _state.sent();
@@ -235,8 +238,11 @@ var SECRET = 'NUT_FORM_INTERNAL';
235
238
  ];
236
239
  }
237
240
  });
238
- }).call(_this);
239
- }))
241
+ });
242
+ return function(entity) {
243
+ return _ref.apply(this, arguments);
244
+ };
245
+ }()))
240
246
  ];
241
247
  case 1:
242
248
  _state.sent();
@@ -246,34 +252,35 @@ var SECRET = 'NUT_FORM_INTERNAL';
246
252
  ];
247
253
  }
248
254
  });
249
- }).call(_this);
250
- });
251
- (0, _define_property._)(this, "submit", function() {
252
- return (0, _async_to_generator._)(function() {
253
- var errors, _this_callbacks_onFinish, _this_callbacks, _this_callbacks_onFinishFailed, _this_callbacks1;
254
- return (0, _ts_generator._)(this, function(_state) {
255
- switch(_state.label){
256
- case 0:
257
- return [
258
- 4,
259
- this.validateFields()
260
- ];
261
- case 1:
262
- errors = _state.sent();
263
- if (errors.length === 0) {
264
- ;
265
- (_this_callbacks_onFinish = (_this_callbacks = this.callbacks).onFinish) === null || _this_callbacks_onFinish === void 0 ? void 0 : _this_callbacks_onFinish.call(_this_callbacks, this.store);
266
- } else if (errors.length > 0) {
267
- ;
268
- (_this_callbacks_onFinishFailed = (_this_callbacks1 = this.callbacks).onFinishFailed) === null || _this_callbacks_onFinishFailed === void 0 ? void 0 : _this_callbacks_onFinishFailed.call(_this_callbacks1, this.store, errors);
269
- }
270
- return [
271
- 2
272
- ];
273
- }
274
- });
275
- }).call(_this);
276
- });
255
+ });
256
+ return function(nameList) {
257
+ return _ref.apply(this, arguments);
258
+ };
259
+ }());
260
+ (0, _define_property._)(this, "submit", /*#__PURE__*/ (0, _async_to_generator._)(function() {
261
+ var errors, _this_callbacks_onFinish, _this_callbacks, _this_callbacks_onFinishFailed, _this_callbacks1;
262
+ return (0, _ts_generator._)(this, function(_state) {
263
+ switch(_state.label){
264
+ case 0:
265
+ return [
266
+ 4,
267
+ _this2.validateFields()
268
+ ];
269
+ case 1:
270
+ errors = _state.sent();
271
+ if (errors.length === 0) {
272
+ ;
273
+ (_this_callbacks_onFinish = (_this_callbacks = _this2.callbacks).onFinish) === null || _this_callbacks_onFinish === void 0 ? void 0 : _this_callbacks_onFinish.call(_this_callbacks, _this2.store);
274
+ } else if (errors.length > 0) {
275
+ ;
276
+ (_this_callbacks_onFinishFailed = (_this_callbacks1 = _this2.callbacks).onFinishFailed) === null || _this_callbacks_onFinishFailed === void 0 ? void 0 : _this_callbacks_onFinishFailed.call(_this_callbacks1, _this2.store, errors);
277
+ }
278
+ return [
279
+ 2
280
+ ];
281
+ }
282
+ });
283
+ }));
277
284
  (0, _define_property._)(this, "resetFields", function(namePaths) {
278
285
  if (namePaths && namePaths.length) {
279
286
  namePaths.forEach(function(path) {
@@ -113,8 +113,8 @@ var InfiniteLoading = function InfiniteLoading(props) {
113
113
  }
114
114
  onScroll && onScroll(e.target.scrollTop);
115
115
  };
116
- var lower = function lower() {
117
- return (0, _async_to_generator._)(function() {
116
+ var lower = /*#__PURE__*/ function() {
117
+ var _ref = (0, _async_to_generator._)(function() {
118
118
  return (0, _ts_generator._)(this, function(_state) {
119
119
  switch(_state.label){
120
120
  case 0:
@@ -137,8 +137,11 @@ var InfiniteLoading = function InfiniteLoading(props) {
137
137
  ];
138
138
  }
139
139
  });
140
- })();
141
- };
140
+ });
141
+ return function lower() {
142
+ return _ref.apply(this, arguments);
143
+ };
144
+ }();
142
145
  var touchStart = function touchStart(event) {
143
146
  if (scrollTop.current === 0 && !isTouching.current && pullRefresh) {
144
147
  y.current = event.touches[0].pageY;
@@ -160,8 +163,8 @@ var InfiniteLoading = function InfiniteLoading(props) {
160
163
  isTouching.current = false;
161
164
  }
162
165
  };
163
- var touchEnd = function touchEnd() {
164
- return (0, _async_to_generator._)(function() {
166
+ var touchEnd = /*#__PURE__*/ function() {
167
+ var _ref = (0, _async_to_generator._)(function() {
165
168
  return (0, _ts_generator._)(this, function(_state) {
166
169
  switch(_state.label){
167
170
  case 0:
@@ -191,8 +194,11 @@ var InfiniteLoading = function InfiniteLoading(props) {
191
194
  ];
192
195
  }
193
196
  });
194
- })();
195
- };
197
+ });
198
+ return function touchEnd() {
199
+ return _ref.apply(this, arguments);
200
+ };
201
+ }();
196
202
  return /*#__PURE__*/ _react.default.createElement(_components.ScrollView, (0, _object_spread_props._)((0, _object_spread._)({}, rest), {
197
203
  className: classes,
198
204
  scrollY: true,
@@ -107,8 +107,8 @@ var InputNumber = function InputNumber(props) {
107
107
  var stepAmount = parseFloat(stepValue) * symbol;
108
108
  return (currentValue * dig + stepAmount * dig) / dig;
109
109
  };
110
- var update = function update(negative, e) {
111
- return (0, _async_to_generator._)(function() {
110
+ var update = /*#__PURE__*/ function() {
111
+ var _ref = (0, _async_to_generator._)(function(negative, e) {
112
112
  var shouldOverBoundary, maybeResume, nextValue;
113
113
  return (0, _ts_generator._)(this, function(_state) {
114
114
  switch(_state.label){
@@ -139,10 +139,13 @@ var InputNumber = function InputNumber(props) {
139
139
  ];
140
140
  }
141
141
  });
142
- })();
143
- };
144
- var handleReduce = function handleReduce(e) {
145
- return (0, _async_to_generator._)(function() {
142
+ });
143
+ return function update(negative, e) {
144
+ return _ref.apply(this, arguments);
145
+ };
146
+ }();
147
+ var handleReduce = /*#__PURE__*/ function() {
148
+ var _ref = (0, _async_to_generator._)(function(e) {
146
149
  return (0, _ts_generator._)(this, function(_state) {
147
150
  switch(_state.label){
148
151
  case 0:
@@ -160,10 +163,13 @@ var InputNumber = function InputNumber(props) {
160
163
  ];
161
164
  }
162
165
  });
163
- })();
164
- };
165
- var handlePlus = function handlePlus(e) {
166
- return (0, _async_to_generator._)(function() {
166
+ });
167
+ return function handleReduce(e) {
168
+ return _ref.apply(this, arguments);
169
+ };
170
+ }();
171
+ var handlePlus = /*#__PURE__*/ function() {
172
+ var _ref = (0, _async_to_generator._)(function(e) {
167
173
  return (0, _ts_generator._)(this, function(_state) {
168
174
  switch(_state.label){
169
175
  case 0:
@@ -181,15 +187,18 @@ var InputNumber = function InputNumber(props) {
181
187
  ];
182
188
  }
183
189
  });
184
- })();
185
- };
190
+ });
191
+ return function handlePlus(e) {
192
+ return _ref.apply(this, arguments);
193
+ };
194
+ }();
186
195
  var parseValue = function parseValue(text) {
187
196
  if (text === '') return null;
188
197
  if (text === '-') return null;
189
198
  return text;
190
199
  };
191
- var handleInputChange = function handleInputChange(e) {
192
- return (0, _async_to_generator._)(function() {
200
+ var handleInputChange = /*#__PURE__*/ function() {
201
+ var _ref = (0, _async_to_generator._)(function(e) {
193
202
  var valueStr, maybeResume;
194
203
  return (0, _ts_generator._)(this, function(_state) {
195
204
  switch(_state.label){
@@ -217,8 +226,11 @@ var InputNumber = function InputNumber(props) {
217
226
  ];
218
227
  }
219
228
  });
220
- })();
221
- };
229
+ });
230
+ return function handleInputChange(e) {
231
+ return _ref.apply(this, arguments);
232
+ };
233
+ }();
222
234
  var handleFocus = function handleFocus(e) {
223
235
  setFocused(true);
224
236
  setInputValue(shadowValue !== undefined && shadowValue !== null ? (0, _bound.bound)(Number(shadowValue), Number(min), Number(max)).toString() : '');
@@ -2,3 +2,5 @@
2
2
  Object.defineProperty(exports, "__esModule", {
3
3
  value: true
4
4
  });
5
+ var _interop_require_default = require("@swc/helpers/_/_interop_require_default");
6
+ var _react = /*#__PURE__*/ _interop_require_default._(require("react"));
@@ -60,30 +60,28 @@ var MenuItem = /*#__PURE__*/ (0, _react.forwardRef)(function(props, ref) {
60
60
  show
61
61
  ]);
62
62
  var getParentOffset = (0, _react.useCallback)(function() {
63
- setTimeout(function() {
64
- return (0, _async_to_generator._)(function() {
65
- var p, rect;
66
- return (0, _ts_generator._)(this, function(_state) {
67
- switch(_state.label){
68
- case 0:
69
- p = parent.menuRef.current;
70
- return [
71
- 4,
72
- (0, _getrect.getRectInMultiPlatform)(p)
73
- ];
74
- case 1:
75
- rect = _state.sent();
76
- setPosition({
77
- height: rect.height,
78
- top: rect.top
79
- });
80
- return [
81
- 2
82
- ];
83
- }
84
- });
85
- })();
86
- }, 100);
63
+ setTimeout(/*#__PURE__*/ (0, _async_to_generator._)(function() {
64
+ var p, rect;
65
+ return (0, _ts_generator._)(this, function(_state) {
66
+ switch(_state.label){
67
+ case 0:
68
+ p = parent.menuRef.current;
69
+ return [
70
+ 4,
71
+ (0, _getrect.getRectInMultiPlatform)(p)
72
+ ];
73
+ case 1:
74
+ rect = _state.sent();
75
+ setPosition({
76
+ height: rect.height,
77
+ top: rect.top
78
+ });
79
+ return [
80
+ 2
81
+ ];
82
+ }
83
+ });
84
+ }), 100);
87
85
  }, [
88
86
  parent.menuRef
89
87
  ]);