ados-rcm 1.1.389 → 1.1.391
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/AModule/AComponents/AFileUploder/AFileUploader.d.ts +11 -14
- package/dist/index.cjs.js +53 -53
- package/dist/index.es.js +893 -906
- package/package.json +1 -1
@@ -4,21 +4,18 @@ import { Resources } from '../AResource/AResource';
|
|
4
4
|
import { IAWrapProps } from '../AWrap/AWrap';
|
5
5
|
export type TFileUploaderType = 'Upload' | 'Download';
|
6
6
|
export type TFileStatus = 'Normal' | 'Error' | 'Loading';
|
7
|
-
export interface
|
8
|
-
|
9
|
-
|
10
|
-
lastModified?: number;
|
11
|
-
type?: string;
|
12
|
-
webkitRelativePath?: string;
|
7
|
+
export interface ExtendedFile extends File {
|
8
|
+
idx?: number;
|
9
|
+
state?: number;
|
13
10
|
[key: string]: any;
|
14
11
|
}
|
15
12
|
export interface IAFileUploaderProps extends IAWrapProps, IABaseProps {
|
16
13
|
/**
|
17
|
-
* useFiles : TUseValues<
|
14
|
+
* useFiles : TUseValues<ExtendedFile[] | undefined>
|
18
15
|
*
|
19
16
|
* Description : useFiles of AFileUploader
|
20
17
|
*/
|
21
|
-
useFiles: TUseValues<
|
18
|
+
useFiles: TUseValues<ExtendedFile[] | undefined>;
|
22
19
|
/**
|
23
20
|
* accept? : string
|
24
21
|
*
|
@@ -32,26 +29,26 @@ export interface IAFileUploaderProps extends IAWrapProps, IABaseProps {
|
|
32
29
|
*/
|
33
30
|
onInvalidFileFormat?: () => void;
|
34
31
|
/**
|
35
|
-
* onDownload? : (file:
|
32
|
+
* onDownload? : (file: ExtendedFile, updateStatus: (status: TFileStatus) => void) => void
|
36
33
|
*
|
37
34
|
* Description : callback function when download button is clicked
|
38
35
|
* @param file The file to download
|
39
36
|
* @param updateStatus A function to update the status of the file (Loading, Error, Normal)
|
40
37
|
*/
|
41
|
-
onDownload?: (file:
|
38
|
+
onDownload?: (file: ExtendedFile, updateStatus: (status: TFileStatus) => void) => void;
|
42
39
|
/**
|
43
|
-
* onDownloads? : (files:
|
40
|
+
* onDownloads? : (files: ExtendedFile[]) => void
|
44
41
|
*
|
45
42
|
* Description : callback function when download all button is clicked
|
46
43
|
* @param files All files to download
|
47
44
|
*/
|
48
|
-
onDownloads?: (files:
|
45
|
+
onDownloads?: (files: ExtendedFile[]) => void;
|
49
46
|
/**
|
50
|
-
* onDelete? : (file:
|
47
|
+
* onDelete? : (file: ExtendedFile) => void
|
51
48
|
*
|
52
49
|
* Description : callback function when delete button is clicked
|
53
50
|
*/
|
54
|
-
onDelete?: (file:
|
51
|
+
onDelete?: (file: ExtendedFile) => void;
|
55
52
|
/**
|
56
53
|
* type : TFileUploaderType
|
57
54
|
*
|