@cloudtower/eagle 0.22.34 → 0.22.37
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/dist/UIKitProvider/index.d.ts +4 -0
- package/dist/components/Button/index.d.ts +1 -1
- package/dist/components/TableForm/AddRowButton.d.ts +4 -0
- package/dist/components/TableForm/Columns/AffixColumn.d.ts +4 -1
- package/dist/components/TableForm/Columns/CheckboxColumn.d.ts +3 -1
- package/dist/components/TableForm/Columns/InputColumn.d.ts +8 -2
- package/dist/components/TableForm/Columns/index.d.ts +27 -7
- package/dist/components/TableForm/TableFormBodyRows.d.ts +4 -0
- package/dist/components/TableForm/__test__/utils.spec.d.ts +1 -0
- package/dist/components/TableForm/index.d.ts +1 -15
- package/dist/components/TableForm/style.d.ts +13 -5
- package/dist/components/TableForm/types.d.ts +80 -13
- package/dist/components/TableForm/utils.d.ts +3 -0
- package/dist/components/index.d.ts +1 -0
- package/dist/components/message-group/__test__/message-group.test.d.ts +1 -0
- package/dist/components/message-group/index.d.ts +23 -0
- package/dist/esm/index.js +1714 -663
- package/dist/esm/stats1.html +1 -1
- package/dist/index.d.ts +2 -1
- package/dist/spec/base.d.ts +8 -1
- package/dist/style.css +1537 -1342
- package/dist/umd/index.js +1713 -662
- package/dist/umd/stats1.html +1 -1
- package/package.json +7 -5
package/dist/esm/index.js
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import { Alert as Alert$1, Badge as Badge$1, Button as Button$1, Tooltip as Tooltip$1, Checkbox as Checkbox$1, DatePicker, Select as Select$1, InputNumber as InputNumber$1, Input as Input$1, TimePicker as TimePicker$1, Modal as Modal$1, Steps as Steps$1, Dropdown, Menu, Progress as Progress$1, Radio as Radio$1, Switch as Switch$1, Table as Table$1, Tag, Row, Col, Tree, Divider, Skeleton,
|
|
1
|
+
import { Alert as Alert$1, Badge as Badge$1, Button as Button$1, Tooltip as Tooltip$1, Checkbox as Checkbox$1, DatePicker, Select as Select$1, InputNumber as InputNumber$1, Input as Input$1, TimePicker as TimePicker$1, message, Modal as Modal$1, Steps as Steps$1, Dropdown, Menu, Progress as Progress$1, Radio as Radio$1, Switch as Switch$1, Table as Table$1, Space, Form, List, Tag, Row, Col, Tree, Divider, Skeleton, Layout, AutoComplete, Popover, Timeline, Typography, Cascader, Upload } from 'antd';
|
|
2
2
|
export { Col, Row } from 'antd';
|
|
3
|
-
import
|
|
4
|
-
import React, { useState, useMemo, useRef, useCallback, useEffect, Fragment, useLayoutEffect, createContext, useContext } from 'react';
|
|
3
|
+
import React, { useState, useMemo, useRef, useCallback, useEffect, Fragment, useLayoutEffect, createContext, memo, useImperativeHandle, useContext } from 'react';
|
|
5
4
|
import cs from 'classnames';
|
|
6
5
|
import _, { sortBy, uniqBy } from 'lodash';
|
|
7
6
|
import { parrotI18n } from '@cloudtower/parrot';
|
|
@@ -11,9 +10,11 @@ import { styled } from '@linaria/react';
|
|
|
11
10
|
import moment from 'moment';
|
|
12
11
|
import { findDOMNode } from 'react-dom';
|
|
13
12
|
import { isElement } from 'react-is';
|
|
14
|
-
import { CloseCircleFilled, CheckOutlined, SearchOutlined } from '@ant-design/icons';
|
|
13
|
+
import { CloseCircleFilled, CheckOutlined, SearchOutlined, PlusOutlined, EyeOutlined, EyeInvisibleOutlined } from '@ant-design/icons';
|
|
15
14
|
import { combineReducers, createStore } from 'redux';
|
|
16
15
|
import { createDispatchHook, createSelectorHook, Provider } from 'react-redux';
|
|
16
|
+
import { HandlePoint816SecondaryIcon, HandlePoint816BlueIcon, XmarkRemove16SecondaryIcon, XmarkRemove16RegularRedIcon } from '@cloudtower/icons-react';
|
|
17
|
+
import { DragDropContext, Droppable, Draggable } from 'react-beautiful-dnd';
|
|
17
18
|
import TimeZones from 'timezones.json';
|
|
18
19
|
import { withTranslation } from 'react-i18next';
|
|
19
20
|
import dayjs from 'dayjs';
|
|
@@ -236,30 +237,30 @@ function getAlertIcon(type) {
|
|
|
236
237
|
}
|
|
237
238
|
}
|
|
238
239
|
|
|
239
|
-
var __defProp$
|
|
240
|
-
var __getOwnPropSymbols$
|
|
241
|
-
var __hasOwnProp$
|
|
242
|
-
var __propIsEnum$
|
|
243
|
-
var __defNormalProp$
|
|
244
|
-
var __spreadValues$
|
|
240
|
+
var __defProp$E = Object.defineProperty;
|
|
241
|
+
var __getOwnPropSymbols$F = Object.getOwnPropertySymbols;
|
|
242
|
+
var __hasOwnProp$F = Object.prototype.hasOwnProperty;
|
|
243
|
+
var __propIsEnum$F = Object.prototype.propertyIsEnumerable;
|
|
244
|
+
var __defNormalProp$E = (obj, key, value) => key in obj ? __defProp$E(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
245
|
+
var __spreadValues$E = (a, b) => {
|
|
245
246
|
for (var prop in b || (b = {}))
|
|
246
|
-
if (__hasOwnProp$
|
|
247
|
-
__defNormalProp$
|
|
248
|
-
if (__getOwnPropSymbols$
|
|
249
|
-
for (var prop of __getOwnPropSymbols$
|
|
250
|
-
if (__propIsEnum$
|
|
251
|
-
__defNormalProp$
|
|
247
|
+
if (__hasOwnProp$F.call(b, prop))
|
|
248
|
+
__defNormalProp$E(a, prop, b[prop]);
|
|
249
|
+
if (__getOwnPropSymbols$F)
|
|
250
|
+
for (var prop of __getOwnPropSymbols$F(b)) {
|
|
251
|
+
if (__propIsEnum$F.call(b, prop))
|
|
252
|
+
__defNormalProp$E(a, prop, b[prop]);
|
|
252
253
|
}
|
|
253
254
|
return a;
|
|
254
255
|
};
|
|
255
|
-
var __objRest$
|
|
256
|
+
var __objRest$s = (source, exclude) => {
|
|
256
257
|
var target = {};
|
|
257
258
|
for (var prop in source)
|
|
258
|
-
if (__hasOwnProp$
|
|
259
|
+
if (__hasOwnProp$F.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
259
260
|
target[prop] = source[prop];
|
|
260
|
-
if (source != null && __getOwnPropSymbols$
|
|
261
|
-
for (var prop of __getOwnPropSymbols$
|
|
262
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
261
|
+
if (source != null && __getOwnPropSymbols$F)
|
|
262
|
+
for (var prop of __getOwnPropSymbols$F(source)) {
|
|
263
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$F.call(source, prop))
|
|
263
264
|
target[prop] = source[prop];
|
|
264
265
|
}
|
|
265
266
|
return target;
|
|
@@ -277,7 +278,7 @@ const BaseIcon = React.forwardRef(
|
|
|
277
278
|
prefixNode,
|
|
278
279
|
suffixIconSrc: SuffixSrc,
|
|
279
280
|
src: Src
|
|
280
|
-
} = _a, HTMLSpanElementProps = __objRest$
|
|
281
|
+
} = _a, HTMLSpanElementProps = __objRest$s(_a, [
|
|
281
282
|
"alt",
|
|
282
283
|
"className",
|
|
283
284
|
"width",
|
|
@@ -291,10 +292,10 @@ const BaseIcon = React.forwardRef(
|
|
|
291
292
|
]);
|
|
292
293
|
return /* @__PURE__ */ React.createElement(
|
|
293
294
|
"span",
|
|
294
|
-
__spreadValues$
|
|
295
|
+
__spreadValues$E({
|
|
295
296
|
ref,
|
|
296
297
|
className,
|
|
297
|
-
style: _.pickBy(__spreadValues$
|
|
298
|
+
style: _.pickBy(__spreadValues$E({ cursor }, style))
|
|
298
299
|
}, HTMLSpanElementProps),
|
|
299
300
|
prefixNode,
|
|
300
301
|
/* @__PURE__ */ React.createElement("span", { className: "icon-inner" }, typeof Src === "string" ? /* @__PURE__ */ React.createElement("img", { alt, src: Src, width, height }) : /* @__PURE__ */ React.createElement(Src, { width, height })),
|
|
@@ -304,31 +305,31 @@ const BaseIcon = React.forwardRef(
|
|
|
304
305
|
}
|
|
305
306
|
);
|
|
306
307
|
|
|
307
|
-
var __defProp$
|
|
308
|
-
var __defProps$
|
|
309
|
-
var __getOwnPropDescs$
|
|
310
|
-
var __getOwnPropSymbols$
|
|
311
|
-
var __hasOwnProp$
|
|
312
|
-
var __propIsEnum$
|
|
313
|
-
var __defNormalProp$
|
|
308
|
+
var __defProp$D = Object.defineProperty;
|
|
309
|
+
var __defProps$v = Object.defineProperties;
|
|
310
|
+
var __getOwnPropDescs$v = Object.getOwnPropertyDescriptors;
|
|
311
|
+
var __getOwnPropSymbols$E = Object.getOwnPropertySymbols;
|
|
312
|
+
var __hasOwnProp$E = Object.prototype.hasOwnProperty;
|
|
313
|
+
var __propIsEnum$E = Object.prototype.propertyIsEnumerable;
|
|
314
|
+
var __defNormalProp$D = (obj, key, value) => key in obj ? __defProp$D(obj, key, {
|
|
314
315
|
enumerable: true,
|
|
315
316
|
configurable: true,
|
|
316
317
|
writable: true,
|
|
317
318
|
value
|
|
318
319
|
}) : obj[key] = value;
|
|
319
|
-
var __spreadValues$
|
|
320
|
-
for (var prop in b || (b = {})) if (__hasOwnProp$
|
|
321
|
-
if (__getOwnPropSymbols$
|
|
322
|
-
if (__propIsEnum$
|
|
320
|
+
var __spreadValues$D = (a, b) => {
|
|
321
|
+
for (var prop in b || (b = {})) if (__hasOwnProp$E.call(b, prop)) __defNormalProp$D(a, prop, b[prop]);
|
|
322
|
+
if (__getOwnPropSymbols$E) for (var prop of __getOwnPropSymbols$E(b)) {
|
|
323
|
+
if (__propIsEnum$E.call(b, prop)) __defNormalProp$D(a, prop, b[prop]);
|
|
323
324
|
}
|
|
324
325
|
return a;
|
|
325
326
|
};
|
|
326
|
-
var __spreadProps$
|
|
327
|
-
var __objRest$
|
|
327
|
+
var __spreadProps$v = (a, b) => __defProps$v(a, __getOwnPropDescs$v(b));
|
|
328
|
+
var __objRest$r = (source, exclude) => {
|
|
328
329
|
var target = {};
|
|
329
|
-
for (var prop in source) if (__hasOwnProp$
|
|
330
|
-
if (source != null && __getOwnPropSymbols$
|
|
331
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
330
|
+
for (var prop in source) if (__hasOwnProp$E.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
|
|
331
|
+
if (source != null && __getOwnPropSymbols$E) for (var prop of __getOwnPropSymbols$E(source)) {
|
|
332
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$E.call(source, prop)) target[prop] = source[prop];
|
|
332
333
|
}
|
|
333
334
|
return target;
|
|
334
335
|
};
|
|
@@ -352,7 +353,7 @@ const Icon = React.forwardRef((props, ref) => {
|
|
|
352
353
|
prefix,
|
|
353
354
|
suffix
|
|
354
355
|
} = _a,
|
|
355
|
-
restProps = __objRest$
|
|
356
|
+
restProps = __objRest$r(_a, ["src", "hoverSrc", "active", "activeSrc", "onMouseEnter", "onMouseLeave", "onMouseMove", "className", "iconWidth", "iconHeight", "cursor", "style", "isRotate", "prefix", "suffix"]);
|
|
356
357
|
const [hover, setHover] = useState(false);
|
|
357
358
|
const _src = useMemo(() => {
|
|
358
359
|
if (active && activeSrc) {
|
|
@@ -380,14 +381,14 @@ const Icon = React.forwardRef((props, ref) => {
|
|
|
380
381
|
}
|
|
381
382
|
return src2;
|
|
382
383
|
}, [active, hover, suffix]);
|
|
383
|
-
return /* @__PURE__ */React.createElement(BaseIcon, __spreadProps$
|
|
384
|
+
return /* @__PURE__ */React.createElement(BaseIcon, __spreadProps$v(__spreadValues$D({
|
|
384
385
|
src: _src,
|
|
385
386
|
className: cs(IconWrapper, "icon-wrapper", className, isRotate && "is-rotate"),
|
|
386
387
|
suffixIconSrc,
|
|
387
388
|
height: iconHeight,
|
|
388
389
|
width: iconWidth,
|
|
389
390
|
prefixNode: prefix,
|
|
390
|
-
style: _.pickBy(__spreadValues$
|
|
391
|
+
style: _.pickBy(__spreadValues$D({
|
|
391
392
|
cursor
|
|
392
393
|
}, style))
|
|
393
394
|
}, restProps), {
|
|
@@ -412,33 +413,33 @@ const Icon = React.forwardRef((props, ref) => {
|
|
|
412
413
|
}));
|
|
413
414
|
});
|
|
414
415
|
|
|
415
|
-
var __defProp$
|
|
416
|
-
var __defProps$
|
|
417
|
-
var __getOwnPropDescs$
|
|
418
|
-
var __getOwnPropSymbols$
|
|
419
|
-
var __hasOwnProp$
|
|
420
|
-
var __propIsEnum$
|
|
421
|
-
var __defNormalProp$
|
|
422
|
-
var __spreadValues$
|
|
416
|
+
var __defProp$C = Object.defineProperty;
|
|
417
|
+
var __defProps$u = Object.defineProperties;
|
|
418
|
+
var __getOwnPropDescs$u = Object.getOwnPropertyDescriptors;
|
|
419
|
+
var __getOwnPropSymbols$D = Object.getOwnPropertySymbols;
|
|
420
|
+
var __hasOwnProp$D = Object.prototype.hasOwnProperty;
|
|
421
|
+
var __propIsEnum$D = Object.prototype.propertyIsEnumerable;
|
|
422
|
+
var __defNormalProp$C = (obj, key, value) => key in obj ? __defProp$C(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
423
|
+
var __spreadValues$C = (a, b) => {
|
|
423
424
|
for (var prop in b || (b = {}))
|
|
424
|
-
if (__hasOwnProp$
|
|
425
|
-
__defNormalProp$
|
|
426
|
-
if (__getOwnPropSymbols$
|
|
427
|
-
for (var prop of __getOwnPropSymbols$
|
|
428
|
-
if (__propIsEnum$
|
|
429
|
-
__defNormalProp$
|
|
425
|
+
if (__hasOwnProp$D.call(b, prop))
|
|
426
|
+
__defNormalProp$C(a, prop, b[prop]);
|
|
427
|
+
if (__getOwnPropSymbols$D)
|
|
428
|
+
for (var prop of __getOwnPropSymbols$D(b)) {
|
|
429
|
+
if (__propIsEnum$D.call(b, prop))
|
|
430
|
+
__defNormalProp$C(a, prop, b[prop]);
|
|
430
431
|
}
|
|
431
432
|
return a;
|
|
432
433
|
};
|
|
433
|
-
var __spreadProps$
|
|
434
|
-
var __objRest$
|
|
434
|
+
var __spreadProps$u = (a, b) => __defProps$u(a, __getOwnPropDescs$u(b));
|
|
435
|
+
var __objRest$q = (source, exclude) => {
|
|
435
436
|
var target = {};
|
|
436
437
|
for (var prop in source)
|
|
437
|
-
if (__hasOwnProp$
|
|
438
|
+
if (__hasOwnProp$D.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
438
439
|
target[prop] = source[prop];
|
|
439
|
-
if (source != null && __getOwnPropSymbols$
|
|
440
|
-
for (var prop of __getOwnPropSymbols$
|
|
441
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
440
|
+
if (source != null && __getOwnPropSymbols$D)
|
|
441
|
+
for (var prop of __getOwnPropSymbols$D(source)) {
|
|
442
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$D.call(source, prop))
|
|
442
443
|
target[prop] = source[prop];
|
|
443
444
|
}
|
|
444
445
|
return target;
|
|
@@ -451,7 +452,7 @@ const Alert = (_a) => {
|
|
|
451
452
|
className,
|
|
452
453
|
onClose,
|
|
453
454
|
closeText
|
|
454
|
-
} = _b, props = __objRest$
|
|
455
|
+
} = _b, props = __objRest$q(_b, [
|
|
455
456
|
"type",
|
|
456
457
|
"icon",
|
|
457
458
|
"showIcon",
|
|
@@ -463,7 +464,7 @@ const Alert = (_a) => {
|
|
|
463
464
|
const _type = type === "normal" ? "info" : type;
|
|
464
465
|
return /* @__PURE__ */ React.createElement(
|
|
465
466
|
Alert$1,
|
|
466
|
-
__spreadProps$
|
|
467
|
+
__spreadProps$u(__spreadValues$C({}, props), {
|
|
467
468
|
className: cs(type ? `alert-${type}` : "", className),
|
|
468
469
|
type: _type,
|
|
469
470
|
icon: icon || _icon,
|
|
@@ -484,42 +485,42 @@ const Arch = (props) => {
|
|
|
484
485
|
return /* @__PURE__ */ React.createElement("span", null, text);
|
|
485
486
|
};
|
|
486
487
|
|
|
487
|
-
var __defProp$
|
|
488
|
-
var __defProps$
|
|
489
|
-
var __getOwnPropDescs$
|
|
490
|
-
var __getOwnPropSymbols$
|
|
491
|
-
var __hasOwnProp$
|
|
492
|
-
var __propIsEnum$
|
|
493
|
-
var __defNormalProp$
|
|
494
|
-
var __spreadValues$
|
|
488
|
+
var __defProp$B = Object.defineProperty;
|
|
489
|
+
var __defProps$t = Object.defineProperties;
|
|
490
|
+
var __getOwnPropDescs$t = Object.getOwnPropertyDescriptors;
|
|
491
|
+
var __getOwnPropSymbols$C = Object.getOwnPropertySymbols;
|
|
492
|
+
var __hasOwnProp$C = Object.prototype.hasOwnProperty;
|
|
493
|
+
var __propIsEnum$C = Object.prototype.propertyIsEnumerable;
|
|
494
|
+
var __defNormalProp$B = (obj, key, value) => key in obj ? __defProp$B(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
495
|
+
var __spreadValues$B = (a, b) => {
|
|
495
496
|
for (var prop in b || (b = {}))
|
|
496
|
-
if (__hasOwnProp$
|
|
497
|
-
__defNormalProp$
|
|
498
|
-
if (__getOwnPropSymbols$
|
|
499
|
-
for (var prop of __getOwnPropSymbols$
|
|
500
|
-
if (__propIsEnum$
|
|
501
|
-
__defNormalProp$
|
|
497
|
+
if (__hasOwnProp$C.call(b, prop))
|
|
498
|
+
__defNormalProp$B(a, prop, b[prop]);
|
|
499
|
+
if (__getOwnPropSymbols$C)
|
|
500
|
+
for (var prop of __getOwnPropSymbols$C(b)) {
|
|
501
|
+
if (__propIsEnum$C.call(b, prop))
|
|
502
|
+
__defNormalProp$B(a, prop, b[prop]);
|
|
502
503
|
}
|
|
503
504
|
return a;
|
|
504
505
|
};
|
|
505
|
-
var __spreadProps$
|
|
506
|
-
var __objRest$
|
|
506
|
+
var __spreadProps$t = (a, b) => __defProps$t(a, __getOwnPropDescs$t(b));
|
|
507
|
+
var __objRest$p = (source, exclude) => {
|
|
507
508
|
var target = {};
|
|
508
509
|
for (var prop in source)
|
|
509
|
-
if (__hasOwnProp$
|
|
510
|
+
if (__hasOwnProp$C.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
510
511
|
target[prop] = source[prop];
|
|
511
|
-
if (source != null && __getOwnPropSymbols$
|
|
512
|
-
for (var prop of __getOwnPropSymbols$
|
|
513
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
512
|
+
if (source != null && __getOwnPropSymbols$C)
|
|
513
|
+
for (var prop of __getOwnPropSymbols$C(source)) {
|
|
514
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$C.call(source, prop))
|
|
514
515
|
target[prop] = source[prop];
|
|
515
516
|
}
|
|
516
517
|
return target;
|
|
517
518
|
};
|
|
518
519
|
const Badge = (_a) => {
|
|
519
|
-
var _b = _a, { type = "error", className } = _b, props = __objRest$
|
|
520
|
+
var _b = _a, { type = "error", className } = _b, props = __objRest$p(_b, ["type", "className"]);
|
|
520
521
|
return /* @__PURE__ */ React.createElement(
|
|
521
522
|
Badge$1,
|
|
522
|
-
__spreadProps$
|
|
523
|
+
__spreadProps$t(__spreadValues$B({
|
|
523
524
|
className: cx(`badge-${type}`, className)
|
|
524
525
|
}, props), {
|
|
525
526
|
showZero: false
|
|
@@ -700,28 +701,28 @@ const HoverableElement = (props) => {
|
|
|
700
701
|
return icon != null ? React.cloneElement(icon, { className }) : null;
|
|
701
702
|
};
|
|
702
703
|
|
|
703
|
-
var __defProp$
|
|
704
|
-
var __getOwnPropSymbols$
|
|
705
|
-
var __hasOwnProp$
|
|
706
|
-
var __propIsEnum$
|
|
707
|
-
var __defNormalProp$
|
|
704
|
+
var __defProp$A = Object.defineProperty;
|
|
705
|
+
var __getOwnPropSymbols$B = Object.getOwnPropertySymbols;
|
|
706
|
+
var __hasOwnProp$B = Object.prototype.hasOwnProperty;
|
|
707
|
+
var __propIsEnum$B = Object.prototype.propertyIsEnumerable;
|
|
708
|
+
var __defNormalProp$A = (obj, key, value) => key in obj ? __defProp$A(obj, key, {
|
|
708
709
|
enumerable: true,
|
|
709
710
|
configurable: true,
|
|
710
711
|
writable: true,
|
|
711
712
|
value
|
|
712
713
|
}) : obj[key] = value;
|
|
713
|
-
var __spreadValues$
|
|
714
|
-
for (var prop in b || (b = {})) if (__hasOwnProp$
|
|
715
|
-
if (__getOwnPropSymbols$
|
|
716
|
-
if (__propIsEnum$
|
|
714
|
+
var __spreadValues$A = (a, b) => {
|
|
715
|
+
for (var prop in b || (b = {})) if (__hasOwnProp$B.call(b, prop)) __defNormalProp$A(a, prop, b[prop]);
|
|
716
|
+
if (__getOwnPropSymbols$B) for (var prop of __getOwnPropSymbols$B(b)) {
|
|
717
|
+
if (__propIsEnum$B.call(b, prop)) __defNormalProp$A(a, prop, b[prop]);
|
|
717
718
|
}
|
|
718
719
|
return a;
|
|
719
720
|
};
|
|
720
|
-
var __objRest$
|
|
721
|
+
var __objRest$o = (source, exclude) => {
|
|
721
722
|
var target = {};
|
|
722
|
-
for (var prop in source) if (__hasOwnProp$
|
|
723
|
-
if (source != null && __getOwnPropSymbols$
|
|
724
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
723
|
+
for (var prop in source) if (__hasOwnProp$B.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
|
|
724
|
+
if (source != null && __getOwnPropSymbols$B) for (var prop of __getOwnPropSymbols$B(source)) {
|
|
725
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$B.call(source, prop)) target[prop] = source[prop];
|
|
725
726
|
}
|
|
726
727
|
return target;
|
|
727
728
|
};
|
|
@@ -744,11 +745,11 @@ const Button = React.forwardRef((props, ref) => {
|
|
|
744
745
|
onMouseLeave,
|
|
745
746
|
size = "middle"
|
|
746
747
|
} = _a,
|
|
747
|
-
restProps = __objRest$
|
|
748
|
+
restProps = __objRest$o(_a, ["type", "className", "children", "prefixIcon", "hoverPrefixIcon", "suffixIcon", "hoverSuffixIcon", "onMouseEnter", "onMouseLeave", "size"]);
|
|
748
749
|
const [status, setStatus] = useState("normal");
|
|
749
750
|
const hasIcon = prefixIcon || suffixIcon;
|
|
750
751
|
const hasHoverIcon = hoverPrefixIcon || hoverSuffixIcon;
|
|
751
|
-
return /* @__PURE__ */React.createElement(Button$1, __spreadValues$
|
|
752
|
+
return /* @__PURE__ */React.createElement(Button$1, __spreadValues$A({
|
|
752
753
|
ref,
|
|
753
754
|
className: cs(className, ButtonStyle$1, type === "link" && NoPadding, (prefixIcon || suffixIcon) && "has-icon", size === "large" && Typo.Label.l1_regular_title, size === "middle" && Typo.Label.l2_regular_title, size === "small" && Typo.Label.l3_regular_title, type && `ant-btn-${type}`, !children && children !== 0 && restProps.icon && "ant-btn-icon-only"),
|
|
754
755
|
type: isAntdButtonTypes(type) ? type : void 0,
|
|
@@ -778,33 +779,33 @@ const Button = React.forwardRef((props, ref) => {
|
|
|
778
779
|
}));
|
|
779
780
|
});
|
|
780
781
|
|
|
781
|
-
var __defProp$
|
|
782
|
-
var __defProps$
|
|
783
|
-
var __getOwnPropDescs$
|
|
784
|
-
var __getOwnPropSymbols$
|
|
785
|
-
var __hasOwnProp$
|
|
786
|
-
var __propIsEnum$
|
|
787
|
-
var __defNormalProp$
|
|
788
|
-
var __spreadValues$
|
|
782
|
+
var __defProp$z = Object.defineProperty;
|
|
783
|
+
var __defProps$s = Object.defineProperties;
|
|
784
|
+
var __getOwnPropDescs$s = Object.getOwnPropertyDescriptors;
|
|
785
|
+
var __getOwnPropSymbols$A = Object.getOwnPropertySymbols;
|
|
786
|
+
var __hasOwnProp$A = Object.prototype.hasOwnProperty;
|
|
787
|
+
var __propIsEnum$A = Object.prototype.propertyIsEnumerable;
|
|
788
|
+
var __defNormalProp$z = (obj, key, value) => key in obj ? __defProp$z(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
789
|
+
var __spreadValues$z = (a, b) => {
|
|
789
790
|
for (var prop in b || (b = {}))
|
|
790
|
-
if (__hasOwnProp$
|
|
791
|
-
__defNormalProp$
|
|
792
|
-
if (__getOwnPropSymbols$
|
|
793
|
-
for (var prop of __getOwnPropSymbols$
|
|
794
|
-
if (__propIsEnum$
|
|
795
|
-
__defNormalProp$
|
|
791
|
+
if (__hasOwnProp$A.call(b, prop))
|
|
792
|
+
__defNormalProp$z(a, prop, b[prop]);
|
|
793
|
+
if (__getOwnPropSymbols$A)
|
|
794
|
+
for (var prop of __getOwnPropSymbols$A(b)) {
|
|
795
|
+
if (__propIsEnum$A.call(b, prop))
|
|
796
|
+
__defNormalProp$z(a, prop, b[prop]);
|
|
796
797
|
}
|
|
797
798
|
return a;
|
|
798
799
|
};
|
|
799
|
-
var __spreadProps$
|
|
800
|
-
var __objRest$
|
|
800
|
+
var __spreadProps$s = (a, b) => __defProps$s(a, __getOwnPropDescs$s(b));
|
|
801
|
+
var __objRest$n = (source, exclude) => {
|
|
801
802
|
var target = {};
|
|
802
803
|
for (var prop in source)
|
|
803
|
-
if (__hasOwnProp$
|
|
804
|
+
if (__hasOwnProp$A.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
804
805
|
target[prop] = source[prop];
|
|
805
|
-
if (source != null && __getOwnPropSymbols$
|
|
806
|
-
for (var prop of __getOwnPropSymbols$
|
|
807
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
806
|
+
if (source != null && __getOwnPropSymbols$A)
|
|
807
|
+
for (var prop of __getOwnPropSymbols$A(source)) {
|
|
808
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$A.call(source, prop))
|
|
808
809
|
target[prop] = source[prop];
|
|
809
810
|
}
|
|
810
811
|
return target;
|
|
@@ -816,7 +817,7 @@ const Tooltip = (props) => {
|
|
|
816
817
|
overlayClassName,
|
|
817
818
|
overlayStyle,
|
|
818
819
|
children
|
|
819
|
-
} = _a, restProps = __objRest$
|
|
820
|
+
} = _a, restProps = __objRest$n(_a, [
|
|
820
821
|
"followMouse",
|
|
821
822
|
"overlayClassName",
|
|
822
823
|
"overlayStyle",
|
|
@@ -858,10 +859,10 @@ const Tooltip = (props) => {
|
|
|
858
859
|
}, [followMouse, onmousemove, uniqueContainerClass]);
|
|
859
860
|
return /* @__PURE__ */ React.createElement(
|
|
860
861
|
Tooltip$1,
|
|
861
|
-
__spreadProps$
|
|
862
|
+
__spreadProps$s(__spreadValues$z({}, restProps), {
|
|
862
863
|
overlayClassName: followMouse ? cs(overlayClassName, uniquePopupClass) : overlayClassName,
|
|
863
864
|
children: _children,
|
|
864
|
-
overlayStyle: followMouse ? __spreadValues$
|
|
865
|
+
overlayStyle: followMouse ? __spreadValues$z({
|
|
865
866
|
transform: "translate(-50%, -100%)",
|
|
866
867
|
pointerEvents: "none"
|
|
867
868
|
}, overlayStyle) : overlayStyle
|
|
@@ -869,28 +870,28 @@ const Tooltip = (props) => {
|
|
|
869
870
|
);
|
|
870
871
|
};
|
|
871
872
|
|
|
872
|
-
var __defProp$
|
|
873
|
-
var __getOwnPropSymbols$
|
|
874
|
-
var __hasOwnProp$
|
|
875
|
-
var __propIsEnum$
|
|
876
|
-
var __defNormalProp$
|
|
873
|
+
var __defProp$y = Object.defineProperty;
|
|
874
|
+
var __getOwnPropSymbols$z = Object.getOwnPropertySymbols;
|
|
875
|
+
var __hasOwnProp$z = Object.prototype.hasOwnProperty;
|
|
876
|
+
var __propIsEnum$z = Object.prototype.propertyIsEnumerable;
|
|
877
|
+
var __defNormalProp$y = (obj, key, value) => key in obj ? __defProp$y(obj, key, {
|
|
877
878
|
enumerable: true,
|
|
878
879
|
configurable: true,
|
|
879
880
|
writable: true,
|
|
880
881
|
value
|
|
881
882
|
}) : obj[key] = value;
|
|
882
|
-
var __spreadValues$
|
|
883
|
-
for (var prop in b || (b = {})) if (__hasOwnProp$
|
|
884
|
-
if (__getOwnPropSymbols$
|
|
885
|
-
if (__propIsEnum$
|
|
883
|
+
var __spreadValues$y = (a, b) => {
|
|
884
|
+
for (var prop in b || (b = {})) if (__hasOwnProp$z.call(b, prop)) __defNormalProp$y(a, prop, b[prop]);
|
|
885
|
+
if (__getOwnPropSymbols$z) for (var prop of __getOwnPropSymbols$z(b)) {
|
|
886
|
+
if (__propIsEnum$z.call(b, prop)) __defNormalProp$y(a, prop, b[prop]);
|
|
886
887
|
}
|
|
887
888
|
return a;
|
|
888
889
|
};
|
|
889
|
-
var __objRest$
|
|
890
|
+
var __objRest$m = (source, exclude) => {
|
|
890
891
|
var target = {};
|
|
891
|
-
for (var prop in source) if (__hasOwnProp$
|
|
892
|
-
if (source != null && __getOwnPropSymbols$
|
|
893
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
892
|
+
for (var prop in source) if (__hasOwnProp$z.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
|
|
893
|
+
if (source != null && __getOwnPropSymbols$z) for (var prop of __getOwnPropSymbols$z(source)) {
|
|
894
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$z.call(source, prop)) target[prop] = source[prop];
|
|
894
895
|
}
|
|
895
896
|
return target;
|
|
896
897
|
};
|
|
@@ -925,7 +926,7 @@ const ButtonGroup = React.forwardRef((props, ref) => {
|
|
|
925
926
|
hideTitle,
|
|
926
927
|
title
|
|
927
928
|
} = _a,
|
|
928
|
-
buttonPropArgs = __objRest$
|
|
929
|
+
buttonPropArgs = __objRest$m(_a, ["key", "icon", "type", "children", "danger", "ghost", "className", "hideTitle", "title"]);
|
|
929
930
|
if (hideTitle) {
|
|
930
931
|
return /* @__PURE__ */React.createElement(Tooltip, {
|
|
931
932
|
key: key || index,
|
|
@@ -934,7 +935,7 @@ const ButtonGroup = React.forwardRef((props, ref) => {
|
|
|
934
935
|
style: {
|
|
935
936
|
cursor: "not-allowed"
|
|
936
937
|
}
|
|
937
|
-
}, /* @__PURE__ */React.createElement(Button, __spreadValues$
|
|
938
|
+
}, /* @__PURE__ */React.createElement(Button, __spreadValues$y({
|
|
938
939
|
style: {
|
|
939
940
|
pointerEvents: "none"
|
|
940
941
|
},
|
|
@@ -944,7 +945,7 @@ const ButtonGroup = React.forwardRef((props, ref) => {
|
|
|
944
945
|
ghost,
|
|
945
946
|
className: cx(ButtonStyle, className2),
|
|
946
947
|
prefixIcon: icon
|
|
947
|
-
}, buttonPropArgs))) : /* @__PURE__ */React.createElement(Button, __spreadValues$
|
|
948
|
+
}, buttonPropArgs))) : /* @__PURE__ */React.createElement(Button, __spreadValues$y({
|
|
948
949
|
type,
|
|
949
950
|
size,
|
|
950
951
|
danger,
|
|
@@ -953,7 +954,7 @@ const ButtonGroup = React.forwardRef((props, ref) => {
|
|
|
953
954
|
prefixIcon: icon
|
|
954
955
|
}, buttonPropArgs)));
|
|
955
956
|
}
|
|
956
|
-
return /* @__PURE__ */React.createElement(Button, __spreadValues$
|
|
957
|
+
return /* @__PURE__ */React.createElement(Button, __spreadValues$y({
|
|
957
958
|
key: key || index,
|
|
958
959
|
type,
|
|
959
960
|
size,
|
|
@@ -987,31 +988,31 @@ const Byte = ({
|
|
|
987
988
|
return /* @__PURE__ */ React.createElement("span", null, /* @__PURE__ */ React.createElement("span", { className: cx("value", valueClassName) }, value), /* @__PURE__ */ React.createElement("span", { className: cx("unit", unitClassName) }, ` ${unit}`));
|
|
988
989
|
};
|
|
989
990
|
|
|
990
|
-
var __defProp$
|
|
991
|
-
var __defProps$
|
|
992
|
-
var __getOwnPropDescs$
|
|
993
|
-
var __getOwnPropSymbols$
|
|
994
|
-
var __hasOwnProp$
|
|
995
|
-
var __propIsEnum$
|
|
996
|
-
var __defNormalProp$
|
|
991
|
+
var __defProp$x = Object.defineProperty;
|
|
992
|
+
var __defProps$r = Object.defineProperties;
|
|
993
|
+
var __getOwnPropDescs$r = Object.getOwnPropertyDescriptors;
|
|
994
|
+
var __getOwnPropSymbols$y = Object.getOwnPropertySymbols;
|
|
995
|
+
var __hasOwnProp$y = Object.prototype.hasOwnProperty;
|
|
996
|
+
var __propIsEnum$y = Object.prototype.propertyIsEnumerable;
|
|
997
|
+
var __defNormalProp$x = (obj, key, value) => key in obj ? __defProp$x(obj, key, {
|
|
997
998
|
enumerable: true,
|
|
998
999
|
configurable: true,
|
|
999
1000
|
writable: true,
|
|
1000
1001
|
value
|
|
1001
1002
|
}) : obj[key] = value;
|
|
1002
|
-
var __spreadValues$
|
|
1003
|
-
for (var prop in b || (b = {})) if (__hasOwnProp$
|
|
1004
|
-
if (__getOwnPropSymbols$
|
|
1005
|
-
if (__propIsEnum$
|
|
1003
|
+
var __spreadValues$x = (a, b) => {
|
|
1004
|
+
for (var prop in b || (b = {})) if (__hasOwnProp$y.call(b, prop)) __defNormalProp$x(a, prop, b[prop]);
|
|
1005
|
+
if (__getOwnPropSymbols$y) for (var prop of __getOwnPropSymbols$y(b)) {
|
|
1006
|
+
if (__propIsEnum$y.call(b, prop)) __defNormalProp$x(a, prop, b[prop]);
|
|
1006
1007
|
}
|
|
1007
1008
|
return a;
|
|
1008
1009
|
};
|
|
1009
|
-
var __spreadProps$
|
|
1010
|
-
var __objRest$
|
|
1010
|
+
var __spreadProps$r = (a, b) => __defProps$r(a, __getOwnPropDescs$r(b));
|
|
1011
|
+
var __objRest$l = (source, exclude) => {
|
|
1011
1012
|
var target = {};
|
|
1012
|
-
for (var prop in source) if (__hasOwnProp$
|
|
1013
|
-
if (source != null && __getOwnPropSymbols$
|
|
1014
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
1013
|
+
for (var prop in source) if (__hasOwnProp$y.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
|
|
1014
|
+
if (source != null && __getOwnPropSymbols$y) for (var prop of __getOwnPropSymbols$y(source)) {
|
|
1015
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$y.call(source, prop)) target[prop] = source[prop];
|
|
1015
1016
|
}
|
|
1016
1017
|
return target;
|
|
1017
1018
|
};
|
|
@@ -1024,8 +1025,8 @@ const Checkbox = _a => {
|
|
|
1024
1025
|
description,
|
|
1025
1026
|
compact
|
|
1026
1027
|
} = _b,
|
|
1027
|
-
props = __objRest$
|
|
1028
|
-
return /* @__PURE__ */React.createElement(Checkbox$1, __spreadProps$
|
|
1028
|
+
props = __objRest$l(_b, ["className", "children", "description", "compact"]);
|
|
1029
|
+
return /* @__PURE__ */React.createElement(Checkbox$1, __spreadProps$r(__spreadValues$x({}, props), {
|
|
1029
1030
|
"data-test": props["data-test"] || props.value,
|
|
1030
1031
|
className: cs(className, CheckboxStyle, compact && "compact")
|
|
1031
1032
|
}), children ? /* @__PURE__ */React.createElement(React.Fragment, null, /* @__PURE__ */React.createElement("div", {
|
|
@@ -1035,39 +1036,39 @@ const Checkbox = _a => {
|
|
|
1035
1036
|
}, description) : null) : null);
|
|
1036
1037
|
};
|
|
1037
1038
|
|
|
1038
|
-
var __defProp$
|
|
1039
|
-
var __getOwnPropSymbols$
|
|
1040
|
-
var __hasOwnProp$
|
|
1041
|
-
var __propIsEnum$
|
|
1042
|
-
var __defNormalProp$
|
|
1043
|
-
var __spreadValues$
|
|
1039
|
+
var __defProp$w = Object.defineProperty;
|
|
1040
|
+
var __getOwnPropSymbols$x = Object.getOwnPropertySymbols;
|
|
1041
|
+
var __hasOwnProp$x = Object.prototype.hasOwnProperty;
|
|
1042
|
+
var __propIsEnum$x = Object.prototype.propertyIsEnumerable;
|
|
1043
|
+
var __defNormalProp$w = (obj, key, value) => key in obj ? __defProp$w(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
1044
|
+
var __spreadValues$w = (a, b) => {
|
|
1044
1045
|
for (var prop in b || (b = {}))
|
|
1045
|
-
if (__hasOwnProp$
|
|
1046
|
-
__defNormalProp$
|
|
1047
|
-
if (__getOwnPropSymbols$
|
|
1048
|
-
for (var prop of __getOwnPropSymbols$
|
|
1049
|
-
if (__propIsEnum$
|
|
1050
|
-
__defNormalProp$
|
|
1046
|
+
if (__hasOwnProp$x.call(b, prop))
|
|
1047
|
+
__defNormalProp$w(a, prop, b[prop]);
|
|
1048
|
+
if (__getOwnPropSymbols$x)
|
|
1049
|
+
for (var prop of __getOwnPropSymbols$x(b)) {
|
|
1050
|
+
if (__propIsEnum$x.call(b, prop))
|
|
1051
|
+
__defNormalProp$w(a, prop, b[prop]);
|
|
1051
1052
|
}
|
|
1052
1053
|
return a;
|
|
1053
1054
|
};
|
|
1054
|
-
var __objRest$
|
|
1055
|
+
var __objRest$k = (source, exclude) => {
|
|
1055
1056
|
var target = {};
|
|
1056
1057
|
for (var prop in source)
|
|
1057
|
-
if (__hasOwnProp$
|
|
1058
|
+
if (__hasOwnProp$x.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
1058
1059
|
target[prop] = source[prop];
|
|
1059
|
-
if (source != null && __getOwnPropSymbols$
|
|
1060
|
-
for (var prop of __getOwnPropSymbols$
|
|
1061
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
1060
|
+
if (source != null && __getOwnPropSymbols$x)
|
|
1061
|
+
for (var prop of __getOwnPropSymbols$x(source)) {
|
|
1062
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$x.call(source, prop))
|
|
1062
1063
|
target[prop] = source[prop];
|
|
1063
1064
|
}
|
|
1064
1065
|
return target;
|
|
1065
1066
|
};
|
|
1066
1067
|
const FieldsBoolean = (_a) => {
|
|
1067
|
-
var _b = _a, { input, children } = _b, props = __objRest$
|
|
1068
|
+
var _b = _a, { input, children } = _b, props = __objRest$k(_b, ["input", "children"]);
|
|
1068
1069
|
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(
|
|
1069
1070
|
Checkbox,
|
|
1070
|
-
__spreadValues$
|
|
1071
|
+
__spreadValues$w({
|
|
1071
1072
|
checked: Boolean(input.value),
|
|
1072
1073
|
onChange: (e) => input.onChange(e.target.checked)
|
|
1073
1074
|
}, props),
|
|
@@ -1092,17 +1093,17 @@ const FieldsDateTime = ({ input }) => /* @__PURE__ */ React.createElement(React.
|
|
|
1092
1093
|
}
|
|
1093
1094
|
));
|
|
1094
1095
|
|
|
1095
|
-
var __getOwnPropSymbols$
|
|
1096
|
-
var __hasOwnProp$
|
|
1097
|
-
var __propIsEnum$
|
|
1098
|
-
var __objRest$
|
|
1096
|
+
var __getOwnPropSymbols$w = Object.getOwnPropertySymbols;
|
|
1097
|
+
var __hasOwnProp$w = Object.prototype.hasOwnProperty;
|
|
1098
|
+
var __propIsEnum$w = Object.prototype.propertyIsEnumerable;
|
|
1099
|
+
var __objRest$j = (source, exclude) => {
|
|
1099
1100
|
var target = {};
|
|
1100
1101
|
for (var prop in source)
|
|
1101
|
-
if (__hasOwnProp$
|
|
1102
|
+
if (__hasOwnProp$w.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
1102
1103
|
target[prop] = source[prop];
|
|
1103
|
-
if (source != null && __getOwnPropSymbols$
|
|
1104
|
-
for (var prop of __getOwnPropSymbols$
|
|
1105
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
1104
|
+
if (source != null && __getOwnPropSymbols$w)
|
|
1105
|
+
for (var prop of __getOwnPropSymbols$w(source)) {
|
|
1106
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$w.call(source, prop))
|
|
1106
1107
|
target[prop] = source[prop];
|
|
1107
1108
|
}
|
|
1108
1109
|
return target;
|
|
@@ -1110,7 +1111,7 @@ var __objRest$i = (source, exclude) => {
|
|
|
1110
1111
|
const FieldsDateTimeRange = (_a) => {
|
|
1111
1112
|
var _b = _a, {
|
|
1112
1113
|
input
|
|
1113
|
-
} = _b, props = __objRest$
|
|
1114
|
+
} = _b, props = __objRest$j(_b, [
|
|
1114
1115
|
"input"
|
|
1115
1116
|
]);
|
|
1116
1117
|
var _a2, _b2;
|
|
@@ -1147,53 +1148,53 @@ const FullView = /*#__PURE__*/styled('div')({
|
|
|
1147
1148
|
const InputStyle = "ipd9bk";
|
|
1148
1149
|
const KitInputStyle = "kypn5o5";
|
|
1149
1150
|
|
|
1150
|
-
var __defProp$
|
|
1151
|
-
var __getOwnPropSymbols$
|
|
1152
|
-
var __hasOwnProp$
|
|
1153
|
-
var __propIsEnum$
|
|
1154
|
-
var __defNormalProp$
|
|
1155
|
-
var __spreadValues$
|
|
1151
|
+
var __defProp$v = Object.defineProperty;
|
|
1152
|
+
var __getOwnPropSymbols$v = Object.getOwnPropertySymbols;
|
|
1153
|
+
var __hasOwnProp$v = Object.prototype.hasOwnProperty;
|
|
1154
|
+
var __propIsEnum$v = Object.prototype.propertyIsEnumerable;
|
|
1155
|
+
var __defNormalProp$v = (obj, key, value) => key in obj ? __defProp$v(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
1156
|
+
var __spreadValues$v = (a, b) => {
|
|
1156
1157
|
for (var prop in b || (b = {}))
|
|
1157
|
-
if (__hasOwnProp$
|
|
1158
|
-
__defNormalProp$
|
|
1159
|
-
if (__getOwnPropSymbols$
|
|
1160
|
-
for (var prop of __getOwnPropSymbols$
|
|
1161
|
-
if (__propIsEnum$
|
|
1162
|
-
__defNormalProp$
|
|
1158
|
+
if (__hasOwnProp$v.call(b, prop))
|
|
1159
|
+
__defNormalProp$v(a, prop, b[prop]);
|
|
1160
|
+
if (__getOwnPropSymbols$v)
|
|
1161
|
+
for (var prop of __getOwnPropSymbols$v(b)) {
|
|
1162
|
+
if (__propIsEnum$v.call(b, prop))
|
|
1163
|
+
__defNormalProp$v(a, prop, b[prop]);
|
|
1163
1164
|
}
|
|
1164
1165
|
return a;
|
|
1165
1166
|
};
|
|
1166
1167
|
const Loading = ({ fullView = true }) => {
|
|
1167
1168
|
const Wrapper = fullView ? FullView : Fragment;
|
|
1168
1169
|
const props = fullView ? { className: "loading-full-view" } : {};
|
|
1169
|
-
return /* @__PURE__ */ React.createElement(Wrapper, __spreadValues$
|
|
1170
|
+
return /* @__PURE__ */ React.createElement(Wrapper, __spreadValues$v({}, props), /* @__PURE__ */ React.createElement("div", { className: "loading" }, /* @__PURE__ */ React.createElement("div", { className: "loading__sugar" }), /* @__PURE__ */ React.createElement("div", { className: "loading__sugar" }), /* @__PURE__ */ React.createElement("div", { className: "loading__sugar" }), /* @__PURE__ */ React.createElement("div", { className: "loading__sugar" }), /* @__PURE__ */ React.createElement("div", { className: "loading__sugar" }), /* @__PURE__ */ React.createElement("div", { className: "loading__sugar" }), /* @__PURE__ */ React.createElement("div", { className: "loading__sugar" })));
|
|
1170
1171
|
};
|
|
1171
1172
|
|
|
1172
|
-
var __defProp$
|
|
1173
|
-
var __defProps$
|
|
1174
|
-
var __getOwnPropDescs$
|
|
1175
|
-
var __getOwnPropSymbols$
|
|
1176
|
-
var __hasOwnProp$
|
|
1177
|
-
var __propIsEnum$
|
|
1178
|
-
var __defNormalProp$
|
|
1173
|
+
var __defProp$u = Object.defineProperty;
|
|
1174
|
+
var __defProps$q = Object.defineProperties;
|
|
1175
|
+
var __getOwnPropDescs$q = Object.getOwnPropertyDescriptors;
|
|
1176
|
+
var __getOwnPropSymbols$u = Object.getOwnPropertySymbols;
|
|
1177
|
+
var __hasOwnProp$u = Object.prototype.hasOwnProperty;
|
|
1178
|
+
var __propIsEnum$u = Object.prototype.propertyIsEnumerable;
|
|
1179
|
+
var __defNormalProp$u = (obj, key, value) => key in obj ? __defProp$u(obj, key, {
|
|
1179
1180
|
enumerable: true,
|
|
1180
1181
|
configurable: true,
|
|
1181
1182
|
writable: true,
|
|
1182
1183
|
value
|
|
1183
1184
|
}) : obj[key] = value;
|
|
1184
|
-
var __spreadValues$
|
|
1185
|
-
for (var prop in b || (b = {})) if (__hasOwnProp$
|
|
1186
|
-
if (__getOwnPropSymbols$
|
|
1187
|
-
if (__propIsEnum$
|
|
1185
|
+
var __spreadValues$u = (a, b) => {
|
|
1186
|
+
for (var prop in b || (b = {})) if (__hasOwnProp$u.call(b, prop)) __defNormalProp$u(a, prop, b[prop]);
|
|
1187
|
+
if (__getOwnPropSymbols$u) for (var prop of __getOwnPropSymbols$u(b)) {
|
|
1188
|
+
if (__propIsEnum$u.call(b, prop)) __defNormalProp$u(a, prop, b[prop]);
|
|
1188
1189
|
}
|
|
1189
1190
|
return a;
|
|
1190
1191
|
};
|
|
1191
|
-
var __spreadProps$
|
|
1192
|
-
var __objRest$
|
|
1192
|
+
var __spreadProps$q = (a, b) => __defProps$q(a, __getOwnPropDescs$q(b));
|
|
1193
|
+
var __objRest$i = (source, exclude) => {
|
|
1193
1194
|
var target = {};
|
|
1194
|
-
for (var prop in source) if (__hasOwnProp$
|
|
1195
|
-
if (source != null && __getOwnPropSymbols$
|
|
1196
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
1195
|
+
for (var prop in source) if (__hasOwnProp$u.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
|
|
1196
|
+
if (source != null && __getOwnPropSymbols$u) for (var prop of __getOwnPropSymbols$u(source)) {
|
|
1197
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$u.call(source, prop)) target[prop] = source[prop];
|
|
1197
1198
|
}
|
|
1198
1199
|
return target;
|
|
1199
1200
|
};
|
|
@@ -1221,7 +1222,7 @@ const Select = _a => {
|
|
|
1221
1222
|
meta,
|
|
1222
1223
|
placeholder
|
|
1223
1224
|
} = _b,
|
|
1224
|
-
restProps = __objRest$
|
|
1225
|
+
restProps = __objRest$i(_b, ["input", "multiple", "className", "scrollBottomBuffer", "onScrollBottom", "onPopupScroll", "onSearch", "showSearch", "filterOption", "loading", "notFoundContent", "children", "error", "selectLimit", "dropdownClassName", "danger", "size", "meta", "placeholder"]);
|
|
1225
1226
|
var _a2;
|
|
1226
1227
|
const limitExceeded = multiple && selectLimit && selectLimit <= (((_a2 = input.value) == null ? void 0 : _a2.length) || 0);
|
|
1227
1228
|
const typo = {
|
|
@@ -1247,7 +1248,7 @@ const Select = _a => {
|
|
|
1247
1248
|
inputDom && (placeholder || item) && inputDom.setAttribute("data-test", String(placeholder || item.textContent));
|
|
1248
1249
|
}
|
|
1249
1250
|
}, [selectRef, placeholder]);
|
|
1250
|
-
return /* @__PURE__ */React.createElement(Select$1, __spreadValues$
|
|
1251
|
+
return /* @__PURE__ */React.createElement(Select$1, __spreadValues$u(__spreadProps$q(__spreadValues$u({}, input), {
|
|
1251
1252
|
ref: selectRef,
|
|
1252
1253
|
size,
|
|
1253
1254
|
value: multiple ? input.value || [] : input.value || void 0,
|
|
@@ -1287,38 +1288,38 @@ const Select = _a => {
|
|
|
1287
1288
|
loading,
|
|
1288
1289
|
placeholder
|
|
1289
1290
|
}), restProps), React.Children.map(children, child => {
|
|
1290
|
-
return isElement(child) ? __spreadProps$
|
|
1291
|
-
props: __spreadProps$
|
|
1291
|
+
return isElement(child) ? __spreadProps$q(__spreadValues$u({}, child), {
|
|
1292
|
+
props: __spreadProps$q(__spreadValues$u({}, child.props), {
|
|
1292
1293
|
"data-test": child.props.value
|
|
1293
1294
|
})
|
|
1294
1295
|
}) : child;
|
|
1295
1296
|
}));
|
|
1296
1297
|
};
|
|
1297
1298
|
|
|
1298
|
-
var __defProp$
|
|
1299
|
-
var __getOwnPropSymbols$
|
|
1300
|
-
var __hasOwnProp$
|
|
1301
|
-
var __propIsEnum$
|
|
1302
|
-
var __defNormalProp$
|
|
1303
|
-
var __spreadValues$
|
|
1299
|
+
var __defProp$t = Object.defineProperty;
|
|
1300
|
+
var __getOwnPropSymbols$t = Object.getOwnPropertySymbols;
|
|
1301
|
+
var __hasOwnProp$t = Object.prototype.hasOwnProperty;
|
|
1302
|
+
var __propIsEnum$t = Object.prototype.propertyIsEnumerable;
|
|
1303
|
+
var __defNormalProp$t = (obj, key, value) => key in obj ? __defProp$t(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
1304
|
+
var __spreadValues$t = (a, b) => {
|
|
1304
1305
|
for (var prop in b || (b = {}))
|
|
1305
|
-
if (__hasOwnProp$
|
|
1306
|
-
__defNormalProp$
|
|
1307
|
-
if (__getOwnPropSymbols$
|
|
1308
|
-
for (var prop of __getOwnPropSymbols$
|
|
1309
|
-
if (__propIsEnum$
|
|
1310
|
-
__defNormalProp$
|
|
1306
|
+
if (__hasOwnProp$t.call(b, prop))
|
|
1307
|
+
__defNormalProp$t(a, prop, b[prop]);
|
|
1308
|
+
if (__getOwnPropSymbols$t)
|
|
1309
|
+
for (var prop of __getOwnPropSymbols$t(b)) {
|
|
1310
|
+
if (__propIsEnum$t.call(b, prop))
|
|
1311
|
+
__defNormalProp$t(a, prop, b[prop]);
|
|
1311
1312
|
}
|
|
1312
1313
|
return a;
|
|
1313
1314
|
};
|
|
1314
|
-
var __objRest$
|
|
1315
|
+
var __objRest$h = (source, exclude) => {
|
|
1315
1316
|
var target = {};
|
|
1316
1317
|
for (var prop in source)
|
|
1317
|
-
if (__hasOwnProp$
|
|
1318
|
+
if (__hasOwnProp$t.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
1318
1319
|
target[prop] = source[prop];
|
|
1319
|
-
if (source != null && __getOwnPropSymbols$
|
|
1320
|
-
for (var prop of __getOwnPropSymbols$
|
|
1321
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
1320
|
+
if (source != null && __getOwnPropSymbols$t)
|
|
1321
|
+
for (var prop of __getOwnPropSymbols$t(source)) {
|
|
1322
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$t.call(source, prop))
|
|
1322
1323
|
target[prop] = source[prop];
|
|
1323
1324
|
}
|
|
1324
1325
|
return target;
|
|
@@ -1328,12 +1329,12 @@ const FieldsEnum = (_a) => {
|
|
|
1328
1329
|
meta: __,
|
|
1329
1330
|
enumValues,
|
|
1330
1331
|
emptyLabel
|
|
1331
|
-
} = _b, restProps = __objRest$
|
|
1332
|
+
} = _b, restProps = __objRest$h(_b, [
|
|
1332
1333
|
"meta",
|
|
1333
1334
|
"enumValues",
|
|
1334
1335
|
"emptyLabel"
|
|
1335
1336
|
]);
|
|
1336
|
-
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(Select, __spreadValues$
|
|
1337
|
+
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(Select, __spreadValues$t({}, restProps), emptyLabel && /* @__PURE__ */ React.createElement(Select$1.Option, { value: "" }, emptyLabel), enumValues.map((v) => {
|
|
1337
1338
|
const item = typeof v === "string" ? { value: v, text: v } : v;
|
|
1338
1339
|
return /* @__PURE__ */ React.createElement(
|
|
1339
1340
|
Select$1.Option,
|
|
@@ -1347,31 +1348,31 @@ const FieldsEnum = (_a) => {
|
|
|
1347
1348
|
})));
|
|
1348
1349
|
};
|
|
1349
1350
|
|
|
1350
|
-
var __defProp$
|
|
1351
|
-
var __defProps$
|
|
1352
|
-
var __getOwnPropDescs$
|
|
1353
|
-
var __getOwnPropSymbols$
|
|
1354
|
-
var __hasOwnProp$
|
|
1355
|
-
var __propIsEnum$
|
|
1356
|
-
var __defNormalProp$
|
|
1351
|
+
var __defProp$s = Object.defineProperty;
|
|
1352
|
+
var __defProps$p = Object.defineProperties;
|
|
1353
|
+
var __getOwnPropDescs$p = Object.getOwnPropertyDescriptors;
|
|
1354
|
+
var __getOwnPropSymbols$s = Object.getOwnPropertySymbols;
|
|
1355
|
+
var __hasOwnProp$s = Object.prototype.hasOwnProperty;
|
|
1356
|
+
var __propIsEnum$s = Object.prototype.propertyIsEnumerable;
|
|
1357
|
+
var __defNormalProp$s = (obj, key, value) => key in obj ? __defProp$s(obj, key, {
|
|
1357
1358
|
enumerable: true,
|
|
1358
1359
|
configurable: true,
|
|
1359
1360
|
writable: true,
|
|
1360
1361
|
value
|
|
1361
1362
|
}) : obj[key] = value;
|
|
1362
|
-
var __spreadValues$
|
|
1363
|
-
for (var prop in b || (b = {})) if (__hasOwnProp$
|
|
1364
|
-
if (__getOwnPropSymbols$
|
|
1365
|
-
if (__propIsEnum$
|
|
1363
|
+
var __spreadValues$s = (a, b) => {
|
|
1364
|
+
for (var prop in b || (b = {})) if (__hasOwnProp$s.call(b, prop)) __defNormalProp$s(a, prop, b[prop]);
|
|
1365
|
+
if (__getOwnPropSymbols$s) for (var prop of __getOwnPropSymbols$s(b)) {
|
|
1366
|
+
if (__propIsEnum$s.call(b, prop)) __defNormalProp$s(a, prop, b[prop]);
|
|
1366
1367
|
}
|
|
1367
1368
|
return a;
|
|
1368
1369
|
};
|
|
1369
|
-
var __spreadProps$
|
|
1370
|
-
var __objRest$
|
|
1370
|
+
var __spreadProps$p = (a, b) => __defProps$p(a, __getOwnPropDescs$p(b));
|
|
1371
|
+
var __objRest$g = (source, exclude) => {
|
|
1371
1372
|
var target = {};
|
|
1372
|
-
for (var prop in source) if (__hasOwnProp$
|
|
1373
|
-
if (source != null && __getOwnPropSymbols$
|
|
1374
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
1373
|
+
for (var prop in source) if (__hasOwnProp$s.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
|
|
1374
|
+
if (source != null && __getOwnPropSymbols$s) for (var prop of __getOwnPropSymbols$s(source)) {
|
|
1375
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$s.call(source, prop)) target[prop] = source[prop];
|
|
1375
1376
|
}
|
|
1376
1377
|
return target;
|
|
1377
1378
|
};
|
|
@@ -1407,13 +1408,13 @@ const InputNumber = _a => {
|
|
|
1407
1408
|
prefix,
|
|
1408
1409
|
controls = true
|
|
1409
1410
|
} = _b,
|
|
1410
|
-
props = __objRest$
|
|
1411
|
+
props = __objRest$g(_b, ["className", "error", "size", "suffix", "prefix", "controls"]);
|
|
1411
1412
|
const typo = {
|
|
1412
1413
|
large: Typo.Label.l2_regular,
|
|
1413
1414
|
middle: Typo.Label.l3_regular,
|
|
1414
1415
|
small: Typo.Label.l4_regular
|
|
1415
1416
|
}[size];
|
|
1416
|
-
return /* @__PURE__ */React.createElement(AntdInputNumberStyled, __spreadProps$
|
|
1417
|
+
return /* @__PURE__ */React.createElement(AntdInputNumberStyled, __spreadProps$p(__spreadValues$s({}, props), {
|
|
1417
1418
|
size,
|
|
1418
1419
|
controls,
|
|
1419
1420
|
"data-test": props.name,
|
|
@@ -1423,33 +1424,33 @@ const InputNumber = _a => {
|
|
|
1423
1424
|
}));
|
|
1424
1425
|
};
|
|
1425
1426
|
|
|
1426
|
-
var __defProp$
|
|
1427
|
-
var __defProps$
|
|
1428
|
-
var __getOwnPropDescs$
|
|
1429
|
-
var __getOwnPropSymbols$
|
|
1430
|
-
var __hasOwnProp$
|
|
1431
|
-
var __propIsEnum$
|
|
1432
|
-
var __defNormalProp$
|
|
1433
|
-
var __spreadValues$
|
|
1427
|
+
var __defProp$r = Object.defineProperty;
|
|
1428
|
+
var __defProps$o = Object.defineProperties;
|
|
1429
|
+
var __getOwnPropDescs$o = Object.getOwnPropertyDescriptors;
|
|
1430
|
+
var __getOwnPropSymbols$r = Object.getOwnPropertySymbols;
|
|
1431
|
+
var __hasOwnProp$r = Object.prototype.hasOwnProperty;
|
|
1432
|
+
var __propIsEnum$r = Object.prototype.propertyIsEnumerable;
|
|
1433
|
+
var __defNormalProp$r = (obj, key, value) => key in obj ? __defProp$r(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
1434
|
+
var __spreadValues$r = (a, b) => {
|
|
1434
1435
|
for (var prop in b || (b = {}))
|
|
1435
|
-
if (__hasOwnProp$
|
|
1436
|
-
__defNormalProp$
|
|
1437
|
-
if (__getOwnPropSymbols$
|
|
1438
|
-
for (var prop of __getOwnPropSymbols$
|
|
1439
|
-
if (__propIsEnum$
|
|
1440
|
-
__defNormalProp$
|
|
1436
|
+
if (__hasOwnProp$r.call(b, prop))
|
|
1437
|
+
__defNormalProp$r(a, prop, b[prop]);
|
|
1438
|
+
if (__getOwnPropSymbols$r)
|
|
1439
|
+
for (var prop of __getOwnPropSymbols$r(b)) {
|
|
1440
|
+
if (__propIsEnum$r.call(b, prop))
|
|
1441
|
+
__defNormalProp$r(a, prop, b[prop]);
|
|
1441
1442
|
}
|
|
1442
1443
|
return a;
|
|
1443
1444
|
};
|
|
1444
|
-
var __spreadProps$
|
|
1445
|
-
var __objRest$
|
|
1445
|
+
var __spreadProps$o = (a, b) => __defProps$o(a, __getOwnPropDescs$o(b));
|
|
1446
|
+
var __objRest$f = (source, exclude) => {
|
|
1446
1447
|
var target = {};
|
|
1447
1448
|
for (var prop in source)
|
|
1448
|
-
if (__hasOwnProp$
|
|
1449
|
+
if (__hasOwnProp$r.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
1449
1450
|
target[prop] = source[prop];
|
|
1450
|
-
if (source != null && __getOwnPropSymbols$
|
|
1451
|
-
for (var prop of __getOwnPropSymbols$
|
|
1452
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
1451
|
+
if (source != null && __getOwnPropSymbols$r)
|
|
1452
|
+
for (var prop of __getOwnPropSymbols$r(source)) {
|
|
1453
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$r.call(source, prop))
|
|
1453
1454
|
target[prop] = source[prop];
|
|
1454
1455
|
}
|
|
1455
1456
|
return target;
|
|
@@ -1460,7 +1461,7 @@ const FieldsFloat = (_a) => {
|
|
|
1460
1461
|
meta,
|
|
1461
1462
|
onBlur,
|
|
1462
1463
|
autoComplete = "off"
|
|
1463
|
-
} = _b, props = __objRest$
|
|
1464
|
+
} = _b, props = __objRest$f(_b, [
|
|
1464
1465
|
"input",
|
|
1465
1466
|
"meta",
|
|
1466
1467
|
"onBlur",
|
|
@@ -1468,7 +1469,7 @@ const FieldsFloat = (_a) => {
|
|
|
1468
1469
|
]);
|
|
1469
1470
|
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(
|
|
1470
1471
|
InputNumber,
|
|
1471
|
-
__spreadValues$
|
|
1472
|
+
__spreadValues$r(__spreadProps$o(__spreadValues$r({}, input), {
|
|
1472
1473
|
onBlur: (e) => onBlur ? onBlur(input, e) : input.onBlur(e),
|
|
1473
1474
|
autoComplete,
|
|
1474
1475
|
error: meta.touched && (meta.error || !meta.dirtySinceLastSubmit && meta.submitError)
|
|
@@ -1476,33 +1477,33 @@ const FieldsFloat = (_a) => {
|
|
|
1476
1477
|
));
|
|
1477
1478
|
};
|
|
1478
1479
|
|
|
1479
|
-
var __defProp$
|
|
1480
|
-
var __defProps$
|
|
1481
|
-
var __getOwnPropDescs$
|
|
1482
|
-
var __getOwnPropSymbols$
|
|
1483
|
-
var __hasOwnProp$
|
|
1484
|
-
var __propIsEnum$
|
|
1485
|
-
var __defNormalProp$
|
|
1486
|
-
var __spreadValues$
|
|
1480
|
+
var __defProp$q = Object.defineProperty;
|
|
1481
|
+
var __defProps$n = Object.defineProperties;
|
|
1482
|
+
var __getOwnPropDescs$n = Object.getOwnPropertyDescriptors;
|
|
1483
|
+
var __getOwnPropSymbols$q = Object.getOwnPropertySymbols;
|
|
1484
|
+
var __hasOwnProp$q = Object.prototype.hasOwnProperty;
|
|
1485
|
+
var __propIsEnum$q = Object.prototype.propertyIsEnumerable;
|
|
1486
|
+
var __defNormalProp$q = (obj, key, value) => key in obj ? __defProp$q(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
1487
|
+
var __spreadValues$q = (a, b) => {
|
|
1487
1488
|
for (var prop in b || (b = {}))
|
|
1488
|
-
if (__hasOwnProp$
|
|
1489
|
-
__defNormalProp$
|
|
1490
|
-
if (__getOwnPropSymbols$
|
|
1491
|
-
for (var prop of __getOwnPropSymbols$
|
|
1492
|
-
if (__propIsEnum$
|
|
1493
|
-
__defNormalProp$
|
|
1489
|
+
if (__hasOwnProp$q.call(b, prop))
|
|
1490
|
+
__defNormalProp$q(a, prop, b[prop]);
|
|
1491
|
+
if (__getOwnPropSymbols$q)
|
|
1492
|
+
for (var prop of __getOwnPropSymbols$q(b)) {
|
|
1493
|
+
if (__propIsEnum$q.call(b, prop))
|
|
1494
|
+
__defNormalProp$q(a, prop, b[prop]);
|
|
1494
1495
|
}
|
|
1495
1496
|
return a;
|
|
1496
1497
|
};
|
|
1497
|
-
var __spreadProps$
|
|
1498
|
-
var __objRest$
|
|
1498
|
+
var __spreadProps$n = (a, b) => __defProps$n(a, __getOwnPropDescs$n(b));
|
|
1499
|
+
var __objRest$e = (source, exclude) => {
|
|
1499
1500
|
var target = {};
|
|
1500
1501
|
for (var prop in source)
|
|
1501
|
-
if (__hasOwnProp$
|
|
1502
|
+
if (__hasOwnProp$q.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
1502
1503
|
target[prop] = source[prop];
|
|
1503
|
-
if (source != null && __getOwnPropSymbols$
|
|
1504
|
-
for (var prop of __getOwnPropSymbols$
|
|
1505
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
1504
|
+
if (source != null && __getOwnPropSymbols$q)
|
|
1505
|
+
for (var prop of __getOwnPropSymbols$q(source)) {
|
|
1506
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$q.call(source, prop))
|
|
1506
1507
|
target[prop] = source[prop];
|
|
1507
1508
|
}
|
|
1508
1509
|
return target;
|
|
@@ -1512,7 +1513,7 @@ const Input = (_a) => {
|
|
|
1512
1513
|
className,
|
|
1513
1514
|
error,
|
|
1514
1515
|
size = "middle"
|
|
1515
|
-
} = _b, props = __objRest$
|
|
1516
|
+
} = _b, props = __objRest$e(_b, [
|
|
1516
1517
|
"className",
|
|
1517
1518
|
"error",
|
|
1518
1519
|
"size"
|
|
@@ -1524,7 +1525,7 @@ const Input = (_a) => {
|
|
|
1524
1525
|
}[size];
|
|
1525
1526
|
return /* @__PURE__ */ React.createElement(
|
|
1526
1527
|
Input$1,
|
|
1527
|
-
__spreadProps$
|
|
1528
|
+
__spreadProps$n(__spreadValues$q({}, props), {
|
|
1528
1529
|
size,
|
|
1529
1530
|
"data-test": props.name,
|
|
1530
1531
|
className: cs(className, InputStyle, typo, error ? "error" : "")
|
|
@@ -1532,33 +1533,33 @@ const Input = (_a) => {
|
|
|
1532
1533
|
);
|
|
1533
1534
|
};
|
|
1534
1535
|
|
|
1535
|
-
var __defProp$
|
|
1536
|
-
var __defProps$
|
|
1537
|
-
var __getOwnPropDescs$
|
|
1538
|
-
var __getOwnPropSymbols$
|
|
1539
|
-
var __hasOwnProp$
|
|
1540
|
-
var __propIsEnum$
|
|
1541
|
-
var __defNormalProp$
|
|
1542
|
-
var __spreadValues$
|
|
1536
|
+
var __defProp$p = Object.defineProperty;
|
|
1537
|
+
var __defProps$m = Object.defineProperties;
|
|
1538
|
+
var __getOwnPropDescs$m = Object.getOwnPropertyDescriptors;
|
|
1539
|
+
var __getOwnPropSymbols$p = Object.getOwnPropertySymbols;
|
|
1540
|
+
var __hasOwnProp$p = Object.prototype.hasOwnProperty;
|
|
1541
|
+
var __propIsEnum$p = Object.prototype.propertyIsEnumerable;
|
|
1542
|
+
var __defNormalProp$p = (obj, key, value) => key in obj ? __defProp$p(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
1543
|
+
var __spreadValues$p = (a, b) => {
|
|
1543
1544
|
for (var prop in b || (b = {}))
|
|
1544
|
-
if (__hasOwnProp$
|
|
1545
|
-
__defNormalProp$
|
|
1546
|
-
if (__getOwnPropSymbols$
|
|
1547
|
-
for (var prop of __getOwnPropSymbols$
|
|
1548
|
-
if (__propIsEnum$
|
|
1549
|
-
__defNormalProp$
|
|
1545
|
+
if (__hasOwnProp$p.call(b, prop))
|
|
1546
|
+
__defNormalProp$p(a, prop, b[prop]);
|
|
1547
|
+
if (__getOwnPropSymbols$p)
|
|
1548
|
+
for (var prop of __getOwnPropSymbols$p(b)) {
|
|
1549
|
+
if (__propIsEnum$p.call(b, prop))
|
|
1550
|
+
__defNormalProp$p(a, prop, b[prop]);
|
|
1550
1551
|
}
|
|
1551
1552
|
return a;
|
|
1552
1553
|
};
|
|
1553
|
-
var __spreadProps$
|
|
1554
|
-
var __objRest$
|
|
1554
|
+
var __spreadProps$m = (a, b) => __defProps$m(a, __getOwnPropDescs$m(b));
|
|
1555
|
+
var __objRest$d = (source, exclude) => {
|
|
1555
1556
|
var target = {};
|
|
1556
1557
|
for (var prop in source)
|
|
1557
|
-
if (__hasOwnProp$
|
|
1558
|
+
if (__hasOwnProp$p.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
1558
1559
|
target[prop] = source[prop];
|
|
1559
|
-
if (source != null && __getOwnPropSymbols$
|
|
1560
|
-
for (var prop of __getOwnPropSymbols$
|
|
1561
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
1560
|
+
if (source != null && __getOwnPropSymbols$p)
|
|
1561
|
+
for (var prop of __getOwnPropSymbols$p(source)) {
|
|
1562
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$p.call(source, prop))
|
|
1562
1563
|
target[prop] = source[prop];
|
|
1563
1564
|
}
|
|
1564
1565
|
return target;
|
|
@@ -1570,7 +1571,7 @@ const FieldsInt = (_a) => {
|
|
|
1570
1571
|
onBlur,
|
|
1571
1572
|
autoComplete = "off",
|
|
1572
1573
|
supportNegativeValue = false
|
|
1573
|
-
} = _b, props = __objRest$
|
|
1574
|
+
} = _b, props = __objRest$d(_b, [
|
|
1574
1575
|
"input",
|
|
1575
1576
|
"meta",
|
|
1576
1577
|
"onBlur",
|
|
@@ -1579,7 +1580,7 @@ const FieldsInt = (_a) => {
|
|
|
1579
1580
|
]);
|
|
1580
1581
|
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(
|
|
1581
1582
|
Input,
|
|
1582
|
-
__spreadValues$
|
|
1583
|
+
__spreadValues$p(__spreadProps$m(__spreadValues$p({}, input), {
|
|
1583
1584
|
onChange: (e) => {
|
|
1584
1585
|
const value = e.currentTarget.value;
|
|
1585
1586
|
if (supportNegativeValue) {
|
|
@@ -1614,31 +1615,31 @@ const formatterInteger = (value) => {
|
|
|
1614
1615
|
}
|
|
1615
1616
|
};
|
|
1616
1617
|
|
|
1617
|
-
var __defProp$
|
|
1618
|
-
var __defProps$
|
|
1619
|
-
var __getOwnPropDescs$
|
|
1620
|
-
var __getOwnPropSymbols$
|
|
1621
|
-
var __hasOwnProp$
|
|
1622
|
-
var __propIsEnum$
|
|
1623
|
-
var __defNormalProp$
|
|
1618
|
+
var __defProp$o = Object.defineProperty;
|
|
1619
|
+
var __defProps$l = Object.defineProperties;
|
|
1620
|
+
var __getOwnPropDescs$l = Object.getOwnPropertyDescriptors;
|
|
1621
|
+
var __getOwnPropSymbols$o = Object.getOwnPropertySymbols;
|
|
1622
|
+
var __hasOwnProp$o = Object.prototype.hasOwnProperty;
|
|
1623
|
+
var __propIsEnum$o = Object.prototype.propertyIsEnumerable;
|
|
1624
|
+
var __defNormalProp$o = (obj, key, value) => key in obj ? __defProp$o(obj, key, {
|
|
1624
1625
|
enumerable: true,
|
|
1625
1626
|
configurable: true,
|
|
1626
1627
|
writable: true,
|
|
1627
1628
|
value
|
|
1628
1629
|
}) : obj[key] = value;
|
|
1629
|
-
var __spreadValues$
|
|
1630
|
-
for (var prop in b || (b = {})) if (__hasOwnProp$
|
|
1631
|
-
if (__getOwnPropSymbols$
|
|
1632
|
-
if (__propIsEnum$
|
|
1630
|
+
var __spreadValues$o = (a, b) => {
|
|
1631
|
+
for (var prop in b || (b = {})) if (__hasOwnProp$o.call(b, prop)) __defNormalProp$o(a, prop, b[prop]);
|
|
1632
|
+
if (__getOwnPropSymbols$o) for (var prop of __getOwnPropSymbols$o(b)) {
|
|
1633
|
+
if (__propIsEnum$o.call(b, prop)) __defNormalProp$o(a, prop, b[prop]);
|
|
1633
1634
|
}
|
|
1634
1635
|
return a;
|
|
1635
1636
|
};
|
|
1636
|
-
var __spreadProps$
|
|
1637
|
-
var __objRest$
|
|
1637
|
+
var __spreadProps$l = (a, b) => __defProps$l(a, __getOwnPropDescs$l(b));
|
|
1638
|
+
var __objRest$c = (source, exclude) => {
|
|
1638
1639
|
var target = {};
|
|
1639
|
-
for (var prop in source) if (__hasOwnProp$
|
|
1640
|
-
if (source != null && __getOwnPropSymbols$
|
|
1641
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
1640
|
+
for (var prop in source) if (__hasOwnProp$o.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
|
|
1641
|
+
if (source != null && __getOwnPropSymbols$o) for (var prop of __getOwnPropSymbols$o(source)) {
|
|
1642
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$o.call(source, prop)) target[prop] = source[prop];
|
|
1642
1643
|
}
|
|
1643
1644
|
return target;
|
|
1644
1645
|
};
|
|
@@ -1676,13 +1677,13 @@ const InputInteger = _a => {
|
|
|
1676
1677
|
min,
|
|
1677
1678
|
controls = false
|
|
1678
1679
|
} = _b,
|
|
1679
|
-
props = __objRest$
|
|
1680
|
+
props = __objRest$c(_b, ["className", "error", "size", "suffix", "prefix", "max", "min", "controls"]);
|
|
1680
1681
|
const typo = {
|
|
1681
1682
|
large: Typo.Label.l2_regular,
|
|
1682
1683
|
middle: Typo.Label.l3_regular,
|
|
1683
1684
|
small: Typo.Label.l4_regular
|
|
1684
1685
|
}[size];
|
|
1685
|
-
return /* @__PURE__ */React.createElement(AntdIntStyled, __spreadProps$
|
|
1686
|
+
return /* @__PURE__ */React.createElement(AntdIntStyled, __spreadProps$l(__spreadValues$o({}, props), {
|
|
1686
1687
|
size,
|
|
1687
1688
|
formatter: formatterInteger,
|
|
1688
1689
|
parser: formatterInteger,
|
|
@@ -1696,33 +1697,33 @@ const InputInteger = _a => {
|
|
|
1696
1697
|
}));
|
|
1697
1698
|
};
|
|
1698
1699
|
|
|
1699
|
-
var __defProp$
|
|
1700
|
-
var __defProps$
|
|
1701
|
-
var __getOwnPropDescs$
|
|
1702
|
-
var __getOwnPropSymbols$
|
|
1703
|
-
var __hasOwnProp$
|
|
1704
|
-
var __propIsEnum$
|
|
1705
|
-
var __defNormalProp$
|
|
1706
|
-
var __spreadValues$
|
|
1700
|
+
var __defProp$n = Object.defineProperty;
|
|
1701
|
+
var __defProps$k = Object.defineProperties;
|
|
1702
|
+
var __getOwnPropDescs$k = Object.getOwnPropertyDescriptors;
|
|
1703
|
+
var __getOwnPropSymbols$n = Object.getOwnPropertySymbols;
|
|
1704
|
+
var __hasOwnProp$n = Object.prototype.hasOwnProperty;
|
|
1705
|
+
var __propIsEnum$n = Object.prototype.propertyIsEnumerable;
|
|
1706
|
+
var __defNormalProp$n = (obj, key, value) => key in obj ? __defProp$n(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
1707
|
+
var __spreadValues$n = (a, b) => {
|
|
1707
1708
|
for (var prop in b || (b = {}))
|
|
1708
|
-
if (__hasOwnProp$
|
|
1709
|
-
__defNormalProp$
|
|
1710
|
-
if (__getOwnPropSymbols$
|
|
1711
|
-
for (var prop of __getOwnPropSymbols$
|
|
1712
|
-
if (__propIsEnum$
|
|
1713
|
-
__defNormalProp$
|
|
1709
|
+
if (__hasOwnProp$n.call(b, prop))
|
|
1710
|
+
__defNormalProp$n(a, prop, b[prop]);
|
|
1711
|
+
if (__getOwnPropSymbols$n)
|
|
1712
|
+
for (var prop of __getOwnPropSymbols$n(b)) {
|
|
1713
|
+
if (__propIsEnum$n.call(b, prop))
|
|
1714
|
+
__defNormalProp$n(a, prop, b[prop]);
|
|
1714
1715
|
}
|
|
1715
1716
|
return a;
|
|
1716
1717
|
};
|
|
1717
|
-
var __spreadProps$
|
|
1718
|
-
var __objRest$
|
|
1718
|
+
var __spreadProps$k = (a, b) => __defProps$k(a, __getOwnPropDescs$k(b));
|
|
1719
|
+
var __objRest$b = (source, exclude) => {
|
|
1719
1720
|
var target = {};
|
|
1720
1721
|
for (var prop in source)
|
|
1721
|
-
if (__hasOwnProp$
|
|
1722
|
+
if (__hasOwnProp$n.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
1722
1723
|
target[prop] = source[prop];
|
|
1723
|
-
if (source != null && __getOwnPropSymbols$
|
|
1724
|
-
for (var prop of __getOwnPropSymbols$
|
|
1725
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
1724
|
+
if (source != null && __getOwnPropSymbols$n)
|
|
1725
|
+
for (var prop of __getOwnPropSymbols$n(source)) {
|
|
1726
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$n.call(source, prop))
|
|
1726
1727
|
target[prop] = source[prop];
|
|
1727
1728
|
}
|
|
1728
1729
|
return target;
|
|
@@ -1732,14 +1733,14 @@ const FieldsInteger = (_a) => {
|
|
|
1732
1733
|
meta,
|
|
1733
1734
|
input,
|
|
1734
1735
|
onBlur
|
|
1735
|
-
} = _b, props = __objRest$
|
|
1736
|
+
} = _b, props = __objRest$b(_b, [
|
|
1736
1737
|
"meta",
|
|
1737
1738
|
"input",
|
|
1738
1739
|
"onBlur"
|
|
1739
1740
|
]);
|
|
1740
1741
|
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(
|
|
1741
1742
|
InputInteger,
|
|
1742
|
-
__spreadProps$
|
|
1743
|
+
__spreadProps$k(__spreadValues$n(__spreadValues$n({}, props), input), {
|
|
1743
1744
|
onBlur: (e) => onBlur ? onBlur(input, e) : input.onBlur(e),
|
|
1744
1745
|
error: meta.touched && (meta.error || !meta.dirtySinceLastSubmit && meta.submitError)
|
|
1745
1746
|
})
|
|
@@ -1903,33 +1904,33 @@ const Overflow = props => {
|
|
|
1903
1904
|
}, children), showOverflow && /* @__PURE__ */React.createElement("span", null, overflow));
|
|
1904
1905
|
};
|
|
1905
1906
|
|
|
1906
|
-
var __defProp$
|
|
1907
|
-
var __defProps$
|
|
1908
|
-
var __getOwnPropDescs$
|
|
1909
|
-
var __getOwnPropSymbols$
|
|
1910
|
-
var __hasOwnProp$
|
|
1911
|
-
var __propIsEnum$
|
|
1912
|
-
var __defNormalProp$
|
|
1913
|
-
var __spreadValues$
|
|
1907
|
+
var __defProp$m = Object.defineProperty;
|
|
1908
|
+
var __defProps$j = Object.defineProperties;
|
|
1909
|
+
var __getOwnPropDescs$j = Object.getOwnPropertyDescriptors;
|
|
1910
|
+
var __getOwnPropSymbols$m = Object.getOwnPropertySymbols;
|
|
1911
|
+
var __hasOwnProp$m = Object.prototype.hasOwnProperty;
|
|
1912
|
+
var __propIsEnum$m = Object.prototype.propertyIsEnumerable;
|
|
1913
|
+
var __defNormalProp$m = (obj, key, value) => key in obj ? __defProp$m(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
1914
|
+
var __spreadValues$m = (a, b) => {
|
|
1914
1915
|
for (var prop in b || (b = {}))
|
|
1915
|
-
if (__hasOwnProp$
|
|
1916
|
-
__defNormalProp$
|
|
1917
|
-
if (__getOwnPropSymbols$
|
|
1918
|
-
for (var prop of __getOwnPropSymbols$
|
|
1919
|
-
if (__propIsEnum$
|
|
1920
|
-
__defNormalProp$
|
|
1916
|
+
if (__hasOwnProp$m.call(b, prop))
|
|
1917
|
+
__defNormalProp$m(a, prop, b[prop]);
|
|
1918
|
+
if (__getOwnPropSymbols$m)
|
|
1919
|
+
for (var prop of __getOwnPropSymbols$m(b)) {
|
|
1920
|
+
if (__propIsEnum$m.call(b, prop))
|
|
1921
|
+
__defNormalProp$m(a, prop, b[prop]);
|
|
1921
1922
|
}
|
|
1922
1923
|
return a;
|
|
1923
1924
|
};
|
|
1924
|
-
var __spreadProps$
|
|
1925
|
-
var __objRest$
|
|
1925
|
+
var __spreadProps$j = (a, b) => __defProps$j(a, __getOwnPropDescs$j(b));
|
|
1926
|
+
var __objRest$a = (source, exclude) => {
|
|
1926
1927
|
var target = {};
|
|
1927
1928
|
for (var prop in source)
|
|
1928
|
-
if (__hasOwnProp$
|
|
1929
|
+
if (__hasOwnProp$m.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
1929
1930
|
target[prop] = source[prop];
|
|
1930
|
-
if (source != null && __getOwnPropSymbols$
|
|
1931
|
-
for (var prop of __getOwnPropSymbols$
|
|
1932
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
1931
|
+
if (source != null && __getOwnPropSymbols$m)
|
|
1932
|
+
for (var prop of __getOwnPropSymbols$m(source)) {
|
|
1933
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$m.call(source, prop))
|
|
1933
1934
|
target[prop] = source[prop];
|
|
1934
1935
|
}
|
|
1935
1936
|
return target;
|
|
@@ -1948,7 +1949,7 @@ const FieldsString = (_a) => {
|
|
|
1948
1949
|
onClick,
|
|
1949
1950
|
maxLength,
|
|
1950
1951
|
focusIndicator
|
|
1951
|
-
} = _b, props = __objRest$
|
|
1952
|
+
} = _b, props = __objRest$a(_b, [
|
|
1952
1953
|
"input",
|
|
1953
1954
|
"meta",
|
|
1954
1955
|
"autoComplete",
|
|
@@ -1980,7 +1981,7 @@ const FieldsString = (_a) => {
|
|
|
1980
1981
|
}
|
|
1981
1982
|
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(
|
|
1982
1983
|
Input,
|
|
1983
|
-
__spreadProps$
|
|
1984
|
+
__spreadProps$j(__spreadValues$m(__spreadProps$j(__spreadValues$m({
|
|
1984
1985
|
className: cs(
|
|
1985
1986
|
className,
|
|
1986
1987
|
KitInputStyle,
|
|
@@ -2005,33 +2006,33 @@ const FieldsString = (_a) => {
|
|
|
2005
2006
|
));
|
|
2006
2007
|
};
|
|
2007
2008
|
|
|
2008
|
-
var __defProp$
|
|
2009
|
-
var __defProps$
|
|
2010
|
-
var __getOwnPropDescs$
|
|
2011
|
-
var __getOwnPropSymbols$
|
|
2012
|
-
var __hasOwnProp$
|
|
2013
|
-
var __propIsEnum$
|
|
2014
|
-
var __defNormalProp$
|
|
2015
|
-
var __spreadValues$
|
|
2009
|
+
var __defProp$l = Object.defineProperty;
|
|
2010
|
+
var __defProps$i = Object.defineProperties;
|
|
2011
|
+
var __getOwnPropDescs$i = Object.getOwnPropertyDescriptors;
|
|
2012
|
+
var __getOwnPropSymbols$l = Object.getOwnPropertySymbols;
|
|
2013
|
+
var __hasOwnProp$l = Object.prototype.hasOwnProperty;
|
|
2014
|
+
var __propIsEnum$l = Object.prototype.propertyIsEnumerable;
|
|
2015
|
+
var __defNormalProp$l = (obj, key, value) => key in obj ? __defProp$l(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
2016
|
+
var __spreadValues$l = (a, b) => {
|
|
2016
2017
|
for (var prop in b || (b = {}))
|
|
2017
|
-
if (__hasOwnProp$
|
|
2018
|
-
__defNormalProp$
|
|
2019
|
-
if (__getOwnPropSymbols$
|
|
2020
|
-
for (var prop of __getOwnPropSymbols$
|
|
2021
|
-
if (__propIsEnum$
|
|
2022
|
-
__defNormalProp$
|
|
2018
|
+
if (__hasOwnProp$l.call(b, prop))
|
|
2019
|
+
__defNormalProp$l(a, prop, b[prop]);
|
|
2020
|
+
if (__getOwnPropSymbols$l)
|
|
2021
|
+
for (var prop of __getOwnPropSymbols$l(b)) {
|
|
2022
|
+
if (__propIsEnum$l.call(b, prop))
|
|
2023
|
+
__defNormalProp$l(a, prop, b[prop]);
|
|
2023
2024
|
}
|
|
2024
2025
|
return a;
|
|
2025
2026
|
};
|
|
2026
|
-
var __spreadProps$
|
|
2027
|
-
var __objRest$
|
|
2027
|
+
var __spreadProps$i = (a, b) => __defProps$i(a, __getOwnPropDescs$i(b));
|
|
2028
|
+
var __objRest$9 = (source, exclude) => {
|
|
2028
2029
|
var target = {};
|
|
2029
2030
|
for (var prop in source)
|
|
2030
|
-
if (__hasOwnProp$
|
|
2031
|
+
if (__hasOwnProp$l.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
2031
2032
|
target[prop] = source[prop];
|
|
2032
|
-
if (source != null && __getOwnPropSymbols$
|
|
2033
|
-
for (var prop of __getOwnPropSymbols$
|
|
2034
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
2033
|
+
if (source != null && __getOwnPropSymbols$l)
|
|
2034
|
+
for (var prop of __getOwnPropSymbols$l(source)) {
|
|
2035
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$l.call(source, prop))
|
|
2035
2036
|
target[prop] = source[prop];
|
|
2036
2037
|
}
|
|
2037
2038
|
return target;
|
|
@@ -2041,7 +2042,7 @@ const TextArea = (_a) => {
|
|
|
2041
2042
|
className,
|
|
2042
2043
|
error,
|
|
2043
2044
|
size = "middle"
|
|
2044
|
-
} = _b, props = __objRest$
|
|
2045
|
+
} = _b, props = __objRest$9(_b, [
|
|
2045
2046
|
"className",
|
|
2046
2047
|
"error",
|
|
2047
2048
|
"size"
|
|
@@ -2053,7 +2054,7 @@ const TextArea = (_a) => {
|
|
|
2053
2054
|
}[size];
|
|
2054
2055
|
return /* @__PURE__ */ React.createElement(
|
|
2055
2056
|
Input$1.TextArea,
|
|
2056
|
-
__spreadProps$
|
|
2057
|
+
__spreadProps$i(__spreadValues$l({}, props), {
|
|
2057
2058
|
className: cs(
|
|
2058
2059
|
className,
|
|
2059
2060
|
InputStyle,
|
|
@@ -2067,33 +2068,33 @@ const TextArea = (_a) => {
|
|
|
2067
2068
|
);
|
|
2068
2069
|
};
|
|
2069
2070
|
|
|
2070
|
-
var __defProp$
|
|
2071
|
-
var __defProps$
|
|
2072
|
-
var __getOwnPropDescs$
|
|
2073
|
-
var __getOwnPropSymbols$
|
|
2074
|
-
var __hasOwnProp$
|
|
2075
|
-
var __propIsEnum$
|
|
2076
|
-
var __defNormalProp$
|
|
2077
|
-
var __spreadValues$
|
|
2071
|
+
var __defProp$k = Object.defineProperty;
|
|
2072
|
+
var __defProps$h = Object.defineProperties;
|
|
2073
|
+
var __getOwnPropDescs$h = Object.getOwnPropertyDescriptors;
|
|
2074
|
+
var __getOwnPropSymbols$k = Object.getOwnPropertySymbols;
|
|
2075
|
+
var __hasOwnProp$k = Object.prototype.hasOwnProperty;
|
|
2076
|
+
var __propIsEnum$k = Object.prototype.propertyIsEnumerable;
|
|
2077
|
+
var __defNormalProp$k = (obj, key, value) => key in obj ? __defProp$k(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
2078
|
+
var __spreadValues$k = (a, b) => {
|
|
2078
2079
|
for (var prop in b || (b = {}))
|
|
2079
|
-
if (__hasOwnProp$
|
|
2080
|
-
__defNormalProp$
|
|
2081
|
-
if (__getOwnPropSymbols$
|
|
2082
|
-
for (var prop of __getOwnPropSymbols$
|
|
2083
|
-
if (__propIsEnum$
|
|
2084
|
-
__defNormalProp$
|
|
2080
|
+
if (__hasOwnProp$k.call(b, prop))
|
|
2081
|
+
__defNormalProp$k(a, prop, b[prop]);
|
|
2082
|
+
if (__getOwnPropSymbols$k)
|
|
2083
|
+
for (var prop of __getOwnPropSymbols$k(b)) {
|
|
2084
|
+
if (__propIsEnum$k.call(b, prop))
|
|
2085
|
+
__defNormalProp$k(a, prop, b[prop]);
|
|
2085
2086
|
}
|
|
2086
2087
|
return a;
|
|
2087
2088
|
};
|
|
2088
|
-
var __spreadProps$
|
|
2089
|
-
var __objRest$
|
|
2089
|
+
var __spreadProps$h = (a, b) => __defProps$h(a, __getOwnPropDescs$h(b));
|
|
2090
|
+
var __objRest$8 = (source, exclude) => {
|
|
2090
2091
|
var target = {};
|
|
2091
2092
|
for (var prop in source)
|
|
2092
|
-
if (__hasOwnProp$
|
|
2093
|
+
if (__hasOwnProp$k.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
2093
2094
|
target[prop] = source[prop];
|
|
2094
|
-
if (source != null && __getOwnPropSymbols$
|
|
2095
|
-
for (var prop of __getOwnPropSymbols$
|
|
2096
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
2095
|
+
if (source != null && __getOwnPropSymbols$k)
|
|
2096
|
+
for (var prop of __getOwnPropSymbols$k(source)) {
|
|
2097
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$k.call(source, prop))
|
|
2097
2098
|
target[prop] = source[prop];
|
|
2098
2099
|
}
|
|
2099
2100
|
return target;
|
|
@@ -2103,14 +2104,14 @@ const FieldsTextArea = (_a) => {
|
|
|
2103
2104
|
input,
|
|
2104
2105
|
meta,
|
|
2105
2106
|
onFocusChangeHeight
|
|
2106
|
-
} = _b, props = __objRest$
|
|
2107
|
+
} = _b, props = __objRest$8(_b, [
|
|
2107
2108
|
"input",
|
|
2108
2109
|
"meta",
|
|
2109
2110
|
"onFocusChangeHeight"
|
|
2110
2111
|
]);
|
|
2111
2112
|
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(
|
|
2112
2113
|
TextArea,
|
|
2113
|
-
__spreadProps$
|
|
2114
|
+
__spreadProps$h(__spreadValues$k(__spreadValues$k({}, input), props), {
|
|
2114
2115
|
error: meta.touched && (meta.error || !meta.dirtySinceLastSubmit && meta.submitError),
|
|
2115
2116
|
onFocus: (e) => {
|
|
2116
2117
|
input.onFocus(e);
|
|
@@ -2124,33 +2125,33 @@ const FieldsTextArea = (_a) => {
|
|
|
2124
2125
|
));
|
|
2125
2126
|
};
|
|
2126
2127
|
|
|
2127
|
-
var __defProp$
|
|
2128
|
-
var __defProps$
|
|
2129
|
-
var __getOwnPropDescs$
|
|
2130
|
-
var __getOwnPropSymbols$
|
|
2131
|
-
var __hasOwnProp$
|
|
2132
|
-
var __propIsEnum$
|
|
2133
|
-
var __defNormalProp$
|
|
2134
|
-
var __spreadValues$
|
|
2128
|
+
var __defProp$j = Object.defineProperty;
|
|
2129
|
+
var __defProps$g = Object.defineProperties;
|
|
2130
|
+
var __getOwnPropDescs$g = Object.getOwnPropertyDescriptors;
|
|
2131
|
+
var __getOwnPropSymbols$j = Object.getOwnPropertySymbols;
|
|
2132
|
+
var __hasOwnProp$j = Object.prototype.hasOwnProperty;
|
|
2133
|
+
var __propIsEnum$j = Object.prototype.propertyIsEnumerable;
|
|
2134
|
+
var __defNormalProp$j = (obj, key, value) => key in obj ? __defProp$j(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
2135
|
+
var __spreadValues$j = (a, b) => {
|
|
2135
2136
|
for (var prop in b || (b = {}))
|
|
2136
|
-
if (__hasOwnProp$
|
|
2137
|
-
__defNormalProp$
|
|
2138
|
-
if (__getOwnPropSymbols$
|
|
2139
|
-
for (var prop of __getOwnPropSymbols$
|
|
2140
|
-
if (__propIsEnum$
|
|
2141
|
-
__defNormalProp$
|
|
2137
|
+
if (__hasOwnProp$j.call(b, prop))
|
|
2138
|
+
__defNormalProp$j(a, prop, b[prop]);
|
|
2139
|
+
if (__getOwnPropSymbols$j)
|
|
2140
|
+
for (var prop of __getOwnPropSymbols$j(b)) {
|
|
2141
|
+
if (__propIsEnum$j.call(b, prop))
|
|
2142
|
+
__defNormalProp$j(a, prop, b[prop]);
|
|
2142
2143
|
}
|
|
2143
2144
|
return a;
|
|
2144
2145
|
};
|
|
2145
|
-
var __spreadProps$
|
|
2146
|
-
var __objRest$
|
|
2146
|
+
var __spreadProps$g = (a, b) => __defProps$g(a, __getOwnPropDescs$g(b));
|
|
2147
|
+
var __objRest$7 = (source, exclude) => {
|
|
2147
2148
|
var target = {};
|
|
2148
2149
|
for (var prop in source)
|
|
2149
|
-
if (__hasOwnProp$
|
|
2150
|
+
if (__hasOwnProp$j.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
2150
2151
|
target[prop] = source[prop];
|
|
2151
|
-
if (source != null && __getOwnPropSymbols$
|
|
2152
|
-
for (var prop of __getOwnPropSymbols$
|
|
2153
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
2152
|
+
if (source != null && __getOwnPropSymbols$j)
|
|
2153
|
+
for (var prop of __getOwnPropSymbols$j(source)) {
|
|
2154
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$j.call(source, prop))
|
|
2154
2155
|
target[prop] = source[prop];
|
|
2155
2156
|
}
|
|
2156
2157
|
return target;
|
|
@@ -2160,7 +2161,7 @@ const TimePicker = (_a) => {
|
|
|
2160
2161
|
className,
|
|
2161
2162
|
error,
|
|
2162
2163
|
size = "middle"
|
|
2163
|
-
} = _b, props = __objRest$
|
|
2164
|
+
} = _b, props = __objRest$7(_b, [
|
|
2164
2165
|
"className",
|
|
2165
2166
|
"error",
|
|
2166
2167
|
"size"
|
|
@@ -2172,7 +2173,7 @@ const TimePicker = (_a) => {
|
|
|
2172
2173
|
}[size];
|
|
2173
2174
|
return /* @__PURE__ */ React.createElement(
|
|
2174
2175
|
TimePicker$1,
|
|
2175
|
-
__spreadProps$
|
|
2176
|
+
__spreadProps$g(__spreadValues$j({}, props), {
|
|
2176
2177
|
size,
|
|
2177
2178
|
"data-test": props.name,
|
|
2178
2179
|
className: cs(className, InputStyle, typo, error ? "error" : "")
|
|
@@ -2180,33 +2181,33 @@ const TimePicker = (_a) => {
|
|
|
2180
2181
|
);
|
|
2181
2182
|
};
|
|
2182
2183
|
|
|
2183
|
-
var __defProp$
|
|
2184
|
-
var __defProps$
|
|
2185
|
-
var __getOwnPropDescs$
|
|
2186
|
-
var __getOwnPropSymbols$
|
|
2187
|
-
var __hasOwnProp$
|
|
2188
|
-
var __propIsEnum$
|
|
2189
|
-
var __defNormalProp$
|
|
2190
|
-
var __spreadValues$
|
|
2184
|
+
var __defProp$i = Object.defineProperty;
|
|
2185
|
+
var __defProps$f = Object.defineProperties;
|
|
2186
|
+
var __getOwnPropDescs$f = Object.getOwnPropertyDescriptors;
|
|
2187
|
+
var __getOwnPropSymbols$i = Object.getOwnPropertySymbols;
|
|
2188
|
+
var __hasOwnProp$i = Object.prototype.hasOwnProperty;
|
|
2189
|
+
var __propIsEnum$i = Object.prototype.propertyIsEnumerable;
|
|
2190
|
+
var __defNormalProp$i = (obj, key, value) => key in obj ? __defProp$i(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
2191
|
+
var __spreadValues$i = (a, b) => {
|
|
2191
2192
|
for (var prop in b || (b = {}))
|
|
2192
|
-
if (__hasOwnProp$
|
|
2193
|
-
__defNormalProp$
|
|
2194
|
-
if (__getOwnPropSymbols$
|
|
2195
|
-
for (var prop of __getOwnPropSymbols$
|
|
2196
|
-
if (__propIsEnum$
|
|
2197
|
-
__defNormalProp$
|
|
2193
|
+
if (__hasOwnProp$i.call(b, prop))
|
|
2194
|
+
__defNormalProp$i(a, prop, b[prop]);
|
|
2195
|
+
if (__getOwnPropSymbols$i)
|
|
2196
|
+
for (var prop of __getOwnPropSymbols$i(b)) {
|
|
2197
|
+
if (__propIsEnum$i.call(b, prop))
|
|
2198
|
+
__defNormalProp$i(a, prop, b[prop]);
|
|
2198
2199
|
}
|
|
2199
2200
|
return a;
|
|
2200
2201
|
};
|
|
2201
|
-
var __spreadProps$
|
|
2202
|
-
var __objRest$
|
|
2202
|
+
var __spreadProps$f = (a, b) => __defProps$f(a, __getOwnPropDescs$f(b));
|
|
2203
|
+
var __objRest$6 = (source, exclude) => {
|
|
2203
2204
|
var target = {};
|
|
2204
2205
|
for (var prop in source)
|
|
2205
|
-
if (__hasOwnProp$
|
|
2206
|
+
if (__hasOwnProp$i.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
2206
2207
|
target[prop] = source[prop];
|
|
2207
|
-
if (source != null && __getOwnPropSymbols$
|
|
2208
|
-
for (var prop of __getOwnPropSymbols$
|
|
2209
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
2208
|
+
if (source != null && __getOwnPropSymbols$i)
|
|
2209
|
+
for (var prop of __getOwnPropSymbols$i(source)) {
|
|
2210
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$i.call(source, prop))
|
|
2210
2211
|
target[prop] = source[prop];
|
|
2211
2212
|
}
|
|
2212
2213
|
return target;
|
|
@@ -2215,13 +2216,13 @@ const FieldsTimePicker = (_a) => {
|
|
|
2215
2216
|
var _b = _a, {
|
|
2216
2217
|
input,
|
|
2217
2218
|
meta
|
|
2218
|
-
} = _b, props = __objRest$
|
|
2219
|
+
} = _b, props = __objRest$6(_b, [
|
|
2219
2220
|
"input",
|
|
2220
2221
|
"meta"
|
|
2221
2222
|
]);
|
|
2222
2223
|
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(
|
|
2223
2224
|
TimePicker,
|
|
2224
|
-
__spreadValues$
|
|
2225
|
+
__spreadValues$i(__spreadProps$f(__spreadValues$i({}, input), {
|
|
2225
2226
|
error: meta.touched && (meta.error || !meta.dirtySinceLastSubmit && meta.submitError)
|
|
2226
2227
|
}), props)
|
|
2227
2228
|
));
|
|
@@ -2260,25 +2261,162 @@ const InputGroup = /*#__PURE__*/styled(_exp())({
|
|
|
2260
2261
|
propsAsIs: true
|
|
2261
2262
|
});
|
|
2262
2263
|
|
|
2263
|
-
var __defProp$
|
|
2264
|
-
var __defProps$
|
|
2265
|
-
var __getOwnPropDescs$
|
|
2266
|
-
var __getOwnPropSymbols$
|
|
2267
|
-
var __hasOwnProp$
|
|
2268
|
-
var __propIsEnum$
|
|
2269
|
-
var __defNormalProp$
|
|
2270
|
-
var __spreadValues$
|
|
2264
|
+
var __defProp$h = Object.defineProperty;
|
|
2265
|
+
var __defProps$e = Object.defineProperties;
|
|
2266
|
+
var __getOwnPropDescs$e = Object.getOwnPropertyDescriptors;
|
|
2267
|
+
var __getOwnPropSymbols$h = Object.getOwnPropertySymbols;
|
|
2268
|
+
var __hasOwnProp$h = Object.prototype.hasOwnProperty;
|
|
2269
|
+
var __propIsEnum$h = Object.prototype.propertyIsEnumerable;
|
|
2270
|
+
var __defNormalProp$h = (obj, key, value) => key in obj ? __defProp$h(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
2271
|
+
var __spreadValues$h = (a, b) => {
|
|
2271
2272
|
for (var prop in b || (b = {}))
|
|
2272
|
-
if (__hasOwnProp$
|
|
2273
|
-
__defNormalProp$
|
|
2274
|
-
if (__getOwnPropSymbols$
|
|
2275
|
-
for (var prop of __getOwnPropSymbols$
|
|
2276
|
-
if (__propIsEnum$
|
|
2277
|
-
__defNormalProp$
|
|
2273
|
+
if (__hasOwnProp$h.call(b, prop))
|
|
2274
|
+
__defNormalProp$h(a, prop, b[prop]);
|
|
2275
|
+
if (__getOwnPropSymbols$h)
|
|
2276
|
+
for (var prop of __getOwnPropSymbols$h(b)) {
|
|
2277
|
+
if (__propIsEnum$h.call(b, prop))
|
|
2278
|
+
__defNormalProp$h(a, prop, b[prop]);
|
|
2278
2279
|
}
|
|
2279
2280
|
return a;
|
|
2280
2281
|
};
|
|
2281
|
-
var __spreadProps$
|
|
2282
|
+
var __spreadProps$e = (a, b) => __defProps$e(a, __getOwnPropDescs$e(b));
|
|
2283
|
+
function makeUUID(length = 25) {
|
|
2284
|
+
let result = "";
|
|
2285
|
+
const characters = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
|
|
2286
|
+
const charactersLength = characters.length;
|
|
2287
|
+
for (let i = 0; i < length; i++) {
|
|
2288
|
+
result += characters.charAt(Math.floor(Math.random() * charactersLength));
|
|
2289
|
+
}
|
|
2290
|
+
return result;
|
|
2291
|
+
}
|
|
2292
|
+
class Batcher {
|
|
2293
|
+
constructor(originalMethod, batchHelper) {
|
|
2294
|
+
this.batchSize = 2;
|
|
2295
|
+
this.batchTime = 200;
|
|
2296
|
+
this.scheduler = {};
|
|
2297
|
+
this.originalMethod = originalMethod;
|
|
2298
|
+
this.batchHelper = batchHelper;
|
|
2299
|
+
}
|
|
2300
|
+
addMessage(originContent) {
|
|
2301
|
+
const batchKey = this.batchHelper.getBatchKey(originContent.content);
|
|
2302
|
+
if (batchKey == null) {
|
|
2303
|
+
this.originalMethod(originContent);
|
|
2304
|
+
return;
|
|
2305
|
+
}
|
|
2306
|
+
if (!this.scheduler[batchKey]) {
|
|
2307
|
+
this.scheduler[batchKey] = {
|
|
2308
|
+
firedHandlers: {},
|
|
2309
|
+
pendingMessages: {}
|
|
2310
|
+
};
|
|
2311
|
+
}
|
|
2312
|
+
const messageStore = this.scheduler[batchKey];
|
|
2313
|
+
const { firedHandlers, pendingMessages, groupedCtx } = messageStore;
|
|
2314
|
+
if (groupedCtx) {
|
|
2315
|
+
groupedCtx.count++;
|
|
2316
|
+
this.applyContent(batchKey, originContent, messageStore);
|
|
2317
|
+
return;
|
|
2318
|
+
}
|
|
2319
|
+
const messageCount = Object.keys(firedHandlers).length + Object.keys(pendingMessages).length;
|
|
2320
|
+
if (messageCount + 1 > this.batchSize) {
|
|
2321
|
+
for (const k in firedHandlers) {
|
|
2322
|
+
try {
|
|
2323
|
+
firedHandlers[k]();
|
|
2324
|
+
} catch (e) {
|
|
2325
|
+
}
|
|
2326
|
+
delete firedHandlers[k];
|
|
2327
|
+
}
|
|
2328
|
+
for (const k in pendingMessages) {
|
|
2329
|
+
delete pendingMessages[k];
|
|
2330
|
+
}
|
|
2331
|
+
messageStore.groupedCtx = {
|
|
2332
|
+
key: originContent.key,
|
|
2333
|
+
count: messageCount + 1
|
|
2334
|
+
};
|
|
2335
|
+
this.applyContent(batchKey, originContent, messageStore);
|
|
2336
|
+
return;
|
|
2337
|
+
}
|
|
2338
|
+
pendingMessages[originContent.key] = originContent;
|
|
2339
|
+
setTimeout(() => {
|
|
2340
|
+
if (originContent.key in pendingMessages) {
|
|
2341
|
+
delete pendingMessages[originContent.key];
|
|
2342
|
+
originContent.onClose = () => {
|
|
2343
|
+
delete firedHandlers[originContent.key];
|
|
2344
|
+
delete messageStore.groupedCtx;
|
|
2345
|
+
};
|
|
2346
|
+
const handler = this.originalMethod(originContent);
|
|
2347
|
+
firedHandlers[originContent.key] = handler;
|
|
2348
|
+
}
|
|
2349
|
+
}, this.batchTime);
|
|
2350
|
+
}
|
|
2351
|
+
applyContent(batchKey, content, store) {
|
|
2352
|
+
content.content = this.batchHelper.getBatchContent(
|
|
2353
|
+
batchKey,
|
|
2354
|
+
store.groupedCtx.count
|
|
2355
|
+
);
|
|
2356
|
+
content.key = store.groupedCtx.key;
|
|
2357
|
+
content.onClose = () => {
|
|
2358
|
+
delete store.groupedCtx;
|
|
2359
|
+
};
|
|
2360
|
+
this.originalMethod(content);
|
|
2361
|
+
}
|
|
2362
|
+
}
|
|
2363
|
+
function createBatchMessageMethods(batchHelper) {
|
|
2364
|
+
if (batchHelper == null) {
|
|
2365
|
+
return message;
|
|
2366
|
+
}
|
|
2367
|
+
let _message = message;
|
|
2368
|
+
const methods = [
|
|
2369
|
+
"success",
|
|
2370
|
+
"error",
|
|
2371
|
+
"info",
|
|
2372
|
+
"warning",
|
|
2373
|
+
"warn",
|
|
2374
|
+
"loading"
|
|
2375
|
+
];
|
|
2376
|
+
for (const method of methods) {
|
|
2377
|
+
const originalMethod = _message[method];
|
|
2378
|
+
const batcher = new Batcher(originalMethod, batchHelper);
|
|
2379
|
+
_message[method] = function(...args) {
|
|
2380
|
+
const key = makeUUID();
|
|
2381
|
+
const content = normalizeContent(args, method);
|
|
2382
|
+
batcher.addMessage(__spreadProps$e(__spreadValues$h({}, content), { key }));
|
|
2383
|
+
return () => {
|
|
2384
|
+
};
|
|
2385
|
+
};
|
|
2386
|
+
}
|
|
2387
|
+
return _message;
|
|
2388
|
+
}
|
|
2389
|
+
function normalizeContent(args, type) {
|
|
2390
|
+
const c = args[0];
|
|
2391
|
+
if (c && typeof c === "object" && "content" in c) {
|
|
2392
|
+
return c;
|
|
2393
|
+
}
|
|
2394
|
+
return {
|
|
2395
|
+
content: c,
|
|
2396
|
+
duration: typeof args[1] === "number" ? args[1] : 6,
|
|
2397
|
+
type: type === "warn" ? "warning" : type
|
|
2398
|
+
};
|
|
2399
|
+
}
|
|
2400
|
+
|
|
2401
|
+
var __defProp$g = Object.defineProperty;
|
|
2402
|
+
var __defProps$d = Object.defineProperties;
|
|
2403
|
+
var __getOwnPropDescs$d = Object.getOwnPropertyDescriptors;
|
|
2404
|
+
var __getOwnPropSymbols$g = Object.getOwnPropertySymbols;
|
|
2405
|
+
var __hasOwnProp$g = Object.prototype.hasOwnProperty;
|
|
2406
|
+
var __propIsEnum$g = Object.prototype.propertyIsEnumerable;
|
|
2407
|
+
var __defNormalProp$g = (obj, key, value) => key in obj ? __defProp$g(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
2408
|
+
var __spreadValues$g = (a, b) => {
|
|
2409
|
+
for (var prop in b || (b = {}))
|
|
2410
|
+
if (__hasOwnProp$g.call(b, prop))
|
|
2411
|
+
__defNormalProp$g(a, prop, b[prop]);
|
|
2412
|
+
if (__getOwnPropSymbols$g)
|
|
2413
|
+
for (var prop of __getOwnPropSymbols$g(b)) {
|
|
2414
|
+
if (__propIsEnum$g.call(b, prop))
|
|
2415
|
+
__defNormalProp$g(a, prop, b[prop]);
|
|
2416
|
+
}
|
|
2417
|
+
return a;
|
|
2418
|
+
};
|
|
2419
|
+
var __spreadProps$d = (a, b) => __defProps$d(a, __getOwnPropDescs$d(b));
|
|
2282
2420
|
const initialChartState = {
|
|
2283
2421
|
pointers: {},
|
|
2284
2422
|
resourceData: {},
|
|
@@ -2288,8 +2426,8 @@ const chartReducer = (state = initialChartState, action) => {
|
|
|
2288
2426
|
switch (action.type) {
|
|
2289
2427
|
case "SET_POINTER" /* SET_POINTER */: {
|
|
2290
2428
|
const { uuid, left, text, visible, value } = action.payload;
|
|
2291
|
-
return __spreadProps$
|
|
2292
|
-
pointers: __spreadProps$
|
|
2429
|
+
return __spreadProps$d(__spreadValues$g({}, state), {
|
|
2430
|
+
pointers: __spreadProps$d(__spreadValues$g({}, state.pointers), {
|
|
2293
2431
|
[uuid]: {
|
|
2294
2432
|
left,
|
|
2295
2433
|
text,
|
|
@@ -2301,16 +2439,16 @@ const chartReducer = (state = initialChartState, action) => {
|
|
|
2301
2439
|
}
|
|
2302
2440
|
case "SET_RESOURCE_DATA" /* SET_RESOURCE_DATA */: {
|
|
2303
2441
|
const { uuid, data } = action.payload;
|
|
2304
|
-
return __spreadProps$
|
|
2305
|
-
resourceData: __spreadProps$
|
|
2442
|
+
return __spreadProps$d(__spreadValues$g({}, state), {
|
|
2443
|
+
resourceData: __spreadProps$d(__spreadValues$g({}, state.resourceData), {
|
|
2306
2444
|
[uuid]: data
|
|
2307
2445
|
})
|
|
2308
2446
|
});
|
|
2309
2447
|
}
|
|
2310
2448
|
case "SET_AVERAGE_DATA" /* SET_AVERAGE_DATA */: {
|
|
2311
2449
|
const { uuid, average } = action.payload;
|
|
2312
|
-
return __spreadProps$
|
|
2313
|
-
averageData: __spreadProps$
|
|
2450
|
+
return __spreadProps$d(__spreadValues$g({}, state), {
|
|
2451
|
+
averageData: __spreadProps$d(__spreadValues$g({}, state.averageData), {
|
|
2314
2452
|
[uuid]: average
|
|
2315
2453
|
})
|
|
2316
2454
|
});
|
|
@@ -2321,25 +2459,25 @@ const chartReducer = (state = initialChartState, action) => {
|
|
|
2321
2459
|
}
|
|
2322
2460
|
};
|
|
2323
2461
|
|
|
2324
|
-
var __defProp$
|
|
2325
|
-
var __defProps$
|
|
2326
|
-
var __getOwnPropDescs$
|
|
2327
|
-
var __getOwnPropSymbols$
|
|
2328
|
-
var __hasOwnProp$
|
|
2329
|
-
var __propIsEnum$
|
|
2330
|
-
var __defNormalProp$
|
|
2331
|
-
var __spreadValues$
|
|
2462
|
+
var __defProp$f = Object.defineProperty;
|
|
2463
|
+
var __defProps$c = Object.defineProperties;
|
|
2464
|
+
var __getOwnPropDescs$c = Object.getOwnPropertyDescriptors;
|
|
2465
|
+
var __getOwnPropSymbols$f = Object.getOwnPropertySymbols;
|
|
2466
|
+
var __hasOwnProp$f = Object.prototype.hasOwnProperty;
|
|
2467
|
+
var __propIsEnum$f = Object.prototype.propertyIsEnumerable;
|
|
2468
|
+
var __defNormalProp$f = (obj, key, value) => key in obj ? __defProp$f(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
2469
|
+
var __spreadValues$f = (a, b) => {
|
|
2332
2470
|
for (var prop in b || (b = {}))
|
|
2333
|
-
if (__hasOwnProp$
|
|
2334
|
-
__defNormalProp$
|
|
2335
|
-
if (__getOwnPropSymbols$
|
|
2336
|
-
for (var prop of __getOwnPropSymbols$
|
|
2337
|
-
if (__propIsEnum$
|
|
2338
|
-
__defNormalProp$
|
|
2471
|
+
if (__hasOwnProp$f.call(b, prop))
|
|
2472
|
+
__defNormalProp$f(a, prop, b[prop]);
|
|
2473
|
+
if (__getOwnPropSymbols$f)
|
|
2474
|
+
for (var prop of __getOwnPropSymbols$f(b)) {
|
|
2475
|
+
if (__propIsEnum$f.call(b, prop))
|
|
2476
|
+
__defNormalProp$f(a, prop, b[prop]);
|
|
2339
2477
|
}
|
|
2340
2478
|
return a;
|
|
2341
2479
|
};
|
|
2342
|
-
var __spreadProps$
|
|
2480
|
+
var __spreadProps$c = (a, b) => __defProps$c(a, __getOwnPropDescs$c(b));
|
|
2343
2481
|
var ModalActions = /* @__PURE__ */ ((ModalActions2) => {
|
|
2344
2482
|
ModalActions2["PUSH_MODAL"] = "PUSH_MODAL";
|
|
2345
2483
|
ModalActions2["POP_MODAL"] = "POP_MODAL";
|
|
@@ -2360,22 +2498,22 @@ const modalReducer = (state = initialModalState, action) => {
|
|
|
2360
2498
|
)) {
|
|
2361
2499
|
return state;
|
|
2362
2500
|
}
|
|
2363
|
-
return __spreadProps$
|
|
2364
|
-
stack: state.stack.concat(__spreadProps$
|
|
2501
|
+
return __spreadProps$c(__spreadValues$f({}, state), {
|
|
2502
|
+
stack: state.stack.concat(__spreadProps$c(__spreadValues$f({}, action.payload), {
|
|
2365
2503
|
id: MODAL_ID++
|
|
2366
2504
|
}))
|
|
2367
2505
|
});
|
|
2368
2506
|
case "POP_MODAL" /* POP_MODAL */:
|
|
2369
|
-
return __spreadProps$
|
|
2507
|
+
return __spreadProps$c(__spreadValues$f({}, state), {
|
|
2370
2508
|
stack: state.stack.slice(0, -1)
|
|
2371
2509
|
});
|
|
2372
2510
|
case "REMOVE_MODAL" /* REMOVE_MODAL */:
|
|
2373
|
-
return __spreadProps$
|
|
2511
|
+
return __spreadProps$c(__spreadValues$f({}, state), {
|
|
2374
2512
|
closeId: 0,
|
|
2375
2513
|
stack: state.stack.filter((m) => m.id !== action.id)
|
|
2376
2514
|
});
|
|
2377
2515
|
case "CLOSE_MODAL" /* CLOSE_MODAL */:
|
|
2378
|
-
return __spreadProps$
|
|
2516
|
+
return __spreadProps$c(__spreadValues$f({}, state), {
|
|
2379
2517
|
closeId: action.id
|
|
2380
2518
|
});
|
|
2381
2519
|
default:
|
|
@@ -2426,33 +2564,33 @@ const KitStoreProvider = (props) => {
|
|
|
2426
2564
|
const useKitDispatch = createDispatchHook(ctx);
|
|
2427
2565
|
const useKitSelector = createSelectorHook(ctx);
|
|
2428
2566
|
|
|
2429
|
-
var __defProp$
|
|
2430
|
-
var __defProps$
|
|
2431
|
-
var __getOwnPropDescs$
|
|
2432
|
-
var __getOwnPropSymbols$
|
|
2433
|
-
var __hasOwnProp$
|
|
2434
|
-
var __propIsEnum$
|
|
2435
|
-
var __defNormalProp$
|
|
2436
|
-
var __spreadValues$
|
|
2567
|
+
var __defProp$e = Object.defineProperty;
|
|
2568
|
+
var __defProps$b = Object.defineProperties;
|
|
2569
|
+
var __getOwnPropDescs$b = Object.getOwnPropertyDescriptors;
|
|
2570
|
+
var __getOwnPropSymbols$e = Object.getOwnPropertySymbols;
|
|
2571
|
+
var __hasOwnProp$e = Object.prototype.hasOwnProperty;
|
|
2572
|
+
var __propIsEnum$e = Object.prototype.propertyIsEnumerable;
|
|
2573
|
+
var __defNormalProp$e = (obj, key, value) => key in obj ? __defProp$e(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
2574
|
+
var __spreadValues$e = (a, b) => {
|
|
2437
2575
|
for (var prop in b || (b = {}))
|
|
2438
|
-
if (__hasOwnProp$
|
|
2439
|
-
__defNormalProp$
|
|
2440
|
-
if (__getOwnPropSymbols$
|
|
2441
|
-
for (var prop of __getOwnPropSymbols$
|
|
2442
|
-
if (__propIsEnum$
|
|
2443
|
-
__defNormalProp$
|
|
2576
|
+
if (__hasOwnProp$e.call(b, prop))
|
|
2577
|
+
__defNormalProp$e(a, prop, b[prop]);
|
|
2578
|
+
if (__getOwnPropSymbols$e)
|
|
2579
|
+
for (var prop of __getOwnPropSymbols$e(b)) {
|
|
2580
|
+
if (__propIsEnum$e.call(b, prop))
|
|
2581
|
+
__defNormalProp$e(a, prop, b[prop]);
|
|
2444
2582
|
}
|
|
2445
2583
|
return a;
|
|
2446
2584
|
};
|
|
2447
|
-
var __spreadProps$
|
|
2448
|
-
var __objRest$
|
|
2585
|
+
var __spreadProps$b = (a, b) => __defProps$b(a, __getOwnPropDescs$b(b));
|
|
2586
|
+
var __objRest$5 = (source, exclude) => {
|
|
2449
2587
|
var target = {};
|
|
2450
2588
|
for (var prop in source)
|
|
2451
|
-
if (__hasOwnProp$
|
|
2589
|
+
if (__hasOwnProp$e.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
2452
2590
|
target[prop] = source[prop];
|
|
2453
|
-
if (source != null && __getOwnPropSymbols$
|
|
2454
|
-
for (var prop of __getOwnPropSymbols$
|
|
2455
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
2591
|
+
if (source != null && __getOwnPropSymbols$e)
|
|
2592
|
+
for (var prop of __getOwnPropSymbols$e(source)) {
|
|
2593
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$e.call(source, prop))
|
|
2456
2594
|
target[prop] = source[prop];
|
|
2457
2595
|
}
|
|
2458
2596
|
return target;
|
|
@@ -2478,7 +2616,7 @@ const Modal = (props) => {
|
|
|
2478
2616
|
showCancel = true,
|
|
2479
2617
|
showOk = true,
|
|
2480
2618
|
afterClose
|
|
2481
|
-
} = _a, restProps = __objRest$
|
|
2619
|
+
} = _a, restProps = __objRest$5(_a, [
|
|
2482
2620
|
"error",
|
|
2483
2621
|
"okText",
|
|
2484
2622
|
"cancelText",
|
|
@@ -2533,7 +2671,7 @@ const Modal = (props) => {
|
|
|
2533
2671
|
}
|
|
2534
2672
|
return /* @__PURE__ */ React.createElement(
|
|
2535
2673
|
Modal$1,
|
|
2536
|
-
__spreadProps$
|
|
2674
|
+
__spreadProps$b(__spreadValues$e({
|
|
2537
2675
|
maskClosable,
|
|
2538
2676
|
className: cs(
|
|
2539
2677
|
className,
|
|
@@ -2568,7 +2706,7 @@ const Modal = (props) => {
|
|
|
2568
2706
|
prevText
|
|
2569
2707
|
), error && /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement("span", { className: "modal-error" }, error))), /* @__PURE__ */ React.createElement("div", { className: "modal-footer-btn-group" }, showCancel && /* @__PURE__ */ React.createElement(
|
|
2570
2708
|
Button,
|
|
2571
|
-
__spreadValues$
|
|
2709
|
+
__spreadValues$e({
|
|
2572
2710
|
type: "quiet",
|
|
2573
2711
|
onMouseDown: (e) => {
|
|
2574
2712
|
e.preventDefault();
|
|
@@ -2582,7 +2720,7 @@ const Modal = (props) => {
|
|
|
2582
2720
|
cancelText
|
|
2583
2721
|
), showOk && /* @__PURE__ */ React.createElement(
|
|
2584
2722
|
Button,
|
|
2585
|
-
__spreadValues$
|
|
2723
|
+
__spreadValues$e({
|
|
2586
2724
|
onClick: (e) => {
|
|
2587
2725
|
var _a2, _b2;
|
|
2588
2726
|
onOk == null ? void 0 : onOk(e);
|
|
@@ -2744,46 +2882,46 @@ const Percent = ({
|
|
|
2744
2882
|
return /* @__PURE__ */ React.createElement("span", null, /* @__PURE__ */ React.createElement("span", { className: cx("value", valueClassName) }, value), /* @__PURE__ */ React.createElement("span", { className: cx("unit", unitClassName) }, unit));
|
|
2745
2883
|
};
|
|
2746
2884
|
|
|
2747
|
-
var __defProp$
|
|
2748
|
-
var __getOwnPropSymbols$
|
|
2749
|
-
var __hasOwnProp$
|
|
2750
|
-
var __propIsEnum$
|
|
2751
|
-
var __defNormalProp$
|
|
2752
|
-
var __spreadValues$
|
|
2885
|
+
var __defProp$d = Object.defineProperty;
|
|
2886
|
+
var __getOwnPropSymbols$d = Object.getOwnPropertySymbols;
|
|
2887
|
+
var __hasOwnProp$d = Object.prototype.hasOwnProperty;
|
|
2888
|
+
var __propIsEnum$d = Object.prototype.propertyIsEnumerable;
|
|
2889
|
+
var __defNormalProp$d = (obj, key, value) => key in obj ? __defProp$d(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
2890
|
+
var __spreadValues$d = (a, b) => {
|
|
2753
2891
|
for (var prop in b || (b = {}))
|
|
2754
|
-
if (__hasOwnProp$
|
|
2755
|
-
__defNormalProp$
|
|
2756
|
-
if (__getOwnPropSymbols$
|
|
2757
|
-
for (var prop of __getOwnPropSymbols$
|
|
2758
|
-
if (__propIsEnum$
|
|
2759
|
-
__defNormalProp$
|
|
2892
|
+
if (__hasOwnProp$d.call(b, prop))
|
|
2893
|
+
__defNormalProp$d(a, prop, b[prop]);
|
|
2894
|
+
if (__getOwnPropSymbols$d)
|
|
2895
|
+
for (var prop of __getOwnPropSymbols$d(b)) {
|
|
2896
|
+
if (__propIsEnum$d.call(b, prop))
|
|
2897
|
+
__defNormalProp$d(a, prop, b[prop]);
|
|
2760
2898
|
}
|
|
2761
2899
|
return a;
|
|
2762
2900
|
};
|
|
2763
|
-
const Progress = (props) => /* @__PURE__ */ React.createElement(Progress$1, __spreadValues$
|
|
2901
|
+
const Progress = (props) => /* @__PURE__ */ React.createElement(Progress$1, __spreadValues$d({}, props));
|
|
2764
2902
|
|
|
2765
|
-
var __defProp$
|
|
2766
|
-
var __getOwnPropSymbols$
|
|
2767
|
-
var __hasOwnProp$
|
|
2768
|
-
var __propIsEnum$
|
|
2769
|
-
var __defNormalProp$
|
|
2903
|
+
var __defProp$c = Object.defineProperty;
|
|
2904
|
+
var __getOwnPropSymbols$c = Object.getOwnPropertySymbols;
|
|
2905
|
+
var __hasOwnProp$c = Object.prototype.hasOwnProperty;
|
|
2906
|
+
var __propIsEnum$c = Object.prototype.propertyIsEnumerable;
|
|
2907
|
+
var __defNormalProp$c = (obj, key, value) => key in obj ? __defProp$c(obj, key, {
|
|
2770
2908
|
enumerable: true,
|
|
2771
2909
|
configurable: true,
|
|
2772
2910
|
writable: true,
|
|
2773
2911
|
value
|
|
2774
2912
|
}) : obj[key] = value;
|
|
2775
|
-
var __spreadValues$
|
|
2776
|
-
for (var prop in b || (b = {})) if (__hasOwnProp$
|
|
2777
|
-
if (__getOwnPropSymbols$
|
|
2778
|
-
if (__propIsEnum$
|
|
2913
|
+
var __spreadValues$c = (a, b) => {
|
|
2914
|
+
for (var prop in b || (b = {})) if (__hasOwnProp$c.call(b, prop)) __defNormalProp$c(a, prop, b[prop]);
|
|
2915
|
+
if (__getOwnPropSymbols$c) for (var prop of __getOwnPropSymbols$c(b)) {
|
|
2916
|
+
if (__propIsEnum$c.call(b, prop)) __defNormalProp$c(a, prop, b[prop]);
|
|
2779
2917
|
}
|
|
2780
2918
|
return a;
|
|
2781
2919
|
};
|
|
2782
|
-
var __objRest$
|
|
2920
|
+
var __objRest$4 = (source, exclude) => {
|
|
2783
2921
|
var target = {};
|
|
2784
|
-
for (var prop in source) if (__hasOwnProp$
|
|
2785
|
-
if (source != null && __getOwnPropSymbols$
|
|
2786
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
2922
|
+
for (var prop in source) if (__hasOwnProp$c.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
|
|
2923
|
+
if (source != null && __getOwnPropSymbols$c) for (var prop of __getOwnPropSymbols$c(source)) {
|
|
2924
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$c.call(source, prop)) target[prop] = source[prop];
|
|
2787
2925
|
}
|
|
2788
2926
|
return target;
|
|
2789
2927
|
};
|
|
@@ -2799,7 +2937,7 @@ const Radio = _a => {
|
|
|
2799
2937
|
checked,
|
|
2800
2938
|
compact = false
|
|
2801
2939
|
} = _b,
|
|
2802
|
-
props = __objRest$
|
|
2940
|
+
props = __objRest$4(_b, ["children", "className", "checked", "compact"]);
|
|
2803
2941
|
const {
|
|
2804
2942
|
description
|
|
2805
2943
|
} = props;
|
|
@@ -2809,7 +2947,7 @@ const Radio = _a => {
|
|
|
2809
2947
|
className: cx("radio-description", Typo.Label.l4_regular)
|
|
2810
2948
|
}, description));
|
|
2811
2949
|
}
|
|
2812
|
-
return /* @__PURE__ */React.createElement(React.Fragment, null, /* @__PURE__ */React.createElement(Radio$1, __spreadValues$
|
|
2950
|
+
return /* @__PURE__ */React.createElement(React.Fragment, null, /* @__PURE__ */React.createElement(Radio$1, __spreadValues$c({
|
|
2813
2951
|
className: cx(className, RadioStyle, compact && "compact"),
|
|
2814
2952
|
checked: checked || false,
|
|
2815
2953
|
"data-test": context.name ? `${context.name}-${String(props.value)}` : String(props.value)
|
|
@@ -2821,13 +2959,13 @@ const RadioGroup = _c => {
|
|
|
2821
2959
|
children,
|
|
2822
2960
|
className
|
|
2823
2961
|
} = _d,
|
|
2824
|
-
props = __objRest$
|
|
2962
|
+
props = __objRest$4(_d, ["children", "className"]);
|
|
2825
2963
|
return /* @__PURE__ */React.createElement(KitRadioGroupContext.Provider, {
|
|
2826
2964
|
value: {
|
|
2827
2965
|
disabled: props.disabled,
|
|
2828
2966
|
name: props.name
|
|
2829
2967
|
}
|
|
2830
|
-
}, /* @__PURE__ */React.createElement(Radio$1.Group, __spreadValues$
|
|
2968
|
+
}, /* @__PURE__ */React.createElement(Radio$1.Group, __spreadValues$c({
|
|
2831
2969
|
className: cx(className, RadioGroupStyle)
|
|
2832
2970
|
}, props), children ? children : null));
|
|
2833
2971
|
};
|
|
@@ -2837,7 +2975,7 @@ const RadioButton = _e => {
|
|
|
2837
2975
|
children,
|
|
2838
2976
|
className
|
|
2839
2977
|
} = _f,
|
|
2840
|
-
props = __objRest$
|
|
2978
|
+
props = __objRest$4(_f, ["children", "className"]);
|
|
2841
2979
|
const {
|
|
2842
2980
|
type,
|
|
2843
2981
|
placeholder = "Label",
|
|
@@ -2883,46 +3021,46 @@ const RadioButton = _e => {
|
|
|
2883
3021
|
className: "ant-radio-button-input-label"
|
|
2884
3022
|
}, typeof children === "string" ? children : ""));
|
|
2885
3023
|
};
|
|
2886
|
-
return /* @__PURE__ */React.createElement(Radio$1.Button, __spreadValues$
|
|
3024
|
+
return /* @__PURE__ */React.createElement(Radio$1.Button, __spreadValues$c({
|
|
2887
3025
|
className: cx(className, RadioButtonStyle),
|
|
2888
3026
|
value: radioButtonValue
|
|
2889
3027
|
}, props), renderChildren());
|
|
2890
3028
|
};
|
|
2891
3029
|
|
|
2892
|
-
var __defProp$
|
|
2893
|
-
var __getOwnPropSymbols$
|
|
2894
|
-
var __hasOwnProp$
|
|
2895
|
-
var __propIsEnum$
|
|
2896
|
-
var __defNormalProp$
|
|
2897
|
-
var __spreadValues$
|
|
3030
|
+
var __defProp$b = Object.defineProperty;
|
|
3031
|
+
var __getOwnPropSymbols$b = Object.getOwnPropertySymbols;
|
|
3032
|
+
var __hasOwnProp$b = Object.prototype.hasOwnProperty;
|
|
3033
|
+
var __propIsEnum$b = Object.prototype.propertyIsEnumerable;
|
|
3034
|
+
var __defNormalProp$b = (obj, key, value) => key in obj ? __defProp$b(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
3035
|
+
var __spreadValues$b = (a, b) => {
|
|
2898
3036
|
for (var prop in b || (b = {}))
|
|
2899
|
-
if (__hasOwnProp$
|
|
2900
|
-
__defNormalProp$
|
|
2901
|
-
if (__getOwnPropSymbols$
|
|
2902
|
-
for (var prop of __getOwnPropSymbols$
|
|
2903
|
-
if (__propIsEnum$
|
|
2904
|
-
__defNormalProp$
|
|
3037
|
+
if (__hasOwnProp$b.call(b, prop))
|
|
3038
|
+
__defNormalProp$b(a, prop, b[prop]);
|
|
3039
|
+
if (__getOwnPropSymbols$b)
|
|
3040
|
+
for (var prop of __getOwnPropSymbols$b(b)) {
|
|
3041
|
+
if (__propIsEnum$b.call(b, prop))
|
|
3042
|
+
__defNormalProp$b(a, prop, b[prop]);
|
|
2905
3043
|
}
|
|
2906
3044
|
return a;
|
|
2907
3045
|
};
|
|
2908
|
-
var __objRest$
|
|
3046
|
+
var __objRest$3 = (source, exclude) => {
|
|
2909
3047
|
var target = {};
|
|
2910
3048
|
for (var prop in source)
|
|
2911
|
-
if (__hasOwnProp$
|
|
3049
|
+
if (__hasOwnProp$b.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
2912
3050
|
target[prop] = source[prop];
|
|
2913
|
-
if (source != null && __getOwnPropSymbols$
|
|
2914
|
-
for (var prop of __getOwnPropSymbols$
|
|
2915
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
3051
|
+
if (source != null && __getOwnPropSymbols$b)
|
|
3052
|
+
for (var prop of __getOwnPropSymbols$b(source)) {
|
|
3053
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$b.call(source, prop))
|
|
2916
3054
|
target[prop] = source[prop];
|
|
2917
3055
|
}
|
|
2918
3056
|
return target;
|
|
2919
3057
|
};
|
|
2920
3058
|
const SearchInput = (props) => {
|
|
2921
|
-
const _a = props, { onChange, debounceWait = 300 } = _a, restProps = __objRest$
|
|
3059
|
+
const _a = props, { onChange, debounceWait = 300 } = _a, restProps = __objRest$3(_a, ["onChange", "debounceWait"]);
|
|
2922
3060
|
const onSearch = _.debounce(onChange, debounceWait);
|
|
2923
3061
|
return /* @__PURE__ */ React.createElement(
|
|
2924
3062
|
Input,
|
|
2925
|
-
__spreadValues$
|
|
3063
|
+
__spreadValues$b({
|
|
2926
3064
|
style: { width: 276 },
|
|
2927
3065
|
prefix: /* @__PURE__ */ React.createElement(SearchOutlined, null),
|
|
2928
3066
|
onChange: (e) => onSearch(e.target.value)
|
|
@@ -3030,31 +3168,31 @@ const Speed = ({
|
|
|
3030
3168
|
return /* @__PURE__ */ React.createElement("span", null, /* @__PURE__ */ React.createElement("span", { className: cx("value", valueClassName) }, value), /* @__PURE__ */ React.createElement("span", { className: cx("unit", unitClassName) }, ` ${unit}`));
|
|
3031
3169
|
};
|
|
3032
3170
|
|
|
3033
|
-
var __defProp$
|
|
3034
|
-
var __defProps$
|
|
3035
|
-
var __getOwnPropDescs$
|
|
3036
|
-
var __getOwnPropSymbols$
|
|
3037
|
-
var __hasOwnProp$
|
|
3038
|
-
var __propIsEnum$
|
|
3039
|
-
var __defNormalProp$
|
|
3171
|
+
var __defProp$a = Object.defineProperty;
|
|
3172
|
+
var __defProps$a = Object.defineProperties;
|
|
3173
|
+
var __getOwnPropDescs$a = Object.getOwnPropertyDescriptors;
|
|
3174
|
+
var __getOwnPropSymbols$a = Object.getOwnPropertySymbols;
|
|
3175
|
+
var __hasOwnProp$a = Object.prototype.hasOwnProperty;
|
|
3176
|
+
var __propIsEnum$a = Object.prototype.propertyIsEnumerable;
|
|
3177
|
+
var __defNormalProp$a = (obj, key, value) => key in obj ? __defProp$a(obj, key, {
|
|
3040
3178
|
enumerable: true,
|
|
3041
3179
|
configurable: true,
|
|
3042
3180
|
writable: true,
|
|
3043
3181
|
value
|
|
3044
3182
|
}) : obj[key] = value;
|
|
3045
|
-
var __spreadValues$
|
|
3046
|
-
for (var prop in b || (b = {})) if (__hasOwnProp$
|
|
3047
|
-
if (__getOwnPropSymbols$
|
|
3048
|
-
if (__propIsEnum$
|
|
3183
|
+
var __spreadValues$a = (a, b) => {
|
|
3184
|
+
for (var prop in b || (b = {})) if (__hasOwnProp$a.call(b, prop)) __defNormalProp$a(a, prop, b[prop]);
|
|
3185
|
+
if (__getOwnPropSymbols$a) for (var prop of __getOwnPropSymbols$a(b)) {
|
|
3186
|
+
if (__propIsEnum$a.call(b, prop)) __defNormalProp$a(a, prop, b[prop]);
|
|
3049
3187
|
}
|
|
3050
3188
|
return a;
|
|
3051
3189
|
};
|
|
3052
|
-
var __spreadProps$
|
|
3053
|
-
var __objRest$
|
|
3190
|
+
var __spreadProps$a = (a, b) => __defProps$a(a, __getOwnPropDescs$a(b));
|
|
3191
|
+
var __objRest$2 = (source, exclude) => {
|
|
3054
3192
|
var target = {};
|
|
3055
|
-
for (var prop in source) if (__hasOwnProp$
|
|
3056
|
-
if (source != null && __getOwnPropSymbols$
|
|
3057
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
3193
|
+
for (var prop in source) if (__hasOwnProp$a.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
|
|
3194
|
+
if (source != null && __getOwnPropSymbols$a) for (var prop of __getOwnPropSymbols$a(source)) {
|
|
3195
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$a.call(source, prop)) target[prop] = source[prop];
|
|
3058
3196
|
}
|
|
3059
3197
|
return target;
|
|
3060
3198
|
};
|
|
@@ -3070,46 +3208,46 @@ const Steps = props => {
|
|
|
3070
3208
|
containerClassname,
|
|
3071
3209
|
showStepCount
|
|
3072
3210
|
} = _a,
|
|
3073
|
-
stepsProps = __objRest$
|
|
3211
|
+
stepsProps = __objRest$2(_a, ["stepsConfig", "containerClassname", "showStepCount"]);
|
|
3074
3212
|
const titleWithCount = (_step, count) => /* @__PURE__ */React.createElement(React.Fragment, null, showStepCount ? /* @__PURE__ */React.createElement("span", {
|
|
3075
3213
|
className: "step-count"
|
|
3076
3214
|
}, count) : null, _step.title);
|
|
3077
3215
|
return /* @__PURE__ */React.createElement(StepsContainer, {
|
|
3078
3216
|
className: containerClassname
|
|
3079
|
-
}, /* @__PURE__ */React.createElement(Steps$1, __spreadProps$
|
|
3217
|
+
}, /* @__PURE__ */React.createElement(Steps$1, __spreadProps$a(__spreadValues$a({}, stepsProps), {
|
|
3080
3218
|
type: "default"
|
|
3081
|
-
}), (stepsConfig == null ? void 0 : stepsConfig.length) ? stepsConfig.map((step, index) => /* @__PURE__ */React.createElement(Steps$1.Step, __spreadProps$
|
|
3219
|
+
}), (stepsConfig == null ? void 0 : stepsConfig.length) ? stepsConfig.map((step, index) => /* @__PURE__ */React.createElement(Steps$1.Step, __spreadProps$a(__spreadValues$a({
|
|
3082
3220
|
key: index
|
|
3083
3221
|
}, step), {
|
|
3084
3222
|
title: titleWithCount(step, index + 1)
|
|
3085
3223
|
}))) : props.children));
|
|
3086
3224
|
};
|
|
3087
3225
|
|
|
3088
|
-
var __defProp$
|
|
3089
|
-
var __defProps$
|
|
3090
|
-
var __getOwnPropDescs$
|
|
3091
|
-
var __getOwnPropSymbols$
|
|
3092
|
-
var __hasOwnProp$
|
|
3093
|
-
var __propIsEnum$
|
|
3094
|
-
var __defNormalProp$
|
|
3226
|
+
var __defProp$9 = Object.defineProperty;
|
|
3227
|
+
var __defProps$9 = Object.defineProperties;
|
|
3228
|
+
var __getOwnPropDescs$9 = Object.getOwnPropertyDescriptors;
|
|
3229
|
+
var __getOwnPropSymbols$9 = Object.getOwnPropertySymbols;
|
|
3230
|
+
var __hasOwnProp$9 = Object.prototype.hasOwnProperty;
|
|
3231
|
+
var __propIsEnum$9 = Object.prototype.propertyIsEnumerable;
|
|
3232
|
+
var __defNormalProp$9 = (obj, key, value) => key in obj ? __defProp$9(obj, key, {
|
|
3095
3233
|
enumerable: true,
|
|
3096
3234
|
configurable: true,
|
|
3097
3235
|
writable: true,
|
|
3098
3236
|
value
|
|
3099
3237
|
}) : obj[key] = value;
|
|
3100
|
-
var __spreadValues$
|
|
3101
|
-
for (var prop in b || (b = {})) if (__hasOwnProp$
|
|
3102
|
-
if (__getOwnPropSymbols$
|
|
3103
|
-
if (__propIsEnum$
|
|
3238
|
+
var __spreadValues$9 = (a, b) => {
|
|
3239
|
+
for (var prop in b || (b = {})) if (__hasOwnProp$9.call(b, prop)) __defNormalProp$9(a, prop, b[prop]);
|
|
3240
|
+
if (__getOwnPropSymbols$9) for (var prop of __getOwnPropSymbols$9(b)) {
|
|
3241
|
+
if (__propIsEnum$9.call(b, prop)) __defNormalProp$9(a, prop, b[prop]);
|
|
3104
3242
|
}
|
|
3105
3243
|
return a;
|
|
3106
3244
|
};
|
|
3107
|
-
var __spreadProps$
|
|
3108
|
-
var __objRest = (source, exclude) => {
|
|
3245
|
+
var __spreadProps$9 = (a, b) => __defProps$9(a, __getOwnPropDescs$9(b));
|
|
3246
|
+
var __objRest$1 = (source, exclude) => {
|
|
3109
3247
|
var target = {};
|
|
3110
|
-
for (var prop in source) if (__hasOwnProp$
|
|
3111
|
-
if (source != null && __getOwnPropSymbols$
|
|
3112
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
3248
|
+
for (var prop in source) if (__hasOwnProp$9.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
|
|
3249
|
+
if (source != null && __getOwnPropSymbols$9) for (var prop of __getOwnPropSymbols$9(source)) {
|
|
3250
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$9.call(source, prop)) target[prop] = source[prop];
|
|
3113
3251
|
}
|
|
3114
3252
|
return target;
|
|
3115
3253
|
};
|
|
@@ -3121,7 +3259,7 @@ const Switch = _a => {
|
|
|
3121
3259
|
className,
|
|
3122
3260
|
checked
|
|
3123
3261
|
} = _b,
|
|
3124
|
-
props = __objRest(_b, ["children", "className", "checked"]);
|
|
3262
|
+
props = __objRest$1(_b, ["children", "className", "checked"]);
|
|
3125
3263
|
const Content = /*#__PURE__*/styled('span')({
|
|
3126
3264
|
name: "Content",
|
|
3127
3265
|
class: "c1to9vb9",
|
|
@@ -3129,7 +3267,7 @@ const Switch = _a => {
|
|
|
3129
3267
|
});
|
|
3130
3268
|
const classNames = [className, SwitchStyle, "switch"];
|
|
3131
3269
|
if (props.size === "large") classNames.push("ant-switch-large");
|
|
3132
|
-
return /* @__PURE__ */React.createElement(React.Fragment, null, /* @__PURE__ */React.createElement(Switch$1, __spreadProps$
|
|
3270
|
+
return /* @__PURE__ */React.createElement(React.Fragment, null, /* @__PURE__ */React.createElement(Switch$1, __spreadProps$9(__spreadValues$9({
|
|
3133
3271
|
className: cx(...classNames),
|
|
3134
3272
|
checked: checked || false
|
|
3135
3273
|
}, props), {
|
|
@@ -3215,26 +3353,26 @@ const ColumnTitle = props => {
|
|
|
3215
3353
|
}));
|
|
3216
3354
|
};
|
|
3217
3355
|
|
|
3218
|
-
var __defProp$
|
|
3219
|
-
var __defProps$
|
|
3220
|
-
var __getOwnPropDescs$
|
|
3221
|
-
var __getOwnPropSymbols$
|
|
3222
|
-
var __hasOwnProp$
|
|
3223
|
-
var __propIsEnum$
|
|
3224
|
-
var __defNormalProp$
|
|
3356
|
+
var __defProp$8 = Object.defineProperty;
|
|
3357
|
+
var __defProps$8 = Object.defineProperties;
|
|
3358
|
+
var __getOwnPropDescs$8 = Object.getOwnPropertyDescriptors;
|
|
3359
|
+
var __getOwnPropSymbols$8 = Object.getOwnPropertySymbols;
|
|
3360
|
+
var __hasOwnProp$8 = Object.prototype.hasOwnProperty;
|
|
3361
|
+
var __propIsEnum$8 = Object.prototype.propertyIsEnumerable;
|
|
3362
|
+
var __defNormalProp$8 = (obj, key, value) => key in obj ? __defProp$8(obj, key, {
|
|
3225
3363
|
enumerable: true,
|
|
3226
3364
|
configurable: true,
|
|
3227
3365
|
writable: true,
|
|
3228
3366
|
value
|
|
3229
3367
|
}) : obj[key] = value;
|
|
3230
|
-
var __spreadValues$
|
|
3231
|
-
for (var prop in b || (b = {})) if (__hasOwnProp$
|
|
3232
|
-
if (__getOwnPropSymbols$
|
|
3233
|
-
if (__propIsEnum$
|
|
3368
|
+
var __spreadValues$8 = (a, b) => {
|
|
3369
|
+
for (var prop in b || (b = {})) if (__hasOwnProp$8.call(b, prop)) __defNormalProp$8(a, prop, b[prop]);
|
|
3370
|
+
if (__getOwnPropSymbols$8) for (var prop of __getOwnPropSymbols$8(b)) {
|
|
3371
|
+
if (__propIsEnum$8.call(b, prop)) __defNormalProp$8(a, prop, b[prop]);
|
|
3234
3372
|
}
|
|
3235
3373
|
return a;
|
|
3236
3374
|
};
|
|
3237
|
-
var __spreadProps$
|
|
3375
|
+
var __spreadProps$8 = (a, b) => __defProps$8(a, __getOwnPropDescs$8(b));
|
|
3238
3376
|
const TableContainerStyle = "t1upn1sz";
|
|
3239
3377
|
const tableStyleCover = "tta5kd2";
|
|
3240
3378
|
const Table = props => {
|
|
@@ -3260,7 +3398,7 @@ const Table = props => {
|
|
|
3260
3398
|
const orderRef = useRef(null);
|
|
3261
3399
|
const hasScrollBard = useTableBodyHasScrollBar(wrapper, dataSource);
|
|
3262
3400
|
const _columns = useMemo(() => columns.map(column => {
|
|
3263
|
-
const _column = __spreadValues$
|
|
3401
|
+
const _column = __spreadValues$8({}, column);
|
|
3264
3402
|
if (_column.sorter) {
|
|
3265
3403
|
_column.title = /* @__PURE__ */React.createElement(ColumnTitle, {
|
|
3266
3404
|
title: column.title,
|
|
@@ -3302,14 +3440,896 @@ const Table = props => {
|
|
|
3302
3440
|
}),
|
|
3303
3441
|
rowClassName,
|
|
3304
3442
|
scroll,
|
|
3305
|
-
rowSelection: rowSelection && __spreadProps$
|
|
3443
|
+
rowSelection: rowSelection && __spreadProps$8(__spreadValues$8({}, rowSelection), {
|
|
3306
3444
|
columnWidth: 32
|
|
3307
3445
|
}),
|
|
3308
3446
|
showSorterTooltip: false
|
|
3309
3447
|
}));
|
|
3310
3448
|
};
|
|
3311
3449
|
|
|
3312
|
-
const
|
|
3450
|
+
const TitleStyle = "tc40oxa";
|
|
3451
|
+
const SubtitleStyle = "sa410aw";
|
|
3452
|
+
const BodyCellTextStyle = "b1lc7yin";
|
|
3453
|
+
const BodyCellTextWrapper = /*#__PURE__*/styled('div')({
|
|
3454
|
+
name: "BodyCellTextWrapper",
|
|
3455
|
+
class: "b1jhbz3e",
|
|
3456
|
+
propsAsIs: false
|
|
3457
|
+
});
|
|
3458
|
+
const TableFormWrapper = /*#__PURE__*/styled('div')({
|
|
3459
|
+
name: "TableFormWrapper",
|
|
3460
|
+
class: "tyua489",
|
|
3461
|
+
propsAsIs: false
|
|
3462
|
+
});
|
|
3463
|
+
const AddRowButtonWrapper = /*#__PURE__*/styled('div')({
|
|
3464
|
+
name: "AddRowButtonWrapper",
|
|
3465
|
+
class: "a1ccrot9",
|
|
3466
|
+
propsAsIs: false
|
|
3467
|
+
});
|
|
3468
|
+
const DraggableHandleWrapper = /*#__PURE__*/styled('div')({
|
|
3469
|
+
name: "DraggableHandleWrapper",
|
|
3470
|
+
class: "d8c9v9g",
|
|
3471
|
+
propsAsIs: false
|
|
3472
|
+
});
|
|
3473
|
+
|
|
3474
|
+
function increaseLastNumber(str, num) {
|
|
3475
|
+
const lastNumberMatch = str.match(/(\d+)$/);
|
|
3476
|
+
if (!lastNumberMatch) {
|
|
3477
|
+
return str;
|
|
3478
|
+
}
|
|
3479
|
+
const prefix = str.slice(0, lastNumberMatch.index);
|
|
3480
|
+
const lastNumber = lastNumberMatch[1];
|
|
3481
|
+
let newLastNumber;
|
|
3482
|
+
if (Number.isSafeInteger(Number(str) + num)) {
|
|
3483
|
+
newLastNumber = Number(str) + num;
|
|
3484
|
+
}
|
|
3485
|
+
newLastNumber = (BigInt(lastNumber) + BigInt(num)).toString();
|
|
3486
|
+
return `${prefix}${newLastNumber}`;
|
|
3487
|
+
}
|
|
3488
|
+
const genEmptyRow = (columns) => {
|
|
3489
|
+
const row = {};
|
|
3490
|
+
columns.forEach((col) => {
|
|
3491
|
+
row[col.key] = col.defaultValue;
|
|
3492
|
+
});
|
|
3493
|
+
return row;
|
|
3494
|
+
};
|
|
3495
|
+
const moveItemInArray = (array, fromIndex, toIndex) => {
|
|
3496
|
+
const arrLength = array.length;
|
|
3497
|
+
const sortArr = [...array];
|
|
3498
|
+
if (fromIndex > -1 && fromIndex < arrLength) {
|
|
3499
|
+
const moveItem = sortArr.splice(fromIndex, 1)[0];
|
|
3500
|
+
sortArr.splice(toIndex, 0, moveItem);
|
|
3501
|
+
}
|
|
3502
|
+
return sortArr;
|
|
3503
|
+
};
|
|
3504
|
+
|
|
3505
|
+
var __defProp$7 = Object.defineProperty;
|
|
3506
|
+
var __defProps$7 = Object.defineProperties;
|
|
3507
|
+
var __getOwnPropDescs$7 = Object.getOwnPropertyDescriptors;
|
|
3508
|
+
var __getOwnPropSymbols$7 = Object.getOwnPropertySymbols;
|
|
3509
|
+
var __hasOwnProp$7 = Object.prototype.hasOwnProperty;
|
|
3510
|
+
var __propIsEnum$7 = Object.prototype.propertyIsEnumerable;
|
|
3511
|
+
var __defNormalProp$7 = (obj, key, value) => key in obj ? __defProp$7(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
3512
|
+
var __spreadValues$7 = (a, b) => {
|
|
3513
|
+
for (var prop in b || (b = {}))
|
|
3514
|
+
if (__hasOwnProp$7.call(b, prop))
|
|
3515
|
+
__defNormalProp$7(a, prop, b[prop]);
|
|
3516
|
+
if (__getOwnPropSymbols$7)
|
|
3517
|
+
for (var prop of __getOwnPropSymbols$7(b)) {
|
|
3518
|
+
if (__propIsEnum$7.call(b, prop))
|
|
3519
|
+
__defNormalProp$7(a, prop, b[prop]);
|
|
3520
|
+
}
|
|
3521
|
+
return a;
|
|
3522
|
+
};
|
|
3523
|
+
var __spreadProps$7 = (a, b) => __defProps$7(a, __getOwnPropDescs$7(b));
|
|
3524
|
+
var __objRest = (source, exclude) => {
|
|
3525
|
+
var target = {};
|
|
3526
|
+
for (var prop in source)
|
|
3527
|
+
if (__hasOwnProp$7.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
3528
|
+
target[prop] = source[prop];
|
|
3529
|
+
if (source != null && __getOwnPropSymbols$7)
|
|
3530
|
+
for (var prop of __getOwnPropSymbols$7(source)) {
|
|
3531
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$7.call(source, prop))
|
|
3532
|
+
target[prop] = source[prop];
|
|
3533
|
+
}
|
|
3534
|
+
return target;
|
|
3535
|
+
};
|
|
3536
|
+
const AddRowButton = (props) => {
|
|
3537
|
+
const {
|
|
3538
|
+
config: { maximum, className, CustomizedButton, buttonProps, text },
|
|
3539
|
+
columns,
|
|
3540
|
+
updateData,
|
|
3541
|
+
data
|
|
3542
|
+
} = props;
|
|
3543
|
+
const _a = buttonProps || {}, {
|
|
3544
|
+
disabled: disabledFromProp,
|
|
3545
|
+
onClick
|
|
3546
|
+
} = _a, restButtonProps = __objRest(_a, [
|
|
3547
|
+
"disabled",
|
|
3548
|
+
"onClick"
|
|
3549
|
+
]);
|
|
3550
|
+
const onAdd = (e, data2) => {
|
|
3551
|
+
const newData = [...data2];
|
|
3552
|
+
const newRow = genEmptyRow(columns);
|
|
3553
|
+
newData.push(newRow);
|
|
3554
|
+
updateData(newData);
|
|
3555
|
+
onClick == null ? void 0 : onClick(e);
|
|
3556
|
+
};
|
|
3557
|
+
const disabled = useMemo(
|
|
3558
|
+
() => disabledFromProp || typeof maximum === "number" && maximum <= data.length,
|
|
3559
|
+
[maximum, data.length, disabledFromProp]
|
|
3560
|
+
);
|
|
3561
|
+
const CustomizedButtonText = useMemo(() => {
|
|
3562
|
+
if (!text)
|
|
3563
|
+
return null;
|
|
3564
|
+
if (typeof text === "string")
|
|
3565
|
+
return text;
|
|
3566
|
+
return text();
|
|
3567
|
+
}, [text]);
|
|
3568
|
+
if (!columns.length) {
|
|
3569
|
+
return null;
|
|
3570
|
+
}
|
|
3571
|
+
return CustomizedButton ? /* @__PURE__ */ React.createElement(CustomizedButton, __spreadValues$7({}, props)) : /* @__PURE__ */ React.createElement(AddRowButtonWrapper, { className }, /* @__PURE__ */ React.createElement(
|
|
3572
|
+
Button,
|
|
3573
|
+
__spreadProps$7(__spreadValues$7({}, restButtonProps), {
|
|
3574
|
+
type: restButtonProps.type || "ordinary",
|
|
3575
|
+
size: restButtonProps.size || "small",
|
|
3576
|
+
icon: restButtonProps.icon || /* @__PURE__ */ React.createElement(PlusOutlined, null),
|
|
3577
|
+
className: cx(Typo.Label.l3_regular, restButtonProps.className),
|
|
3578
|
+
onClick: (e) => {
|
|
3579
|
+
onAdd(e, data);
|
|
3580
|
+
},
|
|
3581
|
+
disabled
|
|
3582
|
+
}),
|
|
3583
|
+
CustomizedButtonText || parrotI18n.t("components.add")
|
|
3584
|
+
), typeof maximum === "number" ? /* @__PURE__ */ React.createElement(
|
|
3585
|
+
"span",
|
|
3586
|
+
{
|
|
3587
|
+
className: cx(
|
|
3588
|
+
Typo.Label.l4_regular,
|
|
3589
|
+
"maximum-desc",
|
|
3590
|
+
disabled && "disabled"
|
|
3591
|
+
)
|
|
3592
|
+
},
|
|
3593
|
+
parrotI18n.t("components.maximum_row_count_desc", {
|
|
3594
|
+
count: maximum
|
|
3595
|
+
})
|
|
3596
|
+
) : null);
|
|
3597
|
+
};
|
|
3598
|
+
|
|
3599
|
+
const AffixColumnHeaderCell = ({ data, column, onChange, onBlur }) => {
|
|
3600
|
+
const [suffix, setSuffix] = useState("");
|
|
3601
|
+
const [prefix, setPrefix] = useState("");
|
|
3602
|
+
const onPrefixChange = useCallback(
|
|
3603
|
+
(e) => {
|
|
3604
|
+
const newPrefix = e.target.value;
|
|
3605
|
+
setPrefix(newPrefix);
|
|
3606
|
+
onChange(newPrefix + suffix);
|
|
3607
|
+
},
|
|
3608
|
+
[suffix, onChange]
|
|
3609
|
+
);
|
|
3610
|
+
const onSuffixChange = useCallback(
|
|
3611
|
+
(e) => {
|
|
3612
|
+
const newSuffix = e.target.value;
|
|
3613
|
+
setSuffix(newSuffix);
|
|
3614
|
+
onChange(prefix + newSuffix);
|
|
3615
|
+
},
|
|
3616
|
+
[prefix, onChange]
|
|
3617
|
+
);
|
|
3618
|
+
return /* @__PURE__ */ React.createElement(Space, null, !column.disablePrefix ? /* @__PURE__ */ React.createElement(
|
|
3619
|
+
Input$1,
|
|
3620
|
+
{
|
|
3621
|
+
value: prefix,
|
|
3622
|
+
placeholder: parrotI18n.t("components.prefix"),
|
|
3623
|
+
size: "small",
|
|
3624
|
+
onChange: onPrefixChange,
|
|
3625
|
+
onBlur
|
|
3626
|
+
}
|
|
3627
|
+
) : void 0, !column.disableSuffix ? /* @__PURE__ */ React.createElement(
|
|
3628
|
+
Input$1,
|
|
3629
|
+
{
|
|
3630
|
+
value: suffix,
|
|
3631
|
+
placeholder: parrotI18n.t("components.suffix"),
|
|
3632
|
+
size: "small",
|
|
3633
|
+
onChange: onSuffixChange,
|
|
3634
|
+
onBlur
|
|
3635
|
+
}
|
|
3636
|
+
) : void 0);
|
|
3637
|
+
};
|
|
3638
|
+
|
|
3639
|
+
const CheckboxColumnBodyCell = ({ data, column, index, onChange }) => {
|
|
3640
|
+
const value = data[index][column.key] === void 0 ? column.defaultValue : data[index][column.key];
|
|
3641
|
+
const _onChange = useCallback(
|
|
3642
|
+
(e) => {
|
|
3643
|
+
onChange(e.target.checked);
|
|
3644
|
+
},
|
|
3645
|
+
[onChange]
|
|
3646
|
+
);
|
|
3647
|
+
const defaultChecked = column.defaultValue;
|
|
3648
|
+
return /* @__PURE__ */ React.createElement(
|
|
3649
|
+
Checkbox$1,
|
|
3650
|
+
{
|
|
3651
|
+
checked: value,
|
|
3652
|
+
onChange: _onChange,
|
|
3653
|
+
defaultChecked
|
|
3654
|
+
}
|
|
3655
|
+
);
|
|
3656
|
+
};
|
|
3657
|
+
|
|
3658
|
+
var __defProp$6 = Object.defineProperty;
|
|
3659
|
+
var __defProps$6 = Object.defineProperties;
|
|
3660
|
+
var __getOwnPropDescs$6 = Object.getOwnPropertyDescriptors;
|
|
3661
|
+
var __getOwnPropSymbols$6 = Object.getOwnPropertySymbols;
|
|
3662
|
+
var __hasOwnProp$6 = Object.prototype.hasOwnProperty;
|
|
3663
|
+
var __propIsEnum$6 = Object.prototype.propertyIsEnumerable;
|
|
3664
|
+
var __defNormalProp$6 = (obj, key, value) => key in obj ? __defProp$6(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
3665
|
+
var __spreadValues$6 = (a, b) => {
|
|
3666
|
+
for (var prop in b || (b = {}))
|
|
3667
|
+
if (__hasOwnProp$6.call(b, prop))
|
|
3668
|
+
__defNormalProp$6(a, prop, b[prop]);
|
|
3669
|
+
if (__getOwnPropSymbols$6)
|
|
3670
|
+
for (var prop of __getOwnPropSymbols$6(b)) {
|
|
3671
|
+
if (__propIsEnum$6.call(b, prop))
|
|
3672
|
+
__defNormalProp$6(a, prop, b[prop]);
|
|
3673
|
+
}
|
|
3674
|
+
return a;
|
|
3675
|
+
};
|
|
3676
|
+
var __spreadProps$6 = (a, b) => __defProps$6(a, __getOwnPropDescs$6(b));
|
|
3677
|
+
const InputPassword = (props) => {
|
|
3678
|
+
const [showPassword, setShowPassword] = useState(false);
|
|
3679
|
+
useEffect(() => {
|
|
3680
|
+
if (props.visible !== void 0) {
|
|
3681
|
+
setShowPassword(props.visible);
|
|
3682
|
+
}
|
|
3683
|
+
}, [props.visible]);
|
|
3684
|
+
const toggleShowPassword = () => {
|
|
3685
|
+
var _a;
|
|
3686
|
+
setShowPassword(!showPassword);
|
|
3687
|
+
(_a = props == null ? void 0 : props.onVisibleChange) == null ? void 0 : _a.call(props, !showPassword);
|
|
3688
|
+
};
|
|
3689
|
+
const inputType = showPassword ? "text" : "password";
|
|
3690
|
+
return /* @__PURE__ */ React.createElement(
|
|
3691
|
+
Input$1,
|
|
3692
|
+
__spreadProps$6(__spreadValues$6({}, props), {
|
|
3693
|
+
type: inputType,
|
|
3694
|
+
suffix: showPassword ? /* @__PURE__ */ React.createElement(
|
|
3695
|
+
EyeOutlined,
|
|
3696
|
+
{
|
|
3697
|
+
className: "ant-input-password-icon",
|
|
3698
|
+
onClick: toggleShowPassword
|
|
3699
|
+
}
|
|
3700
|
+
) : /* @__PURE__ */ React.createElement(
|
|
3701
|
+
EyeInvisibleOutlined,
|
|
3702
|
+
{
|
|
3703
|
+
className: "ant-input-password-icon",
|
|
3704
|
+
onClick: toggleShowPassword
|
|
3705
|
+
}
|
|
3706
|
+
)
|
|
3707
|
+
})
|
|
3708
|
+
);
|
|
3709
|
+
};
|
|
3710
|
+
const CustomInput = (props) => {
|
|
3711
|
+
if (props.type === "password") {
|
|
3712
|
+
return /* @__PURE__ */ React.createElement(InputPassword, __spreadValues$6({}, props));
|
|
3713
|
+
}
|
|
3714
|
+
return /* @__PURE__ */ React.createElement(Input$1, __spreadValues$6({}, props));
|
|
3715
|
+
};
|
|
3716
|
+
const InputColumnHeaderCell = ({ disabled, column, onChange, onBlur, onVisibleChange }) => {
|
|
3717
|
+
const _onChange = (e) => {
|
|
3718
|
+
const newValue = e.target.value;
|
|
3719
|
+
onChange(newValue);
|
|
3720
|
+
};
|
|
3721
|
+
return /* @__PURE__ */ React.createElement(
|
|
3722
|
+
CustomInput,
|
|
3723
|
+
{
|
|
3724
|
+
type: column.type,
|
|
3725
|
+
placeholder: column.placeholder,
|
|
3726
|
+
disabled,
|
|
3727
|
+
size: "small",
|
|
3728
|
+
onChange: _onChange,
|
|
3729
|
+
onBlur,
|
|
3730
|
+
onVisibleChange
|
|
3731
|
+
}
|
|
3732
|
+
);
|
|
3733
|
+
};
|
|
3734
|
+
const InputColumnBodyCell = ({
|
|
3735
|
+
data,
|
|
3736
|
+
latestData,
|
|
3737
|
+
column,
|
|
3738
|
+
index,
|
|
3739
|
+
disabled,
|
|
3740
|
+
onChange,
|
|
3741
|
+
onBlur,
|
|
3742
|
+
visible
|
|
3743
|
+
}) => {
|
|
3744
|
+
const placeHolderValue = column.type === "password" ? "" : latestData[index][column.key];
|
|
3745
|
+
const _onChange = (e) => {
|
|
3746
|
+
const newValue = e.target.value;
|
|
3747
|
+
onChange(newValue);
|
|
3748
|
+
};
|
|
3749
|
+
return /* @__PURE__ */ React.createElement(
|
|
3750
|
+
CustomInput,
|
|
3751
|
+
{
|
|
3752
|
+
size: "small",
|
|
3753
|
+
value: data[index][column.key],
|
|
3754
|
+
type: column.type,
|
|
3755
|
+
defaultValue: column.defaultValue,
|
|
3756
|
+
disabled,
|
|
3757
|
+
placeholder: placeHolderValue || column.placeholder,
|
|
3758
|
+
onChange: _onChange,
|
|
3759
|
+
onBlur,
|
|
3760
|
+
visible
|
|
3761
|
+
}
|
|
3762
|
+
);
|
|
3763
|
+
};
|
|
3764
|
+
|
|
3765
|
+
const TextColumnHeaderCell = ({
|
|
3766
|
+
column
|
|
3767
|
+
}) => {
|
|
3768
|
+
return /* @__PURE__ */ React.createElement(
|
|
3769
|
+
"p",
|
|
3770
|
+
{
|
|
3771
|
+
className: cx(Typo.Label.l4_regular, SubtitleStyle, column.subTitleColor)
|
|
3772
|
+
},
|
|
3773
|
+
column.subTitle
|
|
3774
|
+
);
|
|
3775
|
+
};
|
|
3776
|
+
const TextColumnBodyCell = ({
|
|
3777
|
+
data,
|
|
3778
|
+
column,
|
|
3779
|
+
index
|
|
3780
|
+
}) => {
|
|
3781
|
+
const text = column.displayText || data[index][column.key];
|
|
3782
|
+
const CellDescription = useMemo(() => {
|
|
3783
|
+
var _a, _b;
|
|
3784
|
+
const Result = (_b = (_a = column.renderDescription) == null ? void 0 : _a.call(column, {
|
|
3785
|
+
rowIndex: index,
|
|
3786
|
+
rowData: data[index]
|
|
3787
|
+
})) != null ? _b : null;
|
|
3788
|
+
return typeof Result === "string" ? /* @__PURE__ */ React.createElement("p", { className: cx(Typo.Label.l4_regular, "cell-description") }, Result) : Result;
|
|
3789
|
+
}, [index, data, column]);
|
|
3790
|
+
const Text = useMemo(
|
|
3791
|
+
() => /* @__PURE__ */ React.createElement("p", { className: cx(Typo.Label.l3_regular, BodyCellTextStyle) }, text),
|
|
3792
|
+
[text]
|
|
3793
|
+
);
|
|
3794
|
+
return /* @__PURE__ */ React.createElement(
|
|
3795
|
+
BodyCellTextWrapper,
|
|
3796
|
+
{
|
|
3797
|
+
className: !!CellDescription ? "with-description" : void 0
|
|
3798
|
+
},
|
|
3799
|
+
Text,
|
|
3800
|
+
CellDescription
|
|
3801
|
+
);
|
|
3802
|
+
};
|
|
3803
|
+
|
|
3804
|
+
const ColumnHeaderImpls = {
|
|
3805
|
+
text: TextColumnHeaderCell,
|
|
3806
|
+
input: InputColumnHeaderCell,
|
|
3807
|
+
password: InputColumnHeaderCell,
|
|
3808
|
+
affix: AffixColumnHeaderCell,
|
|
3809
|
+
checkbox: TextColumnHeaderCell
|
|
3810
|
+
};
|
|
3811
|
+
const ColumnBodyImpls = {
|
|
3812
|
+
text: TextColumnBodyCell,
|
|
3813
|
+
input: InputColumnBodyCell,
|
|
3814
|
+
password: InputColumnBodyCell,
|
|
3815
|
+
affix: InputColumnBodyCell,
|
|
3816
|
+
checkbox: CheckboxColumnBodyCell
|
|
3817
|
+
};
|
|
3818
|
+
|
|
3819
|
+
const FormItemStyle = "feau332";
|
|
3820
|
+
const FormItem = props => {
|
|
3821
|
+
const {
|
|
3822
|
+
validateStatus,
|
|
3823
|
+
message,
|
|
3824
|
+
children
|
|
3825
|
+
} = props;
|
|
3826
|
+
return /* @__PURE__ */React.createElement(Form.Item, {
|
|
3827
|
+
className: FormItemStyle,
|
|
3828
|
+
validateStatus,
|
|
3829
|
+
help: validateStatus ? message : ""
|
|
3830
|
+
}, children);
|
|
3831
|
+
};
|
|
3832
|
+
|
|
3833
|
+
var __defProp$5 = Object.defineProperty;
|
|
3834
|
+
var __defProps$5 = Object.defineProperties;
|
|
3835
|
+
var __getOwnPropDescs$5 = Object.getOwnPropertyDescriptors;
|
|
3836
|
+
var __getOwnPropSymbols$5 = Object.getOwnPropertySymbols;
|
|
3837
|
+
var __hasOwnProp$5 = Object.prototype.hasOwnProperty;
|
|
3838
|
+
var __propIsEnum$5 = Object.prototype.propertyIsEnumerable;
|
|
3839
|
+
var __defNormalProp$5 = (obj, key, value) => key in obj ? __defProp$5(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
3840
|
+
var __spreadValues$5 = (a, b) => {
|
|
3841
|
+
for (var prop in b || (b = {}))
|
|
3842
|
+
if (__hasOwnProp$5.call(b, prop))
|
|
3843
|
+
__defNormalProp$5(a, prop, b[prop]);
|
|
3844
|
+
if (__getOwnPropSymbols$5)
|
|
3845
|
+
for (var prop of __getOwnPropSymbols$5(b)) {
|
|
3846
|
+
if (__propIsEnum$5.call(b, prop))
|
|
3847
|
+
__defNormalProp$5(a, prop, b[prop]);
|
|
3848
|
+
}
|
|
3849
|
+
return a;
|
|
3850
|
+
};
|
|
3851
|
+
var __spreadProps$5 = (a, b) => __defProps$5(a, __getOwnPropDescs$5(b));
|
|
3852
|
+
const TableFormBodyCell = (props) => {
|
|
3853
|
+
const {
|
|
3854
|
+
column,
|
|
3855
|
+
disabled,
|
|
3856
|
+
index: rowIndex,
|
|
3857
|
+
data,
|
|
3858
|
+
onChange,
|
|
3859
|
+
latestData,
|
|
3860
|
+
isRowError,
|
|
3861
|
+
onBlur
|
|
3862
|
+
} = props;
|
|
3863
|
+
const width = typeof column.width === "number" ? column.width + "px" : column.width;
|
|
3864
|
+
const _onChange = useCallback(
|
|
3865
|
+
(value, data2) => {
|
|
3866
|
+
const newData = data2.map(
|
|
3867
|
+
(row, i) => i === rowIndex ? __spreadProps$5(__spreadValues$5({}, row), { [column.key]: value }) : row
|
|
3868
|
+
);
|
|
3869
|
+
onChange == null ? void 0 : onChange(newData, rowIndex, column.key);
|
|
3870
|
+
},
|
|
3871
|
+
[rowIndex, onChange, column]
|
|
3872
|
+
);
|
|
3873
|
+
const _onBlur = useCallback(() => {
|
|
3874
|
+
onBlur == null ? void 0 : onBlur(data, rowIndex, column.key);
|
|
3875
|
+
}, [rowIndex, column, onBlur, data]);
|
|
3876
|
+
const renderDefaultComponent = () => {
|
|
3877
|
+
if (!column.type)
|
|
3878
|
+
return null;
|
|
3879
|
+
const CellComponent = ColumnBodyImpls[column.type];
|
|
3880
|
+
return /* @__PURE__ */ React.createElement(
|
|
3881
|
+
CellComponent,
|
|
3882
|
+
__spreadProps$5(__spreadValues$5({}, props), {
|
|
3883
|
+
customData: column.customData,
|
|
3884
|
+
onChange: (val) => {
|
|
3885
|
+
_onChange(val, data);
|
|
3886
|
+
},
|
|
3887
|
+
onBlur: _onBlur
|
|
3888
|
+
})
|
|
3889
|
+
);
|
|
3890
|
+
};
|
|
3891
|
+
const Cell = column.render ? column.render({
|
|
3892
|
+
isHeader: false,
|
|
3893
|
+
disabled,
|
|
3894
|
+
placeholder: props.placeholderValue || latestData[rowIndex][column.key],
|
|
3895
|
+
value: data[rowIndex][column.key],
|
|
3896
|
+
onChange: (val) => {
|
|
3897
|
+
_onChange(val, data);
|
|
3898
|
+
},
|
|
3899
|
+
onBlur: _onBlur,
|
|
3900
|
+
rowIndex
|
|
3901
|
+
}) : renderDefaultComponent();
|
|
3902
|
+
const CellDescription = useMemo(() => {
|
|
3903
|
+
var _a;
|
|
3904
|
+
if (column.type === "text")
|
|
3905
|
+
return null;
|
|
3906
|
+
const Result = ((_a = column.renderDescription) == null ? void 0 : _a.call(column, {
|
|
3907
|
+
rowIndex,
|
|
3908
|
+
rowData: data[rowIndex],
|
|
3909
|
+
latestData
|
|
3910
|
+
})) || null;
|
|
3911
|
+
return typeof Result === "string" ? /* @__PURE__ */ React.createElement("p", { className: cx(Typo.Label.l4_regular, "cell-description") }, Result) : Result;
|
|
3912
|
+
}, [rowIndex, data, latestData, column]);
|
|
3913
|
+
const validateResult = useMemo(() => {
|
|
3914
|
+
var _a;
|
|
3915
|
+
if (isRowError) {
|
|
3916
|
+
return {
|
|
3917
|
+
msg: "",
|
|
3918
|
+
isError: true
|
|
3919
|
+
};
|
|
3920
|
+
}
|
|
3921
|
+
const value = data[rowIndex][column.key];
|
|
3922
|
+
const result = (_a = column.validator) == null ? void 0 : _a.call(column, {
|
|
3923
|
+
value,
|
|
3924
|
+
rowIndex,
|
|
3925
|
+
rowData: data[rowIndex]
|
|
3926
|
+
});
|
|
3927
|
+
if (typeof result === "string" && result) {
|
|
3928
|
+
return { msg: result, isError: true };
|
|
3929
|
+
}
|
|
3930
|
+
}, [data, column, rowIndex, isRowError]);
|
|
3931
|
+
return /* @__PURE__ */ React.createElement(
|
|
3932
|
+
"div",
|
|
3933
|
+
{
|
|
3934
|
+
className: cx("eagle-table-form-cell", `align-${column.align || "left"}`),
|
|
3935
|
+
style: {
|
|
3936
|
+
maxWidth: column.width ? width : "",
|
|
3937
|
+
minWidth: column.width ? width : "",
|
|
3938
|
+
visibility: column.hidden ? "hidden" : "visible"
|
|
3939
|
+
}
|
|
3940
|
+
},
|
|
3941
|
+
/* @__PURE__ */ React.createElement(
|
|
3942
|
+
FormItem,
|
|
3943
|
+
{
|
|
3944
|
+
validateStatus: (validateResult == null ? void 0 : validateResult.isError) ? "error" : "",
|
|
3945
|
+
message: (validateResult == null ? void 0 : validateResult.isError) && validateResult.msg ? validateResult.msg : void 0
|
|
3946
|
+
},
|
|
3947
|
+
Cell
|
|
3948
|
+
),
|
|
3949
|
+
CellDescription
|
|
3950
|
+
);
|
|
3951
|
+
};
|
|
3952
|
+
|
|
3953
|
+
var __defProp$4 = Object.defineProperty;
|
|
3954
|
+
var __defProps$4 = Object.defineProperties;
|
|
3955
|
+
var __getOwnPropDescs$4 = Object.getOwnPropertyDescriptors;
|
|
3956
|
+
var __getOwnPropSymbols$4 = Object.getOwnPropertySymbols;
|
|
3957
|
+
var __hasOwnProp$4 = Object.prototype.hasOwnProperty;
|
|
3958
|
+
var __propIsEnum$4 = Object.prototype.propertyIsEnumerable;
|
|
3959
|
+
var __defNormalProp$4 = (obj, key, value) => key in obj ? __defProp$4(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
3960
|
+
var __spreadValues$4 = (a, b) => {
|
|
3961
|
+
for (var prop in b || (b = {}))
|
|
3962
|
+
if (__hasOwnProp$4.call(b, prop))
|
|
3963
|
+
__defNormalProp$4(a, prop, b[prop]);
|
|
3964
|
+
if (__getOwnPropSymbols$4)
|
|
3965
|
+
for (var prop of __getOwnPropSymbols$4(b)) {
|
|
3966
|
+
if (__propIsEnum$4.call(b, prop))
|
|
3967
|
+
__defNormalProp$4(a, prop, b[prop]);
|
|
3968
|
+
}
|
|
3969
|
+
return a;
|
|
3970
|
+
};
|
|
3971
|
+
var __spreadProps$4 = (a, b) => __defProps$4(a, __getOwnPropDescs$4(b));
|
|
3972
|
+
const TableFormRow = (props) => {
|
|
3973
|
+
const {
|
|
3974
|
+
data,
|
|
3975
|
+
columns,
|
|
3976
|
+
latestData,
|
|
3977
|
+
disabled,
|
|
3978
|
+
passwordVisible,
|
|
3979
|
+
deletable,
|
|
3980
|
+
draggable,
|
|
3981
|
+
rowIndex,
|
|
3982
|
+
provided,
|
|
3983
|
+
snapshot,
|
|
3984
|
+
updateData,
|
|
3985
|
+
onBodyBlur,
|
|
3986
|
+
renderRowDescription,
|
|
3987
|
+
rowValidator
|
|
3988
|
+
} = props;
|
|
3989
|
+
const rowData = data[rowIndex];
|
|
3990
|
+
const deleteRow = (index, data2) => {
|
|
3991
|
+
const newData = [...data2];
|
|
3992
|
+
newData.splice(index, 1);
|
|
3993
|
+
updateData(newData);
|
|
3994
|
+
};
|
|
3995
|
+
const getRowActions = (index, rowDeletable) => {
|
|
3996
|
+
const isRowDeleteDisabled = rowDeletable === false;
|
|
3997
|
+
const DeleteIcon = /* @__PURE__ */ React.createElement(
|
|
3998
|
+
Icon,
|
|
3999
|
+
{
|
|
4000
|
+
className: cx("delete-row-icon", isRowDeleteDisabled && "disabled"),
|
|
4001
|
+
src: XmarkRemove16SecondaryIcon,
|
|
4002
|
+
hoverSrc: isRowDeleteDisabled ? void 0 : XmarkRemove16RegularRedIcon,
|
|
4003
|
+
onClick: () => {
|
|
4004
|
+
if (isRowDeleteDisabled)
|
|
4005
|
+
return;
|
|
4006
|
+
deleteRow(index, data);
|
|
4007
|
+
}
|
|
4008
|
+
}
|
|
4009
|
+
);
|
|
4010
|
+
const FinalRenderIcon = isRowDeleteDisabled ? DeleteIcon : /* @__PURE__ */ React.createElement(Tooltip, { title: parrotI18n.t("components.remove") }, DeleteIcon);
|
|
4011
|
+
return deletable ? [FinalRenderIcon] : void 0;
|
|
4012
|
+
};
|
|
4013
|
+
const RowValidateResult = useMemo(() => {
|
|
4014
|
+
const result = rowValidator == null ? void 0 : rowValidator(rowIndex, data[rowIndex]);
|
|
4015
|
+
if (typeof result === "string" && result) {
|
|
4016
|
+
return /* @__PURE__ */ React.createElement("p", { className: cx(Typo.Label.l4_regular, "row-error-message") }, result);
|
|
4017
|
+
}
|
|
4018
|
+
return null;
|
|
4019
|
+
}, [rowValidator, rowIndex, data]);
|
|
4020
|
+
const Cells = columns.map((col) => {
|
|
4021
|
+
return /* @__PURE__ */ React.createElement(
|
|
4022
|
+
TableFormBodyCell,
|
|
4023
|
+
{
|
|
4024
|
+
key: col.key,
|
|
4025
|
+
column: col,
|
|
4026
|
+
data,
|
|
4027
|
+
latestData,
|
|
4028
|
+
disabled,
|
|
4029
|
+
index: rowIndex,
|
|
4030
|
+
onChange: updateData,
|
|
4031
|
+
onBlur: onBodyBlur,
|
|
4032
|
+
visible: passwordVisible,
|
|
4033
|
+
isRowError: !!RowValidateResult
|
|
4034
|
+
}
|
|
4035
|
+
);
|
|
4036
|
+
});
|
|
4037
|
+
const DraggableHandle = useMemo(
|
|
4038
|
+
() => draggable && provided ? /* @__PURE__ */ React.createElement(DraggableHandleWrapper, __spreadValues$4({}, provided.dragHandleProps), /* @__PURE__ */ React.createElement(
|
|
4039
|
+
Icon,
|
|
4040
|
+
{
|
|
4041
|
+
src: HandlePoint816SecondaryIcon,
|
|
4042
|
+
hoverSrc: HandlePoint816BlueIcon
|
|
4043
|
+
}
|
|
4044
|
+
)) : null,
|
|
4045
|
+
[draggable, provided]
|
|
4046
|
+
);
|
|
4047
|
+
const RowDescription = useMemo(() => {
|
|
4048
|
+
const RenderResult = (renderRowDescription == null ? void 0 : renderRowDescription({
|
|
4049
|
+
rowIndex,
|
|
4050
|
+
rowData,
|
|
4051
|
+
latestData
|
|
4052
|
+
})) || null;
|
|
4053
|
+
return typeof RenderResult === "string" ? /* @__PURE__ */ React.createElement("p", { className: cx(Typo.Label.l4_regular, "row-description") }, RenderResult) : RenderResult;
|
|
4054
|
+
}, [rowIndex, rowData, latestData, renderRowDescription]);
|
|
4055
|
+
return /* @__PURE__ */ React.createElement(
|
|
4056
|
+
List.Item,
|
|
4057
|
+
{
|
|
4058
|
+
key: rowIndex,
|
|
4059
|
+
className: cx(
|
|
4060
|
+
"eagle-table-form-row",
|
|
4061
|
+
(snapshot == null ? void 0 : snapshot.isDragging) && "isDragging"
|
|
4062
|
+
),
|
|
4063
|
+
actions: getRowActions(rowIndex, rowData.deletable)
|
|
4064
|
+
},
|
|
4065
|
+
DraggableHandle,
|
|
4066
|
+
Cells,
|
|
4067
|
+
RowValidateResult,
|
|
4068
|
+
RowDescription
|
|
4069
|
+
);
|
|
4070
|
+
};
|
|
4071
|
+
const TableFormBodyRows = memo((props) => {
|
|
4072
|
+
const { data, draggable, updateData } = props;
|
|
4073
|
+
const onDragEnd = useCallback(
|
|
4074
|
+
(result) => {
|
|
4075
|
+
var _a;
|
|
4076
|
+
const fromIndex = result.source.index;
|
|
4077
|
+
const toIndex = (_a = result.destination) == null ? void 0 : _a.index;
|
|
4078
|
+
if (typeof toIndex !== "number" || toIndex === fromIndex)
|
|
4079
|
+
return;
|
|
4080
|
+
const newData = moveItemInArray(data, fromIndex, toIndex);
|
|
4081
|
+
updateData(newData);
|
|
4082
|
+
},
|
|
4083
|
+
[data, updateData]
|
|
4084
|
+
);
|
|
4085
|
+
return draggable ? /* @__PURE__ */ React.createElement(DragDropContext, { onDragEnd }, /* @__PURE__ */ React.createElement(Droppable, { droppableId: "droppable" }, (provided) => /* @__PURE__ */ React.createElement(
|
|
4086
|
+
"div",
|
|
4087
|
+
__spreadValues$4({
|
|
4088
|
+
className: "draggable-container",
|
|
4089
|
+
ref: provided.innerRef
|
|
4090
|
+
}, provided.droppableProps),
|
|
4091
|
+
data.map((_d, i) => /* @__PURE__ */ React.createElement(
|
|
4092
|
+
Draggable,
|
|
4093
|
+
{
|
|
4094
|
+
draggableId: `draggable-id-${i}`,
|
|
4095
|
+
key: `draggable-id-${i}`,
|
|
4096
|
+
index: i
|
|
4097
|
+
},
|
|
4098
|
+
(provided2, snapshot) => /* @__PURE__ */ React.createElement("div", __spreadValues$4({ ref: provided2.innerRef }, provided2.draggableProps), /* @__PURE__ */ React.createElement(
|
|
4099
|
+
TableFormRow,
|
|
4100
|
+
__spreadProps$4(__spreadValues$4({}, props), {
|
|
4101
|
+
rowIndex: i,
|
|
4102
|
+
provided: provided2,
|
|
4103
|
+
snapshot
|
|
4104
|
+
})
|
|
4105
|
+
))
|
|
4106
|
+
)),
|
|
4107
|
+
provided.placeholder
|
|
4108
|
+
))) : /* @__PURE__ */ React.createElement(React.Fragment, null, data.map((_d, i) => /* @__PURE__ */ React.createElement(TableFormRow, __spreadProps$4(__spreadValues$4({}, props), { rowIndex: i, key: `table-row-${i}` }))));
|
|
4109
|
+
});
|
|
4110
|
+
|
|
4111
|
+
var __defProp$3 = Object.defineProperty;
|
|
4112
|
+
var __defProps$3 = Object.defineProperties;
|
|
4113
|
+
var __getOwnPropDescs$3 = Object.getOwnPropertyDescriptors;
|
|
4114
|
+
var __getOwnPropSymbols$3 = Object.getOwnPropertySymbols;
|
|
4115
|
+
var __hasOwnProp$3 = Object.prototype.hasOwnProperty;
|
|
4116
|
+
var __propIsEnum$3 = Object.prototype.propertyIsEnumerable;
|
|
4117
|
+
var __defNormalProp$3 = (obj, key, value) => key in obj ? __defProp$3(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
4118
|
+
var __spreadValues$3 = (a, b) => {
|
|
4119
|
+
for (var prop in b || (b = {}))
|
|
4120
|
+
if (__hasOwnProp$3.call(b, prop))
|
|
4121
|
+
__defNormalProp$3(a, prop, b[prop]);
|
|
4122
|
+
if (__getOwnPropSymbols$3)
|
|
4123
|
+
for (var prop of __getOwnPropSymbols$3(b)) {
|
|
4124
|
+
if (__propIsEnum$3.call(b, prop))
|
|
4125
|
+
__defNormalProp$3(a, prop, b[prop]);
|
|
4126
|
+
}
|
|
4127
|
+
return a;
|
|
4128
|
+
};
|
|
4129
|
+
var __spreadProps$3 = (a, b) => __defProps$3(a, __getOwnPropDescs$3(b));
|
|
4130
|
+
const BatchInputListHeaderCell = (props) => {
|
|
4131
|
+
const { column, disabled, data, disableBatchFilling, onBlur, onChange } = props;
|
|
4132
|
+
const [errMsg, setErrMsg] = useState();
|
|
4133
|
+
const width = Number.isNaN(Number(column.width)) ? column.width : column.width + "px";
|
|
4134
|
+
const headerOnChange = useCallback(
|
|
4135
|
+
(value) => {
|
|
4136
|
+
var _a;
|
|
4137
|
+
const err = (_a = column.validator) == null ? void 0 : _a.call(column, { value, isHeader: true });
|
|
4138
|
+
setErrMsg(err || void 0);
|
|
4139
|
+
const shouldAutoIncrease = column.type !== "password" && column.autoIncrease;
|
|
4140
|
+
const newData = data.map((cell, rowIndex) => {
|
|
4141
|
+
return __spreadProps$3(__spreadValues$3({}, cell), {
|
|
4142
|
+
[column.key]: shouldAutoIncrease && typeof value === "string" ? increaseLastNumber(value, rowIndex) : value
|
|
4143
|
+
});
|
|
4144
|
+
});
|
|
4145
|
+
onChange == null ? void 0 : onChange(newData, column.key);
|
|
4146
|
+
},
|
|
4147
|
+
[onChange, data, column]
|
|
4148
|
+
);
|
|
4149
|
+
const _onBlur = useCallback(() => {
|
|
4150
|
+
onBlur == null ? void 0 : onBlur(column.key, errMsg);
|
|
4151
|
+
}, [column.key, onBlur, errMsg]);
|
|
4152
|
+
const renderDefaultComponent = () => {
|
|
4153
|
+
if (!column.type)
|
|
4154
|
+
return null;
|
|
4155
|
+
const CellComponent = ColumnHeaderImpls[column.type];
|
|
4156
|
+
return /* @__PURE__ */ React.createElement(
|
|
4157
|
+
CellComponent,
|
|
4158
|
+
__spreadProps$3(__spreadValues$3({}, props), {
|
|
4159
|
+
column,
|
|
4160
|
+
onChange: headerOnChange,
|
|
4161
|
+
onBlur: _onBlur
|
|
4162
|
+
})
|
|
4163
|
+
);
|
|
4164
|
+
};
|
|
4165
|
+
const renderCell = () => column.render ? column.render({
|
|
4166
|
+
isHeader: true,
|
|
4167
|
+
disabled,
|
|
4168
|
+
onChange: headerOnChange,
|
|
4169
|
+
onBlur: _onBlur
|
|
4170
|
+
}) : renderDefaultComponent();
|
|
4171
|
+
return /* @__PURE__ */ React.createElement(
|
|
4172
|
+
"div",
|
|
4173
|
+
{
|
|
4174
|
+
className: cx("eagle-table-form-cell", `align-${column.align || "left"}`),
|
|
4175
|
+
style: {
|
|
4176
|
+
maxWidth: column.width ? width : "",
|
|
4177
|
+
minWidth: column.width ? width : "",
|
|
4178
|
+
visibility: column.hidden ? "hidden" : "visible"
|
|
4179
|
+
}
|
|
4180
|
+
},
|
|
4181
|
+
/* @__PURE__ */ React.createElement(
|
|
4182
|
+
FormItem,
|
|
4183
|
+
{
|
|
4184
|
+
validateStatus: typeof errMsg === "string" && errMsg ? "error" : "",
|
|
4185
|
+
message: errMsg || void 0
|
|
4186
|
+
},
|
|
4187
|
+
/* @__PURE__ */ React.createElement("p", { className: cx(Typo.Label.l3_bold_title, TitleStyle) }, column.title),
|
|
4188
|
+
disableBatchFilling ? null : renderCell()
|
|
4189
|
+
)
|
|
4190
|
+
);
|
|
4191
|
+
};
|
|
4192
|
+
|
|
4193
|
+
var __defProp$2 = Object.defineProperty;
|
|
4194
|
+
var __defProps$2 = Object.defineProperties;
|
|
4195
|
+
var __getOwnPropDescs$2 = Object.getOwnPropertyDescriptors;
|
|
4196
|
+
var __getOwnPropSymbols$2 = Object.getOwnPropertySymbols;
|
|
4197
|
+
var __hasOwnProp$2 = Object.prototype.hasOwnProperty;
|
|
4198
|
+
var __propIsEnum$2 = Object.prototype.propertyIsEnumerable;
|
|
4199
|
+
var __defNormalProp$2 = (obj, key, value) => key in obj ? __defProp$2(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
4200
|
+
var __spreadValues$2 = (a, b) => {
|
|
4201
|
+
for (var prop in b || (b = {}))
|
|
4202
|
+
if (__hasOwnProp$2.call(b, prop))
|
|
4203
|
+
__defNormalProp$2(a, prop, b[prop]);
|
|
4204
|
+
if (__getOwnPropSymbols$2)
|
|
4205
|
+
for (var prop of __getOwnPropSymbols$2(b)) {
|
|
4206
|
+
if (__propIsEnum$2.call(b, prop))
|
|
4207
|
+
__defNormalProp$2(a, prop, b[prop]);
|
|
4208
|
+
}
|
|
4209
|
+
return a;
|
|
4210
|
+
};
|
|
4211
|
+
var __spreadProps$2 = (a, b) => __defProps$2(a, __getOwnPropDescs$2(b));
|
|
4212
|
+
const DEFAULT_ROW_COUNT = 3;
|
|
4213
|
+
const TableForm = React.forwardRef(
|
|
4214
|
+
({
|
|
4215
|
+
defaultData,
|
|
4216
|
+
columns,
|
|
4217
|
+
disabled,
|
|
4218
|
+
rowAddConfig,
|
|
4219
|
+
deletable,
|
|
4220
|
+
size = "default",
|
|
4221
|
+
className,
|
|
4222
|
+
draggable,
|
|
4223
|
+
disableBatchFilling = false,
|
|
4224
|
+
rowSplitType = "border",
|
|
4225
|
+
renderRowDescription,
|
|
4226
|
+
rowValidator,
|
|
4227
|
+
onHeaderChange,
|
|
4228
|
+
onHeaderBlur,
|
|
4229
|
+
onBodyChange,
|
|
4230
|
+
onBodyBlur
|
|
4231
|
+
}, ref) => {
|
|
4232
|
+
const treatedDefaultData = useMemo(() => {
|
|
4233
|
+
return defaultData || [...Array(DEFAULT_ROW_COUNT)].map(() => genEmptyRow(columns));
|
|
4234
|
+
}, [defaultData, columns]);
|
|
4235
|
+
const [data, setData] = useState(treatedDefaultData);
|
|
4236
|
+
const [passwordVisible, setPasswordVisible] = useState(false);
|
|
4237
|
+
const [latestData, setLatestData] = useState(treatedDefaultData);
|
|
4238
|
+
const updateData = useCallback(
|
|
4239
|
+
(value, rowIndex, columnKey) => {
|
|
4240
|
+
setLatestData(value);
|
|
4241
|
+
setData(value);
|
|
4242
|
+
onBodyChange == null ? void 0 : onBodyChange(value, rowIndex, columnKey);
|
|
4243
|
+
},
|
|
4244
|
+
[onBodyChange]
|
|
4245
|
+
);
|
|
4246
|
+
const handleBatchChange = useCallback(
|
|
4247
|
+
(newData, columnKey) => {
|
|
4248
|
+
setLatestData(newData);
|
|
4249
|
+
onHeaderChange == null ? void 0 : onHeaderChange(newData, columnKey);
|
|
4250
|
+
},
|
|
4251
|
+
[onHeaderChange]
|
|
4252
|
+
);
|
|
4253
|
+
const handleBatchBlur = useCallback(
|
|
4254
|
+
(key, error) => {
|
|
4255
|
+
if (error) {
|
|
4256
|
+
const newData = latestData.map((cell) => {
|
|
4257
|
+
return __spreadProps$2(__spreadValues$2({}, cell), {
|
|
4258
|
+
[key]: ""
|
|
4259
|
+
});
|
|
4260
|
+
});
|
|
4261
|
+
setLatestData(newData);
|
|
4262
|
+
onHeaderBlur == null ? void 0 : onHeaderBlur(newData);
|
|
4263
|
+
} else {
|
|
4264
|
+
setData(latestData);
|
|
4265
|
+
onBodyChange == null ? void 0 : onBodyChange(latestData, void 0, key);
|
|
4266
|
+
onHeaderBlur == null ? void 0 : onHeaderBlur(latestData);
|
|
4267
|
+
}
|
|
4268
|
+
},
|
|
4269
|
+
[latestData, onHeaderBlur, onBodyChange]
|
|
4270
|
+
);
|
|
4271
|
+
useImperativeHandle(
|
|
4272
|
+
ref,
|
|
4273
|
+
() => ({
|
|
4274
|
+
setData: (data2) => {
|
|
4275
|
+
updateData(data2);
|
|
4276
|
+
}
|
|
4277
|
+
}),
|
|
4278
|
+
[updateData]
|
|
4279
|
+
);
|
|
4280
|
+
const headerCells = columns.map((col) => {
|
|
4281
|
+
return /* @__PURE__ */ React.createElement(
|
|
4282
|
+
BatchInputListHeaderCell,
|
|
4283
|
+
{
|
|
4284
|
+
key: col.key,
|
|
4285
|
+
data,
|
|
4286
|
+
latestData,
|
|
4287
|
+
disabled,
|
|
4288
|
+
column: col,
|
|
4289
|
+
disableBatchFilling,
|
|
4290
|
+
onChange: handleBatchChange,
|
|
4291
|
+
onBlur: handleBatchBlur,
|
|
4292
|
+
onVisibleChange: setPasswordVisible
|
|
4293
|
+
}
|
|
4294
|
+
);
|
|
4295
|
+
});
|
|
4296
|
+
return /* @__PURE__ */ React.createElement("div", { className }, /* @__PURE__ */ React.createElement(TableFormWrapper, { className: `table-form row-split-by-${rowSplitType}` }, /* @__PURE__ */ React.createElement(List, { size, className: `size-${size}` }, /* @__PURE__ */ React.createElement(
|
|
4297
|
+
List.Item,
|
|
4298
|
+
{
|
|
4299
|
+
className: "eagle-table-form-header",
|
|
4300
|
+
actions: deletable ? [/* @__PURE__ */ React.createElement(React.Fragment, null)] : void 0
|
|
4301
|
+
},
|
|
4302
|
+
draggable ? /* @__PURE__ */ React.createElement(DraggableHandleWrapper, null) : null,
|
|
4303
|
+
headerCells
|
|
4304
|
+
), /* @__PURE__ */ React.createElement(
|
|
4305
|
+
TableFormBodyRows,
|
|
4306
|
+
{
|
|
4307
|
+
data,
|
|
4308
|
+
latestData,
|
|
4309
|
+
columns,
|
|
4310
|
+
passwordVisible,
|
|
4311
|
+
deletable,
|
|
4312
|
+
disabled,
|
|
4313
|
+
draggable,
|
|
4314
|
+
rowSplitType,
|
|
4315
|
+
onBodyBlur,
|
|
4316
|
+
updateData,
|
|
4317
|
+
renderRowDescription,
|
|
4318
|
+
rowValidator
|
|
4319
|
+
}
|
|
4320
|
+
))), (rowAddConfig == null ? void 0 : rowAddConfig.addible) ? /* @__PURE__ */ React.createElement(
|
|
4321
|
+
AddRowButton,
|
|
4322
|
+
{
|
|
4323
|
+
config: rowAddConfig,
|
|
4324
|
+
updateData,
|
|
4325
|
+
columns,
|
|
4326
|
+
data
|
|
4327
|
+
}
|
|
4328
|
+
) : null);
|
|
4329
|
+
}
|
|
4330
|
+
);
|
|
4331
|
+
|
|
4332
|
+
const flatTimeZones = sortBy(uniqBy(TimeZones.reduce((sum, zone) => {
|
|
3313
4333
|
const utcZones = zone.utc.map(utc => {
|
|
3314
4334
|
return {
|
|
3315
4335
|
abbr: zone.abbr,
|
|
@@ -3465,13 +4485,14 @@ function getAntdKit() {
|
|
|
3465
4485
|
menuItemGroup: Menu.ItemGroup,
|
|
3466
4486
|
layout: Layout,
|
|
3467
4487
|
autoComplete: AutoComplete,
|
|
3468
|
-
message,
|
|
4488
|
+
message: createBatchMessageMethods(),
|
|
3469
4489
|
tag: Tag,
|
|
3470
4490
|
popover: Popover,
|
|
3471
4491
|
arch: Arch,
|
|
3472
4492
|
buttonGroup: ButtonGroup,
|
|
3473
4493
|
steps: Steps,
|
|
3474
4494
|
form: Form,
|
|
4495
|
+
formItem: Form.Item,
|
|
3475
4496
|
simplePagination: SimplePagination,
|
|
3476
4497
|
space: Space,
|
|
3477
4498
|
timeZoneSelect: TimeZoneSelect,
|
|
@@ -3479,7 +4500,10 @@ function getAntdKit() {
|
|
|
3479
4500
|
timelineItem: Timeline.Item,
|
|
3480
4501
|
checkboxGroup: Checkbox$1.Group,
|
|
3481
4502
|
typographyText: Typography.Text,
|
|
3482
|
-
cascader: Cascader
|
|
4503
|
+
cascader: Cascader,
|
|
4504
|
+
upload: Upload,
|
|
4505
|
+
datePickerRangePicker: DatePicker.RangePicker,
|
|
4506
|
+
tableForm: TableForm
|
|
3483
4507
|
};
|
|
3484
4508
|
kit.option.isSelectOption = true;
|
|
3485
4509
|
kit.button.__ANT_BUTTON = true;
|
|
@@ -3539,32 +4563,32 @@ const tickFormatter = (tick, dateRange) => {
|
|
|
3539
4563
|
return dayjs(tick).format("MM/DD");
|
|
3540
4564
|
};
|
|
3541
4565
|
|
|
3542
|
-
var __defProp = Object.defineProperty;
|
|
3543
|
-
var __defProps = Object.defineProperties;
|
|
3544
|
-
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
3545
|
-
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
3546
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
3547
|
-
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
3548
|
-
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
3549
|
-
var __spreadValues = (a, b) => {
|
|
4566
|
+
var __defProp$1 = Object.defineProperty;
|
|
4567
|
+
var __defProps$1 = Object.defineProperties;
|
|
4568
|
+
var __getOwnPropDescs$1 = Object.getOwnPropertyDescriptors;
|
|
4569
|
+
var __getOwnPropSymbols$1 = Object.getOwnPropertySymbols;
|
|
4570
|
+
var __hasOwnProp$1 = Object.prototype.hasOwnProperty;
|
|
4571
|
+
var __propIsEnum$1 = Object.prototype.propertyIsEnumerable;
|
|
4572
|
+
var __defNormalProp$1 = (obj, key, value) => key in obj ? __defProp$1(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
4573
|
+
var __spreadValues$1 = (a, b) => {
|
|
3550
4574
|
for (var prop in b || (b = {}))
|
|
3551
|
-
if (__hasOwnProp.call(b, prop))
|
|
3552
|
-
__defNormalProp(a, prop, b[prop]);
|
|
3553
|
-
if (__getOwnPropSymbols)
|
|
3554
|
-
for (var prop of __getOwnPropSymbols(b)) {
|
|
3555
|
-
if (__propIsEnum.call(b, prop))
|
|
3556
|
-
__defNormalProp(a, prop, b[prop]);
|
|
4575
|
+
if (__hasOwnProp$1.call(b, prop))
|
|
4576
|
+
__defNormalProp$1(a, prop, b[prop]);
|
|
4577
|
+
if (__getOwnPropSymbols$1)
|
|
4578
|
+
for (var prop of __getOwnPropSymbols$1(b)) {
|
|
4579
|
+
if (__propIsEnum$1.call(b, prop))
|
|
4580
|
+
__defNormalProp$1(a, prop, b[prop]);
|
|
3557
4581
|
}
|
|
3558
4582
|
return a;
|
|
3559
4583
|
};
|
|
3560
|
-
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
4584
|
+
var __spreadProps$1 = (a, b) => __defProps$1(a, __getOwnPropDescs$1(b));
|
|
3561
4585
|
const ModalStack = () => {
|
|
3562
4586
|
const stack = useKitSelector(
|
|
3563
4587
|
(state) => state.modal.stack
|
|
3564
4588
|
);
|
|
3565
4589
|
return /* @__PURE__ */ React.createElement(React.Fragment, null, stack.map((modal) => /* @__PURE__ */ React.createElement(
|
|
3566
4590
|
modal.component,
|
|
3567
|
-
__spreadProps(__spreadValues({}, modal.props), {
|
|
4591
|
+
__spreadProps$1(__spreadValues$1({}, modal.props), {
|
|
3568
4592
|
modalId: modal.id,
|
|
3569
4593
|
onClose: () => {
|
|
3570
4594
|
var _a;
|
|
@@ -3603,13 +4627,40 @@ var TaskStatus = /* @__PURE__ */ ((TaskStatus2) => {
|
|
|
3603
4627
|
return TaskStatus2;
|
|
3604
4628
|
})(TaskStatus || {});
|
|
3605
4629
|
|
|
4630
|
+
var __defProp = Object.defineProperty;
|
|
4631
|
+
var __defProps = Object.defineProperties;
|
|
4632
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4633
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
4634
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
4635
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
4636
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
4637
|
+
var __spreadValues = (a, b) => {
|
|
4638
|
+
for (var prop in b || (b = {}))
|
|
4639
|
+
if (__hasOwnProp.call(b, prop))
|
|
4640
|
+
__defNormalProp(a, prop, b[prop]);
|
|
4641
|
+
if (__getOwnPropSymbols)
|
|
4642
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
4643
|
+
if (__propIsEnum.call(b, prop))
|
|
4644
|
+
__defNormalProp(a, prop, b[prop]);
|
|
4645
|
+
}
|
|
4646
|
+
return a;
|
|
4647
|
+
};
|
|
4648
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
3606
4649
|
const kitContext = createContext(antdKit);
|
|
3607
4650
|
const UIKitProvider = (props) => {
|
|
3608
|
-
const { children, kit = antdKit } = props;
|
|
3609
|
-
|
|
4651
|
+
const { children, kit = antdKit, message } = props;
|
|
4652
|
+
const _kit = useMemo(() => {
|
|
4653
|
+
if ((message == null ? void 0 : message.batch) != null) {
|
|
4654
|
+
return __spreadProps(__spreadValues({}, kit), {
|
|
4655
|
+
message: createBatchMessageMethods(message.batch)
|
|
4656
|
+
});
|
|
4657
|
+
}
|
|
4658
|
+
return kit;
|
|
4659
|
+
}, [kit, message == null ? void 0 : message.batch]);
|
|
4660
|
+
return /* @__PURE__ */ React.createElement(kitContext.Provider, { value: _kit }, children);
|
|
3610
4661
|
};
|
|
3611
4662
|
const useUIKit = () => {
|
|
3612
4663
|
return useContext(kitContext);
|
|
3613
4664
|
};
|
|
3614
4665
|
|
|
3615
|
-
export { Architecture, Button, ButtonStyle, EntityAsyncStatus, FailedLoad, Icon, InputTagItem, KitStoreProvider, ModalActions, ModalStack, TaskStatus, Typo, UIKitProvider, UIKitStore, UserSource, antdKit, closeModal, kitContext, popModal, pushModal, tableStyleCover, tickFormatter, useElementsSize, useKitDispatch, useKitSelector, useUIKit };
|
|
4666
|
+
export { Architecture, Button, ButtonStyle, EntityAsyncStatus, FailedLoad, Icon, InputTagItem, KitStoreProvider, ModalActions, ModalStack, TaskStatus, Typo, UIKitProvider, UIKitStore, UserSource, antdKit, closeModal, createBatchMessageMethods, kitContext, popModal, pushModal, tableStyleCover, tickFormatter, useElementsSize, useKitDispatch, useKitSelector, useUIKit };
|