@@ -14,16 +14,16 @@ export interface UploadProps
14
14
action ?: Action ;
15
15
method ?: UploadRequestMethod ;
16
16
directory ?: boolean ;
17
- data ?: object | ( ( file : RcFile | string | Blob ) => object ) ;
17
+ data ?: Record < string , unknown > | ( ( file : RcFile | string | Blob ) => Record < string , unknown > ) ;
18
18
headers ?: UploadRequestHeader ;
19
19
accept ?: string ;
20
20
multiple ?: boolean ;
21
21
onBatchStart ?: (
22
22
fileList : { file : RcFile ; parsedFile : Exclude < BeforeUploadFileType , boolean > } [ ] ,
23
23
) => void ;
24
24
onStart ?: ( file : RcFile ) => void ;
25
- onError ?: ( error : Error , ret : object , file : RcFile ) => void ;
26
- onSuccess ?: ( response : object , file : RcFile , xhr : object ) => void ;
25
+ onError ?: ( error : Error , ret : Record < string , unknown > , file : RcFile ) => void ;
26
+ onSuccess ?: ( response : Record < string , unknown > , file : RcFile , xhr : XMLHttpRequest ) => void ;
27
27
onProgress ?: ( event : UploadProgressEvent , file : RcFile ) => void ;
28
28
beforeUpload ?: (
29
29
file : RcFile ,
@@ -57,7 +57,7 @@ export interface UploadRequestOption<T = any> {
57
57
onProgress ?: ( event : UploadProgressEvent ) => void ;
58
58
onError ?: ( event : UploadRequestError | ProgressEvent , body ?: T ) => void ;
59
59
onSuccess ?: ( body : T , xhr ?: XMLHttpRequest ) => void ;
60
- data ?: object ;
60
+ data ?: Record < string , unknown > ;
61
61
filename ?: string ;
62
62
file : Exclude < BeforeUploadFileType , File | boolean > | RcFile ;
63
63
withCredentials ?: boolean ;
0 commit comments