assui 3.1.75 → 3.1.76
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/rc-echart/core.js
CHANGED
|
@@ -5,6 +5,7 @@ import useMount from "ahooks/es/useMount";
|
|
|
5
5
|
import useUpdateEffect from "ahooks/es/useUpdateEffect";
|
|
6
6
|
import classNames from 'classnames';
|
|
7
7
|
import ResizeObserver from 'resize-observer-polyfill';
|
|
8
|
+
var initEmptyObject = {};
|
|
8
9
|
var ReactEchartCore = function ReactEchartCore(props) {
|
|
9
10
|
var _a = props.className,
|
|
10
11
|
className = _a === void 0 ? '' : _a,
|
|
@@ -15,9 +16,9 @@ var ReactEchartCore = function ReactEchartCore(props) {
|
|
|
15
16
|
_c = props.lazyUpdate,
|
|
16
17
|
lazyUpdate = _c === void 0 ? false : _c,
|
|
17
18
|
_d = props.onEvents,
|
|
18
|
-
onEvents = _d === void 0 ?
|
|
19
|
+
onEvents = _d === void 0 ? initEmptyObject : _d,
|
|
19
20
|
_e = props.opts,
|
|
20
|
-
opts = _e === void 0 ?
|
|
21
|
+
opts = _e === void 0 ? initEmptyObject : _e,
|
|
21
22
|
theme = props.theme;
|
|
22
23
|
var chartDomRef = useRef();
|
|
23
24
|
var chartRef = useRef();
|
|
@@ -59,6 +60,7 @@ var ReactEchartCore = function ReactEchartCore(props) {
|
|
|
59
60
|
// need reBuild
|
|
60
61
|
useUpdateEffect(function () {
|
|
61
62
|
dispose();
|
|
63
|
+
initEcharts();
|
|
62
64
|
renderEchartDom();
|
|
63
65
|
bindEvents();
|
|
64
66
|
}, [theme, opts]);
|
package/es/rc-qrcode/index.js
CHANGED
|
@@ -14,11 +14,12 @@ import * as React from 'react';
|
|
|
14
14
|
import QRCode from 'qrcode';
|
|
15
15
|
import useMount from "ahooks/es/useMount";
|
|
16
16
|
import useQrcode from './useQrcode';
|
|
17
|
+
var initEmptyObject = {};
|
|
17
18
|
var RcQrcode = function RcQrcode(props) {
|
|
18
19
|
var _a = props.value,
|
|
19
20
|
value = _a === void 0 ? '' : _a,
|
|
20
21
|
_b = props.options,
|
|
21
|
-
options = _b === void 0 ?
|
|
22
|
+
options = _b === void 0 ? initEmptyObject : _b,
|
|
22
23
|
getCanvasInstance = props.getCanvasInstance;
|
|
23
24
|
var domElRef = React.useRef(null);
|
|
24
25
|
var defaultOptions = {
|
|
@@ -181,6 +181,9 @@ var getLocalImgURL = function getLocalImgURL(file) {
|
|
|
181
181
|
var imgURL = URL.createObjectURL(file);
|
|
182
182
|
return imgURL;
|
|
183
183
|
};
|
|
184
|
+
var initBeforeUpload = function initBeforeUpload() {
|
|
185
|
+
return true;
|
|
186
|
+
};
|
|
184
187
|
var SingleImgUpload = function SingleImgUpload(props) {
|
|
185
188
|
var className = props.className,
|
|
186
189
|
wrapperClassName = props.wrapperClassName,
|
|
@@ -192,9 +195,7 @@ var SingleImgUpload = function SingleImgUpload(props) {
|
|
|
192
195
|
onSuccess = props.onSuccess,
|
|
193
196
|
onCancel = props.onCancel,
|
|
194
197
|
_a = props.beforeUpload,
|
|
195
|
-
beforeUpload = _a === void 0 ?
|
|
196
|
-
return true;
|
|
197
|
-
} : _a,
|
|
198
|
+
beforeUpload = _a === void 0 ? initBeforeUpload : _a,
|
|
198
199
|
onError = props.onError,
|
|
199
200
|
disabled = props.disabled,
|
|
200
201
|
restProps = __rest(props, ["className", "wrapperClassName", "children", "value", "onStart", "onDeleteUpload", "onFormatResData", "onSuccess", "onCancel", "beforeUpload", "onError", "disabled"]);
|
package/lib/rc-echart/core.js
CHANGED
|
@@ -48,6 +48,7 @@ var useMount_1 = __importDefault(require("ahooks/lib/useMount"));
|
|
|
48
48
|
var useUpdateEffect_1 = __importDefault(require("ahooks/lib/useUpdateEffect"));
|
|
49
49
|
var classnames_1 = __importDefault(require("classnames"));
|
|
50
50
|
var resize_observer_polyfill_1 = __importDefault(require("resize-observer-polyfill"));
|
|
51
|
+
var initEmptyObject = {};
|
|
51
52
|
var ReactEchartCore = function ReactEchartCore(props) {
|
|
52
53
|
var _a = props.className,
|
|
53
54
|
className = _a === void 0 ? '' : _a,
|
|
@@ -58,9 +59,9 @@ var ReactEchartCore = function ReactEchartCore(props) {
|
|
|
58
59
|
_c = props.lazyUpdate,
|
|
59
60
|
lazyUpdate = _c === void 0 ? false : _c,
|
|
60
61
|
_d = props.onEvents,
|
|
61
|
-
onEvents = _d === void 0 ?
|
|
62
|
+
onEvents = _d === void 0 ? initEmptyObject : _d,
|
|
62
63
|
_e = props.opts,
|
|
63
|
-
opts = _e === void 0 ?
|
|
64
|
+
opts = _e === void 0 ? initEmptyObject : _e,
|
|
64
65
|
theme = props.theme;
|
|
65
66
|
var chartDomRef = (0, react_1.useRef)();
|
|
66
67
|
var chartRef = (0, react_1.useRef)();
|
|
@@ -102,6 +103,7 @@ var ReactEchartCore = function ReactEchartCore(props) {
|
|
|
102
103
|
// need reBuild
|
|
103
104
|
(0, useUpdateEffect_1["default"])(function () {
|
|
104
105
|
dispose();
|
|
106
|
+
initEcharts();
|
|
105
107
|
renderEchartDom();
|
|
106
108
|
bindEvents();
|
|
107
109
|
}, [theme, opts]);
|
package/lib/rc-qrcode/index.js
CHANGED
|
@@ -59,11 +59,12 @@ var qrcode_1 = __importDefault(require("qrcode"));
|
|
|
59
59
|
var useMount_1 = __importDefault(require("ahooks/lib/useMount"));
|
|
60
60
|
var useQrcode_1 = __importDefault(require("./useQrcode"));
|
|
61
61
|
exports.useQrcode = useQrcode_1["default"];
|
|
62
|
+
var initEmptyObject = {};
|
|
62
63
|
var RcQrcode = function RcQrcode(props) {
|
|
63
64
|
var _a = props.value,
|
|
64
65
|
value = _a === void 0 ? '' : _a,
|
|
65
66
|
_b = props.options,
|
|
66
|
-
options = _b === void 0 ?
|
|
67
|
+
options = _b === void 0 ? initEmptyObject : _b,
|
|
67
68
|
getCanvasInstance = props.getCanvasInstance;
|
|
68
69
|
var domElRef = React.useRef(null);
|
|
69
70
|
var defaultOptions = {
|
|
@@ -224,6 +224,9 @@ var getLocalImgURL = function getLocalImgURL(file) {
|
|
|
224
224
|
var imgURL = URL.createObjectURL(file);
|
|
225
225
|
return imgURL;
|
|
226
226
|
};
|
|
227
|
+
var initBeforeUpload = function initBeforeUpload() {
|
|
228
|
+
return true;
|
|
229
|
+
};
|
|
227
230
|
var SingleImgUpload = function SingleImgUpload(props) {
|
|
228
231
|
var className = props.className,
|
|
229
232
|
wrapperClassName = props.wrapperClassName,
|
|
@@ -235,9 +238,7 @@ var SingleImgUpload = function SingleImgUpload(props) {
|
|
|
235
238
|
onSuccess = props.onSuccess,
|
|
236
239
|
onCancel = props.onCancel,
|
|
237
240
|
_a = props.beforeUpload,
|
|
238
|
-
beforeUpload = _a === void 0 ?
|
|
239
|
-
return true;
|
|
240
|
-
} : _a,
|
|
241
|
+
beforeUpload = _a === void 0 ? initBeforeUpload : _a,
|
|
241
242
|
onError = props.onError,
|
|
242
243
|
disabled = props.disabled,
|
|
243
244
|
restProps = __rest(props, ["className", "wrapperClassName", "children", "value", "onStart", "onDeleteUpload", "onFormatResData", "onSuccess", "onCancel", "beforeUpload", "onError", "disabled"]);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "assui",
|
|
3
|
-
"version": "3.1.
|
|
3
|
+
"version": "3.1.76",
|
|
4
4
|
"description": "react ui library",
|
|
5
5
|
"author": "jason <usochen@gmail.com>",
|
|
6
6
|
"main": "./lib/index.js",
|
|
@@ -80,5 +80,5 @@
|
|
|
80
80
|
"node": ">=10.0.0"
|
|
81
81
|
},
|
|
82
82
|
"license": "MIT",
|
|
83
|
-
"gitHead": "
|
|
83
|
+
"gitHead": "25f97cf662b09a287d612a4ab8f68d09e1438617"
|
|
84
84
|
}
|