@progress/kendo-angular-upload 19.1.2-develop.1 → 19.1.2-develop.3
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/common/action-buttons-layout.d.ts +1 -1
- package/common/base.d.ts +15 -11
- package/directives.d.ts +3 -3
- package/dropzone-external.directive.d.ts +12 -4
- package/dropzone.component.d.ts +16 -9
- package/esm2022/common/base.mjs +15 -11
- package/esm2022/directives.mjs +3 -3
- package/esm2022/dropzone-external.directive.mjs +12 -4
- package/esm2022/dropzone.component.mjs +16 -9
- package/esm2022/events/cancel-event.mjs +7 -16
- package/esm2022/events/clear-event.mjs +5 -12
- package/esm2022/events/error-event.mjs +7 -13
- package/esm2022/events/pause-event.mjs +5 -12
- package/esm2022/events/remove-event.mjs +8 -12
- package/esm2022/events/resume-event.mjs +5 -12
- package/esm2022/events/select-event.mjs +5 -11
- package/esm2022/events/success-event.mjs +6 -12
- package/esm2022/events/upload-event.mjs +7 -34
- package/esm2022/events/upload-progress-event.mjs +5 -11
- package/esm2022/fileselect.component.mjs +16 -6
- package/esm2022/localization/messages.mjs +42 -0
- package/esm2022/package-metadata.mjs +2 -2
- package/esm2022/templates/file-info-template.directive.mjs +5 -6
- package/esm2022/templates/file-template.directive.mjs +5 -6
- package/esm2022/types/file-state.mjs +5 -5
- package/esm2022/upload.component.mjs +73 -56
- package/events/cancel-event.d.ts +7 -16
- package/events/clear-event.d.ts +5 -12
- package/events/error-event.d.ts +7 -13
- package/events/pause-event.d.ts +5 -12
- package/events/remove-event.d.ts +8 -12
- package/events/resume-event.d.ts +5 -12
- package/events/select-event.d.ts +5 -11
- package/events/success-event.d.ts +6 -12
- package/events/upload-event.d.ts +7 -34
- package/events/upload-progress-event.d.ts +5 -11
- package/fesm2022/progress-kendo-angular-upload.mjs +254 -253
- package/fileselect.component.d.ts +14 -4
- package/localization/messages.d.ts +42 -0
- package/package.json +8 -8
- package/schematics/ngAdd/index.js +3 -3
- package/templates/file-info-template.directive.d.ts +5 -6
- package/templates/file-template.directive.d.ts +5 -6
- package/types/chunk-metadata.d.ts +3 -3
- package/types/chunk-settings.d.ts +4 -4
- package/types/file-restrictions.d.ts +4 -5
- package/types/file-state.d.ts +5 -5
- package/types/operation-type.d.ts +1 -1
- package/upload.component.d.ts +71 -54
@@ -15,6 +15,14 @@ import * as i0 from "@angular/core";
|
|
15
15
|
* @hidden
|
16
16
|
*/
|
17
17
|
export declare const FILESELECT_VALUE_ACCESSOR: any;
|
18
|
+
/**
|
19
|
+
* Represents the [Kendo UI FileSelect component for Angular](slug:overview_fileselect_uploads).
|
20
|
+
*
|
21
|
+
* @example
|
22
|
+
* ```html
|
23
|
+
* <kendo-fileselect> </kendo-fileselect>
|
24
|
+
* ```
|
25
|
+
*/
|
18
26
|
export declare class FileSelectComponent extends UploadFileSelectBase implements OnInit, OnDestroy {
|
19
27
|
protected uploadService: UploadService;
|
20
28
|
private localization;
|
@@ -27,12 +35,12 @@ export declare class FileSelectComponent extends UploadFileSelectBase implements
|
|
27
35
|
fileSelectInput: ElementRef;
|
28
36
|
get dir(): string;
|
29
37
|
/**
|
30
|
-
*
|
38
|
+
* Specifies the `name` attribute of the `input` element of the FileSelect.
|
31
39
|
*/
|
32
40
|
set name(name: string);
|
33
41
|
get name(): string;
|
34
42
|
/**
|
35
|
-
* Fires when the
|
43
|
+
* Fires when the component value changes after a successful `select` or `remove` operation.
|
36
44
|
*/
|
37
45
|
valueChange: EventEmitter<Array<File>>;
|
38
46
|
/**
|
@@ -56,11 +64,13 @@ export declare class FileSelectComponent extends UploadFileSelectBase implements
|
|
56
64
|
textFor(key: string): string;
|
57
65
|
ngOnDestroy(): void;
|
58
66
|
/**
|
59
|
-
* Removes specific file from the file list.
|
67
|
+
* Removes a specific file from the file list.
|
68
|
+
*
|
69
|
+
* @param uid The `uid` of the file to be removed.
|
60
70
|
*/
|
61
71
|
removeFileByUid(uid: string): void;
|
62
72
|
/**
|
63
|
-
*
|
73
|
+
* Clears all files from the UI.
|
64
74
|
*/
|
65
75
|
clearFiles(): void;
|
66
76
|
/**
|
@@ -10,86 +10,128 @@ import * as i0 from "@angular/core";
|
|
10
10
|
export declare class Messages extends ComponentMessages {
|
11
11
|
/**
|
12
12
|
* Sets the text for the **Cancel** button.
|
13
|
+
*
|
14
|
+
* @default 'Cancel'
|
13
15
|
*/
|
14
16
|
cancel: string;
|
15
17
|
/**
|
16
18
|
* Sets the text for the **Clear** button.
|
19
|
+
*
|
20
|
+
* @default 'Clear'
|
17
21
|
*/
|
18
22
|
clearSelectedFiles: string;
|
19
23
|
/**
|
20
24
|
* Sets the drop-zone hint.
|
25
|
+
*
|
26
|
+
* @default 'Drop files here to upload'
|
21
27
|
*/
|
22
28
|
dropFilesHere: string;
|
23
29
|
/**
|
24
30
|
* Sets the external drop-zone hint.
|
31
|
+
*
|
32
|
+
* @default 'Drag and drop files here to upload'
|
25
33
|
*/
|
26
34
|
externalDropFilesHere: string;
|
27
35
|
/**
|
28
36
|
* Sets the status message for a batch of files.
|
37
|
+
*
|
38
|
+
* @default 'files'
|
29
39
|
*/
|
30
40
|
filesBatchStatus: string;
|
31
41
|
/**
|
32
42
|
* Sets the status message for a batch of files after failed upload.
|
43
|
+
*
|
44
|
+
* @default 'files failed to upload.'
|
33
45
|
*/
|
34
46
|
filesBatchStatusFailed: string;
|
35
47
|
/**
|
36
48
|
* Sets the status message for a batch of files after successful upload.
|
49
|
+
*
|
50
|
+
* @default 'files successfully uploaded.'
|
37
51
|
*/
|
38
52
|
filesBatchStatusUploaded: string;
|
39
53
|
/**
|
40
54
|
* Sets the file status message after failed upload.
|
55
|
+
*
|
56
|
+
* @default 'File failed to upload.'
|
41
57
|
*/
|
42
58
|
fileStatusFailed: string;
|
43
59
|
/**
|
44
60
|
* Sets the file status message after successful upload.
|
61
|
+
*
|
62
|
+
* @default 'File successfully uploaded.'
|
45
63
|
*/
|
46
64
|
fileStatusUploaded: string;
|
47
65
|
/**
|
48
66
|
* Sets the header status message when the file upload is paused.
|
67
|
+
*
|
68
|
+
* @default 'Paused'
|
49
69
|
*/
|
50
70
|
headerStatusPaused: string;
|
51
71
|
/**
|
52
72
|
* Sets the header status message after the file upload completes.
|
73
|
+
*
|
74
|
+
* @default 'Done'
|
53
75
|
*/
|
54
76
|
headerStatusUploaded: string;
|
55
77
|
/**
|
56
78
|
* Sets the header status message during the upload of the file.
|
79
|
+
*
|
80
|
+
* @default 'Uploading...'
|
57
81
|
*/
|
58
82
|
headerStatusUploading: string;
|
59
83
|
/**
|
60
84
|
* Sets the text for the invalid `allowedExtensions` restriction message.
|
85
|
+
*
|
86
|
+
* @default 'File type not allowed.'
|
61
87
|
*/
|
62
88
|
invalidFileExtension: string;
|
63
89
|
/**
|
64
90
|
* Sets the text for the invalid `maxFileSize` restriction message.
|
91
|
+
*
|
92
|
+
* @default 'File size too large.'
|
65
93
|
*/
|
66
94
|
invalidMaxFileSize: string;
|
67
95
|
/**
|
68
96
|
* Sets the text for the invalid `minFileSize` restriction message.
|
97
|
+
*
|
98
|
+
* @default 'File size too small.'
|
69
99
|
*/
|
70
100
|
invalidMinFileSize: string;
|
71
101
|
/**
|
72
102
|
* Sets the text for the **Pause** button.
|
103
|
+
*
|
104
|
+
* @default 'Pause'
|
73
105
|
*/
|
74
106
|
pause: string;
|
75
107
|
/**
|
76
108
|
* Sets the text for the **Remove** button.
|
109
|
+
*
|
110
|
+
* @default 'Remove'
|
77
111
|
*/
|
78
112
|
remove: string;
|
79
113
|
/**
|
80
114
|
* Sets the text for the **Resume** button.
|
115
|
+
*
|
116
|
+
* @default 'Resume'
|
81
117
|
*/
|
82
118
|
resume: string;
|
83
119
|
/**
|
84
120
|
* Sets the text for the **Retry** button.
|
121
|
+
*
|
122
|
+
* @default 'Retry'
|
85
123
|
*/
|
86
124
|
retry: string;
|
87
125
|
/**
|
88
126
|
* Sets the text for the **Select** button.
|
127
|
+
*
|
128
|
+
* @default 'Select files...'
|
89
129
|
*/
|
90
130
|
select: string;
|
91
131
|
/**
|
92
132
|
* Sets the text for the **Upload files** button.
|
133
|
+
*
|
134
|
+
* @default 'Upload'
|
93
135
|
*/
|
94
136
|
uploadSelectedFiles: string;
|
95
137
|
static ɵfac: i0.ɵɵFactoryDeclaration<Messages, never>;
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@progress/kendo-angular-upload",
|
3
|
-
"version": "19.1.2-develop.
|
3
|
+
"version": "19.1.2-develop.3",
|
4
4
|
"description": "Kendo UI Angular Upload Component",
|
5
5
|
"license": "SEE LICENSE IN LICENSE.md",
|
6
6
|
"author": "Progress",
|
@@ -19,7 +19,7 @@
|
|
19
19
|
"package": {
|
20
20
|
"productName": "Kendo UI for Angular",
|
21
21
|
"productCode": "KENDOUIANGULAR",
|
22
|
-
"publishDate":
|
22
|
+
"publishDate": 1750152453,
|
23
23
|
"licensingDocsUrl": "https://www.telerik.com/kendo-angular-ui/my-license/"
|
24
24
|
}
|
25
25
|
},
|
@@ -30,16 +30,16 @@
|
|
30
30
|
"@angular/forms": "16 - 20",
|
31
31
|
"@angular/platform-browser": "16 - 20",
|
32
32
|
"@progress/kendo-licensing": "^1.5.0",
|
33
|
-
"@progress/kendo-angular-common": "19.1.2-develop.
|
34
|
-
"@progress/kendo-angular-l10n": "19.1.2-develop.
|
35
|
-
"@progress/kendo-angular-icons": "19.1.2-develop.
|
36
|
-
"@progress/kendo-angular-buttons": "19.1.2-develop.
|
37
|
-
"@progress/kendo-angular-progressbar": "19.1.2-develop.
|
33
|
+
"@progress/kendo-angular-common": "19.1.2-develop.3",
|
34
|
+
"@progress/kendo-angular-l10n": "19.1.2-develop.3",
|
35
|
+
"@progress/kendo-angular-icons": "19.1.2-develop.3",
|
36
|
+
"@progress/kendo-angular-buttons": "19.1.2-develop.3",
|
37
|
+
"@progress/kendo-angular-progressbar": "19.1.2-develop.3",
|
38
38
|
"rxjs": "^6.5.3 || ^7.0.0"
|
39
39
|
},
|
40
40
|
"dependencies": {
|
41
41
|
"tslib": "^2.3.1",
|
42
|
-
"@progress/kendo-angular-schematics": "19.1.2-develop.
|
42
|
+
"@progress/kendo-angular-schematics": "19.1.2-develop.3"
|
43
43
|
},
|
44
44
|
"schematics": "./schematics/collection.json",
|
45
45
|
"module": "fesm2022/progress-kendo-angular-upload.mjs",
|
@@ -10,9 +10,9 @@ function default_1(options) {
|
|
10
10
|
], peerDependencies: {
|
11
11
|
// peer dep of the icons
|
12
12
|
'@progress/kendo-svg-icons': '^4.0.0',
|
13
|
-
'@progress/kendo-angular-buttons': '19.1.2-develop.
|
14
|
-
'@progress/kendo-angular-progressbar': '19.1.2-develop.
|
15
|
-
'@progress/kendo-angular-popup': '19.1.2-develop.
|
13
|
+
'@progress/kendo-angular-buttons': '19.1.2-develop.3',
|
14
|
+
'@progress/kendo-angular-progressbar': '19.1.2-develop.3',
|
15
|
+
'@progress/kendo-angular-popup': '19.1.2-develop.3',
|
16
16
|
} });
|
17
17
|
return (0, schematics_1.externalSchematic)('@progress/kendo-angular-schematics', 'ng-add', finalOptions);
|
18
18
|
}
|
@@ -5,20 +5,19 @@
|
|
5
5
|
import { TemplateRef } from '@angular/core';
|
6
6
|
import * as i0 from "@angular/core";
|
7
7
|
/**
|
8
|
-
*
|
8
|
+
* Customizes the rendering of the file info section in the list. All other elements of the default template, such as file icon, action buttons, and upload progress, are preserved in place. ([See example](slug:templates_upload#toc-file-info-template)).
|
9
9
|
*
|
10
10
|
* The following context variables are available in the template:
|
11
11
|
*
|
12
|
-
* * `let-files`—
|
13
|
-
* * `let-state`—
|
14
|
-
* * `#myUpload="kendoUpload"` or `#myFileSelect="kendoFileSelect"`—
|
12
|
+
* * `let-files`—A reference to the files associated with the current item.
|
13
|
+
* * `let-state`—A reference to the current state of each file. If the [`batch`](slug:api_upload_uploadcomponent#toc-batch) option of the Upload is set to `true`, the field reflects the state of the whole batch.
|
14
|
+
* * `#myUpload="kendoUpload"` or `#myFileSelect="kendoFileSelect"`—A reference to the instance of the Upload/FileSelect component. It is exported as `kendoUpload`/`kendoFileSelect` by using the [`exportAs`](https://angular.io/api/core/Component) metadata property.
|
15
15
|
*
|
16
16
|
* @example
|
17
17
|
* ```html
|
18
|
-
* <kendo-upload #myUpload="kendoUpload"
|
18
|
+
* <kendo-upload #myUpload="kendoUpload">
|
19
19
|
* <ng-template kendoUploadFileInfoTemplate let-files let-state>
|
20
20
|
* <div>Name: {{ files[0].name }}</div>
|
21
|
-
* ...
|
22
21
|
* </ng-template>
|
23
22
|
* </kendo-upload>
|
24
23
|
* ```
|
@@ -5,20 +5,19 @@
|
|
5
5
|
import { TemplateRef } from '@angular/core';
|
6
6
|
import * as i0 from "@angular/core";
|
7
7
|
/**
|
8
|
-
*
|
8
|
+
* Customizes the rendering of files in the list. ([See example.](slug:templates_upload#toc-file-template))
|
9
9
|
*
|
10
10
|
* The following context variables are available in the template:
|
11
11
|
*
|
12
|
-
* * `let-files`—
|
13
|
-
* * `let-state`—
|
14
|
-
* * `#myUpload="kendoUpload"` or `#myFileSelect="kendoFileSelect"`—
|
12
|
+
* * `let-files`—A reference to the files associated with the current item.
|
13
|
+
* * `let-state`—A reference to the current state of each file. If the [`batch`](slug:api_upload_uploadcomponent#toc-batch) option of the Upload is set to `true`, the field reflects the state of the whole batch.
|
14
|
+
* * `#myUpload="kendoUpload"` or `#myFileSelect="kendoFileSelect"`—A reference to the instance of the Upload/FileSelect component. It is exported as `kendoUpload`/`kendoFileSelect` by using the [`exportAs`](https://angular.io/api/core/Component) metadata property.
|
15
15
|
*
|
16
16
|
* @example
|
17
17
|
* ```html
|
18
|
-
* <kendo-upload #myUpload="kendoUpload"
|
18
|
+
* <kendo-upload #myUpload="kendoUpload">
|
19
19
|
* <ng-template kendoUploadFileTemplate let-files let-state>
|
20
20
|
* <div>Name: {{ files[0].name }} Size: {{ files[0].size }} bytes</div>
|
21
|
-
* ...
|
22
21
|
* </ng-template>
|
23
22
|
* </kendo-upload>
|
24
23
|
* ```
|
@@ -3,8 +3,8 @@
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
5
5
|
/**
|
6
|
-
* Contains information
|
7
|
-
*
|
6
|
+
* Contains information related to the uploaded file.
|
7
|
+
* Use this metadata to process file chunks and merge them into a file on the back-end.
|
8
8
|
*/
|
9
9
|
export interface ChunkMetadata {
|
10
10
|
/**
|
@@ -28,7 +28,7 @@ export interface ChunkMetadata {
|
|
28
28
|
*/
|
29
29
|
chunkIndex: number;
|
30
30
|
/**
|
31
|
-
* The total number of chunks that the file is split
|
31
|
+
* The total number of chunks that the file is split into.
|
32
32
|
*/
|
33
33
|
totalChunks: number;
|
34
34
|
}
|
@@ -7,25 +7,25 @@
|
|
7
7
|
*/
|
8
8
|
export interface ChunkSettings {
|
9
9
|
/**
|
10
|
-
* The size of the chunks in bytes.
|
10
|
+
* The size of the chunks in bytes.
|
11
11
|
*
|
12
12
|
* @default 1048576
|
13
13
|
*/
|
14
14
|
size?: number;
|
15
15
|
/**
|
16
|
-
*
|
16
|
+
* The number of milliseconds to wait before retrying a failed chunk upload.
|
17
17
|
*
|
18
18
|
* @default 100
|
19
19
|
*/
|
20
20
|
autoRetryAfter?: number;
|
21
21
|
/**
|
22
|
-
*
|
22
|
+
* The number of attempts to retry uploading a failed chunk.
|
23
23
|
*
|
24
24
|
* @default 1
|
25
25
|
*/
|
26
26
|
maxAutoRetries?: number;
|
27
27
|
/**
|
28
|
-
*
|
28
|
+
* Specifies whether the file upload process can be paused and later resumed.
|
29
29
|
*
|
30
30
|
* @default true
|
31
31
|
*/
|
@@ -7,19 +7,18 @@
|
|
7
7
|
*/
|
8
8
|
export interface FileRestrictions {
|
9
9
|
/**
|
10
|
-
* The list of
|
10
|
+
* The list of allowed file extensions
|
11
11
|
* ([see example]({% slug filerestrictions_upload %}#toc-file-extension)).
|
12
|
-
*
|
13
|
-
* and `type` (for example, `docx`, `png`, `svg`, `xls`, and others) values.
|
12
|
+
* Accepts entries of both `.type` (for example, `.docx`, `.png`, `.svg`, `.xls`) and `type` (for example, `docx`, `png`, `svg`, `xls`) values.
|
14
13
|
*/
|
15
14
|
allowedExtensions?: Array<string>;
|
16
15
|
/**
|
17
|
-
*
|
16
|
+
* The maximum file size in bytes
|
18
17
|
* ([see example]({% slug filerestrictions_upload %}#toc-maximum-file-size)).
|
19
18
|
*/
|
20
19
|
maxFileSize?: number;
|
21
20
|
/**
|
22
|
-
*
|
21
|
+
* The minimum file size in bytes
|
23
22
|
* ([see example]({% slug filerestrictions_upload %}#toc-minimum-file-size)).
|
24
23
|
*/
|
25
24
|
minFileSize?: number;
|
package/types/file-state.d.ts
CHANGED
@@ -7,11 +7,11 @@
|
|
7
7
|
*/
|
8
8
|
export declare enum FileState {
|
9
9
|
/**
|
10
|
-
* The file upload process
|
10
|
+
* The file upload process failed.
|
11
11
|
*/
|
12
12
|
Failed = 0,
|
13
13
|
/**
|
14
|
-
* An initially selected
|
14
|
+
* An initially selected file without a set state.
|
15
15
|
*/
|
16
16
|
Initial = 1,
|
17
17
|
/**
|
@@ -19,15 +19,15 @@ export declare enum FileState {
|
|
19
19
|
*/
|
20
20
|
Selected = 2,
|
21
21
|
/**
|
22
|
-
* The file
|
22
|
+
* The file uploaded successfully.
|
23
23
|
*/
|
24
24
|
Uploaded = 3,
|
25
25
|
/**
|
26
|
-
* The file is
|
26
|
+
* The file is uploading.
|
27
27
|
*/
|
28
28
|
Uploading = 4,
|
29
29
|
/**
|
30
|
-
* The file upload process
|
30
|
+
* The file upload process is paused.
|
31
31
|
*/
|
32
32
|
Paused = 5
|
33
33
|
}
|
@@ -3,6 +3,6 @@
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
5
5
|
/**
|
6
|
-
*
|
6
|
+
* The operation (`upload` or `remove`) for which the `success` or `error` event is raised.
|
7
7
|
*/
|
8
8
|
export type OperationType = "upload" | "remove";
|