@qn-pandora/pandora-component 4.3.2 → 4.3.3
Sign up to get free protection for your applications and to get access to all the features.
- package/CHANGELOG.json +20 -0
- package/CHANGELOG.md +28 -45
- package/es/components/FileResumable/constants.d.ts +1 -0
- package/es/components/FileResumable/index.js +4 -2
- package/es/components/NameLimiter/index.d.ts +5 -4
- package/es/components/NameLimiter/index.js +2 -2
- package/es/index.css +2085 -2085
- package/es/index.less +14 -14
- package/lib/components/FileResumable/constants.d.ts +1 -0
- package/lib/components/FileResumable/index.js +4 -2
- package/lib/components/NameLimiter/index.d.ts +5 -4
- package/lib/components/NameLimiter/index.js +2 -2
- package/lib/index.css +6005 -6005
- package/lib/index.less +14 -14
- package/package.json +3 -3
package/CHANGELOG.json
CHANGED
@@ -1,6 +1,26 @@
|
|
1
1
|
{
|
2
2
|
"name": "@qn-pandora/pandora-component",
|
3
3
|
"entries": [
|
4
|
+
{
|
5
|
+
"version": "4.3.3",
|
6
|
+
"tag": "@qn-pandora/pandora-component_v4.3.3",
|
7
|
+
"date": "Tue, 28 Nov 2023 12:13:32 GMT",
|
8
|
+
"comments": {
|
9
|
+
"patch": [
|
10
|
+
{
|
11
|
+
"comment": "2023-11-28发包"
|
12
|
+
}
|
13
|
+
],
|
14
|
+
"dependency": [
|
15
|
+
{
|
16
|
+
"comment": "Updating dependency \"@qn-pandora/pandora-component-icons\" from `^3.3.1` to `^3.3.2`"
|
17
|
+
},
|
18
|
+
{
|
19
|
+
"comment": "Updating dependency \"@qn-pandora/app-sdk\" from `^3.3.2` to `^3.3.3`"
|
20
|
+
}
|
21
|
+
]
|
22
|
+
}
|
23
|
+
},
|
4
24
|
{
|
5
25
|
"version": "4.3.2",
|
6
26
|
"tag": "@qn-pandora/pandora-component_v4.3.2",
|
package/CHANGELOG.md
CHANGED
@@ -1,65 +1,64 @@
|
|
1
1
|
# Change Log - @qn-pandora/pandora-component
|
2
2
|
|
3
|
-
This log was last generated on
|
3
|
+
This log was last generated on Tue, 28 Nov 2023 12:13:32 GMT and should not be manually modified.
|
4
4
|
|
5
|
-
## 4.3.
|
5
|
+
## 4.3.3
|
6
|
+
Tue, 28 Nov 2023 12:13:32 GMT
|
7
|
+
|
8
|
+
### Patches
|
9
|
+
|
10
|
+
- 2023-11-28发包
|
6
11
|
|
12
|
+
## 4.3.2
|
7
13
|
Thu, 16 Nov 2023 11:14:33 GMT
|
8
14
|
|
9
15
|
### Patches
|
10
16
|
|
11
|
-
- 2023-11-16
|
17
|
+
- 2023-11-16发包
|
12
18
|
|
13
19
|
## 4.3.1
|
14
|
-
|
15
20
|
Mon, 30 Oct 2023 08:56:57 GMT
|
16
21
|
|
17
22
|
### Patches
|
18
23
|
|
19
|
-
- 2023-10-30
|
24
|
+
- 2023-10-30发包
|
20
25
|
|
21
26
|
## 4.3.0
|
22
|
-
|
23
27
|
Tue, 24 Oct 2023 08:06:30 GMT
|
24
28
|
|
25
29
|
### Minor changes
|
26
30
|
|
27
|
-
- 2023-10-24
|
31
|
+
- 2023-10-24发包
|
28
32
|
|
29
33
|
## 4.2.0
|
30
|
-
|
31
34
|
Mon, 25 Sep 2023 07:36:39 GMT
|
32
35
|
|
33
36
|
### Minor changes
|
34
37
|
|
35
|
-
- 2023-09-25
|
38
|
+
- 2023-09-25发包
|
36
39
|
|
37
40
|
## 4.1.6
|
38
|
-
|
39
41
|
Fri, 25 Aug 2023 10:29:46 GMT
|
40
42
|
|
41
43
|
### Patches
|
42
44
|
|
43
|
-
- 2023-08-25
|
45
|
+
- 2023-08-25发包
|
44
46
|
|
45
47
|
## 4.1.5
|
46
|
-
|
47
48
|
Fri, 25 Aug 2023 09:17:44 GMT
|
48
49
|
|
49
50
|
### Patches
|
50
51
|
|
51
|
-
- 2023-08-25
|
52
|
+
- 2023-08-25发包
|
52
53
|
|
53
54
|
## 4.1.4
|
54
|
-
|
55
55
|
Thu, 24 Aug 2023 09:24:03 GMT
|
56
56
|
|
57
57
|
### Patches
|
58
58
|
|
59
|
-
- 2023.08.24
|
59
|
+
- 2023.08.24发包
|
60
60
|
|
61
61
|
## 4.1.3
|
62
|
-
|
63
62
|
Wed, 26 Jul 2023 09:10:30 GMT
|
64
63
|
|
65
64
|
### Patches
|
@@ -67,63 +66,55 @@ Wed, 26 Jul 2023 09:10:30 GMT
|
|
67
66
|
- 2023.07.26 publish
|
68
67
|
|
69
68
|
## 4.1.2
|
70
|
-
|
71
69
|
Tue, 25 Jul 2023 09:47:47 GMT
|
72
70
|
|
73
71
|
### Patches
|
74
72
|
|
75
|
-
- 2023.07.25
|
73
|
+
- 2023.07.25发包
|
76
74
|
|
77
75
|
## 4.1.1
|
78
|
-
|
79
76
|
Thu, 20 Jul 2023 07:02:58 GMT
|
80
77
|
|
81
78
|
### Patches
|
82
79
|
|
83
|
-
- 2023.07.20
|
80
|
+
- 2023.07.20发包
|
84
81
|
|
85
82
|
## 4.1.0
|
86
|
-
|
87
83
|
Tue, 27 Jun 2023 06:38:00 GMT
|
88
84
|
|
89
85
|
### Minor changes
|
90
86
|
|
91
|
-
- 2023.06.27
|
87
|
+
- 2023.06.27发包
|
92
88
|
|
93
89
|
## 4.0.12
|
94
|
-
|
95
90
|
Mon, 29 May 2023 10:29:42 GMT
|
96
91
|
|
97
92
|
### Patches
|
98
93
|
|
99
|
-
- 2023.05.29
|
94
|
+
- 2023.05.29发包
|
100
95
|
|
101
96
|
## 4.0.11
|
102
|
-
|
103
97
|
Wed, 24 May 2023 07:19:25 GMT
|
104
98
|
|
105
99
|
### Patches
|
106
100
|
|
107
|
-
- 2023.05.24
|
101
|
+
- 2023.05.24发包
|
108
102
|
|
109
103
|
## 4.0.10
|
110
|
-
|
111
104
|
Tue, 23 May 2023 03:12:29 GMT
|
112
105
|
|
113
106
|
### Patches
|
114
107
|
|
115
|
-
- 2023.05.23
|
108
|
+
- 2023.05.23发布
|
116
109
|
|
117
110
|
## 4.0.9
|
118
|
-
|
119
111
|
Wed, 19 Apr 2023 03:15:25 GMT
|
120
112
|
|
121
113
|
### Patches
|
122
114
|
|
123
|
-
- 2023.04.19
|
115
|
+
- 2023.04.19发包
|
124
116
|
|
125
117
|
## 4.0.8
|
126
|
-
|
127
118
|
Tue, 04 Apr 2023 08:26:02 GMT
|
128
119
|
|
129
120
|
### Patches
|
@@ -131,23 +122,20 @@ Tue, 04 Apr 2023 08:26:02 GMT
|
|
131
122
|
- 2023.04.04
|
132
123
|
|
133
124
|
## 4.0.7
|
134
|
-
|
135
125
|
Thu, 23 Mar 2023 07:12:05 GMT
|
136
126
|
|
137
127
|
### Patches
|
138
128
|
|
139
|
-
- 2023.03.23
|
129
|
+
- 2023.03.23发布
|
140
130
|
|
141
131
|
## 4.0.6
|
142
|
-
|
143
132
|
Mon, 13 Mar 2023 11:30:17 GMT
|
144
133
|
|
145
134
|
### Patches
|
146
135
|
|
147
|
-
- 2023.03.13
|
136
|
+
- 2023.03.13发布
|
148
137
|
|
149
138
|
## 4.0.5
|
150
|
-
|
151
139
|
Wed, 15 Feb 2023 09:26:50 GMT
|
152
140
|
|
153
141
|
### Patches
|
@@ -155,7 +143,6 @@ Wed, 15 Feb 2023 09:26:50 GMT
|
|
155
143
|
- 2023.02.15 发布
|
156
144
|
|
157
145
|
## 4.0.4
|
158
|
-
|
159
146
|
Wed, 11 Jan 2023 08:25:05 GMT
|
160
147
|
|
161
148
|
### Patches
|
@@ -163,7 +150,6 @@ Wed, 11 Jan 2023 08:25:05 GMT
|
|
163
150
|
- 2023-01-11 发布
|
164
151
|
|
165
152
|
## 4.0.3
|
166
|
-
|
167
153
|
Tue, 10 Jan 2023 03:03:58 GMT
|
168
154
|
|
169
155
|
### Patches
|
@@ -171,23 +157,20 @@ Tue, 10 Jan 2023 03:03:58 GMT
|
|
171
157
|
- 2023-01-10 发布
|
172
158
|
|
173
159
|
## 4.0.2
|
174
|
-
|
175
160
|
Tue, 29 Nov 2022 03:37:07 GMT
|
176
161
|
|
177
162
|
### Patches
|
178
163
|
|
179
|
-
- 2022.11.29
|
164
|
+
- 2022.11.29发布
|
180
165
|
|
181
166
|
## 4.0.1
|
182
|
-
|
183
167
|
Mon, 17 Oct 2022 06:49:55 GMT
|
184
168
|
|
185
169
|
### Patches
|
186
170
|
|
187
|
-
- 22
|
171
|
+
- 22年10月16日发布
|
188
172
|
|
189
173
|
## 4.0.0
|
190
|
-
|
191
174
|
Tue, 14 Jun 2022 09:21:39 GMT
|
192
175
|
|
193
176
|
### Breaking changes
|
@@ -195,9 +178,9 @@ Tue, 14 Jun 2022 09:21:39 GMT
|
|
195
178
|
- 很久没发版了,统一发个大版本
|
196
179
|
|
197
180
|
## 3.0.0
|
198
|
-
|
199
181
|
Mon, 20 Dec 2021 11:46:43 GMT
|
200
182
|
|
201
183
|
### Breaking changes
|
202
184
|
|
203
|
-
- 仓库迁移至
|
185
|
+
- 仓库迁移至rush后统一发个大版本
|
186
|
+
|
@@ -261,7 +261,7 @@ export default function FileResumable(props) {
|
|
261
261
|
onError
|
262
262
|
]);
|
263
263
|
var handleStart = useCallback(function () { return __awaiter(_this, void 0, void 0, function () {
|
264
|
-
var params, realFile_1, reader;
|
264
|
+
var params, realFile_1, reader, extension_1;
|
265
265
|
var _this = this;
|
266
266
|
return __generator(this, function (_a) {
|
267
267
|
params = __assign({}, query);
|
@@ -271,6 +271,7 @@ export default function FileResumable(props) {
|
|
271
271
|
reader.readAsText(realFile_1.size > 50 * 1024 * 1024
|
272
272
|
? realFile_1.slice(0, 2 * 1024 * 1024)
|
273
273
|
: realFile_1);
|
274
|
+
extension_1 = realFile_1.name.split('.').pop().toLowerCase();
|
274
275
|
reader.onloadend = function (e) { return __awaiter(_this, void 0, void 0, function () {
|
275
276
|
var md5Str, id, fileId, error_1;
|
276
277
|
var _a, _b, _c;
|
@@ -286,7 +287,7 @@ export default function FileResumable(props) {
|
|
286
287
|
return [4 /*yield*/, fileIsExit({
|
287
288
|
resumableModifyTime: realFile_1.lastModified,
|
288
289
|
resumableFilename: realFile_1.name,
|
289
|
-
resumableType: realFile_1.type,
|
290
|
+
resumableType: realFile_1.type || "application/" + extension_1,
|
290
291
|
resumableFileMd5: md5Str,
|
291
292
|
resumableTotalSize: realFile_1.size
|
292
293
|
})];
|
@@ -303,6 +304,7 @@ export default function FileResumable(props) {
|
|
303
304
|
params.resumableFileMd5 = md5Str;
|
304
305
|
params.resumableModifyTime = realFile_1.lastModified;
|
305
306
|
params.resumableIdentifier = uuid();
|
307
|
+
params.resumableType = realFile_1.type || "application/" + extension_1;
|
306
308
|
(_a = resumable.current) === null || _a === void 0 ? void 0 : _a.updateQuery(params);
|
307
309
|
(_b = resumable.current) === null || _b === void 0 ? void 0 : _b.upload();
|
308
310
|
}
|
@@ -1,13 +1,14 @@
|
|
1
|
-
|
1
|
+
import React from 'react';
|
2
2
|
import type { TooltipPlacement } from 'antd/es/tooltip';
|
3
3
|
/**
|
4
4
|
* 对于超出容器宽度的名称进行省略,使用Tooltip展示。
|
5
5
|
*/
|
6
6
|
export interface INameLimiterProps {
|
7
7
|
/** 资源名称 */
|
8
|
-
name:
|
8
|
+
name: React.ReactNode;
|
9
9
|
/** 用于显示Tooltip的title */
|
10
|
-
title?:
|
10
|
+
title?: React.ReactNode;
|
11
11
|
placement?: TooltipPlacement;
|
12
|
+
getPopupContainer?: (triggerNode: HTMLElement) => HTMLElement;
|
12
13
|
}
|
13
|
-
export default function NameLimiter({ name, title, placement }: INameLimiterProps): JSX.Element;
|
14
|
+
export default function NameLimiter({ name, title, placement, getPopupContainer }: INameLimiterProps): JSX.Element;
|
@@ -18,7 +18,7 @@ import React, { useLayoutEffect, useRef, useState } from 'react';
|
|
18
18
|
import { Tooltip } from 'antd';
|
19
19
|
import { SDK_PREFIX } from '../../constants/style';
|
20
20
|
export default function NameLimiter(_a) {
|
21
|
-
var name = _a.name, title = _a.title, placement = _a.placement;
|
21
|
+
var name = _a.name, title = _a.title, placement = _a.placement, getPopupContainer = _a.getPopupContainer;
|
22
22
|
var _b = __read(useState(false), 2), ellipsis = _b[0], setEllipsis = _b[1];
|
23
23
|
var _c = __read(useState(false), 2), visible = _c[0], setVisible = _c[1];
|
24
24
|
var ref = useRef(null);
|
@@ -29,6 +29,6 @@ export default function NameLimiter(_a) {
|
|
29
29
|
}
|
30
30
|
setEllipsis(ref.current.clientWidth < ref.current.scrollWidth);
|
31
31
|
});
|
32
|
-
return (React.createElement(Tooltip, { overlayClassName: SDK_PREFIX + "-name-limit-tooltip", placement: placement || 'top', title: title || name, visible: (!!title || ellipsis) && visible, onVisibleChange: setVisible },
|
32
|
+
return (React.createElement(Tooltip, { getPopupContainer: getPopupContainer, overlayClassName: SDK_PREFIX + "-name-limit-tooltip", placement: placement || 'top', title: title || name, visible: (!!title || ellipsis) && visible, onVisibleChange: setVisible },
|
33
33
|
React.createElement("span", { className: SDK_PREFIX + "-name-limit", ref: ref }, name)));
|
34
34
|
}
|