@cloudtower/eagle 0.22.8 → 0.22.10
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/components/Table/TableWidget.d.ts +0 -40
- package/dist/components/Table/index.d.ts +1 -2
- package/dist/components/index.d.ts +0 -2
- package/dist/esm/index.js +711 -863
- package/dist/esm/stats1.html +1 -1
- package/dist/hooks/index.d.ts +0 -5
- package/dist/index.d.ts +1 -1
- package/dist/spec/base.d.ts +13 -0
- package/dist/style.css +682 -702
- package/dist/umd/index.js +714 -865
- package/dist/umd/stats1.html +1 -1
- package/dist/utils/index.d.ts +0 -2
- package/package.json +4 -6
- package/dist/components/Table/SidebarTable.d.ts +0 -7
- package/dist/components/TowerTable/TableEmpty.d.ts +0 -7
- package/dist/components/TowerTable/TablePagination.d.ts +0 -9
- package/dist/components/TowerTable/WrapperComponent.d.ts +0 -7
- package/dist/components/TowerTable/index.d.ts +0 -42
- package/dist/hooks/useHistory.d.ts +0 -2
- package/dist/hooks/useMatchMediaQueries.d.ts +0 -10
- package/dist/hooks/useSearch.d.ts +0 -12
- package/dist/utils/history.d.ts +0 -1
- package/dist/utils/router.d.ts +0 -34
package/dist/esm/index.js
CHANGED
|
@@ -1,14 +1,13 @@
|
|
|
1
|
-
import { Button as Button$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, Radio as Radio$1, Table as Table$1, Tag, Tooltip as Tooltip$1, Row, Col,
|
|
1
|
+
import { Alert as Alert$1, Button as Button$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, Dropdown, Menu, Radio as Radio$1, Table as Table$1, Tag, Tooltip as Tooltip$1, Row, Col, Divider, List, Layout, AutoComplete, Space } from 'antd';
|
|
2
2
|
export { Col, Row } from 'antd';
|
|
3
3
|
import cs from 'classnames';
|
|
4
|
-
import React, { useState,
|
|
5
|
-
import moment from 'moment';
|
|
4
|
+
import React, { useState, useMemo, Fragment, useRef, useEffect, useCallback, useLayoutEffect, createContext, useContext } from 'react';
|
|
6
5
|
import _, { sortBy, uniqBy } from 'lodash';
|
|
6
|
+
import moment from 'moment';
|
|
7
7
|
import { findDOMNode } from 'react-dom';
|
|
8
8
|
import { isElement } from 'react-is';
|
|
9
9
|
import { styled } from '@linaria/react';
|
|
10
10
|
import { CloseCircleFilled, CheckOutlined, SearchOutlined } from '@ant-design/icons';
|
|
11
|
-
import { createHashHistory } from 'history';
|
|
12
11
|
import { parrotI18n } from '@cloudtower/parrot';
|
|
13
12
|
export * from '@cloudtower/parrot';
|
|
14
13
|
import { combineReducers, createStore } from 'redux';
|
|
@@ -20,6 +19,304 @@ import { withTranslation } from 'react-i18next';
|
|
|
20
19
|
import dayjs from 'dayjs';
|
|
21
20
|
import 'recharts';
|
|
22
21
|
|
|
22
|
+
const SECOND = 1;
|
|
23
|
+
const MINUTE = 60 * SECOND;
|
|
24
|
+
const HOUR = 60 * MINUTE;
|
|
25
|
+
const DAY = 24 * HOUR;
|
|
26
|
+
|
|
27
|
+
const EMPTY_FUNCTION = () => {
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
function getSize(el) {
|
|
31
|
+
if (!el) {
|
|
32
|
+
return {
|
|
33
|
+
width: 0,
|
|
34
|
+
height: 0
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
return {
|
|
38
|
+
width: el.offsetWidth,
|
|
39
|
+
height: el.offsetHeight
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
var img$9 = "data:image/svg+xml,%3csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M4.11092 7.0535C3.91566 6.85824 3.91566 6.54166 4.11092 6.3464C4.30619 6.15114 4.62277 6.15114 4.81803 6.3464L8.00001 9.52838L8.35226 9.17613L8.35356 9.17482L11.182 6.3464C11.3773 6.15114 11.6938 6.15114 11.8891 6.3464C12.0844 6.54166 12.0844 6.85824 11.8891 7.0535L10.4408 8.50184C10.4288 8.51384 10.4166 8.52604 10.4042 8.53843L9.13138 9.81122C9.11899 9.82361 9.1068 9.83581 9.09479 9.84781L9.06067 9.88193L9.057 9.88556C8.70964 10.2323 8.5226 10.41 8.30903 10.4794C8.10819 10.5447 7.89184 10.5447 7.691 10.4794C7.47748 10.4101 7.29048 10.2324 6.94327 9.88581L6.93935 9.88193L4.11092 7.0535Z' fill='%230080FF'/%3e%3c/svg%3e";
|
|
44
|
+
|
|
45
|
+
var img$8 = "data:image/svg+xml,%3csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M4.11092 7.0535C3.91566 6.85824 3.91566 6.54166 4.11092 6.3464C4.30619 6.15114 4.62277 6.15114 4.81803 6.3464L8.00001 9.52838L8.35226 9.17613L8.35356 9.17482L11.182 6.3464C11.3773 6.15114 11.6938 6.15114 11.8891 6.3464C12.0844 6.54166 12.0844 6.85824 11.8891 7.0535L10.4408 8.50184C10.4288 8.51384 10.4166 8.52604 10.4042 8.53843L9.13138 9.81122C9.11899 9.82361 9.1068 9.83581 9.09479 9.84781L9.06067 9.88193L9.057 9.88556C8.70964 10.2323 8.5226 10.41 8.30903 10.4794C8.10819 10.5447 7.89184 10.5447 7.691 10.4794C7.47748 10.4101 7.29048 10.2324 6.94327 9.88581L6.93935 9.88193L4.11092 7.0535Z' fill='%232C3852' fill-opacity='0.6'/%3e%3c/svg%3e";
|
|
46
|
+
|
|
47
|
+
var img$7 = "data:image/svg+xml,%3csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M9.06067 3.75725C9.45119 3.36672 10.0844 3.36672 10.4749 3.75725C10.8654 4.14777 10.8654 4.78094 10.4749 5.17146L7.64645 7.99989L10.4749 10.8283C10.8654 11.2188 10.8654 11.852 10.4749 12.2425C10.0844 12.6331 9.45119 12.6331 9.06067 12.2425L5.9494 9.13126C5.55338 8.73524 5.35537 8.53723 5.28118 8.30891C5.21592 8.10806 5.21592 7.89172 5.28118 7.69087C5.35537 7.46254 5.55338 7.26454 5.9494 6.86852L9.06067 3.75725Z' fill='%230080FF'/%3e%3c/svg%3e";
|
|
48
|
+
|
|
49
|
+
var img$6 = "data:image/svg+xml,%3csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cpath fill-rule='evenodd' clip-rule='evenodd' d='M3.05028 9.4142L6.86865 5.59582C6.87513 5.58934 6.88156 5.58292 6.88793 5.57655C7.27116 5.19336 7.46641 5.00058 7.69101 4.92761C7.89185 4.86235 8.1082 4.86235 8.30904 4.92761C8.53737 5.00179 8.73538 5.1998 9.1314 5.59582L12.9498 9.4142C13.3403 9.80472 13.3403 10.4379 12.9498 10.8284C12.5592 11.2189 11.9261 11.2189 11.5356 10.8284L8.00003 7.29288L4.46449 10.8284C4.07397 11.2189 3.4408 11.2189 3.05028 10.8284C2.65975 10.4379 2.65975 9.80472 3.05028 9.4142Z' fill='%232C3852' fill-opacity='0.6'/%3e%3c/svg%3e";
|
|
50
|
+
|
|
51
|
+
var img$5 = "data:image/svg+xml,%3csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cpath fill-rule='evenodd' clip-rule='evenodd' d='M8 14.5C11.5899 14.5 14.5 11.5899 14.5 8C14.5 4.41015 11.5899 1.5 8 1.5C4.41015 1.5 1.5 4.41015 1.5 8C1.5 11.5899 4.41015 14.5 8 14.5ZM11.134 6.56615C11.3346 6.28527 11.2696 5.89493 10.9887 5.6943C10.7078 5.49367 10.3175 5.55872 10.1168 5.83961L7.26389 9.83372L5.81653 8.38635C5.57245 8.14227 5.17672 8.14227 4.93265 8.38635C4.68857 8.63043 4.68857 9.02616 4.93265 9.27023L6.90171 11.2393C7.03162 11.3692 7.2121 11.4354 7.3952 11.4202C7.57829 11.4051 7.74545 11.3101 7.85223 11.1606L11.134 6.56615Z' fill='%2300BA5D'/%3e%3c/svg%3e";
|
|
52
|
+
|
|
53
|
+
var img$4 = "data:image/svg+xml,%3csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M9.81662 7.33209C10.1545 7.55506 10.3235 7.66655 10.3822 7.80742C10.4336 7.93055 10.4336 8.0691 10.3822 8.19224C10.3235 8.33311 10.1545 8.4446 9.81662 8.66757L6.81921 10.6454C6.4159 10.9115 6.21424 11.0445 6.04715 11.034C5.90158 11.0248 5.76727 10.9525 5.67943 10.8361C5.57861 10.7024 5.57861 10.4608 5.57861 9.97761L5.57861 6.02205C5.57861 5.53885 5.57861 5.29726 5.67943 5.16359C5.76727 5.04714 5.90158 4.97485 6.04715 4.96567C6.21424 4.95513 6.4159 5.08819 6.81921 5.35431L9.81662 7.33209Z' fill='%230080FF'/%3e%3c/svg%3e";
|
|
54
|
+
|
|
55
|
+
var img$3 = "data:image/svg+xml,%3csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cpath fill-rule='evenodd' clip-rule='evenodd' d='M8 14.5C11.5899 14.5 14.5 11.5899 14.5 8C14.5 4.41015 11.5899 1.5 8 1.5C4.41015 1.5 1.5 4.41015 1.5 8C1.5 11.5899 4.41015 14.5 8 14.5ZM8.75 11.5C8.75 11.9142 8.41421 12.25 8 12.25C7.58579 12.25 7.25 11.9142 7.25 11.5V7.99812C7.25 7.58391 7.58579 7.24812 8 7.24812C8.41421 7.24812 8.75 7.58391 8.75 7.99812V11.5ZM8.875 5.125C8.875 5.60825 8.48325 6 8 6C7.51675 6 7.125 5.60825 7.125 5.125C7.125 4.64175 7.51675 4.25 8 4.25C8.48325 4.25 8.875 4.64175 8.875 5.125Z' fill='%230080FF'/%3e%3c/svg%3e";
|
|
56
|
+
|
|
57
|
+
var img$2 = "data:image/svg+xml,%3csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cpath fill-rule='evenodd' clip-rule='evenodd' d='M8 14.5C11.5899 14.5 14.5 11.5899 14.5 8C14.5 4.41015 11.5899 1.5 8 1.5C4.41015 1.5 1.5 4.41015 1.5 8C1.5 11.5899 4.41015 14.5 8 14.5ZM8.75 11.5C8.75 11.9142 8.41421 12.25 8 12.25C7.58579 12.25 7.25 11.9142 7.25 11.5V7.99812C7.25 7.58391 7.58579 7.24812 8 7.24812C8.41421 7.24812 8.75 7.58391 8.75 7.99812V11.5ZM8.875 5.125C8.875 5.60825 8.48325 6 8 6C7.51675 6 7.125 5.60825 7.125 5.125C7.125 4.64175 7.51675 4.25 8 4.25C8.48325 4.25 8.875 4.64175 8.875 5.125Z' fill='%232C3852' fill-opacity='0.6'/%3e%3c/svg%3e";
|
|
58
|
+
|
|
59
|
+
var img$1 = "data:image/svg+xml,%3csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cpath fill-rule='evenodd' clip-rule='evenodd' d='M7.60245 1.88247C7.31193 2.00834 7.08625 2.37752 6.63487 3.11589L1.69402 11.1983C1.20753 11.9941 0.964285 12.392 0.992929 12.7198C1.0179 13.0056 1.16444 13.267 1.39527 13.4373C1.66005 13.6328 2.12641 13.6328 3.05915 13.6328H12.9408C13.8736 13.6328 14.34 13.6328 14.6047 13.4373C14.8356 13.267 14.9821 13.0056 15.0071 12.7198C15.0357 12.392 14.7925 11.9941 14.306 11.1983L9.36513 3.11589C8.91375 2.37752 8.68807 2.00834 8.39755 1.88247C8.14391 1.77258 7.85609 1.77258 7.60245 1.88247ZM7.25 5.38278C7.25 4.96856 7.58579 4.63278 8 4.63278C8.41421 4.63278 8.75 4.96856 8.75 5.38278V9.38278C8.75 9.79699 8.41421 10.1328 8 10.1328C7.58579 10.1328 7.25 9.79699 7.25 9.38278V5.38278ZM7.125 11.7578C7.125 11.2745 7.51675 10.8828 8 10.8828C8.48325 10.8828 8.875 11.2745 8.875 11.7578C8.875 12.241 8.48325 12.6328 8 12.6328C7.51675 12.6328 7.125 12.241 7.125 11.7578Z' fill='%23FEA008'/%3e%3c/svg%3e";
|
|
60
|
+
|
|
61
|
+
var img = "data:image/svg+xml,%3csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cpath fill-rule='evenodd' clip-rule='evenodd' d='M4.47964 2.70117L2.70108 4.47973C2.35518 4.82563 2.18223 4.99859 2.05854 5.20042C1.94889 5.37936 1.86808 5.57445 1.81908 5.77853C1.76382 6.0087 1.76382 6.25329 1.76382 6.74247V9.25773C1.76382 9.74691 1.76382 9.9915 1.81908 10.2217C1.86808 10.4258 1.94889 10.6208 2.05854 10.7998C2.18223 11.0016 2.35518 11.1746 2.70108 11.5205L4.47964 13.299C4.82554 13.6449 4.9985 13.8179 5.20033 13.9416C5.37927 14.0512 5.57436 14.132 5.77843 14.181C6.00861 14.2363 6.2532 14.2363 6.74238 14.2363H9.25764C9.74682 14.2363 9.99141 14.2363 10.2216 14.181C10.4257 14.132 10.6207 14.0512 10.7997 13.9416C11.0015 13.8179 11.1745 13.6449 11.5204 13.299L13.2989 11.5205C13.6448 11.1746 13.8178 11.0016 13.9415 10.7998C14.0511 10.6208 14.1319 10.4258 14.1809 10.2217C14.2362 9.9915 14.2362 9.74691 14.2362 9.25773V6.74247C14.2362 6.25329 14.2362 6.0087 14.1809 5.77853C14.1319 5.57445 14.0511 5.37936 13.9415 5.20042C13.8178 4.99859 13.6448 4.82563 13.2989 4.47973L11.5204 2.70117C11.1745 2.35527 11.0015 2.18232 10.7997 2.05864C10.6207 1.94898 10.4257 1.86817 10.2216 1.81918C9.99141 1.76392 9.74682 1.76392 9.25764 1.76392H6.74238C6.2532 1.76392 6.00861 1.76392 5.77843 1.81918C5.57436 1.86817 5.37927 1.94898 5.20033 2.05864C4.99849 2.18232 4.82554 2.35527 4.47964 2.70117ZM9.94454 5.17157C10.1886 4.92749 10.5843 4.92749 10.8284 5.17157C11.0725 5.41564 11.0725 5.81137 10.8284 6.05545L8.88389 7.99998L10.8285 9.94457C11.0726 10.1886 11.0726 10.5844 10.8285 10.8284C10.5844 11.0725 10.1887 11.0725 9.9446 10.8284L8.00001 8.88386L6.05545 10.8284C5.81138 11.0725 5.41565 11.0725 5.17157 10.8284C4.92749 10.5843 4.92749 10.1886 5.17157 9.94454L7.11613 7.99998L5.17162 6.05548C4.92755 5.8114 4.92755 5.41567 5.17162 5.17159C5.4157 4.92752 5.81143 4.92752 6.05551 5.17159L8.00001 7.1161L9.94454 5.17157Z' fill='%23F0483E'/%3e%3c/svg%3e";
|
|
62
|
+
|
|
63
|
+
function getAlertIcon(type) {
|
|
64
|
+
switch (type) {
|
|
65
|
+
case "success":
|
|
66
|
+
return img$5;
|
|
67
|
+
case "info":
|
|
68
|
+
return img$3;
|
|
69
|
+
case "warning":
|
|
70
|
+
return img$1;
|
|
71
|
+
case "error":
|
|
72
|
+
return img;
|
|
73
|
+
case "normal":
|
|
74
|
+
return img$2;
|
|
75
|
+
default:
|
|
76
|
+
return img$2;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
var __defProp$s = Object.defineProperty;
|
|
81
|
+
var __getOwnPropSymbols$t = Object.getOwnPropertySymbols;
|
|
82
|
+
var __hasOwnProp$t = Object.prototype.hasOwnProperty;
|
|
83
|
+
var __propIsEnum$t = Object.prototype.propertyIsEnumerable;
|
|
84
|
+
var __defNormalProp$s = (obj, key, value) => key in obj ? __defProp$s(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
85
|
+
var __spreadValues$s = (a, b) => {
|
|
86
|
+
for (var prop in b || (b = {}))
|
|
87
|
+
if (__hasOwnProp$t.call(b, prop))
|
|
88
|
+
__defNormalProp$s(a, prop, b[prop]);
|
|
89
|
+
if (__getOwnPropSymbols$t)
|
|
90
|
+
for (var prop of __getOwnPropSymbols$t(b)) {
|
|
91
|
+
if (__propIsEnum$t.call(b, prop))
|
|
92
|
+
__defNormalProp$s(a, prop, b[prop]);
|
|
93
|
+
}
|
|
94
|
+
return a;
|
|
95
|
+
};
|
|
96
|
+
var __objRest$o = (source, exclude) => {
|
|
97
|
+
var target = {};
|
|
98
|
+
for (var prop in source)
|
|
99
|
+
if (__hasOwnProp$t.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
100
|
+
target[prop] = source[prop];
|
|
101
|
+
if (source != null && __getOwnPropSymbols$t)
|
|
102
|
+
for (var prop of __getOwnPropSymbols$t(source)) {
|
|
103
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$t.call(source, prop))
|
|
104
|
+
target[prop] = source[prop];
|
|
105
|
+
}
|
|
106
|
+
return target;
|
|
107
|
+
};
|
|
108
|
+
const BaseIcon = React.forwardRef(
|
|
109
|
+
(props, ref) => {
|
|
110
|
+
const _a = props, {
|
|
111
|
+
alt,
|
|
112
|
+
className,
|
|
113
|
+
width,
|
|
114
|
+
height,
|
|
115
|
+
cursor,
|
|
116
|
+
style,
|
|
117
|
+
children,
|
|
118
|
+
prefixNode,
|
|
119
|
+
suffixIconSrc,
|
|
120
|
+
src
|
|
121
|
+
} = _a, HTMLSpanElementProps = __objRest$o(_a, [
|
|
122
|
+
"alt",
|
|
123
|
+
"className",
|
|
124
|
+
"width",
|
|
125
|
+
"height",
|
|
126
|
+
"cursor",
|
|
127
|
+
"style",
|
|
128
|
+
"children",
|
|
129
|
+
"prefixNode",
|
|
130
|
+
"suffixIconSrc",
|
|
131
|
+
"src"
|
|
132
|
+
]);
|
|
133
|
+
return /* @__PURE__ */ React.createElement(
|
|
134
|
+
"span",
|
|
135
|
+
__spreadValues$s({
|
|
136
|
+
ref,
|
|
137
|
+
className,
|
|
138
|
+
style: _.pickBy(__spreadValues$s({ cursor }, style))
|
|
139
|
+
}, HTMLSpanElementProps),
|
|
140
|
+
prefixNode,
|
|
141
|
+
/* @__PURE__ */ React.createElement("span", { className: "icon-inner" }, /* @__PURE__ */ React.createElement("img", { alt, src, width, height })),
|
|
142
|
+
children && /* @__PURE__ */ React.createElement("span", { className: "icon-children" }, children),
|
|
143
|
+
suffixIconSrc && /* @__PURE__ */ React.createElement("span", { className: "icon-inner suffix" }, /* @__PURE__ */ React.createElement("img", { alt, src: suffixIconSrc, width, height }))
|
|
144
|
+
);
|
|
145
|
+
}
|
|
146
|
+
);
|
|
147
|
+
|
|
148
|
+
var __defProp$r = Object.defineProperty;
|
|
149
|
+
var __defProps$k = Object.defineProperties;
|
|
150
|
+
var __getOwnPropDescs$k = Object.getOwnPropertyDescriptors;
|
|
151
|
+
var __getOwnPropSymbols$s = Object.getOwnPropertySymbols;
|
|
152
|
+
var __hasOwnProp$s = Object.prototype.hasOwnProperty;
|
|
153
|
+
var __propIsEnum$s = Object.prototype.propertyIsEnumerable;
|
|
154
|
+
var __defNormalProp$r = (obj, key, value) => key in obj ? __defProp$r(obj, key, {
|
|
155
|
+
enumerable: true,
|
|
156
|
+
configurable: true,
|
|
157
|
+
writable: true,
|
|
158
|
+
value
|
|
159
|
+
}) : obj[key] = value;
|
|
160
|
+
var __spreadValues$r = (a, b) => {
|
|
161
|
+
for (var prop in b || (b = {})) if (__hasOwnProp$s.call(b, prop)) __defNormalProp$r(a, prop, b[prop]);
|
|
162
|
+
if (__getOwnPropSymbols$s) for (var prop of __getOwnPropSymbols$s(b)) {
|
|
163
|
+
if (__propIsEnum$s.call(b, prop)) __defNormalProp$r(a, prop, b[prop]);
|
|
164
|
+
}
|
|
165
|
+
return a;
|
|
166
|
+
};
|
|
167
|
+
var __spreadProps$k = (a, b) => __defProps$k(a, __getOwnPropDescs$k(b));
|
|
168
|
+
var __objRest$n = (source, exclude) => {
|
|
169
|
+
var target = {};
|
|
170
|
+
for (var prop in source) if (__hasOwnProp$s.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
|
|
171
|
+
if (source != null && __getOwnPropSymbols$s) for (var prop of __getOwnPropSymbols$s(source)) {
|
|
172
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$s.call(source, prop)) target[prop] = source[prop];
|
|
173
|
+
}
|
|
174
|
+
return target;
|
|
175
|
+
};
|
|
176
|
+
const IconWrapper = "i1mrf09m";
|
|
177
|
+
const Icon = React.forwardRef((props, ref) => {
|
|
178
|
+
const _a = props,
|
|
179
|
+
{
|
|
180
|
+
src,
|
|
181
|
+
hoverSrc,
|
|
182
|
+
active,
|
|
183
|
+
activeSrc,
|
|
184
|
+
onMouseEnter,
|
|
185
|
+
onMouseLeave,
|
|
186
|
+
onMouseMove,
|
|
187
|
+
className,
|
|
188
|
+
iconWidth = 16,
|
|
189
|
+
iconHeight,
|
|
190
|
+
cursor,
|
|
191
|
+
style,
|
|
192
|
+
children,
|
|
193
|
+
isRotate,
|
|
194
|
+
prefix,
|
|
195
|
+
suffix
|
|
196
|
+
} = _a,
|
|
197
|
+
restProps = __objRest$n(_a, ["src", "hoverSrc", "active", "activeSrc", "onMouseEnter", "onMouseLeave", "onMouseMove", "className", "iconWidth", "iconHeight", "cursor", "style", "children", "isRotate", "prefix", "suffix"]);
|
|
198
|
+
const [hover, setHover] = useState(false);
|
|
199
|
+
const _src = useMemo(() => {
|
|
200
|
+
if (active && activeSrc) {
|
|
201
|
+
return activeSrc;
|
|
202
|
+
}
|
|
203
|
+
if (hover && hoverSrc) {
|
|
204
|
+
return hoverSrc;
|
|
205
|
+
}
|
|
206
|
+
return src;
|
|
207
|
+
}, [active, activeSrc, hover, hoverSrc, src]);
|
|
208
|
+
const suffixIconSrc = useMemo(() => {
|
|
209
|
+
if (!suffix) {
|
|
210
|
+
return void 0;
|
|
211
|
+
}
|
|
212
|
+
const {
|
|
213
|
+
activeSrc: activeSrc2,
|
|
214
|
+
hoverSrc: hoverSrc2,
|
|
215
|
+
src: src2
|
|
216
|
+
} = suffix;
|
|
217
|
+
if (active && activeSrc2) {
|
|
218
|
+
return activeSrc2;
|
|
219
|
+
}
|
|
220
|
+
if (hover && hoverSrc2) {
|
|
221
|
+
return hoverSrc2;
|
|
222
|
+
}
|
|
223
|
+
return src2;
|
|
224
|
+
}, [active, hover, suffix]);
|
|
225
|
+
return /* @__PURE__ */React.createElement(BaseIcon, __spreadProps$k(__spreadValues$r({
|
|
226
|
+
src: _src,
|
|
227
|
+
className: cs(IconWrapper, "icon-wrapper", className, isRotate && "is-rotate"),
|
|
228
|
+
suffixIconSrc,
|
|
229
|
+
height: iconHeight,
|
|
230
|
+
width: iconWidth,
|
|
231
|
+
prefixNode: prefix,
|
|
232
|
+
style: _.pickBy(__spreadValues$r({
|
|
233
|
+
cursor
|
|
234
|
+
}, style))
|
|
235
|
+
}, restProps), {
|
|
236
|
+
onMouseEnter: e => {
|
|
237
|
+
onMouseEnter == null ? void 0 : onMouseEnter(e);
|
|
238
|
+
if (hover) {
|
|
239
|
+
setHover(true);
|
|
240
|
+
}
|
|
241
|
+
},
|
|
242
|
+
onMouseMove: e => {
|
|
243
|
+
onMouseMove == null ? void 0 : onMouseMove(e);
|
|
244
|
+
if (hoverSrc) {
|
|
245
|
+
setHover(true);
|
|
246
|
+
}
|
|
247
|
+
},
|
|
248
|
+
onMouseLeave: e => {
|
|
249
|
+
onMouseLeave == null ? void 0 : onMouseLeave(e);
|
|
250
|
+
if (hoverSrc) {
|
|
251
|
+
setHover(false);
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
}));
|
|
255
|
+
});
|
|
256
|
+
|
|
257
|
+
var __defProp$q = Object.defineProperty;
|
|
258
|
+
var __defProps$j = Object.defineProperties;
|
|
259
|
+
var __getOwnPropDescs$j = Object.getOwnPropertyDescriptors;
|
|
260
|
+
var __getOwnPropSymbols$r = Object.getOwnPropertySymbols;
|
|
261
|
+
var __hasOwnProp$r = Object.prototype.hasOwnProperty;
|
|
262
|
+
var __propIsEnum$r = Object.prototype.propertyIsEnumerable;
|
|
263
|
+
var __defNormalProp$q = (obj, key, value) => key in obj ? __defProp$q(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
264
|
+
var __spreadValues$q = (a, b) => {
|
|
265
|
+
for (var prop in b || (b = {}))
|
|
266
|
+
if (__hasOwnProp$r.call(b, prop))
|
|
267
|
+
__defNormalProp$q(a, prop, b[prop]);
|
|
268
|
+
if (__getOwnPropSymbols$r)
|
|
269
|
+
for (var prop of __getOwnPropSymbols$r(b)) {
|
|
270
|
+
if (__propIsEnum$r.call(b, prop))
|
|
271
|
+
__defNormalProp$q(a, prop, b[prop]);
|
|
272
|
+
}
|
|
273
|
+
return a;
|
|
274
|
+
};
|
|
275
|
+
var __spreadProps$j = (a, b) => __defProps$j(a, __getOwnPropDescs$j(b));
|
|
276
|
+
var __objRest$m = (source, exclude) => {
|
|
277
|
+
var target = {};
|
|
278
|
+
for (var prop in source)
|
|
279
|
+
if (__hasOwnProp$r.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
280
|
+
target[prop] = source[prop];
|
|
281
|
+
if (source != null && __getOwnPropSymbols$r)
|
|
282
|
+
for (var prop of __getOwnPropSymbols$r(source)) {
|
|
283
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$r.call(source, prop))
|
|
284
|
+
target[prop] = source[prop];
|
|
285
|
+
}
|
|
286
|
+
return target;
|
|
287
|
+
};
|
|
288
|
+
const Alert = (_a) => {
|
|
289
|
+
var _b = _a, {
|
|
290
|
+
type,
|
|
291
|
+
icon,
|
|
292
|
+
showIcon = true,
|
|
293
|
+
className,
|
|
294
|
+
onClose,
|
|
295
|
+
closeText
|
|
296
|
+
} = _b, props = __objRest$m(_b, [
|
|
297
|
+
"type",
|
|
298
|
+
"icon",
|
|
299
|
+
"showIcon",
|
|
300
|
+
"className",
|
|
301
|
+
"onClose",
|
|
302
|
+
"closeText"
|
|
303
|
+
]);
|
|
304
|
+
const _icon = /* @__PURE__ */ React.createElement(Icon, { src: getAlertIcon(type) });
|
|
305
|
+
const _type = type === "normal" ? "info" : type;
|
|
306
|
+
return /* @__PURE__ */ React.createElement(
|
|
307
|
+
Alert$1,
|
|
308
|
+
__spreadProps$j(__spreadValues$q({}, props), {
|
|
309
|
+
className: cs(type ? `alert-${type}` : "", className),
|
|
310
|
+
type: _type,
|
|
311
|
+
icon: icon || _icon,
|
|
312
|
+
showIcon,
|
|
313
|
+
onClose,
|
|
314
|
+
closeText,
|
|
315
|
+
closable: !!onClose
|
|
316
|
+
})
|
|
317
|
+
);
|
|
318
|
+
};
|
|
319
|
+
|
|
23
320
|
const d1_bold_title = "d6j0lbj";
|
|
24
321
|
const d1s_bold_title = "d1xhvvxe";
|
|
25
322
|
const d1_regular_title = "dk10mxq";
|
|
@@ -155,28 +452,28 @@ const HoverableElement = (props) => {
|
|
|
155
452
|
return icon != null ? React.cloneElement(icon, { className }) : null;
|
|
156
453
|
};
|
|
157
454
|
|
|
158
|
-
var __defProp$
|
|
159
|
-
var __getOwnPropSymbols$
|
|
160
|
-
var __hasOwnProp$
|
|
161
|
-
var __propIsEnum$
|
|
162
|
-
var __defNormalProp$
|
|
455
|
+
var __defProp$p = Object.defineProperty;
|
|
456
|
+
var __getOwnPropSymbols$q = Object.getOwnPropertySymbols;
|
|
457
|
+
var __hasOwnProp$q = Object.prototype.hasOwnProperty;
|
|
458
|
+
var __propIsEnum$q = Object.prototype.propertyIsEnumerable;
|
|
459
|
+
var __defNormalProp$p = (obj, key, value) => key in obj ? __defProp$p(obj, key, {
|
|
163
460
|
enumerable: true,
|
|
164
461
|
configurable: true,
|
|
165
462
|
writable: true,
|
|
166
463
|
value
|
|
167
464
|
}) : obj[key] = value;
|
|
168
|
-
var __spreadValues$
|
|
169
|
-
for (var prop in b || (b = {})) if (__hasOwnProp$
|
|
170
|
-
if (__getOwnPropSymbols$
|
|
171
|
-
if (__propIsEnum$
|
|
465
|
+
var __spreadValues$p = (a, b) => {
|
|
466
|
+
for (var prop in b || (b = {})) if (__hasOwnProp$q.call(b, prop)) __defNormalProp$p(a, prop, b[prop]);
|
|
467
|
+
if (__getOwnPropSymbols$q) for (var prop of __getOwnPropSymbols$q(b)) {
|
|
468
|
+
if (__propIsEnum$q.call(b, prop)) __defNormalProp$p(a, prop, b[prop]);
|
|
172
469
|
}
|
|
173
470
|
return a;
|
|
174
471
|
};
|
|
175
|
-
var __objRest$
|
|
472
|
+
var __objRest$l = (source, exclude) => {
|
|
176
473
|
var target = {};
|
|
177
|
-
for (var prop in source) if (__hasOwnProp$
|
|
178
|
-
if (source != null && __getOwnPropSymbols$
|
|
179
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
474
|
+
for (var prop in source) if (__hasOwnProp$q.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
|
|
475
|
+
if (source != null && __getOwnPropSymbols$q) for (var prop of __getOwnPropSymbols$q(source)) {
|
|
476
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$q.call(source, prop)) target[prop] = source[prop];
|
|
180
477
|
}
|
|
181
478
|
return target;
|
|
182
479
|
};
|
|
@@ -199,11 +496,11 @@ const Button = React.forwardRef((props, ref) => {
|
|
|
199
496
|
onMouseLeave,
|
|
200
497
|
size = "middle"
|
|
201
498
|
} = _a,
|
|
202
|
-
restProps = __objRest$
|
|
499
|
+
restProps = __objRest$l(_a, ["type", "className", "children", "prefixIcon", "hoverPrefixIcon", "suffixIcon", "hoverSuffixIcon", "onMouseEnter", "onMouseLeave", "size"]);
|
|
203
500
|
const [status, setStatus] = useState("normal");
|
|
204
501
|
const hasIcon = prefixIcon || suffixIcon;
|
|
205
502
|
const hasHoverIcon = hoverPrefixIcon || hoverSuffixIcon;
|
|
206
|
-
return /* @__PURE__ */React.createElement(Button$1, __spreadValues$
|
|
503
|
+
return /* @__PURE__ */React.createElement(Button$1, __spreadValues$p({
|
|
207
504
|
ref,
|
|
208
505
|
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"),
|
|
209
506
|
type: isAntdButtonTypes(type) ? type : void 0,
|
|
@@ -233,31 +530,31 @@ const Button = React.forwardRef((props, ref) => {
|
|
|
233
530
|
}));
|
|
234
531
|
});
|
|
235
532
|
|
|
236
|
-
var __defProp$
|
|
237
|
-
var __defProps$
|
|
238
|
-
var __getOwnPropDescs$
|
|
239
|
-
var __getOwnPropSymbols$
|
|
240
|
-
var __hasOwnProp$
|
|
241
|
-
var __propIsEnum$
|
|
242
|
-
var __defNormalProp$
|
|
533
|
+
var __defProp$o = Object.defineProperty;
|
|
534
|
+
var __defProps$i = Object.defineProperties;
|
|
535
|
+
var __getOwnPropDescs$i = Object.getOwnPropertyDescriptors;
|
|
536
|
+
var __getOwnPropSymbols$p = Object.getOwnPropertySymbols;
|
|
537
|
+
var __hasOwnProp$p = Object.prototype.hasOwnProperty;
|
|
538
|
+
var __propIsEnum$p = Object.prototype.propertyIsEnumerable;
|
|
539
|
+
var __defNormalProp$o = (obj, key, value) => key in obj ? __defProp$o(obj, key, {
|
|
243
540
|
enumerable: true,
|
|
244
541
|
configurable: true,
|
|
245
542
|
writable: true,
|
|
246
543
|
value
|
|
247
544
|
}) : obj[key] = value;
|
|
248
|
-
var __spreadValues$
|
|
249
|
-
for (var prop in b || (b = {})) if (__hasOwnProp$
|
|
250
|
-
if (__getOwnPropSymbols$
|
|
251
|
-
if (__propIsEnum$
|
|
545
|
+
var __spreadValues$o = (a, b) => {
|
|
546
|
+
for (var prop in b || (b = {})) if (__hasOwnProp$p.call(b, prop)) __defNormalProp$o(a, prop, b[prop]);
|
|
547
|
+
if (__getOwnPropSymbols$p) for (var prop of __getOwnPropSymbols$p(b)) {
|
|
548
|
+
if (__propIsEnum$p.call(b, prop)) __defNormalProp$o(a, prop, b[prop]);
|
|
252
549
|
}
|
|
253
550
|
return a;
|
|
254
551
|
};
|
|
255
|
-
var __spreadProps$
|
|
256
|
-
var __objRest$
|
|
552
|
+
var __spreadProps$i = (a, b) => __defProps$i(a, __getOwnPropDescs$i(b));
|
|
553
|
+
var __objRest$k = (source, exclude) => {
|
|
257
554
|
var target = {};
|
|
258
|
-
for (var prop in source) if (__hasOwnProp$
|
|
259
|
-
if (source != null && __getOwnPropSymbols$
|
|
260
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
555
|
+
for (var prop in source) if (__hasOwnProp$p.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
|
|
556
|
+
if (source != null && __getOwnPropSymbols$p) for (var prop of __getOwnPropSymbols$p(source)) {
|
|
557
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$p.call(source, prop)) target[prop] = source[prop];
|
|
261
558
|
}
|
|
262
559
|
return target;
|
|
263
560
|
};
|
|
@@ -270,8 +567,8 @@ const Checkbox = _a => {
|
|
|
270
567
|
description,
|
|
271
568
|
compact
|
|
272
569
|
} = _b,
|
|
273
|
-
props = __objRest$
|
|
274
|
-
return /* @__PURE__ */React.createElement(Checkbox$1, __spreadProps$
|
|
570
|
+
props = __objRest$k(_b, ["className", "children", "description", "compact"]);
|
|
571
|
+
return /* @__PURE__ */React.createElement(Checkbox$1, __spreadProps$i(__spreadValues$o({}, props), {
|
|
275
572
|
"data-test": props["data-test"] || props.value,
|
|
276
573
|
className: cs(className, CheckboxStyle, compact && "compact")
|
|
277
574
|
}), children ? /* @__PURE__ */React.createElement(React.Fragment, null, /* @__PURE__ */React.createElement("div", {
|
|
@@ -281,39 +578,39 @@ const Checkbox = _a => {
|
|
|
281
578
|
}, description) : null) : null);
|
|
282
579
|
};
|
|
283
580
|
|
|
284
|
-
var __defProp$
|
|
285
|
-
var __getOwnPropSymbols$
|
|
286
|
-
var __hasOwnProp$
|
|
287
|
-
var __propIsEnum$
|
|
288
|
-
var __defNormalProp$
|
|
289
|
-
var __spreadValues$
|
|
581
|
+
var __defProp$n = Object.defineProperty;
|
|
582
|
+
var __getOwnPropSymbols$o = Object.getOwnPropertySymbols;
|
|
583
|
+
var __hasOwnProp$o = Object.prototype.hasOwnProperty;
|
|
584
|
+
var __propIsEnum$o = Object.prototype.propertyIsEnumerable;
|
|
585
|
+
var __defNormalProp$n = (obj, key, value) => key in obj ? __defProp$n(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
586
|
+
var __spreadValues$n = (a, b) => {
|
|
290
587
|
for (var prop in b || (b = {}))
|
|
291
|
-
if (__hasOwnProp$
|
|
292
|
-
__defNormalProp$
|
|
293
|
-
if (__getOwnPropSymbols$
|
|
294
|
-
for (var prop of __getOwnPropSymbols$
|
|
295
|
-
if (__propIsEnum$
|
|
296
|
-
__defNormalProp$
|
|
588
|
+
if (__hasOwnProp$o.call(b, prop))
|
|
589
|
+
__defNormalProp$n(a, prop, b[prop]);
|
|
590
|
+
if (__getOwnPropSymbols$o)
|
|
591
|
+
for (var prop of __getOwnPropSymbols$o(b)) {
|
|
592
|
+
if (__propIsEnum$o.call(b, prop))
|
|
593
|
+
__defNormalProp$n(a, prop, b[prop]);
|
|
297
594
|
}
|
|
298
595
|
return a;
|
|
299
596
|
};
|
|
300
|
-
var __objRest$
|
|
597
|
+
var __objRest$j = (source, exclude) => {
|
|
301
598
|
var target = {};
|
|
302
599
|
for (var prop in source)
|
|
303
|
-
if (__hasOwnProp$
|
|
600
|
+
if (__hasOwnProp$o.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
304
601
|
target[prop] = source[prop];
|
|
305
|
-
if (source != null && __getOwnPropSymbols$
|
|
306
|
-
for (var prop of __getOwnPropSymbols$
|
|
307
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
602
|
+
if (source != null && __getOwnPropSymbols$o)
|
|
603
|
+
for (var prop of __getOwnPropSymbols$o(source)) {
|
|
604
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$o.call(source, prop))
|
|
308
605
|
target[prop] = source[prop];
|
|
309
606
|
}
|
|
310
607
|
return target;
|
|
311
608
|
};
|
|
312
609
|
const FieldsBoolean = (_a) => {
|
|
313
|
-
var _b = _a, { input, children } = _b, props = __objRest$
|
|
610
|
+
var _b = _a, { input, children } = _b, props = __objRest$j(_b, ["input", "children"]);
|
|
314
611
|
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(
|
|
315
612
|
Checkbox,
|
|
316
|
-
__spreadValues$
|
|
613
|
+
__spreadValues$n({
|
|
317
614
|
checked: Boolean(input.value),
|
|
318
615
|
onChange: (e) => input.onChange(e.target.checked)
|
|
319
616
|
}, props),
|
|
@@ -338,17 +635,17 @@ const FieldsDateTime = ({ input }) => /* @__PURE__ */ React.createElement(React.
|
|
|
338
635
|
}
|
|
339
636
|
));
|
|
340
637
|
|
|
341
|
-
var __getOwnPropSymbols$
|
|
342
|
-
var __hasOwnProp$
|
|
343
|
-
var __propIsEnum$
|
|
344
|
-
var __objRest$
|
|
638
|
+
var __getOwnPropSymbols$n = Object.getOwnPropertySymbols;
|
|
639
|
+
var __hasOwnProp$n = Object.prototype.hasOwnProperty;
|
|
640
|
+
var __propIsEnum$n = Object.prototype.propertyIsEnumerable;
|
|
641
|
+
var __objRest$i = (source, exclude) => {
|
|
345
642
|
var target = {};
|
|
346
643
|
for (var prop in source)
|
|
347
|
-
if (__hasOwnProp$
|
|
644
|
+
if (__hasOwnProp$n.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
348
645
|
target[prop] = source[prop];
|
|
349
|
-
if (source != null && __getOwnPropSymbols$
|
|
350
|
-
for (var prop of __getOwnPropSymbols$
|
|
351
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
646
|
+
if (source != null && __getOwnPropSymbols$n)
|
|
647
|
+
for (var prop of __getOwnPropSymbols$n(source)) {
|
|
648
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$n.call(source, prop))
|
|
352
649
|
target[prop] = source[prop];
|
|
353
650
|
}
|
|
354
651
|
return target;
|
|
@@ -356,7 +653,7 @@ var __objRest$k = (source, exclude) => {
|
|
|
356
653
|
const FieldsDateTimeRange = (_a) => {
|
|
357
654
|
var _b = _a, {
|
|
358
655
|
input
|
|
359
|
-
} = _b, props = __objRest$
|
|
656
|
+
} = _b, props = __objRest$i(_b, [
|
|
360
657
|
"input"
|
|
361
658
|
]);
|
|
362
659
|
var _a2, _b2;
|
|
@@ -398,53 +695,53 @@ const THEAD_SELECTOR = ".ant-table-thead";
|
|
|
398
695
|
const TBODY_SELECTOR = ".ant-table-tbody";
|
|
399
696
|
const MODAL_WHITELIST = [".ant-select-dropdown", ".ant-picker-dropdown", ".ant-dropdown", ".ant-dropdown-menu-submenu", ".ant-tooltip", ".ant-dropdown-menu-item-group-list"];
|
|
400
697
|
|
|
401
|
-
var __defProp$
|
|
402
|
-
var __getOwnPropSymbols$
|
|
403
|
-
var __hasOwnProp$
|
|
404
|
-
var __propIsEnum$
|
|
405
|
-
var __defNormalProp$
|
|
406
|
-
var __spreadValues$
|
|
698
|
+
var __defProp$m = Object.defineProperty;
|
|
699
|
+
var __getOwnPropSymbols$m = Object.getOwnPropertySymbols;
|
|
700
|
+
var __hasOwnProp$m = Object.prototype.hasOwnProperty;
|
|
701
|
+
var __propIsEnum$m = Object.prototype.propertyIsEnumerable;
|
|
702
|
+
var __defNormalProp$m = (obj, key, value) => key in obj ? __defProp$m(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
703
|
+
var __spreadValues$m = (a, b) => {
|
|
407
704
|
for (var prop in b || (b = {}))
|
|
408
|
-
if (__hasOwnProp$
|
|
409
|
-
__defNormalProp$
|
|
410
|
-
if (__getOwnPropSymbols$
|
|
411
|
-
for (var prop of __getOwnPropSymbols$
|
|
412
|
-
if (__propIsEnum$
|
|
413
|
-
__defNormalProp$
|
|
705
|
+
if (__hasOwnProp$m.call(b, prop))
|
|
706
|
+
__defNormalProp$m(a, prop, b[prop]);
|
|
707
|
+
if (__getOwnPropSymbols$m)
|
|
708
|
+
for (var prop of __getOwnPropSymbols$m(b)) {
|
|
709
|
+
if (__propIsEnum$m.call(b, prop))
|
|
710
|
+
__defNormalProp$m(a, prop, b[prop]);
|
|
414
711
|
}
|
|
415
712
|
return a;
|
|
416
713
|
};
|
|
417
714
|
const Loading = ({ fullView = true }) => {
|
|
418
715
|
const Wrapper = fullView ? FullView : Fragment;
|
|
419
716
|
const props = fullView ? { className: "loading-full-view" } : {};
|
|
420
|
-
return /* @__PURE__ */ React.createElement(Wrapper, __spreadValues$
|
|
717
|
+
return /* @__PURE__ */ React.createElement(Wrapper, __spreadValues$m({}, 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" })));
|
|
421
718
|
};
|
|
422
719
|
|
|
423
|
-
var __defProp$
|
|
424
|
-
var __defProps$
|
|
425
|
-
var __getOwnPropDescs$
|
|
426
|
-
var __getOwnPropSymbols$
|
|
427
|
-
var __hasOwnProp$
|
|
428
|
-
var __propIsEnum$
|
|
429
|
-
var __defNormalProp$
|
|
720
|
+
var __defProp$l = Object.defineProperty;
|
|
721
|
+
var __defProps$h = Object.defineProperties;
|
|
722
|
+
var __getOwnPropDescs$h = Object.getOwnPropertyDescriptors;
|
|
723
|
+
var __getOwnPropSymbols$l = Object.getOwnPropertySymbols;
|
|
724
|
+
var __hasOwnProp$l = Object.prototype.hasOwnProperty;
|
|
725
|
+
var __propIsEnum$l = Object.prototype.propertyIsEnumerable;
|
|
726
|
+
var __defNormalProp$l = (obj, key, value) => key in obj ? __defProp$l(obj, key, {
|
|
430
727
|
enumerable: true,
|
|
431
728
|
configurable: true,
|
|
432
729
|
writable: true,
|
|
433
730
|
value
|
|
434
731
|
}) : obj[key] = value;
|
|
435
|
-
var __spreadValues$
|
|
436
|
-
for (var prop in b || (b = {})) if (__hasOwnProp$
|
|
437
|
-
if (__getOwnPropSymbols$
|
|
438
|
-
if (__propIsEnum$
|
|
732
|
+
var __spreadValues$l = (a, b) => {
|
|
733
|
+
for (var prop in b || (b = {})) if (__hasOwnProp$l.call(b, prop)) __defNormalProp$l(a, prop, b[prop]);
|
|
734
|
+
if (__getOwnPropSymbols$l) for (var prop of __getOwnPropSymbols$l(b)) {
|
|
735
|
+
if (__propIsEnum$l.call(b, prop)) __defNormalProp$l(a, prop, b[prop]);
|
|
439
736
|
}
|
|
440
737
|
return a;
|
|
441
738
|
};
|
|
442
|
-
var __spreadProps$
|
|
443
|
-
var __objRest$
|
|
739
|
+
var __spreadProps$h = (a, b) => __defProps$h(a, __getOwnPropDescs$h(b));
|
|
740
|
+
var __objRest$h = (source, exclude) => {
|
|
444
741
|
var target = {};
|
|
445
|
-
for (var prop in source) if (__hasOwnProp$
|
|
446
|
-
if (source != null && __getOwnPropSymbols$
|
|
447
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
742
|
+
for (var prop in source) if (__hasOwnProp$l.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
|
|
743
|
+
if (source != null && __getOwnPropSymbols$l) for (var prop of __getOwnPropSymbols$l(source)) {
|
|
744
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$l.call(source, prop)) target[prop] = source[prop];
|
|
448
745
|
}
|
|
449
746
|
return target;
|
|
450
747
|
};
|
|
@@ -472,7 +769,7 @@ const Select = _a => {
|
|
|
472
769
|
meta,
|
|
473
770
|
placeholder
|
|
474
771
|
} = _b,
|
|
475
|
-
restProps = __objRest$
|
|
772
|
+
restProps = __objRest$h(_b, ["input", "multiple", "className", "scrollBottomBuffer", "onScrollBottom", "onPopupScroll", "onSearch", "showSearch", "filterOption", "loading", "notFoundContent", "children", "error", "selectLimit", "dropdownClassName", "danger", "size", "meta", "placeholder"]);
|
|
476
773
|
var _a2;
|
|
477
774
|
const limitExceeded = multiple && selectLimit && selectLimit <= (((_a2 = input.value) == null ? void 0 : _a2.length) || 0);
|
|
478
775
|
const typo = {
|
|
@@ -498,7 +795,7 @@ const Select = _a => {
|
|
|
498
795
|
inputDom && (placeholder || item) && inputDom.setAttribute("data-test", String(placeholder || item.textContent));
|
|
499
796
|
}
|
|
500
797
|
}, [selectRef, placeholder]);
|
|
501
|
-
return /* @__PURE__ */React.createElement(Select$1, __spreadValues$
|
|
798
|
+
return /* @__PURE__ */React.createElement(Select$1, __spreadValues$l(__spreadProps$h(__spreadValues$l({}, input), {
|
|
502
799
|
ref: selectRef,
|
|
503
800
|
size,
|
|
504
801
|
value: multiple ? input.value || [] : input.value || void 0,
|
|
@@ -538,38 +835,38 @@ const Select = _a => {
|
|
|
538
835
|
loading,
|
|
539
836
|
placeholder
|
|
540
837
|
}), restProps), React.Children.map(children, child => {
|
|
541
|
-
return isElement(child) ? __spreadProps$
|
|
542
|
-
props: __spreadProps$
|
|
838
|
+
return isElement(child) ? __spreadProps$h(__spreadValues$l({}, child), {
|
|
839
|
+
props: __spreadProps$h(__spreadValues$l({}, child.props), {
|
|
543
840
|
"data-test": child.props.value
|
|
544
841
|
})
|
|
545
842
|
}) : child;
|
|
546
843
|
}));
|
|
547
844
|
};
|
|
548
845
|
|
|
549
|
-
var __defProp$
|
|
550
|
-
var __getOwnPropSymbols$
|
|
551
|
-
var __hasOwnProp$
|
|
552
|
-
var __propIsEnum$
|
|
553
|
-
var __defNormalProp$
|
|
554
|
-
var __spreadValues$
|
|
846
|
+
var __defProp$k = Object.defineProperty;
|
|
847
|
+
var __getOwnPropSymbols$k = Object.getOwnPropertySymbols;
|
|
848
|
+
var __hasOwnProp$k = Object.prototype.hasOwnProperty;
|
|
849
|
+
var __propIsEnum$k = Object.prototype.propertyIsEnumerable;
|
|
850
|
+
var __defNormalProp$k = (obj, key, value) => key in obj ? __defProp$k(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
851
|
+
var __spreadValues$k = (a, b) => {
|
|
555
852
|
for (var prop in b || (b = {}))
|
|
556
|
-
if (__hasOwnProp$
|
|
557
|
-
__defNormalProp$
|
|
558
|
-
if (__getOwnPropSymbols$
|
|
559
|
-
for (var prop of __getOwnPropSymbols$
|
|
560
|
-
if (__propIsEnum$
|
|
561
|
-
__defNormalProp$
|
|
853
|
+
if (__hasOwnProp$k.call(b, prop))
|
|
854
|
+
__defNormalProp$k(a, prop, b[prop]);
|
|
855
|
+
if (__getOwnPropSymbols$k)
|
|
856
|
+
for (var prop of __getOwnPropSymbols$k(b)) {
|
|
857
|
+
if (__propIsEnum$k.call(b, prop))
|
|
858
|
+
__defNormalProp$k(a, prop, b[prop]);
|
|
562
859
|
}
|
|
563
860
|
return a;
|
|
564
861
|
};
|
|
565
|
-
var __objRest$
|
|
862
|
+
var __objRest$g = (source, exclude) => {
|
|
566
863
|
var target = {};
|
|
567
864
|
for (var prop in source)
|
|
568
|
-
if (__hasOwnProp$
|
|
865
|
+
if (__hasOwnProp$k.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
569
866
|
target[prop] = source[prop];
|
|
570
|
-
if (source != null && __getOwnPropSymbols$
|
|
571
|
-
for (var prop of __getOwnPropSymbols$
|
|
572
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
867
|
+
if (source != null && __getOwnPropSymbols$k)
|
|
868
|
+
for (var prop of __getOwnPropSymbols$k(source)) {
|
|
869
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$k.call(source, prop))
|
|
573
870
|
target[prop] = source[prop];
|
|
574
871
|
}
|
|
575
872
|
return target;
|
|
@@ -579,12 +876,12 @@ const FieldsEnum = (_a) => {
|
|
|
579
876
|
meta: __,
|
|
580
877
|
enumValues,
|
|
581
878
|
emptyLabel
|
|
582
|
-
} = _b, restProps = __objRest$
|
|
879
|
+
} = _b, restProps = __objRest$g(_b, [
|
|
583
880
|
"meta",
|
|
584
881
|
"enumValues",
|
|
585
882
|
"emptyLabel"
|
|
586
883
|
]);
|
|
587
|
-
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(Select, __spreadValues$
|
|
884
|
+
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(Select, __spreadValues$k({}, restProps), emptyLabel && /* @__PURE__ */ React.createElement(Select$1.Option, { value: "" }, emptyLabel), enumValues.map((v) => {
|
|
588
885
|
const item = typeof v === "string" ? { value: v, text: v } : v;
|
|
589
886
|
return /* @__PURE__ */ React.createElement(
|
|
590
887
|
Select$1.Option,
|
|
@@ -598,31 +895,31 @@ const FieldsEnum = (_a) => {
|
|
|
598
895
|
})));
|
|
599
896
|
};
|
|
600
897
|
|
|
601
|
-
var __defProp$
|
|
602
|
-
var __defProps$
|
|
603
|
-
var __getOwnPropDescs$
|
|
604
|
-
var __getOwnPropSymbols$
|
|
605
|
-
var __hasOwnProp$
|
|
606
|
-
var __propIsEnum$
|
|
607
|
-
var __defNormalProp$
|
|
898
|
+
var __defProp$j = Object.defineProperty;
|
|
899
|
+
var __defProps$g = Object.defineProperties;
|
|
900
|
+
var __getOwnPropDescs$g = Object.getOwnPropertyDescriptors;
|
|
901
|
+
var __getOwnPropSymbols$j = Object.getOwnPropertySymbols;
|
|
902
|
+
var __hasOwnProp$j = Object.prototype.hasOwnProperty;
|
|
903
|
+
var __propIsEnum$j = Object.prototype.propertyIsEnumerable;
|
|
904
|
+
var __defNormalProp$j = (obj, key, value) => key in obj ? __defProp$j(obj, key, {
|
|
608
905
|
enumerable: true,
|
|
609
906
|
configurable: true,
|
|
610
907
|
writable: true,
|
|
611
908
|
value
|
|
612
909
|
}) : obj[key] = value;
|
|
613
|
-
var __spreadValues$
|
|
614
|
-
for (var prop in b || (b = {})) if (__hasOwnProp$
|
|
615
|
-
if (__getOwnPropSymbols$
|
|
616
|
-
if (__propIsEnum$
|
|
910
|
+
var __spreadValues$j = (a, b) => {
|
|
911
|
+
for (var prop in b || (b = {})) if (__hasOwnProp$j.call(b, prop)) __defNormalProp$j(a, prop, b[prop]);
|
|
912
|
+
if (__getOwnPropSymbols$j) for (var prop of __getOwnPropSymbols$j(b)) {
|
|
913
|
+
if (__propIsEnum$j.call(b, prop)) __defNormalProp$j(a, prop, b[prop]);
|
|
617
914
|
}
|
|
618
915
|
return a;
|
|
619
916
|
};
|
|
620
|
-
var __spreadProps$
|
|
621
|
-
var __objRest$
|
|
917
|
+
var __spreadProps$g = (a, b) => __defProps$g(a, __getOwnPropDescs$g(b));
|
|
918
|
+
var __objRest$f = (source, exclude) => {
|
|
622
919
|
var target = {};
|
|
623
|
-
for (var prop in source) if (__hasOwnProp$
|
|
624
|
-
if (source != null && __getOwnPropSymbols$
|
|
625
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
920
|
+
for (var prop in source) if (__hasOwnProp$j.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
|
|
921
|
+
if (source != null && __getOwnPropSymbols$j) for (var prop of __getOwnPropSymbols$j(source)) {
|
|
922
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$j.call(source, prop)) target[prop] = source[prop];
|
|
626
923
|
}
|
|
627
924
|
return target;
|
|
628
925
|
};
|
|
@@ -658,13 +955,13 @@ const InputNumber = _a => {
|
|
|
658
955
|
prefix,
|
|
659
956
|
controls = true
|
|
660
957
|
} = _b,
|
|
661
|
-
props = __objRest$
|
|
958
|
+
props = __objRest$f(_b, ["className", "error", "size", "suffix", "prefix", "controls"]);
|
|
662
959
|
const typo = {
|
|
663
960
|
large: Typo.Label.l2_regular,
|
|
664
961
|
middle: Typo.Label.l3_regular,
|
|
665
962
|
small: Typo.Label.l4_regular
|
|
666
963
|
}[size];
|
|
667
|
-
return /* @__PURE__ */React.createElement(AntdInputNumberStyled, __spreadProps$
|
|
964
|
+
return /* @__PURE__ */React.createElement(AntdInputNumberStyled, __spreadProps$g(__spreadValues$j({}, props), {
|
|
668
965
|
size,
|
|
669
966
|
controls,
|
|
670
967
|
"data-test": props.name,
|
|
@@ -674,33 +971,33 @@ const InputNumber = _a => {
|
|
|
674
971
|
}));
|
|
675
972
|
};
|
|
676
973
|
|
|
677
|
-
var __defProp$
|
|
678
|
-
var __defProps$
|
|
679
|
-
var __getOwnPropDescs$
|
|
680
|
-
var __getOwnPropSymbols$
|
|
681
|
-
var __hasOwnProp$
|
|
682
|
-
var __propIsEnum$
|
|
683
|
-
var __defNormalProp$
|
|
684
|
-
var __spreadValues$
|
|
974
|
+
var __defProp$i = Object.defineProperty;
|
|
975
|
+
var __defProps$f = Object.defineProperties;
|
|
976
|
+
var __getOwnPropDescs$f = Object.getOwnPropertyDescriptors;
|
|
977
|
+
var __getOwnPropSymbols$i = Object.getOwnPropertySymbols;
|
|
978
|
+
var __hasOwnProp$i = Object.prototype.hasOwnProperty;
|
|
979
|
+
var __propIsEnum$i = Object.prototype.propertyIsEnumerable;
|
|
980
|
+
var __defNormalProp$i = (obj, key, value) => key in obj ? __defProp$i(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
981
|
+
var __spreadValues$i = (a, b) => {
|
|
685
982
|
for (var prop in b || (b = {}))
|
|
686
|
-
if (__hasOwnProp$
|
|
687
|
-
__defNormalProp$
|
|
688
|
-
if (__getOwnPropSymbols$
|
|
689
|
-
for (var prop of __getOwnPropSymbols$
|
|
690
|
-
if (__propIsEnum$
|
|
691
|
-
__defNormalProp$
|
|
983
|
+
if (__hasOwnProp$i.call(b, prop))
|
|
984
|
+
__defNormalProp$i(a, prop, b[prop]);
|
|
985
|
+
if (__getOwnPropSymbols$i)
|
|
986
|
+
for (var prop of __getOwnPropSymbols$i(b)) {
|
|
987
|
+
if (__propIsEnum$i.call(b, prop))
|
|
988
|
+
__defNormalProp$i(a, prop, b[prop]);
|
|
692
989
|
}
|
|
693
990
|
return a;
|
|
694
991
|
};
|
|
695
|
-
var __spreadProps$
|
|
696
|
-
var __objRest$
|
|
992
|
+
var __spreadProps$f = (a, b) => __defProps$f(a, __getOwnPropDescs$f(b));
|
|
993
|
+
var __objRest$e = (source, exclude) => {
|
|
697
994
|
var target = {};
|
|
698
995
|
for (var prop in source)
|
|
699
|
-
if (__hasOwnProp$
|
|
996
|
+
if (__hasOwnProp$i.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
700
997
|
target[prop] = source[prop];
|
|
701
|
-
if (source != null && __getOwnPropSymbols$
|
|
702
|
-
for (var prop of __getOwnPropSymbols$
|
|
703
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
998
|
+
if (source != null && __getOwnPropSymbols$i)
|
|
999
|
+
for (var prop of __getOwnPropSymbols$i(source)) {
|
|
1000
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$i.call(source, prop))
|
|
704
1001
|
target[prop] = source[prop];
|
|
705
1002
|
}
|
|
706
1003
|
return target;
|
|
@@ -711,7 +1008,7 @@ const FieldsFloat = (_a) => {
|
|
|
711
1008
|
meta,
|
|
712
1009
|
onBlur,
|
|
713
1010
|
autoComplete = "off"
|
|
714
|
-
} = _b, props = __objRest$
|
|
1011
|
+
} = _b, props = __objRest$e(_b, [
|
|
715
1012
|
"input",
|
|
716
1013
|
"meta",
|
|
717
1014
|
"onBlur",
|
|
@@ -719,7 +1016,7 @@ const FieldsFloat = (_a) => {
|
|
|
719
1016
|
]);
|
|
720
1017
|
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(
|
|
721
1018
|
InputNumber,
|
|
722
|
-
__spreadValues$
|
|
1019
|
+
__spreadValues$i(__spreadProps$f(__spreadValues$i({}, input), {
|
|
723
1020
|
onBlur: (e) => onBlur ? onBlur(input, e) : input.onBlur(e),
|
|
724
1021
|
autoComplete,
|
|
725
1022
|
error: meta.touched && (meta.error || !meta.dirtySinceLastSubmit && meta.submitError)
|
|
@@ -727,33 +1024,33 @@ const FieldsFloat = (_a) => {
|
|
|
727
1024
|
));
|
|
728
1025
|
};
|
|
729
1026
|
|
|
730
|
-
var __defProp$
|
|
731
|
-
var __defProps$
|
|
732
|
-
var __getOwnPropDescs$
|
|
733
|
-
var __getOwnPropSymbols$
|
|
734
|
-
var __hasOwnProp$
|
|
735
|
-
var __propIsEnum$
|
|
736
|
-
var __defNormalProp$
|
|
737
|
-
var __spreadValues$
|
|
1027
|
+
var __defProp$h = Object.defineProperty;
|
|
1028
|
+
var __defProps$e = Object.defineProperties;
|
|
1029
|
+
var __getOwnPropDescs$e = Object.getOwnPropertyDescriptors;
|
|
1030
|
+
var __getOwnPropSymbols$h = Object.getOwnPropertySymbols;
|
|
1031
|
+
var __hasOwnProp$h = Object.prototype.hasOwnProperty;
|
|
1032
|
+
var __propIsEnum$h = Object.prototype.propertyIsEnumerable;
|
|
1033
|
+
var __defNormalProp$h = (obj, key, value) => key in obj ? __defProp$h(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
1034
|
+
var __spreadValues$h = (a, b) => {
|
|
738
1035
|
for (var prop in b || (b = {}))
|
|
739
|
-
if (__hasOwnProp$
|
|
740
|
-
__defNormalProp$
|
|
741
|
-
if (__getOwnPropSymbols$
|
|
742
|
-
for (var prop of __getOwnPropSymbols$
|
|
743
|
-
if (__propIsEnum$
|
|
744
|
-
__defNormalProp$
|
|
1036
|
+
if (__hasOwnProp$h.call(b, prop))
|
|
1037
|
+
__defNormalProp$h(a, prop, b[prop]);
|
|
1038
|
+
if (__getOwnPropSymbols$h)
|
|
1039
|
+
for (var prop of __getOwnPropSymbols$h(b)) {
|
|
1040
|
+
if (__propIsEnum$h.call(b, prop))
|
|
1041
|
+
__defNormalProp$h(a, prop, b[prop]);
|
|
745
1042
|
}
|
|
746
1043
|
return a;
|
|
747
1044
|
};
|
|
748
|
-
var __spreadProps$
|
|
749
|
-
var __objRest$
|
|
1045
|
+
var __spreadProps$e = (a, b) => __defProps$e(a, __getOwnPropDescs$e(b));
|
|
1046
|
+
var __objRest$d = (source, exclude) => {
|
|
750
1047
|
var target = {};
|
|
751
1048
|
for (var prop in source)
|
|
752
|
-
if (__hasOwnProp$
|
|
1049
|
+
if (__hasOwnProp$h.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
753
1050
|
target[prop] = source[prop];
|
|
754
|
-
if (source != null && __getOwnPropSymbols$
|
|
755
|
-
for (var prop of __getOwnPropSymbols$
|
|
756
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
1051
|
+
if (source != null && __getOwnPropSymbols$h)
|
|
1052
|
+
for (var prop of __getOwnPropSymbols$h(source)) {
|
|
1053
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$h.call(source, prop))
|
|
757
1054
|
target[prop] = source[prop];
|
|
758
1055
|
}
|
|
759
1056
|
return target;
|
|
@@ -763,7 +1060,7 @@ const Input = (_a) => {
|
|
|
763
1060
|
className,
|
|
764
1061
|
error,
|
|
765
1062
|
size = "middle"
|
|
766
|
-
} = _b, props = __objRest$
|
|
1063
|
+
} = _b, props = __objRest$d(_b, [
|
|
767
1064
|
"className",
|
|
768
1065
|
"error",
|
|
769
1066
|
"size"
|
|
@@ -775,7 +1072,7 @@ const Input = (_a) => {
|
|
|
775
1072
|
}[size];
|
|
776
1073
|
return /* @__PURE__ */ React.createElement(
|
|
777
1074
|
Input$1,
|
|
778
|
-
__spreadProps$
|
|
1075
|
+
__spreadProps$e(__spreadValues$h({}, props), {
|
|
779
1076
|
size,
|
|
780
1077
|
"data-test": props.name,
|
|
781
1078
|
className: cs(className, InputStyle, typo, error ? "error" : "")
|
|
@@ -783,33 +1080,33 @@ const Input = (_a) => {
|
|
|
783
1080
|
);
|
|
784
1081
|
};
|
|
785
1082
|
|
|
786
|
-
var __defProp$
|
|
787
|
-
var __defProps$
|
|
788
|
-
var __getOwnPropDescs$
|
|
789
|
-
var __getOwnPropSymbols$
|
|
790
|
-
var __hasOwnProp$
|
|
791
|
-
var __propIsEnum$
|
|
792
|
-
var __defNormalProp$
|
|
793
|
-
var __spreadValues$
|
|
1083
|
+
var __defProp$g = Object.defineProperty;
|
|
1084
|
+
var __defProps$d = Object.defineProperties;
|
|
1085
|
+
var __getOwnPropDescs$d = Object.getOwnPropertyDescriptors;
|
|
1086
|
+
var __getOwnPropSymbols$g = Object.getOwnPropertySymbols;
|
|
1087
|
+
var __hasOwnProp$g = Object.prototype.hasOwnProperty;
|
|
1088
|
+
var __propIsEnum$g = Object.prototype.propertyIsEnumerable;
|
|
1089
|
+
var __defNormalProp$g = (obj, key, value) => key in obj ? __defProp$g(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
1090
|
+
var __spreadValues$g = (a, b) => {
|
|
794
1091
|
for (var prop in b || (b = {}))
|
|
795
|
-
if (__hasOwnProp$
|
|
796
|
-
__defNormalProp$
|
|
797
|
-
if (__getOwnPropSymbols$
|
|
798
|
-
for (var prop of __getOwnPropSymbols$
|
|
799
|
-
if (__propIsEnum$
|
|
800
|
-
__defNormalProp$
|
|
1092
|
+
if (__hasOwnProp$g.call(b, prop))
|
|
1093
|
+
__defNormalProp$g(a, prop, b[prop]);
|
|
1094
|
+
if (__getOwnPropSymbols$g)
|
|
1095
|
+
for (var prop of __getOwnPropSymbols$g(b)) {
|
|
1096
|
+
if (__propIsEnum$g.call(b, prop))
|
|
1097
|
+
__defNormalProp$g(a, prop, b[prop]);
|
|
801
1098
|
}
|
|
802
1099
|
return a;
|
|
803
1100
|
};
|
|
804
|
-
var __spreadProps$
|
|
805
|
-
var __objRest$
|
|
1101
|
+
var __spreadProps$d = (a, b) => __defProps$d(a, __getOwnPropDescs$d(b));
|
|
1102
|
+
var __objRest$c = (source, exclude) => {
|
|
806
1103
|
var target = {};
|
|
807
1104
|
for (var prop in source)
|
|
808
|
-
if (__hasOwnProp$
|
|
1105
|
+
if (__hasOwnProp$g.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
809
1106
|
target[prop] = source[prop];
|
|
810
|
-
if (source != null && __getOwnPropSymbols$
|
|
811
|
-
for (var prop of __getOwnPropSymbols$
|
|
812
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
1107
|
+
if (source != null && __getOwnPropSymbols$g)
|
|
1108
|
+
for (var prop of __getOwnPropSymbols$g(source)) {
|
|
1109
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$g.call(source, prop))
|
|
813
1110
|
target[prop] = source[prop];
|
|
814
1111
|
}
|
|
815
1112
|
return target;
|
|
@@ -821,7 +1118,7 @@ const FieldsInt = (_a) => {
|
|
|
821
1118
|
onBlur,
|
|
822
1119
|
autoComplete = "off",
|
|
823
1120
|
supportNegativeValue = false
|
|
824
|
-
} = _b, props = __objRest$
|
|
1121
|
+
} = _b, props = __objRest$c(_b, [
|
|
825
1122
|
"input",
|
|
826
1123
|
"meta",
|
|
827
1124
|
"onBlur",
|
|
@@ -830,7 +1127,7 @@ const FieldsInt = (_a) => {
|
|
|
830
1127
|
]);
|
|
831
1128
|
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(
|
|
832
1129
|
Input,
|
|
833
|
-
__spreadValues$
|
|
1130
|
+
__spreadValues$g(__spreadProps$d(__spreadValues$g({}, input), {
|
|
834
1131
|
onChange: (e) => {
|
|
835
1132
|
const value = e.currentTarget.value;
|
|
836
1133
|
if (supportNegativeValue) {
|
|
@@ -865,206 +1162,6 @@ const formatterInteger = (value) => {
|
|
|
865
1162
|
}
|
|
866
1163
|
};
|
|
867
1164
|
|
|
868
|
-
var __defProp$i = Object.defineProperty;
|
|
869
|
-
var __defProps$e = Object.defineProperties;
|
|
870
|
-
var __getOwnPropDescs$e = Object.getOwnPropertyDescriptors;
|
|
871
|
-
var __getOwnPropSymbols$i = Object.getOwnPropertySymbols;
|
|
872
|
-
var __hasOwnProp$i = Object.prototype.hasOwnProperty;
|
|
873
|
-
var __propIsEnum$i = Object.prototype.propertyIsEnumerable;
|
|
874
|
-
var __defNormalProp$i = (obj, key, value) => key in obj ? __defProp$i(obj, key, {
|
|
875
|
-
enumerable: true,
|
|
876
|
-
configurable: true,
|
|
877
|
-
writable: true,
|
|
878
|
-
value
|
|
879
|
-
}) : obj[key] = value;
|
|
880
|
-
var __spreadValues$i = (a, b) => {
|
|
881
|
-
for (var prop in b || (b = {})) if (__hasOwnProp$i.call(b, prop)) __defNormalProp$i(a, prop, b[prop]);
|
|
882
|
-
if (__getOwnPropSymbols$i) for (var prop of __getOwnPropSymbols$i(b)) {
|
|
883
|
-
if (__propIsEnum$i.call(b, prop)) __defNormalProp$i(a, prop, b[prop]);
|
|
884
|
-
}
|
|
885
|
-
return a;
|
|
886
|
-
};
|
|
887
|
-
var __spreadProps$e = (a, b) => __defProps$e(a, __getOwnPropDescs$e(b));
|
|
888
|
-
var __objRest$d = (source, exclude) => {
|
|
889
|
-
var target = {};
|
|
890
|
-
for (var prop in source) if (__hasOwnProp$i.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
|
|
891
|
-
if (source != null && __getOwnPropSymbols$i) for (var prop of __getOwnPropSymbols$i(source)) {
|
|
892
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$i.call(source, prop)) target[prop] = source[prop];
|
|
893
|
-
}
|
|
894
|
-
return target;
|
|
895
|
-
};
|
|
896
|
-
const _exp$1 = () => InputNumber$1;
|
|
897
|
-
const _exp2 = () => props => props.controls ? "initial" : "none";
|
|
898
|
-
const _exp3 = () => props => `"${props.suffix ? props.suffix : ""}"`;
|
|
899
|
-
const _exp4 = () => ({
|
|
900
|
-
suffix
|
|
901
|
-
}) => suffix ? "flex" : "none";
|
|
902
|
-
const _exp5 = () => props => `"${props.prefix ? props.prefix : ""}"`;
|
|
903
|
-
const _exp6 = () => ({
|
|
904
|
-
prefix
|
|
905
|
-
}) => prefix ? "flex" : "none";
|
|
906
|
-
const AntdIntStyled = /*#__PURE__*/styled(_exp$1())({
|
|
907
|
-
name: "AntdIntStyled",
|
|
908
|
-
class: "at4ovwe",
|
|
909
|
-
propsAsIs: true,
|
|
910
|
-
vars: {
|
|
911
|
-
"at4ovwe-0": [_exp2()],
|
|
912
|
-
"at4ovwe-1": [_exp3()],
|
|
913
|
-
"at4ovwe-2": [_exp4()],
|
|
914
|
-
"at4ovwe-3": [_exp5()],
|
|
915
|
-
"at4ovwe-4": [_exp6()]
|
|
916
|
-
}
|
|
917
|
-
});
|
|
918
|
-
const InputInteger = _a => {
|
|
919
|
-
var _b = _a,
|
|
920
|
-
{
|
|
921
|
-
className,
|
|
922
|
-
error,
|
|
923
|
-
size = "middle",
|
|
924
|
-
suffix,
|
|
925
|
-
prefix,
|
|
926
|
-
max,
|
|
927
|
-
min,
|
|
928
|
-
controls = false
|
|
929
|
-
} = _b,
|
|
930
|
-
props = __objRest$d(_b, ["className", "error", "size", "suffix", "prefix", "max", "min", "controls"]);
|
|
931
|
-
const typo = {
|
|
932
|
-
large: Typo.Label.l2_regular,
|
|
933
|
-
middle: Typo.Label.l3_regular,
|
|
934
|
-
small: Typo.Label.l4_regular
|
|
935
|
-
}[size];
|
|
936
|
-
return /* @__PURE__ */React.createElement(AntdIntStyled, __spreadProps$e(__spreadValues$i({}, props), {
|
|
937
|
-
size,
|
|
938
|
-
formatter: formatterInteger,
|
|
939
|
-
parser: formatterInteger,
|
|
940
|
-
min,
|
|
941
|
-
max,
|
|
942
|
-
controls,
|
|
943
|
-
"data-test": props.name,
|
|
944
|
-
suffix: controls ? "" : suffix,
|
|
945
|
-
prefix,
|
|
946
|
-
className: cs(className, InputStyle, typo, error ? "error" : "")
|
|
947
|
-
}));
|
|
948
|
-
};
|
|
949
|
-
|
|
950
|
-
var __defProp$h = Object.defineProperty;
|
|
951
|
-
var __defProps$d = Object.defineProperties;
|
|
952
|
-
var __getOwnPropDescs$d = Object.getOwnPropertyDescriptors;
|
|
953
|
-
var __getOwnPropSymbols$h = Object.getOwnPropertySymbols;
|
|
954
|
-
var __hasOwnProp$h = Object.prototype.hasOwnProperty;
|
|
955
|
-
var __propIsEnum$h = Object.prototype.propertyIsEnumerable;
|
|
956
|
-
var __defNormalProp$h = (obj, key, value) => key in obj ? __defProp$h(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
957
|
-
var __spreadValues$h = (a, b) => {
|
|
958
|
-
for (var prop in b || (b = {}))
|
|
959
|
-
if (__hasOwnProp$h.call(b, prop))
|
|
960
|
-
__defNormalProp$h(a, prop, b[prop]);
|
|
961
|
-
if (__getOwnPropSymbols$h)
|
|
962
|
-
for (var prop of __getOwnPropSymbols$h(b)) {
|
|
963
|
-
if (__propIsEnum$h.call(b, prop))
|
|
964
|
-
__defNormalProp$h(a, prop, b[prop]);
|
|
965
|
-
}
|
|
966
|
-
return a;
|
|
967
|
-
};
|
|
968
|
-
var __spreadProps$d = (a, b) => __defProps$d(a, __getOwnPropDescs$d(b));
|
|
969
|
-
var __objRest$c = (source, exclude) => {
|
|
970
|
-
var target = {};
|
|
971
|
-
for (var prop in source)
|
|
972
|
-
if (__hasOwnProp$h.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
973
|
-
target[prop] = source[prop];
|
|
974
|
-
if (source != null && __getOwnPropSymbols$h)
|
|
975
|
-
for (var prop of __getOwnPropSymbols$h(source)) {
|
|
976
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$h.call(source, prop))
|
|
977
|
-
target[prop] = source[prop];
|
|
978
|
-
}
|
|
979
|
-
return target;
|
|
980
|
-
};
|
|
981
|
-
const FieldsInteger = (_a) => {
|
|
982
|
-
var _b = _a, {
|
|
983
|
-
meta,
|
|
984
|
-
input,
|
|
985
|
-
onBlur
|
|
986
|
-
} = _b, props = __objRest$c(_b, [
|
|
987
|
-
"meta",
|
|
988
|
-
"input",
|
|
989
|
-
"onBlur"
|
|
990
|
-
]);
|
|
991
|
-
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(
|
|
992
|
-
InputInteger,
|
|
993
|
-
__spreadProps$d(__spreadValues$h(__spreadValues$h({}, props), input), {
|
|
994
|
-
onBlur: (e) => onBlur ? onBlur(input, e) : input.onBlur(e),
|
|
995
|
-
error: meta.touched && (meta.error || !meta.dirtySinceLastSubmit && meta.submitError)
|
|
996
|
-
})
|
|
997
|
-
));
|
|
998
|
-
};
|
|
999
|
-
|
|
1000
|
-
var __defProp$g = Object.defineProperty;
|
|
1001
|
-
var __getOwnPropSymbols$g = Object.getOwnPropertySymbols;
|
|
1002
|
-
var __hasOwnProp$g = Object.prototype.hasOwnProperty;
|
|
1003
|
-
var __propIsEnum$g = Object.prototype.propertyIsEnumerable;
|
|
1004
|
-
var __defNormalProp$g = (obj, key, value) => key in obj ? __defProp$g(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
1005
|
-
var __spreadValues$g = (a, b) => {
|
|
1006
|
-
for (var prop in b || (b = {}))
|
|
1007
|
-
if (__hasOwnProp$g.call(b, prop))
|
|
1008
|
-
__defNormalProp$g(a, prop, b[prop]);
|
|
1009
|
-
if (__getOwnPropSymbols$g)
|
|
1010
|
-
for (var prop of __getOwnPropSymbols$g(b)) {
|
|
1011
|
-
if (__propIsEnum$g.call(b, prop))
|
|
1012
|
-
__defNormalProp$g(a, prop, b[prop]);
|
|
1013
|
-
}
|
|
1014
|
-
return a;
|
|
1015
|
-
};
|
|
1016
|
-
var __objRest$b = (source, exclude) => {
|
|
1017
|
-
var target = {};
|
|
1018
|
-
for (var prop in source)
|
|
1019
|
-
if (__hasOwnProp$g.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
1020
|
-
target[prop] = source[prop];
|
|
1021
|
-
if (source != null && __getOwnPropSymbols$g)
|
|
1022
|
-
for (var prop of __getOwnPropSymbols$g(source)) {
|
|
1023
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$g.call(source, prop))
|
|
1024
|
-
target[prop] = source[prop];
|
|
1025
|
-
}
|
|
1026
|
-
return target;
|
|
1027
|
-
};
|
|
1028
|
-
const BaseIcon = React.forwardRef(
|
|
1029
|
-
(props, ref) => {
|
|
1030
|
-
const _a = props, {
|
|
1031
|
-
alt,
|
|
1032
|
-
className,
|
|
1033
|
-
width,
|
|
1034
|
-
height,
|
|
1035
|
-
cursor,
|
|
1036
|
-
style,
|
|
1037
|
-
children,
|
|
1038
|
-
prefixNode,
|
|
1039
|
-
suffixIconSrc,
|
|
1040
|
-
src
|
|
1041
|
-
} = _a, HTMLSpanElementProps = __objRest$b(_a, [
|
|
1042
|
-
"alt",
|
|
1043
|
-
"className",
|
|
1044
|
-
"width",
|
|
1045
|
-
"height",
|
|
1046
|
-
"cursor",
|
|
1047
|
-
"style",
|
|
1048
|
-
"children",
|
|
1049
|
-
"prefixNode",
|
|
1050
|
-
"suffixIconSrc",
|
|
1051
|
-
"src"
|
|
1052
|
-
]);
|
|
1053
|
-
return /* @__PURE__ */ React.createElement(
|
|
1054
|
-
"span",
|
|
1055
|
-
__spreadValues$g({
|
|
1056
|
-
ref,
|
|
1057
|
-
className,
|
|
1058
|
-
style: _.pickBy(__spreadValues$g({ cursor }, style))
|
|
1059
|
-
}, HTMLSpanElementProps),
|
|
1060
|
-
prefixNode,
|
|
1061
|
-
/* @__PURE__ */ React.createElement("span", { className: "icon-inner" }, /* @__PURE__ */ React.createElement("img", { alt, src, width, height })),
|
|
1062
|
-
children && /* @__PURE__ */ React.createElement("span", { className: "icon-children" }, children),
|
|
1063
|
-
suffixIconSrc && /* @__PURE__ */ React.createElement("span", { className: "icon-inner suffix" }, /* @__PURE__ */ React.createElement("img", { alt, src: suffixIconSrc, width, height }))
|
|
1064
|
-
);
|
|
1065
|
-
}
|
|
1066
|
-
);
|
|
1067
|
-
|
|
1068
1165
|
var __defProp$f = Object.defineProperty;
|
|
1069
1166
|
var __defProps$c = Object.defineProperties;
|
|
1070
1167
|
var __getOwnPropDescs$c = Object.getOwnPropertyDescriptors;
|
|
@@ -1085,100 +1182,117 @@ var __spreadValues$f = (a, b) => {
|
|
|
1085
1182
|
return a;
|
|
1086
1183
|
};
|
|
1087
1184
|
var __spreadProps$c = (a, b) => __defProps$c(a, __getOwnPropDescs$c(b));
|
|
1088
|
-
var __objRest$
|
|
1185
|
+
var __objRest$b = (source, exclude) => {
|
|
1089
1186
|
var target = {};
|
|
1090
1187
|
for (var prop in source) if (__hasOwnProp$f.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
|
|
1091
1188
|
if (source != null && __getOwnPropSymbols$f) for (var prop of __getOwnPropSymbols$f(source)) {
|
|
1092
1189
|
if (exclude.indexOf(prop) < 0 && __propIsEnum$f.call(source, prop)) target[prop] = source[prop];
|
|
1093
1190
|
}
|
|
1094
|
-
return target;
|
|
1095
|
-
};
|
|
1096
|
-
const
|
|
1097
|
-
const
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
restProps = __objRest$a(_a, ["src", "hoverSrc", "active", "activeSrc", "onMouseEnter", "onMouseLeave", "onMouseMove", "className", "iconWidth", "iconHeight", "cursor", "style", "children", "isRotate", "prefix", "suffix"]);
|
|
1118
|
-
const [hover, setHover] = useState(false);
|
|
1119
|
-
const _src = useMemo(() => {
|
|
1120
|
-
if (active && activeSrc) {
|
|
1121
|
-
return activeSrc;
|
|
1122
|
-
}
|
|
1123
|
-
if (hover && hoverSrc) {
|
|
1124
|
-
return hoverSrc;
|
|
1125
|
-
}
|
|
1126
|
-
return src;
|
|
1127
|
-
}, [active, activeSrc, hover, hoverSrc, src]);
|
|
1128
|
-
const suffixIconSrc = useMemo(() => {
|
|
1129
|
-
if (!suffix) {
|
|
1130
|
-
return void 0;
|
|
1131
|
-
}
|
|
1132
|
-
const {
|
|
1133
|
-
activeSrc: activeSrc2,
|
|
1134
|
-
hoverSrc: hoverSrc2,
|
|
1135
|
-
src: src2
|
|
1136
|
-
} = suffix;
|
|
1137
|
-
if (active && activeSrc2) {
|
|
1138
|
-
return activeSrc2;
|
|
1139
|
-
}
|
|
1140
|
-
if (hover && hoverSrc2) {
|
|
1141
|
-
return hoverSrc2;
|
|
1142
|
-
}
|
|
1143
|
-
return src2;
|
|
1144
|
-
}, [active, hover, suffix]);
|
|
1145
|
-
return /* @__PURE__ */React.createElement(BaseIcon, __spreadProps$c(__spreadValues$f({
|
|
1146
|
-
src: _src,
|
|
1147
|
-
className: cs(IconWrapper, "icon-wrapper", className, isRotate && "is-rotate"),
|
|
1148
|
-
suffixIconSrc,
|
|
1149
|
-
height: iconHeight,
|
|
1150
|
-
width: iconWidth,
|
|
1151
|
-
prefixNode: prefix,
|
|
1152
|
-
style: _.pickBy(__spreadValues$f({
|
|
1153
|
-
cursor
|
|
1154
|
-
}, style))
|
|
1155
|
-
}, restProps), {
|
|
1156
|
-
onMouseEnter: e => {
|
|
1157
|
-
onMouseEnter == null ? void 0 : onMouseEnter(e);
|
|
1158
|
-
if (hover) {
|
|
1159
|
-
setHover(true);
|
|
1160
|
-
}
|
|
1161
|
-
},
|
|
1162
|
-
onMouseMove: e => {
|
|
1163
|
-
onMouseMove == null ? void 0 : onMouseMove(e);
|
|
1164
|
-
if (hoverSrc) {
|
|
1165
|
-
setHover(true);
|
|
1166
|
-
}
|
|
1167
|
-
},
|
|
1168
|
-
onMouseLeave: e => {
|
|
1169
|
-
onMouseLeave == null ? void 0 : onMouseLeave(e);
|
|
1170
|
-
if (hoverSrc) {
|
|
1171
|
-
setHover(false);
|
|
1172
|
-
}
|
|
1173
|
-
}
|
|
1174
|
-
}));
|
|
1191
|
+
return target;
|
|
1192
|
+
};
|
|
1193
|
+
const _exp$1 = () => InputNumber$1;
|
|
1194
|
+
const _exp2 = () => props => props.controls ? "initial" : "none";
|
|
1195
|
+
const _exp3 = () => props => `"${props.suffix ? props.suffix : ""}"`;
|
|
1196
|
+
const _exp4 = () => ({
|
|
1197
|
+
suffix
|
|
1198
|
+
}) => suffix ? "flex" : "none";
|
|
1199
|
+
const _exp5 = () => props => `"${props.prefix ? props.prefix : ""}"`;
|
|
1200
|
+
const _exp6 = () => ({
|
|
1201
|
+
prefix
|
|
1202
|
+
}) => prefix ? "flex" : "none";
|
|
1203
|
+
const AntdIntStyled = /*#__PURE__*/styled(_exp$1())({
|
|
1204
|
+
name: "AntdIntStyled",
|
|
1205
|
+
class: "at4ovwe",
|
|
1206
|
+
propsAsIs: true,
|
|
1207
|
+
vars: {
|
|
1208
|
+
"at4ovwe-0": [_exp2()],
|
|
1209
|
+
"at4ovwe-1": [_exp3()],
|
|
1210
|
+
"at4ovwe-2": [_exp4()],
|
|
1211
|
+
"at4ovwe-3": [_exp5()],
|
|
1212
|
+
"at4ovwe-4": [_exp6()]
|
|
1213
|
+
}
|
|
1175
1214
|
});
|
|
1215
|
+
const InputInteger = _a => {
|
|
1216
|
+
var _b = _a,
|
|
1217
|
+
{
|
|
1218
|
+
className,
|
|
1219
|
+
error,
|
|
1220
|
+
size = "middle",
|
|
1221
|
+
suffix,
|
|
1222
|
+
prefix,
|
|
1223
|
+
max,
|
|
1224
|
+
min,
|
|
1225
|
+
controls = false
|
|
1226
|
+
} = _b,
|
|
1227
|
+
props = __objRest$b(_b, ["className", "error", "size", "suffix", "prefix", "max", "min", "controls"]);
|
|
1228
|
+
const typo = {
|
|
1229
|
+
large: Typo.Label.l2_regular,
|
|
1230
|
+
middle: Typo.Label.l3_regular,
|
|
1231
|
+
small: Typo.Label.l4_regular
|
|
1232
|
+
}[size];
|
|
1233
|
+
return /* @__PURE__ */React.createElement(AntdIntStyled, __spreadProps$c(__spreadValues$f({}, props), {
|
|
1234
|
+
size,
|
|
1235
|
+
formatter: formatterInteger,
|
|
1236
|
+
parser: formatterInteger,
|
|
1237
|
+
min,
|
|
1238
|
+
max,
|
|
1239
|
+
controls,
|
|
1240
|
+
"data-test": props.name,
|
|
1241
|
+
suffix: controls ? "" : suffix,
|
|
1242
|
+
prefix,
|
|
1243
|
+
className: cs(className, InputStyle, typo, error ? "error" : "")
|
|
1244
|
+
}));
|
|
1245
|
+
};
|
|
1176
1246
|
|
|
1177
|
-
var
|
|
1178
|
-
|
|
1179
|
-
var
|
|
1180
|
-
|
|
1181
|
-
var
|
|
1247
|
+
var __defProp$e = Object.defineProperty;
|
|
1248
|
+
var __defProps$b = Object.defineProperties;
|
|
1249
|
+
var __getOwnPropDescs$b = Object.getOwnPropertyDescriptors;
|
|
1250
|
+
var __getOwnPropSymbols$e = Object.getOwnPropertySymbols;
|
|
1251
|
+
var __hasOwnProp$e = Object.prototype.hasOwnProperty;
|
|
1252
|
+
var __propIsEnum$e = Object.prototype.propertyIsEnumerable;
|
|
1253
|
+
var __defNormalProp$e = (obj, key, value) => key in obj ? __defProp$e(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
1254
|
+
var __spreadValues$e = (a, b) => {
|
|
1255
|
+
for (var prop in b || (b = {}))
|
|
1256
|
+
if (__hasOwnProp$e.call(b, prop))
|
|
1257
|
+
__defNormalProp$e(a, prop, b[prop]);
|
|
1258
|
+
if (__getOwnPropSymbols$e)
|
|
1259
|
+
for (var prop of __getOwnPropSymbols$e(b)) {
|
|
1260
|
+
if (__propIsEnum$e.call(b, prop))
|
|
1261
|
+
__defNormalProp$e(a, prop, b[prop]);
|
|
1262
|
+
}
|
|
1263
|
+
return a;
|
|
1264
|
+
};
|
|
1265
|
+
var __spreadProps$b = (a, b) => __defProps$b(a, __getOwnPropDescs$b(b));
|
|
1266
|
+
var __objRest$a = (source, exclude) => {
|
|
1267
|
+
var target = {};
|
|
1268
|
+
for (var prop in source)
|
|
1269
|
+
if (__hasOwnProp$e.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
1270
|
+
target[prop] = source[prop];
|
|
1271
|
+
if (source != null && __getOwnPropSymbols$e)
|
|
1272
|
+
for (var prop of __getOwnPropSymbols$e(source)) {
|
|
1273
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$e.call(source, prop))
|
|
1274
|
+
target[prop] = source[prop];
|
|
1275
|
+
}
|
|
1276
|
+
return target;
|
|
1277
|
+
};
|
|
1278
|
+
const FieldsInteger = (_a) => {
|
|
1279
|
+
var _b = _a, {
|
|
1280
|
+
meta,
|
|
1281
|
+
input,
|
|
1282
|
+
onBlur
|
|
1283
|
+
} = _b, props = __objRest$a(_b, [
|
|
1284
|
+
"meta",
|
|
1285
|
+
"input",
|
|
1286
|
+
"onBlur"
|
|
1287
|
+
]);
|
|
1288
|
+
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(
|
|
1289
|
+
InputInteger,
|
|
1290
|
+
__spreadProps$b(__spreadValues$e(__spreadValues$e({}, props), input), {
|
|
1291
|
+
onBlur: (e) => onBlur ? onBlur(input, e) : input.onBlur(e),
|
|
1292
|
+
error: meta.touched && (meta.error || !meta.dirtySinceLastSubmit && meta.submitError)
|
|
1293
|
+
})
|
|
1294
|
+
));
|
|
1295
|
+
};
|
|
1182
1296
|
|
|
1183
1297
|
const InputTagItem = /*#__PURE__*/styled('span')({
|
|
1184
1298
|
name: "InputTagItem",
|
|
@@ -1248,374 +1362,6 @@ const useElementResize = (klass, cb, depend) => {
|
|
|
1248
1362
|
}, [cb, ...depend || []]);
|
|
1249
1363
|
};
|
|
1250
1364
|
|
|
1251
|
-
const SECOND = 1;
|
|
1252
|
-
const MINUTE = 60 * SECOND;
|
|
1253
|
-
const HOUR = 60 * MINUTE;
|
|
1254
|
-
const DAY = 24 * HOUR;
|
|
1255
|
-
|
|
1256
|
-
const EMPTY_FUNCTION = () => {
|
|
1257
|
-
};
|
|
1258
|
-
|
|
1259
|
-
function getSize(el) {
|
|
1260
|
-
if (!el) {
|
|
1261
|
-
return {
|
|
1262
|
-
width: 0,
|
|
1263
|
-
height: 0
|
|
1264
|
-
};
|
|
1265
|
-
}
|
|
1266
|
-
return {
|
|
1267
|
-
width: el.offsetWidth,
|
|
1268
|
-
height: el.offsetHeight
|
|
1269
|
-
};
|
|
1270
|
-
}
|
|
1271
|
-
|
|
1272
|
-
const hashHistory = createHashHistory();
|
|
1273
|
-
|
|
1274
|
-
// Copyright Joyent, Inc. and other Node contributors.
|
|
1275
|
-
//
|
|
1276
|
-
// Permission is hereby granted, free of charge, to any person obtaining a
|
|
1277
|
-
// copy of this software and associated documentation files (the
|
|
1278
|
-
// "Software"), to deal in the Software without restriction, including
|
|
1279
|
-
// without limitation the rights to use, copy, modify, merge, publish,
|
|
1280
|
-
// distribute, sublicense, and/or sell copies of the Software, and to permit
|
|
1281
|
-
// persons to whom the Software is furnished to do so, subject to the
|
|
1282
|
-
// following conditions:
|
|
1283
|
-
//
|
|
1284
|
-
// The above copyright notice and this permission notice shall be included
|
|
1285
|
-
// in all copies or substantial portions of the Software.
|
|
1286
|
-
//
|
|
1287
|
-
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
|
|
1288
|
-
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
|
1289
|
-
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
|
|
1290
|
-
// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
|
|
1291
|
-
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
|
|
1292
|
-
// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
|
|
1293
|
-
// USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
// If obj.hasOwnProperty has been overridden, then calling
|
|
1297
|
-
// obj.hasOwnProperty(prop) will break.
|
|
1298
|
-
// See: https://github.com/joyent/node/issues/1707
|
|
1299
|
-
function hasOwnProperty(obj, prop) {
|
|
1300
|
-
return Object.prototype.hasOwnProperty.call(obj, prop);
|
|
1301
|
-
}
|
|
1302
|
-
var isArray = Array.isArray || function (xs) {
|
|
1303
|
-
return Object.prototype.toString.call(xs) === '[object Array]';
|
|
1304
|
-
};
|
|
1305
|
-
function stringifyPrimitive(v) {
|
|
1306
|
-
switch (typeof v) {
|
|
1307
|
-
case 'string':
|
|
1308
|
-
return v;
|
|
1309
|
-
|
|
1310
|
-
case 'boolean':
|
|
1311
|
-
return v ? 'true' : 'false';
|
|
1312
|
-
|
|
1313
|
-
case 'number':
|
|
1314
|
-
return isFinite(v) ? v : '';
|
|
1315
|
-
|
|
1316
|
-
default:
|
|
1317
|
-
return '';
|
|
1318
|
-
}
|
|
1319
|
-
}
|
|
1320
|
-
|
|
1321
|
-
function stringify (obj, sep, eq, name) {
|
|
1322
|
-
sep = sep || '&';
|
|
1323
|
-
eq = eq || '=';
|
|
1324
|
-
if (obj === null) {
|
|
1325
|
-
obj = undefined;
|
|
1326
|
-
}
|
|
1327
|
-
|
|
1328
|
-
if (typeof obj === 'object') {
|
|
1329
|
-
return map(objectKeys(obj), function(k) {
|
|
1330
|
-
var ks = encodeURIComponent(stringifyPrimitive(k)) + eq;
|
|
1331
|
-
if (isArray(obj[k])) {
|
|
1332
|
-
return map(obj[k], function(v) {
|
|
1333
|
-
return ks + encodeURIComponent(stringifyPrimitive(v));
|
|
1334
|
-
}).join(sep);
|
|
1335
|
-
} else {
|
|
1336
|
-
return ks + encodeURIComponent(stringifyPrimitive(obj[k]));
|
|
1337
|
-
}
|
|
1338
|
-
}).join(sep);
|
|
1339
|
-
|
|
1340
|
-
}
|
|
1341
|
-
|
|
1342
|
-
if (!name) return '';
|
|
1343
|
-
return encodeURIComponent(stringifyPrimitive(name)) + eq +
|
|
1344
|
-
encodeURIComponent(stringifyPrimitive(obj));
|
|
1345
|
-
}
|
|
1346
|
-
function map (xs, f) {
|
|
1347
|
-
if (xs.map) return xs.map(f);
|
|
1348
|
-
var res = [];
|
|
1349
|
-
for (var i = 0; i < xs.length; i++) {
|
|
1350
|
-
res.push(f(xs[i], i));
|
|
1351
|
-
}
|
|
1352
|
-
return res;
|
|
1353
|
-
}
|
|
1354
|
-
|
|
1355
|
-
var objectKeys = Object.keys || function (obj) {
|
|
1356
|
-
var res = [];
|
|
1357
|
-
for (var key in obj) {
|
|
1358
|
-
if (Object.prototype.hasOwnProperty.call(obj, key)) res.push(key);
|
|
1359
|
-
}
|
|
1360
|
-
return res;
|
|
1361
|
-
};
|
|
1362
|
-
|
|
1363
|
-
function parse(qs, sep, eq, options) {
|
|
1364
|
-
sep = sep || '&';
|
|
1365
|
-
eq = eq || '=';
|
|
1366
|
-
var obj = {};
|
|
1367
|
-
|
|
1368
|
-
if (typeof qs !== 'string' || qs.length === 0) {
|
|
1369
|
-
return obj;
|
|
1370
|
-
}
|
|
1371
|
-
|
|
1372
|
-
var regexp = /\+/g;
|
|
1373
|
-
qs = qs.split(sep);
|
|
1374
|
-
|
|
1375
|
-
var maxKeys = 1000;
|
|
1376
|
-
if (options && typeof options.maxKeys === 'number') {
|
|
1377
|
-
maxKeys = options.maxKeys;
|
|
1378
|
-
}
|
|
1379
|
-
|
|
1380
|
-
var len = qs.length;
|
|
1381
|
-
// maxKeys <= 0 means that we should not limit keys count
|
|
1382
|
-
if (maxKeys > 0 && len > maxKeys) {
|
|
1383
|
-
len = maxKeys;
|
|
1384
|
-
}
|
|
1385
|
-
|
|
1386
|
-
for (var i = 0; i < len; ++i) {
|
|
1387
|
-
var x = qs[i].replace(regexp, '%20'),
|
|
1388
|
-
idx = x.indexOf(eq),
|
|
1389
|
-
kstr, vstr, k, v;
|
|
1390
|
-
|
|
1391
|
-
if (idx >= 0) {
|
|
1392
|
-
kstr = x.substr(0, idx);
|
|
1393
|
-
vstr = x.substr(idx + 1);
|
|
1394
|
-
} else {
|
|
1395
|
-
kstr = x;
|
|
1396
|
-
vstr = '';
|
|
1397
|
-
}
|
|
1398
|
-
|
|
1399
|
-
k = decodeURIComponent(kstr);
|
|
1400
|
-
v = decodeURIComponent(vstr);
|
|
1401
|
-
|
|
1402
|
-
if (!hasOwnProperty(obj, k)) {
|
|
1403
|
-
obj[k] = v;
|
|
1404
|
-
} else if (isArray(obj[k])) {
|
|
1405
|
-
obj[k].push(v);
|
|
1406
|
-
} else {
|
|
1407
|
-
obj[k] = [obj[k], v];
|
|
1408
|
-
}
|
|
1409
|
-
}
|
|
1410
|
-
|
|
1411
|
-
return obj;
|
|
1412
|
-
}var qs = {
|
|
1413
|
-
encode: stringify,
|
|
1414
|
-
stringify: stringify,
|
|
1415
|
-
decode: parse,
|
|
1416
|
-
parse: parse
|
|
1417
|
-
};
|
|
1418
|
-
|
|
1419
|
-
var __defProp$e = Object.defineProperty;
|
|
1420
|
-
var __defProps$b = Object.defineProperties;
|
|
1421
|
-
var __getOwnPropDescs$b = Object.getOwnPropertyDescriptors;
|
|
1422
|
-
var __getOwnPropSymbols$e = Object.getOwnPropertySymbols;
|
|
1423
|
-
var __hasOwnProp$e = Object.prototype.hasOwnProperty;
|
|
1424
|
-
var __propIsEnum$e = Object.prototype.propertyIsEnumerable;
|
|
1425
|
-
var __defNormalProp$e = (obj, key, value) => key in obj ? __defProp$e(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
1426
|
-
var __spreadValues$e = (a, b) => {
|
|
1427
|
-
for (var prop in b || (b = {}))
|
|
1428
|
-
if (__hasOwnProp$e.call(b, prop))
|
|
1429
|
-
__defNormalProp$e(a, prop, b[prop]);
|
|
1430
|
-
if (__getOwnPropSymbols$e)
|
|
1431
|
-
for (var prop of __getOwnPropSymbols$e(b)) {
|
|
1432
|
-
if (__propIsEnum$e.call(b, prop))
|
|
1433
|
-
__defNormalProp$e(a, prop, b[prop]);
|
|
1434
|
-
}
|
|
1435
|
-
return a;
|
|
1436
|
-
};
|
|
1437
|
-
var __spreadProps$b = (a, b) => __defProps$b(a, __getOwnPropDescs$b(b));
|
|
1438
|
-
const routes = {
|
|
1439
|
-
overview: {
|
|
1440
|
-
path: ""
|
|
1441
|
-
},
|
|
1442
|
-
datacenters: {
|
|
1443
|
-
path: "datacenters",
|
|
1444
|
-
views: [
|
|
1445
|
-
"detail",
|
|
1446
|
-
"clusters",
|
|
1447
|
-
"hosts",
|
|
1448
|
-
"vms",
|
|
1449
|
-
"elfImages",
|
|
1450
|
-
"vmTemplates",
|
|
1451
|
-
"vmVolumes",
|
|
1452
|
-
"disks",
|
|
1453
|
-
"usbDevices",
|
|
1454
|
-
"vmPlacementGroup",
|
|
1455
|
-
"iscsiTargets",
|
|
1456
|
-
"nvmfSubsystems",
|
|
1457
|
-
"labels"
|
|
1458
|
-
]
|
|
1459
|
-
},
|
|
1460
|
-
clusters: {
|
|
1461
|
-
path: "clusters",
|
|
1462
|
-
views: [
|
|
1463
|
-
"detail",
|
|
1464
|
-
"hosts",
|
|
1465
|
-
"disks",
|
|
1466
|
-
"nics",
|
|
1467
|
-
"usbDevices",
|
|
1468
|
-
"vms",
|
|
1469
|
-
"vmPlacementGroup",
|
|
1470
|
-
"elfImages",
|
|
1471
|
-
"vmTemplates",
|
|
1472
|
-
"vmVolumes",
|
|
1473
|
-
"nfsExports",
|
|
1474
|
-
"iscsiTargets",
|
|
1475
|
-
"nvmfSubsystems",
|
|
1476
|
-
"connection",
|
|
1477
|
-
"vds",
|
|
1478
|
-
"vm_vlan",
|
|
1479
|
-
"system_vlan",
|
|
1480
|
-
"snapshot-plans",
|
|
1481
|
-
"metro",
|
|
1482
|
-
"monitor",
|
|
1483
|
-
"alerts",
|
|
1484
|
-
"logCollection",
|
|
1485
|
-
"consistencyGroups",
|
|
1486
|
-
"labels",
|
|
1487
|
-
"hardware_topo",
|
|
1488
|
-
"setting"
|
|
1489
|
-
]
|
|
1490
|
-
},
|
|
1491
|
-
hosts: {
|
|
1492
|
-
path: "hosts",
|
|
1493
|
-
views: [
|
|
1494
|
-
"detail",
|
|
1495
|
-
"disks",
|
|
1496
|
-
"nics",
|
|
1497
|
-
"vms",
|
|
1498
|
-
"monitor",
|
|
1499
|
-
"usbDevices",
|
|
1500
|
-
"labels"
|
|
1501
|
-
]
|
|
1502
|
-
},
|
|
1503
|
-
vms: {
|
|
1504
|
-
path: "vms"
|
|
1505
|
-
},
|
|
1506
|
-
vm_folders: {
|
|
1507
|
-
path: "vm_folders"
|
|
1508
|
-
},
|
|
1509
|
-
login: {
|
|
1510
|
-
path: "login"
|
|
1511
|
-
},
|
|
1512
|
-
tasks: {
|
|
1513
|
-
path: "tasks"
|
|
1514
|
-
},
|
|
1515
|
-
"vm-recycle": {
|
|
1516
|
-
path: "vm-recycle"
|
|
1517
|
-
},
|
|
1518
|
-
alerts: {
|
|
1519
|
-
path: "alerts"
|
|
1520
|
-
},
|
|
1521
|
-
alert_rules: {
|
|
1522
|
-
path: "alert_rules"
|
|
1523
|
-
},
|
|
1524
|
-
disks: { path: "disks" },
|
|
1525
|
-
elfImages: { path: "elfImages" },
|
|
1526
|
-
vmTemplates: { path: "vmTemplates" },
|
|
1527
|
-
vmVolumes: { path: "vmVolumes" },
|
|
1528
|
-
iscsiTargets: {
|
|
1529
|
-
path: "iscsiTargets",
|
|
1530
|
-
views: ["detail", "lun", "snapshot", "connection"]
|
|
1531
|
-
},
|
|
1532
|
-
nfsExports: {
|
|
1533
|
-
path: "nfsExports",
|
|
1534
|
-
views: ["detail", "inode"]
|
|
1535
|
-
},
|
|
1536
|
-
monitor: { path: "monitor" },
|
|
1537
|
-
"report-tasks": { path: "report-tasks" },
|
|
1538
|
-
"report-templates": { path: "report-templates" },
|
|
1539
|
-
usbDevices: { path: "usbDevices" },
|
|
1540
|
-
"snapshot-plans": { path: "snapshot-plans" },
|
|
1541
|
-
vmPlacementGroup: {
|
|
1542
|
-
path: "vmPlacementGroup"
|
|
1543
|
-
},
|
|
1544
|
-
settings: {
|
|
1545
|
-
path: "settings"
|
|
1546
|
-
},
|
|
1547
|
-
zones: {
|
|
1548
|
-
path: "zones",
|
|
1549
|
-
views: ["detail", "vms", "hosts", "disks"]
|
|
1550
|
-
},
|
|
1551
|
-
nvmfSubsystems: {
|
|
1552
|
-
path: "nvmfSubsystems",
|
|
1553
|
-
views: ["detail", "namespaceGroup", "namespace", "snapshot", "connection"]
|
|
1554
|
-
},
|
|
1555
|
-
namespaceGroups: {
|
|
1556
|
-
path: "namespaceGroups",
|
|
1557
|
-
views: ["namespace"]
|
|
1558
|
-
},
|
|
1559
|
-
"content-library": { path: "content-library" }
|
|
1560
|
-
};
|
|
1561
|
-
const getAllSearch = () => {
|
|
1562
|
-
return qs.parse(hashHistory.location.search.replace(/^\?/, ""));
|
|
1563
|
-
};
|
|
1564
|
-
const routeHasView = (route, view) => {
|
|
1565
|
-
var _a;
|
|
1566
|
-
if (!view)
|
|
1567
|
-
return false;
|
|
1568
|
-
return (_a = routes[route].views) == null ? void 0 : _a.includes(view);
|
|
1569
|
-
};
|
|
1570
|
-
const pushOrReplace = (action) => {
|
|
1571
|
-
return (path, state) => {
|
|
1572
|
-
if (typeof path === "object") {
|
|
1573
|
-
const { resource, id = "", search, state: state2, keepView } = path;
|
|
1574
|
-
let _search = {};
|
|
1575
|
-
if (typeof search === "object") {
|
|
1576
|
-
for (const key in search) {
|
|
1577
|
-
if (key === "view") {
|
|
1578
|
-
if (routeHasView(resource, search[key])) {
|
|
1579
|
-
_search[key] = JSON.stringify(search[key]);
|
|
1580
|
-
}
|
|
1581
|
-
} else if (search[key] || typeof search[key] === "number") {
|
|
1582
|
-
_search[key] = JSON.stringify(search[key]);
|
|
1583
|
-
}
|
|
1584
|
-
}
|
|
1585
|
-
if (keepView && !search.view) {
|
|
1586
|
-
const search2 = getAllSearch();
|
|
1587
|
-
if ("view" in search2 && routeHasView(resource, search2["view"])) {
|
|
1588
|
-
_search["view"] = JSON.stringify(search2["view"]);
|
|
1589
|
-
}
|
|
1590
|
-
}
|
|
1591
|
-
_search = qs.stringify(_search);
|
|
1592
|
-
} else {
|
|
1593
|
-
if (!search && keepView) {
|
|
1594
|
-
let view;
|
|
1595
|
-
try {
|
|
1596
|
-
view = JSON.parse(getAllSearch()["view"]);
|
|
1597
|
-
} catch (e) {
|
|
1598
|
-
}
|
|
1599
|
-
_search = routeHasView(resource, view) ? `?view="${view}"` : search;
|
|
1600
|
-
} else {
|
|
1601
|
-
_search = search;
|
|
1602
|
-
}
|
|
1603
|
-
}
|
|
1604
|
-
hashHistory[action]({
|
|
1605
|
-
pathname: `/${resource}/${id}`,
|
|
1606
|
-
state: state2,
|
|
1607
|
-
search: _search
|
|
1608
|
-
});
|
|
1609
|
-
} else {
|
|
1610
|
-
hashHistory[action](path, state);
|
|
1611
|
-
}
|
|
1612
|
-
};
|
|
1613
|
-
};
|
|
1614
|
-
__spreadProps$b(__spreadValues$e({}, hashHistory), {
|
|
1615
|
-
push: pushOrReplace("push"),
|
|
1616
|
-
replace: pushOrReplace("replace")
|
|
1617
|
-
});
|
|
1618
|
-
|
|
1619
1365
|
function getAllSize(classMap) {
|
|
1620
1366
|
return Object.keys(classMap).reduce((prev, cur) => {
|
|
1621
1367
|
prev[cur] = getSize(
|
|
@@ -1793,7 +1539,7 @@ const FieldsString = (_a) => {
|
|
|
1793
1539
|
size,
|
|
1794
1540
|
allowClear,
|
|
1795
1541
|
onClick,
|
|
1796
|
-
prefix: focusIndicator ? /* @__PURE__ */ React.createElement(Icon, { src: img }) : void 0,
|
|
1542
|
+
prefix: focusIndicator ? /* @__PURE__ */ React.createElement(Icon, { src: img$4 }) : void 0,
|
|
1797
1543
|
error: meta.touched && (meta.error || !meta.dirtySinceLastSubmit && meta.submitError)
|
|
1798
1544
|
}), props), {
|
|
1799
1545
|
onChange: (e) => {
|
|
@@ -2480,6 +2226,105 @@ const Modal = (props) => {
|
|
|
2480
2226
|
);
|
|
2481
2227
|
};
|
|
2482
2228
|
|
|
2229
|
+
const PaginationStyle = "p12gwtiw";
|
|
2230
|
+
const DropdownOverlayStyle = "d1bnu0in";
|
|
2231
|
+
const Pagination = props => {
|
|
2232
|
+
const {
|
|
2233
|
+
current,
|
|
2234
|
+
count,
|
|
2235
|
+
onChange,
|
|
2236
|
+
size,
|
|
2237
|
+
onSizeChange,
|
|
2238
|
+
showTotal = true,
|
|
2239
|
+
className,
|
|
2240
|
+
selectorVisible = true
|
|
2241
|
+
} = props;
|
|
2242
|
+
const sizeRef = useRef(size);
|
|
2243
|
+
useEffect(() => {
|
|
2244
|
+
if (sizeRef.current === size) return;
|
|
2245
|
+
sizeRef.current = size;
|
|
2246
|
+
onSizeChange == null ? void 0 : onSizeChange(size);
|
|
2247
|
+
}, [count, size, onSizeChange]);
|
|
2248
|
+
const selectOptions = useMemo(() => {
|
|
2249
|
+
if (!selectorVisible) return [];
|
|
2250
|
+
return Array.from({
|
|
2251
|
+
length: Math.ceil(count / size)
|
|
2252
|
+
}, (r, i) => {
|
|
2253
|
+
const value = i * size;
|
|
2254
|
+
const lastRange2 = value + size;
|
|
2255
|
+
return {
|
|
2256
|
+
value: i + 1,
|
|
2257
|
+
text: parrotI18n.t("components.pagination_range", {
|
|
2258
|
+
range1: value + 1,
|
|
2259
|
+
range2: lastRange2 > count ? count : lastRange2
|
|
2260
|
+
})
|
|
2261
|
+
};
|
|
2262
|
+
});
|
|
2263
|
+
}, [selectorVisible, count, size]);
|
|
2264
|
+
let lastRange = current * size;
|
|
2265
|
+
lastRange = lastRange > count ? count : lastRange;
|
|
2266
|
+
const renderLeft = () => {
|
|
2267
|
+
if (!showTotal) return null;
|
|
2268
|
+
const content = parrotI18n.t("components.pagination_total", {
|
|
2269
|
+
range1: (current - 1) * size + 1,
|
|
2270
|
+
range2: lastRange,
|
|
2271
|
+
total: count
|
|
2272
|
+
});
|
|
2273
|
+
if (selectorVisible) {
|
|
2274
|
+
return /* @__PURE__ */React.createElement(Dropdown, {
|
|
2275
|
+
placement: "topLeft",
|
|
2276
|
+
overlayClassName: DropdownOverlayStyle,
|
|
2277
|
+
overlay: /* @__PURE__ */React.createElement(Menu, null, /* @__PURE__ */React.createElement(Menu.ItemGroup, {
|
|
2278
|
+
title: parrotI18n.t("components.push_to")
|
|
2279
|
+
}, selectOptions.map(option => /* @__PURE__ */React.createElement(Menu.Item, {
|
|
2280
|
+
key: option.value,
|
|
2281
|
+
onClick: () => onChange(option.value)
|
|
2282
|
+
}, option.text))))
|
|
2283
|
+
}, /* @__PURE__ */React.createElement(Icon, {
|
|
2284
|
+
className: "pagination-left dropdown-trigger",
|
|
2285
|
+
src: img$8,
|
|
2286
|
+
hoverSrc: img$9,
|
|
2287
|
+
prefix: content
|
|
2288
|
+
}));
|
|
2289
|
+
}
|
|
2290
|
+
return /* @__PURE__ */React.createElement("span", {
|
|
2291
|
+
className: "pagination-left"
|
|
2292
|
+
}, content);
|
|
2293
|
+
};
|
|
2294
|
+
if (count === 0) {
|
|
2295
|
+
return null;
|
|
2296
|
+
}
|
|
2297
|
+
return /* @__PURE__ */React.createElement("div", {
|
|
2298
|
+
className: cs(PaginationStyle, "pagination-wrapper", className, selectorVisible && "has-selector")
|
|
2299
|
+
}, renderLeft(), /* @__PURE__ */React.createElement("span", {
|
|
2300
|
+
className: "pagination-right"
|
|
2301
|
+
}, current > 1 && /* @__PURE__ */React.createElement(Button, {
|
|
2302
|
+
className: "prev-btn",
|
|
2303
|
+
type: "quiet",
|
|
2304
|
+
size: "small",
|
|
2305
|
+
prefixIcon: /* @__PURE__ */React.createElement(Icon, {
|
|
2306
|
+
src: img$7
|
|
2307
|
+
}),
|
|
2308
|
+
onClick: () => {
|
|
2309
|
+
onChange == null ? void 0 : onChange(current - 1);
|
|
2310
|
+
}
|
|
2311
|
+
}, parrotI18n.t("components.previous_items", {
|
|
2312
|
+
size
|
|
2313
|
+
})), current * size < count && /* @__PURE__ */React.createElement(Button, {
|
|
2314
|
+
className: "next-btn",
|
|
2315
|
+
type: "quiet",
|
|
2316
|
+
size: "small",
|
|
2317
|
+
prefixIcon: /* @__PURE__ */React.createElement(Icon, {
|
|
2318
|
+
src: img$7
|
|
2319
|
+
}),
|
|
2320
|
+
onClick: () => {
|
|
2321
|
+
onChange == null ? void 0 : onChange(current + 1);
|
|
2322
|
+
}
|
|
2323
|
+
}, parrotI18n.t("components.next_items", {
|
|
2324
|
+
size
|
|
2325
|
+
}))));
|
|
2326
|
+
};
|
|
2327
|
+
|
|
2483
2328
|
var __defProp$4 = Object.defineProperty;
|
|
2484
2329
|
var __getOwnPropSymbols$4 = Object.getOwnPropertySymbols;
|
|
2485
2330
|
var __hasOwnProp$4 = Object.prototype.hasOwnProperty;
|
|
@@ -2648,8 +2493,6 @@ const SearchInput = (props) => {
|
|
|
2648
2493
|
);
|
|
2649
2494
|
};
|
|
2650
2495
|
|
|
2651
|
-
const PaginationStyle = "p12gwtiw";
|
|
2652
|
-
|
|
2653
2496
|
const inputStyle = "igz4le8";
|
|
2654
2497
|
const SimplePagination = props => {
|
|
2655
2498
|
const {
|
|
@@ -2686,7 +2529,7 @@ const SimplePagination = props => {
|
|
|
2686
2529
|
marginRight: "8px"
|
|
2687
2530
|
},
|
|
2688
2531
|
prefixIcon: /* @__PURE__ */React.createElement(Icon, {
|
|
2689
|
-
src: img$
|
|
2532
|
+
src: img$7
|
|
2690
2533
|
}),
|
|
2691
2534
|
onClick: () => {
|
|
2692
2535
|
onPageChange == null ? void 0 : onPageChange(current - 1);
|
|
@@ -2713,7 +2556,7 @@ const SimplePagination = props => {
|
|
|
2713
2556
|
marginLeft: "8px"
|
|
2714
2557
|
},
|
|
2715
2558
|
prefixIcon: /* @__PURE__ */React.createElement(Icon, {
|
|
2716
|
-
src: img$
|
|
2559
|
+
src: img$7
|
|
2717
2560
|
}),
|
|
2718
2561
|
onClick: () => {
|
|
2719
2562
|
onPageChange == null ? void 0 : onPageChange(current + 1);
|
|
@@ -2762,7 +2605,7 @@ const useTableBodyHasScrollBar = (tableBodyEl, data) => {
|
|
|
2762
2605
|
return hasScrollBar;
|
|
2763
2606
|
};
|
|
2764
2607
|
|
|
2765
|
-
const TableLoadingStyle = "
|
|
2608
|
+
const TableLoadingStyle = "t1gz6wqf";
|
|
2766
2609
|
const TableLoading = () => {
|
|
2767
2610
|
const sizes = useElementsSize({
|
|
2768
2611
|
loading: ".ant-table-wrapper .ant-spin"
|
|
@@ -2794,7 +2637,7 @@ const ColumnTitle = props => {
|
|
|
2794
2637
|
} = props;
|
|
2795
2638
|
return /* @__PURE__ */React.createElement(React.Fragment, null, title, /* @__PURE__ */React.createElement(Icon, {
|
|
2796
2639
|
className: cs("order-icon", sortOrder),
|
|
2797
|
-
src: img$
|
|
2640
|
+
src: img$6
|
|
2798
2641
|
}));
|
|
2799
2642
|
};
|
|
2800
2643
|
|
|
@@ -3089,6 +2932,8 @@ function getAntdKit() {
|
|
|
3089
2932
|
THEAD_SELECTOR,
|
|
3090
2933
|
TBODY_SELECTOR,
|
|
3091
2934
|
MODAL_WHITELIST,
|
|
2935
|
+
loading: Loading,
|
|
2936
|
+
pagination: Pagination,
|
|
3092
2937
|
select: Select,
|
|
3093
2938
|
option: Select$1.Option,
|
|
3094
2939
|
table: Table,
|
|
@@ -3103,6 +2948,7 @@ function getAntdKit() {
|
|
|
3103
2948
|
checkbox: Checkbox,
|
|
3104
2949
|
fields,
|
|
3105
2950
|
inputGroup: InputGroup,
|
|
2951
|
+
alert: Alert,
|
|
3106
2952
|
searchInput: SearchInput,
|
|
3107
2953
|
radio: Radio,
|
|
3108
2954
|
radioGroup: RadioGroup,
|
|
@@ -3113,7 +2959,9 @@ function getAntdKit() {
|
|
|
3113
2959
|
menu: Menu,
|
|
3114
2960
|
menuItem: Menu.Item,
|
|
3115
2961
|
menuItemGroup: Menu.ItemGroup,
|
|
2962
|
+
layout: Layout,
|
|
3116
2963
|
autoComplete: AutoComplete,
|
|
2964
|
+
tag: Tag,
|
|
3117
2965
|
simplePagination: SimplePagination,
|
|
3118
2966
|
space: Space,
|
|
3119
2967
|
timeZoneSelect: TimeZoneSelect
|