diff --git a/projects/file-picker/package.json b/projects/file-picker/package.json index b61fd41..b946cae 100644 --- a/projects/file-picker/package.json +++ b/projects/file-picker/package.json @@ -1,6 +1,6 @@ { "name": "ngx-awesome-uploader", - "version": "10.0.1", + "version": "10.0.2", "description": "Angular Library for uploading files with Real-Time Progress bar, File Preview, Drag && Drop and Custom Template with Multi Language support", "peerDependencies": { "@angular/common": "^6.0.0 || ^7.0.0 || ^8.0.0 || ^9.0.0 || ^10.0.0 || ^11.0.0", diff --git a/src/app/demo-file-picker/demo-file-picker.component.html b/src/app/demo-file-picker/demo-file-picker.component.html index d792110..8bec2a9 100644 --- a/src/app/demo-file-picker/demo-file-picker.component.html +++ b/src/app/demo-file-picker/demo-file-picker.component.html @@ -15,6 +15,7 @@ [showPreviewContainer]="true" [customValidator]="myCustomValidator" [enableAutoUpload]="true" + [itemTemplate]="itemTemplate" (fileAdded)="onFileAdded($event)" (fileRemoved)="onFileRemoved($event)" > diff --git a/src/app/demo-file-picker/demo-file-picker.component.ts b/src/app/demo-file-picker/demo-file-picker.component.ts index ab8a0c1..b6f55b1 100644 --- a/src/app/demo-file-picker/demo-file-picker.component.ts +++ b/src/app/demo-file-picker/demo-file-picker.component.ts @@ -37,16 +37,16 @@ export class DemoFilePickerComponent implements OnInit { constructor(private http: HttpClient) { } - // public ngOnInit(): void { - // this.uploader.files = [ - // { - // fileName: 'My File 1 for edit.png', file: null - // }, - // { - // fileName: 'My File 2 for edit.xlsx', file: null - // } - // ] as FilePreviewModel[]; - // } + public ngOnInit(): void { + this.uploader.files = [ + { + fileName: 'My File 1 for edit.png', file: null + }, + { + fileName: 'My File 2 for edit.xlsx', file: null + } + ] as FilePreviewModel[]; + } public onValidationError(er: ValidationError): void { console.log('validationError', er); @@ -71,7 +71,7 @@ export class DemoFilePickerComponent implements OnInit { } public onFileRemoved(file: FilePreviewModel): void { - console.log(this.uploader.files); + console.log('fileRemoved', this.uploader.files); } public removeFile(): void {