@para-ui/core 4.0.48 → 4.0.50
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/Cascader/index.js +5 -4
- package/ComboSelect/index.js +3 -2
- package/CycleSelector/index.js +4 -1
- package/DatePicker/index.js +4 -1
- package/DynamicMultiBox/index.js +3 -2
- package/Form/index.js +4 -3
- package/FormItem/index.js +4 -3
- package/Image/index.js +3 -2
- package/README.md +10 -0
- package/SingleBox/index.js +2 -2
- package/Stepper/index.js +1 -1
- package/Table/index.js +84 -26
- package/Table/interface.d.ts +0 -2
- package/Tag/index.js +87 -55
- package/TimePicker/index.js +4 -1
- package/Timeline/index.js +2 -1
- package/ToggleButton/index.js +2 -1
- package/Tree/index.js +4 -3
- package/Upload/index.js +19 -8
- package/Upload/interface.d.ts +2 -0
- package/Utils/Hooks/useResizeObserver.d.ts +8 -0
- package/_verture/{Portal-42560ff0.js → Portal-f9bedb3a.js} +2 -1
- package/_verture/{defineProperty-f0e15205.js → defineProperty-6f62bb2a.js} +2 -10
- package/_verture/{index-72981a9e.js → index-6647cbf6.js} +2 -1
- package/_verture/{index-063009f8.js → index-972707a5.js} +3 -2
- package/_verture/typeof-adeedc13.js +11 -0
- package/index.js +6 -5
- package/package.json +1 -1
- package/umd/ComboSelect.js +2 -2
- package/umd/DynamicMultiBox.js +1 -1
- package/umd/Form.js +1 -1
- package/umd/FormItem.js +4 -4
- package/umd/Table.js +4 -4
- package/umd/Upload.js +2 -2
- /package/_verture/{index-caffc0da.js → index-bd0da612.js} +0 -0
package/Tag/index.js
CHANGED
|
@@ -4,6 +4,9 @@ import { useState, useRef, useEffect } from 'react';
|
|
|
4
4
|
import Close from '@para-ui/icons/Close';
|
|
5
5
|
import EditOutline from '@para-ui/icons/EditOutline';
|
|
6
6
|
import clsx from 'clsx';
|
|
7
|
+
import { _ as _toConsumableArray } from '../_verture/toConsumableArray-c7a8028f.js';
|
|
8
|
+
import { _ as _typeof } from '../_verture/typeof-adeedc13.js';
|
|
9
|
+
import { _ as _slicedToArray } from '../_verture/slicedToArray-75fa4188.js';
|
|
7
10
|
import { $ as $prefixCls } from '../_verture/constant-5317fc89.js';
|
|
8
11
|
import AutoTips from '../AutoTips/index.js';
|
|
9
12
|
import { t as tinycolor } from '../_verture/tinycolor-ece3542d.js';
|
|
@@ -21,102 +24,129 @@ var css_248z = "@charset \"UTF-8\";\n/**\n* @author Hanz\n* @date 2022/1/12 上
|
|
|
21
24
|
styleInject(css_248z);
|
|
22
25
|
|
|
23
26
|
//tag group
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
className,
|
|
27
|
-
size =
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
27
|
+
var TagGroup = function TagGroup(props) {
|
|
28
|
+
var _useGlobalProps = useGlobalProps(props, 'TagGroup'),
|
|
29
|
+
className = _useGlobalProps.className,
|
|
30
|
+
_useGlobalProps$size = _useGlobalProps.size,
|
|
31
|
+
size = _useGlobalProps$size === void 0 ? 'large' : _useGlobalProps$size,
|
|
32
|
+
style = _useGlobalProps.style,
|
|
33
|
+
defaultInputValue = _useGlobalProps.defaultInputValue,
|
|
34
|
+
_useGlobalProps$incre = _useGlobalProps.increased,
|
|
35
|
+
increased = _useGlobalProps$incre === void 0 ? false : _useGlobalProps$incre,
|
|
36
|
+
increasedTag = _useGlobalProps.increasedTag,
|
|
37
|
+
inputClassName = _useGlobalProps.inputClassName,
|
|
38
|
+
inputWidth = _useGlobalProps.inputWidth,
|
|
39
|
+
_useGlobalProps$margi = _useGlobalProps.marginBottom,
|
|
40
|
+
marginBottom = _useGlobalProps$margi === void 0 ? '8px' : _useGlobalProps$margi,
|
|
41
|
+
_useGlobalProps$margi2 = _useGlobalProps.marginRight,
|
|
42
|
+
marginRight = _useGlobalProps$margi2 === void 0 ? '8px' : _useGlobalProps$margi2,
|
|
43
|
+
onChange = _useGlobalProps.onChange;
|
|
44
|
+
var _useState = useState([]),
|
|
45
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
46
|
+
inData = _useState2[0],
|
|
47
|
+
setInData = _useState2[1]; //数据源
|
|
48
|
+
var _useState3 = useState(defaultInputValue !== null && defaultInputValue !== void 0 ? defaultInputValue : ''),
|
|
49
|
+
_useState4 = _slicedToArray(_useState3, 2),
|
|
50
|
+
inputValue = _useState4[0],
|
|
51
|
+
setInputValue = _useState4[1]; //input value
|
|
52
|
+
var _useState5 = useState(false),
|
|
53
|
+
_useState6 = _slicedToArray(_useState5, 2),
|
|
54
|
+
inputVisible = _useState6[0],
|
|
55
|
+
setInputVisible = _useState6[1]; //input visible
|
|
56
|
+
var inputRef = useRef(); //input ref
|
|
57
|
+
var _useState7 = useState(),
|
|
58
|
+
_useState8 = _slicedToArray(_useState7, 2),
|
|
59
|
+
increasedInputWidth = _useState8[0],
|
|
60
|
+
setIncreasedInputWidth = _useState8[1]; //添加标签的最小宽
|
|
61
|
+
useEffect(function () {
|
|
44
62
|
if (props.data) {
|
|
45
|
-
|
|
63
|
+
var tArr = props.data;
|
|
46
64
|
//Item[]
|
|
47
|
-
|
|
65
|
+
var unObjType = tArr.some(function (v) {
|
|
66
|
+
return ['string', 'number'].includes(_typeof(v));
|
|
67
|
+
});
|
|
48
68
|
if (unObjType) {
|
|
49
|
-
tArr = tArr.map(_
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
69
|
+
tArr = tArr.map(function (_) {
|
|
70
|
+
return {
|
|
71
|
+
value: _,
|
|
72
|
+
label: _
|
|
73
|
+
};
|
|
74
|
+
});
|
|
53
75
|
}
|
|
54
|
-
setInData(
|
|
76
|
+
setInData(_toConsumableArray(tArr));
|
|
55
77
|
}
|
|
56
78
|
}, [props.data]);
|
|
57
79
|
//tag value
|
|
58
|
-
|
|
59
|
-
return data.map(
|
|
80
|
+
var getTagGroupVal = function getTagGroupVal(data) {
|
|
81
|
+
return data.map(function (_) {
|
|
82
|
+
return _.value;
|
|
83
|
+
});
|
|
60
84
|
};
|
|
61
85
|
//show input
|
|
62
|
-
|
|
86
|
+
var showInput = function showInput() {
|
|
63
87
|
setInputVisible(true);
|
|
64
|
-
setTimeout(()
|
|
88
|
+
setTimeout(function () {
|
|
65
89
|
var _a;
|
|
66
90
|
(_a = inputRef.current) === null || _a === void 0 ? void 0 : _a.focus();
|
|
67
91
|
});
|
|
68
92
|
};
|
|
69
|
-
|
|
93
|
+
var handleTagEdit = function handleTagEdit(value, idx) {
|
|
70
94
|
inData[idx].value = value;
|
|
71
|
-
setInData(
|
|
95
|
+
setInData(_toConsumableArray(inData));
|
|
72
96
|
onChange === null || onChange === void 0 ? void 0 : onChange(inData, getTagGroupVal(inData));
|
|
73
97
|
};
|
|
74
98
|
//input change
|
|
75
|
-
|
|
99
|
+
var handleInputChange = function handleInputChange(e) {
|
|
76
100
|
setInputValue(e.target.value);
|
|
77
101
|
};
|
|
78
102
|
//input confirm
|
|
79
|
-
|
|
80
|
-
|
|
103
|
+
var handleInputConfirm = function handleInputConfirm() {
|
|
104
|
+
var val = inputValue.trim();
|
|
81
105
|
if (val !== '') {
|
|
82
106
|
inData.push({
|
|
83
107
|
value: val,
|
|
84
108
|
label: val,
|
|
85
109
|
closable: true
|
|
86
110
|
});
|
|
87
|
-
setInData(
|
|
111
|
+
setInData(_toConsumableArray(inData));
|
|
88
112
|
onChange === null || onChange === void 0 ? void 0 : onChange(inData, getTagGroupVal(inData));
|
|
89
113
|
}
|
|
90
114
|
setInputValue(defaultInputValue !== null && defaultInputValue !== void 0 ? defaultInputValue : '');
|
|
91
115
|
setInputVisible(false);
|
|
92
116
|
};
|
|
93
117
|
//input enter
|
|
94
|
-
|
|
118
|
+
var handleInputEnter = function handleInputEnter(e) {
|
|
95
119
|
if (e.keyCode === 13 || e.which === 13) {
|
|
96
120
|
handleInputConfirm();
|
|
97
121
|
}
|
|
98
122
|
};
|
|
99
123
|
//handle close
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
124
|
+
var handleClose = function handleClose(item) {
|
|
125
|
+
return function (e) {
|
|
126
|
+
var idx = inData.findIndex(function (_) {
|
|
127
|
+
return _.value === item.value;
|
|
128
|
+
});
|
|
129
|
+
if (idx > -1) {
|
|
130
|
+
inData.splice(idx, 1);
|
|
131
|
+
setInData(_toConsumableArray(inData));
|
|
132
|
+
}
|
|
133
|
+
if (item.onClose) item.onClose(e);
|
|
134
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(inData, getTagGroupVal(inData));
|
|
135
|
+
};
|
|
108
136
|
};
|
|
109
137
|
//渲染Tag组
|
|
110
|
-
|
|
138
|
+
var renderTagGroup = function renderTagGroup() {
|
|
111
139
|
if (!(inData === null || inData === void 0 ? void 0 : inData.length)) return null;
|
|
112
|
-
return inData.map((item, idx)
|
|
140
|
+
return inData.map(function (item, idx) {
|
|
113
141
|
return jsx(Tag, Object.assign({
|
|
114
142
|
marginBottom: marginBottom,
|
|
115
143
|
marginRight: marginRight
|
|
116
144
|
}, item, {
|
|
117
145
|
size: size,
|
|
118
146
|
visible: true,
|
|
119
|
-
tagChange:
|
|
147
|
+
tagChange: function tagChange(value) {
|
|
148
|
+
return handleTagEdit(value, idx);
|
|
149
|
+
},
|
|
120
150
|
onClose: handleClose(item)
|
|
121
151
|
}, {
|
|
122
152
|
children: item.label
|
|
@@ -124,10 +154,10 @@ const TagGroup = props => {
|
|
|
124
154
|
});
|
|
125
155
|
};
|
|
126
156
|
//动态增加tag
|
|
127
|
-
|
|
157
|
+
var renderNewInput = function renderNewInput() {
|
|
128
158
|
var _a;
|
|
129
159
|
if (inputVisible) {
|
|
130
|
-
|
|
160
|
+
var inputCls = clsx('tag-group-input', {
|
|
131
161
|
'tag-group-input-large': size === 'large'
|
|
132
162
|
}, inputClassName);
|
|
133
163
|
return jsx("input", {
|
|
@@ -144,17 +174,19 @@ const TagGroup = props => {
|
|
|
144
174
|
onKeyDown: handleInputEnter
|
|
145
175
|
});
|
|
146
176
|
}
|
|
147
|
-
|
|
148
|
-
|
|
177
|
+
var icon = jsx(Plus, {});
|
|
178
|
+
var text = 'New Tag';
|
|
149
179
|
if (increasedTag) {
|
|
150
180
|
icon = increasedTag.icon || jsx(Plus, {});
|
|
151
181
|
text = (_a = increasedTag.text) !== null && _a !== void 0 ? _a : 'New Tag';
|
|
152
182
|
}
|
|
153
|
-
|
|
183
|
+
var newCls = clsx('tag-group-new', {
|
|
154
184
|
'tag-group-new-icon': !text
|
|
155
185
|
}, 'tag-group-add-btn');
|
|
156
186
|
return jsx(Tag, Object.assign({
|
|
157
|
-
getWidth:
|
|
187
|
+
getWidth: function getWidth(width) {
|
|
188
|
+
return setIncreasedInputWidth(width);
|
|
189
|
+
},
|
|
158
190
|
className: newCls,
|
|
159
191
|
size: size,
|
|
160
192
|
icon: icon,
|
package/TimePicker/index.js
CHANGED
|
@@ -24,10 +24,13 @@ import '@para-ui/icons/Forbid';
|
|
|
24
24
|
import '../Tag/index.js';
|
|
25
25
|
import '@para-ui/icons/Close';
|
|
26
26
|
import '@para-ui/icons/EditOutline';
|
|
27
|
+
import '../_verture/toConsumableArray-c7a8028f.js';
|
|
28
|
+
import '../_verture/slicedToArray-75fa4188.js';
|
|
29
|
+
import '../_verture/typeof-adeedc13.js';
|
|
27
30
|
import '../_verture/tinycolor-ece3542d.js';
|
|
28
31
|
import '../_verture/useGlobalProps-4ae1a007.js';
|
|
29
32
|
import '@para-ui/icons/Plus';
|
|
30
|
-
import '../_verture/defineProperty-
|
|
33
|
+
import '../_verture/defineProperty-6f62bb2a.js';
|
|
31
34
|
import 'rc-picker';
|
|
32
35
|
import '@para-ui/icons/CloseCircleF';
|
|
33
36
|
import '@para-ui/icons/Calendar';
|
package/Timeline/index.js
CHANGED
|
@@ -2,9 +2,10 @@ import { _ as __rest } from '../_verture/tslib.es6-55ed4bd2.js';
|
|
|
2
2
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
3
3
|
import React__default from 'react';
|
|
4
4
|
import clsx from 'clsx';
|
|
5
|
-
import {
|
|
5
|
+
import { _ as _defineProperty } from '../_verture/defineProperty-6f62bb2a.js';
|
|
6
6
|
import { a as $rcPrefixCls, $ as $prefixCls } from '../_verture/constant-5317fc89.js';
|
|
7
7
|
import { s as styleInject } from '../_verture/style-inject.es-300983ab.js';
|
|
8
|
+
import '../_verture/typeof-adeedc13.js';
|
|
8
9
|
|
|
9
10
|
//TimelineItem
|
|
10
11
|
var TimelineItem = function TimelineItem(props) {
|
package/ToggleButton/index.js
CHANGED
|
@@ -2,7 +2,7 @@ import { _ as __rest } from '../_verture/tslib.es6-55ed4bd2.js';
|
|
|
2
2
|
import { jsx } from 'react/jsx-runtime';
|
|
3
3
|
import { useRef } from 'react';
|
|
4
4
|
import { Button } from '../Button/index.js';
|
|
5
|
-
import {
|
|
5
|
+
import { _ as _defineProperty } from '../_verture/defineProperty-6f62bb2a.js';
|
|
6
6
|
import { UUID } from '@paraview/lib';
|
|
7
7
|
import clsx from 'clsx';
|
|
8
8
|
import { $ as $prefixCls } from '../_verture/constant-5317fc89.js';
|
|
@@ -20,6 +20,7 @@ import '../_verture/usePopupContainer-635f66f4.js';
|
|
|
20
20
|
import 'dayjs';
|
|
21
21
|
import '../_verture/useFormatMessage-1fc7c957.js';
|
|
22
22
|
import '../_verture/index-ca413216.js';
|
|
23
|
+
import '../_verture/typeof-adeedc13.js';
|
|
23
24
|
|
|
24
25
|
var css_248z = "@charset \"UTF-8\";\n/**\n* @author Hanz\n* @date 2021/11/23 上午9:50\n* @description\n*/\n/**\n* @author linhd\n* @date 2023/4/11 14:16\n* @description 最新色卡\n*/\n.paraui-v4-toggle-button.toggle-button-outlined.paraui-v4-toggle-button-radio.paraui-v4-toggle-button-selected {\n border-color: rgb(46, 101, 230);\n color: rgb(255, 255, 255);\n background-color: rgb(46, 101, 230);\n}\n.paraui-v4-toggle-button.toggle-button-outlined.paraui-v4-toggle-button-radio.paraui-v4-toggle-button-selected:hover {\n border-color: rgb(46, 101, 230);\n}\n.paraui-v4-toggle-button.toggle-button-outlined.paraui-v4-toggle-button-radio:hover {\n border-color: rgb(87, 131, 235);\n}\n.paraui-v4-toggle-button.toggle-button-outlined.paraui-v4-toggle-button-radio[disabled] {\n color: rgb(161, 168, 179);\n background-color: rgb(255, 255, 255);\n border: 1px solid rgb(212, 218, 227);\n}\n.paraui-v4-toggle-button.toggle-button-outlined.paraui-v4-toggle-button-radio[disabled]:hover {\n color: rgb(161, 168, 179);\n}\n.paraui-v4-toggle-button.toggle-button-outlined.paraui-v4-toggle-button-radio[disabled].paraui-v4-toggle-button-selected {\n color: rgb(92, 101, 115);\n background-color: rgb(247, 248, 250);\n border: 1px solid rgb(212, 218, 227);\n}\n.paraui-v4-toggle-button.toggle-button-outlined.paraui-v4-toggle-button-check::before {\n content: \" \";\n position: absolute;\n bottom: 0;\n right: 0;\n border: 8px solid rgb(212, 218, 227);\n border-top-color: transparent;\n border-left-color: transparent;\n}\n.paraui-v4-toggle-button.toggle-button-outlined.paraui-v4-toggle-button-check::after {\n content: \" \";\n width: 8px;\n height: 8px;\n background-image: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABHNCSVQICAgIfAhkiAAAAM5JREFUOE/NkQENwjAURFcFIAEHgIM5YCgAHCABFBAUAA5wABI2CTgABeUd+V06BqFkCeEnl6X9d7d/vy7rWK6jPvu9gfe+z9QnsHDOlV9NgHhk4gpxrvjJBogL+DtwATkG12QDxEvIG3AzcRmW/5gAgsaR+1S54peht+c8s7vxc7+OAFHCIVhBWkfLUm6VliazRsUGAzoy6YEz0LaDeItYMVrVWCJ/nVuUmHhArPuX1XoFTI4wJ8au+NYb/ziBCJZdJqoiPFfyBO+I/2twBz0qQBFvrubpAAAAAElFTkSuQmCC\");\n background-size: 8px 8px;\n background-repeat: no-repeat;\n position: absolute;\n bottom: 1px;\n right: 1px;\n}\n.paraui-v4-toggle-button.toggle-button-outlined.paraui-v4-toggle-button-check:hover {\n border-color: rgb(87, 131, 235);\n}\n.paraui-v4-toggle-button.toggle-button-outlined.paraui-v4-toggle-button-check:hover::before {\n border-color: rgb(87, 131, 235);\n border-top-color: transparent;\n border-left-color: transparent;\n}\n.paraui-v4-toggle-button.toggle-button-outlined.paraui-v4-toggle-button-check.paraui-v4-toggle-button-selected {\n border-color: rgb(46, 101, 230);\n color: rgb(46, 101, 230);\n}\n.paraui-v4-toggle-button.toggle-button-outlined.paraui-v4-toggle-button-check.paraui-v4-toggle-button-selected::before {\n border-color: rgb(46, 101, 230);\n border-top-color: transparent;\n border-left-color: transparent;\n}\n.paraui-v4-toggle-button.toggle-button-outlined.paraui-v4-toggle-button-check[disabled] {\n color: rgb(161, 168, 179);\n background-color: rgb(255, 255, 255);\n border: 1px solid rgb(212, 218, 227);\n}\n.paraui-v4-toggle-button.toggle-button-outlined.paraui-v4-toggle-button-check[disabled]::before {\n border-color: rgb(212, 218, 227);\n border-top-color: transparent;\n border-left-color: transparent;\n}\n.paraui-v4-toggle-button.toggle-button-outlined.paraui-v4-toggle-button-check[disabled]:hover {\n color: rgb(161, 168, 179);\n background-color: rgb(255, 255, 255);\n border: 1px solid rgb(212, 218, 227);\n}\n.paraui-v4-toggle-button.toggle-button-outlined.paraui-v4-toggle-button-check[disabled]:hover::before {\n border-color: rgb(212, 218, 227);\n border-top-color: transparent;\n border-left-color: transparent;\n}\n.paraui-v4-toggle-button.toggle-button-outlined.paraui-v4-toggle-button-check[disabled].paraui-v4-toggle-button-selected {\n color: rgb(92, 101, 115);\n background-color: rgb(247, 248, 250);\n}\n.paraui-v4-toggle-button.toggle-button-icon.paraui-v4-toggle-button-selected {\n border-color: rgb(46, 101, 230);\n color: rgb(255, 255, 255);\n background-color: rgb(46, 101, 230);\n}\n.paraui-v4-toggle-button.toggle-button-icon.paraui-v4-toggle-button-selected:hover {\n border-color: rgb(46, 101, 230);\n}\n.paraui-v4-toggle-button.toggle-button-icon[disabled].paraui-v4-toggle-button-selected {\n border-color: rgba(255, 255, 255, 0.5);\n}\n.paraui-v4-toggle-button.toggle-button-icon[disabled].paraui-v4-toggle-button-selected::before {\n width: 100%;\n height: 100%;\n position: absolute;\n top: 0;\n left: 0;\n z-index: 1;\n content: \"\";\n background-color: rgba(255, 255, 255, 0.5);\n}\n.paraui-v4-toggle-button.toggle-button-text.paraui-v4-button-text {\n color: rgb(29, 33, 38);\n}\n.paraui-v4-toggle-button.toggle-button-text.paraui-v4-button-text:hover {\n color: rgb(46, 101, 230);\n}\n.paraui-v4-toggle-button.toggle-button-text.paraui-v4-button-text:hover[disabled] {\n color: rgb(92, 101, 115);\n}\n.paraui-v4-toggle-button.toggle-button-text.paraui-v4-toggle-button-selected {\n color: rgb(46, 101, 230);\n border: 0;\n font-weight: 700;\n}\n.paraui-v4-toggle-button.toggle-button-text.paraui-v4-toggle-button-selected:hover {\n color: rgb(46, 101, 230);\n}\n.paraui-v4-toggle-button.toggle-button-text.paraui-v4-toggle-button-selected[disabled] {\n color: rgb(92, 101, 115);\n background-color: transparent;\n border: 0;\n}\n.paraui-v4-toggle-button.toggle-button-text.paraui-v4-toggle-button-selected[disabled]:hover {\n background-color: transparent;\n}\n.paraui-v4-toggle-button.toggle-button-text.paraui-v4-toggle-button-selected:first-child:before {\n display: none;\n}\n.paraui-v4-toggle-button.toggle-button-text.paraui-v4-toggle-button-selected::after {\n display: none;\n}\n.paraui-v4-toggle-button.toggle-button-text[disabled] {\n color: rgb(161, 168, 179);\n background-color: transparent;\n border: 0;\n}\n.paraui-v4-toggle-button.toggle-button-text[disabled]:hover {\n color: rgb(161, 168, 179);\n}\n.paraui-v4-toggle-button-wrap {\n display: inline-block;\n}\n.paraui-v4-toggle-button .toggle-button-text {\n width: 100%;\n}\n.paraui-v4-toggle-button-disabled.paraui-v4-toggle-button {\n color: rgb(92, 101, 115);\n}\n.paraui-v4-toggle-button-disabled.paraui-v4-toggle-button:hover {\n color: rgb(92, 101, 115);\n}\n\n.paraui-v4-togglebutton-group {\n display: flex;\n flex-flow: row wrap;\n}\n.paraui-v4-togglebutton-group .toggle-button-item {\n margin: 0 8px;\n}\n.paraui-v4-togglebutton-group-text .toggle-button-item .paraui-v4-toggle-button {\n margin: 0;\n padding: 0 16px;\n}\n.paraui-v4-togglebutton-group-text .toggle-button-item ~ .toggle-button-item .paraui-v4-toggle-button::before {\n position: absolute;\n left: 0;\n top: 50%;\n transform: translateY(-50%);\n content: \"\";\n width: 1px;\n height: 14px;\n background-color: rgb(212, 218, 227);\n}";
|
|
25
26
|
styleInject(css_248z);
|
package/Tree/index.js
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import { T as Tree } from '../_verture/index-
|
|
2
|
-
export { T as default } from '../_verture/index-
|
|
1
|
+
import { T as Tree } from '../_verture/index-6647cbf6.js';
|
|
2
|
+
export { T as default } from '../_verture/index-6647cbf6.js';
|
|
3
3
|
import '../_verture/toConsumableArray-c7a8028f.js';
|
|
4
4
|
import '../_verture/slicedToArray-75fa4188.js';
|
|
5
|
-
import '../_verture/defineProperty-
|
|
5
|
+
import '../_verture/defineProperty-6f62bb2a.js';
|
|
6
|
+
import '../_verture/typeof-adeedc13.js';
|
|
6
7
|
import '../_verture/index-8ac46bd9.js';
|
|
7
8
|
import '../_verture/typeof-6ec38efd.js';
|
|
8
9
|
import '../_verture/tslib.es6-55ed4bd2.js';
|
package/Upload/index.js
CHANGED
|
@@ -6,7 +6,7 @@ import clsx from 'clsx';
|
|
|
6
6
|
import UploadIcon from '@para-ui/icons/UploadFile';
|
|
7
7
|
import LoadingIcon from '@para-ui/icons/Loading';
|
|
8
8
|
import { _ as _toConsumableArray } from '../_verture/toConsumableArray-c7a8028f.js';
|
|
9
|
-
import { _ as _typeof } from '../_verture/
|
|
9
|
+
import { _ as _typeof } from '../_verture/typeof-adeedc13.js';
|
|
10
10
|
import { _ as _slicedToArray } from '../_verture/slicedToArray-75fa4188.js';
|
|
11
11
|
import { r as regenerator } from '../_verture/index-8ac46bd9.js';
|
|
12
12
|
import EditOutline from '@para-ui/icons/EditOutline';
|
|
@@ -36,8 +36,9 @@ import { Modal } from '../Modal/index.js';
|
|
|
36
36
|
import '../_verture/typeof-6ec38efd.js';
|
|
37
37
|
import 'rc-tooltip';
|
|
38
38
|
import 'rc-tooltip/lib/placements';
|
|
39
|
-
import '../_verture/Portal-
|
|
39
|
+
import '../_verture/Portal-f9bedb3a.js';
|
|
40
40
|
import 'react-dom';
|
|
41
|
+
import '../_verture/defineProperty-6f62bb2a.js';
|
|
41
42
|
import 'rc-dialog';
|
|
42
43
|
import 'rc-motion';
|
|
43
44
|
import '@para-ui/icons/Sort';
|
|
@@ -1663,7 +1664,7 @@ var ImgCrop = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
|
1663
1664
|
});
|
|
1664
1665
|
});
|
|
1665
1666
|
|
|
1666
|
-
var css_248z = "@charset \"UTF-8\";\n/**\n* @author Hanz\n* @date 2021/11/11 下午1:40\n* @description\n*/\n/**\n* @author linhd\n* @date 2023/4/11 14:16\n* @description 最新色卡\n*/\n.paraui-v4-upload .component-upload {\n position: relative;\n display: inline-block;\n}\n.paraui-v4-upload-loading {\n pointer-events: none;\n}\n.paraui-v4-upload-drag {\n position: relative;\n}\n.paraui-v4-upload-drag-loading {\n pointer-events: none;\n}\n.paraui-v4-upload-drag-hover .upload-drag-container {\n border-color: rgb(87, 131, 235);\n}\n.paraui-v4-upload-drag .upload-drag-container {\n display: inline-flex;\n width: 100%;\n height: 200px;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n font-size: 14px;\n line-height: 1;\n border: 1px dashed rgb(212, 218, 227);\n background-color: rgb(247, 248, 250);\n border-radius: 4px;\n cursor: pointer;\n transition: 0.3s;\n}\n.paraui-v4-upload-drag .upload-drag-container:hover {\n border-color: rgb(87, 131, 235);\n}\n.paraui-v4-upload-drag .upload-drag-container:hover .upload-drag-text {\n color: rgb(46, 101, 230);\n}\n.paraui-v4-upload-drag .upload-drag-container .upload-drag-icon {\n line-height: 0;\n}\n.paraui-v4-upload-drag .upload-drag-container .upload-drag-icon svg {\n font-size: 48px;\n color: rgb(46, 101, 230);\n}\n.paraui-v4-upload-drag .upload-drag-container .upload-drag-icon .upload-drag-loading {\n animation: uploadLoadingCircle 1s infinite linear;\n}\n.paraui-v4-upload-drag .upload-drag-container .upload-drag-text {\n margin:
|
|
1667
|
+
var css_248z = "@charset \"UTF-8\";\n/**\n* @author Hanz\n* @date 2021/11/11 下午1:40\n* @description\n*/\n/**\n* @author linhd\n* @date 2023/4/11 14:16\n* @description 最新色卡\n*/\n.paraui-v4-upload .component-upload {\n position: relative;\n display: inline-block;\n}\n.paraui-v4-upload-loading {\n pointer-events: none;\n}\n.paraui-v4-upload-drag {\n position: relative;\n}\n.paraui-v4-upload-drag-loading {\n pointer-events: none;\n}\n.paraui-v4-upload-drag-hover .upload-drag-container {\n border-color: rgb(87, 131, 235);\n}\n.paraui-v4-upload-drag .upload-drag-container {\n display: inline-flex;\n width: 100%;\n height: 200px;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n font-size: 14px;\n line-height: 1;\n border: 1px dashed rgb(212, 218, 227);\n background-color: rgb(247, 248, 250);\n border-radius: 4px;\n cursor: pointer;\n transition: 0.3s;\n}\n.paraui-v4-upload-drag .upload-drag-container:hover {\n border-color: rgb(87, 131, 235);\n}\n.paraui-v4-upload-drag .upload-drag-container:hover .upload-drag-text {\n color: rgb(46, 101, 230);\n}\n.paraui-v4-upload-drag .upload-drag-container .upload-drag-icon {\n line-height: 0;\n margin-bottom: 16px;\n}\n.paraui-v4-upload-drag .upload-drag-container .upload-drag-icon svg {\n font-size: 48px;\n color: rgb(46, 101, 230);\n}\n.paraui-v4-upload-drag .upload-drag-container .upload-drag-icon .upload-drag-loading {\n animation: uploadLoadingCircle 1s infinite linear;\n}\n.paraui-v4-upload-drag .upload-drag-container .upload-drag-text {\n margin: 0 0 10px 0;\n color: rgb(29, 33, 38);\n padding: 0 20px;\n}\n.paraui-v4-upload-drag .upload-drag-container .upload-drag-text-loading {\n color: rgb(46, 101, 230);\n}\n.paraui-v4-upload-drag .upload-drag-container .upload-drag-text-filename {\n margin-right: 5px;\n color: rgb(29, 33, 38);\n word-break: break-all;\n}\n.paraui-v4-upload-drag .upload-drag-container .upload-drag-hint {\n color: rgb(92, 101, 115);\n padding: 0 20px;\n text-align: center;\n white-space: pre-wrap;\n line-height: 21px;\n}\n.paraui-v4-upload-drag .component-upload {\n display: block;\n max-width: 590px;\n}\n.paraui-v4-upload-drag .component-upload-disabled {\n color: rgb(92, 101, 115);\n cursor: not-allowed;\n}\n.paraui-v4-upload-drag .component-upload-disabled > div {\n width: 100%;\n}\n.paraui-v4-upload-drag .component-upload-disabled .upload-drag-container {\n cursor: not-allowed;\n}\n.paraui-v4-upload-drag .component-upload-disabled .upload-drag-container:hover {\n border-color: rgb(212, 218, 227);\n}\n.paraui-v4-upload-drag .component-upload-disabled .upload-drag-container .upload-drag-icon svg {\n color: rgb(161, 168, 179);\n}\n.paraui-v4-upload-drag .component-upload-disabled .upload-drag-container .upload-drag-text {\n color: rgb(92, 101, 115);\n}\n@keyframes uploadLoadingCircle {\n 100% {\n transform: rotate(360deg);\n }\n}";
|
|
1667
1668
|
styleInject(css_248z);
|
|
1668
1669
|
|
|
1669
1670
|
//upload
|
|
@@ -1698,9 +1699,10 @@ const InternalUpload = props => {
|
|
|
1698
1699
|
actionRender,
|
|
1699
1700
|
onPreview,
|
|
1700
1701
|
removeErrorTip,
|
|
1701
|
-
defaultFile
|
|
1702
|
+
defaultFile,
|
|
1703
|
+
height
|
|
1702
1704
|
} = props,
|
|
1703
|
-
restProps = __rest(props, ["type", "className", "style", "onStart", "onSuccess", "onError", "onProgress", "onRemove", "beforeUpload", "onChange", "onDrop", "defaultFileList", "fileList", "showUploadList", "maxCount", "children", "itemRender", "showUploadError", "size", "stash", "uploading", "showLoading", "loading", "dragArea", "disabledTooltip", "operateBtnProps", "actionRender", "onPreview", "removeErrorTip", "defaultFile"]);
|
|
1705
|
+
restProps = __rest(props, ["type", "className", "style", "onStart", "onSuccess", "onError", "onProgress", "onRemove", "beforeUpload", "onChange", "onDrop", "defaultFileList", "fileList", "showUploadList", "maxCount", "children", "itemRender", "showUploadError", "size", "stash", "uploading", "showLoading", "loading", "dragArea", "disabledTooltip", "operateBtnProps", "actionRender", "onPreview", "removeErrorTip", "defaultFile", "height"]);
|
|
1704
1706
|
const intl = useFormatMessage('Upload', localeJson);
|
|
1705
1707
|
const [uploadFileList, setUploadFileList] = useState(composeDefaultFileList(defaultFileList, defaultFile)); //文件列表
|
|
1706
1708
|
const [showLoading, setShowLoading] = useState(false); //upload loading
|
|
@@ -1909,6 +1911,9 @@ const InternalUpload = props => {
|
|
|
1909
1911
|
areaText = text,
|
|
1910
1912
|
areaDesc = hint
|
|
1911
1913
|
} = dragArea !== null && dragArea !== void 0 ? dragArea : {};
|
|
1914
|
+
console.log('areaIcon', areaIcon);
|
|
1915
|
+
console.log('areaText', areaText);
|
|
1916
|
+
console.log('areaDesc', areaDesc);
|
|
1912
1917
|
if (showLoading) {
|
|
1913
1918
|
areaIcon = jsx(LoadingIcon, {
|
|
1914
1919
|
className: 'upload-drag-loading'
|
|
@@ -1927,15 +1932,15 @@ const InternalUpload = props => {
|
|
|
1927
1932
|
}
|
|
1928
1933
|
const dragNode = jsx(Fragment, {
|
|
1929
1934
|
children: children ? children : jsxs(Fragment, {
|
|
1930
|
-
children: [jsx("p", Object.assign({
|
|
1935
|
+
children: [areaIcon && jsx("p", Object.assign({
|
|
1931
1936
|
className: "upload-drag-icon"
|
|
1932
1937
|
}, {
|
|
1933
1938
|
children: areaIcon
|
|
1934
|
-
})), jsx("p", Object.assign({
|
|
1939
|
+
})), areaText && jsx("p", Object.assign({
|
|
1935
1940
|
className: 'upload-drag-text'
|
|
1936
1941
|
}, {
|
|
1937
1942
|
children: areaText
|
|
1938
|
-
})), !showLoading && jsx("p", Object.assign({
|
|
1943
|
+
})), !showLoading && areaDesc && jsx("p", Object.assign({
|
|
1939
1944
|
className: "upload-drag-hint"
|
|
1940
1945
|
}, {
|
|
1941
1946
|
children: areaDesc
|
|
@@ -1948,12 +1953,18 @@ const InternalUpload = props => {
|
|
|
1948
1953
|
disabled: true
|
|
1949
1954
|
}, {
|
|
1950
1955
|
children: jsx("div", Object.assign({
|
|
1956
|
+
style: {
|
|
1957
|
+
height
|
|
1958
|
+
},
|
|
1951
1959
|
className: 'upload-drag-container'
|
|
1952
1960
|
}, {
|
|
1953
1961
|
children: dragNode
|
|
1954
1962
|
}))
|
|
1955
1963
|
}));
|
|
1956
1964
|
return jsx("div", Object.assign({
|
|
1965
|
+
style: {
|
|
1966
|
+
height
|
|
1967
|
+
},
|
|
1957
1968
|
className: 'upload-drag-container'
|
|
1958
1969
|
}, {
|
|
1959
1970
|
children: dragNode
|
package/Upload/interface.d.ts
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { _ as _slicedToArray } from './slicedToArray-75fa4188.js';
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import { createPortal } from 'react-dom';
|
|
4
|
-
import {
|
|
4
|
+
import { _ as _typeof } from './typeof-adeedc13.js';
|
|
5
5
|
import { _ as _toConsumableArray } from './toConsumableArray-c7a8028f.js';
|
|
6
|
+
import { _ as _defineProperty } from './defineProperty-6f62bb2a.js';
|
|
6
7
|
|
|
7
8
|
function _extends() {
|
|
8
9
|
_extends = Object.assign ? Object.assign.bind() : function (target) {
|
|
@@ -1,12 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
"@babel/helpers - typeof";
|
|
3
|
-
|
|
4
|
-
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {
|
|
5
|
-
return typeof o;
|
|
6
|
-
} : function (o) {
|
|
7
|
-
return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
|
|
8
|
-
}, _typeof(o);
|
|
9
|
-
}
|
|
1
|
+
import { _ as _typeof } from './typeof-adeedc13.js';
|
|
10
2
|
|
|
11
3
|
function toPrimitive(t, r) {
|
|
12
4
|
if ("object" != _typeof(t) || !t) return t;
|
|
@@ -39,4 +31,4 @@ function _defineProperty(obj, key, value) {
|
|
|
39
31
|
return obj;
|
|
40
32
|
}
|
|
41
33
|
|
|
42
|
-
export {
|
|
34
|
+
export { _defineProperty as _, toPropertyKey as t };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { _ as _toConsumableArray } from './toConsumableArray-c7a8028f.js';
|
|
2
|
-
import { _ as
|
|
2
|
+
import { _ as _defineProperty } from './defineProperty-6f62bb2a.js';
|
|
3
3
|
import { _ as _slicedToArray } from './slicedToArray-75fa4188.js';
|
|
4
4
|
import { r as regenerator } from './index-8ac46bd9.js';
|
|
5
5
|
import { _ as __rest, a as __awaiter } from './tslib.es6-55ed4bd2.js';
|
|
@@ -7,6 +7,7 @@ import { jsx, Fragment, jsxs } from 'react/jsx-runtime';
|
|
|
7
7
|
import React__default, { isValidElement, cloneElement, useRef, useState, useImperativeHandle, useEffect, useMemo } from 'react';
|
|
8
8
|
import RcTree from 'rc-tree';
|
|
9
9
|
import clsx from 'clsx';
|
|
10
|
+
import { _ as _typeof } from './typeof-adeedc13.js';
|
|
10
11
|
import LoadingOutlined from '@para-ui/icons/LoadingF';
|
|
11
12
|
import FileOutlined from '@para-ui/icons/Document';
|
|
12
13
|
import SolidArrowDown from '@para-ui/icons/DownTriangleF';
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { _ as __rest } from './tslib.es6-55ed4bd2.js';
|
|
2
2
|
import { jsx, Fragment, jsxs } from 'react/jsx-runtime';
|
|
3
|
-
import { c as clsx, _ as _objectSpread2, r as reactIs, s as supportRef, u as useComposeRef, w as warning, a as _extends, b as _objectWithoutProperties, d as wrapperRaf, e as useEvent$2, f as useLayoutEffect$3, g as composeRef, K as KeyCode, h as fillRef, P as Portal, i as warningOnce, j as useMergedState$2, k as canUseDom$1, l as useMemo$1, n as noteOnce } from './Portal-
|
|
3
|
+
import { c as clsx, _ as _objectSpread2, r as reactIs, s as supportRef, u as useComposeRef, w as warning, a as _extends, b as _objectWithoutProperties, d as wrapperRaf, e as useEvent$2, f as useLayoutEffect$3, g as composeRef, K as KeyCode, h as fillRef, P as Portal, i as warningOnce, j as useMergedState$2, k as canUseDom$1, l as useMemo$1, n as noteOnce } from './Portal-f9bedb3a.js';
|
|
4
4
|
import { _ as _toConsumableArray, a as _iterableToArray } from './toConsumableArray-c7a8028f.js';
|
|
5
|
-
import {
|
|
5
|
+
import { t as toPropertyKey, _ as _defineProperty } from './defineProperty-6f62bb2a.js';
|
|
6
6
|
import { _ as _slicedToArray, a as _arrayWithHoles, b as _unsupportedIterableToArray, c as _nonIterableRest } from './slicedToArray-75fa4188.js';
|
|
7
|
+
import { _ as _typeof$1 } from './typeof-adeedc13.js';
|
|
7
8
|
import * as React$4 from 'react';
|
|
8
9
|
import React__default, { useState as useState$1, useMemo, useCallback, useRef, useEffect } from 'react';
|
|
9
10
|
import ReactDOM, { unstable_batchedUpdates, flushSync } from 'react-dom';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
function _typeof(o) {
|
|
2
|
+
"@babel/helpers - typeof";
|
|
3
|
+
|
|
4
|
+
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {
|
|
5
|
+
return typeof o;
|
|
6
|
+
} : function (o) {
|
|
7
|
+
return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
|
|
8
|
+
}, _typeof(o);
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export { _typeof as _ };
|
package/index.js
CHANGED
|
@@ -10,7 +10,7 @@ export { Button } from './Button/index.js';
|
|
|
10
10
|
export { ButtonGroup } from './ButtonGroup/index.js';
|
|
11
11
|
export { Card } from './Card/index.js';
|
|
12
12
|
export { Carousel } from './Carousel/index.js';
|
|
13
|
-
export { C as Cascader } from './_verture/index-
|
|
13
|
+
export { C as Cascader } from './_verture/index-972707a5.js';
|
|
14
14
|
export { Checkbox } from './Checkbox/index.js';
|
|
15
15
|
export { CheckboxGroup } from './CheckboxGroup/index.js';
|
|
16
16
|
export { default as CodeEditor, CompletionItemKind } from './CodeEditor/index.js';
|
|
@@ -32,7 +32,7 @@ export { D as Dropdown } from './_verture/index-bde7aabe.js';
|
|
|
32
32
|
export { default as DynamicMultiBox } from './DynamicMultiBox/index.js';
|
|
33
33
|
export { default as Empty } from './Empty/index.js';
|
|
34
34
|
export { default as Form } from './Form/index.js';
|
|
35
|
-
export { F as FormItem } from './_verture/index-
|
|
35
|
+
export { F as FormItem } from './_verture/index-bd0da612.js';
|
|
36
36
|
export { u as FunctionModal, F as FunctionModalProvider, a as useClose } from './_verture/modalContext-8a48c400.js';
|
|
37
37
|
export { G as GlobalContext, c as changeConfirmLocale, g as getConfirmLocale } from './_verture/index-ca413216.js';
|
|
38
38
|
export { default as Help } from './Help/index.js';
|
|
@@ -87,7 +87,7 @@ export { Title } from './Title/index.js';
|
|
|
87
87
|
export { ToggleButton, ToggleButtonGroup } from './ToggleButton/index.js';
|
|
88
88
|
export { Tooltip } from './Tooltip/index.js';
|
|
89
89
|
export { SSortablejs, Transfer } from './Transfer/index.js';
|
|
90
|
-
export { T as Tree } from './_verture/index-
|
|
90
|
+
export { T as Tree } from './_verture/index-6647cbf6.js';
|
|
91
91
|
export { default as Upload } from './Upload/index.js';
|
|
92
92
|
export { default as Utils, getDateYYYYMMddHHMM, isObject, pixelReplacement } from './Utils/index.js';
|
|
93
93
|
export { default as locale } from './locale/index.js';
|
|
@@ -114,10 +114,11 @@ import '@para-ui/icons/LoadingF';
|
|
|
114
114
|
import 'react-slick';
|
|
115
115
|
import '@para-ui/icons/RightCircleF';
|
|
116
116
|
import '@para-ui/icons/LeftCircleF';
|
|
117
|
-
import './_verture/Portal-
|
|
117
|
+
import './_verture/Portal-f9bedb3a.js';
|
|
118
118
|
import './_verture/slicedToArray-75fa4188.js';
|
|
119
|
-
import './_verture/
|
|
119
|
+
import './_verture/typeof-adeedc13.js';
|
|
120
120
|
import './_verture/toConsumableArray-c7a8028f.js';
|
|
121
|
+
import './_verture/defineProperty-6f62bb2a.js';
|
|
121
122
|
import 'rc-motion';
|
|
122
123
|
import './_verture/typeof-6ec38efd.js';
|
|
123
124
|
import 'rc-tree/lib/utils/conductUtil';
|