@nutui/nutui-react 3.0.19 → 3.0.20

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 (108) hide show
  1. package/CHANGELOG.md +65 -54
  2. package/dist/cjs/hooks/taro/use-custom-event.js +5 -5
  3. package/dist/cjs/hooks/use-ref-state.js +3 -3
  4. package/dist/cjs/hooks/use-touch.js +1 -2
  5. package/dist/cjs/locales/vi-VN.d.ts +3 -0
  6. package/dist/cjs/locales/vi-VN.js +170 -0
  7. package/dist/cjs/packages/address/address.js +3 -3
  8. package/dist/cjs/packages/address/utils.js +3 -3
  9. package/dist/cjs/packages/avatarcropper/avatarcropper.js +4 -7
  10. package/dist/cjs/packages/calendar/utils.js +8 -8
  11. package/dist/cjs/packages/calendarcard/icon.js +5 -5
  12. package/dist/cjs/packages/calendarcard/utils.js +6 -6
  13. package/dist/cjs/packages/cascader/cascader.js +12 -21
  14. package/dist/cjs/packages/cascader/utils.js +3 -3
  15. package/dist/cjs/packages/collapseitem/collapseitem.js +4 -7
  16. package/dist/cjs/packages/configprovider/configprovider.js +7 -7
  17. package/dist/cjs/packages/configprovider/index.js +6 -6
  18. package/dist/cjs/packages/countdown/countdown.js +1 -2
  19. package/dist/cjs/packages/datepicker/utils.js +9 -9
  20. package/dist/cjs/packages/dialog/content.js +3 -3
  21. package/dist/cjs/packages/dialog/dialog.js +4 -7
  22. package/dist/cjs/packages/elevator/elevator.js +3 -3
  23. package/dist/cjs/packages/form/index.js +0 -2
  24. package/dist/cjs/packages/form/useform.js +50 -57
  25. package/dist/cjs/packages/infiniteloading/infiniteloading.js +8 -14
  26. package/dist/cjs/packages/inputnumber/inputnumber.js +16 -28
  27. package/dist/cjs/packages/lottie/types.js +0 -2
  28. package/dist/cjs/packages/nutui.react.build.js +105 -105
  29. package/dist/cjs/packages/nutui.react.js +105 -105
  30. package/dist/cjs/packages/overlay/overlay.js +3 -3
  31. package/dist/cjs/packages/pickerview/pickerview.js +1 -2
  32. package/dist/cjs/packages/pickerview/utils.js +3 -3
  33. package/dist/cjs/packages/pulltorefresh/pulltorefresh.js +41 -51
  34. package/dist/cjs/packages/radio/index.js +0 -2
  35. package/dist/cjs/packages/range/utils.js +3 -3
  36. package/dist/cjs/packages/safearea/safearea.js +12 -3
  37. package/dist/cjs/packages/safearea/style/safearea.scss +6 -0
  38. package/dist/cjs/packages/safearea/style/style.css +2 -0
  39. package/dist/cjs/packages/safearea/style-jmapp/safearea.scss +6 -0
  40. package/dist/cjs/packages/safearea/style-jmapp/style.css +2 -0
  41. package/dist/cjs/packages/safearea/style-jrkf/safearea.scss +6 -0
  42. package/dist/cjs/packages/safearea/style-jrkf/style.css +2 -0
  43. package/dist/cjs/packages/shortpassword/shortpassword.js +3 -3
  44. package/dist/cjs/packages/skeleton/skeleton.js +2 -4
  45. package/dist/cjs/packages/swiper/effects/focus.js +4 -4
  46. package/dist/cjs/packages/swiper/index.js +0 -1
  47. package/dist/cjs/packages/switch/switch.js +4 -7
  48. package/dist/cjs/packages/uploader/uploader.js +30 -37
  49. package/dist/cjs/packages/virtuallist/utils.js +6 -6
  50. package/dist/cjs/packages/watermark/watermark.js +4 -8
  51. package/dist/cjs/types/spec/address/base.js +0 -2
  52. package/dist/cjs/utils/date.js +5 -5
  53. package/dist/cjs/utils/event-mocker.js +10 -18
  54. package/dist/cjs/utils/get-rect.js +4 -4
  55. package/dist/cjs/utils/get-scroll-parent.js +3 -3
  56. package/dist/cjs/utils/merge-props.js +3 -3
  57. package/dist/cjs/utils/merge.js +6 -6
  58. package/dist/cjs/utils/raf.js +3 -3
  59. package/dist/cjs/utils/render.js +5 -9
  60. package/dist/cjs/utils/rubberband.js +3 -3
  61. package/dist/cjs/utils/taro/ConfigurableCSSTransition copy.d.ts +15 -0
  62. package/dist/cjs/utils/taro/ConfigurableCSSTransition copy.js +130 -0
  63. package/dist/cjs/utils/taro/get-rect.js +14 -24
  64. package/dist/cjs/utils/taro/get-system-info.js +4 -4
  65. package/dist/cjs/utils/taro/platform.js +5 -5
  66. package/dist/es/hooks/use-touch.js +1 -1
  67. package/dist/es/locales/vi-VN.d.ts +3 -0
  68. package/dist/es/locales/vi-VN.js +160 -0
  69. package/dist/es/packages/avatarcropper/avatarcropper.js +4 -7
  70. package/dist/es/packages/cascader/cascader.js +12 -21
  71. package/dist/es/packages/collapseitem/collapseitem.js +4 -7
  72. package/dist/es/packages/countdown/countdown.js +1 -2
  73. package/dist/es/packages/dialog/dialog.js +4 -7
  74. package/dist/es/packages/form/index.js +0 -1
  75. package/dist/es/packages/form/useform.js +46 -53
  76. package/dist/es/packages/infiniteloading/infiniteloading.js +8 -14
  77. package/dist/es/packages/inputnumber/inputnumber.js +16 -28
  78. package/dist/es/packages/lottie/types.js +1 -1
  79. package/dist/es/packages/pickerview/pickerview.js +1 -2
  80. package/dist/es/packages/pulltorefresh/pulltorefresh.js +41 -51
  81. package/dist/es/packages/radio/index.js +0 -1
  82. package/dist/es/packages/safearea/safearea.js +12 -3
  83. package/dist/es/packages/safearea/style/safearea.scss +6 -0
  84. package/dist/es/packages/safearea/style/style.css +2 -0
  85. package/dist/es/packages/safearea/style-jmapp/safearea.scss +6 -0
  86. package/dist/es/packages/safearea/style-jmapp/style.css +2 -0
  87. package/dist/es/packages/safearea/style-jrkf/safearea.scss +6 -0
  88. package/dist/es/packages/safearea/style-jrkf/style.css +2 -0
  89. package/dist/es/packages/skeleton/skeleton.js +2 -4
  90. package/dist/es/packages/swiper/index.js +0 -1
  91. package/dist/es/packages/switch/switch.js +4 -7
  92. package/dist/es/packages/uploader/uploader.js +30 -37
  93. package/dist/es/packages/watermark/watermark.js +4 -8
  94. package/dist/es/types/spec/address/base.js +1 -1
  95. package/dist/es/utils/event-mocker.js +4 -12
  96. package/dist/es/utils/render.js +2 -6
  97. package/dist/es/utils/taro/ConfigurableCSSTransition copy.d.ts +15 -0
  98. package/dist/es/utils/taro/ConfigurableCSSTransition copy.js +119 -0
  99. package/dist/es/utils/taro/get-rect.js +10 -20
  100. package/dist/nutui.react.umd.js +405 -595
  101. package/dist/style-jmapp.css +1 -1
  102. package/dist/style-jmapp.scss +30 -30
  103. package/dist/style-jrkf.css +1 -1
  104. package/dist/style-jrkf.scss +37 -37
  105. package/dist/style.css +1 -1
  106. package/dist/style.scss +35 -35
  107. package/package.json +1 -1
  108. package/postinstall.js +9 -0
@@ -0,0 +1,130 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", {
3
+ value: true
4
+ });
5
+ Object.defineProperty(exports, "default", {
6
+ enumerable: true,
7
+ get: function() {
8
+ return _default;
9
+ }
10
+ });
11
+ var _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
12
+ var _sliced_to_array = require("@swc/helpers/_/_sliced_to_array");
13
+ var _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
14
+ var ConfigurableCSSTransition = function ConfigurableCSSTransition(props) {
15
+ var inPhase = props.in, _props_timeout = props.timeout, timeout = _props_timeout === void 0 ? 300 : _props_timeout, tmp = props.classNames, baseClassName = tmp === void 0 ? '' : tmp, nodeRef = props.nodeRef, mountOnEnter = props.mountOnEnter, unmountOnExit = props.unmountOnExit, onEntered = props.onEntered, onExited = props.onExited, children = props.children;
16
+ var _useState = (0, _sliced_to_array._)((0, _react.useState)(function() {
17
+ if (inPhase) return 'entered';
18
+ return unmountOnExit || mountOnEnter ? 'unmounted' : 'exited';
19
+ }), 2), status = _useState[0], setStatus = _useState[1];
20
+ var _useState1 = (0, _sliced_to_array._)((0, _react.useState)(function() {
21
+ if (inPhase) return "".concat(baseClassName, "-enter-done");
22
+ return "".concat(baseClassName, "-exit-done");
23
+ }), 2), classes = _useState1[0], setClasses = _useState1[1];
24
+ var fallbackTimerRef = (0, _react.useRef)(null);
25
+ var statusRef = (0, _react.useRef)(status);
26
+ var prevInPhase = (0, _react.useRef)(inPhase);
27
+ var latestOnAnimationEnd = (0, _react.useRef)(children.props.onAnimationEnd);
28
+ (0, _react.useEffect)(function() {
29
+ latestOnAnimationEnd.current = children.props.onAnimationEnd;
30
+ });
31
+ var updateStatus = (0, _react.useCallback)(function(nextStatus) {
32
+ statusRef.current = nextStatus;
33
+ setStatus(nextStatus);
34
+ }, []);
35
+ var handleAnimationEnd = (0, _react.useCallback)(function(e) {
36
+ var _latestOnAnimationEnd_current;
37
+ (_latestOnAnimationEnd_current = latestOnAnimationEnd.current) === null || _latestOnAnimationEnd_current === void 0 ? void 0 : _latestOnAnimationEnd_current.call(latestOnAnimationEnd, e);
38
+ if (e && e.target !== e.currentTarget) return;
39
+ if (fallbackTimerRef.current) clearTimeout(fallbackTimerRef.current);
40
+ if (statusRef.current === 'entering') {
41
+ updateStatus('entered');
42
+ setClasses("".concat(baseClassName, "-enter-done"));
43
+ onEntered === null || onEntered === void 0 ? void 0 : onEntered();
44
+ } else if (statusRef.current === 'exiting') {
45
+ updateStatus('exited');
46
+ setClasses("".concat(baseClassName, "-exit-done"));
47
+ if (unmountOnExit) {
48
+ updateStatus('unmounted');
49
+ }
50
+ onExited === null || onExited === void 0 ? void 0 : onExited();
51
+ }
52
+ }, [
53
+ baseClassName,
54
+ onEntered,
55
+ onExited,
56
+ unmountOnExit,
57
+ updateStatus
58
+ ]);
59
+ var enter = (0, _react.useCallback)(function() {
60
+ if (fallbackTimerRef.current) clearTimeout(fallbackTimerRef.current);
61
+ if (statusRef.current === 'unmounted') {
62
+ updateStatus('exited');
63
+ }
64
+ if (timeout === 0) {
65
+ updateStatus('entered');
66
+ setClasses("".concat(baseClassName, "-enter-done"));
67
+ onEntered === null || onEntered === void 0 ? void 0 : onEntered();
68
+ return;
69
+ }
70
+ updateStatus('entering');
71
+ setClasses("".concat(baseClassName, "-enter ").concat(baseClassName, "-enter-active"));
72
+ // Safety fallback: Give it extra time over the expected timeout in case onAnimationEnd misses
73
+ fallbackTimerRef.current = setTimeout(function() {
74
+ handleAnimationEnd(null);
75
+ }, timeout + 200);
76
+ }, [
77
+ baseClassName,
78
+ handleAnimationEnd,
79
+ onEntered,
80
+ timeout,
81
+ updateStatus
82
+ ]);
83
+ var exit = (0, _react.useCallback)(function() {
84
+ if (fallbackTimerRef.current) clearTimeout(fallbackTimerRef.current);
85
+ if (timeout === 0) {
86
+ updateStatus('exited');
87
+ setClasses("".concat(baseClassName, "-exit-done"));
88
+ if (unmountOnExit) {
89
+ updateStatus('unmounted');
90
+ }
91
+ onExited === null || onExited === void 0 ? void 0 : onExited();
92
+ return;
93
+ }
94
+ updateStatus('exiting');
95
+ setClasses("".concat(baseClassName, "-exit ").concat(baseClassName, "-exit-active"));
96
+ fallbackTimerRef.current = setTimeout(function() {
97
+ handleAnimationEnd(null);
98
+ }, timeout + 200);
99
+ }, [
100
+ baseClassName,
101
+ handleAnimationEnd,
102
+ onExited,
103
+ timeout,
104
+ unmountOnExit,
105
+ updateStatus
106
+ ]);
107
+ (0, _react.useEffect)(function() {
108
+ if (prevInPhase.current !== inPhase) {
109
+ if (inPhase) {
110
+ enter();
111
+ } else {
112
+ exit();
113
+ }
114
+ prevInPhase.current = inPhase;
115
+ }
116
+ return function() {
117
+ if (fallbackTimerRef.current) clearTimeout(fallbackTimerRef.current);
118
+ };
119
+ }, [
120
+ inPhase,
121
+ enter,
122
+ exit
123
+ ]);
124
+ if (status === 'unmounted') return null;
125
+ return /*#__PURE__*/ (0, _react.cloneElement)(children, {
126
+ className: "".concat(children.props.className || '', " ").concat(classes),
127
+ onAnimationEnd: handleAnimationEnd
128
+ });
129
+ };
130
+ var _default = ConfigurableCSSTransition;
@@ -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: all[name]
8
+ get: Object.getOwnPropertyDescriptor(all, name).get
9
9
  });
10
10
  }
11
11
  _export(exports, {
12
- getRectInMultiPlatform: function() {
12
+ get getRectInMultiPlatform () {
13
13
  return getRectInMultiPlatform;
14
14
  },
15
- getRectInMultiPlatformWithoutCache: function() {
15
+ get getRectInMultiPlatformWithoutCache () {
16
16
  return getRectInMultiPlatformWithoutCache;
17
17
  },
18
- makeRect: function() {
18
+ get makeRect () {
19
19
  return makeRect;
20
20
  }
21
21
  });
@@ -36,12 +36,10 @@ function makeRect(width, height) {
36
36
  height: height
37
37
  };
38
38
  }
39
- var getRectInMultiPlatform = /*#__PURE__*/ function() {
40
- var _ref = (0, _async_to_generator._)(function(element) {
41
- var harmonyId;
42
- var _arguments = arguments;
39
+ var getRectInMultiPlatform = function getRectInMultiPlatform(element) {
40
+ var harmonyId = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : '';
41
+ return (0, _async_to_generator._)(function() {
43
42
  return (0, _ts_generator._)(this, function(_state) {
44
- harmonyId = _arguments.length > 1 && _arguments[1] !== void 0 ? _arguments[1] : '';
45
43
  if (element) {
46
44
  if (_getrect.inBrowser) {
47
45
  return [
@@ -72,17 +70,12 @@ var getRectInMultiPlatform = /*#__PURE__*/ function() {
72
70
  Promise.resolve(makeRect(0, 0))
73
71
  ];
74
72
  });
75
- });
76
- return function getRectInMultiPlatform(element) {
77
- return _ref.apply(this, arguments);
78
- };
79
- }();
80
- var getRectInMultiPlatformWithoutCache = /*#__PURE__*/ function() {
81
- var _ref = (0, _async_to_generator._)(function(element) {
82
- var harmonyId;
83
- var _arguments = arguments;
73
+ })();
74
+ };
75
+ var getRectInMultiPlatformWithoutCache = function getRectInMultiPlatformWithoutCache(element) {
76
+ var harmonyId = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : '';
77
+ return (0, _async_to_generator._)(function() {
84
78
  return (0, _ts_generator._)(this, function(_state) {
85
- harmonyId = _arguments.length > 1 && _arguments[1] !== void 0 ? _arguments[1] : '';
86
79
  if (element) {
87
80
  if (_getrect.inBrowser) {
88
81
  return [
@@ -105,8 +98,5 @@ var getRectInMultiPlatformWithoutCache = /*#__PURE__*/ function() {
105
98
  Promise.resolve(makeRect(0, 0))
106
99
  ];
107
100
  });
108
- });
109
- return function getRectInMultiPlatformWithoutCache(element) {
110
- return _ref.apply(this, arguments);
111
- };
112
- }();
101
+ })();
102
+ };
@@ -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: all[name]
8
+ get: Object.getOwnPropertyDescriptor(all, name).get
9
9
  });
10
10
  }
11
11
  _export(exports, {
12
- getAppBaseInfo: function() {
12
+ get getAppBaseInfo () {
13
13
  return getAppBaseInfo;
14
14
  },
15
- getDeviceInfo: function() {
15
+ get getDeviceInfo () {
16
16
  return getDeviceInfo;
17
17
  },
18
- getWindowInfo: function() {
18
+ get getWindowInfo () {
19
19
  return getWindowInfo;
20
20
  }
21
21
  });
@@ -5,20 +5,20 @@ 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: all[name]
8
+ get: Object.getOwnPropertyDescriptor(all, name).get
9
9
  });
10
10
  }
11
11
  _export(exports, {
12
- harmony: function() {
12
+ get harmony () {
13
13
  return harmony;
14
14
  },
15
- miniprogram: function() {
15
+ get miniprogram () {
16
16
  return miniprogram;
17
17
  },
18
- td: function() {
18
+ get td () {
19
19
  return td;
20
20
  },
21
- web: function() {
21
+ get web () {
22
22
  return web;
23
23
  }
24
24
  });
@@ -1,4 +1,4 @@
1
- import React, { useRef } from "react";
1
+ import { useRef } from "react";
2
2
  var MIN_DISTANCE = 10;
3
3
  function getDirection(x, y) {
4
4
  if (x > y && x > MIN_DISTANCE) {
@@ -0,0 +1,3 @@
1
+ import { BaseLang } from './base';
2
+ declare const viVN: BaseLang;
3
+ export default viVN;
@@ -0,0 +1,160 @@
1
+ var viVN = {
2
+ save: 'Lưu',
3
+ confirm: 'Xác nhận',
4
+ cancel: 'Hủy',
5
+ done: 'Hoàn thành',
6
+ noData: 'Tạm thời không có dữ liệu',
7
+ placeholder: 'Vui lòng nhập nội dung',
8
+ select: 'Vui lòng chọn',
9
+ edit: 'Chỉnh sửa',
10
+ reset: 'Đặt lại',
11
+ close: 'Đóng',
12
+ video: {
13
+ errorTip: 'Tải video không thành công',
14
+ clickRetry: 'Nhấn để thử lại'
15
+ },
16
+ fixednav: {
17
+ activeText: 'Thu gọn thanh điều hướng',
18
+ inactiveText: 'Điều hướng nhanh'
19
+ },
20
+ infiniteloading: {
21
+ pullRefreshText: 'Thả để làm mới',
22
+ loadText: 'Đang tải……',
23
+ loadMoreText: 'Ôi, đã đến cuối rồi!'
24
+ },
25
+ pagination: {
26
+ prev: 'Trang trước',
27
+ next: 'Trang sau'
28
+ },
29
+ range: {
30
+ rangeText: 'Không nằm trong phạm vi này'
31
+ },
32
+ calendaritem: {
33
+ weekdays: [
34
+ 'CN',
35
+ 'T2',
36
+ 'T3',
37
+ 'T4',
38
+ 'T5',
39
+ 'T6',
40
+ 'T7'
41
+ ],
42
+ end: 'Kết thúc',
43
+ start: 'Bắt đầu',
44
+ confirm: 'Xác nhận',
45
+ title: 'Chọn lịch',
46
+ monthTitle: function(year, month) {
47
+ return "Th\xe1ng ".concat(month, " Năm ").concat(year);
48
+ },
49
+ today: 'Hôm nay',
50
+ loadPreviousMonth: 'Tải dữ liệu của tháng trước',
51
+ noEarlierMonth: 'Không có tháng nào sớm hơn'
52
+ },
53
+ shortpassword: {
54
+ title: 'Vui lòng nhập mật khẩu',
55
+ description: 'Bạn đã sử dụng tài sản ảo, vui lòng xác minh',
56
+ tips: 'Quên mật khẩu'
57
+ },
58
+ uploader: {
59
+ list: 'Tải lên tập tin',
60
+ ready: 'Chuẩn bị hoàn thành',
61
+ readyUpload: 'Chuẩn bị tải lên',
62
+ waitingUpload: 'Đang đợi tải lên',
63
+ uploading: 'Đang tải lên...',
64
+ success: 'Tải lên thành công',
65
+ error: 'Tải lên thất bại',
66
+ deleteWord: 'Người dùng đã chặn xóa!'
67
+ },
68
+ countdown: {
69
+ day: 'Ngày',
70
+ hour: 'Giờ',
71
+ minute: 'Phút',
72
+ second: 'Giây'
73
+ },
74
+ address: {
75
+ selectRegion: 'Vui lòng chọn khu vực',
76
+ deliveryTo: 'Giao đến',
77
+ hotCity: 'Thành phố nóng',
78
+ chooseAnotherAddress: 'Chọn địa chỉ khác',
79
+ selectProvince: 'Chọn Tỉnh/Thành phố'
80
+ },
81
+ signature: {
82
+ reSign: 'Ký lại',
83
+ unsupported: 'Xin lỗi, trình duyệt hiện tại không hỗ trợ Canvas, không thể dùng tính năng này!'
84
+ },
85
+ ecard: {
86
+ chooseText: 'Chọn mệnh giá thẻ',
87
+ otherValueText: 'Mệnh giá khác',
88
+ placeholder: 'Nhập số nguyên 1-5000'
89
+ },
90
+ timeselect: {
91
+ pickupTime: 'Thời gian lấy hàng'
92
+ },
93
+ sku: {
94
+ buyNow: 'Mua ngay',
95
+ buyNumber: 'Số lượng mua',
96
+ addToCard: 'Thêm vào giỏ hàng'
97
+ },
98
+ skuheader: {
99
+ skuId: 'Mã sản phẩm'
100
+ },
101
+ addresslist: {
102
+ addAddress: 'Tạo địa chỉ '
103
+ },
104
+ comment: {
105
+ complaintsText: 'Tôi muốn khiếu nại',
106
+ additionalReview: function(day) {
107
+ return "Đ\xe1nh gi\xe1 th\xeam sau ".concat(day, " ng\xe0y");
108
+ },
109
+ additionalImages: function(length) {
110
+ return "".concat(length, " ảnh đ\xe1nh gi\xe1 th\xeam");
111
+ }
112
+ },
113
+ searchbar: {
114
+ basePlaceholder: 'Lên JD tìm sản phẩm tốt',
115
+ text: 'Văn bản',
116
+ test: 'Kiểm tra',
117
+ title1: 'Cách dùng cơ bản',
118
+ title2: 'Hình dạng và độ dài tối đa ô tìm kiếm',
119
+ title3: 'Cài đặt nền trong và ngoài ô tìm kiếm',
120
+ title4: 'Cài đặt văn bản ô tìm kiếm',
121
+ title5: 'Tùy chỉnh biểu tượng',
122
+ title6: 'Lắng nghe thay đổi dữ liệu'
123
+ },
124
+ audio: {
125
+ back: 'Quay lại',
126
+ forward: 'Chuyển nhanh',
127
+ pause: 'Tạm dừng',
128
+ start: 'Bắt đầu',
129
+ mute: 'Tắt âm',
130
+ tips: 'Sự kiện onPlayEnd chỉ xảy ra khi loop=false'
131
+ },
132
+ avatarCropper: {
133
+ rotate: 'Xoay',
134
+ selectImage: 'Chọn ảnh'
135
+ },
136
+ datepicker: {
137
+ year: 'Năm',
138
+ month: 'Tháng',
139
+ day: 'Ngày',
140
+ hour: 'Giờ',
141
+ min: 'Phút',
142
+ seconds: 'Giây'
143
+ },
144
+ pullToRefresh: {
145
+ pullingText: 'Kéo xuống để làm mới',
146
+ canReleaseText: 'Thả để làm mới',
147
+ refreshingText: 'Đang tải...',
148
+ completeText: 'Làm mới thành công'
149
+ },
150
+ tour: {
151
+ prevStepText: 'Bước trước',
152
+ completeText: 'Hoàn thành',
153
+ nextStepText: 'Bước tiếp theo'
154
+ },
155
+ watermark: {
156
+ errorCanvasTips: 'Môi trường hiện tại không hỗ trợ Canvas'
157
+ },
158
+ mask: 'Lớp phủ'
159
+ };
160
+ export default viVN;
@@ -231,8 +231,8 @@ export var AvatarCropper = function(props) {
231
231
  }));
232
232
  resetScale(scale);
233
233
  };
234
- var inputImageChange = /*#__PURE__*/ function() {
235
- var _ref = _async_to_generator(function(event) {
234
+ var inputImageChange = function(event) {
235
+ return _async_to_generator(function() {
236
236
  var $el, files, base64, image;
237
237
  return _ts_generator(this, function(_state) {
238
238
  switch(_state.label){
@@ -261,11 +261,8 @@ export var AvatarCropper = function(props) {
261
261
  ];
262
262
  }
263
263
  });
264
- });
265
- return function inputImageChange(event) {
266
- return _ref.apply(this, arguments);
267
- };
268
- }();
264
+ })();
265
+ };
269
266
  var resetScale = function(scale) {
270
267
  setState(_object_spread_props(_object_spread({}, state), {
271
268
  moveX: 0,
@@ -173,8 +173,8 @@ export var Cascader = /*#__PURE__*/ forwardRef(function(props, ref) {
173
173
  outerOptions
174
174
  ]);
175
175
  useEffect(function() {
176
- var load = /*#__PURE__*/ function() {
177
- var _ref = _async_to_generator(function() {
176
+ var load = function() {
177
+ return _async_to_generator(function() {
178
178
  var parent, error;
179
179
  return _ts_generator(this, function(_state) {
180
180
  switch(_state.label){
@@ -192,8 +192,8 @@ export var Cascader = /*#__PURE__*/ forwardRef(function(props, ref) {
192
192
  ]);
193
193
  return [
194
194
  4,
195
- innerValue.reduce(/*#__PURE__*/ function() {
196
- var _ref = _async_to_generator(function(promise, val, key) {
195
+ innerValue.reduce(function(promise, val, key) {
196
+ return _async_to_generator(function() {
197
197
  var pane, parent, node;
198
198
  return _ts_generator(this, function(_state) {
199
199
  switch(_state.label){
@@ -233,11 +233,8 @@ export var Cascader = /*#__PURE__*/ forwardRef(function(props, ref) {
233
233
  ];
234
234
  }
235
235
  });
236
- });
237
- return function(promise, val, key) {
238
- return _ref.apply(this, arguments);
239
- };
240
- }(), Promise.resolve(parent))
236
+ })();
237
+ }, Promise.resolve(parent))
241
238
  ];
242
239
  case 2:
243
240
  _state.sent();
@@ -260,17 +257,14 @@ export var Cascader = /*#__PURE__*/ forwardRef(function(props, ref) {
260
257
  ];
261
258
  }
262
259
  });
263
- });
264
- return function load() {
265
- return _ref.apply(this, arguments);
266
- };
267
- }();
260
+ })();
261
+ };
268
262
  if (lazy) load();
269
263
  }, [
270
264
  lazy
271
265
  ]);
272
- var chooseItem = /*#__PURE__*/ function() {
273
- var _ref = _async_to_generator(function(pane, levelIndex) {
266
+ var chooseItem = function(pane, levelIndex) {
267
+ return _async_to_generator(function() {
274
268
  var nextValue, nextPathNodes, _props_onPathChange, asyncOptions;
275
269
  return _ts_generator(this, function(_state) {
276
270
  switch(_state.label){
@@ -324,11 +318,8 @@ export var Cascader = /*#__PURE__*/ forwardRef(function(props, ref) {
324
318
  ];
325
319
  }
326
320
  });
327
- });
328
- return function chooseItem(pane, levelIndex) {
329
- return _ref.apply(this, arguments);
330
- };
331
- }();
321
+ })();
322
+ };
332
323
  var renderCascaderItem = function(item, levelIndex) {
333
324
  var _item_pane;
334
325
  return (_item_pane = item.pane) === null || _item_pane === void 0 ? void 0 : _item_pane.map(function(pane, index) {
@@ -55,8 +55,8 @@ export var CollapseItem = function(props) {
55
55
  var _useState = _sliced_to_array(useState(0), 2), tran = _useState[0], setTran = _useState[1];
56
56
  var _useRefState = _sliced_to_array(useRefState(0), 2), currentHeight = _useRefState[0], setCurrentHeight = _useRefState[1];
57
57
  var _useState1 = _sliced_to_array(useState(0), 2), wrapperHeight = _useState1[0], setWrapperHeight = _useState1[1];
58
- var updateRectHeight = /*#__PURE__*/ function() {
59
- var _ref = _async_to_generator(function() {
58
+ var updateRectHeight = function() {
59
+ return _async_to_generator(function() {
60
60
  var height;
61
61
  return _ts_generator(this, function(_state) {
62
62
  height = contentRef.current.offsetHeight;
@@ -69,11 +69,8 @@ export var CollapseItem = function(props) {
69
69
  2
70
70
  ];
71
71
  });
72
- });
73
- return function updateRectHeight() {
74
- return _ref.apply(this, arguments);
75
- };
76
- }();
72
+ })();
73
+ };
77
74
  useEffect(function() {
78
75
  updateRectHeight();
79
76
  }, [
@@ -63,8 +63,7 @@ var InternalCountDown = function(props, ref) {
63
63
  stateRef.current.handleEndTime = Date.now() + Number(remainingTime);
64
64
  } else {
65
65
  stateRef.current.handleEndTime = endTime;
66
- stateRef.current.diffTime = Date.now() - getTimeStamp(startTime) // 时间差
67
- ;
66
+ stateRef.current.diffTime = Date.now() - getTimeStamp(startTime); // 时间差
68
67
  }
69
68
  if (!stateRef.current.counting) stateRef.current.counting = true;
70
69
  tick();
@@ -60,8 +60,8 @@ var BaseDialog = function(props, ref) {
60
60
  if (!(beforeCancel === null || beforeCancel === void 0 ? void 0 : beforeCancel())) return;
61
61
  onCancel();
62
62
  };
63
- var handleOk = /*#__PURE__*/ function() {
64
- var _ref = _async_to_generator(function(e) {
63
+ var handleOk = function(e) {
64
+ return _async_to_generator(function() {
65
65
  var e1;
66
66
  return _ts_generator(this, function(_state) {
67
67
  switch(_state.label){
@@ -101,11 +101,8 @@ var BaseDialog = function(props, ref) {
101
101
  ];
102
102
  }
103
103
  });
104
- });
105
- return function handleOk(e) {
106
- return _ref.apply(this, arguments);
107
- };
108
- }();
104
+ })();
105
+ };
109
106
  var btnClass = hideCancelButton || hideConfirmButton ? "".concat(classPrefix, "-footer-block") : '';
110
107
  var renderCancelOfVertical = function() {
111
108
  return !hideCancelButton && /*#__PURE__*/ React.createElement("div", {
@@ -1,4 +1,3 @@
1
- import React from "react";
2
1
  import { Form } from "./form";
3
2
  import { FormItem } from "../formitem/formitem";
4
3
  import { useForm, useWatch } from "./useform";