@para-ui/core 3.0.0 → 3.0.1
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/Button/index.d.ts +8 -0
- package/Button/index.js +67 -28
- package/ComboSelect/index.js +122 -43
- package/ComboSelect/interface.d.ts +2 -0
- package/ComboSelect/lang/en_US.d.ts +1 -0
- package/ComboSelect/lang/index.d.ts +2 -0
- package/ComboSelect/lang/zh_CN.d.ts +1 -0
- package/Container/index.js +4 -9
- package/Form/index.js +2 -2
- package/FormItem/index.js +2 -2
- package/FunctionModal/index.js +2 -2
- package/GlobalContext/componentsProps.d.ts +2 -0
- package/Loading/index.js +1 -1
- package/PageHeader/index.js +5 -6
- package/PopConfirm/index.d.ts +2 -0
- package/README.md +13 -1
- package/Select/index.d.ts +2 -0
- package/Select/index.js +4 -2
- package/Selector/index.d.ts +3 -19
- package/Selector/index.js +1993 -212
- package/Selector/interface.d.ts +355 -0
- package/Selector/lang/en_US.d.ts +8 -0
- package/Selector/lang/index.d.ts +17 -0
- package/Selector/lang/zh_CN.d.ts +8 -0
- package/Selector/selectorData/index.d.ts +10 -0
- package/Selector/selectorMain/index.d.ts +2 -9
- package/Selector/selectorNode/index.d.ts +10 -0
- package/Selector/util.d.ts +15 -0
- package/SelectorPicker/index.d.ts +49 -0
- package/SelectorPicker/index.js +316 -0
- package/Table/index.js +22 -19
- package/TextField/index.d.ts +2 -0
- package/TextField/index.js +4 -3
- package/Tree/index.js +2 -2
- package/Tree/interface.d.ts +0 -2
- package/_verture/{index-ce3860a0.js → index-5bb4b5d7.js} +0 -4
- package/_verture/{index-3d26f6a5.js → index-abfdd262.js} +0 -0
- package/_verture/{modalContext-fc19f4ae.js → modalContext-59669f93.js} +0 -0
- package/index.d.ts +2 -0
- package/index.js +6 -4
- package/package.json +7 -5
- package/Selector/branchNode/index.d.ts +0 -32
- package/Selector/leafNode/index.d.ts +0 -34
- package/Selector/selectorRight/index.d.ts +0 -16
- package/Selector/selectorTop/index.d.ts +0 -16
|
@@ -0,0 +1,316 @@
|
|
|
1
|
+
import { _ as _defineProperty } from '../_verture/defineProperty-0590dc61.js';
|
|
2
|
+
import { _ as _toConsumableArray } from '../_verture/toConsumableArray-f8047a75.js';
|
|
3
|
+
import { _ as _slicedToArray } from '../_verture/slicedToArray-d7722f4b.js';
|
|
4
|
+
import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
|
|
5
|
+
import { useState, Fragment as Fragment$1 } from 'react';
|
|
6
|
+
import HelperText from '../HelperText/index.js';
|
|
7
|
+
import Label from '../Label/index.js';
|
|
8
|
+
import clsx from 'clsx';
|
|
9
|
+
import { Dropdown } from '../Dropdown/index.js';
|
|
10
|
+
import Selector, { handFieldConfig } from '../Selector/index.js';
|
|
11
|
+
import CloseCircle from '@para-ui/icons/CloseCircle';
|
|
12
|
+
import Down from '@para-ui/icons/Down';
|
|
13
|
+
import CloseIcon from '@para-ui/icons/Close';
|
|
14
|
+
import { s as styleInject } from '../_verture/style-inject.es-300983ab.js';
|
|
15
|
+
import '../Help/index.js';
|
|
16
|
+
import '../_verture/tslib.es6-55ed4bd2.js';
|
|
17
|
+
import '../Tooltip/index.js';
|
|
18
|
+
import 'rc-tooltip';
|
|
19
|
+
import 'rc-tooltip/lib/placements';
|
|
20
|
+
import '@para-ui/icons/Help';
|
|
21
|
+
import 'rc-dropdown';
|
|
22
|
+
import '../_verture/index-342379c6.js';
|
|
23
|
+
import '../Radio/index.js';
|
|
24
|
+
import '../Checkbox/index.js';
|
|
25
|
+
import '../Popover/index.js';
|
|
26
|
+
import '../Loading/index.js';
|
|
27
|
+
import '@para-ui/icons/LoadingF';
|
|
28
|
+
import '../Search/index.js';
|
|
29
|
+
import '../TextField/index.js';
|
|
30
|
+
import '../_verture/typeof-498dd2b1.js';
|
|
31
|
+
import '@paraview/lib';
|
|
32
|
+
import '@para-ui/icons/PreviewClose';
|
|
33
|
+
import '@para-ui/icons/PreviewOpen';
|
|
34
|
+
import '../AutoTips/index.js';
|
|
35
|
+
import '../_verture/useGlobalProps-af9a2af6.js';
|
|
36
|
+
import '@para-ui/core/GlobalContext';
|
|
37
|
+
import '../Button/index.js';
|
|
38
|
+
import '@para-ui/icons/Forbid';
|
|
39
|
+
import '../_verture/useFormatMessage-ac9d6acf.js';
|
|
40
|
+
import '@para-ui/icons/Search';
|
|
41
|
+
import '../Breadcrumbs/index.js';
|
|
42
|
+
import '@para-ui/icons/More';
|
|
43
|
+
import '../Empty/index.js';
|
|
44
|
+
import '@para-ui/icons/Refresh';
|
|
45
|
+
|
|
46
|
+
var css_248z = "@charset \"UTF-8\";\n/**\n* @author Hanz\n* @date 2022/8/2 5:57 PM\n* @description\n*/\n/**\n* @author Hanz\n* @date 2021/10/20 下午2:08\n* @description color\n*/\n.paraui-selector-picker-wrapper {\n position: relative;\n display: flex;\n min-height: 36px;\n padding: 0 42px 0 12px;\n border: 1px solid rgba(171, 176, 185, 0.4);\n border-radius: 4px;\n background-color: rgb(255, 255, 255);\n cursor: pointer;\n transition: 0.3s;\n}\n.paraui-selector-picker-wrapper:hover {\n border-color: rgba(54, 102, 214, 0.8);\n}\n.paraui-selector-picker-wrapper .paraui-selector-picker-placeholder {\n position: absolute;\n top: 50%;\n left: 12px;\n right: 42px;\n transform: translateY(-50%);\n font-size: 14px;\n color: rgba(46, 55, 67, 0.4);\n white-space: nowrap;\n}\n.paraui-selector-picker-wrapper .paraui-selector-picker-arrow {\n position: absolute;\n top: 7px;\n right: 12px;\n line-height: 0;\n transition: 0.3s;\n}\n.paraui-selector-picker-wrapper .paraui-selector-picker-arrow svg {\n color: rgba(46, 55, 67, 0.7);\n font-size: 20px;\n}\n.paraui-selector-picker-wrapper .paraui-selector-picker-clear {\n position: absolute;\n top: 9px;\n right: 12px;\n opacity: 0;\n line-height: 0;\n cursor: pointer;\n transition: 0.3s;\n}\n.paraui-selector-picker-wrapper .paraui-selector-picker-clear svg {\n color: rgba(46, 55, 67, 0.7);\n font-size: 16px;\n}\n.paraui-selector-picker-wrapper .paraui-selector-picker-overflow {\n position: relative;\n display: flex;\n width: 100%;\n flex: auto;\n flex-wrap: wrap;\n padding-top: 5px;\n}\n.paraui-selector-picker-wrapper .paraui-selector-picker-overflow-single {\n padding-top: 0;\n align-items: center;\n overflow: hidden;\n}\n.paraui-selector-picker-wrapper .paraui-selector-picker-overflow-single .paraui-selector-picker-single-content {\n max-width: 100%;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n font-size: 14px;\n color: rgb(46, 55, 67);\n}\n.paraui-selector-picker-wrapper .paraui-selector-picker-overflow-item {\n flex: none;\n max-width: 100%;\n}\n.paraui-selector-picker-wrapper .paraui-selector-picker-overflow-item .paraui-selector-picker-item {\n display: inline-flex;\n align-items: center;\n padding: 0 12px;\n height: 24px;\n margin: 0 8px 5px 0;\n max-width: 100%;\n color: rgb(46, 55, 67);\n line-height: 24px;\n background-color: rgba(171, 176, 185, 0.2);\n border-radius: 4px;\n user-select: none;\n transition: 0.3s;\n cursor: default;\n}\n.paraui-selector-picker-wrapper .paraui-selector-picker-overflow-item .paraui-selector-picker-item-content {\n display: inline-block;\n margin-right: 4px;\n overflow: hidden;\n font-size: 12px;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.paraui-selector-picker-wrapper .paraui-selector-picker-overflow-item .paraui-selector-picker-item .paraui-selector-picker-item-remove {\n display: inline-flex;\n cursor: pointer;\n}\n.paraui-selector-picker-wrapper .paraui-selector-picker-overflow-item .paraui-selector-picker-item .paraui-selector-picker-item-remove svg {\n font-size: 16px;\n color: inherit;\n}\n.paraui-selector-picker-focused .paraui-selector-picker-wrapper {\n border-color: rgb(54, 102, 214);\n}\n.paraui-selector-picker-focused .paraui-selector-picker-wrapper .paraui-selector-picker-arrow {\n transform: rotate(180deg);\n color: rgb(54, 102, 214);\n}\n.paraui-selector-picker-disabled {\n cursor: not-allowed;\n}\n.paraui-selector-picker-disabled .paraui-selector-picker-wrapper {\n background-color: rgba(171, 176, 185, 0.12);\n border-color: rgba(171, 176, 185, 0.4);\n pointer-events: none;\n}\n.paraui-selector-picker-error .paraui-selector-picker-wrapper {\n border-color: rgb(235, 96, 84);\n}\n.paraui-selector-picker-error .paraui-selector-picker-wrapper:hover {\n border-color: rgb(235, 96, 84);\n}\n.paraui-selector-picker-clear .paraui-selector-picker-wrapper:hover .paraui-selector-picker-arrow {\n opacity: 0;\n}\n.paraui-selector-picker-clear .paraui-selector-picker-wrapper:hover .paraui-selector-picker-clear {\n opacity: 1;\n}\n.paraui-selector-picker-dropdown .paraui-selector {\n border: 0;\n}";
|
|
47
|
+
styleInject(css_248z);
|
|
48
|
+
|
|
49
|
+
var SelectorPicker = function SelectorPicker(props) {
|
|
50
|
+
var _a, _b, _c;
|
|
51
|
+
|
|
52
|
+
var className = props.className,
|
|
53
|
+
label = props.label,
|
|
54
|
+
value = props.value,
|
|
55
|
+
defaultValue = props.defaultValue,
|
|
56
|
+
_props$required = props.required,
|
|
57
|
+
required = _props$required === void 0 ? false : _props$required,
|
|
58
|
+
labelTooltip = props.labelTooltip,
|
|
59
|
+
_props$error = props.error,
|
|
60
|
+
error = _props$error === void 0 ? false : _props$error,
|
|
61
|
+
helperText = props.helperText,
|
|
62
|
+
_props$size = props.size,
|
|
63
|
+
size = _props$size === void 0 ? 'medium' : _props$size,
|
|
64
|
+
_props$disabled = props.disabled,
|
|
65
|
+
disabled = _props$disabled === void 0 ? false : _props$disabled,
|
|
66
|
+
style = props.style,
|
|
67
|
+
_props$placeholder = props.placeholder,
|
|
68
|
+
placeholder = _props$placeholder === void 0 ? '请选择' : _props$placeholder,
|
|
69
|
+
_props$multiple = props.multiple,
|
|
70
|
+
multiple = _props$multiple === void 0 ? false : _props$multiple,
|
|
71
|
+
maxCount = props.maxCount,
|
|
72
|
+
_props$allowClear = props.allowClear,
|
|
73
|
+
allowClear = _props$allowClear === void 0 ? false : _props$allowClear,
|
|
74
|
+
selectorProps = props.selectorProps,
|
|
75
|
+
onChange = props.onChange,
|
|
76
|
+
onClear = props.onClear;
|
|
77
|
+
var fieldConfigHand = handFieldConfig((_a = props.selectorProps) === null || _a === void 0 ? void 0 : _a.fieldConfig, ((_b = props.selectorProps) === null || _b === void 0 ? void 0 : _b.rowKey) || 'key'); // 字段配置,对应数据字段
|
|
78
|
+
|
|
79
|
+
var selectorFieldConfigHand = Object.assign(Object.assign({}, fieldConfigHand), (_c = props.selectorProps) === null || _c === void 0 ? void 0 : _c.backDataFieldConfig); // 选中值字段配置,对应数据字段
|
|
80
|
+
|
|
81
|
+
var _useState = useState(!defaultValue ? [] : defaultValue),
|
|
82
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
83
|
+
valueCom = _useState2[0],
|
|
84
|
+
setValueCom = _useState2[1];
|
|
85
|
+
|
|
86
|
+
var _useState3 = useState(false),
|
|
87
|
+
_useState4 = _slicedToArray(_useState3, 2),
|
|
88
|
+
open = _useState4[0],
|
|
89
|
+
setOpen = _useState4[1]; // 显示下拉
|
|
90
|
+
|
|
91
|
+
|
|
92
|
+
var prefixCls = 'paraui-selector-picker';
|
|
93
|
+
/** 改变事件 val绑定值, node处理过的数据 rowData原始数据 */
|
|
94
|
+
|
|
95
|
+
var onChangeCom = function onChangeCom(val, node, rowData) {
|
|
96
|
+
onChange && onChange(val, node, rowData);
|
|
97
|
+
|
|
98
|
+
if (value === undefined) {
|
|
99
|
+
setValueCom(!val ? [] : val);
|
|
100
|
+
}
|
|
101
|
+
};
|
|
102
|
+
/** 处理value,defaultValue */
|
|
103
|
+
|
|
104
|
+
|
|
105
|
+
var handValue = function handValue() {
|
|
106
|
+
if (value !== undefined) return value;
|
|
107
|
+
return valueCom;
|
|
108
|
+
};
|
|
109
|
+
/** 处理组件绑定的值 */
|
|
110
|
+
|
|
111
|
+
|
|
112
|
+
var handComVal = function handComVal() {
|
|
113
|
+
var val = handValue();
|
|
114
|
+
var handVal = !val ? [] : [val];
|
|
115
|
+
|
|
116
|
+
if (val instanceof Array) {
|
|
117
|
+
handVal = _toConsumableArray(val);
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
return handVal;
|
|
121
|
+
}; //打开浮层
|
|
122
|
+
|
|
123
|
+
|
|
124
|
+
var openSelector = function openSelector() {
|
|
125
|
+
setOpen(true);
|
|
126
|
+
}; //生成cls
|
|
127
|
+
|
|
128
|
+
|
|
129
|
+
var makeCls = function makeCls() {
|
|
130
|
+
var _clsx;
|
|
131
|
+
|
|
132
|
+
var list = handComVal();
|
|
133
|
+
return clsx(prefixCls, className, (_clsx = {}, _defineProperty(_clsx, "".concat(prefixCls, "-focused"), open), _defineProperty(_clsx, "".concat(prefixCls, "-disabled"), disabled), _defineProperty(_clsx, "".concat(prefixCls, "-error"), error), _defineProperty(_clsx, "".concat(prefixCls, "-clear"), allowClear && list.length), _defineProperty(_clsx, "".concat(prefixCls, "-").concat(size), size !== 'medium'), _clsx));
|
|
134
|
+
}; //渲染label
|
|
135
|
+
|
|
136
|
+
|
|
137
|
+
var renderLabel = function renderLabel() {
|
|
138
|
+
if (label || required) {
|
|
139
|
+
return jsx(Label, Object.assign({
|
|
140
|
+
label: label,
|
|
141
|
+
required: required
|
|
142
|
+
}, labelTooltip));
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
return null;
|
|
146
|
+
}; //删除当前选中项
|
|
147
|
+
|
|
148
|
+
|
|
149
|
+
var handleTagRemove = function handleTagRemove(opt, index, e) {
|
|
150
|
+
e.stopPropagation();
|
|
151
|
+
var list = handComVal();
|
|
152
|
+
list.splice(index, 1);
|
|
153
|
+
onChangeCom(_toConsumableArray(list), {}, {});
|
|
154
|
+
}; //全部清空
|
|
155
|
+
|
|
156
|
+
|
|
157
|
+
var handleAllClear = function handleAllClear(e) {
|
|
158
|
+
e.stopPropagation();
|
|
159
|
+
setOpen(false);
|
|
160
|
+
onClear === null || onClear === void 0 ? void 0 : onClear();
|
|
161
|
+
onChangeCom(multiple ? [] : {}, {}, {});
|
|
162
|
+
};
|
|
163
|
+
/** 处理tag标签 */
|
|
164
|
+
|
|
165
|
+
|
|
166
|
+
var handTagDom = function handTagDom(item, index) {
|
|
167
|
+
var labelStr = selectorFieldConfigHand.mainTitle || '';
|
|
168
|
+
var val = selectorFieldConfigHand.key || '';
|
|
169
|
+
return jsx("div", Object.assign({
|
|
170
|
+
className: "".concat(prefixCls, "-overflow-item")
|
|
171
|
+
}, {
|
|
172
|
+
children: jsxs("span", Object.assign({
|
|
173
|
+
className: "".concat(prefixCls, "-item")
|
|
174
|
+
}, {
|
|
175
|
+
children: [jsx("span", Object.assign({
|
|
176
|
+
className: "".concat(prefixCls, "-item-content")
|
|
177
|
+
}, {
|
|
178
|
+
children: item[labelStr] || item[val]
|
|
179
|
+
})), jsx("span", Object.assign({
|
|
180
|
+
className: "".concat(prefixCls, "-item-remove"),
|
|
181
|
+
onClick: function onClick(e) {
|
|
182
|
+
return handleTagRemove === null || handleTagRemove === void 0 ? void 0 : handleTagRemove(item, index, e);
|
|
183
|
+
}
|
|
184
|
+
}, {
|
|
185
|
+
children: jsx(CloseIcon, {})
|
|
186
|
+
}))]
|
|
187
|
+
}))
|
|
188
|
+
}));
|
|
189
|
+
}; //tag memo
|
|
190
|
+
|
|
191
|
+
|
|
192
|
+
var tagMemo = function tagMemo() {
|
|
193
|
+
var _a;
|
|
194
|
+
|
|
195
|
+
var list = handComVal();
|
|
196
|
+
if (!list.length) return;
|
|
197
|
+
|
|
198
|
+
if (!multiple) {
|
|
199
|
+
//单选
|
|
200
|
+
return jsx("span", Object.assign({
|
|
201
|
+
className: "".concat(prefixCls, "-single-content")
|
|
202
|
+
}, {
|
|
203
|
+
children: (_a = list[0]) === null || _a === void 0 ? void 0 : _a.label
|
|
204
|
+
}));
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
var realShowList = _toConsumableArray(list); //实际
|
|
208
|
+
|
|
209
|
+
|
|
210
|
+
var overList = []; //超出显示
|
|
211
|
+
|
|
212
|
+
if (maxCount) {
|
|
213
|
+
if (list.length > maxCount) {
|
|
214
|
+
overList = list.slice(maxCount);
|
|
215
|
+
realShowList = list.slice(0, maxCount);
|
|
216
|
+
}
|
|
217
|
+
} //超出部分
|
|
218
|
+
|
|
219
|
+
|
|
220
|
+
var renderOverTag = (overList === null || overList === void 0 ? void 0 : overList.length) ? jsx("div", Object.assign({
|
|
221
|
+
className: "".concat(prefixCls, "-overflow-item")
|
|
222
|
+
}, {
|
|
223
|
+
children: jsx("span", Object.assign({
|
|
224
|
+
className: "".concat(prefixCls, "-item")
|
|
225
|
+
}, {
|
|
226
|
+
children: jsx("span", Object.assign({
|
|
227
|
+
className: "".concat(prefixCls, "-item-content")
|
|
228
|
+
}, {
|
|
229
|
+
children: "+".concat(overList === null || overList === void 0 ? void 0 : overList.length)
|
|
230
|
+
}))
|
|
231
|
+
}))
|
|
232
|
+
})) : null;
|
|
233
|
+
return jsxs(Fragment, {
|
|
234
|
+
children: [realShowList.map(function (item, idx) {
|
|
235
|
+
return jsx(Fragment$1, {
|
|
236
|
+
children: handTagDom(item, idx)
|
|
237
|
+
}, idx);
|
|
238
|
+
}), renderOverTag]
|
|
239
|
+
});
|
|
240
|
+
};
|
|
241
|
+
/** dropdown 下拉浮层 */
|
|
242
|
+
|
|
243
|
+
|
|
244
|
+
var renderOverlay = function renderOverlay() {
|
|
245
|
+
var handSelectorProps = function handSelectorProps() {
|
|
246
|
+
var obj = Object.assign({
|
|
247
|
+
layout: 'list',
|
|
248
|
+
disabled: disabled,
|
|
249
|
+
selectMode: multiple ? 'check' : 'radio',
|
|
250
|
+
value: handValue(),
|
|
251
|
+
defaultValue: defaultValue,
|
|
252
|
+
onChange: onChangeCom
|
|
253
|
+
}, selectorProps);
|
|
254
|
+
return obj;
|
|
255
|
+
};
|
|
256
|
+
|
|
257
|
+
return jsx("div", {
|
|
258
|
+
children: jsx(Selector, Object.assign({}, handSelectorProps()))
|
|
259
|
+
});
|
|
260
|
+
}; //dropdown anchor
|
|
261
|
+
|
|
262
|
+
|
|
263
|
+
var renderAnchor = function renderAnchor() {
|
|
264
|
+
var list = handComVal();
|
|
265
|
+
var overflowCls = clsx("".concat(prefixCls, "-overflow"), !multiple && "".concat(prefixCls, "-overflow-single")); //清除图标
|
|
266
|
+
|
|
267
|
+
var clearBtn = allowClear && list.length ? jsx("span", Object.assign({
|
|
268
|
+
className: "".concat(prefixCls, "-clear"),
|
|
269
|
+
onClick: handleAllClear
|
|
270
|
+
}, {
|
|
271
|
+
children: jsx(CloseCircle, {})
|
|
272
|
+
})) : null;
|
|
273
|
+
return jsxs("div", Object.assign({
|
|
274
|
+
className: "".concat(prefixCls, "-wrapper"),
|
|
275
|
+
onClick: openSelector
|
|
276
|
+
}, {
|
|
277
|
+
children: [jsx("div", Object.assign({
|
|
278
|
+
className: overflowCls
|
|
279
|
+
}, {
|
|
280
|
+
children: tagMemo()
|
|
281
|
+
})), jsx("span", Object.assign({
|
|
282
|
+
className: "".concat(prefixCls, "-arrow")
|
|
283
|
+
}, {
|
|
284
|
+
children: jsx(Down, {})
|
|
285
|
+
})), clearBtn, !list.length && jsx("span", Object.assign({
|
|
286
|
+
className: "".concat(prefixCls, "-placeholder")
|
|
287
|
+
}, {
|
|
288
|
+
children: placeholder
|
|
289
|
+
}))]
|
|
290
|
+
}));
|
|
291
|
+
};
|
|
292
|
+
|
|
293
|
+
return jsxs("div", Object.assign({
|
|
294
|
+
className: makeCls(),
|
|
295
|
+
style: style
|
|
296
|
+
}, {
|
|
297
|
+
children: [renderLabel(), jsx(Dropdown, Object.assign({
|
|
298
|
+
visible: open,
|
|
299
|
+
destroyPopupOnHide: true,
|
|
300
|
+
overlay: renderOverlay(),
|
|
301
|
+
placement: 'bottomLeft',
|
|
302
|
+
trigger: ['click'],
|
|
303
|
+
onVisibleChange: function onVisibleChange(vis) {
|
|
304
|
+
return setOpen(vis);
|
|
305
|
+
},
|
|
306
|
+
overlayClassName: 'paraui-selector-picker-dropdown'
|
|
307
|
+
}, {
|
|
308
|
+
children: renderAnchor()
|
|
309
|
+
})), jsx(HelperText, {
|
|
310
|
+
error: error,
|
|
311
|
+
helperText: helperText
|
|
312
|
+
})]
|
|
313
|
+
}));
|
|
314
|
+
};
|
|
315
|
+
|
|
316
|
+
export { SelectorPicker as default };
|
package/Table/index.js
CHANGED
|
@@ -503,11 +503,15 @@ var TableHead$1 = function TableHead(props) {
|
|
|
503
503
|
align: "center",
|
|
504
504
|
className: handCls()
|
|
505
505
|
}, {
|
|
506
|
-
children: jsx(
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
506
|
+
children: jsx("div", Object.assign({
|
|
507
|
+
className: 'table-header-box'
|
|
508
|
+
}, {
|
|
509
|
+
children: jsx(Checkbox, {
|
|
510
|
+
indeterminate: indeterminate,
|
|
511
|
+
checked: checked,
|
|
512
|
+
onChange: onSelectAll
|
|
513
|
+
})
|
|
514
|
+
}))
|
|
511
515
|
}));
|
|
512
516
|
}
|
|
513
517
|
}, [check, indeterminate, checked, selectAll, posFixed, radio, expandable]); // 单选框memo
|
|
@@ -808,7 +812,11 @@ var TableHead$1 = function TableHead(props) {
|
|
|
808
812
|
className: handCls(),
|
|
809
813
|
onClick: clickShowColums
|
|
810
814
|
}, {
|
|
811
|
-
children: jsx(
|
|
815
|
+
children: jsx("div", Object.assign({
|
|
816
|
+
className: 'table-header-box'
|
|
817
|
+
}, {
|
|
818
|
+
children: jsx(Panel, {})
|
|
819
|
+
}))
|
|
812
820
|
}))
|
|
813
821
|
}));
|
|
814
822
|
}, [showColumns, posFixed, operate, anchorElColums, showList, headDataJson]); // 处理class
|
|
@@ -1525,7 +1533,7 @@ var TableElement = function TableElement(props) {
|
|
|
1525
1533
|
}));
|
|
1526
1534
|
};
|
|
1527
1535
|
|
|
1528
|
-
var css_248z = "@charset \"UTF-8\";\n/**\n* @author Hanz\n* @date 2021/10/20 下午2:08\n* @description color\n*/\n.paraui-table {\n width: 100%;\n height: 100%;\n display: inline-block;\n overflow: auto;\n background-color: white;\n font-family: -apple-system, BlinkMacSystemFont, Helvetica Neue, PingFang SC, Microsoft YaHei, Source Han Sans SC, Noto Sans CJK SC, WenQuanYi Micro Hei, sans-serif;\n font-size: 14px;\n font-weight: 400;\n}\n.paraui-table.paraui-table-no-data > .paraui-table-container > table {\n height: 100%;\n}\n.paraui-table.paraui-table-load.paraui-table-no-data > .paraui-table-container > table {\n height: auto;\n}\n.paraui-table.paraui-table-radio.paraui-table-check .table-radio {\n left: 48px;\n}\n.paraui-table.paraui-table-expandable.paraui-table-check .table-expandable {\n left: 48px;\n}\n.paraui-table.paraui-table-expandable.paraui-table-check.paraui-table-radio .table-expandable {\n left: 80px;\n}\n.paraui-table > .table-contain {\n height: 100%;\n position: relative;\n}\n.paraui-table > .table-contain > table {\n height: auto;\n}\n.paraui-table > .table-contain > table .table-checkbox {\n left: 0;\n}\n.paraui-table > .table-contain > table .table-checkbox > label {\n vertical-align: middle;\n}\n.paraui-table > .table-contain > table .table-radio {\n left: 0;\n}\n.paraui-table > .table-contain > table .table-radio > label {\n vertical-align: middle;\n}\n.paraui-table > .table-contain > table .table-expandable {\n left: 0;\n}\n.paraui-table > .table-contain > table .table-expandable > svg {\n vertical-align: middle;\n}\n.paraui-table > .table-contain > table > .table-head {\n width: 100%;\n white-space: nowrap;\n}\n.paraui-table > .table-contain > table > .table-head > tr th {\n height: 50px;\n}\n.paraui-table > .table-contain > table > .table-head.table-head-scroll tr th {\n max-width: 240px;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box {\n height: 49px;\n line-height: 49px;\n position: relative;\n padding: 0 8px;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-title {\n height: 100%;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-title > span {\n height: 100%;\n display: inline-block;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-title > .table-header-title-label {\n width: 100%;\n color: rgba(46, 55, 67, 0.7);\n font-weight: 700;\n font-size: 14px;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-title > .table-sort-svg {\n line-height: 0;\n width: 12px;\n margin-left: 5px;\n white-space: pre-wrap;\n vertical-align: top;\n height: inherit;\n padding-top: 15px;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-title > .table-sort-svg > svg {\n font-size: 12px;\n color: rgba(46, 55, 67, 0.7);\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-title > .table-sort-svg > .up-svg {\n position: relative;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-title > .table-sort-svg > .down-svg {\n position: relative;\n top: -5px;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-filter {\n position: absolute;\n right: 0;\n top: 0;\n cursor: pointer;\n width: 28px;\n text-align: left;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-filter.table-header-filter-select > svg {\n color: rgb(54, 102, 214);\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-filter.table-header-filter-show {\n background-color: rgba(54, 102, 214, 0.05);\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-filter.table-header-filter-show > svg {\n color: rgb(54, 102, 214);\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-filter:hover {\n background-color: rgb(227, 234, 247);\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-filter:hover > svg {\n color: rgb(54, 102, 214);\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-filter > svg {\n font-size: 14px;\n color: rgba(46, 55, 67, 0.7);\n margin-left: 7px;\n position: relative;\n top: 2px;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box.table-header-box-sort {\n cursor: pointer;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box.table-header-box-sort > .table-header-title > .table-header-title-label {\n max-width: calc(100% - 18px);\n width: auto;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box.table-header-box-filter > .table-header-title {\n margin-right: 18px;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box.table-header-box-sort-asc > .table-header-title > .table-sort-svg > .up-svg {\n color: rgb(54, 102, 214);\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box.table-header-box-sort-desc > .table-header-title > .table-sort-svg > .down-svg {\n color: rgb(54, 102, 214);\n}\n.paraui-table > .table-contain > table > .table-head .show-colums {\n width: 56px;\n cursor: pointer;\n border-left: 1px solid rgba(171, 176, 185, 0.12);\n right: 0;\n}\n.paraui-table > .table-contain > table > .table-head .show-colums > svg {\n font-size: 24px;\n color: rgba(46, 55, 67, 0.7);\n position: relative;\n top: 5px;\n}\n.paraui-table > .table-contain > table > .table-head .show-colums:hover > svg {\n color: rgb(54, 102, 214);\n}\n.paraui-table > .table-contain > table > .table-head.table-head-no-btn tr th:first-child .table-header-box {\n padding-left: 16px;\n}\n.paraui-table > .table-contain > table > .table-head .table-head-btn {\n width: 32px;\n padding: 0;\n}\n.paraui-table > .table-contain > table > .table-head .table-head-btn:first-child {\n width: 48px;\n}\n.paraui-table > .table-contain > table > .table-body {\n width: 100%;\n}\n.paraui-table > .table-contain > table > .table-body.table-body-scroll tr td {\n max-width: 240px;\n color: rgba(46, 55, 67, 0.7);\n}\n.paraui-table > .table-contain > table > .table-body tr {\n height: 56px;\n}\n.paraui-table > .table-contain > table > .table-body tr td {\n background-color: white;\n}\n.paraui-table > .table-contain > table > .table-body tr:nth-of-type(2n) td {\n background-color: rgb(249, 250, 251);\n}\n.paraui-table > .table-contain > table > .table-body tr:hover td {\n background-color: rgb(237, 241, 249);\n}\n.paraui-table > .table-contain > table > .table-body tr .table-expandable > svg {\n transition: all 0.3s;\n cursor: pointer;\n font-size: 16px;\n color: rgba(46, 55, 67, 0.7);\n}\n.paraui-table > .table-contain > table > .table-body tr .table-expandable > svg:hover {\n color: rgb(54, 102, 214);\n}\n.paraui-table > .table-contain > table > .table-body tr .table-expandable > .expand {\n transform: rotate(180deg);\n color: rgb(54, 102, 214);\n}\n.paraui-table > .table-contain > table > .table-body .more-table-row {\n cursor: pointer;\n}\n.paraui-table > .table-contain > table > .table-body .more-table-row .more-btn {\n color: rgb(54, 102, 214);\n font-size: 14px;\n}\n.paraui-table > .table-contain > table > .table-body.table-body-no-btn tr td:first-child {\n padding-left: 16px;\n}\n.paraui-table > .table-contain > table > .table-body.table-body-no-btn > .table-no-data > td:first-child {\n padding: 0;\n}\n.paraui-table > .table-contain > table > .table-body .table-body-btn {\n width: 32px;\n padding: 0;\n}\n.paraui-table > .table-contain > table > .table-body .table-body-btn:first-child {\n width: 48px;\n}\n.paraui-table > .table-contain > table > .table-body > .table-no-data {\n height: calc(100% - 50px);\n}\n.paraui-table > .table-contain > table > .table-body > .table-no-data:hover td {\n background-color: white;\n}\n.paraui-table > .table-contain > table > .table-body > .table-no-data > td {\n padding: 56px 0 0 0;\n}\n.paraui-table > .paraui-table-pagination {\n width: 100%;\n height: 60px;\n padding-right: 10px;\n display: flex;\n align-items: flex-end;\n justify-content: flex-end;\n}\n.paraui-table.table-pagination > .table-contain {\n height: calc(100% - 60px);\n}\n.paraui-table.table-pagination.table-load-more > .table-contain {\n height: 100%;\n}\n.paraui-table-show-colums-popover > .paraui-popover-content {\n width: 200px;\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-box {\n padding-top: 8px;\n max-height: 224px;\n overflow-y: auto;\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-box > .show-colums-select-item {\n height: 36px;\n line-height: 36px;\n cursor: pointer;\n display: flex;\n padding: 0 4px;\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-box > .show-colums-select-item > label {\n width: 32px;\n display: flex;\n justify-content: center;\n align-items: center;\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-box > .show-colums-select-item > span {\n color: rgb(46, 55, 67);\n font-size: 14px;\n display: inline-block;\n width: calc(100% - 32px);\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-box > .show-colums-select-item:hover > span {\n color: rgb(54, 102, 214);\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-box > .show-colums-select-item:hover > label .paraui-checkbox-box-inner {\n border-color: rgb(54, 102, 214);\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-box > .show-colums-select-item.show-colums-select-item-select > span {\n color: rgb(54, 102, 214);\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-box > .show-colums-select-item.show-colums-select-item-select > label .paraui-checkbox-box-inner {\n border-color: rgb(54, 102, 214);\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-footer {\n height: 45px;\n border-top: 1px solid rgba(171, 176, 185, 0.2);\n text-align: center;\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-footer > button {\n width: 100%;\n height: 100%;\n border: 0;\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-footer > button > span {\n font-size: 14px;\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-footer > button > span > span {\n margin-right: 5px;\n color: rgb(46, 55, 67);\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-footer > button > span > span svg {\n font-size: 14px;\n color: rgb(46, 55, 67);\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-footer > button:hover > span > span svg {\n color: rgb(54, 102, 214);\n}\n\n.paraui-filter-popover > .paraui-popover-content {\n width: 200px;\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-box {\n padding-top: 8px;\n max-height: 224px;\n overflow-y: auto;\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-box > .filter-select-item {\n height: 36px;\n line-height: 36px;\n cursor: pointer;\n display: flex;\n padding: 0 4px;\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-box > .filter-select-item > label {\n width: 32px;\n display: flex;\n justify-content: center;\n align-items: center;\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-box > .filter-select-item > span {\n color: rgb(46, 55, 67);\n font-size: 14px;\n display: inline-block;\n width: calc(100% - 32px);\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-box > .filter-select-item:hover > span {\n color: rgb(54, 102, 214);\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-box > .filter-select-item:hover > label .rc-checkbox-inner {\n border-color: rgb(54, 102, 214);\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-box > .filter-select-item.filter-select-item-select > span {\n color: rgb(54, 102, 214);\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-box > .filter-select-item.filter-select-item-select > label .rc-checkbox-inner {\n border-color: rgb(54, 102, 214);\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-footer {\n height: 45px;\n border-top: 1px solid rgba(171, 176, 185, 0.2);\n text-align: center;\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-footer > button {\n width: 50%;\n height: 100%;\n border: 0;\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-footer > button > span {\n font-size: 14px;\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-footer > button > span > span {\n margin-right: 5px;\n color: rgb(46, 55, 67);\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-footer > button > span > span svg {\n font-size: 14px;\n color: rgb(46, 55, 67);\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-footer > button:hover > span > span svg {\n color: rgb(54, 102, 214);\n}";
|
|
1536
|
+
var css_248z = "@charset \"UTF-8\";\n/**\n* @author Hanz\n* @date 2021/10/20 下午2:08\n* @description color\n*/\n.paraui-table {\n width: 100%;\n height: 100%;\n display: inline-block;\n overflow: auto;\n background-color: white;\n font-family: -apple-system, BlinkMacSystemFont, Helvetica Neue, PingFang SC, Microsoft YaHei, Source Han Sans SC, Noto Sans CJK SC, WenQuanYi Micro Hei, sans-serif;\n font-size: 14px;\n font-weight: 400;\n}\n.paraui-table.paraui-table-no-data > .paraui-table-container > table {\n height: 100%;\n}\n.paraui-table.paraui-table-load.paraui-table-no-data > .paraui-table-container > table {\n height: auto;\n}\n.paraui-table.paraui-table-radio.paraui-table-check .table-radio {\n left: 48px;\n}\n.paraui-table.paraui-table-expandable.paraui-table-check .table-expandable {\n left: 48px;\n}\n.paraui-table.paraui-table-expandable.paraui-table-check.paraui-table-radio .table-expandable {\n left: 80px;\n}\n.paraui-table > .table-contain {\n height: 100%;\n position: relative;\n}\n.paraui-table > .table-contain > table {\n height: auto;\n}\n.paraui-table > .table-contain > table .table-checkbox {\n left: 0;\n}\n.paraui-table > .table-contain > table .table-checkbox > label {\n vertical-align: middle;\n}\n.paraui-table > .table-contain > table .table-checkbox .table-header-box {\n display: flex;\n justify-content: center;\n align-items: center;\n}\n.paraui-table > .table-contain > table .table-radio {\n left: 0;\n}\n.paraui-table > .table-contain > table .table-radio > label {\n vertical-align: middle;\n}\n.paraui-table > .table-contain > table .table-radio .table-header-box {\n display: flex;\n justify-content: center;\n align-items: center;\n}\n.paraui-table > .table-contain > table .table-expandable {\n left: 0;\n}\n.paraui-table > .table-contain > table .table-expandable > svg {\n vertical-align: middle;\n}\n.paraui-table > .table-contain > table > .table-head {\n width: 100%;\n white-space: nowrap;\n}\n.paraui-table > .table-contain > table > .table-head > tr th {\n height: 50px;\n}\n.paraui-table > .table-contain > table > .table-head.table-head-scroll tr th {\n max-width: 240px;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box {\n height: 49px;\n line-height: 49px;\n position: relative;\n padding: 0 8px;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-title {\n height: 100%;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-title > span {\n height: 100%;\n display: inline-block;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-title > .table-header-title-label {\n width: 100%;\n color: rgba(46, 55, 67, 0.7);\n font-weight: 700;\n font-size: 14px;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-title > .table-sort-svg {\n line-height: 0;\n width: 12px;\n margin-left: 5px;\n white-space: pre-wrap;\n vertical-align: top;\n height: inherit;\n padding-top: 15px;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-title > .table-sort-svg > svg {\n font-size: 12px;\n color: rgba(46, 55, 67, 0.7);\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-title > .table-sort-svg > .up-svg {\n position: relative;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-title > .table-sort-svg > .down-svg {\n position: relative;\n top: -5px;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-filter {\n position: absolute;\n right: 0;\n top: 0;\n cursor: pointer;\n width: 28px;\n text-align: left;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-filter.table-header-filter-select > svg {\n color: rgb(54, 102, 214);\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-filter.table-header-filter-show {\n background-color: rgba(54, 102, 214, 0.05);\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-filter.table-header-filter-show > svg {\n color: rgb(54, 102, 214);\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-filter:hover {\n background-color: rgb(227, 234, 247);\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-filter:hover > svg {\n color: rgb(54, 102, 214);\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box > .table-header-filter > svg {\n font-size: 14px;\n color: rgba(46, 55, 67, 0.7);\n margin-left: 7px;\n position: relative;\n top: 2px;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box.table-header-box-sort {\n cursor: pointer;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box.table-header-box-sort > .table-header-title > .table-header-title-label {\n max-width: calc(100% - 18px);\n width: auto;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box.table-header-box-filter > .table-header-title {\n margin-right: 18px;\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box.table-header-box-sort-asc > .table-header-title > .table-sort-svg > .up-svg {\n color: rgb(54, 102, 214);\n}\n.paraui-table > .table-contain > table > .table-head .table-header-box.table-header-box-sort-desc > .table-header-title > .table-sort-svg > .down-svg {\n color: rgb(54, 102, 214);\n}\n.paraui-table > .table-contain > table > .table-head .show-colums {\n width: 56px;\n cursor: pointer;\n border-left: 1px solid rgba(171, 176, 185, 0.12);\n right: 0;\n}\n.paraui-table > .table-contain > table > .table-head .show-colums .table-header-box {\n display: flex;\n align-items: center;\n justify-content: center;\n}\n.paraui-table > .table-contain > table > .table-head .show-colums .table-header-box > svg {\n font-size: 24px;\n color: rgba(46, 55, 67, 0.7);\n}\n.paraui-table > .table-contain > table > .table-head .show-colums .table-header-box:hover > svg {\n color: rgb(54, 102, 214);\n}\n.paraui-table > .table-contain > table > .table-head.table-head-no-btn tr th:first-child .table-header-box {\n padding-left: 16px;\n}\n.paraui-table > .table-contain > table > .table-head .table-head-btn {\n width: 32px;\n padding: 0;\n}\n.paraui-table > .table-contain > table > .table-head .table-head-btn:first-child {\n width: 48px;\n}\n.paraui-table > .table-contain > table > .table-body {\n width: 100%;\n}\n.paraui-table > .table-contain > table > .table-body.table-body-scroll tr td {\n max-width: 240px;\n color: rgba(46, 55, 67, 0.7);\n}\n.paraui-table > .table-contain > table > .table-body tr {\n height: 56px;\n}\n.paraui-table > .table-contain > table > .table-body tr td {\n background-color: white;\n}\n.paraui-table > .table-contain > table > .table-body tr:nth-of-type(2n) td {\n background-color: rgb(249, 250, 251);\n}\n.paraui-table > .table-contain > table > .table-body tr:hover td {\n background-color: rgb(237, 241, 249);\n}\n.paraui-table > .table-contain > table > .table-body tr .table-expandable > svg {\n transition: all 0.3s;\n cursor: pointer;\n font-size: 16px;\n color: rgba(46, 55, 67, 0.7);\n}\n.paraui-table > .table-contain > table > .table-body tr .table-expandable > svg:hover {\n color: rgb(54, 102, 214);\n}\n.paraui-table > .table-contain > table > .table-body tr .table-expandable > .expand {\n transform: rotate(180deg);\n color: rgb(54, 102, 214);\n}\n.paraui-table > .table-contain > table > .table-body .more-table-row {\n cursor: pointer;\n}\n.paraui-table > .table-contain > table > .table-body .more-table-row .more-btn {\n color: rgb(54, 102, 214);\n font-size: 14px;\n}\n.paraui-table > .table-contain > table > .table-body.table-body-no-btn tr td:first-child {\n padding-left: 16px;\n}\n.paraui-table > .table-contain > table > .table-body.table-body-no-btn > .table-no-data > td:first-child {\n padding: 0;\n}\n.paraui-table > .table-contain > table > .table-body .table-body-btn {\n width: 32px;\n padding: 0;\n}\n.paraui-table > .table-contain > table > .table-body .table-body-btn:first-child {\n width: 48px;\n}\n.paraui-table > .table-contain > table > .table-body > .table-no-data {\n height: calc(100% - 50px);\n}\n.paraui-table > .table-contain > table > .table-body > .table-no-data:hover td {\n background-color: white;\n}\n.paraui-table > .table-contain > table > .table-body > .table-no-data > td {\n padding: 56px 0 0 0;\n}\n.paraui-table > .paraui-table-pagination {\n width: 100%;\n height: 60px;\n padding-right: 10px;\n display: flex;\n align-items: flex-end;\n justify-content: flex-end;\n}\n.paraui-table.table-pagination > .table-contain {\n height: calc(100% - 60px);\n}\n.paraui-table.table-pagination.table-load-more > .table-contain {\n height: 100%;\n}\n.paraui-table-show-colums-popover > .paraui-popover-content {\n width: 200px;\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-box {\n padding-top: 8px;\n max-height: 224px;\n overflow-y: auto;\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-box > .show-colums-select-item {\n height: 36px;\n line-height: 36px;\n cursor: pointer;\n display: flex;\n padding: 0 4px;\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-box > .show-colums-select-item > label {\n width: 32px;\n display: flex;\n justify-content: center;\n align-items: center;\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-box > .show-colums-select-item > span {\n color: rgb(46, 55, 67);\n font-size: 14px;\n display: inline-block;\n width: calc(100% - 32px);\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-box > .show-colums-select-item:hover > span {\n color: rgb(54, 102, 214);\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-box > .show-colums-select-item:hover > label .paraui-checkbox-box-inner {\n border-color: rgb(54, 102, 214);\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-box > .show-colums-select-item.show-colums-select-item-select > span {\n color: rgb(54, 102, 214);\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-box > .show-colums-select-item.show-colums-select-item-select > label .paraui-checkbox-box-inner {\n border-color: rgb(54, 102, 214);\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-footer {\n height: 45px;\n border-top: 1px solid rgba(171, 176, 185, 0.2);\n text-align: center;\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-footer > button {\n width: 100%;\n height: 100%;\n border: 0;\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-footer > button > span {\n font-size: 14px;\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-footer > button > span > span {\n margin-right: 5px;\n color: rgb(46, 55, 67);\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-footer > button > span > span svg {\n font-size: 14px;\n color: rgb(46, 55, 67);\n}\n.paraui-table-show-colums-popover > .paraui-popover-content .show-colums-select > .show-colums-select-footer > button:hover > span > span svg {\n color: rgb(54, 102, 214);\n}\n\n.paraui-filter-popover > .paraui-popover-content {\n width: 200px;\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-box {\n padding-top: 8px;\n max-height: 224px;\n overflow-y: auto;\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-box > .filter-select-item {\n height: 36px;\n line-height: 36px;\n cursor: pointer;\n display: flex;\n padding: 0 4px;\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-box > .filter-select-item > label {\n width: 32px;\n display: flex;\n justify-content: center;\n align-items: center;\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-box > .filter-select-item > span {\n color: rgb(46, 55, 67);\n font-size: 14px;\n display: inline-block;\n width: calc(100% - 32px);\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-box > .filter-select-item:hover > span {\n color: rgb(54, 102, 214);\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-box > .filter-select-item:hover > label .rc-checkbox-inner {\n border-color: rgb(54, 102, 214);\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-box > .filter-select-item.filter-select-item-select > span {\n color: rgb(54, 102, 214);\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-box > .filter-select-item.filter-select-item-select > label .rc-checkbox-inner {\n border-color: rgb(54, 102, 214);\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-footer {\n height: 45px;\n border-top: 1px solid rgba(171, 176, 185, 0.2);\n text-align: center;\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-footer > button {\n width: 50%;\n height: 100%;\n border: 0;\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-footer > button > span {\n font-size: 14px;\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-footer > button > span > span {\n margin-right: 5px;\n color: rgb(46, 55, 67);\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-footer > button > span > span svg {\n font-size: 14px;\n color: rgb(46, 55, 67);\n}\n.paraui-filter-popover > .paraui-popover-content .filter-select > .filter-select-footer > button:hover > span > span svg {\n color: rgb(54, 102, 214);\n}";
|
|
1529
1537
|
styleInject(css_248z);
|
|
1530
1538
|
|
|
1531
1539
|
var Table = function Table(props) {
|
|
@@ -1760,7 +1768,6 @@ var Table = function Table(props) {
|
|
|
1760
1768
|
return function () {
|
|
1761
1769
|
clearTimeout(constData.reqTimer);
|
|
1762
1770
|
clearTimeout(constData.loadingTimer);
|
|
1763
|
-
clearTimeout(constData.reqLoadingTimer);
|
|
1764
1771
|
window.removeEventListener('resize', changeResize);
|
|
1765
1772
|
};
|
|
1766
1773
|
}, []);
|
|
@@ -1854,6 +1861,7 @@ var Table = function Table(props) {
|
|
|
1854
1861
|
|
|
1855
1862
|
useEffect(function () {
|
|
1856
1863
|
clearTimeout(constData.reqTimer);
|
|
1864
|
+
if (url) Cancel(reqId);
|
|
1857
1865
|
constData.reqTimer = setTimeout(function () {
|
|
1858
1866
|
constData.initReq = true;
|
|
1859
1867
|
|
|
@@ -2210,23 +2218,18 @@ var Table = function Table(props) {
|
|
|
2210
2218
|
while (1) {
|
|
2211
2219
|
switch (_context.prev = _context.next) {
|
|
2212
2220
|
case 0:
|
|
2213
|
-
Cancel(reqId); // 因为cancel掉以后,上一个接口err回来会取消loading,用setTimeout把事件推迟
|
|
2214
|
-
|
|
2215
|
-
clearTimeout(constData.reqLoadingTimer);
|
|
2216
|
-
constData.reqLoadingTimer = setTimeout(function () {
|
|
2217
|
-
if (props.loading === undefined) setLoadState(true);
|
|
2218
|
-
});
|
|
2219
2221
|
obj.uuid = reqId;
|
|
2220
|
-
|
|
2222
|
+
if (props.loading === undefined) setLoadState(true);
|
|
2223
|
+
_context.next = 4;
|
|
2221
2224
|
return requestFunc(obj);
|
|
2222
2225
|
|
|
2223
|
-
case
|
|
2226
|
+
case 4:
|
|
2224
2227
|
_yield$requestFunc = _context.sent;
|
|
2225
2228
|
data = _yield$requestFunc.data;
|
|
2226
2229
|
err = _yield$requestFunc.err;
|
|
2227
2230
|
|
|
2228
2231
|
if (!err) {
|
|
2229
|
-
_context.next =
|
|
2232
|
+
_context.next = 11;
|
|
2230
2233
|
break;
|
|
2231
2234
|
}
|
|
2232
2235
|
|
|
@@ -2240,7 +2243,7 @@ var Table = function Table(props) {
|
|
|
2240
2243
|
|
|
2241
2244
|
return _context.abrupt("return", false);
|
|
2242
2245
|
|
|
2243
|
-
case
|
|
2246
|
+
case 11:
|
|
2244
2247
|
if (requestCallback) {
|
|
2245
2248
|
requestCallback(data, function (handData) {
|
|
2246
2249
|
if (handData) {
|
|
@@ -2255,7 +2258,7 @@ var Table = function Table(props) {
|
|
|
2255
2258
|
if (props.loading === undefined) setLoadState(false);
|
|
2256
2259
|
}
|
|
2257
2260
|
|
|
2258
|
-
case
|
|
2261
|
+
case 12:
|
|
2259
2262
|
case "end":
|
|
2260
2263
|
return _context.stop();
|
|
2261
2264
|
}
|
package/TextField/index.d.ts
CHANGED
|
@@ -63,6 +63,8 @@ export interface TextFieldProps {
|
|
|
63
63
|
showSelectName?: string;
|
|
64
64
|
/** 返回输入建议的方法,仅当你的输入建议数据 resolve 时,通过调用 callback(data:[]) 来返回它 */
|
|
65
65
|
fetchSuggestions?: (val: string, cb: (data: any[]) => void) => void;
|
|
66
|
+
/** 下拉搜索空状态 */
|
|
67
|
+
searchEmpty?: ReactNode;
|
|
66
68
|
/** 渲染下拉子节点 */
|
|
67
69
|
renderSelectItem?: (item: any) => ReactNode;
|
|
68
70
|
/** 失去焦点 */
|
package/TextField/index.js
CHANGED
|
@@ -81,6 +81,7 @@ var TextField = function TextField(props) {
|
|
|
81
81
|
showSelectName = _a$showSelectName === void 0 ? 'value' : _a$showSelectName,
|
|
82
82
|
_a$resize = _a.resize,
|
|
83
83
|
resize = _a$resize === void 0 ? true : _a$resize,
|
|
84
|
+
searchEmpty = _a.searchEmpty,
|
|
84
85
|
onBlur = _a.onBlur,
|
|
85
86
|
onFocus = _a.onFocus,
|
|
86
87
|
onChange = _a.onChange,
|
|
@@ -91,7 +92,7 @@ var TextField = function TextField(props) {
|
|
|
91
92
|
onClickAddonAfter = _a.onClickAddonAfter,
|
|
92
93
|
onSelect = _a.onSelect,
|
|
93
94
|
onClear = _a.onClear,
|
|
94
|
-
otherProps = __rest(_a, ["className", "style", "size", "labelMode", "placeholder", "label", "labelTooltip", "disabled", "multiline", "required", "labelSign", "rows", "error", "helperText", "addonBefore", "addonAfter", "defaultValue", "value", "autoFocus", "type", "onClickIcon", "rightIcon", "showRightIcon", "allowClear", "limitLength", "fetchSuggestions", "selectPopoverClass", "renderSelectItem", "showSelectName", "resize", "onBlur", "onFocus", "onChange", "onKeydown", "onKeyUp", "onEnter", "onClickAddonBefore", "onClickAddonAfter", "onSelect", "onClear"]);
|
|
95
|
+
otherProps = __rest(_a, ["className", "style", "size", "labelMode", "placeholder", "label", "labelTooltip", "disabled", "multiline", "required", "labelSign", "rows", "error", "helperText", "addonBefore", "addonAfter", "defaultValue", "value", "autoFocus", "type", "onClickIcon", "rightIcon", "showRightIcon", "allowClear", "limitLength", "fetchSuggestions", "selectPopoverClass", "renderSelectItem", "showSelectName", "resize", "searchEmpty", "onBlur", "onFocus", "onChange", "onKeydown", "onKeyUp", "onEnter", "onClickAddonBefore", "onClickAddonAfter", "onSelect", "onClear"]);
|
|
95
96
|
|
|
96
97
|
var _useState = useState('text-field-select-content-' + UUID()),
|
|
97
98
|
_useState2 = _slicedToArray(_useState, 1),
|
|
@@ -586,9 +587,9 @@ var TextField = function TextField(props) {
|
|
|
586
587
|
children: handText(item)
|
|
587
588
|
})
|
|
588
589
|
}), index);
|
|
589
|
-
}), selectLoading && jsx(Loading, {})]
|
|
590
|
+
}), selectData.length === 0 && searchEmpty, selectLoading && jsx(Loading, {})]
|
|
590
591
|
}));
|
|
591
|
-
}, [selectPosDom, open, selectData, renderSelectItem, showSelectName, onSelect, selectLoading, classSearchOne]); // 带有搜索的中间主体
|
|
592
|
+
}, [selectPosDom, open, selectData, renderSelectItem, showSelectName, onSelect, selectLoading, classSearchOne, searchEmpty]); // 带有搜索的中间主体
|
|
592
593
|
|
|
593
594
|
var searchContentMemo = useMemo(function () {
|
|
594
595
|
return jsx(Dropdown, Object.assign({
|
package/Tree/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { T as Tree } from '../_verture/index-
|
|
2
|
-
export { T as default } from '../_verture/index-
|
|
1
|
+
import { T as Tree } from '../_verture/index-5bb4b5d7.js';
|
|
2
|
+
export { T as default } from '../_verture/index-5bb4b5d7.js';
|
|
3
3
|
import '../_verture/toConsumableArray-f8047a75.js';
|
|
4
4
|
import '../_verture/slicedToArray-d7722f4b.js';
|
|
5
5
|
import '../_verture/defineProperty-0590dc61.js';
|
package/Tree/interface.d.ts
CHANGED
|
@@ -161,8 +161,6 @@ export interface TreeProps extends Omit<RcTreeProps, 'prefixCls' | 'showLine' |
|
|
|
161
161
|
paramsCallback?: (params: {
|
|
162
162
|
[name: string]: any;
|
|
163
163
|
}) => any;
|
|
164
|
-
/** 非空渲染完成时回调 */
|
|
165
|
-
onMounted?: () => void;
|
|
166
164
|
/** 空状态属性 */
|
|
167
165
|
emptyProps?: EmptyProps;
|
|
168
166
|
/** 自定义空数据节点 */
|
|
File without changes
|
|
File without changes
|
package/index.d.ts
CHANGED
|
@@ -94,6 +94,8 @@ export { default as SelectInput } from './SelectInput';
|
|
|
94
94
|
export * from './SelectInput';
|
|
95
95
|
export { default as Selector } from './Selector';
|
|
96
96
|
export * from './Selector';
|
|
97
|
+
export { default as SelectorPicker } from './SelectorPicker';
|
|
98
|
+
export * from './SelectorPicker';
|
|
97
99
|
export { default as SingleBox } from './SingleBox';
|
|
98
100
|
export * from './SingleBox';
|
|
99
101
|
export { default as Slider } from './Slider';
|
package/index.js
CHANGED
|
@@ -19,8 +19,8 @@ export { Drawer } from './Drawer/index.js';
|
|
|
19
19
|
export { Dropdown } from './Dropdown/index.js';
|
|
20
20
|
export { default as Empty } from './Empty/index.js';
|
|
21
21
|
export { default as Form } from './Form/index.js';
|
|
22
|
-
export { F as FormItem } from './_verture/index-
|
|
23
|
-
export { u as FunctionModal, F as FunctionModalProvider, a as useClose } from './_verture/modalContext-
|
|
22
|
+
export { F as FormItem } from './_verture/index-abfdd262.js';
|
|
23
|
+
export { u as FunctionModal, F as FunctionModalProvider, a as useClose } from './_verture/modalContext-59669f93.js';
|
|
24
24
|
export { default as GlobalContext, changeConfirmLocale, getConfirmLocale } from './GlobalContext/index.js';
|
|
25
25
|
export { default as Help } from './Help/index.js';
|
|
26
26
|
export { default as HelperText } from './HelperText/index.js';
|
|
@@ -46,7 +46,8 @@ export { RadioGroup } from './RadioGroup/index.js';
|
|
|
46
46
|
export { Search } from './Search/index.js';
|
|
47
47
|
export { default as Select } from './Select/index.js';
|
|
48
48
|
export { SelectInput } from './SelectInput/index.js';
|
|
49
|
-
export { default as Selector } from './Selector/index.js';
|
|
49
|
+
export { default as Selector, handFieldConfig } from './Selector/index.js';
|
|
50
|
+
export { default as SelectorPicker } from './SelectorPicker/index.js';
|
|
50
51
|
export { SingleBox } from './SingleBox/index.js';
|
|
51
52
|
export { Slider } from './Slider/index.js';
|
|
52
53
|
export { default as Split } from './Split/index.js';
|
|
@@ -62,7 +63,7 @@ export { Timeline } from './Timeline/index.js';
|
|
|
62
63
|
export { ToggleButton, ToggleButtonGroup } from './ToggleButton/index.js';
|
|
63
64
|
export { Tooltip } from './Tooltip/index.js';
|
|
64
65
|
export { Transfer } from './Transfer/index.js';
|
|
65
|
-
export { T as Tree } from './_verture/index-
|
|
66
|
+
export { T as Tree } from './_verture/index-5bb4b5d7.js';
|
|
66
67
|
export { default as Upload } from './Upload/index.js';
|
|
67
68
|
import './_verture/slicedToArray-d7722f4b.js';
|
|
68
69
|
import 'react/jsx-runtime';
|
|
@@ -127,6 +128,7 @@ import '@para-ui/icons/DoubleRight';
|
|
|
127
128
|
import '@para-ui/icons/Left';
|
|
128
129
|
import 'rc-progress';
|
|
129
130
|
import '@para-ui/icons/Check';
|
|
131
|
+
import '@para-ui/icons/Refresh';
|
|
130
132
|
import 'rc-slider';
|
|
131
133
|
import 'rc-steps';
|
|
132
134
|
import '@para-ui/icons/One';
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@para-ui/core",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "3.0.
|
|
4
|
+
"version": "3.0.1",
|
|
5
5
|
"main": "./index.js",
|
|
6
6
|
"typings": "./index.d.ts",
|
|
7
7
|
"description": "Powered by Para FED",
|
|
@@ -9,13 +9,14 @@
|
|
|
9
9
|
"license": "ParaView",
|
|
10
10
|
"scripts": {
|
|
11
11
|
"ci": "npm ci --unsafe-perm && npm run build",
|
|
12
|
-
"start": "node run dev && webpack serve --config=./config/webpack.dev.config.js",
|
|
13
|
-
"build": "
|
|
12
|
+
"start": "node run dev && webpack serve --mode=development --config=./config/webpack.dev.config.js",
|
|
13
|
+
"build:docs": "node run && webpack --config=./config/webpack.dev.config.js",
|
|
14
|
+
"build": "rm -rf dist && rollup -c",
|
|
14
15
|
"npm:publish": "./publish.sh"
|
|
15
16
|
},
|
|
16
17
|
"dependencies": {
|
|
17
|
-
"@para-ui/core": "^
|
|
18
|
-
"@para-ui/icons": "^
|
|
18
|
+
"@para-ui/core": "^3.0.0",
|
|
19
|
+
"@para-ui/icons": "^3.0.0",
|
|
19
20
|
"@paraview/lib": "^2.0.3",
|
|
20
21
|
"clsx": "1.1.1",
|
|
21
22
|
"dayjs": "^1.11.3",
|
|
@@ -76,6 +77,7 @@
|
|
|
76
77
|
"fs-extra": "^8.1.0",
|
|
77
78
|
"html-webpack-plugin": "^5.5.0",
|
|
78
79
|
"mini-css-extract-plugin": "^2.6.1",
|
|
80
|
+
"minimist": "^1.2.6",
|
|
79
81
|
"postcss": "^8.4.14",
|
|
80
82
|
"postcss-import": "^14.1.0",
|
|
81
83
|
"react-app-polyfill": "^3.0.0",
|