Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@iplab/ngx-file-upload

Package Overview
Dependencies
Maintainers
1
Versions
69
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@iplab/ngx-file-upload - npm Package Compare versions

Comparing version 1.1.8 to 1.1.9

2

bundles/iplab-ngx-file-upload.umd.min.js

@@ -1,2 +0,2 @@

!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("rxjs"),require("@angular/animations"),require("@angular/common"),require("@angular/core"),require("@angular/forms")):"function"==typeof define&&define.amd?define("@iplab/ngx-file-upload",["exports","rxjs","@angular/animations","@angular/common","@angular/core","@angular/forms"],e):e((t.iplab=t.iplab||{},t.iplab["ngx-file-upload"]={}),t.rxjs,t.ng.animations,t.ng.common,t.ng.core,t.ng.forms)}(this,function(t,e,i,n,o,r){"use strict";function s(t,e){var i="function"==typeof Symbol&&t[Symbol.iterator];if(!i)return t;var n,o,r=i.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=r.next()).done;)s.push(n.value)}catch(a){o={error:a}}finally{try{n&&!n.done&&(i=r["return"])&&i.call(r)}finally{if(o)throw o.error}}return s}function a(t){return null==t||0===t.length}var l={INVALID:0,VALID:1,DISABLED:2};l[l.INVALID]="INVALID",l[l.VALID]="VALID",l[l.DISABLED]="DISABLED";var c=function(){function t(t){this.files=new Set,this.listVisible=!0,this.status=l.VALID,this.errors=[],this.validators=[],this.statusChanged=new e.Subject,this.statusChanges=this.statusChanged.asObservable(),this.valueChanges=new e.BehaviorSubject([]),this.listVisibilityChanges=new e.BehaviorSubject(this.listVisible),this.defineValidators(t)}return t.prototype.setValidators=function(t){return this.defineValidators(t),this.validate(),this},t.prototype.defineValidators=function(t){a(t)||(this.validators=Array.isArray(t)?function i(){for(var t=[],e=0;e<arguments.length;e++)t=t.concat(s(arguments[e]));return t}(t):[t])},t.prototype.addFile=function(t){return this.files.add(t),this.validate(),this.valueChanges.next(Array.from(this.files.values())),this},t.prototype.removeFile=function(t){return this.files["delete"](t),this.validate(),this.valueChanges.next(Array.from(this.files.values())),this},t.prototype.addFiles=function(t){return this.addMultipleFiles(Array.from(t)),this},t.prototype.addMultipleFiles=function(t){var e=this;t.forEach(function(t){return e.files.add(t)}),this.validate(),this.valueChanges.next(Array.from(this.files.values()))},Object.defineProperty(t.prototype,"valid",{get:function(){return 0===this.errors.length&&this.status!==l.DISABLED},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"invalid",{get:function(){return 0<this.errors.length||this.status===l.DISABLED},enumerable:!0,configurable:!0}),t.prototype.getError=function(){return this.errors},Object.defineProperty(t.prototype,"size",{get:function(){return this.files.size},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"value",{get:function(){return Array.from(this.files.values())},enumerable:!0,configurable:!0}),t.prototype.setValue=function(t){if(this.files.clear(),!(t instanceof Array))throw Error("FormControl.setValue was provided with wrong argument type, "+t+" was provided instead Array<File>");return this.addMultipleFiles(t),this},t.prototype.clear=function(){return this.files.clear(),this.validate(),this.valueChanges.next(Array.from(this.files.values())),this},Object.defineProperty(t.prototype,"isListVisible",{get:function(){return this.listVisible},enumerable:!0,configurable:!0}),t.prototype.setListVisibility=function(t){return void 0===t&&(t=!0),this.listVisible=t,this.listVisibilityChanges.next(this.listVisible),this},Object.defineProperty(t.prototype,"disabled",{get:function(){return this.status===l.DISABLED},enumerable:!0,configurable:!0}),t.prototype.enable=function(t){return void 0===t&&(t=!0),this.status=t?l.VALID:l.DISABLED,this.validate(),this.statusChanged.next(this.status),this},t.prototype.disable=function(t){return void 0===t&&(t=!0),this.status=t?l.DISABLED:l.VALID,this.validate(),this.statusChanged.next(this.status),this},t.prototype.validate=function(){var e=this;if(this.status!==l.DISABLED){var t=this.valid;this.errors=this.validators.map(function(t){return t(e)}).filter(function(t){return t}),t!==this.valid&&this.statusChanged.next(this.valid?l.VALID:l.INVALID)}else this.errors.length=0},t}(),p={aac:"audio/aac",abw:"application/x-abiword",arc:"application/octet-stream",avi:"video/x-msvideo",azw:"application/vnd.amazon.ebook",bin:"application/octet-stream",bmp:"image/bmp",bz:"application/x-bzip",bz2:"application/x-bzip2",csh:"application/x-csh",css:"text/css",csv:"text/csv",doc:"application/msword",docx:"application/vnd.openxmlformats-officedocument.wordprocessingml.document",eot:"application/vnd.ms-fontobject",epub:"application/epub+zip",es:"application/ecmascript",gif:"image/gif",html:"text/html",ico:"image/x-icon",ics:"text/calendar",jar:"application/java-archive",jpg:"image/jpeg",js:"application/javascript",json:"application/json",midi:"audio/midi",mpeg:"video/mpeg",mpkg:"application/vnd.apple.installer+xml",odp:"application/vnd.oasis.opendocument.presentation",ods:"application/vnd.oasis.opendocument.spreadsheet",odt:"application/vnd.oasis.opendocument.text",oga:"audio/ogg",ogv:"video/ogg",ogx:"application/ogg",otf:"font/otf",png:"image/png",pdf:"application/pdf",ppt:"application/vnd.ms-powerpoint",pptx:"application/vnd.openxmlformats-officedocument.presentationml.presentation",rar:"application/vnd.openxmlformats-officedocument.presentationml.presentation",rtf:"application/rtf",sh:"application/x-sh",svg:"image/svg+xml",swf:"application/x-shockwave-flash",tar:"application/x-tar",tiff:"image/tiff",ts:"application/typescript",ttf:"font/ttf",vsd:"application/vnd.visio",wav:"audio/wav",weba:"audio/webm",webm:"video/webm",webp:"image/webp",woff:"font/woff",woff2:"font/woff2",xhtml:"application/xhtml+xml",xls:"application/vnd.ms-excel",xlsx:"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",xml:"application/xml",xul:"application/vnd.mozilla.xul+xml",zip:"application/zip","3gp":"video/3gpp","3g2":"video/3gpp2","7z":"application/x-7z-compressed"},h=function(){function t(t){this.renderer=t,this.extensions=["bytes","KB","MB","GB"]}return t.prototype.isFileDragDropAvailable=function(){var t=this.renderer.createElement("div");return("draggable"in t||"ondragstart"in t&&"ondrop"in t)&&FormData&&!!FileReader},t.prototype.calculateSize=function(t,e){return void 0===e&&(e=0),isNaN(t)&&(t=0),t<1024?Math.round(100*t)/100+" "+this.extensions[e]:this.calculateSize(t/1024,e+1)},t.prototype.getFileType=function(e){return Object.keys(p).find(function(t){return p[t]===e.type})},t.decorators=[{type:o.Injectable}],t.ctorParameters=function(){return[{type:o.Renderer2}]},t}(),u=i.trigger("insertAnimation",[i.transition("* => *",[i.query(":leave",[i.stagger(30,[i.animate(".3s",i.style({opacity:0}))])],{optional:!0}),i.query(":enter",[i.style({opacity:0}),i.stagger(30,[i.animate(".3s",i.style({opacity:1}))])],{optional:!0})])]),d=i.trigger("zoomAnimation",[i.transition("static => zoomOut",[i.animate(250,i.style({transform:"translate(-50%, -50%) scale(2, 2)",opacity:0}))]),i.transition("static => zoomIn",[i.query(":self",[i.style({transform:"translate(-50%, -50%) scale(.2, .2)",opacity:0,top:"50%",left:"50%",margin:0}),i.stagger(50,[i.animate(250,i.style({transform:"translate(-50%, -50%) scale(1, 1)",opacity:1}))])])])]),f="dragover",g="ng-touched",v=function(){function t(t,e,i,n,o){var r=this;this.fileUploadService=t,this.hostElementRef=e,this.renderer=i,this.document=n,this.cdr=o,this.control=null,this.templateRef=null,this.listItem=null,this.templateContext={$implicit:this.fileUploadService.isFileDragDropAvailable(),isFileDragDropAvailable:this.fileUploadService.isFileDragDropAvailable()},this.zoomText="static",this.listVisible=!1,this.hooks=[],this.subscriptions=[],this.onChange=function(){},this.onTouch=function(){r.renderer.addClass(r.hostElementRef.nativeElement,g)}}return t.prototype.ngOnInit=function(){a(this.control)&&(this.control=new c),this.setEvents(),this.checkAndMarkAsDisabled(),this.connectToForm()},t.prototype.ngOnDestroy=function(){this.cdr.detach(),this.hooks.forEach(function(t){return t()}),this.hooks.length=0,this.subscriptions.forEach(function(t){return t.unsubscribe()}),this.subscriptions.length=0},Object.defineProperty(t.prototype,"hasFiles",{get:function(){return this.control.isListVisible&&0<this.control.size},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"isInvalid",{get:function(){return!this.control.disabled&&this.control.invalid},enumerable:!0,configurable:!0}),t.prototype.setEvents=function(){var e=this;["drag","dragstart","dragend","dragover","dragenter","dragleave","drop"].forEach(function(t){e.hooks.push(e.renderer.listen(e.document,t,function(t){return e.preventDragEvents(t)}))}),["dragover","dragenter"].forEach(function(t){e.hooks.push(e.renderer.listen(e.hostElementRef.nativeElement,t,function(t){return e.onDragOver(t)}))}),["dragleave","dragend","drop"].forEach(function(t){e.hooks.push(e.renderer.listen(e.hostElementRef.nativeElement,t,function(t){return e.onDragLeave(t)}))}),this.subscriptions.push(this.control.statusChanges.subscribe(function(t){return e.checkAndMarkAsDisabled()})),this.subscriptions.push(this.control.valueChanges.subscribe(function(t){return e.renderView()})),this.subscriptions.push(this.control.listVisibilityChanges.subscribe(function(t){return e.toggleListVisibility()}))},t.prototype.checkAndMarkAsDisabled=function(){this.control.disabled?(this.renderer.addClass(this.hostElementRef.nativeElement,"disabled"),this.renderer.setProperty(this.input.nativeElement,"disabled",!0)):(this.renderer.removeClass(this.hostElementRef.nativeElement,"disabled"),this.renderer.setProperty(this.input.nativeElement,"disabled",!1))},t.prototype.preventDragEvents=function(t){t.preventDefault(),t.stopPropagation()},t.prototype.renderView=function(){this.listVisible||(this.zoomText=this.control.isListVisible&&0<this.control.size?"zoomOut":"static"),this.cdr.markForCheck()},t.prototype.showList=function(){"static"!==this.zoomText&&(this.listVisible=!0)},t.prototype.hideList=function(){this.listVisible=!1},t.prototype.toggleListVisibility=function(){this.listVisible=this.control.isListVisible&&0<this.control.size,this.listVisible&&(this.renderer.addClass(this.hostElementRef.nativeElement,"list-visible"),this.zoomText="static"),this.cdr.markForCheck()},t.prototype.onDragOver=function(t){this.renderer.addClass(this.hostElementRef.nativeElement,f)},t.prototype.onDragLeave=function(t){this.renderer.removeClass(this.hostElementRef.nativeElement,f)},t.prototype.onDrop=function(t){if(!this.control.disabled){var e=t.dataTransfer.files;this.control.addFiles(e),this.onTouch()}},t.prototype.onInputChange=function(t){var e=t.target;this.control.disabled||this.control.addFiles(e.files),this.clearInputEl(),this.onTouch()},t.prototype.clearInputEl=function(){this.input.nativeElement.value=null},t.prototype.connectToForm=function(){var e=this;this.subscriptions.push(this.control.valueChanges.subscribe(function(t){return e.onChange(t)}))},t.prototype.writeValue=function(t){null!=t&&this.control.setValue(t)},t.prototype.registerOnChange=function(t){this.onChange=t},t.prototype.registerOnTouched=function(t){this.onTouch=t},t.prototype.setDisabledState=function(t){this.control.disable(t)},t.prototype.zoomAnimationDone=function(t){this.control.isListVisible&&0<this.control.size?this.showList():this.hideList(),"static"===t.fromState&&"zoomOut"===t.toState?this.renderer.addClass(this.hostElementRef.nativeElement,"hide-text"):this.renderer.removeClass(this.hostElementRef.nativeElement,"hide-text"),"zoomIn"===t.toState&&(this.zoomText="static")},t.prototype.animationListFinished=function(t){"void"===t.toState&&(this.zoomText="zoomIn",this.renderer.removeClass(this.hostElementRef.nativeElement,"list-visible")),"void"===t.fromState&&(this.zoomText="static",this.renderer.addClass(this.hostElementRef.nativeElement,"list-visible"))},t.decorators=[{type:o.Component,args:[{selector:"file-upload",template:'<label class="upload-input" [@zoomAnimation]="zoomText" (@zoomAnimation.done)="zoomAnimationDone($event)">\r\n\r\n <ng-container *ngTemplateOutlet="templateRef ? templateRef : defaultTemplate; context: templateContext"></ng-container>\r\n\r\n <ng-template #defaultTemplate let-isFileDragDropAvailable="isFileDragDropAvailable">\r\n <div class="icon">\r\n <svg viewBox="0 0 96 96">\r\n <g>\r\n <path d="M62.8,68.1c0-0.6-0.2-1.1-0.6-1.5c-0.4-0.4-0.9-0.6-1.5-0.6s-1.1,0.2-1.5,0.6\r\n c-0.4,0.4-0.6,0.9-0.6,1.5c0,0.6,0.2,1.1,0.6,1.5c0.4,0.4,0.9,0.6,1.5,0.6s1.1-0.2,1.5-0.6S62.8,68.7,62.8,68.1z M71.3,68.1\r\n c0-0.6-0.2-1.1-0.6-1.5c-0.4-0.4-0.9-0.6-1.5-0.6c-0.6,0-1.1,0.2-1.5,0.6C67.2,67,67,67.5,67,68.1c0,0.6,0.2,1.1,0.6,1.5\r\n s0.9,0.6,1.5,0.6c0.6,0,1.1-0.2,1.5-0.6C71.1,69.2,71.3,68.7,71.3,68.1z M75.5,60.7v10.6c0,0.9-0.3,1.6-0.9,2.2\r\n c-0.6,0.6-1.4,0.9-2.2,0.9H23.7c-0.9,0-1.6-0.3-2.2-0.9c-0.6-0.6-0.9-1.4-0.9-2.2V60.7c0-0.9,0.3-1.6,0.9-2.2\r\n c0.6-0.6,1.4-0.9,2.2-0.9h14.1c0.5,1.2,1.2,2.2,2.3,3c1.1,0.8,2.3,1.2,3.7,1.2h8.5c1.3,0,2.6-0.4,3.7-1.2c1.1-0.8,1.9-1.8,2.3-3\r\n h14.1c0.9,0,1.6,0.3,2.2,0.9C75.2,59.1,75.5,59.8,75.5,60.7z M64.8,39.3c-0.4,0.9-1,1.3-2,1.3h-8.5v14.8c0,0.6-0.2,1.1-0.6,1.5\r\n c-0.4,0.4-0.9,0.6-1.5,0.6h-8.5c-0.6,0-1.1-0.2-1.5-0.6c-0.4-0.4-0.6-0.9-0.6-1.5V40.6h-8.5c-0.9,0-1.6-0.4-2-1.3\r\n c-0.4-0.9-0.2-1.6,0.5-2.3l14.8-14.8c0.4-0.4,0.9-0.6,1.5-0.6s1.1,0.2,1.5,0.6L64.3,37C65,37.7,65.1,38.4,64.8,39.3z"/>\r\n </g>\r\n </svg>\r\n </div>\r\n \r\n <div class="upload-text">\r\n <ng-container *ngIf="isFileDragDropAvailable; else isNotDragDropAvailable">\r\n <b>Drag and drop</b> files<br> or click here\r\n </ng-container>\r\n <ng-template #isNotDragDropAvailable>\r\n <b>Click here</b> to<br> choose a files\r\n </ng-template>\r\n </div>\r\n </ng-template>\r\n\r\n <input #inputRef type="file" class="files-input" multiple (change)="onInputChange($event)">\r\n</label>\r\n\r\n<div class="upload-list" *ngIf="(control.listVisibilityChanges | async) && control.size > 0 && listVisible" [@insertAnimation]="control.size" (@insertAnimation.done)="animationListFinished($event)">\r\n <ng-template ngFor let-file let-i="index" [ngForOf]="control.valueChanges | async">\r\n <ng-container *ngTemplateOutlet="listItem ? listItem : defaultItemTemplate; context: { $implicit: file, file: file, index: i, control: control }"></ng-container>\r\n </ng-template>\r\n \r\n <ng-template #defaultItemTemplate let-i="index" let-file="file" let-control="control">\r\n <file-upload-list-item [index]="i" [file]="file" [control]="control"></file-upload-list-item>\r\n </ng-template>\r\n</div>',providers:[h,{provide:r.NG_VALUE_ACCESSOR,useExisting:o.forwardRef(function(){return t}),multi:!0}],changeDetection:o.ChangeDetectionStrategy.OnPush,animations:[d,u],styles:[':host,:host>*{box-sizing:border-box}:host{overflow:hidden;display:block;background:#fafafa;padding:20px 66px 20px 20px;min-height:140px;outline:#92b0b3 dashed 1px;outline-offset:-10px;position:relative}:host(.dragover){outline-width:2px}:host(.disabled){opacity:.5;cursor:no-drop}.files-input{width:.1px;height:.1px;opacity:0;position:absolute;left:-100%;top:-100%;overflow:hidden}.icon{height:35px;width:35px;border:1px solid #eaeaea;border-radius:4px;float:left}.icon svg{fill:#909293}.upload-input:after{clear:both;content:"\\0A0";display:block;height:0;line-height:0;visibility:hidden;zoom:1}.upload-input{cursor:pointer;display:inline-block;color:#646464;position:absolute;top:50%;left:50%;margin:0;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%)}:host(.disabled) .upload-input{cursor:not-allowed}:host(.list-visible) .upload-input{top:20px;left:100%;margin-left:-20px;-webkit-transform:translate(-100%,0);transform:translate(-100%,0);text-align:center}.upload-text{overflow:hidden;width:auto;position:relative;padding-left:20px}:host(.hide-text) .upload-input{opacity:0}:host(.list-visible) .upload-text{display:none}:host(.dragover:not(.disabled)) .upload-input,:host(:not(.disabled)) .upload-input:hover{color:#80a9d2}:host(.dragover:not(.disabled)) .icon svg,:host(:not(.disabled)) .upload-input:hover svg{fill:#80a9d2}file-upload-list-item{padding:10px 0 0}file-upload-list-item:first-child{padding:0}']}]}],t.ctorParameters=function(){return[{type:h},{type:o.ElementRef},{type:o.Renderer2},{type:undefined,decorators:[{type:o.Inject,args:[n.DOCUMENT]}]},{type:o.ChangeDetectorRef}]},t.propDecorators={control:[{type:o.Input}],templateRef:[{type:o.ContentChild,args:["placeholder"]}],listItem:[{type:o.ContentChild,args:["item"]}],input:[{type:o.ViewChild,args:["inputRef"]}],hasFiles:[{type:o.HostBinding,args:["class.has-files"]}],isInvalid:[{type:o.HostBinding,args:["class.ng-invalid"]}],onDrop:[{type:o.HostListener,args:["drop",["$event"]]}]},t}(),m=function(){function t(t){this.fileUploadService=t}return t.prototype.removeFile=function(t){this.control.removeFile(t)},t.prototype.calculateSize=function(t){return this.fileUploadService.calculateSize(t)},t.decorators=[{type:o.Component,args:[{selector:"file-upload-list-item",template:'\n <file-upload-icon [file]="file"></file-upload-icon>\n <div class="file-info">\n <span class="file-name">{{ file.name }}</span> ({{ calculateSize( file.size ) }})\n </div>\n <div class="file-buttons">\n <span class="remove-btn" (click)="removeFile(file)">\n <svg viewBox="0 0 96 96">\n <g>\n <path d="M40.5,66.8V39.3c0-0.4-0.1-0.7-0.4-0.9S39.6,38,39.3,38h-2.5c-0.4,0-0.7,0.1-0.9,0.4\n s-0.4,0.5-0.4,0.9v27.5c0,0.4,0.1,0.7,0.4,0.9s0.5,0.4,0.9,0.4h2.5c0.4,0,0.7-0.1,0.9-0.4S40.5,67.1,40.5,66.8z M50.5,66.8V39.3\n c0-0.4-0.1-0.7-0.4-0.9S49.6,38,49.3,38h-2.5c-0.4,0-0.7,0.1-0.9,0.4s-0.4,0.5-0.4,0.9v27.5c0,0.4,0.1,0.7,0.4,0.9s0.5,0.4,0.9,0.4\n h2.5c0.4,0,0.7-0.1,0.9-0.4S50.5,67.1,50.5,66.8z M60.5,66.8V39.3c0-0.4-0.1-0.7-0.4-0.9S59.6,38,59.3,38h-2.5\n c-0.4,0-0.7,0.1-0.9,0.4s-0.4,0.5-0.4,0.9v27.5c0,0.4,0.1,0.7,0.4,0.9s0.5,0.4,0.9,0.4h2.5c0.4,0,0.7-0.1,0.9-0.4\n S60.5,67.1,60.5,66.8z M39.3,28h17.5l-1.9-4.6c-0.2-0.2-0.4-0.4-0.7-0.4H41.8c-0.3,0.1-0.5,0.2-0.7,0.4L39.3,28z M75.5,29.3v2.5\n c0,0.4-0.1,0.7-0.4,0.9S74.6,33,74.3,33h-3.8v37c0,2.2-0.6,4-1.8,5.6S66,78,64.3,78H31.8c-1.7,0-3.2-0.8-4.4-2.3s-1.8-3.4-1.8-5.5\n V33h-3.8c-0.4,0-0.7-0.1-0.9-0.4s-0.4-0.5-0.4-0.9v-2.5c0-0.4,0.1-0.7,0.4-0.9s0.5-0.4,0.9-0.4h12.1l2.7-6.5c0.4-1,1.1-1.8,2.1-2.5\n s2-1,3.1-1h12.5c1,0,2.1,0.3,3.1,1s1.7,1.5,2.1,2.5l2.7,6.5h12.1c0.4,0,0.7,0.1,0.9,0.4S75.5,28.9,75.5,29.3z"/>\n </g>\n </svg> Remove</span>\n </div>\n ',styles:[':host{display:block;font-size:14px;color:#646464}:host:after{clear:both;content:"\\0A0";display:block;height:0;line-height:0;visibility:hidden;zoom:1}file-upload-icon{float:left;width:30px;height:36px;margin:0 10px 0 0}.remove-btn{font-size:12px;cursor:pointer}.remove-btn svg{display:inline-block;vertical-align:-20%;height:18px;width:18px}']}]}],t.ctorParameters=function(){return[{type:h}]},t.propDecorators={index:[{type:o.Input}],file:[{type:o.Input}],control:[{type:o.Input}]},t}(),y=function(){function t(t){this.fileUploadService=t,this.fileType="unknown"}return t.prototype.ngOnInit=function(){this.fileType=this.fileUploadService.getFileType(this.file)},t.prototype.isIcon=function(t){switch(t){case"text":return"html"===this.fileType||"css"===this.fileType||"csv"===this.fileType||"js"===this.fileType||"pdf"===this.fileType||"ppt"===this.fileType||"xls"===this.fileType||"xlsx"===this.fileType||"xml"===this.fileType||"doc"===this.fileType||"docx"===this.fileType;case"audio":return"aac"===this.fileType||"midi"===this.fileType||"oga"===this.fileType||"wav"===this.fileType||"weba"===this.fileType;case"image":return"png"===this.fileType||"bmp"===this.fileType||"gif"===this.fileType||"jpg"===this.fileType||"svg"===this.fileType||"webp"===this.fileType||"ico"===this.fileType;case"video":return"avi"===this.fileType||"mpeg"===this.fileType||"ogv"===this.fileType||"webm"===this.fileType||"3gp"===this.fileType||"3g2"===this.fileType}},t.decorators=[{type:o.Component,args:[{selector:"file-upload-icon",template:'\r\n\r\n<ng-container [ngSwitch]="true">\r\n\r\n <svg *ngSwitchDefault viewBox="0 0 96 96">\r\n <g>\r\n <path d="M71.4,30.7c0.6,0.6,1.2,1.5,1.6,2.5c0.4,1.1,0.7,2.1,0.7,2.9v38.6c0,0.9-0.3,1.7-0.9,2.3\r\n S71.4,78,70.5,78h-45c-0.9,0-1.7-0.3-2.3-0.9c-0.6-0.6-0.9-1.4-0.9-2.3V21.2c0-0.9,0.3-1.7,0.9-2.3c0.6-0.6,1.4-0.9,2.3-0.9h30\r\n c0.9,0,1.9,0.2,2.9,0.7c1.1,0.4,1.9,1,2.5,1.6L71.4,30.7z M56.6,22.6v12.6h12.6c-0.2-0.6-0.5-1.1-0.7-1.4L57.9,23.3\r\n C57.7,23,57.2,22.8,56.6,22.6z M69.4,73.7V39.4H55.5c-0.9,0-1.7-0.3-2.3-0.9c-0.6-0.6-0.9-1.4-0.9-2.3V22.3H26.6v51.4H69.4z"/>\r\n </g>\r\n </svg>\r\n\r\n <svg *ngSwitchCase="isIcon(\'image\')" viewBox="0 0 96 96">\r\n <g>\r\n <path d="M71.4,30.7c0.6,0.6,1.2,1.5,1.6,2.5c0.4,1.1,0.7,2.1,0.7,2.9v38.6c0,0.9-0.3,1.7-0.9,2.3\r\n S71.4,78,70.5,78h-45c-0.9,0-1.7-0.3-2.3-0.9c-0.6-0.6-0.9-1.4-0.9-2.3V21.2c0-0.9,0.3-1.7,0.9-2.3c0.6-0.6,1.4-0.9,2.3-0.9h30\r\n c0.9,0,1.9,0.2,2.9,0.7c1.1,0.4,1.9,1,2.5,1.6L71.4,30.7z M56.6,22.6v12.6h12.6c-0.2-0.6-0.5-1.1-0.7-1.4L57.9,23.3\r\n C57.7,23,57.2,22.8,56.6,22.6z M69.4,73.7V39.4H55.5c-0.9,0-1.7-0.3-2.3-0.9c-0.6-0.6-0.9-1.4-0.9-2.3V22.3H26.6v51.4H69.4z\r\n M65.1,58.7v10.7H30.9V63l6.4-6.4l4.3,4.3L54.4,48L65.1,58.7z M37.3,52.3c-1.8,0-3.3-0.6-4.6-1.9c-1.3-1.2-1.9-2.8-1.9-4.6\r\n c0-1.8,0.6-3.3,1.9-4.6c1.3-1.2,2.8-1.9,4.6-1.9s3.3,0.6,4.6,1.9c1.3,1.3,1.9,2.8,1.9,4.6c0,1.8-0.6,3.3-1.9,4.6\r\n C40.6,51.7,39.1,52.3,37.3,52.3z"/>\r\n </g>\r\n </svg>\r\n\r\n <svg *ngSwitchCase="isIcon(\'audio\')" viewBox="0 0 96 96">\r\n <g>\r\n <path d="M71.4,30.7c0.6,0.6,1.2,1.5,1.6,2.5c0.4,1.1,0.7,2.1,0.7,2.9v38.6c0,0.9-0.3,1.7-0.9,2.3\r\n S71.4,78,70.5,78h-45c-0.9,0-1.7-0.3-2.3-0.9c-0.6-0.6-0.9-1.4-0.9-2.3V21.2c0-0.9,0.3-1.7,0.9-2.3c0.6-0.6,1.4-0.9,2.3-0.9h30\r\n c0.9,0,1.9,0.2,2.9,0.7c1.1,0.4,1.9,1,2.5,1.6L71.4,30.7z M56.6,22.6v12.6h12.6c-0.2-0.6-0.5-1.1-0.7-1.4L57.9,23.3\r\n C57.7,23,57.2,22.8,56.6,22.6z M69.4,73.7V39.4H55.5c-0.9,0-1.7-0.3-2.3-0.9c-0.6-0.6-0.9-1.4-0.9-2.3V22.3H26.6v51.4H69.4z\r\n M43,46.5c0.4,0.2,0.7,0.5,0.7,1v18.2c0,0.5-0.2,0.8-0.7,1c-0.2,0-0.3,0.1-0.4,0.1c-0.3,0-0.5-0.1-0.8-0.3l-5.6-5.6h-4.4\r\n c-0.3,0-0.6-0.1-0.8-0.3c-0.2-0.2-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-0.9-1.4-0.9-2.3V21.2c0-0.9,0.3-1.7,0.9-2.3c0.6-0.6,1.4-0.9,2.3-0.9h30\r\n c0.9,0,1.9,0.2,2.9,0.7c1.1,0.4,1.9,1,2.5,1.6L71.4,30.7z M56.6,22.6v12.6h12.6c-0.2-0.6-0.5-1.1-0.7-1.4L57.9,23.3\r\n C57.7,23,57.2,22.8,56.6,22.6z M69.4,73.7V39.4H55.5c-0.9,0-1.7-0.3-2.3-0.9c-0.6-0.6-0.9-1.4-0.9-2.3V22.3H26.6v51.4H69.4z\r\n M48,43.7c1.2,0,2.2,0.4,3,1.3c0.8,0.8,1.3,1.9,1.3,3v12.9c0,1.2-0.4,2.2-1.3,3c-0.8,0.8-1.9,1.3-3,1.3H35.1c-1.2,0-2.2-0.4-3-1.3\r\n c-0.8-0.8-1.3-1.9-1.3-3V48c0-1.2,0.4-2.2,1.3-3c0.8-0.8,1.9-1.3,3-1.3H48z M64.5,43.8c0.4,0.2,0.7,0.5,0.7,1v19.3\r\n c0,0.5-0.2,0.8-0.7,1c-0.2,0-0.3,0.1-0.4,0.1c-0.3,0-0.6-0.1-0.8-0.3l-8.9-8.9v-3l8.9-8.9c0.2-0.2,0.5-0.3,0.8-0.3\r\n C64.2,43.7,64.3,43.7,64.5,43.8z"/>\r\n </g>\r\n </svg>\r\n\r\n</ng-container>',styles:[":host{display:block;border:1px solid #eaeaea;border-radius:4px}:host svg{fill:#909293}"]}]}],t.ctorParameters=function(){return[{type:h}]},t.propDecorators={file:[{type:o.Input}]},t}(),b=function(){function t(t,e,i,n){var o=this;this.fileUploadService=t,this.hostElementRef=e,this.renderer=i,this.document=n,this.control=null,this.templateRef=null,this.hooks=[],this.subscriptions=[],this.onTouch=function(){o.renderer.addClass(o.hostElementRef.nativeElement,g)}}return t.prototype.ngOnInit=function(){a(this.control)&&(this.control=new c)},t.prototype.ngAfterViewInit=function(){this.fileUploadService.isFileDragDropAvailable()&&(this.setEvents(),this.checkAndMarkAsDisabled())},t.prototype.ngOnDestroy=function(){this.hooks.forEach(function(t){return t()}),this.hooks.length=0,this.subscriptions.forEach(function(t){return t.unsubscribe()}),this.subscriptions.length=0},Object.defineProperty(t.prototype,"hasFiles",{get:function(){return this.control.isListVisible&&0<this.control.size},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"isInvalid",{get:function(){return!this.control.disabled&&this.control.invalid},enumerable:!0,configurable:!0}),t.prototype.setEvents=function(){var i=this;["drag","dragstart","dragend","dragover","dragenter","dragleave","drop"].forEach(function(t){i.hooks.push(i.renderer.listen(i.document,t,function(t){return i.preventDragEvents(t)}))}),["dragover","dragenter"].forEach(function(t){i.hooks.push(i.renderer.listen(i.hostElementRef.nativeElement,t,function(t){return i.onDragOver(t)}))}),["dragleave","dragend","drop"].forEach(function(e){i.hooks.push(i.renderer.listen(i.hostElementRef.nativeElement,e,function(t){(i.control.disabled&&"dragleave"===e||"dragleave"!==e)&&i.onDragLeave(t)}))}),["dragleave"].forEach(function(t){i.hooks.push(i.renderer.listen(i.overlay.nativeElement,t,function(t){return i.onDragLeave(t)}))}),this.subscriptions.push(this.control.statusChanges.subscribe(function(t){return i.checkAndMarkAsDisabled()}))},t.prototype.checkAndMarkAsDisabled=function(){this.control.disabled?this.renderer.addClass(this.hostElementRef.nativeElement,"disabled"):this.renderer.removeClass(this.hostElementRef.nativeElement,"disabled")},t.prototype.preventDragEvents=function(t){t.preventDefault(),t.stopPropagation()},t.prototype.onDragOver=function(t){this.renderer.addClass(this.hostElementRef.nativeElement,f)},t.prototype.onDragLeave=function(t){this.renderer.removeClass(this.hostElementRef.nativeElement,f)},t.prototype.onDrop=function(t){if(!this.control.disabled){var e=t.dataTransfer.files;this.control.addFiles(e),this.onTouch()}},t.decorators=[{type:o.Component,args:[{selector:"[file-drop-zone]",template:'\n <ng-content></ng-content>\n <div #overlay class="overlay" *ngIf="fileUploadService.isFileDragDropAvailable()">\n\n <div class="upload-input">\n <ng-container *ngTemplateOutlet="templateRef ? templateRef : defaultTemplate"></ng-container>\n\n <ng-template #defaultTemplate>\n <div class="icon">\n <svg viewBox="0 0 96 96">\n <g>\n <path d="M62.8,68.1c0-0.6-0.2-1.1-0.6-1.5c-0.4-0.4-0.9-0.6-1.5-0.6s-1.1,0.2-1.5,0.6\n c-0.4,0.4-0.6,0.9-0.6,1.5c0,0.6,0.2,1.1,0.6,1.5c0.4,0.4,0.9,0.6,1.5,0.6s1.1-0.2,1.5-0.6S62.8,68.7,62.8,68.1z M71.3,68.1\n c0-0.6-0.2-1.1-0.6-1.5c-0.4-0.4-0.9-0.6-1.5-0.6c-0.6,0-1.1,0.2-1.5,0.6C67.2,67,67,67.5,67,68.1c0,0.6,0.2,1.1,0.6,1.5\n s0.9,0.6,1.5,0.6c0.6,0,1.1-0.2,1.5-0.6C71.1,69.2,71.3,68.7,71.3,68.1z M75.5,60.7v10.6c0,0.9-0.3,1.6-0.9,2.2\n c-0.6,0.6-1.4,0.9-2.2,0.9H23.7c-0.9,0-1.6-0.3-2.2-0.9c-0.6-0.6-0.9-1.4-0.9-2.2V60.7c0-0.9,0.3-1.6,0.9-2.2\n c0.6-0.6,1.4-0.9,2.2-0.9h14.1c0.5,1.2,1.2,2.2,2.3,3c1.1,0.8,2.3,1.2,3.7,1.2h8.5c1.3,0,2.6-0.4,3.7-1.2c1.1-0.8,1.9-1.8,2.3-3\n h14.1c0.9,0,1.6,0.3,2.2,0.9C75.2,59.1,75.5,59.8,75.5,60.7z M64.8,39.3c-0.4,0.9-1,1.3-2,1.3h-8.5v14.8c0,0.6-0.2,1.1-0.6,1.5\n c-0.4,0.4-0.9,0.6-1.5,0.6h-8.5c-0.6,0-1.1-0.2-1.5-0.6c-0.4-0.4-0.6-0.9-0.6-1.5V40.6h-8.5c-0.9,0-1.6-0.4-2-1.3\n c-0.4-0.9-0.2-1.6,0.5-2.3l14.8-14.8c0.4-0.4,0.9-0.6,1.5-0.6s1.1,0.2,1.5,0.6L64.3,37C65,37.7,65.1,38.4,64.8,39.3z"/>\n </g>\n </svg>\n </div>\n \n <div class="upload-text">\n <b>Drop</b> it here\n </div>\n </ng-template>\n </div>\n </div>\n ',providers:[h],styles:[":host{position:relative;display:block}:host .overlay{display:none;background:rgba(255,255,255,.8);outline:#92b0b3 dashed 2px;outline-offset:-10px;position:absolute;top:0;left:0;right:0;bottom:0}:host(.dragover:not(.disabled)) .overlay{display:block}.icon{height:35px;width:35px;border:1px solid #eaeaea;border-radius:4px;margin:0 auto 10px}:host /deep/ .icon svg{fill:#80a9d2}.upload-input{pointer-events:none;cursor:pointer;display:inline-block;color:#80a9d2;position:absolute;top:50%;left:50%;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%);transition:.15s ease-in-out}"]}]}],t.ctorParameters=function(){return[{type:h},{type:o.ElementRef},{type:o.Renderer2},{type:undefined,decorators:[{type:o.Inject,args:[n.DOCUMENT]}]}]},t.propDecorators={control:[{type:o.Input}],overlay:[{type:o.ViewChild,args:["overlay"]}],templateRef:[{type:o.ContentChild,args:["placeholder"]}],hasFiles:[{type:o.HostBinding,args:["class.has-files"]}],isInvalid:[{type:o.HostBinding,args:["class.ng-invalid"]}],onDrop:[{type:o.HostListener,args:["drop",["$event"]]}]},t}(),x=function(t,e,i){return void 0===i&&(i=0),!a(e)&&t.size>e||t.size<i?{maxSize:e,minSize:i,actual:t.size,file:t}:null},z=/(^[.]\w*)$/m,C=function(t,e){var i,n,o="."+t.name.split(".").pop();try{for(var r=function l(t){var e="function"==typeof Symbol&&t[Symbol.iterator],i=0;return e?e.call(t):{next:function(){return t&&i>=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}}}(e),s=r.next();!s.done;s=r.next()){var a=s.value;if(z.test(a)?a===o:new RegExp(a).test(t.type))return null}}catch(c){i={error:c}}finally{try{s&&!s.done&&(n=r["return"])&&n.call(r)}finally{if(i)throw i.error}}return{allowedTypes:e,actual:t.type,file:t}},D=function(t){if(!Array.isArray(t))throw Error("FormControl.setValue was provided with wrong argument type, "+t+" was provided instead Array<File>")},E=function(){function t(){}return t.fileSize=function(n){return function(t){var e=t.value;if(a(e))return null;D(e);var i=e.map(function(t){return x(t,n)}).filter(function(t){return t});return 0<i.length?{fileSize:i}:null}},t.sizeRange=function(t){var n=t.minSize,o=t.maxSize;return function(t){var e=t.value;if(a(e))return null;D(e);var i=e.map(function(t){return x(t,o,n)}).filter(function(t){return t});return 0<i.length?{sizeRange:i}:null}},t.filesLimit=function(i){return function(t){var e=t.value;return a(e)?null:(D(e),e.length>i?{filesLimit:{max:i,actual:e.length}}:null)}},t.accept=function(n){return function(t){var e=t.value;if(a(e))return null;D(e);var i=e.map(function(t){return C(t,n)}).filter(function(t){return t});return console.log("notAllowedFiles",i),0<i.length?{fileTypes:i}:null}},t}(),V=function(){function t(){}return t.prototype.ngOnChanges=function(t){("filesize"in t||"maxsize"in t||"minsize"in t)&&(this._createValidator(),this.onChange&&this.onChange())},t.prototype.validate=function(t){return this.validator(t)},t.prototype.registerOnValidatorChange=function(t){this.onChange=t},t.prototype._createValidator=function(){var t=null;a(this.maxsize)?a(this.filesize)||(t="string"==typeof this.filesize?parseInt(this.filesize,10):this.filesize):t="string"==typeof this.maxsize?parseInt(this.maxsize,10):this.maxsize;var e="string"==typeof this.minsize?parseInt(this.minsize,10):this.minsize;this.validator=E.sizeRange({maxSize:t,minSize:e})},t.decorators=[{type:o.Directive,args:[{selector:"[filesize][formControlName],[filesize][formControl],[filesize][ngModel],\n [minsize][formControlName],[minsize][formControl],[minsize][ngModel],\n [maxsize][formControlName],[maxsize][formControl],[maxsize][ngModel]",providers:[{provide:r.NG_VALIDATORS,useExisting:o.forwardRef(function(){return t}),multi:!0}],host:{"[attr.filesize]":"filesize ? filesize : null","[attr.minsize]":"minsize ? minsize : null","[attr.maxsize]":"maxsize ? maxsize : null"}}]}],t.propDecorators={filesize:[{type:o.Input}],minsize:[{type:o.Input}],maxsize:[{type:o.Input}]},t}(),w=function(){function t(){}return t.prototype.ngOnChanges=function(t){"fileslimit"in t&&(this._createValidator(),this.onChange&&this.onChange())},t.prototype.validate=function(t){return null!=this.fileslimit?this.validator(t):null},t.prototype.registerOnValidatorChange=function(t){this.onChange=t},t.prototype._createValidator=function(){this.validator=E.filesLimit("string"==typeof this.fileslimit?parseInt(this.fileslimit,10):this.fileslimit)},t.decorators=[{type:o.Directive,args:[{selector:"[fileslimit][formControlName],[fileslimit][formControl],[fileslimit][ngModel]",providers:[{provide:r.NG_VALIDATORS,useExisting:o.forwardRef(function(){return t}),multi:!0}],host:{"[attr.fileslimit]":"fileslimit ? fileslimit : null"}}]}],t.propDecorators={fileslimit:[{type:o.Input}]},t}(),A=function(){function t(){}return t.prototype.ngOnChanges=function(t){"accept"in t&&(this._createValidator(),this.onChange&&this.onChange())},t.prototype.validate=function(t){return null!=this.accept?this.validator(t):null},t.prototype.registerOnValidatorChange=function(t){this.onChange=t},t.prototype._createValidator=function(){this.validator=E.accept(this.accept.split(","))},t.decorators=[{type:o.Directive,args:[{selector:"[accept][formControlName],[accept][formControl],[accept][ngModel]",providers:[{provide:r.NG_VALIDATORS,useExisting:o.forwardRef(function(){return w}),multi:!0}],host:{"[attr.accept]":"accept ? accept : null"}}]}],t.propDecorators={accept:[{type:o.Input}]},t}(),I=function(){function t(t){this.injector=t}return t.prototype.ngDoBootstrap=function(){},t.decorators=[{type:o.NgModule,args:[{imports:[n.CommonModule,r.ReactiveFormsModule,r.FormsModule],declarations:[v,m,y,b,V,w,A],exports:[v,b,V,w,A],entryComponents:[v]}]}],t.ctorParameters=function(){return[{type:o.Injector}]},t}();t.FileUploadControl=c,t.FileUploadValidators=E,t.FileUploadTypes=p,t.FileUploadModule=I,t.ɵd=u,t.ɵc=d,t.ɵg=b,t.ɵf=y,t.ɵe=m,t.ɵa=v,t.ɵh=V,t.ɵj=A,t.ɵi=w,t.ɵb=h,Object.defineProperty(t,"__esModule",{value:!0})});
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("rxjs"),require("@angular/animations"),require("@angular/common"),require("@angular/core"),require("@angular/forms")):"function"==typeof define&&define.amd?define("@iplab/ngx-file-upload",["exports","rxjs","@angular/animations","@angular/common","@angular/core","@angular/forms"],e):e((t.iplab=t.iplab||{},t.iplab["ngx-file-upload"]={}),t.rxjs,t.ng.animations,t.ng.common,t.ng.core,t.ng.forms)}(this,function(t,e,i,n,o,r){"use strict";function s(t,e){var i="function"==typeof Symbol&&t[Symbol.iterator];if(!i)return t;var n,o,r=i.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=r.next()).done;)s.push(n.value)}catch(a){o={error:a}}finally{try{n&&!n.done&&(i=r["return"])&&i.call(r)}finally{if(o)throw o.error}}return s}function a(t){return null==t||0===t.length}var l={INVALID:0,VALID:1,DISABLED:2};l[l.INVALID]="INVALID",l[l.VALID]="VALID",l[l.DISABLED]="DISABLED";var c=function(){function t(t){this.files=new Set,this.listVisible=!0,this.status=l.VALID,this.errors=[],this.validators=[],this.statusChanged=new e.Subject,this.statusChanges=this.statusChanged.asObservable(),this.valueChanges=new e.BehaviorSubject([]),this.listVisibilityChanges=new e.BehaviorSubject(this.listVisible),this.defineValidators(t)}return t.prototype.setValidators=function(t){return this.defineValidators(t),this.validate(),this},t.prototype.defineValidators=function(t){a(t)||(this.validators=Array.isArray(t)?function i(){for(var t=[],e=0;e<arguments.length;e++)t=t.concat(s(arguments[e]));return t}(t):[t])},t.prototype.addFile=function(t){return this.files.add(t),this.validate(),this.valueChanges.next(Array.from(this.files.values())),this},t.prototype.removeFile=function(t){return this.files["delete"](t),this.validate(),this.valueChanges.next(Array.from(this.files.values())),this},t.prototype.addFiles=function(t){return this.addMultipleFiles(Array.from(t)),this},t.prototype.addMultipleFiles=function(t){var e=this;t.forEach(function(t){return e.files.add(t)}),this.validate(),this.valueChanges.next(Array.from(this.files.values()))},Object.defineProperty(t.prototype,"valid",{get:function(){return 0===this.errors.length&&this.status!==l.DISABLED},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"invalid",{get:function(){return 0<this.errors.length||this.status===l.DISABLED},enumerable:!0,configurable:!0}),t.prototype.getError=function(){return this.errors},Object.defineProperty(t.prototype,"size",{get:function(){return this.files.size},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"value",{get:function(){return Array.from(this.files.values())},enumerable:!0,configurable:!0}),t.prototype.setValue=function(t){if(this.files.clear(),!(t instanceof Array))throw Error("FormControl.setValue was provided with wrong argument type, "+t+" was provided instead Array<File>");return this.addMultipleFiles(t),this},t.prototype.clear=function(){return this.files.clear(),this.validate(),this.valueChanges.next(Array.from(this.files.values())),this},Object.defineProperty(t.prototype,"isListVisible",{get:function(){return this.listVisible},enumerable:!0,configurable:!0}),t.prototype.setListVisibility=function(t){return void 0===t&&(t=!0),this.listVisible=t,this.listVisibilityChanges.next(this.listVisible),this},Object.defineProperty(t.prototype,"disabled",{get:function(){return this.status===l.DISABLED},enumerable:!0,configurable:!0}),t.prototype.enable=function(t){return void 0===t&&(t=!0),this.status=t?l.VALID:l.DISABLED,this.validate(),this.statusChanged.next(this.status),this},t.prototype.disable=function(t){return void 0===t&&(t=!0),this.status=t?l.DISABLED:l.VALID,this.validate(),this.statusChanged.next(this.status),this},t.prototype.validate=function(){var e=this;if(this.status!==l.DISABLED){var t=this.valid;this.errors=this.validators.map(function(t){return t(e)}).filter(function(t){return t}),t!==this.valid&&this.statusChanged.next(this.valid?l.VALID:l.INVALID)}else this.errors.length=0},t}(),p={aac:"audio/aac",abw:"application/x-abiword",arc:"application/octet-stream",avi:"video/x-msvideo",azw:"application/vnd.amazon.ebook",bin:"application/octet-stream",bmp:"image/bmp",bz:"application/x-bzip",bz2:"application/x-bzip2",csh:"application/x-csh",css:"text/css",csv:"text/csv",doc:"application/msword",docx:"application/vnd.openxmlformats-officedocument.wordprocessingml.document",eot:"application/vnd.ms-fontobject",epub:"application/epub+zip",es:"application/ecmascript",gif:"image/gif",html:"text/html",ico:"image/x-icon",ics:"text/calendar",jar:"application/java-archive",jpg:"image/jpeg",js:"application/javascript",json:"application/json",midi:"audio/midi",mpeg:"video/mpeg",mpkg:"application/vnd.apple.installer+xml",odp:"application/vnd.oasis.opendocument.presentation",ods:"application/vnd.oasis.opendocument.spreadsheet",odt:"application/vnd.oasis.opendocument.text",oga:"audio/ogg",ogv:"video/ogg",ogx:"application/ogg",otf:"font/otf",png:"image/png",pdf:"application/pdf",ppt:"application/vnd.ms-powerpoint",pptx:"application/vnd.openxmlformats-officedocument.presentationml.presentation",rar:"application/vnd.openxmlformats-officedocument.presentationml.presentation",rtf:"application/rtf",sh:"application/x-sh",svg:"image/svg+xml",swf:"application/x-shockwave-flash",tar:"application/x-tar",tiff:"image/tiff",ts:"application/typescript",ttf:"font/ttf",vsd:"application/vnd.visio",wav:"audio/wav",weba:"audio/webm",webm:"video/webm",webp:"image/webp",woff:"font/woff",woff2:"font/woff2",xhtml:"application/xhtml+xml",xls:"application/vnd.ms-excel",xlsx:"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",xml:"application/xml",xul:"application/vnd.mozilla.xul+xml",zip:"application/zip","3gp":"video/3gpp","3g2":"video/3gpp2","7z":"application/x-7z-compressed"},h=function(){function t(t){this.renderer=t,this.extensions=["bytes","KB","MB","GB"]}return t.prototype.isFileDragDropAvailable=function(){var t=this.renderer.createElement("div");return("draggable"in t||"ondragstart"in t&&"ondrop"in t)&&FormData&&!!FileReader},t.prototype.calculateSize=function(t,e){return void 0===e&&(e=0),isNaN(t)&&(t=0),t<1024?Math.round(100*t)/100+" "+this.extensions[e]:this.calculateSize(t/1024,e+1)},t.prototype.getFileType=function(e){return Object.keys(p).find(function(t){return p[t]===e.type})},t.decorators=[{type:o.Injectable}],t.ctorParameters=function(){return[{type:o.Renderer2}]},t}(),u=i.trigger("insertAnimation",[i.transition("* => *",[i.query(":leave",[i.stagger(30,[i.animate(".3s",i.style({opacity:0}))])],{optional:!0}),i.query(":enter",[i.style({opacity:0}),i.stagger(30,[i.animate(".3s",i.style({opacity:1}))])],{optional:!0})])]),d=i.trigger("zoomAnimation",[i.transition("static => zoomOut",[i.animate(250,i.style({transform:"translate(-50%, -50%) scale(2, 2)",opacity:0}))]),i.transition("static => zoomIn",[i.query(":self",[i.style({transform:"translate(-50%, -50%) scale(.2, .2)",opacity:0,top:"50%",left:"50%",margin:0}),i.stagger(50,[i.animate(250,i.style({transform:"translate(-50%, -50%) scale(1, 1)",opacity:1}))])])])]),f="dragover",g="ng-touched",v=function(){function t(t,e,i,n,o){var r=this;this.fileUploadService=t,this.hostElementRef=e,this.renderer=i,this.document=n,this.cdr=o,this.control=null,this.templateRef=null,this.listItem=null,this.templateContext={$implicit:this.fileUploadService.isFileDragDropAvailable(),isFileDragDropAvailable:this.fileUploadService.isFileDragDropAvailable()},this.zoomText="static",this.listVisible=!1,this.hooks=[],this.subscriptions=[],this.onChange=function(){},this.onTouch=function(){r.renderer.addClass(r.hostElementRef.nativeElement,g)}}return t.prototype.ngOnInit=function(){a(this.control)&&(this.control=new c),this.setEvents(),this.checkAndMarkAsDisabled(),this.connectToForm()},t.prototype.ngOnDestroy=function(){this.cdr.detach(),this.hooks.forEach(function(t){return t()}),this.hooks.length=0,this.subscriptions.forEach(function(t){return t.unsubscribe()}),this.subscriptions.length=0},Object.defineProperty(t.prototype,"hasFiles",{get:function(){return this.control.isListVisible&&0<this.control.size},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"isInvalid",{get:function(){return!this.control.disabled&&this.control.invalid},enumerable:!0,configurable:!0}),t.prototype.setEvents=function(){var e=this;["drag","dragstart","dragend","dragover","dragenter","dragleave","drop"].forEach(function(t){e.hooks.push(e.renderer.listen(e.document,t,function(t){return e.preventDragEvents(t)}))}),["dragover","dragenter"].forEach(function(t){e.hooks.push(e.renderer.listen(e.hostElementRef.nativeElement,t,function(t){return e.onDragOver(t)}))}),["dragleave","dragend","drop"].forEach(function(t){e.hooks.push(e.renderer.listen(e.hostElementRef.nativeElement,t,function(t){return e.onDragLeave(t)}))}),this.subscriptions.push(this.control.statusChanges.subscribe(function(t){return e.checkAndMarkAsDisabled()})),this.subscriptions.push(this.control.valueChanges.subscribe(function(t){return e.renderView()})),this.subscriptions.push(this.control.listVisibilityChanges.subscribe(function(t){return e.toggleListVisibility()}))},t.prototype.checkAndMarkAsDisabled=function(){this.control.disabled?(this.renderer.addClass(this.hostElementRef.nativeElement,"disabled"),this.renderer.setProperty(this.input.nativeElement,"disabled",!0)):(this.renderer.removeClass(this.hostElementRef.nativeElement,"disabled"),this.renderer.setProperty(this.input.nativeElement,"disabled",!1))},t.prototype.preventDragEvents=function(t){t.preventDefault(),t.stopPropagation()},t.prototype.renderView=function(){this.listVisible||(this.zoomText=this.control.isListVisible&&0<this.control.size?"zoomOut":"static"),this.cdr.markForCheck()},t.prototype.showList=function(){"static"!==this.zoomText&&(this.listVisible=!0)},t.prototype.hideList=function(){this.listVisible=!1},t.prototype.toggleListVisibility=function(){this.listVisible=this.control.isListVisible&&0<this.control.size,this.listVisible&&(this.renderer.addClass(this.hostElementRef.nativeElement,"list-visible"),this.zoomText="static"),this.cdr.markForCheck()},t.prototype.onDragOver=function(t){this.renderer.addClass(this.hostElementRef.nativeElement,f)},t.prototype.onDragLeave=function(t){this.renderer.removeClass(this.hostElementRef.nativeElement,f)},t.prototype.onDrop=function(t){if(!this.control.disabled){var e=t.dataTransfer.files;this.control.addFiles(e),this.onTouch()}},t.prototype.onInputChange=function(t){var e=t.target;this.control.disabled||this.control.addFiles(e.files),this.clearInputEl(),this.onTouch()},t.prototype.clearInputEl=function(){this.input.nativeElement.value=null},t.prototype.connectToForm=function(){var e=this;this.subscriptions.push(this.control.valueChanges.subscribe(function(t){return e.onChange(t)}))},t.prototype.writeValue=function(t){null!=t&&this.control.setValue(t)},t.prototype.registerOnChange=function(t){this.onChange=t},t.prototype.registerOnTouched=function(t){this.onTouch=t},t.prototype.setDisabledState=function(t){this.control.disable(t)},t.prototype.zoomAnimationDone=function(t){this.control.isListVisible&&0<this.control.size?this.showList():this.hideList(),"static"===t.fromState&&"zoomOut"===t.toState?this.renderer.addClass(this.hostElementRef.nativeElement,"hide-text"):this.renderer.removeClass(this.hostElementRef.nativeElement,"hide-text"),"zoomIn"===t.toState&&(this.zoomText="static")},t.prototype.animationListFinished=function(t){"void"===t.toState&&(this.zoomText="zoomIn",this.renderer.removeClass(this.hostElementRef.nativeElement,"list-visible")),"void"===t.fromState&&(this.zoomText="static",this.renderer.addClass(this.hostElementRef.nativeElement,"list-visible"))},t.decorators=[{type:o.Component,args:[{selector:"file-upload",template:'<label class="upload-input" [@zoomAnimation]="zoomText" (@zoomAnimation.done)="zoomAnimationDone($event)">\r\n\r\n <ng-container *ngTemplateOutlet="templateRef ? templateRef : defaultTemplate; context: templateContext"></ng-container>\r\n\r\n <ng-template #defaultTemplate let-isFileDragDropAvailable="isFileDragDropAvailable">\r\n <div class="icon">\r\n <svg viewBox="0 0 96 96">\r\n <g>\r\n <path d="M62.8,68.1c0-0.6-0.2-1.1-0.6-1.5c-0.4-0.4-0.9-0.6-1.5-0.6s-1.1,0.2-1.5,0.6\r\n c-0.4,0.4-0.6,0.9-0.6,1.5c0,0.6,0.2,1.1,0.6,1.5c0.4,0.4,0.9,0.6,1.5,0.6s1.1-0.2,1.5-0.6S62.8,68.7,62.8,68.1z M71.3,68.1\r\n c0-0.6-0.2-1.1-0.6-1.5c-0.4-0.4-0.9-0.6-1.5-0.6c-0.6,0-1.1,0.2-1.5,0.6C67.2,67,67,67.5,67,68.1c0,0.6,0.2,1.1,0.6,1.5\r\n s0.9,0.6,1.5,0.6c0.6,0,1.1-0.2,1.5-0.6C71.1,69.2,71.3,68.7,71.3,68.1z M75.5,60.7v10.6c0,0.9-0.3,1.6-0.9,2.2\r\n c-0.6,0.6-1.4,0.9-2.2,0.9H23.7c-0.9,0-1.6-0.3-2.2-0.9c-0.6-0.6-0.9-1.4-0.9-2.2V60.7c0-0.9,0.3-1.6,0.9-2.2\r\n c0.6-0.6,1.4-0.9,2.2-0.9h14.1c0.5,1.2,1.2,2.2,2.3,3c1.1,0.8,2.3,1.2,3.7,1.2h8.5c1.3,0,2.6-0.4,3.7-1.2c1.1-0.8,1.9-1.8,2.3-3\r\n h14.1c0.9,0,1.6,0.3,2.2,0.9C75.2,59.1,75.5,59.8,75.5,60.7z M64.8,39.3c-0.4,0.9-1,1.3-2,1.3h-8.5v14.8c0,0.6-0.2,1.1-0.6,1.5\r\n c-0.4,0.4-0.9,0.6-1.5,0.6h-8.5c-0.6,0-1.1-0.2-1.5-0.6c-0.4-0.4-0.6-0.9-0.6-1.5V40.6h-8.5c-0.9,0-1.6-0.4-2-1.3\r\n c-0.4-0.9-0.2-1.6,0.5-2.3l14.8-14.8c0.4-0.4,0.9-0.6,1.5-0.6s1.1,0.2,1.5,0.6L64.3,37C65,37.7,65.1,38.4,64.8,39.3z"/>\r\n </g>\r\n </svg>\r\n </div>\r\n \r\n <div class="upload-text">\r\n <ng-container *ngIf="isFileDragDropAvailable; else isNotDragDropAvailable">\r\n <b>Drag and drop</b> files<br> or click here\r\n </ng-container>\r\n <ng-template #isNotDragDropAvailable>\r\n <b>Click here</b> to<br> choose a files\r\n </ng-template>\r\n </div>\r\n </ng-template>\r\n\r\n <input #inputRef type="file" class="files-input" multiple (change)="onInputChange($event)">\r\n</label>\r\n\r\n<div class="upload-list" *ngIf="(control.listVisibilityChanges | async) && control.size > 0 && listVisible" [@insertAnimation]="control.size" (@insertAnimation.done)="animationListFinished($event)">\r\n <ng-template ngFor let-file let-i="index" [ngForOf]="control.valueChanges | async">\r\n <ng-container *ngTemplateOutlet="listItem ? listItem : defaultItemTemplate; context: { $implicit: file, file: file, index: i, control: control }"></ng-container>\r\n </ng-template>\r\n \r\n <ng-template #defaultItemTemplate let-i="index" let-file="file" let-control="control">\r\n <file-upload-list-item [index]="i" [file]="file" [control]="control"></file-upload-list-item>\r\n </ng-template>\r\n</div>',providers:[h,{provide:r.NG_VALUE_ACCESSOR,useExisting:o.forwardRef(function(){return t}),multi:!0}],changeDetection:o.ChangeDetectionStrategy.OnPush,animations:[d,u],styles:[':host,:host>*{box-sizing:border-box}:host{overflow:hidden;display:block;background:#fafafa;padding:20px 66px 20px 20px;min-height:140px;outline:#92b0b3 dashed 1px;outline-offset:-10px;position:relative}:host(.dragover){outline-width:2px}:host(.disabled){opacity:.5;cursor:no-drop}.files-input{width:.1px;height:.1px;opacity:0;position:absolute;left:-100%;top:-100%;overflow:hidden}.icon{height:35px;width:35px;border:1px solid #eaeaea;border-radius:4px;float:left}.icon svg{fill:#909293}.upload-input:after{clear:both;content:"\\0A0";display:block;height:0;line-height:0;visibility:hidden;zoom:1}.upload-input{cursor:pointer;display:inline-block;color:#646464;position:absolute;top:50%;left:50%;margin:0;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%)}:host(.disabled) .upload-input{cursor:not-allowed}:host(.list-visible) .upload-input{top:20px;left:100%;margin-left:-20px;-webkit-transform:translate(-100%,0);transform:translate(-100%,0);text-align:center}.upload-text{overflow:hidden;width:auto;position:relative;padding-left:20px}:host(.hide-text) .upload-input{opacity:0}:host(.list-visible) .upload-text{display:none}:host(.dragover:not(.disabled)) .upload-input,:host(:not(.disabled)) .upload-input:hover{color:#80a9d2}:host(.dragover:not(.disabled)) .icon svg,:host(:not(.disabled)) .upload-input:hover svg{fill:#80a9d2}file-upload-list-item{padding:10px 0 0}file-upload-list-item:first-child{padding:0}']}]}],t.ctorParameters=function(){return[{type:h},{type:o.ElementRef},{type:o.Renderer2},{type:undefined,decorators:[{type:o.Inject,args:[n.DOCUMENT]}]},{type:o.ChangeDetectorRef}]},t.propDecorators={control:[{type:o.Input}],templateRef:[{type:o.ContentChild,args:["placeholder"]}],listItem:[{type:o.ContentChild,args:["item"]}],input:[{type:o.ViewChild,args:["inputRef"]}],hasFiles:[{type:o.HostBinding,args:["class.has-files"]}],isInvalid:[{type:o.HostBinding,args:["class.ng-invalid"]}],onDrop:[{type:o.HostListener,args:["drop",["$event"]]}]},t}(),m=function(){function t(t){this.fileUploadService=t}return t.prototype.removeFile=function(t){this.control.removeFile(t)},t.prototype.calculateSize=function(t){return this.fileUploadService.calculateSize(t)},t.decorators=[{type:o.Component,args:[{selector:"file-upload-list-item",template:'\n <file-upload-icon [file]="file"></file-upload-icon>\n <div class="file-info">\n <span class="file-name">{{ file.name }}</span> ({{ calculateSize( file.size ) }})\n </div>\n <div class="file-buttons">\n <span class="remove-btn" (click)="removeFile(file)">\n <svg viewBox="0 0 96 96">\n <g>\n <path d="M40.5,66.8V39.3c0-0.4-0.1-0.7-0.4-0.9S39.6,38,39.3,38h-2.5c-0.4,0-0.7,0.1-0.9,0.4\n s-0.4,0.5-0.4,0.9v27.5c0,0.4,0.1,0.7,0.4,0.9s0.5,0.4,0.9,0.4h2.5c0.4,0,0.7-0.1,0.9-0.4S40.5,67.1,40.5,66.8z M50.5,66.8V39.3\n c0-0.4-0.1-0.7-0.4-0.9S49.6,38,49.3,38h-2.5c-0.4,0-0.7,0.1-0.9,0.4s-0.4,0.5-0.4,0.9v27.5c0,0.4,0.1,0.7,0.4,0.9s0.5,0.4,0.9,0.4\n h2.5c0.4,0,0.7-0.1,0.9-0.4S50.5,67.1,50.5,66.8z M60.5,66.8V39.3c0-0.4-0.1-0.7-0.4-0.9S59.6,38,59.3,38h-2.5\n c-0.4,0-0.7,0.1-0.9,0.4s-0.4,0.5-0.4,0.9v27.5c0,0.4,0.1,0.7,0.4,0.9s0.5,0.4,0.9,0.4h2.5c0.4,0,0.7-0.1,0.9-0.4\n S60.5,67.1,60.5,66.8z M39.3,28h17.5l-1.9-4.6c-0.2-0.2-0.4-0.4-0.7-0.4H41.8c-0.3,0.1-0.5,0.2-0.7,0.4L39.3,28z M75.5,29.3v2.5\n c0,0.4-0.1,0.7-0.4,0.9S74.6,33,74.3,33h-3.8v37c0,2.2-0.6,4-1.8,5.6S66,78,64.3,78H31.8c-1.7,0-3.2-0.8-4.4-2.3s-1.8-3.4-1.8-5.5\n V33h-3.8c-0.4,0-0.7-0.1-0.9-0.4s-0.4-0.5-0.4-0.9v-2.5c0-0.4,0.1-0.7,0.4-0.9s0.5-0.4,0.9-0.4h12.1l2.7-6.5c0.4-1,1.1-1.8,2.1-2.5\n s2-1,3.1-1h12.5c1,0,2.1,0.3,3.1,1s1.7,1.5,2.1,2.5l2.7,6.5h12.1c0.4,0,0.7,0.1,0.9,0.4S75.5,28.9,75.5,29.3z"/>\n </g>\n </svg> Remove</span>\n </div>\n ',styles:[':host{display:block;font-size:14px;color:#646464}:host:after{clear:both;content:"\\0A0";display:block;height:0;line-height:0;visibility:hidden;zoom:1}file-upload-icon{float:left;width:30px;height:36px;margin:0 10px 0 0}.remove-btn{font-size:12px;cursor:pointer}.remove-btn svg{display:inline-block;vertical-align:-20%;height:18px;width:18px}']}]}],t.ctorParameters=function(){return[{type:h}]},t.propDecorators={index:[{type:o.Input}],file:[{type:o.Input}],control:[{type:o.Input}]},t}(),y=function(){function t(t){this.fileUploadService=t,this.fileType="unknown"}return t.prototype.ngOnInit=function(){this.fileType=this.fileUploadService.getFileType(this.file)},t.prototype.isIcon=function(t){switch(t){case"text":return"html"===this.fileType||"css"===this.fileType||"csv"===this.fileType||"js"===this.fileType||"pdf"===this.fileType||"ppt"===this.fileType||"xls"===this.fileType||"xlsx"===this.fileType||"xml"===this.fileType||"doc"===this.fileType||"docx"===this.fileType;case"audio":return"aac"===this.fileType||"midi"===this.fileType||"oga"===this.fileType||"wav"===this.fileType||"weba"===this.fileType;case"image":return"png"===this.fileType||"bmp"===this.fileType||"gif"===this.fileType||"jpg"===this.fileType||"svg"===this.fileType||"webp"===this.fileType||"ico"===this.fileType;case"video":return"avi"===this.fileType||"mpeg"===this.fileType||"ogv"===this.fileType||"webm"===this.fileType||"3gp"===this.fileType||"3g2"===this.fileType}},t.decorators=[{type:o.Component,args:[{selector:"file-upload-icon",template:'\r\n\r\n<ng-container [ngSwitch]="true">\r\n\r\n <svg *ngSwitchDefault viewBox="0 0 96 96">\r\n <g>\r\n <path d="M71.4,30.7c0.6,0.6,1.2,1.5,1.6,2.5c0.4,1.1,0.7,2.1,0.7,2.9v38.6c0,0.9-0.3,1.7-0.9,2.3\r\n S71.4,78,70.5,78h-45c-0.9,0-1.7-0.3-2.3-0.9c-0.6-0.6-0.9-1.4-0.9-2.3V21.2c0-0.9,0.3-1.7,0.9-2.3c0.6-0.6,1.4-0.9,2.3-0.9h30\r\n c0.9,0,1.9,0.2,2.9,0.7c1.1,0.4,1.9,1,2.5,1.6L71.4,30.7z M56.6,22.6v12.6h12.6c-0.2-0.6-0.5-1.1-0.7-1.4L57.9,23.3\r\n C57.7,23,57.2,22.8,56.6,22.6z M69.4,73.7V39.4H55.5c-0.9,0-1.7-0.3-2.3-0.9c-0.6-0.6-0.9-1.4-0.9-2.3V22.3H26.6v51.4H69.4z"/>\r\n </g>\r\n </svg>\r\n\r\n <svg *ngSwitchCase="isIcon(\'image\')" viewBox="0 0 96 96">\r\n <g>\r\n <path d="M71.4,30.7c0.6,0.6,1.2,1.5,1.6,2.5c0.4,1.1,0.7,2.1,0.7,2.9v38.6c0,0.9-0.3,1.7-0.9,2.3\r\n S71.4,78,70.5,78h-45c-0.9,0-1.7-0.3-2.3-0.9c-0.6-0.6-0.9-1.4-0.9-2.3V21.2c0-0.9,0.3-1.7,0.9-2.3c0.6-0.6,1.4-0.9,2.3-0.9h30\r\n c0.9,0,1.9,0.2,2.9,0.7c1.1,0.4,1.9,1,2.5,1.6L71.4,30.7z M56.6,22.6v12.6h12.6c-0.2-0.6-0.5-1.1-0.7-1.4L57.9,23.3\r\n C57.7,23,57.2,22.8,56.6,22.6z M69.4,73.7V39.4H55.5c-0.9,0-1.7-0.3-2.3-0.9c-0.6-0.6-0.9-1.4-0.9-2.3V22.3H26.6v51.4H69.4z\r\n M65.1,58.7v10.7H30.9V63l6.4-6.4l4.3,4.3L54.4,48L65.1,58.7z M37.3,52.3c-1.8,0-3.3-0.6-4.6-1.9c-1.3-1.2-1.9-2.8-1.9-4.6\r\n c0-1.8,0.6-3.3,1.9-4.6c1.3-1.2,2.8-1.9,4.6-1.9s3.3,0.6,4.6,1.9c1.3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,3,1.3c0.8,0.8,1.3,1.9,1.3,3v12.9c0,1.2-0.4,2.2-1.3,3c-0.8,0.8-1.9,1.3-3,1.3H35.1c-1.2,0-2.2-0.4-3-1.3\r\n c-0.8-0.8-1.3-1.9-1.3-3V48c0-1.2,0.4-2.2,1.3-3c0.8-0.8,1.9-1.3,3-1.3H48z M64.5,43.8c0.4,0.2,0.7,0.5,0.7,1v19.3\r\n c0,0.5-0.2,0.8-0.7,1c-0.2,0-0.3,0.1-0.4,0.1c-0.3,0-0.6-0.1-0.8-0.3l-8.9-8.9v-3l8.9-8.9c0.2-0.2,0.5-0.3,0.8-0.3\r\n C64.2,43.7,64.3,43.7,64.5,43.8z"/>\r\n </g>\r\n </svg>\r\n\r\n</ng-container>',styles:[":host{display:block;border:1px solid #eaeaea;border-radius:4px}:host svg{fill:#909293}"]}]}],t.ctorParameters=function(){return[{type:h}]},t.propDecorators={file:[{type:o.Input}]},t}(),b=function(){function t(t,e,i,n){var o=this;this.fileUploadService=t,this.hostElementRef=e,this.renderer=i,this.document=n,this.control=null,this.templateRef=null,this.hooks=[],this.subscriptions=[],this.onTouch=function(){o.renderer.addClass(o.hostElementRef.nativeElement,g)}}return t.prototype.ngOnInit=function(){a(this.control)&&(this.control=new c)},t.prototype.ngAfterViewInit=function(){this.fileUploadService.isFileDragDropAvailable()&&(this.setEvents(),this.checkAndMarkAsDisabled())},t.prototype.ngOnDestroy=function(){this.hooks.forEach(function(t){return t()}),this.hooks.length=0,this.subscriptions.forEach(function(t){return t.unsubscribe()}),this.subscriptions.length=0},Object.defineProperty(t.prototype,"hasFiles",{get:function(){return this.control.isListVisible&&0<this.control.size},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"isInvalid",{get:function(){return!this.control.disabled&&this.control.invalid},enumerable:!0,configurable:!0}),t.prototype.setEvents=function(){var i=this;["drag","dragstart","dragend","dragover","dragenter","dragleave","drop"].forEach(function(t){i.hooks.push(i.renderer.listen(i.document,t,function(t){return i.preventDragEvents(t)}))}),["dragover","dragenter"].forEach(function(t){i.hooks.push(i.renderer.listen(i.hostElementRef.nativeElement,t,function(t){return i.onDragOver(t)}))}),["dragleave","dragend","drop"].forEach(function(e){i.hooks.push(i.renderer.listen(i.hostElementRef.nativeElement,e,function(t){(i.control.disabled&&"dragleave"===e||"dragleave"!==e)&&i.onDragLeave(t)}))}),["dragleave"].forEach(function(t){i.hooks.push(i.renderer.listen(i.overlay.nativeElement,t,function(t){return i.onDragLeave(t)}))}),this.subscriptions.push(this.control.statusChanges.subscribe(function(t){return i.checkAndMarkAsDisabled()}))},t.prototype.checkAndMarkAsDisabled=function(){this.control.disabled?this.renderer.addClass(this.hostElementRef.nativeElement,"disabled"):this.renderer.removeClass(this.hostElementRef.nativeElement,"disabled")},t.prototype.preventDragEvents=function(t){t.preventDefault(),t.stopPropagation()},t.prototype.onDragOver=function(t){this.renderer.addClass(this.hostElementRef.nativeElement,f)},t.prototype.onDragLeave=function(t){this.renderer.removeClass(this.hostElementRef.nativeElement,f)},t.prototype.onDrop=function(t){if(!this.control.disabled){var e=t.dataTransfer.files;this.control.addFiles(e),this.onTouch()}},t.decorators=[{type:o.Component,args:[{selector:"[file-drop-zone]",template:'\n <ng-content></ng-content>\n <div #overlay class="overlay" *ngIf="fileUploadService.isFileDragDropAvailable()">\n\n <div class="upload-input">\n <ng-container *ngTemplateOutlet="templateRef ? templateRef : defaultTemplate"></ng-container>\n\n <ng-template #defaultTemplate>\n <div class="icon">\n <svg viewBox="0 0 96 96">\n <g>\n <path d="M62.8,68.1c0-0.6-0.2-1.1-0.6-1.5c-0.4-0.4-0.9-0.6-1.5-0.6s-1.1,0.2-1.5,0.6\n c-0.4,0.4-0.6,0.9-0.6,1.5c0,0.6,0.2,1.1,0.6,1.5c0.4,0.4,0.9,0.6,1.5,0.6s1.1-0.2,1.5-0.6S62.8,68.7,62.8,68.1z M71.3,68.1\n c0-0.6-0.2-1.1-0.6-1.5c-0.4-0.4-0.9-0.6-1.5-0.6c-0.6,0-1.1,0.2-1.5,0.6C67.2,67,67,67.5,67,68.1c0,0.6,0.2,1.1,0.6,1.5\n s0.9,0.6,1.5,0.6c0.6,0,1.1-0.2,1.5-0.6C71.1,69.2,71.3,68.7,71.3,68.1z M75.5,60.7v10.6c0,0.9-0.3,1.6-0.9,2.2\n c-0.6,0.6-1.4,0.9-2.2,0.9H23.7c-0.9,0-1.6-0.3-2.2-0.9c-0.6-0.6-0.9-1.4-0.9-2.2V60.7c0-0.9,0.3-1.6,0.9-2.2\n c0.6-0.6,1.4-0.9,2.2-0.9h14.1c0.5,1.2,1.2,2.2,2.3,3c1.1,0.8,2.3,1.2,3.7,1.2h8.5c1.3,0,2.6-0.4,3.7-1.2c1.1-0.8,1.9-1.8,2.3-3\n h14.1c0.9,0,1.6,0.3,2.2,0.9C75.2,59.1,75.5,59.8,75.5,60.7z M64.8,39.3c-0.4,0.9-1,1.3-2,1.3h-8.5v14.8c0,0.6-0.2,1.1-0.6,1.5\n c-0.4,0.4-0.9,0.6-1.5,0.6h-8.5c-0.6,0-1.1-0.2-1.5-0.6c-0.4-0.4-0.6-0.9-0.6-1.5V40.6h-8.5c-0.9,0-1.6-0.4-2-1.3\n c-0.4-0.9-0.2-1.6,0.5-2.3l14.8-14.8c0.4-0.4,0.9-0.6,1.5-0.6s1.1,0.2,1.5,0.6L64.3,37C65,37.7,65.1,38.4,64.8,39.3z"/>\n </g>\n </svg>\n </div>\n \n <div class="upload-text">\n <b>Drop</b> it here\n </div>\n </ng-template>\n </div>\n </div>\n ',providers:[h],styles:[":host{position:relative;display:block}:host .overlay{display:none;background:rgba(255,255,255,.8);outline:#92b0b3 dashed 2px;outline-offset:-10px;position:absolute;top:0;left:0;right:0;bottom:0}:host(.dragover:not(.disabled)) .overlay{display:block}.icon{height:35px;width:35px;border:1px solid #eaeaea;border-radius:4px;margin:0 auto 10px}:host /deep/ .icon svg{fill:#80a9d2}.upload-input{pointer-events:none;cursor:pointer;display:inline-block;color:#80a9d2;position:absolute;top:50%;left:50%;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%);transition:.15s ease-in-out}"]}]}],t.ctorParameters=function(){return[{type:h},{type:o.ElementRef},{type:o.Renderer2},{type:undefined,decorators:[{type:o.Inject,args:[n.DOCUMENT]}]}]},t.propDecorators={control:[{type:o.Input}],overlay:[{type:o.ViewChild,args:["overlay"]}],templateRef:[{type:o.ContentChild,args:["placeholder"]}],hasFiles:[{type:o.HostBinding,args:["class.has-files"]}],isInvalid:[{type:o.HostBinding,args:["class.ng-invalid"]}],onDrop:[{type:o.HostListener,args:["drop",["$event"]]}]},t}(),x=function(t,e,i){return void 0===i&&(i=0),!a(e)&&t.size>e||t.size<i?{maxSize:e,minSize:i,actual:t.size,file:t}:null},z=/(^[.]\w*)$/m,C=function(t,e){var i,n,o="."+t.name.split(".").pop();try{for(var r=function l(t){var e="function"==typeof Symbol&&t[Symbol.iterator],i=0;return e?e.call(t):{next:function(){return t&&i>=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}}}(e),s=r.next();!s.done;s=r.next()){var a=s.value;if(z.test(a)?a===o:new RegExp(a).test(t.type))return null}}catch(c){i={error:c}}finally{try{s&&!s.done&&(n=r["return"])&&n.call(r)}finally{if(i)throw i.error}}return{allowedTypes:e,actual:t.type,file:t}},D=function(t){if(!Array.isArray(t))throw Error("FormControl.setValue was provided with wrong argument type, "+t+" was provided instead Array<File>")},E=function(){function t(){}return t.fileSize=function(n){return function(t){var e=t.value;if(a(e))return null;D(e);var i=e.map(function(t){return x(t,n)}).filter(function(t){return t});return 0<i.length?{fileSize:i}:null}},t.sizeRange=function(t){var n=t.minSize,o=t.maxSize;return function(t){var e=t.value;if(a(e))return null;D(e);var i=e.map(function(t){return x(t,o,n)}).filter(function(t){return t});return 0<i.length?{sizeRange:i}:null}},t.filesLimit=function(i){return function(t){var e=t.value;return a(e)?null:(D(e),e.length>i?{filesLimit:{max:i,actual:e.length}}:null)}},t.accept=function(n){return function(t){var e=t.value;if(a(e))return null;D(e);var i=e.map(function(t){return C(t,n)}).filter(function(t){return t});return 0<i.length?{fileTypes:i}:null}},t}(),V=function(){function t(){}return t.prototype.ngOnChanges=function(t){("filesize"in t||"maxsize"in t||"minsize"in t)&&(this._createValidator(),this.onChange&&this.onChange())},t.prototype.validate=function(t){return this.validator(t)},t.prototype.registerOnValidatorChange=function(t){this.onChange=t},t.prototype._createValidator=function(){var t=null;a(this.maxsize)?a(this.filesize)||(t="string"==typeof this.filesize?parseInt(this.filesize,10):this.filesize):t="string"==typeof this.maxsize?parseInt(this.maxsize,10):this.maxsize;var e="string"==typeof this.minsize?parseInt(this.minsize,10):this.minsize;this.validator=E.sizeRange({maxSize:t,minSize:e})},t.decorators=[{type:o.Directive,args:[{selector:"[filesize][formControlName],[filesize][formControl],[filesize][ngModel],\n [minsize][formControlName],[minsize][formControl],[minsize][ngModel],\n [maxsize][formControlName],[maxsize][formControl],[maxsize][ngModel]",providers:[{provide:r.NG_VALIDATORS,useExisting:o.forwardRef(function(){return t}),multi:!0}],host:{"[attr.filesize]":"filesize ? filesize : null","[attr.minsize]":"minsize ? minsize : null","[attr.maxsize]":"maxsize ? maxsize : null"}}]}],t.propDecorators={filesize:[{type:o.Input}],minsize:[{type:o.Input}],maxsize:[{type:o.Input}]},t}(),w=function(){function t(){}return t.prototype.ngOnChanges=function(t){"fileslimit"in t&&(this._createValidator(),this.onChange&&this.onChange())},t.prototype.validate=function(t){return null!=this.fileslimit?this.validator(t):null},t.prototype.registerOnValidatorChange=function(t){this.onChange=t},t.prototype._createValidator=function(){this.validator=E.filesLimit("string"==typeof this.fileslimit?parseInt(this.fileslimit,10):this.fileslimit)},t.decorators=[{type:o.Directive,args:[{selector:"[fileslimit][formControlName],[fileslimit][formControl],[fileslimit][ngModel]",providers:[{provide:r.NG_VALIDATORS,useExisting:o.forwardRef(function(){return t}),multi:!0}],host:{"[attr.fileslimit]":"fileslimit ? fileslimit : null"}}]}],t.propDecorators={fileslimit:[{type:o.Input}]},t}(),A=function(){function t(){}return t.prototype.ngOnChanges=function(t){"accept"in t&&(this._createValidator(),this.onChange&&this.onChange())},t.prototype.validate=function(t){return null!=this.accept?this.validator(t):null},t.prototype.registerOnValidatorChange=function(t){this.onChange=t},t.prototype._createValidator=function(){this.validator=E.accept(this.accept.split(","))},t.decorators=[{type:o.Directive,args:[{selector:"[accept][formControlName],[accept][formControl],[accept][ngModel]",providers:[{provide:r.NG_VALIDATORS,useExisting:o.forwardRef(function(){return w}),multi:!0}],host:{"[attr.accept]":"accept ? accept : null"}}]}],t.propDecorators={accept:[{type:o.Input}]},t}(),I=function(){function t(t){this.injector=t}return t.prototype.ngDoBootstrap=function(){},t.decorators=[{type:o.NgModule,args:[{imports:[n.CommonModule,r.ReactiveFormsModule,r.FormsModule],declarations:[v,m,y,b,V,w,A],exports:[v,b,V,w,A],entryComponents:[v]}]}],t.ctorParameters=function(){return[{type:o.Injector}]},t}();t.FileUploadControl=c,t.FileUploadValidators=E,t.FileUploadTypes=p,t.FileUploadModule=I,t.ɵd=u,t.ɵc=d,t.ɵg=b,t.ɵf=y,t.ɵe=m,t.ɵa=v,t.ɵh=V,t.ɵj=A,t.ɵi=w,t.ɵb=h,Object.defineProperty(t,"__esModule",{value:!0})});
//# sourceMappingURL=iplab-ngx-file-upload.umd.min.js.map

@@ -144,3 +144,2 @@ /**

.filter((error) => error);
console.log('notAllowedFiles', notAllowedFiles);
return notAllowedFiles.length > 0 ?

@@ -152,2 +151,2 @@ { 'fileTypes': notAllowedFiles } : null;

export { ɵ0, ɵ1, ɵ2 };
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidmFsaWRhdG9ycy5jbGFzcy5qcyIsInNvdXJjZVJvb3QiOiJuZzovL0BpcGxhYi9uZ3gtZmlsZS11cGxvYWQvIiwic291cmNlcyI6WyJoZWxwZXJzL3ZhbGlkYXRvcnMuY2xhc3MudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7OztBQUNBLE9BQU8sRU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ICAgICByZXR1cm4gKGNvbnRyb2w6IEFic3RyYWN0Q29udHJvbCB8IEZpbGVVcGxvYWRDb250cm9sKToge2ZpbGVTaXplOiBBcnJheTxWYWxpZGF0aW9uRXJyb3JzPn0gPT4ge1xyXG4gICAgICAgICAgICBjb25zdCBmaWxlczogQXJyYXk8RmlsZT4gPSBjb250cm9sLnZhbHVlO1xyXG4gICAgICAgICAgICBpZiAoSXNOdWxsT3JFbXB0eShmaWxlcykpIHsgcmV0dXJuIG51bGw7IH1cclxuICAgICAgICAgICAgY2hlY2tWYWx1ZVR5cGUoZmlsZXMpO1xyXG5cclxuICAgICAgICAgICAgY29uc3QgdG9MYXJnZUZpbGVzID0gZmlsZXMubWFwKChmaWxlKSA9PiBjaGVja0ZpbGVTaXplKGZpbGUsIG1heFNpemUpKVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLmZpbHRlcigoZXJyb3IpID0+IGVycm9yKTtcclxuXHJcbiAgICAgICAgICAgIHJldHVybiB0b0xhcmdlRmlsZXMubGVuZ3RoID4gMCA/XHJcbiAgICAgICAgICAgICAgICAgICAgeydmaWxlU2l6ZSc6IHRvTGFyZ2VGaWxlc30gOiBudWxsO1xyXG4gICAgICAgIH07XHJcbiAgICB9XHJcblxyXG4gICAgLyoqXHJcbiAgICAgKiBDb21wYXJlIHRoZSBGaWxlIHNpemUgaW4gYnl0ZXMgd2l0aCBtYXggYW5kIG1pbiBzaXplIGxpbWl0c1xyXG4gICAgICogQGR5bmFtaWNcclxuICAgICAqL1xyXG4gICAgcHVibGljIHN0YXRpYyBzaXplUmFuZ2UoeyBtaW5TaXplLCBtYXhTaXplIH06IHsgbWluU2l6ZT86IG51bWJlcjsgbWF4U2l6ZT86IG51bWJlciB9KTogVmFsaWRhdG9yRm4ge1xyXG4gICAgICAgIHJldHVybiAoY29udHJvbDogQWJzdHJhY3RDb250cm9sIHwgRmlsZVVwbG9hZENvbnRyb2wpOiB7c2l6ZVJhbmdlOiBBcnJheTxWYWxpZGF0aW9uRXJyb3JzPn0gPT4ge1xyXG4gICAgICAgICAgICBjb25zdCBmaWxlczogQXJyYXk8RmlsZT4gPSBjb250cm9sLnZhbHVlO1xyXG4gICAgICAgICAgICBpZiAoSXNOdWxsT3JFbXB0eShmaWxlcykpIHsgcmV0dXJuIG51bGw7IH1cclxuICAgICAgICAgICAgY2hlY2tWYWx1ZVR5cGUoZmlsZXMpO1xyXG5cclxuICAgICAgICAgICAgY29uc3Qgc2l6ZU1pc21hdGNoID0gZmlsZXMubWFwKChmaWxlKSA9PiBjaGVja0ZpbGVTaXplKGZpbGUsIG1heFNpemUsIG1pblNpemUpKVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLmZpbHRlcigoZXJyb3IpID0+IGVycm9yKTtcclxuXHJcbiAgICAgICAgICAgIHJldHVybiBzaXplTWlzbWF0Y2gubGVuZ3RoID4gMCA/XHJcbiAgICAgICAgICAgICAgICAgICAgeydzaXplUmFuZ2UnOiBzaXplTWlzbWF0Y2h9IDogbnVsbDtcclxuICAgICAgICB9O1xyXG4gICAgfVxyXG5cclxuICAgIC8qKlxyXG4gICAgICogdmFsaWRhdG9yIHRoYXQgcmVxdWlyZXMgY29udHJvbCB0byBoYXZlIGxpbWl0IG9uIGZpbGVzIG51bWJlclxyXG4gICAgICogQGR5bmFtaWNcclxuICAgICAqL1xyXG4gICAgcHVibGljIHN0YXRpYyBmaWxlc0xpbWl0KG51bUZpbGVzOiBudW1iZXIpOiBWYWxpZGF0b3JGbiB7XHJcbiAgICAgICAgcmV0dXJuIChjb250cm9sOiBBYnN0cmFjdENvbnRyb2wgfCBGaWxlVXBsb2FkQ29udHJvbCk6IFZhbGlkYXRpb25FcnJvcnMgPT4ge1xyXG4gICAgICAgICAgICBjb25zdCBmaWxlczogQXJyYXk8RmlsZT4gPSBjb250cm9sLnZhbHVlO1xyXG4gICAgICAgICAgICBpZiAoSXNOdWxsT3JFbXB0eShmaWxlcykpIH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AgICAgICAgICAgICAgICAgICAgICAuZmlsdGVyKChlcnJvcikgPT4gZXJyb3IpO1xyXG5cclxuICAgICAgICAgICAgcmV0dXJuIG5vdEFsbG93ZWRGaWxlcy5sZW5ndGggPiAwID9cclxuICAgICAgICAgICAgICAgIHsnZmlsZVR5cGVzJzogbm90QWxsb3dlZEZpbGVzfSA6IG51bGw7XHJcbiAgICAgICAgfTtcclxuICAgIH1cclxuXHJcbn1cclxuIl19

@@ -228,3 +228,2 @@ /**

.filter(function (error) { return error; });
console.log('notAllowedFiles', notAllowedFiles);
return notAllowedFiles.length > 0 ?

@@ -239,2 +238,2 @@ { 'fileTypes': notAllowedFiles } : null;

export { ɵ0, ɵ1, ɵ2 };
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidmFsaWRhdG9ycy5jbGFzcy5qcyIsInNvdXJjZVJvb3QiOiJuZzovL0BpcGxhYi9uZ3gtZmlsZS11cGxvYWQvIiwic291cmNlcyI6WyJoZWxwZXJzL3ZhbGlkYXRvcnMuY2xhc3MudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7QUFDQSxPQUFPLEVBQUUsYUFBYSxFQUFFLE1BQU0saUJBQWlCLENBQUM7Ozs7QUFHaEQsc0NBRUM7Ozs7QUFFRCxpQ0FFQzs7Ozs7SUFLSyxhQUFhLEdBQUcsVUFBQyxJQUFVLEVBQUUsT0FBZSxFQUFFLE9BQW1CO0lBQW5CLHdCQUFBLEVBQUEsV0FBbUI7SUFDbkUsT0FBTyxDQUFDLENBQUMsYUFBYSxDQUFDLE9BQU8sQ0FBQyxJQUFJLElBQUksQ0FBQyxJQUFJLEdBQUcsT0FBTyxDQUFDLElBQUksSUFBSSxDQUFDLElBQUksR0FBRyxPQUFPLENBQUMsQ0FBQztRQUM1RSxFQUFDLE9BQU8sU0FBQSxFQUFFLE9BQU8sU0FBQSxFQUFFLE1BQU0sRUFBRSxJQUFJLENBQUMsSUFBSSxFQ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FsdWU7XHJcbiAgICAgICAgICAgIGlmIChJc051bGxPckVtcHR5KGZpbGVzKSkgeyByZXR1cm4gbnVsbDsgfVxyXG4gICAgICAgICAgICBjaGVja1ZhbHVlVHlwZShmaWxlcyk7XHJcblxyXG4gICAgICAgICAgICBjb25zdCB0b0xhcmdlRmlsZXMgPSBmaWxlcy5tYXAoKGZpbGUpID0+IGNoZWNrRmlsZVNpemUoZmlsZSwgbWF4U2l6ZSkpXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAuZmlsdGVyKChlcnJvcikgPT4gZXJyb3IpO1xyXG5cclxuICAgICAgICAgICAgcmV0dXJuIHRvTGFyZ2VGaWxlcy5sZW5ndGggPiAwID9cclxuICAgICAgICAgICAgICAgICAgICB7J2ZpbGVTaXplJzogdG9MYXJnZUZpbGVzfSA6IG51bGw7XHJcbiAgICAgICAgfTtcclxuICAgIH1cclxuXHJcbiAgICAvKipcclxuICAgICAqIENvbXBhcmUgdGhlIEZpbGUgc2l6ZSBpbiBieXRlcyB3aXRoIG1heCBhbmQgbWluIHNpemUgbGltaXRzXHJcbiAgICAgKiBAZHluYW1pY1xyXG4gICAgICovXHJcbiAgICBwdWJsaWMgc3RhdGljIHNpemVSYW5nZSh7IG1pblNpemUsIG1heFNpemUgfTogeyBtaW5TaXplPzogbnVtYmVyOyBtYXhTaXplPzogbnVtYmVyIH0pOiBWYWxpZGF0b3JGbiB7XHJcbiAgICAgICAgcmV0dXJuIChjb250cm9sOiBBYnN0cmFjdENvbnRyb2wgfCBGaWxlVXBsb2FkQ29udHJvbCk6IHtzaXplUmFuZ2U6IEFycmF5PFZhbGlkYXRpb25FcnJvcnM+fSA9PiB7XHJcbiAgICAgICAgICAgIGNvbnN0IGZpbGVzOiBBcnJheTxGaWxlPiA9IGNvbnRyb2wudmFsdWU7XHJcbiAgICAgICAgICAgIGlmIChJc051bGxPckVtcHR5KGZpbGVzKSkgeyByZXR1cm4gbnVsbDsgfVxyXG4gICAgICAgICAgICBjaGVja1ZhbHVlVHlwZShmaWxlcyk7XHJcblxyXG4gICAgICAgICAgICBjb25zdCBzaXplTWlzbWF0Y2ggPSBmaWxlcy5tYXAoKGZpbGUpID0+IGNoZWNrRmlsZVNpemUoZmlsZSwgbWF4U2l6ZSwgbWluU2l6ZSkpXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAuZmlsdGVyKChlcnJvcikgPT4gZXJyb3IpO1xyXG5cclxuICAgICAgICAgICAgcmV0dXJuIHNpemVNaXNtYXRjaC5sZW5ndGggPiAwID9cclxuICAgICAgICAgICAgICAgICAgICB7J3NpemVSYW5nZSc6IHNpemVNaXNtYXRjaH0gOiBudWxsO1xyXG4gICAgICAgIH07XHJcbiAgICB9XHJcblxyXG4gICAgLyoqXHJcbiAgICAgKiB2YWxpZGF0b3IgdGhhdCByZXF1aXJlcyBjb250cm9sIHRvIGhhdmUgbGltaXQgb24gZmlsZXMgbnVtYmVyXHJcbiAgICAgKiBAZHluYW1pY1xyXG4gICAgICovXHJcbiAgICBwdWJsaWMgc3RhdGljIGZpbGVzTGltaXQobnVtRmlsZXM6IG51bWJlcik6IFZhbGlkYXRvckZuIHtcclxuICAgICAgICByZXR1cm4gKGNvbnRyb2w6IEFic3RyYWN0Q29udHJvbCB8IEZpbGVVcGxvYWRDb250cm9sKTogVmFsaWRhdGlvbkVycm9ycyA9PiB7XHJcbiAgICAgICAgICAgIGNvbnN0IGZpbGVzOiBBcnJheTxGaWxlPiA9IGNvbnRyb2wudmFsdWU7XHJcbiAgICAgICAgICAgIGlmIChJc051bGxPckVtcHR5KGZpbGVzKSkgeyByZXR1cm4gbnVsbDsgfVxyXG4gICAgICAgICAgICBjaGVja1ZhbHVlVHlwZShmaWxlcyk7XHJcblxyXG4gICAgICAgICAgICByZXR1cm4gZmlsZXMubGVuZ3RoID4gbnVtRmlsZXMgP1xyXG4gICAgICAgICAgICAgICAgeydmaWxlc0xpbWl0JzogeydtYXgnOiBudW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S8qLCBtZWRpYV90eXBlXSlgXHJcbiAgICAgKiBAZHluYW1pY1xyXG4gICAgICovXHJcbiAgICBwdWJsaWMgc3RhdGljIGFjY2VwdChhbGxvd2VkRmlsZVR5cGVzOiBBcnJheTxzdHJpbmc+KSB7XHJcbiAgICAgICAgcmV0dXJuIChjb250cm9sOiBBYnN0cmFjdENvbnRyb2wgfCBGaWxlVXBsb2FkQ29udHJvbCk6IFZhbGlkYXRpb25FcnJvcnMgPT4ge1xyXG4gICAgICAgICAgICBjb25zdCBmaWxlczogQXJyYXk8RmlsZT4gPSBjb250cm9sLnZhbHVlO1xyXG4gICAgICAgICAgICBpZiAoSXNOdWxsT3JFbXB0eShmaWxlcykpIHsgcmV0dXJuIG51bGw7IH1cclxuICAgICAgICAgICAgY2hlY2tWYWx1ZVR5cGUoZmlsZXMpO1xyXG5cclxuICAgICAgICAgICAgY29uc3Qgbm90QWxsb3dlZEZpbGVzID0gZmlsZXMubWFwKChmaWxlKSA9PiBjaGVja0ZpbGVUeXBlKGZpbGUsIGFsbG93ZWRGaWxlVHlwZXMpKVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLmZpbHRlcigoZXJyb3IpID0+IGVycm9yKTtcclxuXHJcbiAgICAgICAgICAgIGNvbnNvbGUubG9nKCdub3RBbGxvd2VkRmlsZXMnLCBub3RBbGxvd2VkRmlsZXMpO1xyXG4gICAgICAgICAgICByZXR1cm4gbm90QWxsb3dlZEZpbGVzLmxlbmd0aCA+IDAgP1xyXG4gICAgICAgICAgICAgICAgeydmaWxlVHlwZXMnOiBub3RBbGxvd2VkRmlsZXN9IDogbnVsbDtcclxuICAgICAgICB9O1xyXG4gICAgfVxyXG5cclxufVxyXG4iXX0=
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidmFsaWRhdG9ycy5jbGFzcy5qcyIsInNvdXJjZVJvb3QiOiJuZzovL0BpcGxhYi9uZ3gtZmlsZS11cGxvY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WxpZGF0b3IgdGhhdCByZXF1aXJlcyBjb250cm9scyB0byBoYXZlIGEgZmlsZSBtYXhpbXVtIHNpemUgbGVuZ3RoLlxyXG4gICAgICogQ29tcGFyZSB0aGUgRmlsZSBzaXplIGluIGJ5dGVzXHJcbiAgICAgKiBAZHluYW1pY1xyXG4gICAgICovXHJcbiAgICBwdWJsaWMgc3RhdGljIGZpbGVTaXplKG1heFNpemU6IG51bWJlcik6IFZhbGlkYXRvckZuIHtcclxuICAgICAgICByZXR1cm4gKGNvbnRyb2w6IEFic3RyYWN0Q29udHJvbCB8IEZpbGVVcGxvYWRDb250cm9sKToge2ZpbGVTaXplOiBBcnJheTxWYWxpZGF0aW9uRXJyb3JzPn0gPT4ge1xyXG4gICAgICAgICAgICBjb25zdCBmaWxlczogQXJyYXk8RmlsZT4gPSBjb250cm9sLnZhbHVlO1xyXG4gICAgICAgICAgICBpZiAoSXNOdWxsT3JFbXB0eShmaWxlcykpIHsgcmV0dXJuIG51bGw7IH1cclxuICAgICAgICAgICAgY2hlY2tWYWx1ZVR5cGUoZmlsZXMpO1xyXG5cclxuICAgICAgICAgICAgY29uc3QgdG9MYXJnZUZpbGVzID0gZmlsZXMubWFwKChmaWxlKSA9PiBjaGVja0ZpbGVTaXplKGZpbGUsIG1heFNpemUpKVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLmZpbHRlcigoZXJyb3IpID0+IGVycm9yKTtcclxuXHJcbiAgICAgICAgICAgIHJldHVybiB0b0xhcmdlRmlsZXMubGVuZ3RoID4gMCA/XHJcbiAgICAgICAgICAgICAgICAgICAgeydmaWxlU2l6ZSc6IHRvTGFyZ2VGaWxlc30gOiBudWxsO1xyXG4gICAgICAgIH07XHJcbiAgICB9XHJcblxyXG4gICAgLyoqXHJcbiAgICAgKiBDb21wYXJlIHRoZSBGaWxlIHNpemUgaW4gYnl0ZXMgd2l0aCBtYXggYW5kIG1pbiBzaXplIGxpbWl0c1xyXG4gICAgICogQGR5bmFtaWNcclxuICAgICAqL1xyXG4gICAgcHVibGljIHN0YXRpYyBzaXplUmFuZ2UoeyBtaW5TaXplLCBtYXhTaXplIH06IHsgbWluU2l6ZT86IG51bWJlcjsgbWF4U2l6ZT86IG51bWJlciB9KTogVmFsaWRhdG9yRm4ge1xyXG4gICAgICAgIHJldHVybiAoY29udHJvbDogQWJzdHJhY3RDb250cm9sIHwgRmlsZVVwbG9hZENvbnRyb2wpOiB7c2l6ZVJhbmdlOiBBcnJheTxWYWxpZGF0aW9uRXJyb3JzPn0gPT4ge1xyXG4gICAgICAgICAgICBjb25zdCBmaWxlczogQXJyYXk8RmlsZT4gPSBjb250cm9sLnZhbHVlO1xyXG4gICAgICAgICAgICBpZiAoSXNOdWxsT3JFbXB0eShmaWxlcykpIHsgcmV0dXJuIG51bGw7IH1cclxuICAgICAgICAgICAgY2hlY2tWYWx1ZVR5cGUoZmlsZXMpO1xyXG5cclxuICAgICAgICAgICAgY29uc3Qgc2l6ZU1pc21hdGNoID0gZmlsZXMubWFwKChmaWxlKSA9PiBjaGVja0ZpbGVTaXplKGZpbGUsIG1heFNpemUsIG1pblNpemUpKVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLmZpbHRlcigoZXJyb3IpID0+IGVycm9yKTtcclxuXHJcbiAgICAgICAgICAgIHJldHVybiBzaXplTWlzbWF0Y2gubGVuZ3RoID4gMCA/XHJcbiAgICAgICAgICAgICAgICAgICAgeydzaXplUmFuZ2UnOiBzaXplTWlzbWF0Y2h9IDogbnVsbDtcclxuICAgICAgICB9O1xyXG4gICAgfVxyXG5cclxuICAgIC8qKlxyXG4gICAgICogdmFsaWRhdG9yIHRoYXQgcmVxdWlyZXMgY29udHJvbCB0byBoYXZlIGxpbWl0IG9uIGZpbGVzIG51bWJlclxyXG4gICAgICogQGR5bmFtaWNcclxuICAgICAqL1xyXG4gICAgcHVibGljIHN0YXRpYyBmaWxlc0xpbWl0KG51bUZpbGVzOiBudW1i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ICAgICAgICAgICAgICAgICAgICAgIC5maWx0ZXIoKGVycm9yKSA9PiBlcnJvcik7XHJcblxyXG4gICAgICAgICAgICByZXR1cm4gbm90QWxsb3dlZEZpbGVzLmxlbmd0aCA+IDAgP1xyXG4gICAgICAgICAgICAgICAgeydmaWxlVHlwZXMnOiBub3RBbGxvd2VkRmlsZXN9IDogbnVsbDtcclxuICAgICAgICB9O1xyXG4gICAgfVxyXG5cclxufVxyXG4iXX0=

@@ -1168,3 +1168,2 @@ import { BehaviorSubject, Subject } from 'rxjs';

.filter((error) => error);
console.log('notAllowedFiles', notAllowedFiles);
return notAllowedFiles.length > 0 ?

@@ -1171,0 +1170,0 @@ { 'fileTypes': notAllowedFiles } : null;

@@ -6,3 +6,3 @@ {

"bugs": "https://github.com/pIvan/file-upload/issues",
"version": "1.1.8",
"version": "1.1.9",
"author": "Ivan Pintar",

@@ -9,0 +9,0 @@ "license": "MIT",

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc