@progress/kendo-angular-upload 17.0.0-develop.4 → 17.0.0-develop.41
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/README.md +36 -15
- package/common/action-buttons-layout.d.ts +1 -1
- package/common/base.d.ts +1 -1
- package/dropzone-external.directive.d.ts +1 -1
- package/dropzone-internal.directive.d.ts +1 -1
- package/dropzone.component.d.ts +1 -1
- package/{esm2020 → esm2022}/common/base.mjs +96 -67
- package/{esm2020 → esm2022}/dropzone-base.mjs +13 -9
- package/{esm2020 → esm2022}/dropzone-external.directive.mjs +16 -5
- package/{esm2020 → esm2022}/dropzone-internal.directive.mjs +14 -6
- package/{esm2020 → esm2022}/dropzone.component.mjs +38 -19
- package/{esm2020 → esm2022}/dropzone.service.mjs +3 -3
- package/{esm2020 → esm2022}/events/cancel-event.mjs +4 -0
- package/{esm2020 → esm2022}/events/error-event.mjs +12 -0
- package/{esm2020 → esm2022}/events/pause-event.mjs +4 -0
- package/{esm2020 → esm2022}/events/preventable-event.mjs +1 -3
- package/{esm2020 → esm2022}/events/remove-event.mjs +12 -0
- package/{esm2020 → esm2022}/events/resume-event.mjs +4 -0
- package/{esm2020 → esm2022}/events/select-event.mjs +4 -0
- package/{esm2020 → esm2022}/events/success-event.mjs +12 -0
- package/{esm2020 → esm2022}/events/upload-event.mjs +35 -0
- package/{esm2020 → esm2022}/events/upload-progress-event.mjs +8 -0
- package/{esm2020 → esm2022}/file-select.directive.mjs +17 -8
- package/{esm2020 → esm2022}/fileselect.component.mjs +61 -43
- package/{esm2020 → esm2022}/fileselect.module.mjs +8 -8
- package/{esm2020 → esm2022}/localization/custom-messages.component.mjs +12 -11
- package/{esm2020 → esm2022}/localization/localized-messages.directive.mjs +9 -8
- package/esm2022/localization/messages.mjs +143 -0
- package/{esm2020 → esm2022}/navigation.service.mjs +17 -14
- package/{esm2020 → esm2022}/package-metadata.mjs +2 -2
- package/{esm2020 → esm2022}/rendering/file-list-item-action-button.component.mjs +16 -10
- package/{esm2020 → esm2022}/rendering/file-list-item-base.mjs +7 -4
- package/{esm2020 → esm2022}/rendering/file-list-item.mjs +10 -5
- package/{esm2020 → esm2022}/rendering/file-list-multiple-items.component.mjs +18 -13
- package/{esm2020 → esm2022}/rendering/file-list-single-item.component.mjs +16 -12
- package/{esm2020 → esm2022}/rendering/file-list.component.mjs +14 -5
- package/{esm2020 → esm2022}/rendering/upload-action-buttons.component.mjs +17 -10
- package/{esm2020 → esm2022}/rendering/upload-status-total.component.mjs +14 -8
- package/{esm2020 → esm2022}/templates/file-info-template.directive.mjs +4 -3
- package/{esm2020 → esm2022}/templates/file-template.directive.mjs +4 -3
- package/{esm2020 → esm2022}/types/chunk-map.mjs +1 -0
- package/{esm2020 → esm2022}/types/file-map.mjs +1 -0
- package/{esm2020 → esm2022}/upload.component.mjs +114 -96
- package/{esm2020 → esm2022}/upload.module.mjs +8 -8
- package/{esm2020 → esm2022}/upload.service.mjs +50 -49
- package/{esm2020 → esm2022}/uploads.module.mjs +8 -8
- package/{fesm2020 → fesm2022}/progress-kendo-angular-upload.mjs +791 -443
- package/file-select.directive.d.ts +1 -1
- package/fileselect.component.d.ts +1 -1
- package/localization/messages.d.ts +1 -1
- package/package.json +16 -22
- package/rendering/file-list-item-action-button.component.d.ts +1 -1
- package/rendering/file-list-item.d.ts +1 -1
- package/rendering/file-list-multiple-items.component.d.ts +1 -1
- package/rendering/file-list-single-item.component.d.ts +1 -1
- package/rendering/file-list.component.d.ts +1 -1
- package/rendering/upload-action-buttons.component.d.ts +1 -1
- package/rendering/upload-status-total.component.d.ts +1 -1
- package/schematics/ngAdd/index.js +3 -3
- package/types/direction.d.ts +1 -1
- package/types/operation-type.d.ts +1 -1
- package/upload.component.d.ts +1 -1
- package/upload.service.d.ts +1 -1
- package/esm2020/localization/messages.mjs +0 -59
- package/fesm2015/progress-kendo-angular-upload.mjs +0 -4808
- /package/{esm2020 → esm2022}/common/action-buttons-layout.mjs +0 -0
- /package/{esm2020 → esm2022}/common/util.mjs +0 -0
- /package/{esm2020 → esm2022}/common/validation-util.mjs +0 -0
- /package/{esm2020 → esm2022}/directives.mjs +0 -0
- /package/{esm2020 → esm2022}/events/clear-event.mjs +0 -0
- /package/{esm2020 → esm2022}/events.mjs +0 -0
- /package/{esm2020 → esm2022}/index.mjs +0 -0
- /package/{esm2020 → esm2022}/progress-kendo-angular-upload.mjs +0 -0
- /package/{esm2020 → esm2022}/types/async-settings.mjs +0 -0
- /package/{esm2020 → esm2022}/types/chunk-info.mjs +0 -0
- /package/{esm2020 → esm2022}/types/chunk-metadata.mjs +0 -0
- /package/{esm2020 → esm2022}/types/chunk-settings.mjs +0 -0
- /package/{esm2020 → esm2022}/types/direction.mjs +0 -0
- /package/{esm2020 → esm2022}/types/file-groups.mjs +0 -0
- /package/{esm2020 → esm2022}/types/file-info.mjs +0 -0
- /package/{esm2020 → esm2022}/types/file-restrictions.mjs +0 -0
- /package/{esm2020 → esm2022}/types/file-state.mjs +0 -0
- /package/{esm2020 → esm2022}/types/operation-type.mjs +0 -0
- /package/{esm2020 → esm2022}/types.mjs +0 -0
|
@@ -45,83 +45,14 @@ let idx = 0;
|
|
|
45
45
|
* Represents the [Kendo UI Upload component for Angular]({% slug overview_upload %}).
|
|
46
46
|
*/
|
|
47
47
|
export class UploadComponent extends UploadFileSelectBase {
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
this.cdr = cdr;
|
|
57
|
-
this.injector = injector;
|
|
58
|
-
/**
|
|
59
|
-
* Enables the chunk functionality of the Upload.
|
|
60
|
-
*
|
|
61
|
-
* @default false
|
|
62
|
-
*/
|
|
63
|
-
this.chunkable = false;
|
|
64
|
-
/**
|
|
65
|
-
* Toggles the visibility of the file list.
|
|
66
|
-
* @default true
|
|
67
|
-
*/
|
|
68
|
-
this.showFileList = true;
|
|
69
|
-
/**
|
|
70
|
-
* Specifies the possible layout of the action buttons.
|
|
71
|
-
*/
|
|
72
|
-
this.actionsLayout = 'end';
|
|
73
|
-
/**
|
|
74
|
-
* Fires when the upload is canceled while in progress.
|
|
75
|
-
*/
|
|
76
|
-
this.cancel = new EventEmitter();
|
|
77
|
-
/**
|
|
78
|
-
* Fires when the file list is about to be cleared. If prevented, the files will not be cleared.
|
|
79
|
-
*/
|
|
80
|
-
this.clear = new EventEmitter();
|
|
81
|
-
/**
|
|
82
|
-
* Fires when all active uploads are completed either successfully or with errors.
|
|
83
|
-
*/
|
|
84
|
-
this.complete = new EventEmitter();
|
|
85
|
-
/**
|
|
86
|
-
* Fires when an `upload` or `remove` operation has failed.
|
|
87
|
-
*/
|
|
88
|
-
this.error = new EventEmitter();
|
|
89
|
-
/**
|
|
90
|
-
* Fires when the upload of a file has been paused.
|
|
91
|
-
*/
|
|
92
|
-
this.pause = new EventEmitter();
|
|
93
|
-
/**
|
|
94
|
-
* Fires when the upload of a file has been resumed.
|
|
95
|
-
*/
|
|
96
|
-
this.resume = new EventEmitter();
|
|
97
|
-
/**
|
|
98
|
-
* Fires when an `upload` or `remove` operation is successfully completed.
|
|
99
|
-
*/
|
|
100
|
-
this.success = new EventEmitter();
|
|
101
|
-
/**
|
|
102
|
-
* Fires when one or more files are about to be uploaded. If prevented, the files will neither be uploaded, nor added to the file list.
|
|
103
|
-
*/
|
|
104
|
-
this.upload = new EventEmitter();
|
|
105
|
-
/**
|
|
106
|
-
* Fires when one or more files are being uploaded.
|
|
107
|
-
*/
|
|
108
|
-
this.uploadProgress = new EventEmitter();
|
|
109
|
-
/**
|
|
110
|
-
* Fires when the value of the component has changed as a result of a successful `upload`, `remove` or `clear` operation.
|
|
111
|
-
*/
|
|
112
|
-
this.valueChange = new EventEmitter();
|
|
113
|
-
validatePackage(packageMetadata);
|
|
114
|
-
this.fileList = this.uploadService.files;
|
|
115
|
-
this.localizationChangeSubscription = localization.changes.subscribe(({ rtl }) => {
|
|
116
|
-
this.direction = rtl ? 'rtl' : 'ltr';
|
|
117
|
-
});
|
|
118
|
-
this.direction = localization.rtl ? 'rtl' : 'ltr';
|
|
119
|
-
this.navigation.computeKeys();
|
|
120
|
-
this.wrapper = wrapper.nativeElement;
|
|
121
|
-
this.subscribeBlur();
|
|
122
|
-
this.subscribeFocus();
|
|
123
|
-
this.attachEventHandlers();
|
|
124
|
-
}
|
|
48
|
+
uploadService;
|
|
49
|
+
localization;
|
|
50
|
+
navigation;
|
|
51
|
+
dropZoneService;
|
|
52
|
+
zone;
|
|
53
|
+
renderer;
|
|
54
|
+
cdr;
|
|
55
|
+
injector;
|
|
125
56
|
/**
|
|
126
57
|
* By default, the selected files are immediately uploaded
|
|
127
58
|
* ([see example]({% slug fileprocessing_upload %}#toc-automatic-upload-of-files)).
|
|
@@ -247,6 +178,12 @@ export class UploadComponent extends UploadFileSelectBase {
|
|
|
247
178
|
get removeUrl() {
|
|
248
179
|
return this.uploadService.async.removeUrl;
|
|
249
180
|
}
|
|
181
|
+
/**
|
|
182
|
+
* Enables the chunk functionality of the Upload.
|
|
183
|
+
*
|
|
184
|
+
* @default false
|
|
185
|
+
*/
|
|
186
|
+
chunkable = false;
|
|
250
187
|
/**
|
|
251
188
|
* Specifies if the selected files are uploaded simultaneously or one by one.
|
|
252
189
|
*
|
|
@@ -258,6 +195,11 @@ export class UploadComponent extends UploadFileSelectBase {
|
|
|
258
195
|
get concurrent() {
|
|
259
196
|
return this.uploadService.async.concurrent;
|
|
260
197
|
}
|
|
198
|
+
/**
|
|
199
|
+
* Toggles the visibility of the file list.
|
|
200
|
+
* @default true
|
|
201
|
+
*/
|
|
202
|
+
showFileList = true;
|
|
261
203
|
/**
|
|
262
204
|
* @hidden
|
|
263
205
|
*/
|
|
@@ -267,9 +209,85 @@ export class UploadComponent extends UploadFileSelectBase {
|
|
|
267
209
|
get tabIndex() {
|
|
268
210
|
return this.tabindex;
|
|
269
211
|
}
|
|
212
|
+
/**
|
|
213
|
+
* Specifies the possible layout of the action buttons.
|
|
214
|
+
*/
|
|
215
|
+
actionsLayout = 'end';
|
|
216
|
+
fileSelectInput;
|
|
217
|
+
/**
|
|
218
|
+
* Fires when the upload is canceled while in progress.
|
|
219
|
+
*/
|
|
220
|
+
cancel = new EventEmitter();
|
|
221
|
+
/**
|
|
222
|
+
* Fires when the file list is about to be cleared. If prevented, the files will not be cleared.
|
|
223
|
+
*/
|
|
224
|
+
clear = new EventEmitter();
|
|
225
|
+
/**
|
|
226
|
+
* Fires when all active uploads are completed either successfully or with errors.
|
|
227
|
+
*/
|
|
228
|
+
complete = new EventEmitter();
|
|
229
|
+
/**
|
|
230
|
+
* Fires when an `upload` or `remove` operation has failed.
|
|
231
|
+
*/
|
|
232
|
+
error = new EventEmitter();
|
|
233
|
+
/**
|
|
234
|
+
* Fires when the upload of a file has been paused.
|
|
235
|
+
*/
|
|
236
|
+
pause = new EventEmitter();
|
|
237
|
+
/**
|
|
238
|
+
* Fires when the upload of a file has been resumed.
|
|
239
|
+
*/
|
|
240
|
+
resume = new EventEmitter();
|
|
241
|
+
/**
|
|
242
|
+
* Fires when an `upload` or `remove` operation is successfully completed.
|
|
243
|
+
*/
|
|
244
|
+
success = new EventEmitter();
|
|
245
|
+
/**
|
|
246
|
+
* Fires when one or more files are about to be uploaded. If prevented, the files will neither be uploaded, nor added to the file list.
|
|
247
|
+
*/
|
|
248
|
+
upload = new EventEmitter();
|
|
249
|
+
/**
|
|
250
|
+
* Fires when one or more files are being uploaded.
|
|
251
|
+
*/
|
|
252
|
+
uploadProgress = new EventEmitter();
|
|
253
|
+
/**
|
|
254
|
+
* Fires when the value of the component has changed as a result of a successful `upload`, `remove` or `clear` operation.
|
|
255
|
+
*/
|
|
256
|
+
valueChange = new EventEmitter();
|
|
270
257
|
get dir() {
|
|
271
258
|
return this.direction;
|
|
272
259
|
}
|
|
260
|
+
direction;
|
|
261
|
+
wrapper;
|
|
262
|
+
fileListId;
|
|
263
|
+
documentClick; // eslint-disable-line @typescript-eslint/ban-types
|
|
264
|
+
blurSubscription;
|
|
265
|
+
wrapperFocusSubscription;
|
|
266
|
+
selectButtonFocusSubscription;
|
|
267
|
+
localizationChangeSubscription;
|
|
268
|
+
subs;
|
|
269
|
+
constructor(uploadService, localization, navigation, dropZoneService, zone, renderer, cdr, wrapper, injector) {
|
|
270
|
+
super(uploadService, navigation, cdr, injector, zone);
|
|
271
|
+
this.uploadService = uploadService;
|
|
272
|
+
this.localization = localization;
|
|
273
|
+
this.navigation = navigation;
|
|
274
|
+
this.dropZoneService = dropZoneService;
|
|
275
|
+
this.zone = zone;
|
|
276
|
+
this.renderer = renderer;
|
|
277
|
+
this.cdr = cdr;
|
|
278
|
+
this.injector = injector;
|
|
279
|
+
validatePackage(packageMetadata);
|
|
280
|
+
this.fileList = this.uploadService.files;
|
|
281
|
+
this.localizationChangeSubscription = localization.changes.subscribe(({ rtl }) => {
|
|
282
|
+
this.direction = rtl ? 'rtl' : 'ltr';
|
|
283
|
+
});
|
|
284
|
+
this.direction = localization.rtl ? 'rtl' : 'ltr';
|
|
285
|
+
this.navigation.computeKeys();
|
|
286
|
+
this.wrapper = wrapper.nativeElement;
|
|
287
|
+
this.subscribeBlur();
|
|
288
|
+
this.subscribeFocus();
|
|
289
|
+
this.attachEventHandlers();
|
|
290
|
+
}
|
|
273
291
|
ngOnInit() {
|
|
274
292
|
this.verifySettings();
|
|
275
293
|
const { buttonId, fileListId } = this.getIds();
|
|
@@ -524,23 +542,22 @@ export class UploadComponent extends UploadFileSelectBase {
|
|
|
524
542
|
this.uploadProgress.emit(args);
|
|
525
543
|
}));
|
|
526
544
|
}
|
|
527
|
-
}
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
}
|
|
543
|
-
], viewQueries: [{ propertyName: "fileSelectInput", first: true, predicate: ["fileSelectInput"], descendants: true, static: true }], exportAs: ["kendoUpload"], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: `
|
|
545
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: UploadComponent, deps: [{ token: i1.UploadService }, { token: i2.LocalizationService }, { token: i3.NavigationService }, { token: i4.DropZoneService }, { token: i0.NgZone }, { token: i0.Renderer2 }, { token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
|
|
546
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: UploadComponent, isStandalone: true, selector: "kendo-upload", inputs: { autoUpload: "autoUpload", batch: "batch", withCredentials: "withCredentials", saveField: "saveField", saveHeaders: "saveHeaders", saveMethod: "saveMethod", saveUrl: "saveUrl", responseType: "responseType", removeField: "removeField", removeHeaders: "removeHeaders", removeMethod: "removeMethod", removeUrl: "removeUrl", chunkable: "chunkable", concurrent: "concurrent", showFileList: "showFileList", tabIndex: "tabIndex", actionsLayout: "actionsLayout" }, outputs: { cancel: "cancel", clear: "clear", complete: "complete", error: "error", pause: "pause", resume: "resume", success: "success", upload: "upload", uploadProgress: "uploadProgress", valueChange: "valueChange" }, host: { properties: { "attr.dir": "this.dir" } }, providers: [
|
|
547
|
+
LocalizationService,
|
|
548
|
+
NavigationService,
|
|
549
|
+
UploadService,
|
|
550
|
+
DropZoneService,
|
|
551
|
+
UPLOAD_VALUE_ACCESSOR,
|
|
552
|
+
{
|
|
553
|
+
provide: L10N_PREFIX,
|
|
554
|
+
useValue: 'kendo.upload'
|
|
555
|
+
},
|
|
556
|
+
{
|
|
557
|
+
provide: KendoInput,
|
|
558
|
+
useExisting: forwardRef(() => UploadComponent)
|
|
559
|
+
}
|
|
560
|
+
], viewQueries: [{ propertyName: "fileSelectInput", first: true, predicate: ["fileSelectInput"], descendants: true, static: true }], exportAs: ["kendoUpload"], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: `
|
|
544
561
|
<ng-container kendoUploadLocalizedMessages
|
|
545
562
|
i18n-cancel="kendo.upload.cancel|The text for the Cancel button"
|
|
546
563
|
cancel="Cancel"
|
|
@@ -651,8 +668,9 @@ UploadComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", versio
|
|
|
651
668
|
[disabled]="disabled"
|
|
652
669
|
[actionsLayout]="actionsLayout">
|
|
653
670
|
</kendo-upload-action-buttons>
|
|
654
|
-
`, isInline: true, dependencies: [{ kind: "directive", type: LocalizedMessagesDirective, selector: "\n [kendoUploadLocalizedMessages],\n [kendoFileSelectLocalizedMessages],\n [kendoUploadDropZoneLocalizedMessages]\n " }, { kind: "directive", type: DropZoneInternalDirective, selector: "\n [kendoUploadInternalDropZone],\n [kendoFileSelectInternalDropZone]\n ", inputs: ["disabled", "multiple", "restrictions"] }, { kind: "component", type: ButtonComponent, selector: "button[kendoButton]
|
|
655
|
-
|
|
671
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: LocalizedMessagesDirective, selector: "\n [kendoUploadLocalizedMessages],\n [kendoFileSelectLocalizedMessages],\n [kendoUploadDropZoneLocalizedMessages]\n " }, { kind: "directive", type: DropZoneInternalDirective, selector: "\n [kendoUploadInternalDropZone],\n [kendoFileSelectInternalDropZone]\n ", inputs: ["disabled", "multiple", "restrictions"] }, { kind: "component", type: ButtonComponent, selector: "button[kendoButton]", inputs: ["arrowIcon", "toggleable", "togglable", "selected", "tabIndex", "imageUrl", "iconClass", "icon", "disabled", "size", "rounded", "fillMode", "themeColor", "svgIcon", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }, { kind: "directive", type: FileSelectDirective, selector: "[kendoFileSelect]", inputs: ["dir", "disabled", "multiple", "restrictions", "accept", "required"] }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: UploadStatusTotalComponent, selector: "kendo-upload-status-total", inputs: ["fileList"] }, { kind: "component", type: FileListComponent, selector: "[kendo-upload-file-list]", inputs: ["disabled", "fileList", "fileTemplate", "fileInfoTemplate"] }, { kind: "component", type: UploadActionButtonsComponent, selector: "kendo-upload-action-buttons", inputs: ["disabled", "actionsLayout"] }] });
|
|
672
|
+
}
|
|
673
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: UploadComponent, decorators: [{
|
|
656
674
|
type: Component,
|
|
657
675
|
args: [{
|
|
658
676
|
exportAs: 'kendoUpload',
|
|
@@ -21,15 +21,15 @@ import * as i8 from "./dropzone.component";
|
|
|
21
21
|
* Represents the [NgModule](https://angular.io/api/core/NgModule) definition for the Upload component.
|
|
22
22
|
*/
|
|
23
23
|
export class UploadModule {
|
|
24
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: UploadModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
25
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: UploadModule, imports: [i1.UploadComponent, i2.UploadActionButtonsComponent, i3.UploadStatusTotalComponent, i4.FileTemplateDirective, i5.FileInfoTemplateDirective, i6.CustomMessagesComponent, i7.UploadDropZoneDirective, i8.UploadDropZoneComponent], exports: [i1.UploadComponent, i2.UploadActionButtonsComponent, i3.UploadStatusTotalComponent, i4.FileTemplateDirective, i5.FileInfoTemplateDirective, i6.CustomMessagesComponent, i7.UploadDropZoneDirective, i8.UploadDropZoneComponent] });
|
|
26
|
+
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: UploadModule, providers: [
|
|
27
|
+
IconsService,
|
|
28
|
+
PopupService,
|
|
29
|
+
ResizeBatchService
|
|
30
|
+
], imports: [i1.UploadComponent, i3.UploadStatusTotalComponent, i8.UploadDropZoneComponent] });
|
|
24
31
|
}
|
|
25
|
-
|
|
26
|
-
UploadModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: UploadModule, imports: [i1.UploadComponent, i2.UploadActionButtonsComponent, i3.UploadStatusTotalComponent, i4.FileTemplateDirective, i5.FileInfoTemplateDirective, i6.CustomMessagesComponent, i7.UploadDropZoneDirective, i8.UploadDropZoneComponent], exports: [i1.UploadComponent, i2.UploadActionButtonsComponent, i3.UploadStatusTotalComponent, i4.FileTemplateDirective, i5.FileInfoTemplateDirective, i6.CustomMessagesComponent, i7.UploadDropZoneDirective, i8.UploadDropZoneComponent] });
|
|
27
|
-
UploadModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: UploadModule, providers: [
|
|
28
|
-
IconsService,
|
|
29
|
-
PopupService,
|
|
30
|
-
ResizeBatchService
|
|
31
|
-
], imports: [i1.UploadComponent, i2.UploadActionButtonsComponent, i3.UploadStatusTotalComponent, i6.CustomMessagesComponent, i8.UploadDropZoneComponent] });
|
|
32
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: UploadModule, decorators: [{
|
|
32
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: UploadModule, decorators: [{
|
|
33
33
|
type: NgModule,
|
|
34
34
|
args: [{
|
|
35
35
|
exports: [...KENDO_UPLOAD],
|
|
@@ -15,54 +15,55 @@ import * as i1 from "@angular/common/http";
|
|
|
15
15
|
* @hidden
|
|
16
16
|
*/
|
|
17
17
|
export class UploadService {
|
|
18
|
+
http;
|
|
19
|
+
cancelEvent = new EventEmitter();
|
|
20
|
+
clearEvent = new EventEmitter();
|
|
21
|
+
completeEvent = new EventEmitter();
|
|
22
|
+
errorEvent = new EventEmitter();
|
|
23
|
+
pauseEvent = new EventEmitter();
|
|
24
|
+
removeEvent = new EventEmitter();
|
|
25
|
+
resumeEvent = new EventEmitter();
|
|
26
|
+
selectEvent = new EventEmitter();
|
|
27
|
+
successEvent = new EventEmitter();
|
|
28
|
+
uploadEvent = new EventEmitter();
|
|
29
|
+
uploadProgressEvent = new EventEmitter();
|
|
30
|
+
/**
|
|
31
|
+
* Required for the `ControlValueAccessor` integration
|
|
32
|
+
*/
|
|
33
|
+
changeEvent = new EventEmitter();
|
|
34
|
+
/**
|
|
35
|
+
* Default async settings
|
|
36
|
+
*/
|
|
37
|
+
async = {
|
|
38
|
+
autoUpload: true,
|
|
39
|
+
batch: false,
|
|
40
|
+
chunk: false,
|
|
41
|
+
concurrent: true,
|
|
42
|
+
removeField: "fileNames",
|
|
43
|
+
removeHeaders: new HttpHeaders(),
|
|
44
|
+
removeMethod: "POST",
|
|
45
|
+
removeUrl: "",
|
|
46
|
+
responseType: "json",
|
|
47
|
+
saveField: "files",
|
|
48
|
+
saveHeaders: new HttpHeaders(),
|
|
49
|
+
saveMethod: "POST",
|
|
50
|
+
saveUrl: "",
|
|
51
|
+
withCredentials: true
|
|
52
|
+
};
|
|
53
|
+
/**
|
|
54
|
+
* Default chunk settings
|
|
55
|
+
*/
|
|
56
|
+
chunk = {
|
|
57
|
+
autoRetryAfter: 100,
|
|
58
|
+
size: 1024 * 1024,
|
|
59
|
+
maxAutoRetries: 1,
|
|
60
|
+
resumable: true
|
|
61
|
+
};
|
|
62
|
+
component = 'Upload';
|
|
63
|
+
chunkMap = new ChunkMap();
|
|
64
|
+
fileList = new FileMap();
|
|
18
65
|
constructor(http) {
|
|
19
66
|
this.http = http;
|
|
20
|
-
this.cancelEvent = new EventEmitter();
|
|
21
|
-
this.clearEvent = new EventEmitter();
|
|
22
|
-
this.completeEvent = new EventEmitter();
|
|
23
|
-
this.errorEvent = new EventEmitter();
|
|
24
|
-
this.pauseEvent = new EventEmitter();
|
|
25
|
-
this.removeEvent = new EventEmitter();
|
|
26
|
-
this.resumeEvent = new EventEmitter();
|
|
27
|
-
this.selectEvent = new EventEmitter();
|
|
28
|
-
this.successEvent = new EventEmitter();
|
|
29
|
-
this.uploadEvent = new EventEmitter();
|
|
30
|
-
this.uploadProgressEvent = new EventEmitter();
|
|
31
|
-
/**
|
|
32
|
-
* Required for the `ControlValueAccessor` integration
|
|
33
|
-
*/
|
|
34
|
-
this.changeEvent = new EventEmitter();
|
|
35
|
-
/**
|
|
36
|
-
* Default async settings
|
|
37
|
-
*/
|
|
38
|
-
this.async = {
|
|
39
|
-
autoUpload: true,
|
|
40
|
-
batch: false,
|
|
41
|
-
chunk: false,
|
|
42
|
-
concurrent: true,
|
|
43
|
-
removeField: "fileNames",
|
|
44
|
-
removeHeaders: new HttpHeaders(),
|
|
45
|
-
removeMethod: "POST",
|
|
46
|
-
removeUrl: "",
|
|
47
|
-
responseType: "json",
|
|
48
|
-
saveField: "files",
|
|
49
|
-
saveHeaders: new HttpHeaders(),
|
|
50
|
-
saveMethod: "POST",
|
|
51
|
-
saveUrl: "",
|
|
52
|
-
withCredentials: true
|
|
53
|
-
};
|
|
54
|
-
/**
|
|
55
|
-
* Default chunk settings
|
|
56
|
-
*/
|
|
57
|
-
this.chunk = {
|
|
58
|
-
autoRetryAfter: 100,
|
|
59
|
-
size: 1024 * 1024,
|
|
60
|
-
maxAutoRetries: 1,
|
|
61
|
-
resumable: true
|
|
62
|
-
};
|
|
63
|
-
this.component = 'Upload';
|
|
64
|
-
this.chunkMap = new ChunkMap();
|
|
65
|
-
this.fileList = new FileMap();
|
|
66
67
|
}
|
|
67
68
|
get files() {
|
|
68
69
|
return this.fileList;
|
|
@@ -420,9 +421,9 @@ export class UploadService {
|
|
|
420
421
|
}
|
|
421
422
|
return false;
|
|
422
423
|
}
|
|
424
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: UploadService, deps: [{ token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
425
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: UploadService });
|
|
423
426
|
}
|
|
424
|
-
|
|
425
|
-
UploadService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: UploadService });
|
|
426
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: UploadService, decorators: [{
|
|
427
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: UploadService, decorators: [{
|
|
427
428
|
type: Injectable
|
|
428
429
|
}], ctorParameters: function () { return [{ type: i1.HttpClient }]; } });
|
|
@@ -44,15 +44,15 @@ import * as i9 from "./rendering/upload-status-total.component";
|
|
|
44
44
|
* ```
|
|
45
45
|
*/
|
|
46
46
|
export class UploadsModule {
|
|
47
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: UploadsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
48
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: UploadsModule, imports: [i1.FileSelectComponent, i2.FileTemplateDirective, i3.FileInfoTemplateDirective, i4.CustomMessagesComponent, i5.UploadDropZoneDirective, i6.UploadDropZoneComponent, i7.UploadComponent, i8.UploadActionButtonsComponent, i9.UploadStatusTotalComponent, i2.FileTemplateDirective, i3.FileInfoTemplateDirective, i4.CustomMessagesComponent, i5.UploadDropZoneDirective, i6.UploadDropZoneComponent], exports: [i1.FileSelectComponent, i2.FileTemplateDirective, i3.FileInfoTemplateDirective, i4.CustomMessagesComponent, i5.UploadDropZoneDirective, i6.UploadDropZoneComponent, i7.UploadComponent, i8.UploadActionButtonsComponent, i9.UploadStatusTotalComponent, i2.FileTemplateDirective, i3.FileInfoTemplateDirective, i4.CustomMessagesComponent, i5.UploadDropZoneDirective, i6.UploadDropZoneComponent] });
|
|
49
|
+
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: UploadsModule, providers: [
|
|
50
|
+
IconsService,
|
|
51
|
+
PopupService,
|
|
52
|
+
ResizeBatchService
|
|
53
|
+
], imports: [i1.FileSelectComponent, i6.UploadDropZoneComponent, i7.UploadComponent, i9.UploadStatusTotalComponent, i6.UploadDropZoneComponent] });
|
|
47
54
|
}
|
|
48
|
-
|
|
49
|
-
UploadsModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: UploadsModule, imports: [i1.FileSelectComponent, i2.FileTemplateDirective, i3.FileInfoTemplateDirective, i4.CustomMessagesComponent, i5.UploadDropZoneDirective, i6.UploadDropZoneComponent, i7.UploadComponent, i8.UploadActionButtonsComponent, i9.UploadStatusTotalComponent, i2.FileTemplateDirective, i3.FileInfoTemplateDirective, i4.CustomMessagesComponent, i5.UploadDropZoneDirective, i6.UploadDropZoneComponent], exports: [i1.FileSelectComponent, i2.FileTemplateDirective, i3.FileInfoTemplateDirective, i4.CustomMessagesComponent, i5.UploadDropZoneDirective, i6.UploadDropZoneComponent, i7.UploadComponent, i8.UploadActionButtonsComponent, i9.UploadStatusTotalComponent, i2.FileTemplateDirective, i3.FileInfoTemplateDirective, i4.CustomMessagesComponent, i5.UploadDropZoneDirective, i6.UploadDropZoneComponent] });
|
|
50
|
-
UploadsModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: UploadsModule, providers: [
|
|
51
|
-
IconsService,
|
|
52
|
-
PopupService,
|
|
53
|
-
ResizeBatchService
|
|
54
|
-
], imports: [i1.FileSelectComponent, i4.CustomMessagesComponent, i6.UploadDropZoneComponent, i7.UploadComponent, i8.UploadActionButtonsComponent, i9.UploadStatusTotalComponent, i4.CustomMessagesComponent, i6.UploadDropZoneComponent] });
|
|
55
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: UploadsModule, decorators: [{
|
|
55
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: UploadsModule, decorators: [{
|
|
56
56
|
type: NgModule,
|
|
57
57
|
args: [{
|
|
58
58
|
exports: [...KENDO_UPLOADS],
|