{"version":3,"sources":["./src/app/modules/website.module.ts","./src/app/modules/newsdashboard/newsdashboard.component.html","./src/app/shared/components/right/right.component.html","./src/app/shared/components/footer/footer.component.html","./src/app/shared/components/home/home.component.html","./src/app/encode-html.pipe.ts","./src/app/modules/define-pages/displaypage/displaypage.component.ts","./src/app/modules/define-pages/displaypage/displaypage.component.html","./node_modules/@angular/material/progress-bar/index.d.ts.MatProgressBar.html","./src/app/modules/photogallery/carousel/carousel.component.ts","./src/app/modules/photogallery/carousel/carousel.component.html","./node_modules/ngx-image-cropper/node_modules/tslib/tslib.es6.js","./node_modules/ngx-image-cropper/fesm2015/ngx-image-cropper.js","./node_modules/ngx-image-cropper/ngx-image-cropper.d.ts.ImageCropperComponent.html","./node_modules/primeng/fesm2015/primeng-api.js","./src/app/modules/photogallery/cropNuploadphoto/cropNuploadphoto.component.ts","./src/app/modules/photogallery/cropNuploadphoto/cropNuploadphoto.component.html","./src/app/modules/photogallery/photobrowser/photobrowser.component.ts","./src/app/modules/photogallery/photobrowser/photobrowser.component.html","./node_modules/ng2-ckeditor/fesm2015/ng2-ckeditor.js","./node_modules/ng2-ckeditor/ng2-ckeditor.d.ts.ɵa.html","./src/app/modules/define-pages/texteditor/texteditor.component.ts","./src/app/modules/define-pages/texteditor/texteditor.component.html","./src/app/modules/define-pages/pageDashboard/pageDashboard.component.ts","./src/app/modules/define-pages/pageDashboard/pageDashboard.component.html","./src/app/modules/define-pages/pageView/pageView.component.ts","./src/app/shared/content.service.ts","./src/app/modules/define-pages/pageView/pageView.component.html","./node_modules/ngx-dropzone/fesm2015/ngx-dropzone.js","./node_modules/ngx-dropzone/ngx-dropzone.d.ts.NgxDropzoneComponent.html","./node_modules/ngx-dropzone/ngx-dropzone.d.ts.NgxDropzonePreviewComponent.html","./node_modules/ngx-dropzone/ngx-dropzone.d.ts.NgxDropzoneRemoveBadgeComponent.html","./src/app/modules/photogallery/imgDragAndDrop/imgDragAndDrop.ts","./node_modules/ng2-img-max/dist/src/img-exif.service.js","./node_modules/ng2-img-max/dist/src/img-max-size.service.js","./node_modules/ng2-pica/dist/src/img-exif.service.js","./node_modules/ng2-pica/dist/src/ng2-pica.service.js","./node_modules/ng2-pica/dist/src/ng2-pica.module.js","./node_modules/ng2-img-max/dist/src/img-maxpx-size.service.js","./node_modules/ng2-img-max/dist/src/ng2-img-max.service.js","./src/app/modules/photogallery/imgDragAndDrop/imgDragAndDrop.html","./src/app/modules/files/filedrag-and-drop/filedrag-and-drop.component.ts","./src/app/modules/files/filedrag-and-drop/filedrag-and-drop.component.html","./src/app/modules/photogallery/photos/photos.component.ts","./src/app/modules/photogallery/photos/photos.component.html","./src/app/modules/photogallery/albumedit-input/albumedit-input.component.ts","./src/app/modules/photogallery/albumedit-input/albumedit-input.component.html","./node_modules/@angular/cdk/fesm2015/clipboard.js","./src/app/modules/photogallery/albums/albums.component.ts","./src/app/modules/photogallery/albums/albums.component.html","./src/app/modules/contact/contactdashboard/contactdashboard.component.ts","./src/app/modules/contact/contactdashboard/contactdashboard.component.html","./src/app/modules/contact/addMessage/contact.component.ts","./src/app/modules/contact/addMessage/contact.component.html","./src/app/modules/define-pages/menu-config/menu-config.component.ts","./src/app/modules/define-pages/menu-config/menu-config.component.html","./src/app/modules/allnewsdashboard/allnewsdashboard.component.ts","./src/app/modules/allnewsdashboard/allnewsdashboard.component.html","./node_modules/ng2-img-max/dist/src/ng2-img-max.module.js","./node_modules/ngx-photo-editor/fesm2015/ngx-photo-editor.js","./src/app/modules/website-routing.module.ts","./src/app/modules/photogallery/albums/albums.module.ts","./src/app/modules/define-pages/define-pages.module.ts","./node_modules/exifr/dist/mini.legacy.umd.js","./node_modules/pica/dist/pica.js","./node_modules/cropperjs/dist/cropper.js"],"names":["WebsiteModule","EncodeHTMLPipe","sanitizer","value","this","bypassSecurityTrustHtml","naomitsuService","ar","route","shareddata","dataStorage","images","Name","ImgUrl","loading","color","mode","loop","ParentPage","Title","PageBody","ParentLink","GroupId","queryParamMap","subscribe","params","get","paramMap","pId","CurrentRandomImages","r","length","getRandomDisplayPhotoes","GetLatestPage","navigate","pHistoryId","IdtoDisplay","filterstring","list","fields","lookupFields","PageName","filter","data","pagetodisplay","link","split","AssignImageUrl","PhotoPath","getParentPageLink","ParentId","PageHistories","h","PageHistoryId","PageTitle","photoPath","Math","floor","random","globalconstant","apiUrl","Parent","CurrentPagesData","p","item","PageId","label","PhId","RandomImagesParentId","image","FileName","toLowerCase","rimg","FileId","map","element","ChangeRandomImages","Page","GetParentPage","ParentPageId","parentId","config","dataservice","nav","unique","name","major","error","folderHierarachy","PhotoId","Description","UpdatableName","interval","keyboard","pauseOnHover","animation","selectedAlbumId","snapshot","getPhotoes","orderBy","selectedAlbum","UpdatedFileFolderName","Albums","getNestedFolders","fileId","ParentItem","style","transform","transition","__awaiter","thisArg","_arguments","P","generator","Promise","resolve","reject","fulfilled","step","next","e","rejected","result","done","then","apply","_c0","_c1","ImageCropperComponent_img_2_Template","rf","ctx","_r5","imageLoadedInView","ctx_r1","imageVisible","safeTransformStyle","safeImgDataUrl","ImageCropperComponent_div_4_ng_container_2_Template","_r8","$event","ctx_r7","startMove","moveTypes","Resize","ctx_r9","ctx_r10","ctx_r11","ctx_r12","ctx_r13","ctx_r14","ctx_r15","ctx_r16","ctx_r17","ctx_r18","ctx_r19","ctx_r20","ctx_r21","ctx_r22","ctx_r23","ImageCropperComponent_div_4_Template","_r25","keyboardAccess","ctx_r26","Move","ctx_r27","ctx_r2","cropper","y1","x1","x2","y2","alignImage","marginLeft","roundCropper","hideResizeSquares","MoveTypes","Pinch","CropService","sourceImage","loadedImage","settings","imagePosition","getImagePosition","width","height","cropCanvas","document","createElement","getContext","backgroundColor","fillStyle","fillRect","scaleX","scale","flipH","scaleY","flipV","transformedImage","transformed","setTransform","size","translate","rotate","PI","drawImage","output","cropperPosition","Object","assign","containWithinAspectRatio","offsetImagePosition","getOffsetImagePosition","resizeRatio","getResizeRatio","round","maintainAspectRatio","aspectRatio","canvas","width_source","height_source","ratio_w","ratio_h","ratio_w_half","ceil","ratio_h_half","img","getImageData","img2","createImageData","data2","j","i","center_y","weight","weights","weights_alpha","gx_r","gx_g","gx_b","gx_a","xx_start","yy_start","xx_stop","yy_stop","min","yy","dy","abs","center_x","w0","xx","dx","w","sqrt","pos_x","putImageData","resizeCanvas","base64","toDataURL","format","getQuality","ratio","nativeElement","offsetWidth","out","max","offsetX","offsetY","canvasRotation","exifTransform","original","ratioWidth","resizeToWidth","ratioHeight","resizeToHeight","ratios","Array","push","onlyScaleDown","imageQuality","ɵfac","t","ɵprov","token","factory","providedIn","ngInjectableDef","CropperSettings","cropperMinWidth","cropperMinHeight","cropperMaxHeight","cropperMaxWidth","cropperStaticWidth","cropperStaticHeight","initialStepSize","autoCrop","cropperScaledMinWidth","cropperScaledMinHeight","cropperScaledMaxWidth","cropperScaledMaxHeight","stepSize","options","keys","forEach","k","LoadImageService","autoRotateSupported","Image","onload","src","file","cropperSettings","fileReader","FileReader","event","loadImage","target","type","catch","readAsDataURL","imageBase64","imageType","isValidImageType","loadBase64Image","Error","test","url","onerror","context","crossOrigin","originalImage","originalBase64","res","transformImageBase64","autoRotate","exifRotationOrBase64Image","view","DataView","replace","binaryString","atob","len","bytes","Uint8Array","charCodeAt","buffer","base64ToArrayBuffer","getUint16","byteLength","offset","marker","getUint32","little","tags","getExifRotation","flip","getTransformationsFromExifData","complete","transformLoadedImage","naturalWidth","naturalHeight","originalSize","transformedSize","getTransformedSize","transformedBase64","loadImageFromBase64","minHeightToContain","CropperPositionService","sourceImageElement","offsetHeight","cropperWidth","cropperHeight","cropperHeightWithAspectRatio","cropperWidthWithAspectRatio","moveStart","diffX","getClientX","clientX","diffY","getClientY","clientY","maxSize","moveX","moveY","position","newWidth","newHeight","checkAspectRatio","overflowX","overflowY","overflowX1","overflowX2","overflowY1","overflowY2","touches","ImageCropperComponent","cropService","cropperPositionService","loadImageService","cd","Hammer","window","setImageMaxSizeRetries","disabled","imageCropped","startCropImage","imageLoaded","cropperReady","loadImageFailed","reset","changes","onChangesUpdateSettings","onChangesInputImage","setLoadedImage","err","loadImageError","setMaxSize","setCropperScaledMinSize","setCropperScaledMaxSize","checkCropperPosition","doAutoCrop","markForCheck","resetCropperPosition","setCssTransform","hasOwnProperty","imageChangedEvent","imageURL","imageFile","isValidImageChangedEvent","loadImageFile","files","loadImageFromURL","bypassSecurityTrustStyle","activatePinchGesture","active","bypassSecurityTrustResourceUrl","console","emit","setTimeout","checkImageMaxSizeRecursively","sourceImageLoaded","resizeCropperPosition","hammer","wrapper","set","enable","on","onPinch","bind","pinchStop","startPinch","warn","changeKeyboardStepSize","keyboardMoveCropper","key","includes","moveType","shiftKey","altKey","getInvertedPositionForKey","getPositionForKey","moveEvent","getEventForKey","preventDefault","stopPropagation","moveImg","moveStop","move","resize","detectChanges","setCropperScaledMinWidth","setCropperScaledMinHeight","maintainSize","crop","ɵcmp","selectors","viewQuery","_t","first","hostVars","hostBindings","onResize","inputs","outputs","features","decls","vars","consts","template","directives","styles","changeDetection","ImageCropperModule","ɵmod","ɵinj","imports","ConfirmationService","requireConfirmationSource","Subject","acceptConfirmationSource","requireConfirmation$","asObservable","accept","confirmation","MessageService","messageSource","clearSource","messageObserver","clearObserver","message","messages","SharedModule","datePipe","uploadService","alertMessage","confirmationService","messageService","dialog","tokenStorage","autoClose","keepAfterRouteChange","UploadForm","selectedRatio","croppedImage","rotation","showCropper","description","patchValue","checklogin","getAlbums","getToken","fileName","formData","FormData","append","base64Image","byteString","ab","ArrayBuffer","ia","Blob","base64ToFile","existingAlbum","toString","filteredAlbum","uploadImage","postFile","success","confirm","icon","add","severity","summary","detail","sourceImageDimensions","flipAfterRotate","flippedH","flippedV","alert","el","mediaObserver","ngVersion","full","matVersion","blueColorScheme","searchForm","Album","required","maxLength","year","radioAlbum","mediaSub","deviceXs","mqAlias","controls","setValue","indx","queryParams","strFilter","AllAlbums","minId","o","getPhotos","log","count","album","photos","f","photo","PhotoName","Width","Height","PhotoCount","fullPath","breakpoint","rowHeight","oldvalue","albumtoUpdate","Active","UploadDate","Date","postPatch","CKButtonDirective","click","editor","instance","addCommand","command","exec","evt","ui","addButton","toolbar","ɵdir","CKGroupDirective","toolbarButtons","button","addToolbarGroup","previous","subgroupOf","initialize","contentQueries","dirIndex","CKEditorComponent","zone","change","editorChange","ready","blur","focus","contentDom","fileUploadRequest","fileUploadResponse","paste","drop","_value","v","onChange","readonly","setReadOnly","currentValue","removeAllListeners","CKEDITOR","instances","destroy","ckeditorInit","run","onTouched","documentContains","host","readOnly","setData","getData","debounce","debounceTimeout","clearTimeout","updateValue","parseInt","toolbarGroups","group","_","fn","node","contains","body","provide","useExisting","multi","encapsulation","CKEditorModule","fb","router","fileUploadService","OneMB","processing","Edit","imageCount","imgURL","errorMessage","PageDetail","FullPath","CurrentVersion","UpdateDate","IsTemplate","HasSubmenu","Module","PublishOrDraft","PageDetailForm","Published","PageHistory","Version","CreatedDate","selected","Id","mycontent","id","undefined","ckeConfig","allowedContent","extraPlugins","forcePasteAsPlainText","removeButtons","scayt_autoStartup","autoGrow_onStartup","autoGrow_minHeight","autoGrow_maxHeight","match","selectedFile","reader","_event","pageData","formdata","ppId","limitTo","pgid","onSave","insert","Update","duplicate","PageGroups","ele","g","page","pageId","history","toUpperCase","PageLeft","PageRight","PageFooter","DATA","displayedColumns","selection","columns","arrPage","arr","pPage","ParentPages","getmax","Action","column","columnDef","header","cell","SelectedArr","c","dataSource","paginator","sort","pageHistory","phid","reduce","prev","current","pageTitle","pid","ptitle","filterValue","trim","confirmYesNo","openConfirmDialog","afterClosed","getDetails","toggle","checked","isAllSelected","clear","row","select","pageViewComponent","contentservice","GetcontentById","PageHeader","content","ContentService","http","pagecontent","post","title","query","pageGroupId","pageName","httpOptions","headers","patch","NgxDropzonePreviewComponent_ngx_dropzone_remove_badge_1_Template","_r2","_remove","_c2","NgxDropzoneComponent_ng_content_2_Template","_c3","_c4","NgxDropzoneLabelDirective","coerceBooleanProperty","KEY_CODE","BACKSPACE","DELETE","NgxDropzonePreviewComponent","_removable","removed","tabIndex","keyCode","remove","keyEvent","hostStyle","removable","ngContentSelectors","NgxDropzoneService","maxFileSize","multiple","addedFiles","rejectedFiles","isAccepted","rejectFile","acceptFiletypes","it","filetype","filename","find","acceptFiletype","endsWith","startsWith","reason","rejectedFile","NgxDropzoneComponent","service","_disabled","_multiple","_maxFileSize","_expandable","_disableClick","_isHovered","_previewChildren","isNaN","parseFloat","Number","coerceNumberProperty","disableClick","showFileSelector","handleFileDrop","dataTransfer","_fileInput","parseFileList","source","_onClick","_onDragOver","_onDragLeave","_onDrop","expandable","ariaLabel","ariaLabelledby","ariaDescribedBy","_onFilesSelected","_hasPreviews","NgxDropzoneRemoveBadgeComponent","NgxDropzoneModule","ng2ImgMax","Processing","Requestsize","dragdropForm","resultCount","RequestLimit","info","toFixed","resizeImage","uploadedImage","compressImage","File","UpdatedFolder","uploadFile","postFiles","splice","indexOf","ImgExifService","prototype","getOrientedImage","orientation","cw","ch","cx","cy","deg","addEventListener","ImgMaxSizeService","imageExifService","maxSizeInMB","ignoreAlpha","logExecutionTime","_this","compressedFileSubject","timeAtStart","getTime","initialFile","compressedFile","cvs","self","orientedImg","URL","revokeObjectURL","imageData","isImgUsingAlpha","getCompressedFile","createObjectURL","quality","currentStep","toBlob","blob","getResultFile","newQuality","getCalculatedQuality","checkCompressionStatus","generateResultFile","lastModified","resultFile","blobToFile","currentSize","ratioMaxSizeToCurrentSize","ratioMaxSizeToInitialSize","multiplicator","isInteger","Ng2PicaService","keepAspectRatio","resizedFile","resizeFile","returnedFile","from","to","curPica","pica","response","resizeBuffer","fromCanvas","useAlpha","toCanvas","resizedCanvas","newFile","Ng2PicaModule","providers","useClass","ImgMaxPXSizeService","ng2PicaService","maxWidth","maxHeight","resizedFileSubject","currentWidth","currentHeight","Ng2ImgMaxService","imgMaxSizeService","imgMaxPXSizeService","compress","getEXIFOrientedImage","optionsNoAutoClose","folderName","droppedFile","fileEntry","isFile","ImagePath","AlbumName","albumId","_elementRef","AlbumId","findIndex","focusOut","tried","currency","editMode","PendingCopy","text","_document","textarea","_textarea","top","opacity","left","setAttribute","appendChild","successful","currentFocus","activeElement","setSelectionRange","execCommand","_a","parentNode","removeChild","Clipboard","pendingCopy","beginCopy","copy","CKD_COPY_TO_CLIPBOARD_CONFIG","CdkCopyToClipboard","_clipboard","_ngZone","attempts","copied","_pending","Set","remainingAttempts","pending","attempt","_destroyed","_currentTimeout","delete","runOutsideAngular","ClipboardModule","FileOrImage","folderDisplayHierachy","absoluteurl","folderSearch","FileOrFolder","open","FilePath","browsePath","DisplayPath","Copy","View","getFiles","MessageId","messageDetail","activeUrl","SuccessMessage","ContactForm","Email","email","MessageBody","GetContactEntry","updateAsRead","AllData","faIcon","DisplayOrder","HomePage","filtered","parentPage","columnName","PartialPage","falcon","sanitize","CurrentNewsNEventId","m","a","b","Link","newsdate","today","badgeDate","Body","Ng2ImgMaxModule","NgxPhotoEditorModule","WebsiteRoutingModule","AlbumsModule","DefinePagesModule","TypeError","n","enumerable","configurable","writable","defineProperty","s","create","constructor","getOwnPropertyNames","u","setPrototypeOf","getPrototypeOf","__proto__","Reflect","construct","sham","Proxy","call","Function","arguments","Map","has","ReferenceError","l","d","getOwnPropertyDescriptor","values","entries","y","fromEntries","S","slice","String","substring","global","fetch","XMLHttpRequest","responseType","setRequestHeader","ok","status","arrayBuffer","send","A","defineProperties","isArray","O","_map","_keys","U","navigator","x","HTMLImageElement","B","process","versions","C","Buffer","BigInt","V","T","I","stack","L","ifd0","enabled","exif","makerNote","userComment","gps","interop","ifd1","jfif","xmp","iptc","icc","z","TextDecoder","F","decode","decodeURIComponent","escape","fromCharCode","E","le","byteOffset","_swapDataView","dataView","toUint8","_lengthToEnd","getUint8Array","join","getInt8","getUint8","getInt16","getInt32","getFloat32","getFloat64","getUint64","D","concat","R","kind","N","M","W","K","H","G","onloadend","readAsArrayBuffer","J","X","q","read","Q","Y","Z","allKeys","allValues","$","ee","te","ne","re","ie","se","ae","ue","oe","fe","he","ce","translateKeys","translateValues","reviveValues","de","parse","applyInheritables","canBeFiltered","dict","translateTagSet","pick","skip","deps","tagKeys","tagValues","me","ve","tiff","multiSegment","mergeOutput","silentErrors","chunked","firstChunkSize","firstChunkSizeNode","firstChunkSizeBrowser","chunkSize","chunkLimit","pe","ye","setupFromTrue","setupFromUndefined","setupFromArray","setupFromObject","filterNestedSegmentTags","traverseTiffDependencyTree","checkLoadedPlugins","setupGlobalFilters","thumbnail","ke","batchEnableWithBool","batchEnableWithUserValue","ge","needed","some","finalizeFilters","be","we","Ae","Oe","Se","Pe","Ue","xe","useCached","fileParser","isTiff","isJpeg","getString","isHeic","parsers","setup","errors","assignToOutput","all","close","getOrFindSegment","start","ensureSegmentChunk","extractThumbnail","Be","Ce","je","_e","latitude","longitude","Ve","Te","Ie","Le","freeze","thumbnailUrl","Exifr","fileParsers","segmentParsers","fileReaders","tagRevivers","createDictionary","extendDictionary","fetchUrlAsArrayBuffer","readBlobAsArrayBuffer","chunkedProps","otherSegments","segments","tiffBlocks","segmentsAndBlocks","tiffExtractables","inheritables","allFormatters","Options","disableAllOptions","gpsOnlyOptions","orientationOnlyOptions","thumbnailOnlyOptions","ze","Fe","Ee","ranges","_extend","allocUnsafe","uintView","_tryExtend","available","readChunk","De","end","shift","Re","Ne","Me","We","input","_swapArrayBuffer","nextChunkOffset","fullyRead","chunksRead","safeWrapAddress","_readChunk","readChunked","readWhole","Ke","chunk","JSON","stringify","subarray","extendOptions","He","normalizeInput","globalOptions","localOptions","canTranslate","headerLength","translated","translateBlock","raw","translateValue","assignObjectToOutput","Ge","Je","Xe","qe","Qe","Ye","Ze","$e","et","tt","nt","rt","canHandle","findAppSegments","readSegments","mergeMultiSegments","createParsers","appSegments","findAll","wanted","keyList","remaining","unfinishedMultiSegment","setupSegmentFinderArgs","_findAppSegments","onlyTiff","canReadNextChunk","readNextChunk","findPosition","chunkNumber","chunkCount","recordUnknownSegments","unknownSegments","stopAfterSos","recordJpegSegments","jpegSegments","mergedAppSegments","handleMultiSegments","getSegment","st","at","ut","ot","ft","parseHeader","parseIfd0Block","saveParseBlock","createOutput","handleError","ifd0Offset","ifd1Offset","findIfd0Offset","parseTags","ensureChunk","parseBlock","exifOffset","interopOffset","gpsOffset","unpack","ht","parseExifBlock","ifd1Parsed","findIfd1Offset","headerParsed","parseThumbnailBlock","parseTag","parseTagValue","Uint16Array","Uint32Array","Int8Array","Int16Array","Int32Array","Float32Array","Float64Array","getFloat","getDouble","default","exports","module","code","1","_dereq_","inherits","Multimath","mm_unsharp_mask","mm_resize","MathLib","requested_features","__requested_features","js","wasm","has_wasm","use","resizeAndUnsharp","cache","unsharpAmount","unsharp_mask","toWidth","toHeight","unsharpRadius","unsharpThreshold","2","clampTo8","convolveHorizontally","dest","srcW","srcH","destW","filters","filterPtr","filterShift","filterSize","srcPtr","srcY","destX","filterVal","srcOffset","destOffset","convolveVertically","3","4","wasm_fn","wasm_src","5","createFilters","destH","alpha","filtersX","filtersY","tmp","dst","ptr","resetAlpha","6","FILTER_INFO","toFixedPoint","num","srcSize","destSize","destPixel","srcPixel","srcFirst","srcLast","filterElementSize","floatFilter","fxpFilter","total","pxl","idx","floatVal","filterTotal","leftNotEmpty","rightNotEmpty","filterFunction","scaleInverted","scaleClamped","srcWindow","win","maxFilterElementSize","packedFilter","packedFilterPtr","slowCopy","7","xpi","sin","cos","8","IS_LE","__","copyInt16asLE","target_offset","asUint8Array","tmp_offset","__align","filtersX_offset","filtersY_offset","__instance","mem","__memory","mem32","src32","convolveHV","_convolveHV","9","Pool","idle","acquired","lastId","timeoutId","acquire","resource","pop","release","_this2","lastUsed","now","gc","_this3","10","fromWidth","fromHeight","srcTileSize","destTileBorder","minScale","stageCount","pow","11","PIXEL_EPSILON","pixelFloor","nearest","pixelCeil","innerX","innerY","toTileWidth","toTileHeight","innerTileWidth","innerTileHeight","tile","tiles","toX","toY","toInnerX","toInnerY","toInnerWidth","toInnerHeight","12","objClass","obj","isCanvas","cname","isImage","isImageBitmap","limiter","concurrency","queue","roll","cib_quality_name","cib_support","createCanvas","createImageBitmap","resizeWidth","resizeHeight","resizeQuality","bitmap","13","mathLib","onmessage","ev","opts","postMessage","14","a0","a1","a2","a3","b1","b2","convolveMono16","line","coeff","prev_src","curr_src","curr_out","prev_out","prev_prev_out","src_index","out_index","line_index","coeff_a0","coeff_a1","coeff_b1","coeff_b2","radius","tmp_line","sigma","exp","g1","g2","gaussCoef","15","ctor","superCtor","super_","TempCtor","16","base64decode","hasWebAssembly","DEFAULT_OPTIONS","MultiMath","__cache","__init_promise","__modules","modules","__wasm","__isLE","init","WebAssembly","compile","__base64decode","__reallocate","Memory","initial","mem_size","grow","memsize","env_extra","env_base","memoryBase","memory","tableBase","table","Table","Instance","env","number","base","reminder","17","str","bits","charAt","tailbits","18","19","20","glur_mono16","hsl_l16","amount","threshold","m1","m2","hShifted","diff","iTimes4","lightness","blured","amountFp","thresholdFp","21","pixels","img_bytes_cnt","hsl_bytes_cnt","blur_bytes_cnt","blur_line_byte_cnt","hsl_offset","blur_offset","blur_tmp_offset","blur_line_offset","blur_coeffs_offset","img32","_hsl_l16","blurMono16","_blurMono16","unsharp","_unsharp","22","23","wa","bin","24","getOwnPropertySymbols","propIsEnumerable","propertyIsEnumerable","toObject","val","test1","test2","test3","letter","shouldUseNative","symbols","25","bundleFn","sources","wkey","cacheKeys","wcache","skey","scache","workerSources","resolveSources","depPath","depKey","webkitURL","mozURL","msURL","bare","workerUrl","worker","Worker","objectURL","_arrayLikeToArray","arr2","webworkify","utils","createStages","createRegions","singletones","NEED_SAFARI_FIX","userAgent","hardwareConcurrency","CAN_NEW_IMAGE_DATA","CAN_CREATE_IMAGE_BITMAP","DEFAULT_PICA_OPTS","tmpCanvas","DEFAULT_RESIZE_OPTS","workerFabric","terminate","Pica","limiter_key","__limit","cib","ww","__workersPool","__mathlib","__initPromise","ImageData","Uint8ClampedArray","ImageBitmap","debug","wpool_key","checkCibResize","initMath","mathlib","canceled","cancelToken","toCtx","Boolean","imageBitmap","tmpCtx","iData","tileAndResize","srcCtx","srcImageBitmap","isImageBitmapReused","jobs","srcImageData","globalCompositeOperation","preload","wasm_nodule","invokeResize","toImageData","processTile","cleanup","processStages","stages","_stages$shift2","_arrayWithHoles","Symbol","iterator","_arr","_n","_d","_s","_i","_iterableToArrayLimit","minLen","_unsupportedIterableToArray","_nonIterableRest","isLastStage","mimeType","convertToBlob","asString","asBuffer","_typeof","_classCallCheck","Constructor","_defineProperties","props","descriptor","_defineProperty","ownKeys","object","enumerableOnly","sym","_objectSpread2","getOwnPropertyDescriptors","_toConsumableArray","_arrayWithoutHoles","iter","_iterableToArray","_nonIterableSpread","IS_BROWSER","WINDOW","IS_TOUCH_DEVICE","documentElement","HAS_POINTER_EVENT","NAMESPACE","ACTION_ALL","ACTION_CROP","ACTION_MOVE","ACTION_ZOOM","ACTION_EAST","ACTION_WEST","ACTION_SOUTH","ACTION_NORTH","ACTION_NORTH_EAST","ACTION_NORTH_WEST","ACTION_SOUTH_EAST","ACTION_SOUTH_WEST","CLASS_CROP","CLASS_DISABLED","CLASS_HIDDEN","CLASS_HIDE","CLASS_INVISIBLE","CLASS_MODAL","CLASS_MOVE","DATA_ACTION","DATA_PREVIEW","DRAG_MODE_CROP","DRAG_MODE_MOVE","DRAG_MODE_NONE","EVENT_CROP","EVENT_CROP_END","EVENT_CROP_MOVE","EVENT_CROP_START","EVENT_DBLCLICK","EVENT_POINTER_DOWN","EVENT_POINTER_MOVE","EVENT_POINTER_UP","EVENT_READY","EVENT_RESIZE","EVENT_WHEEL","EVENT_ZOOM","MIME_TYPE_JPEG","REGEXP_ACTIONS","REGEXP_DATA_URL","REGEXP_DATA_URL_JPEG","REGEXP_TAG_NAME","DEFAULTS","viewMode","dragMode","initialAspectRatio","NaN","preview","responsive","restore","checkCrossOrigin","checkOrientation","modal","guides","center","highlight","background","autoCropArea","movable","rotatable","scalable","zoomable","zoomOnTouch","zoomOnWheel","wheelZoomRatio","cropBoxMovable","cropBoxResizable","toggleDragModeOnDblclick","minCanvasWidth","minCanvasHeight","minCropBoxWidth","minCropBoxHeight","minContainerWidth","minContainerHeight","cropstart","cropmove","cropend","zoom","isNumber","isPositiveNumber","Infinity","isUndefined","isObject","isPlainObject","_constructor","isFunction","toArray","callback","_len","args","_key","arg","REGEXP_DECIMALS","normalizeDecimalNumber","times","REGEXP_SUFFIX","setStyle","property","addClass","elem","classList","className","removeClass","toggleClass","added","REGEXP_CAMEL_CASE","toParamCase","dataset","getAttribute","REGEXP_SPACES","onceSupported","supported","once","listener","removeEventListener","removeListener","handler","listeners","addListener","_handler","_element$listeners","_len2","_key2","dispatchEvent","Event","CustomEvent","bubbles","cancelable","createEvent","initCustomEvent","getOffset","box","getBoundingClientRect","pageXOffset","clientLeft","pageYOffset","clientTop","location","REGEXP_ORIGINS","isCrossOriginURL","parts","protocol","hostname","port","addTimestamp","timestamp","getTransforms","_ref","translateX","translateY","WebkitTransform","msTransform","getPointer","_ref2","endOnly","pageX","pageY","endX","endY","startX","startY","getAdjustedSizes","_ref4","isValidWidth","isValidHeight","adjustedWidth","getSourceCanvas","_ref6","_ref7","_ref8","imageAspectRatio","imageNaturalWidth","imageNaturalHeight","_ref6$rotate","_ref6$scaleX","_ref6$scaleY","_ref8$fillColor","fillColor","_ref8$imageSmoothingE","imageSmoothingEnabled","_ref8$imageSmoothingQ","imageSmoothingQuality","_ref8$maxWidth","_ref8$maxHeight","_ref8$minWidth","minWidth","_ref8$minHeight","minHeight","maxSizes","minSizes","destMaxSizes","destMinSizes","destWidth","destHeight","save","param","REGEXP_DATA_URL_HEAD","render","initContainer","initCanvas","initCropBox","renderCanvas","cropped","renderCropBox","container","containerData","rotated","canvasWidth","canvasHeight","canvasData","limited","limitCanvas","oldLeft","oldTop","initialCanvasData","sizeLimited","positionLimited","cropBoxData","_getAdjustedSizes","newCanvasLeft","newCanvasTop","minLeft","minTop","maxLeft","maxTop","changed","_getRotatedSizes","_ref5","degree","arc","sinArc","cosArc","getRotatedSizes","renderImage","limitCropBox","initialCropBoxData","maxCropBoxWidth","maxCropBoxHeight","face","cropBox","initPreview","crossOriginUrl","alt","viewBox","viewBoxImage","previews","ownerDocument","querySelectorAll","querySelector","html","innerHTML","cssText","resetPreview","removeAttribute","removeData","cropBoxWidth","cropBoxHeight","originalWidth","originalHeight","getElementsByTagName","events","onCropStart","cropStart","onWheel","wheel","passive","capture","onDblclick","dblclick","onCropMove","cropMove","onCropEnd","cropEnd","unbind","handlers","getCanvasData","getCropBoxData","setCanvasData","setCropBoxData","setDragMode","dragBox","delta","wheeling","deltaY","wheelDelta","buttons","pointerType","ctrlKey","action","pointers","changedTouches","touch","identifier","pointerId","originalEvent","cropping","right","bottom","renderable","pointer","range","check","side","pointers2","maxRatio","pointer2","z1","getMaxZoomRatio","methods","initialImageData","hasSameSize","isImg","replaced","uncreate","load","disable","originalUrl","_this$canvasData","moveTo","_originalEvent","zoomTo","pivot","oldRatio","_ref3","getPointersCenter","rotateTo","_scaleX","_scaleY","rounded","getContainerData","sized","widthChanged","heightChanged","getCroppedCanvas","HTMLCanvasElement","_this$getData","initialX","initialY","initialWidth","initialHeight","_options$imageSmoothi","srcWidth","srcHeight","dstX","dstY","dstWidth","dstHeight","sourceWidth","sourceHeight","srcX","setAspectRatio","croppable","AnotherCropper","Cropper","tagName","reloading","sizing","staticProps","protoProps","binary","uint8","clone","xhr","onabort","ontimeout","onprogress","getResponseHeader","abort","withCredentials","littleEndian","app1Start","ifdStart","tiffOffset","getStringFromCharCode","endianness","firstIFDOffset","_offset","_length","setUint16","resetAndGetOrientation","chunks","btoa","arrayBufferToDataURL","_parseOrientation","parseOrientation","stop","insertBefore","nextSibling","isIOSWebKit","build","sizingImage","getElementsByClassName","unbuild"],"mappings":"wKAqEO,MAAMA,G,s5DC3DD,mRACI,4IACA,qKAA0E,c,OAA1E,EAKI,U,8BALJ,gBACI,gEAAK,8BACD,+DAAI,0HAA4D,yCACpB,cALxD,QAAK,OAAL,QAAoB,gBAA2B,cAGlC,mCAC+D,sG,8BAiBh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hT,KAAKunE,QAAS,EACdvnE,KAAK6lE,OAAQ,GACJ7lE,KAAKsnE,WACdtnE,KAAK6nE,IAAIC,QAAU,KACnB9nE,KAAK6nE,IAAIK,SACAloE,KAAKiE,OACdjE,KAAKopE,YAr9GKrZ,EAAkBD,EAAYz5B,UAAWoxC,GACrDD,GAAazX,EAAkBD,EAAa0X,GA8+GzCJ,EAh/GT,IAAsBtX,EAAa2X,EAAYD,EA0lGpB,GA2Z3B,OAFA56D,GAAOw6D,GAAQ/wC,UAAWmnC,GAAQtJ,GAASqN,GAAQc,GAAUx7C,GAAQ09C,IAE9D6C,GA1hHyE51D","file":"modules-website-module-ngfactory.89f316711942f7602d7e.js","sourcesContent":["import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { SharedModule } from 'primeng/api';\r\nimport { WebsiteComponents, WebsiteRoutingModule } from './website-routing.module';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { NgxFileDropModule } from 'ngx-file-drop';\r\nimport { HttpClientModule } from '@angular/common/http';\r\nimport { RouterModule } from '@angular/router';\r\nimport { NgbModule } from '@ng-bootstrap/ng-bootstrap';\r\nimport { Ng2ImgMaxModule } from 'ng2-img-max';\r\nimport { ImageCropperModule } from 'ngx-image-cropper';\r\nimport { NgxDropzoneModule } from 'ngx-dropzone';\r\nimport {NgxPhotoEditorModule} from \"ngx-photo-editor\";\r\nimport { MatCardModule } from '@angular/material/card';\r\nimport { MatProgressBarModule } from '@angular/material/progress-bar';\r\nimport { MatIconModule } from '@angular/material/icon';\r\nimport { MatFormFieldModule } from '@angular/material/form-field';\r\nimport { MatSelectModule } from '@angular/material/select';\r\nimport { MatProgressSpinnerModule } from '@angular/material/progress-spinner';\r\nimport { MatCheckboxModule } from '@angular/material/checkbox';\r\nimport { CKEditorModule } from 'ng2-ckeditor';\r\nimport { MatTableModule } from '@angular/material/table';\r\nimport { MatPaginatorModule } from '@angular/material/paginator';\r\nimport { MatDividerModule } from '@angular/material/divider';\r\nimport { MaterialModule } from '../shared/material/material.module';\r\nimport { SharedhomepageModule } from './sharedhomepage.module';\r\nimport { FlexLayoutModule } from '@angular/flex-layout';\r\nimport { AlbumsModule } from './photogallery/albums/albums.module';\r\nimport { DefinePagesModule } from './define-pages/define-pages.module';\r\n\r\n@NgModule({\r\n declarations: [WebsiteComponents],\r\n imports: [\r\n CommonModule,\r\n NgxFileDropModule, \r\n NgbModule , \r\n HttpClientModule,\r\n FormsModule, \r\n ImageCropperModule, \r\n NgxDropzoneModule,\r\n RouterModule,\r\n SharedModule,\r\n SharedhomepageModule,\r\n ReactiveFormsModule, \r\n Ng2ImgMaxModule,\r\n NgxPhotoEditorModule,\r\n MatCardModule,\r\n MatProgressBarModule,\r\n MatIconModule,\r\n MatFormFieldModule,\r\n MatSelectModule,\r\n MatProgressSpinnerModule,\r\n MatCheckboxModule,\r\n CKEditorModule,\r\n MatTableModule,\r\n MatPaginatorModule,\r\n MatDividerModule,\r\n WebsiteRoutingModule,\r\n //ClipboardModule \r\n MaterialModule,\r\n FlexLayoutModule,\r\n AlbumsModule,\r\n //SharedhomepageModule\r\n DefinePagesModule\r\n \r\n \r\n ],\r\n exports:[WebsiteComponents,FlexLayoutModule]\r\n})\r\nexport class WebsiteModule { }\r\n","\r\n\r\n\r\n {{PageTitle}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n \r\n\r\n \r\n \r\n \r\n \r\n\r\n","\r\n
\r\n \r\n
","\r\n","
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
","import { Pipe, PipeTransform,Sanitizer } from '@angular/core';\r\nimport { DomSanitizer, SafeHtml } from '@angular/platform-browser';\r\n\r\n@Pipe({\r\n name: 'encodeHTML'\r\n})\r\nexport class EncodeHTMLPipe implements PipeTransform {\r\n constructor(private sanitizer:DomSanitizer){}\r\n transform(value:string): SafeHtml {\r\n \r\n return this.sanitizer.bypassSecurityTrustHtml(value);\r\n \r\n }\r\n\r\n}\r\n","import { ChangeDetectorRef, Component, OnInit } from '@angular/core';\r\nimport { ThemePalette } from '@angular/material/core';\r\nimport { ProgressSpinnerMode } from '@angular/material/progress-spinner';\r\n//import { DomSanitizer } from '@angular/platform-browser';\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport { globalconstants } from 'src/app/shared/globalconstant';\r\nimport { List } from 'src/app/shared/interface';\r\nimport { SharedataService } from 'src/app/shared/sharedata.service';\r\nimport { TokenStorageService } from 'src/app/_services/token-storage.service';\r\nimport { NaomitsuService } from '../../../shared/databaseService'\r\n\r\n//@Pipe({ name: 'safeHtml' })\r\n@Component({\r\n\r\n selector: 'app-displaypage',\r\n templateUrl: './displaypage.component.html',\r\n styleUrls: ['./displaypage.component.scss']\r\n})\r\nexport class DisplaypageComponent implements OnInit {\r\n images = [];\r\n Name = {};\r\n ImgUrl = '';\r\n loading: boolean = false;\r\n color: ThemePalette = 'primary';\r\n mode: ProgressSpinnerMode = 'determinate';\r\n value = 50;\r\n GroupId: number;\r\n pId: number;\r\n HomePageId: number;\r\n loop: number = 0;\r\n ParentPage = \"\";\r\n Title: string = \"\";\r\n PageBody: string = '';\r\n ParentLink = '';\r\n constructor(\r\n private naomitsuService: NaomitsuService,\r\n private ar: ActivatedRoute,\r\n private route: Router,\r\n private shareddata: SharedataService,\r\n private dataStorage: TokenStorageService\r\n //private cdref: ChangeDetectorRef\r\n //private sanitized: DomSanitizer\r\n ) {\r\n\r\n }\r\n\r\n ngOnInit(): void {\r\n //console.log('window', window.location.href);\r\n this.loading = true;\r\n this.GroupId = 0;\r\n this.ar.queryParamMap.subscribe(params => {\r\n this.GroupId = +params.get(\"GroupId\");\r\n\r\n });\r\n\r\n //if (this.images.length == 0)\r\n // this.getRandomDisplayPhotoes();\r\n\r\n this.ar.paramMap.subscribe(params => {\r\n this.pId = +params.get(\"pid\");\r\n this.shareddata.CurrentRandomImages.subscribe(r => {\r\n this.images = r;\r\n if (this.images.length == 0)\r\n this.getRandomDisplayPhotoes(params.get('phid'));\r\n else\r\n this.GetLatestPage(params.get('phid'));\r\n })\r\n })\r\n\r\n\r\n }\r\n ngAfterContentChecked() {\r\n\r\n }\r\n\r\n back() {\r\n if (this.GroupId == 0)\r\n this.route.navigate(['/home']);\r\n else\r\n this.route.navigate(['/home/about/' + this.GroupId]);\r\n }\r\n GetLatestPage(pHistoryId) {\r\n debugger;\r\n let IdtoDisplay = pHistoryId;\r\n //let pages: any[];\r\n let filterstring = '';\r\n if (pHistoryId == 0)\r\n filterstring = \"Active eq 1 and HomePage eq 1\";\r\n else\r\n filterstring = \"Active eq 1 and PageId eq \" + this.pId;\r\n\r\n let list: List = new List();\r\n list.fields = [\r\n \"link\", \"PageId\", \"ParentId\", \"PhotoPath\",\r\n \"PageTitle\", \"HomePage\", \"FullPath\",\r\n \"PageHistories/PageBody\",\r\n \"PageHistories/PageHistoryId\",\r\n \"PageHistories/ParentPageId\"];\r\n list.lookupFields = [\"PageHistories\"];\r\n list.PageName = \"Pages\";\r\n list.filter = [filterstring];\r\n this.ImgUrl = '';\r\n this.PageBody ='';\r\n this.loading =true;\r\n this.naomitsuService.get(list)\r\n .subscribe((data: any) => {\r\n if (data.value.length > 0) {\r\n let pagetodisplay = [...data.value];\r\n if (IdtoDisplay == 0) {\r\n ///home/display/44/87\r\n IdtoDisplay = +pagetodisplay[0].link.split('/')[3];\r\n }\r\n \r\n this.AssignImageUrl(pagetodisplay[0].PhotoPath);\r\n \r\n //for link below title\r\n this.getParentPageLink(pagetodisplay[0].ParentId);\r\n\r\n this.PageBody = pagetodisplay[0].PageHistories.filter(h => h.PageHistoryId == IdtoDisplay)[0].PageBody;\r\n //this.ParentPage = pagetodisplay[0].PageTitle;\r\n this.Title = pagetodisplay[0].PageTitle;\r\n this.loading = false;\r\n }\r\n })\r\n\r\n }\r\n AssignImageUrl(photoPath) {\r\n if (photoPath == \"\" || photoPath == null)\r\n this.ImgUrl = this.images[Math.floor(Math.random() * this.images.length)];\r\n else\r\n this.ImgUrl = globalconstants.apiUrl + \"/Image/PagePhoto/\" + photoPath;\r\n }\r\n getParentPageLink(ParentId) {\r\n let Parent;\r\n this.ParentPage = '';\r\n this.shareddata.CurrentPagesData.subscribe(p => {\r\n Parent = p.filter(item => item.PageId == ParentId);\r\n if (Parent.length > 0) {\r\n this.ParentLink = Parent[0].link;\r\n this.ParentPage = Parent[0].label;\r\n }\r\n })\r\n\r\n }\r\n getRandomDisplayPhotoes(PhId) {\r\n let list: List = new List();\r\n list.fields = [\"FileId\", \"FileName\", \"ParentId\"];\r\n list.PageName = \"FilesNPhotoes\";\r\n list.filter = ['Active eq 1 and FileOrPhoto eq 0'];// eq ' + this.searchForm.get(\"FilesNPhoto\").value];\r\n this.naomitsuService.get(list)\r\n .subscribe((data: any) => {\r\n //this.images =\r\n let RandomImagesParentId = data.value.filter(image => {\r\n return image.FileName != null && image.FileName.toLowerCase() == \"random images\"\r\n });\r\n if (RandomImagesParentId.length > 0) {\r\n this.images = data.value.filter(rimg => rimg.ParentId == RandomImagesParentId[0].FileId)\r\n .map(element => {\r\n return globalconstants.apiUrl + \"/Image/random images/\" + element.FileName\r\n\r\n });\r\n this.shareddata.ChangeRandomImages(this.images);\r\n this.GetLatestPage(PhId);\r\n }\r\n })\r\n }\r\n getPageFromHistory(IdtoDisplay) {\r\n let list: List = new List();\r\n list.fields = [\"PageHistoryId\", \"PageBody\", \"Page/PageTitle\", \"ParentPageId\"];\r\n list.lookupFields = [\"Page\"];\r\n list.PageName = \"PageHistories\";\r\n list.filter = [\"PageHistoryId eq \" + IdtoDisplay];\r\n this.naomitsuService.get(list)\r\n .subscribe((data: any) => {\r\n if (data.value.length > 0) {\r\n //console.log(data.value[0])\r\n this.Title = data.value[0].Page.PageTitle;\r\n this.PageBody = data.value[0].PageBody\r\n if (this.GroupId > 0)\r\n this.GetParentPage(this.GroupId);\r\n else\r\n this.GetParentPage(data.value[0].ParentPageId);\r\n this.loop = 0;\r\n }\r\n this.loading = false;\r\n });\r\n }\r\n getHomePageId() {\r\n let list: List = new List();\r\n list.fields = [\"PageId\", \"PageTitle\", \"ParentId\"];\r\n list.PageName = \"Pages\";\r\n list.filter = [\"Active eq 1 and HomePage eq 1\"];\r\n this.naomitsuService.get(list)\r\n .subscribe((data: any) => {\r\n if (data.value.length > 0)\r\n this.GroupId = data.value[0].PageId;\r\n });\r\n }\r\n GetParentPage(parentId) {\r\n let list: List = new List();\r\n list.fields = [\"PageId\", \"PageTitle\", \"ParentId\"];\r\n list.PageName = \"Pages\";\r\n list.filter = [\"Active eq 1 and PageId eq \" + parentId];\r\n this.naomitsuService.get(list)\r\n .subscribe((data: any) => {\r\n debugger;\r\n if (data.value.length > 0)\r\n\r\n if (this.loop == 0 && data.value[0].ParentId > 0) {\r\n this.loop = 1\r\n this.GetParentPage(data.value[0].ParentId)\r\n }\r\n else\r\n this.ParentPage = data.value[0].PageTitle;\r\n });\r\n }\r\n}\r\n","\r\n {{Title}}\r\n 0\">\r\n \r\n {{ParentPage}} > {{Title}}\r\n \r\n \r\n {{ParentPage }} > {{ Title}}\r\n \r\n \r\n \r\n\r\n \r\n\r\n
\r\n
 
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n

\r\n \r\n
\r\n
\r\n\r\n\r\n
\r\n
","\n\n \n \n \n \n \n \n\n
\n
\n
\n","import { Component, OnInit, VERSION } from '@angular/core';\r\nimport { NgbCarouselConfig } from \"@ng-bootstrap/ng-bootstrap\";\r\nimport { List } from 'src/app/shared/interface';\r\nimport { NaomitsuService } from '../../../shared/databaseService'\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport {globalconstants } from '../../../shared/globalconstant';\r\n@Component({\r\n selector: 'carousel, [carousel]',\r\n templateUrl: './carousel.component.html',\r\n styleUrls: ['./carousel.component.scss'],\r\n providers: [NgbCarouselConfig]\r\n})\r\n\r\nexport class CarouselComponent implements OnInit {\r\n \r\n selectedAlbum: string;\r\n selectedAlbumId: number;\r\n loading =true;\r\n unique = [];\r\n Albums: any[];\r\n name = \"Angular \" + VERSION.major;\r\n error=\"\";\r\n folderHierarachy='Image/';\r\n images = [\r\n {\r\n PhotoId: 0,\r\n PhotoPath: \"\",\r\n Description: \"\",\r\n UpdatableName: \"\"\r\n }\r\n ];// [100, 500, 700, 800, 807].map(n => `https://picsum.photos/id/${n}/900/500`);\r\n\r\n constructor(private config: NgbCarouselConfig,\r\n private dataservice: NaomitsuService,\r\n private route: ActivatedRoute,\r\n private nav: Router) {\r\n // customize default values of carousels used by this component tree\r\n config.interval = 3000;\r\n config.keyboard = true;\r\n config.pauseOnHover = false;\r\n config.animation = true;\r\n this.route.paramMap.subscribe(item => {\r\n this.selectedAlbumId = +this.route.snapshot.queryParamMap.get('fileId');//item.get('AlbumId')\r\n //console.log('this.selectedAlbum',item);\r\n })\r\n\r\n }\r\n\r\n ngOnInit() {\r\n this.getPhotoes();\r\n }\r\n\r\n getPhotoes() {\r\n\r\n let list: List = new List();\r\n list.fields = [\"FileId\", \"FileName\", \"Description\", \"UpdatedFileFolderName\", \"ParentId\"];\r\n //list.lookupFields = [\"Album\"];\r\n list.PageName = \"FilesNPhotoes\";\r\n list.filter = [\"Active eq 1 and FileOrPhoto eq 1 and (FileOrFolder eq 1 or ParentId eq \" + this.selectedAlbumId+\" or FileId eq \" + this.selectedAlbumId+\")\"];\r\n list.orderBy = \"UploadDate desc\";\r\n this.loading=true;\r\n this.dataservice.get(list)\r\n .subscribe((data: any) => {\r\n //debugger;\r\n if (data.value.length > 0) {\r\n var browsePath='';\r\n this.selectedAlbum = data.value.filter(item=>{\r\n return item.FileId == this.selectedAlbumId\r\n })[0].UpdatedFileFolderName;\r\n this.Albums = [...data.value]; \r\n this.getNestedFolders(this.selectedAlbumId);\r\n this.images = data.value.filter(item=>{\r\n return item.ParentId ==this.selectedAlbumId\r\n })\r\n .map(item=>{\r\n //browsePath =globalconstants.apiUrl + \"/Image/\" + item.Album.AlbumName+ \"/\" + item.PhotoPath;\r\n browsePath = globalconstants.apiUrl + \"/\" + this.folderHierarachy + item.FileName;\r\n return { \r\n PhotoPath: browsePath,\r\n Description:item.Description\r\n }\r\n });\r\n // if (data.value.length == 1)\r\n // //this.config.animation=false;\r\n // this.selectedAlbum = data.value[0].UpdatedFileFolderName;// this.images[0].Album.AlbumName;\r\n // //console.log('this.images',this.images)\r\n }\r\n else\r\n this.error =\"No image to display\";\r\n // setTimeout(() => {\r\n this.loading=false; \r\n })\r\n }\r\n getNestedFolders(fileId) {\r\n let ParentItem = this.Albums.filter(item => item.FileId == fileId);\r\n debugger;\r\n while (ParentItem.length > 0) {\r\n this.folderHierarachy += ParentItem[0].FileName + \"/\";\r\n ParentItem = this.Albums.filter(item => item.FileId == ParentItem[0].ParentId)\r\n }\r\n }\r\n getAlbums() {\r\n\r\n let list: List = new List();\r\n list.fields = [\"FileId\", \"FileName\", \"UpdatedFileFolderName\", \"FileOrFolder\", \"UploadDate\", \"ParentId\", \"Active\"];\r\n list.PageName = \"FilesNPhotoes\";\r\n list.filter = ['Active eq 1 and FileOrFolder eq 1 and FileOrPhoto eq 1'];// + this.searchForm.get(\"FilesNPhoto\").value];\r\n list.orderBy = \"UploadDate desc\";\r\n //list.limitTo =10;\r\n this.dataservice.get(list)\r\n .subscribe((data: any) => {\r\n this.Albums = [...data.value] \r\n })\r\n }\r\n enlargeImg(element){\r\n element.style.transform = \"scale(1.5)\";\r\n // Animation effect \r\n element.style.transition = \"transform 0.25s ease\";\r\n }\r\n back() {\r\n this.nav.navigate([\"/home/browsephoto\"]);\r\n }\r\n\r\n}","\r\n\r\n \r\n

\r\n {{selectedAlbum}}\r\n \r\n
\r\n 1\"> \r\n \r\n \r\n \"{{image.Description}}\"\r\n \r\n
\r\n

{{image.Description}}

\r\n
\r\n
\r\n
\r\n
\r\n \"{{images[0].Description}}\"\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
","/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport function __createBinding(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n}\r\n\r\nexport function __exportStar(m, exports) {\r\n for (var p in m) if (p !== \"default\" && !exports.hasOwnProperty(p)) exports[p] = m[p];\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n};\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];\r\n result.default = mod;\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, privateMap) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to get private field on non-instance\");\r\n }\r\n return privateMap.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, privateMap, value) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to set private field on non-instance\");\r\n }\r\n privateMap.set(receiver, value);\r\n return value;\r\n}\r\n","import { Injectable, ɵɵdefineInjectable, EventEmitter, isDevMode, Component, ChangeDetectionStrategy, ChangeDetectorRef, ViewChild, Input, HostBinding, Output, HostListener, NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { DomSanitizer } from '@angular/platform-browser';\nimport { __awaiter } from 'tslib';\n\n/**\n * @fileoverview added by tsickle\n * Generated from: lib/interfaces/move-start.interface.ts\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\n/**\n * @record\n */\nimport * as ɵngcc0 from '@angular/core';\nimport * as ɵngcc1 from '@angular/platform-browser';\nimport * as ɵngcc2 from '@angular/common';\n\nconst _c0 = [\"wrapper\"];\nconst _c1 = [\"sourceImage\"];\nfunction ImageCropperComponent_img_2_Template(rf, ctx) { if (rf & 1) {\n const _r5 = ɵngcc0.ɵɵgetCurrentView();\n ɵngcc0.ɵɵelementStart(0, \"img\", 4, 5);\n ɵngcc0.ɵɵlistener(\"load\", function ImageCropperComponent_img_2_Template_img_load_0_listener() { ɵngcc0.ɵɵrestoreView(_r5); const ctx_r4 = ɵngcc0.ɵɵnextContext(); return ctx_r4.imageLoadedInView(); });\n ɵngcc0.ɵɵelementEnd();\n} if (rf & 2) {\n const ctx_r1 = ɵngcc0.ɵɵnextContext();\n ɵngcc0.ɵɵstyleProp(\"visibility\", ctx_r1.imageVisible ? \"visible\" : \"hidden\")(\"transform\", ctx_r1.safeTransformStyle);\n ɵngcc0.ɵɵproperty(\"src\", ctx_r1.safeImgDataUrl, ɵngcc0.ɵɵsanitizeUrl);\n} }\nfunction ImageCropperComponent_div_4_ng_container_2_Template(rf, ctx) { if (rf & 1) {\n const _r8 = ɵngcc0.ɵɵgetCurrentView();\n ɵngcc0.ɵɵelementContainerStart(0);\n ɵngcc0.ɵɵelementStart(1, \"span\", 9);\n ɵngcc0.ɵɵlistener(\"mousedown\", function ImageCropperComponent_div_4_ng_container_2_Template_span_mousedown_1_listener($event) { ɵngcc0.ɵɵrestoreView(_r8); const ctx_r7 = ɵngcc0.ɵɵnextContext(2); return ctx_r7.startMove($event, ctx_r7.moveTypes.Resize, \"topleft\"); })(\"touchstart\", function ImageCropperComponent_div_4_ng_container_2_Template_span_touchstart_1_listener($event) { ɵngcc0.ɵɵrestoreView(_r8); const ctx_r9 = ɵngcc0.ɵɵnextContext(2); return ctx_r9.startMove($event, ctx_r9.moveTypes.Resize, \"topleft\"); });\n ɵngcc0.ɵɵelement(2, \"span\", 10);\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(3, \"span\", 11);\n ɵngcc0.ɵɵelement(4, \"span\", 10);\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(5, \"span\", 12);\n ɵngcc0.ɵɵlistener(\"mousedown\", function ImageCropperComponent_div_4_ng_container_2_Template_span_mousedown_5_listener($event) { ɵngcc0.ɵɵrestoreView(_r8); const ctx_r10 = ɵngcc0.ɵɵnextContext(2); return ctx_r10.startMove($event, ctx_r10.moveTypes.Resize, \"topright\"); })(\"touchstart\", function ImageCropperComponent_div_4_ng_container_2_Template_span_touchstart_5_listener($event) { ɵngcc0.ɵɵrestoreView(_r8); const ctx_r11 = ɵngcc0.ɵɵnextContext(2); return ctx_r11.startMove($event, ctx_r11.moveTypes.Resize, \"topright\"); });\n ɵngcc0.ɵɵelement(6, \"span\", 10);\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(7, \"span\", 13);\n ɵngcc0.ɵɵelement(8, \"span\", 10);\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(9, \"span\", 14);\n ɵngcc0.ɵɵlistener(\"mousedown\", function ImageCropperComponent_div_4_ng_container_2_Template_span_mousedown_9_listener($event) { ɵngcc0.ɵɵrestoreView(_r8); const ctx_r12 = ɵngcc0.ɵɵnextContext(2); return ctx_r12.startMove($event, ctx_r12.moveTypes.Resize, \"bottomright\"); })(\"touchstart\", function ImageCropperComponent_div_4_ng_container_2_Template_span_touchstart_9_listener($event) { ɵngcc0.ɵɵrestoreView(_r8); const ctx_r13 = ɵngcc0.ɵɵnextContext(2); return ctx_r13.startMove($event, ctx_r13.moveTypes.Resize, \"bottomright\"); });\n ɵngcc0.ɵɵelement(10, \"span\", 10);\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(11, \"span\", 15);\n ɵngcc0.ɵɵelement(12, \"span\", 10);\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(13, \"span\", 16);\n ɵngcc0.ɵɵlistener(\"mousedown\", function ImageCropperComponent_div_4_ng_container_2_Template_span_mousedown_13_listener($event) { ɵngcc0.ɵɵrestoreView(_r8); const ctx_r14 = ɵngcc0.ɵɵnextContext(2); return ctx_r14.startMove($event, ctx_r14.moveTypes.Resize, \"bottomleft\"); })(\"touchstart\", function ImageCropperComponent_div_4_ng_container_2_Template_span_touchstart_13_listener($event) { ɵngcc0.ɵɵrestoreView(_r8); const ctx_r15 = ɵngcc0.ɵɵnextContext(2); return ctx_r15.startMove($event, ctx_r15.moveTypes.Resize, \"bottomleft\"); });\n ɵngcc0.ɵɵelement(14, \"span\", 10);\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(15, \"span\", 17);\n ɵngcc0.ɵɵelement(16, \"span\", 10);\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(17, \"span\", 18);\n ɵngcc0.ɵɵlistener(\"mousedown\", function ImageCropperComponent_div_4_ng_container_2_Template_span_mousedown_17_listener($event) { ɵngcc0.ɵɵrestoreView(_r8); const ctx_r16 = ɵngcc0.ɵɵnextContext(2); return ctx_r16.startMove($event, ctx_r16.moveTypes.Resize, \"top\"); })(\"touchstart\", function ImageCropperComponent_div_4_ng_container_2_Template_span_touchstart_17_listener($event) { ɵngcc0.ɵɵrestoreView(_r8); const ctx_r17 = ɵngcc0.ɵɵnextContext(2); return ctx_r17.startMove($event, ctx_r17.moveTypes.Resize, \"top\"); });\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(18, \"span\", 19);\n ɵngcc0.ɵɵlistener(\"mousedown\", function ImageCropperComponent_div_4_ng_container_2_Template_span_mousedown_18_listener($event) { ɵngcc0.ɵɵrestoreView(_r8); const ctx_r18 = ɵngcc0.ɵɵnextContext(2); return ctx_r18.startMove($event, ctx_r18.moveTypes.Resize, \"right\"); })(\"touchstart\", function ImageCropperComponent_div_4_ng_container_2_Template_span_touchstart_18_listener($event) { ɵngcc0.ɵɵrestoreView(_r8); const ctx_r19 = ɵngcc0.ɵɵnextContext(2); return ctx_r19.startMove($event, ctx_r19.moveTypes.Resize, \"right\"); });\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(19, \"span\", 20);\n ɵngcc0.ɵɵlistener(\"mousedown\", function ImageCropperComponent_div_4_ng_container_2_Template_span_mousedown_19_listener($event) { ɵngcc0.ɵɵrestoreView(_r8); const ctx_r20 = ɵngcc0.ɵɵnextContext(2); return ctx_r20.startMove($event, ctx_r20.moveTypes.Resize, \"bottom\"); })(\"touchstart\", function ImageCropperComponent_div_4_ng_container_2_Template_span_touchstart_19_listener($event) { ɵngcc0.ɵɵrestoreView(_r8); const ctx_r21 = ɵngcc0.ɵɵnextContext(2); return ctx_r21.startMove($event, ctx_r21.moveTypes.Resize, \"bottom\"); });\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(20, \"span\", 21);\n ɵngcc0.ɵɵlistener(\"mousedown\", function ImageCropperComponent_div_4_ng_container_2_Template_span_mousedown_20_listener($event) { ɵngcc0.ɵɵrestoreView(_r8); const ctx_r22 = ɵngcc0.ɵɵnextContext(2); return ctx_r22.startMove($event, ctx_r22.moveTypes.Resize, \"left\"); })(\"touchstart\", function ImageCropperComponent_div_4_ng_container_2_Template_span_touchstart_20_listener($event) { ɵngcc0.ɵɵrestoreView(_r8); const ctx_r23 = ɵngcc0.ɵɵnextContext(2); return ctx_r23.startMove($event, ctx_r23.moveTypes.Resize, \"left\"); });\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementContainerEnd();\n} }\nfunction ImageCropperComponent_div_4_Template(rf, ctx) { if (rf & 1) {\n const _r25 = ɵngcc0.ɵɵgetCurrentView();\n ɵngcc0.ɵɵelementStart(0, \"div\", 6);\n ɵngcc0.ɵɵlistener(\"keydown\", function ImageCropperComponent_div_4_Template_div_keydown_0_listener($event) { ɵngcc0.ɵɵrestoreView(_r25); const ctx_r24 = ɵngcc0.ɵɵnextContext(); return ctx_r24.keyboardAccess($event); });\n ɵngcc0.ɵɵelementStart(1, \"div\", 7);\n ɵngcc0.ɵɵlistener(\"mousedown\", function ImageCropperComponent_div_4_Template_div_mousedown_1_listener($event) { ɵngcc0.ɵɵrestoreView(_r25); const ctx_r26 = ɵngcc0.ɵɵnextContext(); return ctx_r26.startMove($event, ctx_r26.moveTypes.Move); })(\"touchstart\", function ImageCropperComponent_div_4_Template_div_touchstart_1_listener($event) { ɵngcc0.ɵɵrestoreView(_r25); const ctx_r27 = ɵngcc0.ɵɵnextContext(); return ctx_r27.startMove($event, ctx_r27.moveTypes.Move); });\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵtemplate(2, ImageCropperComponent_div_4_ng_container_2_Template, 21, 0, \"ng-container\", 8);\n ɵngcc0.ɵɵelementEnd();\n} if (rf & 2) {\n const ctx_r2 = ɵngcc0.ɵɵnextContext();\n ɵngcc0.ɵɵstyleProp(\"top\", ctx_r2.cropper.y1, \"px\")(\"left\", ctx_r2.cropper.x1, \"px\")(\"width\", ctx_r2.cropper.x2 - ctx_r2.cropper.x1, \"px\")(\"height\", ctx_r2.cropper.y2 - ctx_r2.cropper.y1, \"px\")(\"margin-left\", ctx_r2.alignImage === \"center\" ? ctx_r2.marginLeft : null)(\"visibility\", ctx_r2.imageVisible ? \"visible\" : \"hidden\");\n ɵngcc0.ɵɵclassProp(\"rounded\", ctx_r2.roundCropper);\n ɵngcc0.ɵɵadvance(2);\n ɵngcc0.ɵɵproperty(\"ngIf\", !ctx_r2.hideResizeSquares);\n} }\nfunction MoveStart() { }\nif (false) {\n /** @type {?} */\n MoveStart.prototype.active;\n /** @type {?} */\n MoveStart.prototype.type;\n /** @type {?} */\n MoveStart.prototype.position;\n /** @type {?} */\n MoveStart.prototype.x1;\n /** @type {?} */\n MoveStart.prototype.y1;\n /** @type {?} */\n MoveStart.prototype.x2;\n /** @type {?} */\n MoveStart.prototype.y2;\n /** @type {?} */\n MoveStart.prototype.clientX;\n /** @type {?} */\n MoveStart.prototype.clientY;\n}\n/** @enum {string} */\nconst MoveTypes = {\n Move: \"move\",\n Resize: \"resize\",\n Pinch: \"pinch\",\n};\n\n/**\n * @fileoverview added by tsickle\n * Generated from: lib/utils/resize.utils.ts\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\n/*\n * Hermite resize - fast image resize/resample using Hermite filter.\n * https://github.com/viliusle/Hermite-resize\n */\n/**\n * @param {?} canvas\n * @param {?} width\n * @param {?} height\n * @return {?}\n */\nfunction resizeCanvas(canvas, width, height) {\n /** @type {?} */\n const width_source = canvas.width;\n /** @type {?} */\n const height_source = canvas.height;\n width = Math.round(width);\n height = Math.round(height);\n /** @type {?} */\n const ratio_w = width_source / width;\n /** @type {?} */\n const ratio_h = height_source / height;\n /** @type {?} */\n const ratio_w_half = Math.ceil(ratio_w / 2);\n /** @type {?} */\n const ratio_h_half = Math.ceil(ratio_h / 2);\n /** @type {?} */\n const ctx = canvas.getContext('2d');\n if (ctx) {\n /** @type {?} */\n const img = ctx.getImageData(0, 0, width_source, height_source);\n /** @type {?} */\n const img2 = ctx.createImageData(width, height);\n /** @type {?} */\n const data = img.data;\n /** @type {?} */\n const data2 = img2.data;\n for (let j = 0; j < height; j++) {\n for (let i = 0; i < width; i++) {\n /** @type {?} */\n const x2 = (i + j * width) * 4;\n /** @type {?} */\n const center_y = j * ratio_h;\n /** @type {?} */\n let weight = 0;\n /** @type {?} */\n let weights = 0;\n /** @type {?} */\n let weights_alpha = 0;\n /** @type {?} */\n let gx_r = 0;\n /** @type {?} */\n let gx_g = 0;\n /** @type {?} */\n let gx_b = 0;\n /** @type {?} */\n let gx_a = 0;\n /** @type {?} */\n const xx_start = Math.floor(i * ratio_w);\n /** @type {?} */\n const yy_start = Math.floor(j * ratio_h);\n /** @type {?} */\n let xx_stop = Math.ceil((i + 1) * ratio_w);\n /** @type {?} */\n let yy_stop = Math.ceil((j + 1) * ratio_h);\n xx_stop = Math.min(xx_stop, width_source);\n yy_stop = Math.min(yy_stop, height_source);\n for (let yy = yy_start; yy < yy_stop; yy++) {\n /** @type {?} */\n const dy = Math.abs(center_y - yy) / ratio_h_half;\n /** @type {?} */\n const center_x = i * ratio_w;\n /** @type {?} */\n const w0 = dy * dy;\n for (let xx = xx_start; xx < xx_stop; xx++) {\n /** @type {?} */\n const dx = Math.abs(center_x - xx) / ratio_w_half;\n /** @type {?} */\n const w = Math.sqrt(w0 + dx * dx);\n if (w >= 1) {\n //pixel too far\n continue;\n }\n //hermite filter\n weight = 2 * w * w * w - 3 * w * w + 1;\n /** @type {?} */\n const pos_x = 4 * (xx + yy * width_source);\n //alpha\n gx_a += weight * data[pos_x + 3];\n weights_alpha += weight;\n //colors\n if (data[pos_x + 3] < 255)\n weight = weight * data[pos_x + 3] / 250;\n gx_r += weight * data[pos_x];\n gx_g += weight * data[pos_x + 1];\n gx_b += weight * data[pos_x + 2];\n weights += weight;\n }\n }\n data2[x2] = gx_r / weights;\n data2[x2 + 1] = gx_g / weights;\n data2[x2 + 2] = gx_b / weights;\n data2[x2 + 3] = gx_a / weights_alpha;\n }\n }\n canvas.width = width;\n canvas.height = height;\n //draw\n ctx.putImageData(img2, 0, 0);\n }\n}\n\n/**\n * @fileoverview added by tsickle\n * Generated from: lib/services/crop.service.ts\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\nclass CropService {\n /**\n * @param {?} sourceImage\n * @param {?} loadedImage\n * @param {?} cropper\n * @param {?} settings\n * @return {?}\n */\n crop(sourceImage, loadedImage, cropper, settings) {\n /** @type {?} */\n const imagePosition = this.getImagePosition(sourceImage, loadedImage, cropper, settings);\n /** @type {?} */\n const width = imagePosition.x2 - imagePosition.x1;\n /** @type {?} */\n const height = imagePosition.y2 - imagePosition.y1;\n /** @type {?} */\n const cropCanvas = (/** @type {?} */ (document.createElement('canvas')));\n cropCanvas.width = width;\n cropCanvas.height = height;\n /** @type {?} */\n const ctx = cropCanvas.getContext('2d');\n if (!ctx) {\n return;\n }\n if (settings.backgroundColor != null) {\n ctx.fillStyle = settings.backgroundColor;\n ctx.fillRect(0, 0, width, height);\n }\n /** @type {?} */\n const scaleX = (settings.transform.scale || 1) * (settings.transform.flipH ? -1 : 1);\n /** @type {?} */\n const scaleY = (settings.transform.scale || 1) * (settings.transform.flipV ? -1 : 1);\n /** @type {?} */\n const transformedImage = loadedImage.transformed;\n ctx.setTransform(scaleX, 0, 0, scaleY, transformedImage.size.width / 2, transformedImage.size.height / 2);\n ctx.translate(-imagePosition.x1 / scaleX, -imagePosition.y1 / scaleY);\n ctx.rotate((settings.transform.rotate || 0) * Math.PI / 180);\n ctx.drawImage(transformedImage.image, -transformedImage.size.width / 2, -transformedImage.size.height / 2);\n /** @type {?} */\n const output = {\n width, height,\n imagePosition,\n cropperPosition: Object.assign({}, cropper)\n };\n if (settings.containWithinAspectRatio) {\n output.offsetImagePosition = this.getOffsetImagePosition(sourceImage, loadedImage, cropper, settings);\n }\n /** @type {?} */\n const resizeRatio = this.getResizeRatio(width, height, settings);\n if (resizeRatio !== 1) {\n output.width = Math.round(width * resizeRatio);\n output.height = settings.maintainAspectRatio\n ? Math.round(output.width / settings.aspectRatio)\n : Math.round(height * resizeRatio);\n resizeCanvas(cropCanvas, output.width, output.height);\n }\n output.base64 = cropCanvas.toDataURL('image/' + settings.format, this.getQuality(settings));\n return output;\n }\n /**\n * @private\n * @param {?} sourceImage\n * @param {?} loadedImage\n * @param {?} cropper\n * @param {?} settings\n * @return {?}\n */\n getImagePosition(sourceImage, loadedImage, cropper, settings) {\n /** @type {?} */\n const sourceImageElement = sourceImage.nativeElement;\n /** @type {?} */\n const ratio = loadedImage.transformed.size.width / sourceImageElement.offsetWidth;\n /** @type {?} */\n const out = {\n x1: Math.round(cropper.x1 * ratio),\n y1: Math.round(cropper.y1 * ratio),\n x2: Math.round(cropper.x2 * ratio),\n y2: Math.round(cropper.y2 * ratio)\n };\n if (!settings.containWithinAspectRatio) {\n out.x1 = Math.max(out.x1, 0);\n out.y1 = Math.max(out.y1, 0);\n out.x2 = Math.min(out.x2, loadedImage.transformed.size.width);\n out.y2 = Math.min(out.y2, loadedImage.transformed.size.height);\n }\n return out;\n }\n /**\n * @private\n * @param {?} sourceImage\n * @param {?} loadedImage\n * @param {?} cropper\n * @param {?} settings\n * @return {?}\n */\n getOffsetImagePosition(sourceImage, loadedImage, cropper, settings) {\n /** @type {?} */\n const canvasRotation = settings.canvasRotation + loadedImage.exifTransform.rotate;\n /** @type {?} */\n const sourceImageElement = sourceImage.nativeElement;\n /** @type {?} */\n const ratio = loadedImage.transformed.size.width / sourceImageElement.offsetWidth;\n /** @type {?} */\n let offsetX;\n /** @type {?} */\n let offsetY;\n if (canvasRotation % 2) {\n offsetX = (loadedImage.transformed.size.width - loadedImage.original.size.height) / 2;\n offsetY = (loadedImage.transformed.size.height - loadedImage.original.size.width) / 2;\n }\n else {\n offsetX = (loadedImage.transformed.size.width - loadedImage.original.size.width) / 2;\n offsetY = (loadedImage.transformed.size.height - loadedImage.original.size.height) / 2;\n }\n /** @type {?} */\n const out = {\n x1: Math.round(cropper.x1 * ratio) - offsetX,\n y1: Math.round(cropper.y1 * ratio) - offsetY,\n x2: Math.round(cropper.x2 * ratio) - offsetX,\n y2: Math.round(cropper.y2 * ratio) - offsetY\n };\n if (!settings.containWithinAspectRatio) {\n out.x1 = Math.max(out.x1, 0);\n out.y1 = Math.max(out.y1, 0);\n out.x2 = Math.min(out.x2, loadedImage.transformed.size.width);\n out.y2 = Math.min(out.y2, loadedImage.transformed.size.height);\n }\n return out;\n }\n /**\n * @param {?} width\n * @param {?} height\n * @param {?} settings\n * @return {?}\n */\n getResizeRatio(width, height, settings) {\n /** @type {?} */\n const ratioWidth = settings.resizeToWidth / width;\n /** @type {?} */\n const ratioHeight = settings.resizeToHeight / height;\n /** @type {?} */\n const ratios = new Array();\n if (settings.resizeToWidth > 0) {\n ratios.push(ratioWidth);\n }\n if (settings.resizeToHeight > 0) {\n ratios.push(ratioHeight);\n }\n /** @type {?} */\n const result = ratios.length === 0 ? 1 : Math.min(...ratios);\n if (result > 1 && !settings.onlyScaleDown) {\n return result;\n }\n return Math.min(result, 1);\n }\n /**\n * @param {?} settings\n * @return {?}\n */\n getQuality(settings) {\n return Math.min(1, Math.max(0, settings.imageQuality / 100));\n }\n}\nCropService.ɵfac = function CropService_Factory(t) { return new (t || CropService)(); };\nCropService.ɵprov = ɵngcc0.ɵɵdefineInjectable({ token: CropService, factory: CropService.ɵfac, providedIn: 'root' });\n/** @nocollapse */ CropService.ngInjectableDef = ɵɵdefineInjectable({ factory: function CropService_Factory() { return new CropService(); }, token: CropService, providedIn: \"root\" });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(CropService, [{\n type: Injectable,\n args: [{ providedIn: 'root' }]\n }], null, null); })();\n\n/**\n * @fileoverview added by tsickle\n * Generated from: lib/interfaces/cropper.settings.ts\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\nclass CropperSettings {\n constructor() {\n // From options\n this.format = 'png';\n this.maintainAspectRatio = true;\n this.transform = {};\n this.aspectRatio = 1;\n this.resizeToWidth = 0;\n this.resizeToHeight = 0;\n this.cropperMinWidth = 0;\n this.cropperMinHeight = 0;\n this.cropperMaxHeight = 0;\n this.cropperMaxWidth = 0;\n this.cropperStaticWidth = 0;\n this.cropperStaticHeight = 0;\n this.canvasRotation = 0;\n this.initialStepSize = 3;\n this.roundCropper = false;\n this.onlyScaleDown = false;\n this.imageQuality = 92;\n this.autoCrop = true;\n this.containWithinAspectRatio = false;\n this.hideResizeSquares = false;\n this.alignImage = 'center';\n // Internal\n this.cropperScaledMinWidth = 20;\n this.cropperScaledMinHeight = 20;\n this.cropperScaledMaxWidth = 20;\n this.cropperScaledMaxHeight = 20;\n this.stepSize = this.initialStepSize;\n }\n /**\n * @param {?} options\n * @return {?}\n */\n setOptions(options) {\n Object.keys(options).forEach((/**\n * @param {?} k\n * @return {?}\n */\n (k) => this[k] = options[k]));\n }\n}\nif (false) {\n /** @type {?} */\n CropperSettings.prototype.format;\n /** @type {?} */\n CropperSettings.prototype.maintainAspectRatio;\n /** @type {?} */\n CropperSettings.prototype.transform;\n /** @type {?} */\n CropperSettings.prototype.aspectRatio;\n /** @type {?} */\n CropperSettings.prototype.resizeToWidth;\n /** @type {?} */\n CropperSettings.prototype.resizeToHeight;\n /** @type {?} */\n CropperSettings.prototype.cropperMinWidth;\n /** @type {?} */\n CropperSettings.prototype.cropperMinHeight;\n /** @type {?} */\n CropperSettings.prototype.cropperMaxHeight;\n /** @type {?} */\n CropperSettings.prototype.cropperMaxWidth;\n /** @type {?} */\n CropperSettings.prototype.cropperStaticWidth;\n /** @type {?} */\n CropperSettings.prototype.cropperStaticHeight;\n /** @type {?} */\n CropperSettings.prototype.canvasRotation;\n /** @type {?} */\n CropperSettings.prototype.initialStepSize;\n /** @type {?} */\n CropperSettings.prototype.roundCropper;\n /** @type {?} */\n CropperSettings.prototype.onlyScaleDown;\n /** @type {?} */\n CropperSettings.prototype.imageQuality;\n /** @type {?} */\n CropperSettings.prototype.autoCrop;\n /** @type {?} */\n CropperSettings.prototype.backgroundColor;\n /** @type {?} */\n CropperSettings.prototype.containWithinAspectRatio;\n /** @type {?} */\n CropperSettings.prototype.hideResizeSquares;\n /** @type {?} */\n CropperSettings.prototype.alignImage;\n /** @type {?} */\n CropperSettings.prototype.cropperScaledMinWidth;\n /** @type {?} */\n CropperSettings.prototype.cropperScaledMinHeight;\n /** @type {?} */\n CropperSettings.prototype.cropperScaledMaxWidth;\n /** @type {?} */\n CropperSettings.prototype.cropperScaledMaxHeight;\n /** @type {?} */\n CropperSettings.prototype.stepSize;\n}\n\n/**\n * @fileoverview added by tsickle\n * Generated from: lib/utils/exif.utils.ts\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\n// Black 2x1 JPEG, with the following meta information set:\n// - EXIF Orientation: 6 (Rotated 90° CCW)\n// Source: https://github.com/blueimp/JavaScript-Load-Image\n/** @type {?} */\nconst testAutoOrientationImageURL = 'data:image/jpeg;base64,/9j/4QAiRXhpZgAATU0AKgAAAAgAAQESAAMAAAABAAYAAAA' +\n 'AAAD/2wCEAAEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBA' +\n 'QEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQE' +\n 'BAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAf/AABEIAAEAAgMBEQACEQEDEQH/x' +\n 'ABKAAEAAAAAAAAAAAAAAAAAAAALEAEAAAAAAAAAAAAAAAAAAAAAAQEAAAAAAAAAAAAAAAA' +\n 'AAAAAEQEAAAAAAAAAAAAAAAAAAAAA/9oADAMBAAIRAxEAPwA/8H//2Q==';\n/**\n * @return {?}\n */\nfunction supportsAutomaticRotation() {\n return new Promise((/**\n * @param {?} resolve\n * @return {?}\n */\n (resolve) => {\n /** @type {?} */\n const img = new Image();\n img.onload = (/**\n * @return {?}\n */\n () => {\n // Check if browser supports automatic image orientation:\n /** @type {?} */\n const supported = img.width === 1 && img.height === 2;\n resolve(supported);\n });\n img.src = testAutoOrientationImageURL;\n }));\n}\n/**\n * @param {?} exifRotationOrBase64Image\n * @return {?}\n */\nfunction getTransformationsFromExifData(exifRotationOrBase64Image) {\n if (typeof exifRotationOrBase64Image === 'string') {\n exifRotationOrBase64Image = getExifRotation(exifRotationOrBase64Image);\n }\n switch (exifRotationOrBase64Image) {\n case 2:\n return { rotate: 0, flip: true };\n case 3:\n return { rotate: 2, flip: false };\n case 4:\n return { rotate: 2, flip: true };\n case 5:\n return { rotate: 1, flip: true };\n case 6:\n return { rotate: 1, flip: false };\n case 7:\n return { rotate: 3, flip: true };\n case 8:\n return { rotate: 3, flip: false };\n default:\n return { rotate: 0, flip: false };\n }\n}\n/**\n * @param {?} imageBase64\n * @return {?}\n */\nfunction getExifRotation(imageBase64) {\n /** @type {?} */\n const view = new DataView(base64ToArrayBuffer(imageBase64));\n if (view.getUint16(0, false) != 0xFFD8) {\n return -2;\n }\n /** @type {?} */\n const length = view.byteLength;\n /** @type {?} */\n let offset = 2;\n while (offset < length) {\n if (view.getUint16(offset + 2, false) <= 8)\n return -1;\n /** @type {?} */\n const marker = view.getUint16(offset, false);\n offset += 2;\n if (marker == 0xFFE1) {\n if (view.getUint32(offset += 2, false) != 0x45786966) {\n return -1;\n }\n /** @type {?} */\n const little = view.getUint16(offset += 6, false) == 0x4949;\n offset += view.getUint32(offset + 4, little);\n /** @type {?} */\n const tags = view.getUint16(offset, little);\n offset += 2;\n for (let i = 0; i < tags; i++) {\n if (view.getUint16(offset + (i * 12), little) == 0x0112) {\n return view.getUint16(offset + (i * 12) + 8, little);\n }\n }\n }\n else if ((marker & 0xFF00) != 0xFF00) {\n break;\n }\n else {\n offset += view.getUint16(offset, false);\n }\n }\n return -1;\n}\n/**\n * @param {?} imageBase64\n * @return {?}\n */\nfunction base64ToArrayBuffer(imageBase64) {\n imageBase64 = imageBase64.replace(/^data\\:([^\\;]+)\\;base64,/gmi, '');\n /** @type {?} */\n const binaryString = atob(imageBase64);\n /** @type {?} */\n const len = binaryString.length;\n /** @type {?} */\n const bytes = new Uint8Array(len);\n for (let i = 0; i < len; i++) {\n bytes[i] = binaryString.charCodeAt(i);\n }\n return bytes.buffer;\n}\n\n/**\n * @fileoverview added by tsickle\n * Generated from: lib/services/load-image.service.ts\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\n/**\n * @record\n */\nfunction LoadImageBase64() { }\nif (false) {\n /** @type {?} */\n LoadImageBase64.prototype.originalImage;\n /** @type {?} */\n LoadImageBase64.prototype.originalBase64;\n}\n/**\n * @record\n */\nfunction LoadedImage() { }\nif (false) {\n /** @type {?} */\n LoadedImage.prototype.original;\n /** @type {?} */\n LoadedImage.prototype.transformed;\n /** @type {?} */\n LoadedImage.prototype.exifTransform;\n}\nclass LoadImageService {\n constructor() {\n this.autoRotateSupported = supportsAutomaticRotation();\n }\n /**\n * @param {?} file\n * @param {?} cropperSettings\n * @return {?}\n */\n loadImageFile(file, cropperSettings) {\n return new Promise((/**\n * @param {?} resolve\n * @param {?} reject\n * @return {?}\n */\n (resolve, reject) => {\n /** @type {?} */\n const fileReader = new FileReader();\n fileReader.onload = (/**\n * @param {?} event\n * @return {?}\n */\n (event) => {\n this.loadImage(event.target.result, file.type, cropperSettings)\n .then(resolve)\n .catch(reject);\n });\n fileReader.readAsDataURL(file);\n }));\n }\n /**\n * @private\n * @param {?} imageBase64\n * @param {?} imageType\n * @param {?} cropperSettings\n * @return {?}\n */\n loadImage(imageBase64, imageType, cropperSettings) {\n if (!this.isValidImageType(imageType)) {\n return Promise.reject(new Error('Invalid image type'));\n }\n return this.loadBase64Image(imageBase64, cropperSettings);\n }\n /**\n * @private\n * @param {?} type\n * @return {?}\n */\n isValidImageType(type) {\n return /image\\/(png|jpg|jpeg|bmp|gif|tiff|webp)/.test(type);\n }\n /**\n * @param {?} url\n * @param {?} cropperSettings\n * @return {?}\n */\n loadImageFromURL(url, cropperSettings) {\n return new Promise((/**\n * @param {?} resolve\n * @param {?} reject\n * @return {?}\n */\n (resolve, reject) => {\n /** @type {?} */\n const img = new Image();\n img.onerror = (/**\n * @return {?}\n */\n () => reject);\n img.onload = (/**\n * @return {?}\n */\n () => {\n /** @type {?} */\n const canvas = document.createElement('canvas');\n /** @type {?} */\n const context = canvas.getContext('2d');\n canvas.width = img.width;\n canvas.height = img.height;\n context.drawImage(img, 0, 0);\n this.loadBase64Image(canvas.toDataURL(), cropperSettings).then(resolve);\n });\n img.crossOrigin = 'anonymous';\n img.src = url;\n }));\n }\n /**\n * @param {?} imageBase64\n * @param {?} cropperSettings\n * @return {?}\n */\n loadBase64Image(imageBase64, cropperSettings) {\n return new Promise((/**\n * @param {?} resolve\n * @param {?} reject\n * @return {?}\n */\n (resolve, reject) => {\n /** @type {?} */\n const originalImage = new Image();\n originalImage.onload = (/**\n * @return {?}\n */\n () => resolve({\n originalImage,\n originalBase64: imageBase64\n }));\n originalImage.onerror = reject;\n originalImage.src = imageBase64;\n })).then((/**\n * @param {?} res\n * @return {?}\n */\n (res) => this.transformImageBase64(res, cropperSettings)));\n }\n /**\n * @private\n * @param {?} res\n * @param {?} cropperSettings\n * @return {?}\n */\n transformImageBase64(res, cropperSettings) {\n return __awaiter(this, void 0, void 0, function* () {\n /** @type {?} */\n const autoRotate = yield this.autoRotateSupported;\n /** @type {?} */\n const exifTransform = yield getTransformationsFromExifData(autoRotate ? -1 : res.originalBase64);\n if (!res.originalImage || !res.originalImage.complete) {\n return Promise.reject(new Error('No image loaded'));\n }\n /** @type {?} */\n const loadedImage = {\n original: {\n base64: res.originalBase64,\n image: res.originalImage,\n size: {\n width: res.originalImage.naturalWidth,\n height: res.originalImage.naturalHeight\n }\n },\n exifTransform\n };\n return this.transformLoadedImage(loadedImage, cropperSettings);\n });\n }\n /**\n * @param {?} loadedImage\n * @param {?} cropperSettings\n * @return {?}\n */\n transformLoadedImage(loadedImage, cropperSettings) {\n return __awaiter(this, void 0, void 0, function* () {\n /** @type {?} */\n const canvasRotation = cropperSettings.canvasRotation + loadedImage.exifTransform.rotate;\n /** @type {?} */\n const originalSize = {\n width: loadedImage.original.image.naturalWidth,\n height: loadedImage.original.image.naturalHeight\n };\n if (canvasRotation === 0 && !loadedImage.exifTransform.flip && !cropperSettings.containWithinAspectRatio) {\n return {\n original: {\n base64: loadedImage.original.base64,\n image: loadedImage.original.image,\n size: Object.assign({}, originalSize)\n },\n transformed: {\n base64: loadedImage.original.base64,\n image: loadedImage.original.image,\n size: Object.assign({}, originalSize)\n },\n exifTransform: loadedImage.exifTransform\n };\n }\n /** @type {?} */\n const transformedSize = this.getTransformedSize(originalSize, loadedImage.exifTransform, cropperSettings);\n /** @type {?} */\n const canvas = document.createElement('canvas');\n canvas.width = transformedSize.width;\n canvas.height = transformedSize.height;\n /** @type {?} */\n const ctx = canvas.getContext('2d');\n ctx.setTransform(loadedImage.exifTransform.flip ? -1 : 1, 0, 0, 1, canvas.width / 2, canvas.height / 2);\n ctx.rotate(Math.PI * (canvasRotation / 2));\n ctx.drawImage(loadedImage.original.image, -originalSize.width / 2, -originalSize.height / 2);\n /** @type {?} */\n const transformedBase64 = canvas.toDataURL();\n /** @type {?} */\n const transformedImage = yield this.loadImageFromBase64(transformedBase64);\n return {\n original: {\n base64: loadedImage.original.base64,\n image: loadedImage.original.image,\n size: Object.assign({}, originalSize)\n },\n transformed: {\n base64: transformedBase64,\n image: transformedImage,\n size: {\n width: transformedImage.width,\n height: transformedImage.height\n }\n },\n exifTransform: loadedImage.exifTransform\n };\n });\n }\n /**\n * @private\n * @param {?} imageBase64\n * @return {?}\n */\n loadImageFromBase64(imageBase64) {\n return new Promise(((/**\n * @param {?} resolve\n * @param {?} reject\n * @return {?}\n */\n (resolve, reject) => {\n /** @type {?} */\n const image = new Image();\n image.onload = (/**\n * @return {?}\n */\n () => resolve(image));\n image.onerror = reject;\n image.src = imageBase64;\n })));\n }\n /**\n * @private\n * @param {?} originalSize\n * @param {?} exifTransform\n * @param {?} cropperSettings\n * @return {?}\n */\n getTransformedSize(originalSize, exifTransform, cropperSettings) {\n /** @type {?} */\n const canvasRotation = cropperSettings.canvasRotation + exifTransform.rotate;\n if (cropperSettings.containWithinAspectRatio) {\n if (canvasRotation % 2) {\n /** @type {?} */\n const minWidthToContain = originalSize.width * cropperSettings.aspectRatio;\n /** @type {?} */\n const minHeightToContain = originalSize.height / cropperSettings.aspectRatio;\n return {\n width: Math.max(originalSize.height, minWidthToContain),\n height: Math.max(originalSize.width, minHeightToContain)\n };\n }\n else {\n /** @type {?} */\n const minWidthToContain = originalSize.height * cropperSettings.aspectRatio;\n /** @type {?} */\n const minHeightToContain = originalSize.width / cropperSettings.aspectRatio;\n return {\n width: Math.max(originalSize.width, minWidthToContain),\n height: Math.max(originalSize.height, minHeightToContain)\n };\n }\n }\n if (canvasRotation % 2) {\n return {\n height: originalSize.width,\n width: originalSize.height\n };\n }\n return {\n width: originalSize.width,\n height: originalSize.height\n };\n }\n}\nLoadImageService.ɵfac = function LoadImageService_Factory(t) { return new (t || LoadImageService)(); };\nLoadImageService.ɵprov = ɵngcc0.ɵɵdefineInjectable({ token: LoadImageService, factory: LoadImageService.ɵfac, providedIn: 'root' });\n/** @nocollapse */ LoadImageService.ngInjectableDef = ɵɵdefineInjectable({ factory: function LoadImageService_Factory() { return new LoadImageService(); }, token: LoadImageService, providedIn: \"root\" });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(LoadImageService, [{\n type: Injectable,\n args: [{ providedIn: 'root' }]\n }], function () { return []; }, null); })();\nif (false) {\n /**\n * @type {?}\n * @private\n */\n LoadImageService.prototype.autoRotateSupported;\n}\n\n/**\n * @fileoverview added by tsickle\n * Generated from: lib/services/cropper-position.service.ts\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\nclass CropperPositionService {\n /**\n * @param {?} sourceImage\n * @param {?} cropperPosition\n * @param {?} settings\n * @return {?}\n */\n resetCropperPosition(sourceImage, cropperPosition, settings) {\n /** @type {?} */\n const sourceImageElement = sourceImage.nativeElement;\n if (settings.cropperStaticHeight && settings.cropperStaticWidth) {\n cropperPosition.x1 = 0;\n cropperPosition.x2 = sourceImageElement.offsetWidth > settings.cropperStaticWidth ?\n settings.cropperStaticWidth : sourceImageElement.offsetWidth;\n cropperPosition.y1 = 0;\n cropperPosition.y2 = sourceImageElement.offsetHeight > settings.cropperStaticHeight ?\n settings.cropperStaticHeight : sourceImageElement.offsetHeight;\n }\n else {\n /** @type {?} */\n const cropperWidth = Math.min(settings.cropperScaledMaxWidth, sourceImageElement.offsetWidth);\n /** @type {?} */\n const cropperHeight = Math.min(settings.cropperScaledMaxHeight, sourceImageElement.offsetHeight);\n if (!settings.maintainAspectRatio) {\n cropperPosition.x1 = 0;\n cropperPosition.x2 = cropperWidth;\n cropperPosition.y1 = 0;\n cropperPosition.y2 = cropperHeight;\n }\n else if (cropperWidth / settings.aspectRatio < cropperHeight) {\n cropperPosition.x1 = 0;\n cropperPosition.x2 = cropperWidth;\n /** @type {?} */\n const cropperHeightWithAspectRatio = cropperWidth / settings.aspectRatio;\n cropperPosition.y1 = (sourceImageElement.offsetHeight - cropperHeightWithAspectRatio) / 2;\n cropperPosition.y2 = cropperPosition.y1 + cropperHeightWithAspectRatio;\n }\n else {\n cropperPosition.y1 = 0;\n cropperPosition.y2 = cropperHeight;\n /** @type {?} */\n const cropperWidthWithAspectRatio = cropperHeight * settings.aspectRatio;\n cropperPosition.x1 = (sourceImageElement.offsetWidth - cropperWidthWithAspectRatio) / 2;\n cropperPosition.x2 = cropperPosition.x1 + cropperWidthWithAspectRatio;\n }\n }\n }\n /**\n * @param {?} event\n * @param {?} moveStart\n * @param {?} cropperPosition\n * @return {?}\n */\n move(event, moveStart, cropperPosition) {\n /** @type {?} */\n const diffX = this.getClientX(event) - moveStart.clientX;\n /** @type {?} */\n const diffY = this.getClientY(event) - moveStart.clientY;\n cropperPosition.x1 = moveStart.x1 + diffX;\n cropperPosition.y1 = moveStart.y1 + diffY;\n cropperPosition.x2 = moveStart.x2 + diffX;\n cropperPosition.y2 = moveStart.y2 + diffY;\n }\n /**\n * @param {?} event\n * @param {?} moveStart\n * @param {?} cropperPosition\n * @param {?} maxSize\n * @param {?} settings\n * @return {?}\n */\n resize(event, moveStart, cropperPosition, maxSize, settings) {\n /** @type {?} */\n const moveX = this.getClientX(event) - moveStart.clientX;\n /** @type {?} */\n const moveY = this.getClientY(event) - moveStart.clientY;\n switch (moveStart.position) {\n case 'left':\n cropperPosition.x1 = Math.min(Math.max(moveStart.x1 + moveX, cropperPosition.x2 - settings.cropperScaledMaxWidth), cropperPosition.x2 - settings.cropperScaledMinWidth);\n break;\n case 'topleft':\n cropperPosition.x1 = Math.min(Math.max(moveStart.x1 + moveX, cropperPosition.x2 - settings.cropperScaledMaxWidth), cropperPosition.x2 - settings.cropperScaledMinWidth);\n cropperPosition.y1 = Math.min(Math.max(moveStart.y1 + moveY, cropperPosition.y2 - settings.cropperScaledMaxHeight), cropperPosition.y2 - settings.cropperScaledMinHeight);\n break;\n case 'top':\n cropperPosition.y1 = Math.min(Math.max(moveStart.y1 + moveY, cropperPosition.y2 - settings.cropperScaledMaxHeight), cropperPosition.y2 - settings.cropperScaledMinHeight);\n break;\n case 'topright':\n cropperPosition.x2 = Math.max(Math.min(moveStart.x2 + moveX, cropperPosition.x1 + settings.cropperScaledMaxWidth), cropperPosition.x1 + settings.cropperScaledMinWidth);\n cropperPosition.y1 = Math.min(Math.max(moveStart.y1 + moveY, cropperPosition.y2 - settings.cropperScaledMaxHeight), cropperPosition.y2 - settings.cropperScaledMinHeight);\n break;\n case 'right':\n cropperPosition.x2 = Math.max(Math.min(moveStart.x2 + moveX, cropperPosition.x1 + settings.cropperScaledMaxWidth), cropperPosition.x1 + settings.cropperScaledMinWidth);\n break;\n case 'bottomright':\n cropperPosition.x2 = Math.max(Math.min(moveStart.x2 + moveX, cropperPosition.x1 + settings.cropperScaledMaxWidth), cropperPosition.x1 + settings.cropperScaledMinWidth);\n cropperPosition.y2 = Math.max(Math.min(moveStart.y2 + moveY, cropperPosition.y1 + settings.cropperScaledMaxHeight), cropperPosition.y1 + settings.cropperScaledMinHeight);\n break;\n case 'bottom':\n cropperPosition.y2 = Math.max(Math.min(moveStart.y2 + moveY, cropperPosition.y1 + settings.cropperScaledMaxHeight), cropperPosition.y1 + settings.cropperScaledMinHeight);\n break;\n case 'bottomleft':\n cropperPosition.x1 = Math.min(Math.max(moveStart.x1 + moveX, cropperPosition.x2 - settings.cropperScaledMaxWidth), cropperPosition.x2 - settings.cropperScaledMinWidth);\n cropperPosition.y2 = Math.max(Math.min(moveStart.y2 + moveY, cropperPosition.y1 + settings.cropperScaledMaxHeight), cropperPosition.y1 + settings.cropperScaledMinHeight);\n break;\n case 'center':\n /** @type {?} */\n const scale = event.scale;\n /** @type {?} */\n const newWidth = Math.min(Math.max(settings.cropperScaledMinWidth, (Math.abs(moveStart.x2 - moveStart.x1)) * scale), settings.cropperScaledMaxWidth);\n /** @type {?} */\n const newHeight = Math.min(Math.max(settings.cropperScaledMinHeight, (Math.abs(moveStart.y2 - moveStart.y1)) * scale), settings.cropperScaledMaxHeight);\n cropperPosition.x1 = moveStart.clientX - newWidth / 2;\n cropperPosition.x2 = moveStart.clientX + newWidth / 2;\n cropperPosition.y1 = moveStart.clientY - newHeight / 2;\n cropperPosition.y2 = moveStart.clientY + newHeight / 2;\n if (cropperPosition.x1 < 0) {\n cropperPosition.x2 -= cropperPosition.x1;\n cropperPosition.x1 = 0;\n }\n else if (cropperPosition.x2 > maxSize.width) {\n cropperPosition.x1 -= (cropperPosition.x2 - maxSize.width);\n cropperPosition.x2 = maxSize.width;\n }\n if (cropperPosition.y1 < 0) {\n cropperPosition.y2 -= cropperPosition.y1;\n cropperPosition.y1 = 0;\n }\n else if (cropperPosition.y2 > maxSize.height) {\n cropperPosition.y1 -= (cropperPosition.y2 - maxSize.height);\n cropperPosition.y2 = maxSize.height;\n }\n break;\n }\n if (settings.maintainAspectRatio) {\n this.checkAspectRatio(moveStart.position, cropperPosition, maxSize, settings);\n }\n }\n /**\n * @param {?} position\n * @param {?} cropperPosition\n * @param {?} maxSize\n * @param {?} settings\n * @return {?}\n */\n checkAspectRatio(position, cropperPosition, maxSize, settings) {\n /** @type {?} */\n let overflowX = 0;\n /** @type {?} */\n let overflowY = 0;\n switch (position) {\n case 'top':\n cropperPosition.x2 = cropperPosition.x1 + (cropperPosition.y2 - cropperPosition.y1) * settings.aspectRatio;\n overflowX = Math.max(cropperPosition.x2 - maxSize.width, 0);\n overflowY = Math.max(0 - cropperPosition.y1, 0);\n if (overflowX > 0 || overflowY > 0) {\n cropperPosition.x2 -= (overflowY * settings.aspectRatio) > overflowX ? (overflowY * settings.aspectRatio) : overflowX;\n cropperPosition.y1 += (overflowY * settings.aspectRatio) > overflowX ? overflowY : overflowX / settings.aspectRatio;\n }\n break;\n case 'bottom':\n cropperPosition.x2 = cropperPosition.x1 + (cropperPosition.y2 - cropperPosition.y1) * settings.aspectRatio;\n overflowX = Math.max(cropperPosition.x2 - maxSize.width, 0);\n overflowY = Math.max(cropperPosition.y2 - maxSize.height, 0);\n if (overflowX > 0 || overflowY > 0) {\n cropperPosition.x2 -= (overflowY * settings.aspectRatio) > overflowX ? (overflowY * settings.aspectRatio) : overflowX;\n cropperPosition.y2 -= (overflowY * settings.aspectRatio) > overflowX ? overflowY : (overflowX / settings.aspectRatio);\n }\n break;\n case 'topleft':\n cropperPosition.y1 = cropperPosition.y2 - (cropperPosition.x2 - cropperPosition.x1) / settings.aspectRatio;\n overflowX = Math.max(0 - cropperPosition.x1, 0);\n overflowY = Math.max(0 - cropperPosition.y1, 0);\n if (overflowX > 0 || overflowY > 0) {\n cropperPosition.x1 += (overflowY * settings.aspectRatio) > overflowX ? (overflowY * settings.aspectRatio) : overflowX;\n cropperPosition.y1 += (overflowY * settings.aspectRatio) > overflowX ? overflowY : overflowX / settings.aspectRatio;\n }\n break;\n case 'topright':\n cropperPosition.y1 = cropperPosition.y2 - (cropperPosition.x2 - cropperPosition.x1) / settings.aspectRatio;\n overflowX = Math.max(cropperPosition.x2 - maxSize.width, 0);\n overflowY = Math.max(0 - cropperPosition.y1, 0);\n if (overflowX > 0 || overflowY > 0) {\n cropperPosition.x2 -= (overflowY * settings.aspectRatio) > overflowX ? (overflowY * settings.aspectRatio) : overflowX;\n cropperPosition.y1 += (overflowY * settings.aspectRatio) > overflowX ? overflowY : overflowX / settings.aspectRatio;\n }\n break;\n case 'right':\n case 'bottomright':\n cropperPosition.y2 = cropperPosition.y1 + (cropperPosition.x2 - cropperPosition.x1) / settings.aspectRatio;\n overflowX = Math.max(cropperPosition.x2 - maxSize.width, 0);\n overflowY = Math.max(cropperPosition.y2 - maxSize.height, 0);\n if (overflowX > 0 || overflowY > 0) {\n cropperPosition.x2 -= (overflowY * settings.aspectRatio) > overflowX ? (overflowY * settings.aspectRatio) : overflowX;\n cropperPosition.y2 -= (overflowY * settings.aspectRatio) > overflowX ? overflowY : overflowX / settings.aspectRatio;\n }\n break;\n case 'left':\n case 'bottomleft':\n cropperPosition.y2 = cropperPosition.y1 + (cropperPosition.x2 - cropperPosition.x1) / settings.aspectRatio;\n overflowX = Math.max(0 - cropperPosition.x1, 0);\n overflowY = Math.max(cropperPosition.y2 - maxSize.height, 0);\n if (overflowX > 0 || overflowY > 0) {\n cropperPosition.x1 += (overflowY * settings.aspectRatio) > overflowX ? (overflowY * settings.aspectRatio) : overflowX;\n cropperPosition.y2 -= (overflowY * settings.aspectRatio) > overflowX ? overflowY : overflowX / settings.aspectRatio;\n }\n break;\n case 'center':\n cropperPosition.x2 = cropperPosition.x1 + (cropperPosition.y2 - cropperPosition.y1) * settings.aspectRatio;\n cropperPosition.y2 = cropperPosition.y1 + (cropperPosition.x2 - cropperPosition.x1) / settings.aspectRatio;\n /** @type {?} */\n const overflowX1 = Math.max(0 - cropperPosition.x1, 0);\n /** @type {?} */\n const overflowX2 = Math.max(cropperPosition.x2 - maxSize.width, 0);\n /** @type {?} */\n const overflowY1 = Math.max(cropperPosition.y2 - maxSize.height, 0);\n /** @type {?} */\n const overflowY2 = Math.max(0 - cropperPosition.y1, 0);\n if (overflowX1 > 0 || overflowX2 > 0 || overflowY1 > 0 || overflowY2 > 0) {\n cropperPosition.x1 += (overflowY1 * settings.aspectRatio) > overflowX1 ? (overflowY1 * settings.aspectRatio) : overflowX1;\n cropperPosition.x2 -= (overflowY2 * settings.aspectRatio) > overflowX2 ? (overflowY2 * settings.aspectRatio) : overflowX2;\n cropperPosition.y1 += (overflowY2 * settings.aspectRatio) > overflowX2 ? overflowY2 : overflowX2 / settings.aspectRatio;\n cropperPosition.y2 -= (overflowY1 * settings.aspectRatio) > overflowX1 ? overflowY1 : overflowX1 / settings.aspectRatio;\n }\n break;\n }\n }\n /**\n * @param {?} event\n * @return {?}\n */\n getClientX(event) {\n return (event.touches && event.touches[0] ? event.touches[0].clientX : event.clientX) || 0;\n }\n /**\n * @param {?} event\n * @return {?}\n */\n getClientY(event) {\n return (event.touches && event.touches[0] ? event.touches[0].clientY : event.clientY) || 0;\n }\n}\nCropperPositionService.ɵfac = function CropperPositionService_Factory(t) { return new (t || CropperPositionService)(); };\nCropperPositionService.ɵprov = ɵngcc0.ɵɵdefineInjectable({ token: CropperPositionService, factory: CropperPositionService.ɵfac, providedIn: 'root' });\n/** @nocollapse */ CropperPositionService.ngInjectableDef = ɵɵdefineInjectable({ factory: function CropperPositionService_Factory() { return new CropperPositionService(); }, token: CropperPositionService, providedIn: \"root\" });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(CropperPositionService, [{\n type: Injectable,\n args: [{ providedIn: 'root' }]\n }], null, null); })();\n\n/**\n * @fileoverview added by tsickle\n * Generated from: lib/utils/keyboard.utils.ts\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\n/**\n * @param {?} key\n * @return {?}\n */\nfunction getPositionForKey(key) {\n switch (key) {\n case 'ArrowUp':\n return 'top';\n case 'ArrowRight':\n return 'right';\n case 'ArrowDown':\n return 'bottom';\n case 'ArrowLeft':\n default:\n return 'left';\n }\n}\n/**\n * @param {?} key\n * @return {?}\n */\nfunction getInvertedPositionForKey(key) {\n switch (key) {\n case 'ArrowUp':\n return 'bottom';\n case 'ArrowRight':\n return 'left';\n case 'ArrowDown':\n return 'top';\n case 'ArrowLeft':\n default:\n return 'right';\n }\n}\n/**\n * @param {?} key\n * @param {?} stepSize\n * @return {?}\n */\nfunction getEventForKey(key, stepSize) {\n switch (key) {\n case 'ArrowUp':\n return { clientX: 0, clientY: stepSize * -1 };\n case 'ArrowRight':\n return { clientX: stepSize, clientY: 0 };\n case 'ArrowDown':\n return { clientX: 0, clientY: stepSize };\n case 'ArrowLeft':\n default:\n return { clientX: stepSize * -1, clientY: 0 };\n }\n}\n\n/**\n * @fileoverview added by tsickle\n * Generated from: lib/component/image-cropper.component.ts\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\nclass ImageCropperComponent {\n /**\n * @param {?} cropService\n * @param {?} cropperPositionService\n * @param {?} loadImageService\n * @param {?} sanitizer\n * @param {?} cd\n */\n constructor(cropService, cropperPositionService, loadImageService, sanitizer, cd) {\n this.cropService = cropService;\n this.cropperPositionService = cropperPositionService;\n this.loadImageService = loadImageService;\n this.sanitizer = sanitizer;\n this.cd = cd;\n this.Hammer = typeof window !== 'undefined'\n ? (/** @type {?} */ (((/** @type {?} */ (window))).Hammer))\n : null;\n this.settings = new CropperSettings();\n this.setImageMaxSizeRetries = 0;\n this.marginLeft = '0px';\n this.moveTypes = MoveTypes;\n this.imageVisible = false;\n this.format = this.settings.format;\n this.transform = {};\n this.maintainAspectRatio = this.settings.maintainAspectRatio;\n this.aspectRatio = this.settings.aspectRatio;\n this.resizeToWidth = this.settings.resizeToWidth;\n this.resizeToHeight = this.settings.resizeToHeight;\n this.cropperMinWidth = this.settings.cropperMinWidth;\n this.cropperMinHeight = this.settings.cropperMinHeight;\n this.cropperMaxHeight = this.settings.cropperMaxHeight;\n this.cropperMaxWidth = this.settings.cropperMaxWidth;\n this.cropperStaticWidth = this.settings.cropperStaticWidth;\n this.cropperStaticHeight = this.settings.cropperStaticHeight;\n this.canvasRotation = this.settings.canvasRotation;\n this.initialStepSize = this.settings.initialStepSize;\n this.roundCropper = this.settings.roundCropper;\n this.onlyScaleDown = this.settings.onlyScaleDown;\n this.imageQuality = this.settings.imageQuality;\n this.autoCrop = this.settings.autoCrop;\n this.backgroundColor = this.settings.backgroundColor;\n this.containWithinAspectRatio = this.settings.containWithinAspectRatio;\n this.hideResizeSquares = this.settings.hideResizeSquares;\n this.cropper = {\n x1: -100,\n y1: -100,\n x2: 10000,\n y2: 10000\n };\n this.alignImage = this.settings.alignImage;\n this.disabled = false;\n this.imageCropped = new EventEmitter();\n this.startCropImage = new EventEmitter();\n this.imageLoaded = new EventEmitter();\n this.cropperReady = new EventEmitter();\n this.loadImageFailed = new EventEmitter();\n this.reset();\n }\n /**\n * @param {?} changes\n * @return {?}\n */\n ngOnChanges(changes) {\n this.onChangesUpdateSettings(changes);\n this.onChangesInputImage(changes);\n if (this.loadedImage && this.loadedImage.original.image.complete\n && (changes.containWithinAspectRatio || changes.canvasRotation)) {\n this.loadImageService\n .transformLoadedImage(this.loadedImage, this.settings)\n .then((/**\n * @param {?} res\n * @return {?}\n */\n (res) => this.setLoadedImage(res)))\n .catch((/**\n * @param {?} err\n * @return {?}\n */\n (err) => this.loadImageError(err)));\n }\n if (changes.cropper) {\n this.setMaxSize();\n this.setCropperScaledMinSize();\n this.setCropperScaledMaxSize();\n this.checkCropperPosition(false);\n this.doAutoCrop();\n this.cd.markForCheck();\n }\n if (changes.aspectRatio && this.imageVisible) {\n this.resetCropperPosition();\n }\n if (changes.transform) {\n this.transform = this.transform || {};\n this.setCssTransform();\n this.doAutoCrop();\n }\n }\n /**\n * @private\n * @param {?} changes\n * @return {?}\n */\n onChangesUpdateSettings(changes) {\n Object.keys(changes)\n .filter((/**\n * @param {?} p\n * @return {?}\n */\n (p) => this.settings.hasOwnProperty(p)))\n .forEach((/**\n * @param {?} p\n * @return {?}\n */\n (p) => this.settings[p] = this[p]));\n if (this.settings.cropperStaticHeight && this.settings.cropperStaticWidth) {\n this.settings.hideResizeSquares = true;\n this.settings.cropperMinWidth = this.settings.cropperStaticWidth;\n this.settings.cropperMinHeight = this.settings.cropperStaticHeight;\n this.settings.cropperMaxHeight = this.settings.cropperStaticHeight;\n this.settings.cropperMaxWidth = this.settings.cropperStaticWidth;\n this.settings.maintainAspectRatio = false;\n }\n }\n /**\n * @private\n * @param {?} changes\n * @return {?}\n */\n onChangesInputImage(changes) {\n if (changes.imageChangedEvent || changes.imageURL || changes.imageBase64 || changes.imageFile) {\n this.reset();\n }\n if (changes.imageChangedEvent && this.isValidImageChangedEvent()) {\n this.loadImageFile(this.imageChangedEvent.target.files[0]);\n }\n if (changes.imageURL && this.imageURL) {\n this.loadImageFromURL(this.imageURL);\n }\n if (changes.imageBase64 && this.imageBase64) {\n this.loadBase64Image(this.imageBase64);\n }\n if (changes.imageFile && this.imageFile) {\n this.loadImageFile(this.imageFile);\n }\n }\n /**\n * @private\n * @return {?}\n */\n isValidImageChangedEvent() {\n return this.imageChangedEvent\n && this.imageChangedEvent.target\n && this.imageChangedEvent.target.files\n && this.imageChangedEvent.target.files.length > 0;\n }\n /**\n * @private\n * @return {?}\n */\n setCssTransform() {\n this.safeTransformStyle = this.sanitizer.bypassSecurityTrustStyle('scaleX(' + (this.transform.scale || 1) * (this.transform.flipH ? -1 : 1) + ')' +\n 'scaleY(' + (this.transform.scale || 1) * (this.transform.flipV ? -1 : 1) + ')' +\n 'rotate(' + (this.transform.rotate || 0) + 'deg)');\n }\n /**\n * @return {?}\n */\n ngOnInit() {\n this.settings.stepSize = this.initialStepSize;\n this.activatePinchGesture();\n }\n /**\n * @private\n * @return {?}\n */\n reset() {\n this.imageVisible = false;\n this.loadedImage = null;\n this.safeImgDataUrl = 'data:image/png;base64,iVBORw0KGg'\n + 'oAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAC0lEQVQYV2NgAAIAAAU'\n + 'AAarVyFEAAAAASUVORK5CYII=';\n this.moveStart = {\n active: false,\n type: null,\n position: null,\n x1: 0,\n y1: 0,\n x2: 0,\n y2: 0,\n clientX: 0,\n clientY: 0\n };\n this.maxSize = {\n width: 0,\n height: 0\n };\n this.cropper.x1 = -100;\n this.cropper.y1 = -100;\n this.cropper.x2 = 10000;\n this.cropper.y2 = 10000;\n }\n /**\n * @private\n * @param {?} file\n * @return {?}\n */\n loadImageFile(file) {\n this.loadImageService\n .loadImageFile(file, this.settings)\n .then((/**\n * @param {?} res\n * @return {?}\n */\n (res) => this.setLoadedImage(res)))\n .catch((/**\n * @param {?} err\n * @return {?}\n */\n (err) => this.loadImageError(err)));\n }\n /**\n * @private\n * @param {?} imageBase64\n * @return {?}\n */\n loadBase64Image(imageBase64) {\n this.loadImageService\n .loadBase64Image(imageBase64, this.settings)\n .then((/**\n * @param {?} res\n * @return {?}\n */\n (res) => this.setLoadedImage(res)))\n .catch((/**\n * @param {?} err\n * @return {?}\n */\n (err) => this.loadImageError(err)));\n }\n /**\n * @private\n * @param {?} url\n * @return {?}\n */\n loadImageFromURL(url) {\n this.loadImageService\n .loadImageFromURL(url, this.settings)\n .then((/**\n * @param {?} res\n * @return {?}\n */\n (res) => this.setLoadedImage(res)))\n .catch((/**\n * @param {?} err\n * @return {?}\n */\n (err) => this.loadImageError(err)));\n }\n /**\n * @private\n * @param {?} loadedImage\n * @return {?}\n */\n setLoadedImage(loadedImage) {\n this.loadedImage = loadedImage;\n this.safeImgDataUrl = this.sanitizer.bypassSecurityTrustResourceUrl(loadedImage.transformed.base64);\n this.cd.markForCheck();\n }\n /**\n * @private\n * @param {?} error\n * @return {?}\n */\n loadImageError(error) {\n console.error(error);\n this.loadImageFailed.emit();\n }\n /**\n * @return {?}\n */\n imageLoadedInView() {\n if (this.loadedImage != null) {\n this.imageLoaded.emit(this.loadedImage);\n this.setImageMaxSizeRetries = 0;\n setTimeout((/**\n * @return {?}\n */\n () => this.checkImageMaxSizeRecursively()));\n }\n }\n /**\n * @private\n * @return {?}\n */\n checkImageMaxSizeRecursively() {\n if (this.setImageMaxSizeRetries > 40) {\n this.loadImageFailed.emit();\n }\n else if (this.sourceImageLoaded()) {\n this.setMaxSize();\n this.setCropperScaledMinSize();\n this.setCropperScaledMaxSize();\n this.resetCropperPosition();\n this.cropperReady.emit(Object.assign({}, this.maxSize));\n this.cd.markForCheck();\n }\n else {\n this.setImageMaxSizeRetries++;\n setTimeout((/**\n * @return {?}\n */\n () => this.checkImageMaxSizeRecursively()), 50);\n }\n }\n /**\n * @private\n * @return {?}\n */\n sourceImageLoaded() {\n return this.sourceImage && this.sourceImage.nativeElement && this.sourceImage.nativeElement.offsetWidth > 0;\n }\n /**\n * @return {?}\n */\n onResize() {\n if (!this.loadedImage) {\n return;\n }\n this.resizeCropperPosition();\n this.setMaxSize();\n this.setCropperScaledMinSize();\n this.setCropperScaledMaxSize();\n }\n /**\n * @private\n * @return {?}\n */\n activatePinchGesture() {\n if (this.Hammer) {\n /** @type {?} */\n const hammer = new this.Hammer(this.wrapper.nativeElement);\n hammer.get('pinch').set({ enable: true });\n hammer.on('pinchmove', this.onPinch.bind(this));\n hammer.on('pinchend', this.pinchStop.bind(this));\n hammer.on('pinchstart', this.startPinch.bind(this));\n }\n else if (isDevMode()) {\n console.warn('[NgxImageCropper] Could not find HammerJS - Pinch Gesture won\\'t work');\n }\n }\n /**\n * @private\n * @return {?}\n */\n resizeCropperPosition() {\n /** @type {?} */\n const sourceImageElement = this.sourceImage.nativeElement;\n if (this.maxSize.width !== sourceImageElement.offsetWidth || this.maxSize.height !== sourceImageElement.offsetHeight) {\n this.cropper.x1 = this.cropper.x1 * sourceImageElement.offsetWidth / this.maxSize.width;\n this.cropper.x2 = this.cropper.x2 * sourceImageElement.offsetWidth / this.maxSize.width;\n this.cropper.y1 = this.cropper.y1 * sourceImageElement.offsetHeight / this.maxSize.height;\n this.cropper.y2 = this.cropper.y2 * sourceImageElement.offsetHeight / this.maxSize.height;\n }\n }\n /**\n * @return {?}\n */\n resetCropperPosition() {\n this.cropperPositionService.resetCropperPosition(this.sourceImage, this.cropper, this.settings);\n this.doAutoCrop();\n this.imageVisible = true;\n }\n /**\n * @param {?} event\n * @return {?}\n */\n keyboardAccess(event) {\n this.changeKeyboardStepSize(event);\n this.keyboardMoveCropper(event);\n }\n /**\n * @private\n * @param {?} event\n * @return {?}\n */\n changeKeyboardStepSize(event) {\n if (event.key >= '1' && event.key <= '9') {\n this.settings.stepSize = +event.key;\n return;\n }\n }\n /**\n * @private\n * @param {?} event\n * @return {?}\n */\n keyboardMoveCropper(event) {\n /** @type {?} */\n const keyboardWhiteList = ['ArrowUp', 'ArrowDown', 'ArrowRight', 'ArrowLeft'];\n if (!(keyboardWhiteList.includes(event.key))) {\n return;\n }\n /** @type {?} */\n const moveType = event.shiftKey ? MoveTypes.Resize : MoveTypes.Move;\n /** @type {?} */\n const position = event.altKey ? getInvertedPositionForKey(event.key) : getPositionForKey(event.key);\n /** @type {?} */\n const moveEvent = getEventForKey(event.key, this.settings.stepSize);\n event.preventDefault();\n event.stopPropagation();\n this.startMove({ clientX: 0, clientY: 0 }, moveType, position);\n this.moveImg(moveEvent);\n this.moveStop();\n }\n /**\n * @param {?} event\n * @param {?} moveType\n * @param {?=} position\n * @return {?}\n */\n startMove(event, moveType, position = null) {\n if (this.moveStart && this.moveStart.active && this.moveStart.type === MoveTypes.Pinch) {\n return;\n }\n if (event.preventDefault) {\n event.preventDefault();\n }\n this.moveStart = Object.assign({ active: true, type: moveType, position, clientX: this.cropperPositionService.getClientX(event), clientY: this.cropperPositionService.getClientY(event) }, this.cropper);\n }\n /**\n * @param {?} event\n * @return {?}\n */\n startPinch(event) {\n if (!this.safeImgDataUrl) {\n return;\n }\n if (event.preventDefault) {\n event.preventDefault();\n }\n this.moveStart = Object.assign({ active: true, type: MoveTypes.Pinch, position: 'center', clientX: this.cropper.x1 + (this.cropper.x2 - this.cropper.x1) / 2, clientY: this.cropper.y1 + (this.cropper.y2 - this.cropper.y1) / 2 }, this.cropper);\n }\n /**\n * @param {?} event\n * @return {?}\n */\n moveImg(event) {\n if (this.moveStart.active) {\n if (event.stopPropagation) {\n event.stopPropagation();\n }\n if (event.preventDefault) {\n event.preventDefault();\n }\n if (this.moveStart.type === MoveTypes.Move) {\n this.cropperPositionService.move(event, this.moveStart, this.cropper);\n this.checkCropperPosition(true);\n }\n else if (this.moveStart.type === MoveTypes.Resize) {\n if (!this.cropperStaticWidth && !this.cropperStaticHeight) {\n this.cropperPositionService.resize(event, this.moveStart, this.cropper, this.maxSize, this.settings);\n }\n this.checkCropperPosition(false);\n }\n this.cd.detectChanges();\n }\n }\n /**\n * @param {?} event\n * @return {?}\n */\n onPinch(event) {\n if (this.moveStart.active) {\n if (event.stopPropagation) {\n event.stopPropagation();\n }\n if (event.preventDefault) {\n event.preventDefault();\n }\n if (this.moveStart.type === MoveTypes.Pinch) {\n this.cropperPositionService.resize(event, this.moveStart, this.cropper, this.maxSize, this.settings);\n this.checkCropperPosition(false);\n }\n this.cd.detectChanges();\n }\n }\n /**\n * @private\n * @return {?}\n */\n setMaxSize() {\n if (this.sourceImage) {\n /** @type {?} */\n const sourceImageElement = this.sourceImage.nativeElement;\n this.maxSize.width = sourceImageElement.offsetWidth;\n this.maxSize.height = sourceImageElement.offsetHeight;\n this.marginLeft = this.sanitizer.bypassSecurityTrustStyle('calc(50% - ' + this.maxSize.width / 2 + 'px)');\n }\n }\n /**\n * @private\n * @return {?}\n */\n setCropperScaledMinSize() {\n if (this.loadedImage.transformed.image) {\n this.setCropperScaledMinWidth();\n this.setCropperScaledMinHeight();\n }\n else {\n this.settings.cropperScaledMinWidth = 20;\n this.settings.cropperScaledMinHeight = 20;\n }\n }\n /**\n * @private\n * @return {?}\n */\n setCropperScaledMinWidth() {\n this.settings.cropperScaledMinWidth = this.cropperMinWidth > 0\n ? Math.max(20, this.cropperMinWidth / this.loadedImage.transformed.image.width * this.maxSize.width)\n : 20;\n }\n /**\n * @private\n * @return {?}\n */\n setCropperScaledMinHeight() {\n if (this.maintainAspectRatio) {\n this.settings.cropperScaledMinHeight = Math.max(20, this.settings.cropperScaledMinWidth / this.aspectRatio);\n }\n else if (this.cropperMinHeight > 0) {\n this.settings.cropperScaledMinHeight = Math.max(20, this.cropperMinHeight / this.loadedImage.transformed.image.height * this.maxSize.height);\n }\n else {\n this.settings.cropperScaledMinHeight = 20;\n }\n }\n /**\n * @private\n * @return {?}\n */\n setCropperScaledMaxSize() {\n if (this.loadedImage.transformed.image) {\n /** @type {?} */\n const ratio = this.loadedImage.transformed.size.width / this.maxSize.width;\n this.settings.cropperScaledMaxWidth = this.cropperMaxWidth > 20 ? this.cropperMaxWidth / ratio : this.maxSize.width;\n this.settings.cropperScaledMaxHeight = this.cropperMaxHeight > 20 ? this.cropperMaxHeight / ratio : this.maxSize.height;\n if (this.maintainAspectRatio) {\n if (this.settings.cropperScaledMaxWidth > this.settings.cropperScaledMaxHeight * this.aspectRatio) {\n this.settings.cropperScaledMaxWidth = this.settings.cropperScaledMaxHeight * this.aspectRatio;\n }\n else if (this.settings.cropperScaledMaxWidth < this.settings.cropperScaledMaxHeight * this.aspectRatio) {\n this.settings.cropperScaledMaxHeight = this.settings.cropperScaledMaxWidth / this.aspectRatio;\n }\n }\n }\n else {\n this.settings.cropperScaledMaxWidth = this.maxSize.width;\n this.settings.cropperScaledMaxHeight = this.maxSize.height;\n }\n }\n /**\n * @private\n * @param {?=} maintainSize\n * @return {?}\n */\n checkCropperPosition(maintainSize = false) {\n if (this.cropper.x1 < 0) {\n this.cropper.x2 -= maintainSize ? this.cropper.x1 : 0;\n this.cropper.x1 = 0;\n }\n if (this.cropper.y1 < 0) {\n this.cropper.y2 -= maintainSize ? this.cropper.y1 : 0;\n this.cropper.y1 = 0;\n }\n if (this.cropper.x2 > this.maxSize.width) {\n this.cropper.x1 -= maintainSize ? (this.cropper.x2 - this.maxSize.width) : 0;\n this.cropper.x2 = this.maxSize.width;\n }\n if (this.cropper.y2 > this.maxSize.height) {\n this.cropper.y1 -= maintainSize ? (this.cropper.y2 - this.maxSize.height) : 0;\n this.cropper.y2 = this.maxSize.height;\n }\n }\n /**\n * @return {?}\n */\n moveStop() {\n if (this.moveStart.active) {\n this.moveStart.active = false;\n this.doAutoCrop();\n }\n }\n /**\n * @return {?}\n */\n pinchStop() {\n if (this.moveStart.active) {\n this.moveStart.active = false;\n this.doAutoCrop();\n }\n }\n /**\n * @private\n * @return {?}\n */\n doAutoCrop() {\n if (this.autoCrop) {\n this.crop();\n }\n }\n /**\n * @return {?}\n */\n crop() {\n if (this.sourceImage && this.sourceImage.nativeElement && this.loadedImage.transformed.image != null) {\n this.startCropImage.emit();\n /** @type {?} */\n const output = this.cropService.crop(this.sourceImage, this.loadedImage, this.cropper, this.settings);\n if (output != null) {\n this.imageCropped.emit(output);\n }\n return output;\n }\n return null;\n }\n}\nImageCropperComponent.ɵfac = function ImageCropperComponent_Factory(t) { return new (t || ImageCropperComponent)(ɵngcc0.ɵɵdirectiveInject(CropService), ɵngcc0.ɵɵdirectiveInject(CropperPositionService), ɵngcc0.ɵɵdirectiveInject(LoadImageService), ɵngcc0.ɵɵdirectiveInject(ɵngcc1.DomSanitizer), ɵngcc0.ɵɵdirectiveInject(ɵngcc0.ChangeDetectorRef)); };\nImageCropperComponent.ɵcmp = ɵngcc0.ɵɵdefineComponent({ type: ImageCropperComponent, selectors: [[\"image-cropper\"]], viewQuery: function ImageCropperComponent_Query(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵstaticViewQuery(_c0, true);\n ɵngcc0.ɵɵviewQuery(_c1, true);\n } if (rf & 2) {\n let _t;\n ɵngcc0.ɵɵqueryRefresh(_t = ɵngcc0.ɵɵloadQuery()) && (ctx.wrapper = _t.first);\n ɵngcc0.ɵɵqueryRefresh(_t = ɵngcc0.ɵɵloadQuery()) && (ctx.sourceImage = _t.first);\n } }, hostVars: 4, hostBindings: function ImageCropperComponent_HostBindings(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵlistener(\"resize\", function ImageCropperComponent_resize_HostBindingHandler() { return ctx.onResize(); }, false, ɵngcc0.ɵɵresolveWindow)(\"mousemove\", function ImageCropperComponent_mousemove_HostBindingHandler($event) { return ctx.moveImg($event); }, false, ɵngcc0.ɵɵresolveDocument)(\"touchmove\", function ImageCropperComponent_touchmove_HostBindingHandler($event) { return ctx.moveImg($event); }, false, ɵngcc0.ɵɵresolveDocument)(\"mouseup\", function ImageCropperComponent_mouseup_HostBindingHandler() { return ctx.moveStop(); }, false, ɵngcc0.ɵɵresolveDocument)(\"touchend\", function ImageCropperComponent_touchend_HostBindingHandler() { return ctx.moveStop(); }, false, ɵngcc0.ɵɵresolveDocument);\n } if (rf & 2) {\n ɵngcc0.ɵɵstyleProp(\"text-align\", ctx.alignImage);\n ɵngcc0.ɵɵclassProp(\"disabled\", ctx.disabled);\n } }, inputs: { format: \"format\", transform: \"transform\", maintainAspectRatio: \"maintainAspectRatio\", aspectRatio: \"aspectRatio\", resizeToWidth: \"resizeToWidth\", resizeToHeight: \"resizeToHeight\", cropperMinWidth: \"cropperMinWidth\", cropperMinHeight: \"cropperMinHeight\", cropperMaxHeight: \"cropperMaxHeight\", cropperMaxWidth: \"cropperMaxWidth\", cropperStaticWidth: \"cropperStaticWidth\", cropperStaticHeight: \"cropperStaticHeight\", canvasRotation: \"canvasRotation\", initialStepSize: \"initialStepSize\", roundCropper: \"roundCropper\", onlyScaleDown: \"onlyScaleDown\", imageQuality: \"imageQuality\", autoCrop: \"autoCrop\", backgroundColor: \"backgroundColor\", containWithinAspectRatio: \"containWithinAspectRatio\", hideResizeSquares: \"hideResizeSquares\", cropper: \"cropper\", alignImage: \"alignImage\", disabled: \"disabled\", imageChangedEvent: \"imageChangedEvent\", imageURL: \"imageURL\", imageBase64: \"imageBase64\", imageFile: \"imageFile\" }, outputs: { imageCropped: \"imageCropped\", startCropImage: \"startCropImage\", imageLoaded: \"imageLoaded\", cropperReady: \"cropperReady\", loadImageFailed: \"loadImageFailed\" }, features: [ɵngcc0.ɵɵNgOnChangesFeature], decls: 5, vars: 10, consts: [[\"wrapper\", \"\"], [\"class\", \"source-image\", 3, \"src\", \"visibility\", \"transform\", \"load\", 4, \"ngIf\"], [1, \"overlay\"], [\"class\", \"cropper\", \"tabindex\", \"0\", 3, \"rounded\", \"top\", \"left\", \"width\", \"height\", \"margin-left\", \"visibility\", \"keydown\", 4, \"ngIf\"], [1, \"source-image\", 3, \"src\", \"load\"], [\"sourceImage\", \"\"], [\"tabindex\", \"0\", 1, \"cropper\", 3, \"keydown\"], [1, \"move\", 3, \"mousedown\", \"touchstart\"], [4, \"ngIf\"], [1, \"resize\", \"topleft\", 3, \"mousedown\", \"touchstart\"], [1, \"square\"], [1, \"resize\", \"top\"], [1, \"resize\", \"topright\", 3, \"mousedown\", \"touchstart\"], [1, \"resize\", \"right\"], [1, \"resize\", \"bottomright\", 3, \"mousedown\", \"touchstart\"], [1, \"resize\", \"bottom\"], [1, \"resize\", \"bottomleft\", 3, \"mousedown\", \"touchstart\"], [1, \"resize\", \"left\"], [1, \"resize-bar\", \"top\", 3, \"mousedown\", \"touchstart\"], [1, \"resize-bar\", \"right\", 3, \"mousedown\", \"touchstart\"], [1, \"resize-bar\", \"bottom\", 3, \"mousedown\", \"touchstart\"], [1, \"resize-bar\", \"left\", 3, \"mousedown\", \"touchstart\"]], template: function ImageCropperComponent_Template(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵelementStart(0, \"div\", null, 0);\n ɵngcc0.ɵɵtemplate(2, ImageCropperComponent_img_2_Template, 2, 5, \"img\", 1);\n ɵngcc0.ɵɵelement(3, \"div\", 2);\n ɵngcc0.ɵɵtemplate(4, ImageCropperComponent_div_4_Template, 3, 15, \"div\", 3);\n ɵngcc0.ɵɵelementEnd();\n } if (rf & 2) {\n ɵngcc0.ɵɵstyleProp(\"background\", ctx.imageVisible && ctx.backgroundColor);\n ɵngcc0.ɵɵadvance(2);\n ɵngcc0.ɵɵproperty(\"ngIf\", ctx.safeImgDataUrl);\n ɵngcc0.ɵɵadvance(1);\n ɵngcc0.ɵɵstyleProp(\"width\", ctx.maxSize.width, \"px\")(\"height\", ctx.maxSize.height, \"px\")(\"margin-left\", ctx.alignImage === \"center\" ? ctx.marginLeft : null);\n ɵngcc0.ɵɵadvance(1);\n ɵngcc0.ɵɵproperty(\"ngIf\", ctx.imageVisible);\n } }, directives: [ɵngcc2.NgIf], styles: [\"[_nghost-%COMP%]{display:flex;position:relative;width:100%;max-width:100%;max-height:100%;overflow:hidden;padding:5px;text-align:center}[_nghost-%COMP%] > div[_ngcontent-%COMP%]{width:100%;position:relative}[_nghost-%COMP%] > div[_ngcontent-%COMP%] img.source-image[_ngcontent-%COMP%]{max-width:100%;max-height:100%;transform-origin:center}[_nghost-%COMP%] .overlay[_ngcontent-%COMP%]{position:absolute;pointer-events:none;touch-action:none;outline:var(--cropper-overlay-color,#fff) solid 100vw;top:0;left:0}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%]{position:absolute;display:flex;color:#53535c;background:0 0;outline:rgba(255,255,255,.3) solid 100vw;outline:var(--cropper-outline-color,rgba(255,255,255,.3)) solid 100vw;touch-action:none}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%]:after{position:absolute;content:\\\"\\\";top:0;bottom:0;left:0;right:0;pointer-events:none;border:1px dashed;opacity:.75;color:inherit;z-index:1}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .move[_ngcontent-%COMP%]{width:100%;cursor:move;border:1px solid rgba(255,255,255,.5)}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%]:focus .move[_ngcontent-%COMP%]{border-color:#1e90ff;border-width:2px}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .resize[_ngcontent-%COMP%]{position:absolute;display:inline-block;line-height:6px;padding:8px;opacity:.85;z-index:1}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .resize[_ngcontent-%COMP%] .square[_ngcontent-%COMP%]{display:inline-block;background:#53535c;width:6px;height:6px;border:1px solid rgba(255,255,255,.5);box-sizing:content-box}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .resize.topleft[_ngcontent-%COMP%]{top:-12px;left:-12px;cursor:nwse-resize}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .resize.top[_ngcontent-%COMP%]{top:-12px;left:calc(50% - 12px);cursor:ns-resize}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .resize.topright[_ngcontent-%COMP%]{top:-12px;right:-12px;cursor:nesw-resize}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .resize.right[_ngcontent-%COMP%]{top:calc(50% - 12px);right:-12px;cursor:ew-resize}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .resize.bottomright[_ngcontent-%COMP%]{bottom:-12px;right:-12px;cursor:nwse-resize}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .resize.bottom[_ngcontent-%COMP%]{bottom:-12px;left:calc(50% - 12px);cursor:ns-resize}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .resize.bottomleft[_ngcontent-%COMP%]{bottom:-12px;left:-12px;cursor:nesw-resize}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .resize.left[_ngcontent-%COMP%]{top:calc(50% - 12px);left:-12px;cursor:ew-resize}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .resize-bar[_ngcontent-%COMP%]{position:absolute;z-index:1}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .resize-bar.top[_ngcontent-%COMP%]{top:-11px;left:11px;width:calc(100% - 22px);height:22px;cursor:ns-resize}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .resize-bar.right[_ngcontent-%COMP%]{top:11px;right:-11px;height:calc(100% - 22px);width:22px;cursor:ew-resize}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .resize-bar.bottom[_ngcontent-%COMP%]{bottom:-11px;left:11px;width:calc(100% - 22px);height:22px;cursor:ns-resize}[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .resize-bar.left[_ngcontent-%COMP%]{top:11px;left:-11px;height:calc(100% - 22px);width:22px;cursor:ew-resize}[_nghost-%COMP%] .cropper.rounded[_ngcontent-%COMP%]{outline-color:transparent}[_nghost-%COMP%] .cropper.rounded[_ngcontent-%COMP%]:after{border-radius:100%;box-shadow:0 0 0 100vw rgba(255,255,255,.3);box-shadow:0 0 0 100vw var(--cropper-outline-color,rgba(255,255,255,.3))}@media (orientation:portrait){[_nghost-%COMP%] .cropper[_ngcontent-%COMP%]{outline-width:100vh}[_nghost-%COMP%] .cropper.rounded[_ngcontent-%COMP%]:after{box-shadow:0 0 0 100vh rgba(255,255,255,.3);box-shadow:0 0 0 100vh var(--cropper-outline-color,rgba(255,255,255,.3))}}[_nghost-%COMP%] .cropper.rounded[_ngcontent-%COMP%] .move[_ngcontent-%COMP%]{border-radius:100%}.disabled[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .move[_ngcontent-%COMP%], .disabled[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .resize[_ngcontent-%COMP%], .disabled[_nghost-%COMP%] .cropper[_ngcontent-%COMP%] .resize-bar[_ngcontent-%COMP%]{display:none}\"], changeDetection: 0 });\n/** @nocollapse */\nImageCropperComponent.ctorParameters = () => [\n { type: CropService },\n { type: CropperPositionService },\n { type: LoadImageService },\n { type: DomSanitizer },\n { type: ChangeDetectorRef }\n];\nImageCropperComponent.propDecorators = {\n wrapper: [{ type: ViewChild, args: ['wrapper', { static: true },] }],\n sourceImage: [{ type: ViewChild, args: ['sourceImage', { static: false },] }],\n imageChangedEvent: [{ type: Input }],\n imageURL: [{ type: Input }],\n imageBase64: [{ type: Input }],\n imageFile: [{ type: Input }],\n format: [{ type: Input }],\n transform: [{ type: Input }],\n maintainAspectRatio: [{ type: Input }],\n aspectRatio: [{ type: Input }],\n resizeToWidth: [{ type: Input }],\n resizeToHeight: [{ type: Input }],\n cropperMinWidth: [{ type: Input }],\n cropperMinHeight: [{ type: Input }],\n cropperMaxHeight: [{ type: Input }],\n cropperMaxWidth: [{ type: Input }],\n cropperStaticWidth: [{ type: Input }],\n cropperStaticHeight: [{ type: Input }],\n canvasRotation: [{ type: Input }],\n initialStepSize: [{ type: Input }],\n roundCropper: [{ type: Input }],\n onlyScaleDown: [{ type: Input }],\n imageQuality: [{ type: Input }],\n autoCrop: [{ type: Input }],\n backgroundColor: [{ type: Input }],\n containWithinAspectRatio: [{ type: Input }],\n hideResizeSquares: [{ type: Input }],\n cropper: [{ type: Input }],\n alignImage: [{ type: HostBinding, args: ['style.text-align',] }, { type: Input }],\n disabled: [{ type: HostBinding, args: ['class.disabled',] }, { type: Input }],\n imageCropped: [{ type: Output }],\n startCropImage: [{ type: Output }],\n imageLoaded: [{ type: Output }],\n cropperReady: [{ type: Output }],\n loadImageFailed: [{ type: Output }],\n onResize: [{ type: HostListener, args: ['window:resize',] }],\n moveImg: [{ type: HostListener, args: ['document:mousemove', ['$event'],] }, { type: HostListener, args: ['document:touchmove', ['$event'],] }],\n moveStop: [{ type: HostListener, args: ['document:mouseup',] }, { type: HostListener, args: ['document:touchend',] }]\n};\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(ImageCropperComponent, [{\n type: Component,\n args: [{\n selector: 'image-cropper',\n template: \"
\\n \\n
\\n
\\n \\n
\\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n\\n\",\n changeDetection: ChangeDetectionStrategy.OnPush,\n styles: [\":host{display:flex;position:relative;width:100%;max-width:100%;max-height:100%;overflow:hidden;padding:5px;text-align:center}:host>div{width:100%;position:relative}:host>div img.source-image{max-width:100%;max-height:100%;transform-origin:center}:host .overlay{position:absolute;pointer-events:none;touch-action:none;outline:var(--cropper-overlay-color,#fff) solid 100vw;top:0;left:0}:host .cropper{position:absolute;display:flex;color:#53535c;background:0 0;outline:rgba(255,255,255,.3) solid 100vw;outline:var(--cropper-outline-color,rgba(255,255,255,.3)) solid 100vw;touch-action:none}:host .cropper:after{position:absolute;content:\\\"\\\";top:0;bottom:0;left:0;right:0;pointer-events:none;border:1px dashed;opacity:.75;color:inherit;z-index:1}:host .cropper .move{width:100%;cursor:move;border:1px solid rgba(255,255,255,.5)}:host .cropper:focus .move{border-color:#1e90ff;border-width:2px}:host .cropper .resize{position:absolute;display:inline-block;line-height:6px;padding:8px;opacity:.85;z-index:1}:host .cropper .resize .square{display:inline-block;background:#53535c;width:6px;height:6px;border:1px solid rgba(255,255,255,.5);box-sizing:content-box}:host .cropper .resize.topleft{top:-12px;left:-12px;cursor:nwse-resize}:host .cropper .resize.top{top:-12px;left:calc(50% - 12px);cursor:ns-resize}:host .cropper .resize.topright{top:-12px;right:-12px;cursor:nesw-resize}:host .cropper .resize.right{top:calc(50% - 12px);right:-12px;cursor:ew-resize}:host .cropper .resize.bottomright{bottom:-12px;right:-12px;cursor:nwse-resize}:host .cropper .resize.bottom{bottom:-12px;left:calc(50% - 12px);cursor:ns-resize}:host .cropper .resize.bottomleft{bottom:-12px;left:-12px;cursor:nesw-resize}:host .cropper .resize.left{top:calc(50% - 12px);left:-12px;cursor:ew-resize}:host .cropper .resize-bar{position:absolute;z-index:1}:host .cropper .resize-bar.top{top:-11px;left:11px;width:calc(100% - 22px);height:22px;cursor:ns-resize}:host .cropper .resize-bar.right{top:11px;right:-11px;height:calc(100% - 22px);width:22px;cursor:ew-resize}:host .cropper .resize-bar.bottom{bottom:-11px;left:11px;width:calc(100% - 22px);height:22px;cursor:ns-resize}:host .cropper .resize-bar.left{top:11px;left:-11px;height:calc(100% - 22px);width:22px;cursor:ew-resize}:host .cropper.rounded{outline-color:transparent}:host .cropper.rounded:after{border-radius:100%;box-shadow:0 0 0 100vw rgba(255,255,255,.3);box-shadow:0 0 0 100vw var(--cropper-outline-color,rgba(255,255,255,.3))}@media (orientation:portrait){:host .cropper{outline-width:100vh}:host .cropper.rounded:after{box-shadow:0 0 0 100vh rgba(255,255,255,.3);box-shadow:0 0 0 100vh var(--cropper-outline-color,rgba(255,255,255,.3))}}:host .cropper.rounded .move{border-radius:100%}:host.disabled .cropper .move,:host.disabled .cropper .resize,:host.disabled .cropper .resize-bar{display:none}\"]\n }]\n }], function () { return [{ type: CropService }, { type: CropperPositionService }, { type: LoadImageService }, { type: ɵngcc1.DomSanitizer }, { type: ɵngcc0.ChangeDetectorRef }]; }, { format: [{\n type: Input\n }], transform: [{\n type: Input\n }], maintainAspectRatio: [{\n type: Input\n }], aspectRatio: [{\n type: Input\n }], resizeToWidth: [{\n type: Input\n }], resizeToHeight: [{\n type: Input\n }], cropperMinWidth: [{\n type: Input\n }], cropperMinHeight: [{\n type: Input\n }], cropperMaxHeight: [{\n type: Input\n }], cropperMaxWidth: [{\n type: Input\n }], cropperStaticWidth: [{\n type: Input\n }], cropperStaticHeight: [{\n type: Input\n }], canvasRotation: [{\n type: Input\n }], initialStepSize: [{\n type: Input\n }], roundCropper: [{\n type: Input\n }], onlyScaleDown: [{\n type: Input\n }], imageQuality: [{\n type: Input\n }], autoCrop: [{\n type: Input\n }], backgroundColor: [{\n type: Input\n }], containWithinAspectRatio: [{\n type: Input\n }], hideResizeSquares: [{\n type: Input\n }], cropper: [{\n type: Input\n }], alignImage: [{\n type: HostBinding,\n args: ['style.text-align']\n }, {\n type: Input\n }], disabled: [{\n type: HostBinding,\n args: ['class.disabled']\n }, {\n type: Input\n }], imageCropped: [{\n type: Output\n }], startCropImage: [{\n type: Output\n }], imageLoaded: [{\n type: Output\n }], cropperReady: [{\n type: Output\n }], loadImageFailed: [{\n type: Output\n }], \n /**\n * @return {?}\n */\n onResize: [{\n type: HostListener,\n args: ['window:resize']\n }], \n /**\n * @param {?} event\n * @return {?}\n */\n moveImg: [{\n type: HostListener,\n args: ['document:mousemove', ['$event']]\n }, {\n type: HostListener,\n args: ['document:touchmove', ['$event']]\n }], \n /**\n * @return {?}\n */\n moveStop: [{\n type: HostListener,\n args: ['document:mouseup']\n }, {\n type: HostListener,\n args: ['document:touchend']\n }], wrapper: [{\n type: ViewChild,\n args: ['wrapper', { static: true }]\n }], sourceImage: [{\n type: ViewChild,\n args: ['sourceImage', { static: false }]\n }], imageChangedEvent: [{\n type: Input\n }], imageURL: [{\n type: Input\n }], imageBase64: [{\n type: Input\n }], imageFile: [{\n type: Input\n }] }); })();\nif (false) {\n /**\n * @type {?}\n * @private\n */\n ImageCropperComponent.prototype.Hammer;\n /**\n * @type {?}\n * @private\n */\n ImageCropperComponent.prototype.settings;\n /**\n * @type {?}\n * @private\n */\n ImageCropperComponent.prototype.setImageMaxSizeRetries;\n /**\n * @type {?}\n * @private\n */\n ImageCropperComponent.prototype.moveStart;\n /**\n * @type {?}\n * @private\n */\n ImageCropperComponent.prototype.loadedImage;\n /** @type {?} */\n ImageCropperComponent.prototype.safeImgDataUrl;\n /** @type {?} */\n ImageCropperComponent.prototype.safeTransformStyle;\n /** @type {?} */\n ImageCropperComponent.prototype.marginLeft;\n /** @type {?} */\n ImageCropperComponent.prototype.maxSize;\n /** @type {?} */\n ImageCropperComponent.prototype.moveTypes;\n /** @type {?} */\n ImageCropperComponent.prototype.imageVisible;\n /** @type {?} */\n ImageCropperComponent.prototype.wrapper;\n /** @type {?} */\n ImageCropperComponent.prototype.sourceImage;\n /** @type {?} */\n ImageCropperComponent.prototype.imageChangedEvent;\n /** @type {?} */\n ImageCropperComponent.prototype.imageURL;\n /** @type {?} */\n ImageCropperComponent.prototype.imageBase64;\n /** @type {?} */\n ImageCropperComponent.prototype.imageFile;\n /** @type {?} */\n ImageCropperComponent.prototype.format;\n /** @type {?} */\n ImageCropperComponent.prototype.transform;\n /** @type {?} */\n ImageCropperComponent.prototype.maintainAspectRatio;\n /** @type {?} */\n ImageCropperComponent.prototype.aspectRatio;\n /** @type {?} */\n ImageCropperComponent.prototype.resizeToWidth;\n /** @type {?} */\n ImageCropperComponent.prototype.resizeToHeight;\n /** @type {?} */\n ImageCropperComponent.prototype.cropperMinWidth;\n /** @type {?} */\n ImageCropperComponent.prototype.cropperMinHeight;\n /** @type {?} */\n ImageCropperComponent.prototype.cropperMaxHeight;\n /** @type {?} */\n ImageCropperComponent.prototype.cropperMaxWidth;\n /** @type {?} */\n ImageCropperComponent.prototype.cropperStaticWidth;\n /** @type {?} */\n ImageCropperComponent.prototype.cropperStaticHeight;\n /** @type {?} */\n ImageCropperComponent.prototype.canvasRotation;\n /** @type {?} */\n ImageCropperComponent.prototype.initialStepSize;\n /** @type {?} */\n ImageCropperComponent.prototype.roundCropper;\n /** @type {?} */\n ImageCropperComponent.prototype.onlyScaleDown;\n /** @type {?} */\n ImageCropperComponent.prototype.imageQuality;\n /** @type {?} */\n ImageCropperComponent.prototype.autoCrop;\n /** @type {?} */\n ImageCropperComponent.prototype.backgroundColor;\n /** @type {?} */\n ImageCropperComponent.prototype.containWithinAspectRatio;\n /** @type {?} */\n ImageCropperComponent.prototype.hideResizeSquares;\n /** @type {?} */\n ImageCropperComponent.prototype.cropper;\n /** @type {?} */\n ImageCropperComponent.prototype.alignImage;\n /** @type {?} */\n ImageCropperComponent.prototype.disabled;\n /** @type {?} */\n ImageCropperComponent.prototype.imageCropped;\n /** @type {?} */\n ImageCropperComponent.prototype.startCropImage;\n /** @type {?} */\n ImageCropperComponent.prototype.imageLoaded;\n /** @type {?} */\n ImageCropperComponent.prototype.cropperReady;\n /** @type {?} */\n ImageCropperComponent.prototype.loadImageFailed;\n /**\n * @type {?}\n * @private\n */\n ImageCropperComponent.prototype.cropService;\n /**\n * @type {?}\n * @private\n */\n ImageCropperComponent.prototype.cropperPositionService;\n /**\n * @type {?}\n * @private\n */\n ImageCropperComponent.prototype.loadImageService;\n /**\n * @type {?}\n * @private\n */\n ImageCropperComponent.prototype.sanitizer;\n /**\n * @type {?}\n * @private\n */\n ImageCropperComponent.prototype.cd;\n}\n\n/**\n * @fileoverview added by tsickle\n * Generated from: lib/image-cropper.module.ts\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\nclass ImageCropperModule {\n}\nImageCropperModule.ɵmod = ɵngcc0.ɵɵdefineNgModule({ type: ImageCropperModule });\nImageCropperModule.ɵinj = ɵngcc0.ɵɵdefineInjector({ factory: function ImageCropperModule_Factory(t) { return new (t || ImageCropperModule)(); }, imports: [[\n CommonModule\n ]] });\n(function () { (typeof ngJitMode === \"undefined\" || ngJitMode) && ɵngcc0.ɵɵsetNgModuleScope(ImageCropperModule, { declarations: function () { return [ImageCropperComponent]; }, imports: function () { return [CommonModule]; }, exports: function () { return [ImageCropperComponent]; } }); })();\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(ImageCropperModule, [{\n type: NgModule,\n args: [{\n imports: [\n CommonModule\n ],\n declarations: [\n ImageCropperComponent\n ],\n exports: [\n ImageCropperComponent\n ]\n }]\n }], null, null); })();\n\n/**\n * @fileoverview added by tsickle\n * Generated from: lib/interfaces/index.ts\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\n\n/**\n * @fileoverview added by tsickle\n * Generated from: lib/utils/blob.utils.ts\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\n/**\n * @param {?} base64Image\n * @return {?}\n */\nfunction base64ToFile(base64Image) {\n /** @type {?} */\n const split = base64Image.split(',');\n /** @type {?} */\n const type = split[0].replace('data:', '').replace(';base64', '');\n /** @type {?} */\n const byteString = atob(split[1]);\n /** @type {?} */\n const ab = new ArrayBuffer(byteString.length);\n /** @type {?} */\n const ia = new Uint8Array(ab);\n for (let i = 0; i < byteString.length; i += 1) {\n ia[i] = byteString.charCodeAt(i);\n }\n return new Blob([ab], { type });\n}\n\n/**\n * @fileoverview added by tsickle\n * Generated from: public-api.ts\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\n\n/**\n * @fileoverview added by tsickle\n * Generated from: ngx-image-cropper.ts\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\n\nexport { ImageCropperComponent, ImageCropperModule, base64ToFile, CropService as ɵa, CropperPositionService as ɵb, LoadImageService as ɵc };\n\n//# sourceMappingURL=ngx-image-cropper.js.map","
\n \n
\n
\n \n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n","import { ɵɵdefineInjectable, Injectable, Component, Directive, TemplateRef, Input, NgModule } from '@angular/core';\nimport { Subject } from 'rxjs';\nimport { ObjectUtils } from 'primeng/utils';\nimport { CommonModule } from '@angular/common';\n\nimport * as ɵngcc0 from '@angular/core';\n\nconst _c0 = [\"*\"];\nclass FilterMatchMode {\n}\nFilterMatchMode.STARTS_WITH = 'startsWith';\nFilterMatchMode.CONTAINS = 'contains';\nFilterMatchMode.NOT_CONTAINS = 'notContains';\nFilterMatchMode.ENDS_WITH = 'endsWith';\nFilterMatchMode.EQUALS = 'equals';\nFilterMatchMode.NOT_EQUALS = 'notEquals';\nFilterMatchMode.IN = 'in';\nFilterMatchMode.LESS_THAN = 'lt';\nFilterMatchMode.LESS_THAN_OR_EQUAL_TO = 'lte';\nFilterMatchMode.GREATER_THAN = 'gt';\nFilterMatchMode.GREATER_THAN_OR_EQUAL_TO = 'gte';\nFilterMatchMode.BETWEEN = 'between';\nFilterMatchMode.IS = 'is';\nFilterMatchMode.IS_NOT = 'isNot';\nFilterMatchMode.BEFORE = 'before';\nFilterMatchMode.AFTER = 'after';\n\nclass PrimeNGConfig {\n constructor() {\n this.ripple = false;\n this.filterMatchModeOptions = {\n text: [\n FilterMatchMode.STARTS_WITH,\n FilterMatchMode.CONTAINS,\n FilterMatchMode.NOT_CONTAINS,\n FilterMatchMode.ENDS_WITH,\n FilterMatchMode.EQUALS,\n FilterMatchMode.NOT_EQUALS\n ],\n numeric: [\n FilterMatchMode.EQUALS,\n FilterMatchMode.NOT_EQUALS,\n FilterMatchMode.LESS_THAN,\n FilterMatchMode.LESS_THAN_OR_EQUAL_TO,\n FilterMatchMode.GREATER_THAN,\n FilterMatchMode.GREATER_THAN_OR_EQUAL_TO\n ],\n date: [\n FilterMatchMode.IS,\n FilterMatchMode.IS_NOT,\n FilterMatchMode.BEFORE,\n FilterMatchMode.AFTER\n ]\n };\n this.translation = {\n startsWith: 'Starts with',\n contains: 'Contains',\n notContains: 'Not contains',\n endsWith: 'Ends with',\n equals: 'Equals',\n notEquals: 'Not equals',\n lt: 'Less than',\n lte: 'Less than or equal to',\n gt: 'Greater than',\n gte: 'Greater than or equal to',\n is: 'Is',\n isNot: 'Is not',\n before: 'Before',\n after: 'After',\n clear: 'Clear',\n apply: 'Apply',\n matchAll: 'Match All',\n matchAny: 'Match Any',\n addRule: 'Add Rule',\n removeRule: 'Remove Rule',\n accept: 'Yes',\n reject: 'No',\n choose: 'Choose',\n upload: 'Upload',\n cancel: 'Cancel',\n dayNames: [\"Sunday\", \"Monday\", \"Tuesday\", \"Wednesday\", \"Thursday\", \"Friday\", \"Saturday\"],\n dayNamesShort: [\"Sun\", \"Mon\", \"Tue\", \"Wed\", \"Thu\", \"Fri\", \"Sat\"],\n dayNamesMin: [\"Su\", \"Mo\", \"Tu\", \"We\", \"Th\", \"Fr\", \"Sa\"],\n monthNames: [\"January\", \"February\", \"March\", \"April\", \"May\", \"June\", \"July\", \"August\", \"September\", \"October\", \"November\", \"December\"],\n monthNamesShort: [\"Jan\", \"Feb\", \"Mar\", \"Apr\", \"May\", \"Jun\", \"Jul\", \"Aug\", \"Sep\", \"Oct\", \"Nov\", \"Dec\"],\n today: 'Today',\n weekHeader: 'Wk'\n };\n this.translationSource = new Subject();\n this.translationObserver = this.translationSource.asObservable();\n }\n getTranslation(key) {\n return this.translation[key];\n }\n setTranslation(value) {\n this.translation = Object.assign(Object.assign({}, this.translation), value);\n this.translationSource.next(this.translation);\n }\n}\nPrimeNGConfig.ɵfac = function PrimeNGConfig_Factory(t) { return new (t || PrimeNGConfig)(); };\nPrimeNGConfig.ɵprov = ɵɵdefineInjectable({ factory: function PrimeNGConfig_Factory() { return new PrimeNGConfig(); }, token: PrimeNGConfig, providedIn: \"root\" });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(PrimeNGConfig, [{\n type: Injectable,\n args: [{ providedIn: 'root' }]\n }], function () { return []; }, null); })();\n\nclass TranslationKeys {\n}\nTranslationKeys.STARTS_WITH = 'startsWith';\nTranslationKeys.CONTAINS = 'contains';\nTranslationKeys.NOT_CONTAINS = 'notContains';\nTranslationKeys.ENDS_WITH = 'endsWith';\nTranslationKeys.EQUALS = 'equals';\nTranslationKeys.NOT_EQUALS = 'notEquals';\nTranslationKeys.LT = 'lt';\nTranslationKeys.LTE = 'lte';\nTranslationKeys.GT = 'gt';\nTranslationKeys.GTE = 'gte';\nTranslationKeys.IS = 'is';\nTranslationKeys.IS_NOT = 'isNot';\nTranslationKeys.BEFORE = 'before';\nTranslationKeys.AFTER = 'after';\nTranslationKeys.CLEAR = 'clear';\nTranslationKeys.APPLY = 'apply';\nTranslationKeys.MATCH_ALL = 'matchAll';\nTranslationKeys.MATCH_ANY = 'matchAny';\nTranslationKeys.ADD_RULE = 'addRule';\nTranslationKeys.REMOVE_RULE = 'removeRule';\nTranslationKeys.ACCEPT = 'accept';\nTranslationKeys.REJECT = 'reject';\nTranslationKeys.CHOOSE = 'choose';\nTranslationKeys.UPLOAD = 'upload';\nTranslationKeys.CANCEL = 'cancel';\nTranslationKeys.DAY_NAMES = 'dayNames';\nTranslationKeys.DAY_NAMES_SHORT = 'dayNamesShort';\nTranslationKeys.DAY_NAMES_MIN = 'dayNamesMin';\nTranslationKeys.MONTH_NAMES = 'monthNames';\nTranslationKeys.MONTH_NAMES_SHORT = 'monthNamesShort';\nTranslationKeys.TODAY = 'today';\nTranslationKeys.WEEK_HEADER = 'weekHeader';\n\nclass ConfirmationService {\n constructor() {\n this.requireConfirmationSource = new Subject();\n this.acceptConfirmationSource = new Subject();\n this.requireConfirmation$ = this.requireConfirmationSource.asObservable();\n this.accept = this.acceptConfirmationSource.asObservable();\n }\n confirm(confirmation) {\n this.requireConfirmationSource.next(confirmation);\n return this;\n }\n close() {\n this.requireConfirmationSource.next(null);\n return this;\n }\n onAccept() {\n this.acceptConfirmationSource.next();\n }\n}\nConfirmationService.ɵfac = function ConfirmationService_Factory(t) { return new (t || ConfirmationService)(); };\nConfirmationService.ɵprov = ɵngcc0.ɵɵdefineInjectable({ token: ConfirmationService, factory: ConfirmationService.ɵfac });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(ConfirmationService, [{\n type: Injectable\n }], function () { return []; }, null); })();\n\nclass FilterService {\n constructor() {\n this.filters = {\n startsWith: (value, filter, filterLocale) => {\n if (filter === undefined || filter === null || filter.trim() === '') {\n return true;\n }\n if (value === undefined || value === null) {\n return false;\n }\n let filterValue = ObjectUtils.removeAccents(filter.toString()).toLocaleLowerCase(filterLocale);\n let stringValue = ObjectUtils.removeAccents(value.toString()).toLocaleLowerCase(filterLocale);\n return stringValue.slice(0, filterValue.length) === filterValue;\n },\n contains: (value, filter, filterLocale) => {\n if (filter === undefined || filter === null || (typeof filter === 'string' && filter.trim() === '')) {\n return true;\n }\n if (value === undefined || value === null) {\n return false;\n }\n let filterValue = ObjectUtils.removeAccents(filter.toString()).toLocaleLowerCase(filterLocale);\n let stringValue = ObjectUtils.removeAccents(value.toString()).toLocaleLowerCase(filterLocale);\n return stringValue.indexOf(filterValue) !== -1;\n },\n notContains: (value, filter, filterLocale) => {\n if (filter === undefined || filter === null || (typeof filter === 'string' && filter.trim() === '')) {\n return true;\n }\n if (value === undefined || value === null) {\n return false;\n }\n let filterValue = ObjectUtils.removeAccents(filter.toString()).toLocaleLowerCase(filterLocale);\n let stringValue = ObjectUtils.removeAccents(value.toString()).toLocaleLowerCase(filterLocale);\n return stringValue.indexOf(filterValue) === -1;\n },\n endsWith: (value, filter, filterLocale) => {\n if (filter === undefined || filter === null || filter.trim() === '') {\n return true;\n }\n if (value === undefined || value === null) {\n return false;\n }\n let filterValue = ObjectUtils.removeAccents(filter.toString()).toLocaleLowerCase(filterLocale);\n let stringValue = ObjectUtils.removeAccents(value.toString()).toLocaleLowerCase(filterLocale);\n return stringValue.indexOf(filterValue, stringValue.length - filterValue.length) !== -1;\n },\n equals: (value, filter, filterLocale) => {\n if (filter === undefined || filter === null || (typeof filter === 'string' && filter.trim() === '')) {\n return true;\n }\n if (value === undefined || value === null) {\n return false;\n }\n if (value.getTime && filter.getTime)\n return value.getTime() === filter.getTime();\n else\n return ObjectUtils.removeAccents(value.toString()).toLocaleLowerCase(filterLocale) == ObjectUtils.removeAccents(filter.toString()).toLocaleLowerCase(filterLocale);\n },\n notEquals: (value, filter, filterLocale) => {\n if (filter === undefined || filter === null || (typeof filter === 'string' && filter.trim() === '')) {\n return false;\n }\n if (value === undefined || value === null) {\n return true;\n }\n if (value.getTime && filter.getTime)\n return value.getTime() !== filter.getTime();\n else\n return ObjectUtils.removeAccents(value.toString()).toLocaleLowerCase(filterLocale) != ObjectUtils.removeAccents(filter.toString()).toLocaleLowerCase(filterLocale);\n },\n in: (value, filter) => {\n if (filter === undefined || filter === null || filter.length === 0) {\n return true;\n }\n for (let i = 0; i < filter.length; i++) {\n if (ObjectUtils.equals(value, filter[i])) {\n return true;\n }\n }\n return false;\n },\n between: (value, filter) => {\n if (filter == null || filter[0] == null || filter[0] == null) {\n return true;\n }\n if (value === undefined || value === null) {\n return false;\n }\n if (value.getTime)\n return filter[0].getTime() >= value.getTime() && value.getTime() <= filter[1].getTime();\n else\n return filter[0] <= value && value <= filter[1];\n },\n lt: (value, filter, filterLocale) => {\n if (filter === undefined || filter === null) {\n return true;\n }\n if (value === undefined || value === null) {\n return false;\n }\n if (value.getTime && filter.getTime)\n return value.getTime() < filter.getTime();\n else\n return value < filter;\n },\n lte: (value, filter, filterLocale) => {\n if (filter === undefined || filter === null) {\n return true;\n }\n if (value === undefined || value === null) {\n return false;\n }\n if (value.getTime && filter.getTime)\n return value.getTime() <= filter.getTime();\n else\n return value <= filter;\n },\n gt: (value, filter, filterLocale) => {\n if (filter === undefined || filter === null) {\n return true;\n }\n if (value === undefined || value === null) {\n return false;\n }\n if (value.getTime && filter.getTime)\n return value.getTime() > filter.getTime();\n else\n return value > filter;\n },\n gte: (value, filter, filterLocale) => {\n if (filter === undefined || filter === null) {\n return true;\n }\n if (value === undefined || value === null) {\n return false;\n }\n if (value.getTime && filter.getTime)\n return value.getTime() >= filter.getTime();\n else\n return value >= filter;\n },\n is: (value, filter, filterLocale) => {\n return this.filters.equals(value, filter, filterLocale);\n },\n isNot: (value, filter, filterLocale) => {\n return this.filters.notEquals(value, filter, filterLocale);\n },\n before: (value, filter, filterLocale) => {\n return this.filters.lt(value, filter, filterLocale);\n },\n after: (value, filter, filterLocale) => {\n return this.filters.gt(value, filter, filterLocale);\n }\n };\n }\n filter(value, fields, filterValue, filterMatchMode, filterLocale) {\n let filteredItems = [];\n if (value) {\n for (let item of value) {\n for (let field of fields) {\n let fieldValue = ObjectUtils.resolveFieldData(item, field);\n if (this.filters[filterMatchMode](fieldValue, filterValue, filterLocale)) {\n filteredItems.push(item);\n break;\n }\n }\n }\n }\n return filteredItems;\n }\n register(rule, fn) {\n this.filters[rule] = fn;\n }\n}\nFilterService.ɵfac = function FilterService_Factory(t) { return new (t || FilterService)(); };\nFilterService.ɵprov = ɵɵdefineInjectable({ factory: function FilterService_Factory() { return new FilterService(); }, token: FilterService, providedIn: \"root\" });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(FilterService, [{\n type: Injectable,\n args: [{ providedIn: 'root' }]\n }], function () { return []; }, null); })();\n\nclass ContextMenuService {\n constructor() {\n this.activeItemKeyChange = new Subject();\n this.activeItemKeyChange$ = this.activeItemKeyChange.asObservable();\n }\n changeKey(key) {\n this.activeItemKey = key;\n this.activeItemKeyChange.next(this.activeItemKey);\n }\n reset() {\n this.activeItemKey = null;\n this.activeItemKeyChange.next(this.activeItemKey);\n }\n}\nContextMenuService.ɵfac = function ContextMenuService_Factory(t) { return new (t || ContextMenuService)(); };\nContextMenuService.ɵprov = ɵngcc0.ɵɵdefineInjectable({ token: ContextMenuService, factory: ContextMenuService.ɵfac });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(ContextMenuService, [{\n type: Injectable\n }], function () { return []; }, null); })();\n\nclass MessageService {\n constructor() {\n this.messageSource = new Subject();\n this.clearSource = new Subject();\n this.messageObserver = this.messageSource.asObservable();\n this.clearObserver = this.clearSource.asObservable();\n }\n add(message) {\n if (message) {\n this.messageSource.next(message);\n }\n }\n addAll(messages) {\n if (messages && messages.length) {\n this.messageSource.next(messages);\n }\n }\n clear(key) {\n this.clearSource.next(key || null);\n }\n}\nMessageService.ɵfac = function MessageService_Factory(t) { return new (t || MessageService)(); };\nMessageService.ɵprov = ɵngcc0.ɵɵdefineInjectable({ token: MessageService, factory: MessageService.ɵfac });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(MessageService, [{\n type: Injectable\n }], function () { return []; }, null); })();\n\nclass PrimeIcons {\n}\nPrimeIcons.ALIGN_CENTER = 'pi pi-align-center';\nPrimeIcons.ALIGN_JUSTIFY = 'pi pi-align-justify';\nPrimeIcons.ALIGN_LEFT = 'pi pi-align-left';\nPrimeIcons.ALIGN_RIGHT = 'pi pi-align-right';\nPrimeIcons.AMAZON = 'pi pi-amazon';\nPrimeIcons.ANDROID = 'pi pi-android';\nPrimeIcons.ANGLE_DOUBLE_DOWN = 'pi pi-angle-double-down';\nPrimeIcons.ANGLE_DOUBLE_LEFT = 'pi pi-angle-double-left';\nPrimeIcons.ANGLE_DOUBLE_RIGHT = 'pi pi-angle-double-right';\nPrimeIcons.ANGLE_DOUBLE_UP = 'pi pi-angle-double-up';\nPrimeIcons.ANGLE_DOWN = 'pi pi-angle-down';\nPrimeIcons.ANGLE_LEFT = 'pi pi-angle-left';\nPrimeIcons.ANGLE_RIGHT = 'pi pi-angle-right';\nPrimeIcons.ANGLE_UP = 'pi pi-angle-up';\nPrimeIcons.APPLE = 'pi pi-apple';\nPrimeIcons.ARROW_CIRCLE_DOWN = 'pi pi-arrow-circle-down';\nPrimeIcons.ARROW_CIRCLE_LEFT = 'pi pi-arrow-circle-left';\nPrimeIcons.ARROW_CIRCLE_RIGHT = 'pi pi-arrow-circle-right';\nPrimeIcons.ARROW_CIRCLE_UP = 'pi pi-arrow-circle-up';\nPrimeIcons.ARROW_DOWN = 'pi pi-arrow-down';\nPrimeIcons.ARROW_LEFT = 'pi pi-arrow-left';\nPrimeIcons.ARROW_RIGHT = 'pi pi-arrow-right';\nPrimeIcons.ARROW_UP = 'pi pi-arrow-up';\nPrimeIcons.BACKWARD = 'pi pi-backward';\nPrimeIcons.BAN = 'pi pi-ban';\nPrimeIcons.BARS = 'pi pi-bars';\nPrimeIcons.BELL = 'pi pi-bell';\nPrimeIcons.BOOK = 'pi pi-book';\nPrimeIcons.BOOKMARK = 'pi pi-bookmark';\nPrimeIcons.BRIEFCASE = 'pi pi-briefcase';\nPrimeIcons.CALENDAR_MINUS = 'pi pi-calendar-minus';\nPrimeIcons.CALENDAR_PLUS = 'pi pi-calendar-plus';\nPrimeIcons.CALENDAR_TIMES = 'pi pi-calendar-times';\nPrimeIcons.CALENDAR = 'pi pi-calendar';\nPrimeIcons.CAMERA = 'pi pi-camera';\nPrimeIcons.CARET_DOWN = 'pi pi-caret-down';\nPrimeIcons.CARET_LEFT = 'pi pi-caret-left';\nPrimeIcons.CARET_RIGHT = 'pi pi-caret-right';\nPrimeIcons.CARET_UP = 'pi pi-caret-up';\nPrimeIcons.CHART_BAR = 'pi pi-chart-bar';\nPrimeIcons.CHART_LINE = 'pi pi-chart-line';\nPrimeIcons.CHECK_CIRCLE = 'pi pi-check-circle';\nPrimeIcons.CHECK_SQUARE = 'pi pi-check-square';\nPrimeIcons.CHECK = 'pi pi-check';\nPrimeIcons.CHEVRON_CIRCLE_DOWN = 'pi pi-chevron-circle-down';\nPrimeIcons.CHEVRON_CIRCLE_LEFT = 'pi pi-chevron-circle-left';\nPrimeIcons.CHEVRON_CIRCLE_RIGHT = 'pi pi-chevron-circle-right';\nPrimeIcons.CHEVRON_CIRCLE_UP = 'pi pi-chevron-circle-up';\nPrimeIcons.CHEVRON_DOWN = 'pi pi-chevron-down';\nPrimeIcons.CHEVRON_LEFT = 'pi pi-chevron-left';\nPrimeIcons.CHEVRON_RIGHT = 'pi pi-chevron-right';\nPrimeIcons.CHEVRON_UP = 'pi pi-chevron-up';\nPrimeIcons.CLOCK = 'pi pi-clock';\nPrimeIcons.CLONE = 'pi pi-clone';\nPrimeIcons.CLOUD_DOWNLOAD = 'pi pi-cloud-download';\nPrimeIcons.CLOUD_UPLOAD = 'pi pi-cloud-upload';\nPrimeIcons.CLOUD = 'pi pi-cloud';\nPrimeIcons.COG = 'pi pi-cog';\nPrimeIcons.COMMENT = 'pi pi-comment';\nPrimeIcons.COMMENTS = 'pi pi-comments';\nPrimeIcons.COMPASS = 'pi pi-compass';\nPrimeIcons.COPY = 'pi pi-copy';\nPrimeIcons.CREDIT_CARD = 'pi pi-credit-card';\nPrimeIcons.DESKTOP = 'pi pi-desktop';\nPrimeIcons.DISCORD = 'pi pi-discord';\nPrimeIcons.DIRECTIONS_ALT = 'pi pi-directions-alt';\nPrimeIcons.DIRECTIONS = 'pi pi-directions';\nPrimeIcons.DOLLAR = 'pi pi-dollar';\nPrimeIcons.DOWNLOAD = 'pi pi-download';\nPrimeIcons.EJECT = 'pi pi-eject';\nPrimeIcons.ELLIPSIS_H = 'pi pi-ellipsis-h';\nPrimeIcons.ELLIPSIS_V = 'pi pi-ellipsis-v';\nPrimeIcons.ENVELOPE = 'pi pi-envelope';\nPrimeIcons.EXCLAMATION_CIRCLE = 'pi pi-exclamation-circle';\nPrimeIcons.EXCLAMATION_TRIANGLE = 'pi pi-exclamation-triangle ';\nPrimeIcons.EXTERNAL_LINK = 'pi pi-external-link';\nPrimeIcons.EYE_SLASH = 'pi pi-eye-slash';\nPrimeIcons.EYE = 'pi pi-eye';\nPrimeIcons.FACEBOOK = 'pi pi-facebook';\nPrimeIcons.FAST_BACKWARD = 'pi pi-fast-backward';\nPrimeIcons.FAST_FORWARD = 'pi pi-fast-forward';\nPrimeIcons.FILE_EXCEL = 'pi pi-file-excel';\nPrimeIcons.FILE_O = 'pi pi-file-o';\nPrimeIcons.FILE_PDF = 'pi pi-file-pdf';\nPrimeIcons.FILE = 'pi pi-file';\nPrimeIcons.FILTER = 'pi pi-filter';\nPrimeIcons.FILTER_SLASH = 'pi pi-filter-slash';\nPrimeIcons.FLAG = 'pi pi-flag';\nPrimeIcons.FOLDER_OPEN = 'pi pi-folder-open';\nPrimeIcons.FOLDER = 'pi pi-folder';\nPrimeIcons.FORWARD = 'pi pi-forward';\nPrimeIcons.GITHUB = 'pi pi-github';\nPrimeIcons.GLOBE = 'pi pi-globe';\nPrimeIcons.GOOGLE = 'pi pi-google';\nPrimeIcons.HEART = 'pi pi-heart';\nPrimeIcons.HOME = 'pi pi-home';\nPrimeIcons.ID_CARD = 'pi pi-id-card';\nPrimeIcons.IMAGE = 'pi pi-image';\nPrimeIcons.IMAGES = 'pi pi-images';\nPrimeIcons.INBOX = 'pi pi-inbox';\nPrimeIcons.INFO_CIRCLE = 'pi pi-info-circle';\nPrimeIcons.INFO = 'pi pi-info';\nPrimeIcons.KEY = 'pi pi-key';\nPrimeIcons.LINK = 'pi pi-link';\nPrimeIcons.LIST = 'pi pi-list';\nPrimeIcons.LOCK_OPEN = 'pi pi-lock-open';\nPrimeIcons.LOCK = 'pi pi-lock';\nPrimeIcons.MAP = 'pi pi-map';\nPrimeIcons.MAP_MARKER = 'pi pi-map-marker';\nPrimeIcons.MICROSOFT = 'pi pi-microsoft';\nPrimeIcons.MINUS_CIRCLE = 'pi pi-minus-circle';\nPrimeIcons.MINUS = 'pi pi-minus';\nPrimeIcons.MOBILE = 'pi pi-mobile';\nPrimeIcons.MONEY_BILL = 'pi pi-money-bill';\nPrimeIcons.MOON = 'pi pi-moon';\nPrimeIcons.PALETTE = 'pi pi-palette';\nPrimeIcons.PAPERCLIP = 'pi pi-paperclip';\nPrimeIcons.PAUSE = 'pi pi-pause';\nPrimeIcons.PAYPAL = 'pi pi-paypal';\nPrimeIcons.PENCIL = 'pi pi-pencil';\nPrimeIcons.PERCENTAGE = 'pi pi-percentage';\nPrimeIcons.PHONE = 'pi pi-phone';\nPrimeIcons.PLAY = 'pi pi-play';\nPrimeIcons.PLUS_CIRCLE = 'pi pi-plus-circle';\nPrimeIcons.PLUS = 'pi pi-plus';\nPrimeIcons.POWER_OFF = 'pi pi-power-off';\nPrimeIcons.PRINT = 'pi pi-print';\nPrimeIcons.QUESTION_CIRCLE = 'pi pi-question-circle';\nPrimeIcons.QUESTION = 'pi pi-question';\nPrimeIcons.RADIO_OFF = 'pi pi-radio-off';\nPrimeIcons.RADIO_ON = 'pi pi-radio-on';\nPrimeIcons.REFRESH = 'pi pi-refresh';\nPrimeIcons.REPLAY = 'pi pi-replay';\nPrimeIcons.REPLY = 'pi pi-reply';\nPrimeIcons.SAVE = 'pi pi-save';\nPrimeIcons.SEARCH_MINUS = 'pi pi-search-minus';\nPrimeIcons.SEARCH_PLUS = 'pi pi-search-plus';\nPrimeIcons.SEARCH = 'pi pi-search';\nPrimeIcons.SEND = 'pi pi-send';\nPrimeIcons.SHARE_ALT = 'pi pi-share-alt';\nPrimeIcons.SHIELD = 'pi pi-shield';\nPrimeIcons.SHOPPING_CART = 'pi pi-shopping-cart';\nPrimeIcons.SIGN_IN = 'pi pi-sign-in';\nPrimeIcons.SIGN_OUT = 'pi pi-sign-out';\nPrimeIcons.SITEMAP = 'pi pi-sitemap';\nPrimeIcons.SLACK = 'pi pi-slack';\nPrimeIcons.SLIDERS_H = 'pi pi-sliders-h';\nPrimeIcons.SLIDERS_V = 'pi pi-sliders-v';\nPrimeIcons.SORT_ALPHA_ALT_DOWN = 'pi pi-sort-alpha-alt-down';\nPrimeIcons.SORT_ALPHA_ALT_UP = 'pi pi-sort-alpha-alt-up';\nPrimeIcons.SORT_ALPHA_DOWN = 'pi pi-sort-alpha-down';\nPrimeIcons.SORT_ALPHA_UP = 'pi pi-sort-alpha-up';\nPrimeIcons.SORT_ALT = 'pi pi-sort-alt';\nPrimeIcons.SORT_AMOUNT_DOWN_ALT = 'pi pi-sort-amount-down-alt';\nPrimeIcons.SORT_AMOUNT_DOWN = 'pi pi-sort-amount-down';\nPrimeIcons.SORT_AMOUNT_UP_ALT = 'pi pi-sort-amount-up-alt';\nPrimeIcons.SORT_AMOUNT_UP = 'pi pi-sort-amount-up';\nPrimeIcons.SORT_DOWN = 'pi pi-sort-down';\nPrimeIcons.SORT_NUMERIC_ALT_DOWN = 'pi pi-sort-numeric-alt-down';\nPrimeIcons.SORT_NUMERIC_ALT_UP = 'pi pi-sort-numeric-alt-up';\nPrimeIcons.SORT_NUMERIC_DOWN = 'pi pi-sort-numeric-down';\nPrimeIcons.SORT_NUMERIC_UP = 'pi pi-sort-numeric-up';\nPrimeIcons.SORT_UP = 'pi pi-sort-up';\nPrimeIcons.SORT = 'pi pi-sort';\nPrimeIcons.SPINNER = 'pi pi-spinner';\nPrimeIcons.STAR_O = 'pi pi-star-o';\nPrimeIcons.STAR = 'pi pi-star';\nPrimeIcons.STEP_BACKWARD_ALT = 'pi pi-step-backward-alt';\nPrimeIcons.STEP_BACKWARD = 'pi pi-step-backward';\nPrimeIcons.STEP_FORWARD_ALT = 'pi pi-step-forward-alt';\nPrimeIcons.STEP_FORWARD = 'pi pi-step-forward';\nPrimeIcons.SUN = 'pi pi-sun';\nPrimeIcons.TABLE = 'pi pi-table';\nPrimeIcons.TABLET = 'pi pi-tablet';\nPrimeIcons.TAG = 'pi pi-tag';\nPrimeIcons.TAGS = 'pi pi-tags';\nPrimeIcons.TH_LARGE = 'pi pi-th-large';\nPrimeIcons.THUMBS_DOWN = 'pi pi-thumbs-down';\nPrimeIcons.THUMBS_UP = 'pi pi-thumbs-up';\nPrimeIcons.TICKET = 'pi pi-ticket';\nPrimeIcons.TIMES_CIRCLE = 'pi pi-times-circle';\nPrimeIcons.TIMES = 'pi pi-times';\nPrimeIcons.TRASH = 'pi pi-trash';\nPrimeIcons.TWITTER = 'pi pi-twitter';\nPrimeIcons.UNDO = 'pi pi-undo';\nPrimeIcons.UNLOCK = 'pi pi-unlock';\nPrimeIcons.UPLOAD = 'pi pi-upload';\nPrimeIcons.USER_EDIT = 'pi pi-user-edit';\nPrimeIcons.USER_MINUS = 'pi pi-user-minus';\nPrimeIcons.USER_PLUS = 'pi pi-user-plus';\nPrimeIcons.USER = 'pi pi-user';\nPrimeIcons.USERS = 'pi pi-users';\nPrimeIcons.VIDEO = 'pi pi-video';\nPrimeIcons.VIMEO = 'pi pi-vimeo';\nPrimeIcons.VOLUME_DOWN = 'pi pi-volume-down';\nPrimeIcons.VOLUME_OFF = 'pi pi-volume-off';\nPrimeIcons.VOLUME_UP = 'pi pi-volume-up';\nPrimeIcons.YOUTUBE = 'pi pi-youtube';\nPrimeIcons.WALLET = 'pi pi-wallet';\nPrimeIcons.WIFI = 'pi pi-wifi';\nPrimeIcons.WINDOW_MAXIMIZE = 'pi pi-window-maximize';\nPrimeIcons.WINDOW_MINIMIZE = 'pi pi-window-minimize';\n\nclass FilterOperator {\n}\nFilterOperator.AND = 'and';\nFilterOperator.OR = 'or';\n\nclass Header {\n}\nHeader.ɵfac = function Header_Factory(t) { return new (t || Header)(); };\nHeader.ɵcmp = ɵngcc0.ɵɵdefineComponent({ type: Header, selectors: [[\"p-header\"]], ngContentSelectors: _c0, decls: 1, vars: 0, template: function Header_Template(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵprojectionDef();\n ɵngcc0.ɵɵprojection(0);\n } }, encapsulation: 2 });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(Header, [{\n type: Component,\n args: [{\n selector: 'p-header',\n template: ''\n }]\n }], null, null); })();\nclass Footer {\n}\nFooter.ɵfac = function Footer_Factory(t) { return new (t || Footer)(); };\nFooter.ɵcmp = ɵngcc0.ɵɵdefineComponent({ type: Footer, selectors: [[\"p-footer\"]], ngContentSelectors: _c0, decls: 1, vars: 0, template: function Footer_Template(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵprojectionDef();\n ɵngcc0.ɵɵprojection(0);\n } }, encapsulation: 2 });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(Footer, [{\n type: Component,\n args: [{\n selector: 'p-footer',\n template: ''\n }]\n }], null, null); })();\nclass PrimeTemplate {\n constructor(template) {\n this.template = template;\n }\n getType() {\n return this.name;\n }\n}\nPrimeTemplate.ɵfac = function PrimeTemplate_Factory(t) { return new (t || PrimeTemplate)(ɵngcc0.ɵɵdirectiveInject(ɵngcc0.TemplateRef)); };\nPrimeTemplate.ɵdir = ɵngcc0.ɵɵdefineDirective({ type: PrimeTemplate, selectors: [[\"\", \"pTemplate\", \"\"]], inputs: { type: \"type\", name: [\"pTemplate\", \"name\"] } });\nPrimeTemplate.ctorParameters = () => [\n { type: TemplateRef }\n];\nPrimeTemplate.propDecorators = {\n type: [{ type: Input }],\n name: [{ type: Input, args: ['pTemplate',] }]\n};\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(PrimeTemplate, [{\n type: Directive,\n args: [{\n selector: '[pTemplate]',\n host: {}\n }]\n }], function () { return [{ type: ɵngcc0.TemplateRef }]; }, { type: [{\n type: Input\n }], name: [{\n type: Input,\n args: ['pTemplate']\n }] }); })();\nclass SharedModule {\n}\nSharedModule.ɵmod = ɵngcc0.ɵɵdefineNgModule({ type: SharedModule });\nSharedModule.ɵinj = ɵngcc0.ɵɵdefineInjector({ factory: function SharedModule_Factory(t) { return new (t || SharedModule)(); }, imports: [[CommonModule]] });\n(function () { (typeof ngJitMode === \"undefined\" || ngJitMode) && ɵngcc0.ɵɵsetNgModuleScope(SharedModule, { declarations: function () { return [Header, Footer, PrimeTemplate]; }, imports: function () { return [CommonModule]; }, exports: function () { return [Header, Footer, PrimeTemplate]; } }); })();\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(SharedModule, [{\n type: NgModule,\n args: [{\n imports: [CommonModule],\n exports: [Header, Footer, PrimeTemplate],\n declarations: [Header, Footer, PrimeTemplate]\n }]\n }], null, null); })();\n\nclass TreeDragDropService {\n constructor() {\n this.dragStartSource = new Subject();\n this.dragStopSource = new Subject();\n this.dragStart$ = this.dragStartSource.asObservable();\n this.dragStop$ = this.dragStopSource.asObservable();\n }\n startDrag(event) {\n this.dragStartSource.next(event);\n }\n stopDrag(event) {\n this.dragStopSource.next(event);\n }\n}\nTreeDragDropService.ɵfac = function TreeDragDropService_Factory(t) { return new (t || TreeDragDropService)(); };\nTreeDragDropService.ɵprov = ɵngcc0.ɵɵdefineInjectable({ token: TreeDragDropService, factory: TreeDragDropService.ɵfac });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(TreeDragDropService, [{\n type: Injectable\n }], function () { return []; }, null); })();\n\n/**\n * Generated bundle index. Do not edit.\n */\n\nexport { ConfirmationService, ContextMenuService, FilterMatchMode, FilterOperator, FilterService, Footer, Header, MessageService, PrimeIcons, PrimeNGConfig, PrimeTemplate, SharedModule, TranslationKeys, TreeDragDropService };\n\n//# sourceMappingURL=primeng-api.js.map","import { Component, OnInit, ViewChild,Input } from '@angular/core';\r\nimport { Dimensions, ImageCroppedEvent, ImageCropperComponent, ImageTransform } from 'ngx-image-cropper';\r\nimport { base64ToFile } from 'ngx-image-cropper';\r\nimport { DatePipe } from '@angular/common';\r\nimport { FileUploadService } from '../../../shared/upload.service'\r\nimport { AlertService } from 'src/app/shared/components/alert/alert.service';\r\nimport { FormControl, FormGroup, Validators } from '@angular/forms';\r\nimport { ConfirmationService, MessageService } from 'primeng/api';\r\nimport { List } from 'src/app/shared/interface';\r\nimport { NaomitsuService } from 'src/app/shared/databaseService';\r\nimport { Router } from '@angular/router';\r\nimport { DialogService } from 'src/app/shared/dialog.service';\r\nimport { TokenStorageService } from 'src/app/_services/token-storage.service';\r\n//import { formmodule } from 'src/app/interface';\r\nconst MAX_SIZE: number = 1048576;\r\n\r\n@Component({\r\n selector: 'app-uploadphoto',\r\n templateUrl: './cropNuploadphoto.component.html',\r\n styleUrls: ['./cropNuploadphoto.component.scss'],\r\n providers: [FileUploadService, ConfirmationService, MessageService]\r\n})\r\nexport class cropNUploadphotoComponent implements OnInit {\r\n options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n Albums: any[];\r\n formData: FormData;\r\n UploadForm: FormGroup = new FormGroup({});\r\n selectedRatio:string=\"5/2\";\r\n constructor(private datePipe: DatePipe,\r\n private uploadService: FileUploadService,\r\n private alertMessage: AlertService,\r\n private confirmationService: ConfirmationService,\r\n private messageService: MessageService,\r\n private naomitsuService: NaomitsuService,\r\n private route: Router,\r\n private dialog: DialogService,\r\n private tokenStorage: TokenStorageService) {\r\n this.UploadForm = new FormGroup(\r\n {\r\n parentId: new FormControl(0),\r\n UpdatedFileFolderName: new FormControl(''),\r\n description: new FormControl(''),\r\n \r\n });\r\n }\r\n ngOnInit() {\r\n \r\n this.UploadForm.patchValue({\"aspectRatio\":\"4/3\"})\r\n this.Albums = [];\r\n this.checklogin();\r\n this.getAlbums();\r\n }\r\n checklogin() {\r\n let options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n let token = this.tokenStorage.getToken();\r\n\r\n if (token == null) {\r\n this.alertMessage.error(\"Access denied! login required.\", options);\r\n this.route.navigate(['/home']);\r\n }\r\n }\r\n fileName: string;\r\n selectedAlbum: string;\r\n ParentId: number;\r\n imageChangedEvent: any = '';\r\n croppedImage: any = '';\r\n canvasRotation = 0;\r\n rotation = 0;\r\n scale = 1;\r\n showCropper = false;\r\n containWithinAspectRatio = false;\r\n transform: ImageTransform = {};\r\n\r\n @ViewChild(ImageCropperComponent, { static: true }) imageCropper: ImageCropperComponent;\r\n\r\n fileChangeEvent(event: any): void {\r\n if (event === null || event === undefined){\r\n return null\r\n }\r\n this.imageChangedEvent = event;\r\n this.fileName = this.imageChangedEvent.target.files[0].name;\r\n //console.log('this.fileName',this.fileName);\r\n }\r\n\r\n imageCropped(event: ImageCroppedEvent) {\r\n //this.cropper.setAspectRatio(this.aspectRatio);\r\n this.croppedImage = event.base64;\r\n this.formData = new FormData();\r\n this.formData.append(\"Image\", base64ToFile(this.croppedImage), this.fileName);\r\n //this.formData.append(\"album\", this.selectedAlbum);\r\n //this.formData.append(\"description\", this.UploadForm.get(\"Description\").value);\r\n // this.fileName =file.name;\r\n \r\n }\r\n\r\n uploadFile() {\r\n let error: boolean = false;\r\n \r\n //console.log('this.fileName', this.fileName);\r\n this.selectedAlbum = this.UploadForm.get(\"UpdatedFileFolderName\").value;\r\n this.ParentId = this.UploadForm.get(\"parentId\").value;\r\n //this.formData = new FormData();\r\n //this.formData.append(this.fileName,base64ToFile(this.croppedImage),this.fileName);\r\n if (this.selectedAlbum == '' && this.ParentId == 0) {\r\n error = true;\r\n this.alertMessage.error(\"Please enter album or select existing album!\", this.options);\r\n }\r\n else {\r\n if (this.ParentId > 0) {\r\n var existingAlbum = this.Albums.filter(item => item.FileId == this.ParentId)[0].UpdatedFileFolderName;\r\n this.formData.append(\"folderName\", existingAlbum);\r\n }\r\n else\r\n this.formData.append(\"folderName\", this.selectedAlbum);\r\n\r\n this.formData.append(\"parentId\", this.ParentId.toString());\r\n this.formData.append(\"description\", this.UploadForm.get(\"description\").value);\r\n this.formData.append(\"fileOrPhoto\", \"1\");\r\n let filteredAlbum: any[] = [];\r\n if (this.Albums.length > 0) {\r\n filteredAlbum = this.Albums.filter(item => {\r\n return item.UpdatedFileFolderName == this.selectedAlbum\r\n });\r\n }\r\n this.uploadImage();\r\n \r\n }\r\n }\r\n uploadImage() {\r\n let options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n //this.formData.append(\"Image\", base64ToFile(this.croppedImage),this.fileName);\r\n this.uploadService.postFile(this.formData).subscribe(res => {\r\n this.alertMessage.success(\"Files Uploaded successfully.\", options);\r\n this.route.navigate([\"/home/managefile\"]);\r\n });\r\n }\r\n \r\n confirm(event: Event) {\r\n this.confirmationService.confirm({\r\n target: event.target,\r\n message: 'Album already exists! Do you want to add to existing album?',\r\n icon: 'pi pi-exclamation-triangle',\r\n accept: () => {\r\n this.messageService.add({ severity: 'info', summary: 'Confirmed', detail: 'Added to existing album.' });\r\n },\r\n reject: () => {\r\n this.messageService.add({ severity: 'error', summary: 'Rejected', detail: 'Image not added' });\r\n }\r\n });\r\n }\r\n getAlbums() {\r\n let list: List = new List();\r\n list.fields = [\"FileId\", \"UpdatedFileFolderName\"];\r\n list.PageName = \"FilesNPhotoes\";\r\n list.filter = [\"Active eq 1 and FileOrPhoto eq 1 and FileOrFolder eq 1\"];\r\n this.naomitsuService.get(list)\r\n .subscribe((data: any) => {\r\n if (data.value.length > 0) {\r\n this.Albums = data.value;\r\n }\r\n });\r\n }\r\n\r\n imageLoaded() {\r\n this.showCropper = true;\r\n //console.log('Image loaded');\r\n }\r\n\r\n cropperReady(sourceImageDimensions: Dimensions) {\r\n //console.log('Cropper ready', sourceImageDimensions);\r\n }\r\n\r\n loadImageFailed() {\r\n //console.log('Load failed');\r\n }\r\n\r\n rotateLeft() {\r\n this.canvasRotation--;\r\n this.flipAfterRotate();\r\n }\r\n\r\n rotateRight() {\r\n this.canvasRotation++;\r\n this.flipAfterRotate();\r\n }\r\n\r\n private flipAfterRotate() {\r\n const flippedH = this.transform.flipH;\r\n const flippedV = this.transform.flipV;\r\n this.transform = {\r\n ...this.transform,\r\n flipH: flippedV,\r\n flipV: flippedH\r\n };\r\n }\r\n\r\n\r\n flipHorizontal() {\r\n this.transform = {\r\n ...this.transform,\r\n flipH: !this.transform.flipH\r\n };\r\n }\r\n\r\n flipVertical() {\r\n this.transform = {\r\n ...this.transform,\r\n flipV: !this.transform.flipV\r\n };\r\n }\r\n\r\n resetImage() {\r\n this.scale = 1;\r\n this.rotation = 0;\r\n this.canvasRotation = 0;\r\n this.transform = {};\r\n }\r\n\r\n zoomOut() {\r\n this.scale -= .1;\r\n this.transform = {\r\n ...this.transform,\r\n scale: this.scale\r\n };\r\n }\r\n\r\n zoomIn() {\r\n this.scale += .1;\r\n this.transform = {\r\n ...this.transform,\r\n scale: this.scale\r\n };\r\n }\r\n\r\n toggleContainWithinAspectRatio() {\r\n this.containWithinAspectRatio = !this.containWithinAspectRatio;\r\n }\r\n\r\n updateRotation() {\r\n this.transform = {\r\n ...this.transform,\r\n rotate: this.rotation\r\n };\r\n }\r\n\r\n}\r\n\r\n\r\n","\r\n \r\n Crop and Upload Image\r\n \r\n
\r\n
\r\n \r\n Enter album\r\n \r\n \r\n \r\n Existing albums\r\n \r\n {{album.UpdatedFileFolderName}}\r\n \r\n \r\n \r\n Description\r\n \r\n \r\n \r\n   \r\n   \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
","import { Component, ElementRef, OnInit, VERSION } from '@angular/core';\r\nimport { FormControl, FormGroup, Validators } from '@angular/forms';\r\nimport { Router } from '@angular/router';\r\nimport { List } from 'src/app/shared/interface';\r\nimport { AlertService } from 'src/app/shared/components/alert/alert.service';\r\nimport { NaomitsuService } from '../../../shared/databaseService'\r\nimport { globalconstants } from 'src/app/shared/globalconstant';\r\nimport { Subscription } from 'rxjs';\r\nimport { MediaObserver } from '@angular/flex-layout';\r\n\r\n@Component({\r\n selector: 'app-photobrowser',\r\n templateUrl: './photobrowser.component.html',\r\n styleUrls: ['./photobrowser.component.scss']\r\n})\r\nexport class PhotobrowserComponent implements OnInit {\r\n ngVersion: string = VERSION.full;\r\n matVersion: string = '5.1.0';\r\n breakpoint: number;\r\n rowHeight: string;\r\n //searchForm:FormGroup;\r\n folderHierarachy: string;\r\n blueColorScheme = [\"#FCE786\",\r\n \"#EC7235\",\r\n \"#D22D16\",\r\n \"#77BFE2\",\r\n \"#36A1D4\"];\r\n searchForm = new FormGroup({\r\n Album: new FormControl('', [Validators.required, Validators.maxLength(50)]),\r\n year: new FormControl(''),\r\n radioAlbum: new FormControl('')\r\n });\r\n images: any[];\r\n Albums: any[];\r\n AllAlbums: any[];\r\n Photos: any[];\r\n unique: any[];\r\n selectedAlbum: string;\r\n oldvalue: string;\r\n loading = false;\r\n mediaSub: Subscription;\r\n deviceXs: boolean;\r\n\r\n constructor(\r\n private dataservice: NaomitsuService,\r\n private route: Router,\r\n private alert: AlertService,\r\n private el: ElementRef,\r\n private mediaObserver: MediaObserver\r\n ) { }\r\n\r\n ngOnInit() {\r\n this.mediaSub = this.mediaObserver.asObservable().subscribe((result) => {\r\n this.deviceXs = result[0].mqAlias === \"xs\" ? true : false;\r\n });\r\n // this.resize(window.innerWidth);\r\n this.getAlbums();\r\n this.searchForm.controls.radioAlbum.setValue('');\r\n }\r\n changeColor(indx) {\r\n let i = indx % 4;\r\n return this.blueColorScheme[i];\r\n }\r\n view(event) {\r\n //console.log('this.Albums.length',event)\r\n debugger;\r\n this.selectedAlbum = event;\r\n // let selectedAlbumId = this.Albums.filter(item => {\r\n // return item.UpdatedFileFolderName == this.selectedAlbum\r\n // })[0].FileId;\r\n this.route.navigate([\"/home/photocarousel\"], { queryParams: { fileId: event } });\r\n }\r\n applyFilter(strFilter) {\r\n let count = 0;\r\n if (strFilter.length > 2)\r\n this.Albums = [...this.AllAlbums.filter(item => { return item.UpdatedFileFolderName.toLowerCase().includes(strFilter.toLowerCase()) })];\r\n else if (strFilter.length == 0)\r\n this.Albums = this.AllAlbums.filter((item, indx) => indx < 10);\r\n else\r\n return;\r\n }\r\n getAlbums() {\r\n this.loading = true;\r\n let list: List = new List();\r\n list.fields = [\"FileId\", \"FileName\", \"UpdatedFileFolderName\", \"UploadDate\"];\r\n list.PageName = \"FilesNPhotoes\";\r\n list.filter = ['Active eq 1 and FileOrFolder eq 1 and FileOrPhoto eq 1'];\r\n list.orderBy = \"UploadDate desc\";\r\n //list.limitTo =10;\r\n this.dataservice.get(list)\r\n .subscribe((data: any) => {\r\n // console.log(data.value);\r\n this.Albums = data.value.filter((item, indx) => {\r\n return indx < 10;\r\n });\r\n let minId = Math.min.apply(Math, this.Albums.map(o => o.FileId))\r\n //let minId = this.Albums.reduce((a, b.FileId)=>Math.min(a.FileId, b.FileId));\r\n //console.log('this.Albums', this.Albums)\r\n //console.log('minId', minId)\r\n this.getPhotos(minId);\r\n this.AllAlbums = data.value;\r\n this.loading = false;\r\n }, error => console.log(error))\r\n }\r\n getPhotos(minId) {\r\n\r\n let list: List = new List();\r\n list.fields = [\"FileId\", \"FileName\", \"Description\", \"UpdatedFileFolderName\", \"ParentId\"];\r\n //list.lookupFields = [\"Album\"];\r\n list.PageName = \"FilesNPhotoes\";\r\n list.filter = [\"Active eq 1 and FileOrPhoto eq 1 and ParentId ge \" + minId];\r\n list.orderBy = \"UploadDate desc\";\r\n this.loading = true;\r\n this.dataservice.get(list)\r\n .subscribe((data: any) => {\r\n //debugger;\r\n let count = 0;\r\n if (data.value.length > 0) {\r\n var browsePath = '';\r\n var width = '150px';\r\n var cols = 1;\r\n this.Albums.forEach(album => {\r\n album.photos =\r\n data.value.filter(f => {\r\n return f.ParentId == album.FileId\r\n })\r\n });\r\n\r\n this.Albums.forEach((album) => {\r\n count = album.photos.length;\r\n width = count > 1 ? '160px' : '320px';\r\n //console.log('photo count', count);\r\n //console.log('photo width', width);\r\n\r\n album.photos = album.photos.map((photo, indx) => {\r\n browsePath = globalconstants.apiUrl + \"/Image/\" + album.FileName + \"/\" + photo.FileName\r\n\r\n return {\r\n PhotoId: photo.FileId,\r\n PhotoPath: browsePath,\r\n PhotoName: photo.UpdatedFileFolderName,\r\n Description: photo.Description,\r\n Width: width,\r\n Height: width,\r\n PhotoCount: count\r\n }\r\n })\r\n });\r\n //count=0;\r\n\r\n }\r\n\r\n //console.log('album', this.Albums);\r\n this.loading = false;\r\n })\r\n }\r\n\r\n getNestedFolders(fileId) {\r\n let ParentItem = this.Albums.filter(item => item.FileId == fileId);\r\n let fullPath = '';\r\n while (ParentItem.length > 0) {\r\n fullPath += ParentItem[0].FileName + \"/\";\r\n ParentItem = this.Albums.filter(item => item.FileId == ParentItem[0].ParentId)\r\n }\r\n return fullPath;\r\n }\r\n // onResize(event) {\r\n // this.resize(event.target.innerWidth);\r\n // }\r\n\r\n resize() {\r\n if (this.deviceXs) {\r\n this.breakpoint = 1;\r\n this.rowHeight = this.el.nativeElement.offsetWidth + ':' + this.el.nativeElement.offsetHeight / 4;\r\n } else {\r\n this.breakpoint = 4;\r\n this.rowHeight = this.el.nativeElement.offsetWidth / 4 + ':' + this.el.nativeElement.offsetHeight;\r\n }\r\n }\r\n selected(event) {\r\n //console.log('event',event)\r\n this.selectedAlbum = event.target.value;\r\n //console.log('this.selectedAlbum', this.selectedAlbum)\r\n // let tempImages = this.Albums.filter((item)=>{\r\n // return item.Album == this.selectedAlbum\r\n // })\r\n // this.images = tempImages.map(item=> {return item.PhotoPath});\r\n }\r\n getoldvalue(value: string) {\r\n this.oldvalue = value;\r\n //console.log('old value', this.oldvalue);\r\n }\r\n saveCost(value) {\r\n if (value.length == 0 || value.length > 50) {\r\n this.alert.error(\"Character should not be empty or less than 50!\");\r\n return;\r\n }\r\n\r\n let albumtoUpdate = {\r\n UpdatedFileFolderName: value,\r\n Active: 1,\r\n UploadDate: new Date()\r\n }\r\n let selectedAlbumId = this.Albums.filter(item => {\r\n return item.UpdatedFileFolderName == this.oldvalue\r\n })[0].FileId;\r\n //console.log('selectedAlbumId', selectedAlbumId);\r\n this.dataservice.postPatch('FilesNPhotoes', albumtoUpdate, selectedAlbumId, 'patch')\r\n .subscribe(res => {\r\n //console.log(res);\r\n });\r\n }\r\n}\r\n","\r\n Photo Gallery\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n {{album.UpdatedFileFolderName|slice:0:30}}30\">...\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { EventEmitter, Directive, Output, Input, ContentChildren, Component, forwardRef, NgZone, ViewChild, NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\n\n/**\n * CKGroup component\n * Usage :\n * \n * \n * \n * \n */\nimport * as ɵngcc0 from '@angular/core';\n\nconst _c0 = [\"host\"];\nclass CKButtonDirective {\n constructor() {\n this.click = new EventEmitter();\n }\n initialize(editor) {\n editor.instance.addCommand(this.command, {\n exec: (evt) => {\n this.click.emit(evt);\n },\n });\n editor.instance.ui.addButton(this.name, {\n label: this.label,\n command: this.command,\n toolbar: this.toolbar,\n icon: this.icon,\n });\n }\n ngOnInit() {\n if (!this.name)\n throw new Error('Attribute \"name\" is required on ');\n if (!this.command)\n throw new Error('Attribute \"command\" is required on ');\n }\n}\nCKButtonDirective.ɵfac = function CKButtonDirective_Factory(t) { return new (t || CKButtonDirective)(); };\nCKButtonDirective.ɵdir = ɵngcc0.ɵɵdefineDirective({ type: CKButtonDirective, selectors: [[\"ckbutton\"]], inputs: { label: \"label\", command: \"command\", toolbar: \"toolbar\", name: \"name\", icon: \"icon\" }, outputs: { click: \"click\" } });\nCKButtonDirective.propDecorators = {\n click: [{ type: Output }],\n label: [{ type: Input }],\n command: [{ type: Input }],\n toolbar: [{ type: Input }],\n name: [{ type: Input }],\n icon: [{ type: Input }]\n};\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(CKButtonDirective, [{\n type: Directive,\n args: [{\n selector: 'ckbutton'\n }]\n }], function () { return []; }, { click: [{\n type: Output\n }], label: [{\n type: Input\n }], command: [{\n type: Input\n }], toolbar: [{\n type: Input\n }], name: [{\n type: Input\n }], icon: [{\n type: Input\n }] }); })();\n\n/**\n * CKGroup component\n * Usage :\n * \n * \n * .\n * .\n * \n * \n */\nclass CKGroupDirective {\n ngAfterContentInit() {\n // Reconfigure each button's toolbar property within ckgroup to hold its parent's name\n this.toolbarButtons.forEach((button) => (button.toolbar = this.name));\n }\n initialize(editor) {\n editor.instance.ui.addToolbarGroup(this.name, this.previous, this.subgroupOf);\n // Initialize each button within ckgroup\n this.toolbarButtons.forEach((button) => {\n button.initialize(editor);\n });\n }\n}\nCKGroupDirective.ɵfac = function CKGroupDirective_Factory(t) { return new (t || CKGroupDirective)(); };\nCKGroupDirective.ɵdir = ɵngcc0.ɵɵdefineDirective({ type: CKGroupDirective, selectors: [[\"ckgroup\"]], contentQueries: function CKGroupDirective_ContentQueries(rf, ctx, dirIndex) { if (rf & 1) {\n ɵngcc0.ɵɵcontentQuery(dirIndex, CKButtonDirective, false);\n } if (rf & 2) {\n let _t;\n ɵngcc0.ɵɵqueryRefresh(_t = ɵngcc0.ɵɵloadQuery()) && (ctx.toolbarButtons = _t);\n } }, inputs: { name: \"name\", previous: \"previous\", subgroupOf: \"subgroupOf\" } });\nCKGroupDirective.propDecorators = {\n name: [{ type: Input }],\n previous: [{ type: Input }],\n subgroupOf: [{ type: Input }],\n toolbarButtons: [{ type: ContentChildren, args: [CKButtonDirective,] }]\n};\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(CKGroupDirective, [{\n type: Directive,\n args: [{\n selector: 'ckgroup'\n }]\n }], null, { name: [{\n type: Input\n }], previous: [{\n type: Input\n }], subgroupOf: [{\n type: Input\n }], toolbarButtons: [{\n type: ContentChildren,\n args: [CKButtonDirective]\n }] }); })();\n\n// Imports\n/**\n * CKEditor component\n * Usage :\n * \n */\nclass CKEditorComponent {\n /**\n * Constructor\n */\n constructor(zone) {\n this.zone = zone;\n this.change = new EventEmitter();\n this.editorChange = new EventEmitter();\n this.ready = new EventEmitter();\n this.blur = new EventEmitter();\n this.focus = new EventEmitter();\n this.contentDom = new EventEmitter();\n this.fileUploadRequest = new EventEmitter();\n this.fileUploadResponse = new EventEmitter();\n this.paste = new EventEmitter();\n this.drop = new EventEmitter();\n this._value = '';\n }\n get value() {\n return this._value;\n }\n set value(v) {\n if (v !== this._value) {\n this._value = v;\n this.onChange(v);\n }\n }\n ngOnChanges(changes) {\n if (changes.readonly && this.instance) {\n this.instance.setReadOnly(changes.readonly.currentValue);\n }\n }\n /**\n * On component destroy\n */\n ngOnDestroy() {\n if (this.instance) {\n this.instance.removeAllListeners();\n CKEDITOR.instances[this.instance.name].destroy();\n this.instance.destroy();\n this.instance = null;\n }\n }\n /**\n * On component view init\n */\n ngAfterViewInit() {\n this.ckeditorInit(this.config || {});\n }\n /**\n * On component view checked\n */\n ngAfterViewChecked() {\n this.ckeditorInit(this.config || {});\n }\n /**\n * Value update process\n */\n updateValue(value) {\n this.zone.run(() => {\n this.value = value;\n this.onChange(value);\n this.onTouched();\n this.change.emit(value);\n });\n }\n /**\n * CKEditor init\n */\n ckeditorInit(config) {\n if (typeof CKEDITOR === 'undefined') {\n console.warn('CKEditor 4.x is missing (http://ckeditor.com/)');\n }\n else {\n // Check textarea exists\n if (this.instance || !this.documentContains(this.host.nativeElement)) {\n return;\n }\n if (this.readonly) {\n config.readOnly = this.readonly;\n }\n // CKEditor replace textarea\n this.instance = CKEDITOR.replace(this.host.nativeElement, config);\n // Set initial value\n this.instance.setData(this.value);\n // listen for instanceReady event\n this.instance.on('instanceReady', (evt) => {\n // if value has changed while instance loading\n // update instance with current component value\n if (this.instance.getData() !== this.value) {\n this.instance.setData(this.value);\n }\n // send the evt to the EventEmitter\n this.ready.emit(evt);\n });\n // CKEditor change event\n this.instance.on('change', (evt) => {\n this.onTouched();\n let value = this.instance.getData();\n if (this.value !== value) {\n // Debounce update\n if (this.debounce) {\n if (this.debounceTimeout)\n clearTimeout(this.debounceTimeout);\n this.debounceTimeout = setTimeout(() => {\n this.updateValue(value);\n this.debounceTimeout = null;\n }, parseInt(this.debounce));\n // Live update\n }\n else {\n this.updateValue(value);\n }\n }\n // Original ckeditor event dispatch\n this.editorChange.emit(evt);\n });\n // CKEditor blur event\n this.instance.on('blur', (evt) => {\n this.blur.emit(evt);\n });\n // CKEditor focus event\n this.instance.on('focus', (evt) => {\n this.focus.emit(evt);\n });\n // CKEditor contentDom event\n this.instance.on('contentDom', (evt) => {\n this.contentDom.emit(evt);\n });\n // CKEditor fileUploadRequest event\n this.instance.on('fileUploadRequest', (evt) => {\n this.fileUploadRequest.emit(evt);\n });\n // CKEditor fileUploadResponse event\n this.instance.on('fileUploadResponse', (evt) => {\n this.fileUploadResponse.emit(evt);\n });\n // CKEditor paste event\n this.instance.on('paste', (evt) => {\n this.paste.emit(evt);\n });\n // CKEditor drop event\n this.instance.on('drop', (evt) => {\n this.drop.emit(evt);\n });\n // Add Toolbar Groups to Editor. This will also add Buttons within groups.\n this.toolbarGroups.forEach((group) => {\n group.initialize(this);\n });\n // Add Toolbar Buttons to Editor.\n this.toolbarButtons.forEach((button) => {\n button.initialize(this);\n });\n }\n }\n /**\n * Implements ControlValueAccessor\n */\n writeValue(value) {\n this._value = value;\n if (this.instance)\n this.instance.setData(value);\n }\n onChange(_) { }\n onTouched() { }\n registerOnChange(fn) {\n this.onChange = fn;\n }\n registerOnTouched(fn) {\n this.onTouched = fn;\n }\n documentContains(node) {\n return document.contains ? document.contains(node) : document.body.contains(node);\n }\n}\nCKEditorComponent.ɵfac = function CKEditorComponent_Factory(t) { return new (t || CKEditorComponent)(ɵngcc0.ɵɵdirectiveInject(ɵngcc0.NgZone)); };\nCKEditorComponent.ɵcmp = ɵngcc0.ɵɵdefineComponent({ type: CKEditorComponent, selectors: [[\"ckeditor\"]], contentQueries: function CKEditorComponent_ContentQueries(rf, ctx, dirIndex) { if (rf & 1) {\n ɵngcc0.ɵɵcontentQuery(dirIndex, CKButtonDirective, false);\n ɵngcc0.ɵɵcontentQuery(dirIndex, CKGroupDirective, false);\n } if (rf & 2) {\n let _t;\n ɵngcc0.ɵɵqueryRefresh(_t = ɵngcc0.ɵɵloadQuery()) && (ctx.toolbarButtons = _t);\n ɵngcc0.ɵɵqueryRefresh(_t = ɵngcc0.ɵɵloadQuery()) && (ctx.toolbarGroups = _t);\n } }, viewQuery: function CKEditorComponent_Query(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵviewQuery(_c0, true);\n } if (rf & 2) {\n let _t;\n ɵngcc0.ɵɵqueryRefresh(_t = ɵngcc0.ɵɵloadQuery()) && (ctx.host = _t.first);\n } }, inputs: { value: \"value\", config: \"config\", readonly: \"readonly\", debounce: \"debounce\" }, outputs: { change: \"change\", editorChange: \"editorChange\", ready: \"ready\", blur: \"blur\", focus: \"focus\", contentDom: \"contentDom\", fileUploadRequest: \"fileUploadRequest\", fileUploadResponse: \"fileUploadResponse\", paste: \"paste\", drop: \"drop\" }, features: [ɵngcc0.ɵɵProvidersFeature([\n {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => CKEditorComponent),\n multi: true\n },\n ]), ɵngcc0.ɵɵNgOnChangesFeature], decls: 2, vars: 0, consts: [[\"host\", \"\"]], template: function CKEditorComponent_Template(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵelement(0, \"textarea\", null, 0);\n } }, encapsulation: 2 });\nCKEditorComponent.ctorParameters = () => [\n { type: NgZone }\n];\nCKEditorComponent.propDecorators = {\n config: [{ type: Input }],\n readonly: [{ type: Input }],\n debounce: [{ type: Input }],\n change: [{ type: Output }],\n editorChange: [{ type: Output }],\n ready: [{ type: Output }],\n blur: [{ type: Output }],\n focus: [{ type: Output }],\n contentDom: [{ type: Output }],\n fileUploadRequest: [{ type: Output }],\n fileUploadResponse: [{ type: Output }],\n paste: [{ type: Output }],\n drop: [{ type: Output }],\n host: [{ type: ViewChild, args: ['host', { static: false },] }],\n toolbarButtons: [{ type: ContentChildren, args: [CKButtonDirective,] }],\n toolbarGroups: [{ type: ContentChildren, args: [CKGroupDirective,] }],\n value: [{ type: Input }]\n};\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(CKEditorComponent, [{\n type: Component,\n args: [{\n selector: 'ckeditor',\n providers: [\n {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => CKEditorComponent),\n multi: true\n },\n ],\n template: ``\n }]\n }], function () { return [{ type: ɵngcc0.NgZone }]; }, { change: [{\n type: Output\n }], editorChange: [{\n type: Output\n }], ready: [{\n type: Output\n }], blur: [{\n type: Output\n }], focus: [{\n type: Output\n }], contentDom: [{\n type: Output\n }], fileUploadRequest: [{\n type: Output\n }], fileUploadResponse: [{\n type: Output\n }], paste: [{\n type: Output\n }], drop: [{\n type: Output\n }], value: [{\n type: Input\n }], config: [{\n type: Input\n }], readonly: [{\n type: Input\n }], debounce: [{\n type: Input\n }], host: [{\n type: ViewChild,\n args: ['host', { static: false }]\n }], toolbarButtons: [{\n type: ContentChildren,\n args: [CKButtonDirective]\n }], toolbarGroups: [{\n type: ContentChildren,\n args: [CKGroupDirective]\n }] }); })();\n\n/**\n * CKEditorModule\n */\nclass CKEditorModule {\n}\nCKEditorModule.ɵmod = ɵngcc0.ɵɵdefineNgModule({ type: CKEditorModule });\nCKEditorModule.ɵinj = ɵngcc0.ɵɵdefineInjector({ factory: function CKEditorModule_Factory(t) { return new (t || CKEditorModule)(); }, imports: [[CommonModule]] });\n(function () { (typeof ngJitMode === \"undefined\" || ngJitMode) && ɵngcc0.ɵɵsetNgModuleScope(CKEditorModule, { declarations: function () { return [CKEditorComponent, CKButtonDirective, CKGroupDirective]; }, imports: function () { return [CommonModule]; }, exports: function () { return [CKEditorComponent, CKButtonDirective, CKGroupDirective]; } }); })();\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(CKEditorModule, [{\n type: NgModule,\n args: [{\n imports: [CommonModule],\n declarations: [CKEditorComponent, CKButtonDirective, CKGroupDirective],\n exports: [CKEditorComponent, CKButtonDirective, CKGroupDirective]\n }]\n }], null, null); })();\n\n/**\n * Generated bundle index. Do not edit.\n */\n\nexport { CKEditorModule, CKEditorComponent as ɵa, CKButtonDirective as ɵb, CKGroupDirective as ɵc };\n\n//# sourceMappingURL=ng2-ckeditor.js.map","","import { Component, OnInit, ViewChild, ElementRef } from '@angular/core';\r\nimport { FormGroup, FormBuilder, Validators, NgForm, FormControl } from '@angular/forms';\r\nimport { Router, ActivatedRoute } from '@angular/router';\r\nimport { NaomitsuService } from '../../../shared/databaseService';\r\nimport { List, IPage } from 'src/app/shared/interface';\r\nimport { SharedataService } from '../../../shared/sharedata.service';\r\nimport { AlertService } from 'src/app/shared/components/alert/alert.service';\r\nimport { TokenStorageService } from 'src/app/_services/token-storage.service';\r\nimport { FileUploadService } from 'src/app/shared/upload.service';\r\nimport { globalconstants } from 'src/app/shared/globalconstant';\r\n//import { FormsModule} from '@angular/forms';\r\n@Component({\r\n\r\n selector: 'app-text-editor',\r\n\r\n templateUrl: './texteditor.component.html',\r\n\r\n styleUrls: ['./texteditor.component.scss']\r\n\r\n})\r\n\r\nexport class TextEditorComponent implements OnInit {\r\n OneMB =1048576;\r\n processing =false;\r\n Edit = false;\r\n imageCount=0;\r\n message: string;\r\n imgURL: any='';\r\n selectedFile: any;\r\n //Albums: any;\r\n errorMessage = '';\r\n formdata: FormData;\r\n options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n PageDetail = {\r\n PageId: 0,\r\n PageTitle: '',\r\n ParentId: 0,\r\n FullPath: '',\r\n PhotoPath:'',\r\n CurrentVersion: 0,\r\n UpdateDate: new Date(),\r\n IsTemplate: 1,\r\n HasSubmenu: 1,\r\n Module: 1,\r\n label: '',\r\n link: '',\r\n Active: 1\r\n };\r\n PublishOrDraft: number = 0;\r\n PageDetailForm = this.fb.group({\r\n PhotoPath:[''],\r\n PageTitle: ['',[Validators.required, Validators.maxLength(50)]],\r\n ParentId: [0],\r\n PageBody: [''],\r\n PageHistoryId: [0],\r\n Published: [0],\r\n HasSubmenu: [false],\r\n PageId: [0],\r\n link: [''],\r\n });\r\n PageHistory = {\r\n PageHistoryId: 0,\r\n PageBody: '',\r\n Version: 0,\r\n ParentPageId: 0,\r\n Published: 0,\r\n UpdateDate: new Date(),\r\n CreatedDate: new Date()\r\n }\r\n selected: number = 0;\r\n PageGroups: any;\r\n Id: number = 0;\r\n PageHistoryId: number = 0;\r\n name = 'ng2-ckeditor';\r\n ckeConfig: any;\r\n mycontent: string = '';\r\n log: string = ''\r\n res: any;\r\n loading = false;\r\n constructor(\r\n private fb:FormBuilder,\r\n private naomitsuService: NaomitsuService,\r\n private router: Router,\r\n private ar: ActivatedRoute,\r\n private shareddata: SharedataService,\r\n protected alert: AlertService,\r\n private tokenStorage: TokenStorageService,\r\n private fileUploadService: FileUploadService,) {\r\n //this.PageDetail =[];\r\n }\r\n\r\n get f() { return this.PageDetailForm.controls; }\r\n\r\n ngOnInit() {\r\n this.loading = true;\r\n this.checklogin();\r\n this.GetParentPage();\r\n debugger;\r\n this.ar.queryParamMap\r\n .subscribe((params) => {\r\n this.Id = this.ar.snapshot.params.id;\r\n\r\n if (this.Id != undefined) {\r\n this.GetLatestPage(this.Id);\r\n }\r\n else\r\n {\r\n this.loading =false;\r\n }\r\n \r\n this.ckeConfig = {\r\n allowedContent: false,\r\n extraPlugins: 'divarea',\r\n forcePasteAsPlainText: false,\r\n removeButtons: 'About',\r\n scayt_autoStartup: true,\r\n autoGrow_onStartup: true,\r\n autoGrow_minHeight: 500,\r\n autoGrow_maxHeight: 600\r\n };\r\n \r\n });\r\n }\r\n ngAfterViewInit() {\r\n //this.loading = false;\r\n }\r\n preview(files) {\r\n if (files.length === 0)\r\n return;\r\n\r\n var mimeType = files[0].type;\r\n if (mimeType.match(/image\\/*/) == null) {\r\n this.message = \"Only images are supported.\";\r\n return;\r\n }\r\n this.selectedFile = files[0];\r\n console.log('image size',this.selectedFile.size);\r\n \r\n if(this.selectedFile.size > this.OneMB)\r\n {\r\n this.alert.error('Image size is too big! Please try to upload image size less than 1mb');\r\n return;\r\n }\r\n\r\n this.selectedFile.size\r\n var reader = new FileReader();\r\n this.imageCount = files.length;\r\n reader.readAsDataURL(files[0]);\r\n reader.onload = (_event) => {\r\n this.imgURL = reader.result;\r\n }\r\n }\r\n edit() {\r\n this.Edit = true;\r\n }\r\n delete() {\r\n let pageData ={\r\n UpdateDate:new Date(),\r\n PhotoPath:\"\"\r\n }\r\n this.processing =true;\r\n this.naomitsuService.postPatch('Pages', pageData, this.Id, 'patch')\r\n .subscribe(\r\n (data: any) => {\r\n this.imgURL =\"\";\r\n this.alert.success(\"Photo deleted successfully.\",this.options);\r\n this.processing=false;\r\n });\r\n }\r\n uploadFile() {\r\n let error: boolean = false;\r\n this.processing =true;\r\n this.formdata = new FormData();\r\n this.formdata.append(\"description\", \"Page photo\");\r\n this.formdata.append(\"fileOrPhoto\", \"0\");\r\n this.formdata.append(\"folderName\", \"PagePhoto\");\r\n this.formdata.append(\"parentId\", \"-1\");\r\n\r\n if (this.Id != null || this.Id != 0)\r\n this.formdata.append(\"PageId\", this.Id.toString());\r\n this.formdata.append(\"image\", this.selectedFile, this.selectedFile.name);\r\n this.uploadImage();\r\n }\r\n\r\n uploadImage() {\r\n let options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n //this.formData.append(\"Image\", base64ToFile(this.croppedImage),this.fileName);\r\n this.fileUploadService.postFile(this.formdata).subscribe(res => {\r\n //let filename = this.selectedFile.name.substring(0,10).replace(' ','-').\r\n this.PageDetailForm.patchValue({\"PhotoPath\": res});\r\n //console.log('res',res);\r\n this.alert.success(\"Files Uploaded successfully.\", options);\r\n this.imageCount =0;\r\n this.Edit = false;\r\n this.processing =false; \r\n });\r\n }\r\n\r\n dashboard() {\r\n this.router.navigate(['/home/pages']);\r\n }\r\n\r\n GetLatestPage(ppId: number) {\r\n\r\n let list: List = new List();\r\n list.fields = [\"PageHistoryId\", \"PageBody\", \"Version\", \r\n \"Published\", \"Page/PhotoPath\", \r\n \"Page/HasSubmenu\", \"Page/PageTitle\",\r\n \"Page/link\",];\r\n list.PageName = \"PageHistories\";\r\n list.lookupFields = [\"Page\"];\r\n list.filter = [\"ParentPageId eq \" + ppId];\r\n list.orderBy = \"PageHistoryId desc\";\r\n list.limitTo = 1;\r\n this.naomitsuService.get(list)\r\n .subscribe((data: any) => {\r\n debugger;\r\n if (data.value.length > 0) {\r\n if (data.value[0].Page.PhotoPath == null || data.value[0].Page.PhotoPath == \"\")\r\n this.imgURL = \"\";\r\n else\r\n this.imgURL = globalconstants.apiUrl + \"/Image/PagePhoto/\" + data.value[0].Page.PhotoPath\r\n\r\n this.PageDetailForm.patchValue({\r\n PhotoPath:data.value[0].Page.PhotoPath,\r\n PageTitle: data.value[0].Page.PageTitle,\r\n ParentId: +this.ar.snapshot.queryParams.pgid,\r\n PageBody: data.value[0].PageBody,\r\n PageHistoryId: data.value[0].PageHistoryId,\r\n Version: data.value[0].Version,\r\n Published: data.value[0].Published,\r\n HasSubmenu: data.value[0].Page.HasSubmenu,\r\n link: data.value[0].Page.link,\r\n PageId: ppId\r\n });\r\n //this.selected = this.ar.snapshot.queryParams.pgid; \r\n //this.PageDetailForm.controls.PageGroupId.patchValue(this.ar.snapshot.queryParams.pgid);\r\n }\r\n this.loading=false;\r\n });\r\n }\r\n checklogin() {\r\n let options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n let token = this.tokenStorage.getToken();\r\n\r\n if (token == null) {\r\n this.alert.error(\"Access denied! login required.\", options);\r\n this.router.navigate(['/home']);\r\n }\r\n }\r\n onSaveAsDraft() {\r\n this.PublishOrDraft = 0;\r\n this.loading = true;\r\n this.onSave();\r\n }\r\n onSubmit() {\r\n this.PublishOrDraft = 1;\r\n this.onSave();\r\n }\r\n onSave() {\r\n debugger;\r\n //console.log('to update', this.PageDetailForm.value)\r\n if (this.Id == undefined) {\r\n this.insert();\r\n }\r\n else {\r\n //if save as draft is clicked & the latest is published.\r\n if (this.PageDetailForm.get(\"Published\").value == 1 && this.PublishOrDraft == 0)\r\n this.insert();\r\n else\r\n this.Update();\r\n }\r\n }\r\n insert() {\r\n let active = 1;\r\n let duplicate = [];\r\n if (this.Id == undefined) {\r\n duplicate = this.PageGroups.filter(ele => {\r\n return ele.ParentId == this.PageDetailForm.value.ParentId\r\n && ele.PageTitle == this.PageDetailForm.value.PageTitle\r\n })\r\n if (this.PublishOrDraft == 0)\r\n active = 0;\r\n }\r\n if (duplicate.length > 0) {\r\n this.alert.error('There is already a page named ' + this.PageDetailForm.value.PageTitle, this.options);\r\n }\r\n else {\r\n let PageTitle = this.PageDetailForm.get(\"PageTitle\").value;\r\n this.PageDetail.PageTitle = PageTitle;// .get(\"PageTitle\").value;\r\n this.PageDetail.label = PageTitle;\r\n this.PageDetail.link = this.PageDetailForm.get(\"link\").value;\r\n this.PageDetail.ParentId = this.PageDetailForm.get(\"ParentId\").value;\r\n this.PageDetail.FullPath = this.PageDetailForm.get(\"ParentId\").value == 0 ? PageTitle : this.PageGroups.filter(g => g.PageId == this.PageDetailForm.get(\"ParentId\").value)[0].FullPath + ' > ' + PageTitle;\r\n this.PageDetail.Active = active;\r\n this.PageDetail.CurrentVersion = 1;\r\n this.PageDetail.UpdateDate = new Date();\r\n this.PageDetail.PhotoPath = this.PageDetailForm.get(\"PhotoPath\").value;\r\n this.PageDetail.HasSubmenu = this.PageDetailForm.get(\"HasSubmenu\").value == true ? 1 : 0;\r\n let mode: 'patch' | 'post' = 'post';\r\n\r\n //if save as draft the Pages should be updated but histories to be inserted.\r\n if (this.Id != undefined) {\r\n mode = 'patch'\r\n this.PageDetail.PageId = this.Id;\r\n }\r\n else {\r\n mode = 'post';\r\n this.PageDetail.PageId = 0;\r\n }\r\n this.naomitsuService.postPatch('Pages', this.PageDetail, this.PageDetail.PageId, mode)\r\n .subscribe(\r\n (page: any) => {\r\n let pageId = page == null ? this.PageDetail.PageId : page.PageId;\r\n\r\n this.PageHistory.PageHistoryId = this.PageDetailForm.get(\"PageHistoryId\").value;\r\n this.PageHistory.PageBody = this.PageDetailForm.get(\"PageBody\").value;\r\n this.PageHistory.CreatedDate = new Date();\r\n this.PageHistory.UpdateDate = new Date();\r\n this.PageHistory.Published = this.PublishOrDraft;\r\n this.PageHistory.Version = 1;\r\n this.PageHistory.ParentPageId = pageId;\r\n this.naomitsuService.postPatch('PageHistories', this.PageHistory, 0, 'post')\r\n .subscribe(\r\n (history: any) => {\r\n this.alert.success(\"Data saved successfully\", this.options);\r\n debugger;\r\n if (this.PublishOrDraft == 1) {\r\n if (this.PageDetailForm.value.PageTitle.toUpperCase().includes(\"NEWS\"))\r\n this.PageDetail.link = '/home/about/' + this.Id + \"/\" + pageId;\r\n else\r\n this.PageDetail.link = '/home/display/' + history.PageHistoryId + \"/\" + pageId;\r\n\r\n delete this.PageDetail.PageId;\r\n this.naomitsuService.postPatch('Pages', this.PageDetail, pageId, 'patch')\r\n .subscribe(\r\n (data: any) => {\r\n this.loading = false;\r\n }, (error) => {\r\n this.loading = false;\r\n console.log(error);\r\n })\r\n }\r\n this.router.navigate(['/home/pages']);\r\n }, (error) => {\r\n console.log('update histories', error);\r\n });\r\n },\r\n (error) => {\r\n console.log('update pages', error);\r\n });\r\n }\r\n }\r\n Update() {\r\n let duplicate = this.PageGroups.filter(ele => {\r\n return ele.ParentId == this.PageDetailForm.value.ParentId\r\n && ele.PageTitle == this.PageDetailForm.value.PageTitle\r\n && ele.PageId != this.Id\r\n\r\n })\r\n if (duplicate.length > 0) {\r\n this.alert.error('There is already a page named ' + this.PageDetailForm.value.PageTitle, this.options);\r\n }\r\n else {\r\n this.PageDetailForm.patchValue(\r\n {\r\n PageLeft: \"\",\r\n PageRight: \"\",\r\n PageFooter: \"\",\r\n Published: this.PublishOrDraft\r\n });\r\n\r\n this.PageDetail.PageTitle = this.PageDetailForm.value.PageTitle;// .get(\"PageTitle\").value;\r\n this.PageDetail.label = this.PageDetailForm.value.PageTitle;\r\n debugger;\r\n this.PageDetail.HasSubmenu = this.PageDetailForm.value.HasSubmenu == true ? 1 : 0;\r\n\r\n ///if it has no sub menu, link has to be defined only when it is published.\r\n if (this.PublishOrDraft == 1) {\r\n if (this.PageDetailForm.value.PageTitle.toUpperCase().includes(\"NEWS\"))\r\n this.PageDetail.link = '/home/about/' + this.Id + \"/\" + this.Id;\r\n else\r\n this.PageDetail.link = '/home/display/' + this.PageDetailForm.get(\"PageHistoryId\").value + \"/\" + this.Id;\r\n }\r\n else\r\n this.PageDetail.link = this.PageDetailForm.value.link;\r\n //console.log('this.PageDetailForm.value.ParentId', this.PageDetailForm.value.ParentId);\r\n let FullPath = '';\r\n if (this.PageDetailForm.value.ParentId == 0)\r\n FullPath = this.PageDetailForm.value.PageTitle;\r\n else\r\n FullPath = this.PageGroups.filter(g => g.PageId == this.PageDetailForm.value.ParentId)[0].FullPath + ' > ' + this.PageDetailForm.value.PageTitle;\r\n\r\n this.PageDetail.ParentId = this.PageDetailForm.value.ParentId;//\").value;\r\n this.PageDetail.FullPath = FullPath;\r\n this.PageDetail.PhotoPath = this.PageDetailForm.get(\"PhotoPath\").value;\r\n this.PageDetail.Active = 1;\r\n this.PageDetail.CurrentVersion = this.PageHistory.Version + 1;\r\n this.PageDetail.UpdateDate = new Date();\r\n delete this.PageDetail.PageId;\r\n this.naomitsuService.postPatch('Pages', this.PageDetail, this.Id, 'patch')\r\n .subscribe(\r\n (data: any) => {\r\n this.PageHistory.PageHistoryId = this.PageDetailForm.get(\"PageHistoryId\").value;\r\n this.PageHistory.PageBody = this.PageDetailForm.get(\"PageBody\").value;\r\n this.PageHistory.CreatedDate = new Date();\r\n this.PageHistory.UpdateDate = new Date();\r\n this.PageHistory.Published = this.PublishOrDraft;\r\n this.PageHistory.Version = this.PageHistory.Version + 1;\r\n this.PageHistory.ParentPageId = this.Id;\r\n\r\n this.naomitsuService.postPatch('PageHistories', this.PageHistory, this.PageHistory.PageHistoryId, 'patch')\r\n .subscribe(\r\n (data: any) => {\r\n this.loading = false;\r\n this.alert.success(\"Data updated Successfully\", this.options);\r\n this.router.navigate(['/home/pages']);\r\n });\r\n });\r\n }\r\n }\r\n GetParentPage() {\r\n let list: List = new List();\r\n list.fields = [\"PageId\", \"PageTitle\", \"ParentId\", \"link\", \"FullPath\"];\r\n list.PageName = \"Pages\";\r\n list.filter = [\"Active eq 1\"];\r\n list.orderBy = \"ParentId\";\r\n\r\n this.naomitsuService.get(list)\r\n .subscribe((data: any) => {\r\n this.PageGroups = data.value;\r\n //console.log(this.PageGroups);\r\n });\r\n\r\n }\r\n\r\n}","\r\n Define Page\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n Enter Title\r\n \r\n Title\r\n is required.\r\n \r\n
\r\n
\r\n \r\n Select parent\r\n \r\n ---\r\n {{p.PageTitle}}\r\n \r\n \r\n
\r\n
\r\n \r\n   Has Submenu   \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
0\">\r\n Photo \r\n
\r\n {{message}}\r\n \r\n \r\n\r\n
\r\n
\r\n \r\n \r\n   \r\n   \r\n\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
","import { Component, OnInit } from '@angular/core';\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport { MatTableDataSource } from '@angular/material/table';\r\nimport { ViewChild } from '@angular/core';\r\nimport { MatPaginator } from '@angular/material/paginator';\r\nimport { MatSort } from '@angular/material/sort';\r\nimport { IPage, List } from '../../../shared/interface';\r\nimport { NaomitsuService } from '../../../shared/databaseService';\r\n//import { SharedataService } from '../../../shared/sharedata.service';\r\nimport { SelectionModel } from '@angular/cdk/collections';\r\nimport { TokenStorageService } from 'src/app/_services/token-storage.service';\r\nimport { AlertService } from 'src/app/shared/components/alert/alert.service';\r\nimport { ConfirmationService, MessageService } from 'primeng/api';\r\nimport { DialogService } from 'src/app/shared/dialog.service';\r\n\r\n@Component({\r\n selector: 'app-pagecontent',\r\n templateUrl: './pageDashboard.component.html',\r\n styleUrls: ['./pageDashboard.component.scss'],\r\n providers: [ConfirmationService, MessageService]\r\n})\r\nexport class pageDashboardComponent implements OnInit {\r\n options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n\r\n ParentPages: [{ PageId, PageTitle }];\r\n PageDetail: IPage;\r\n //SelectedData:PageDetail[] = [];\r\n DATA: IPage[] = [];\r\n loading = false;\r\n columns: Array;\r\n title: string;\r\n Id: number;\r\n query: string;//displayedColumns: Array;\r\n list: List;\r\n\r\n displayedColumns = [];// ['id', 'name', 'progress', 'color'];\r\n dataSource: MatTableDataSource;\r\n\r\n @ViewChild(MatPaginator) paginator: MatPaginator;\r\n @ViewChild(MatSort) sort: MatSort;\r\n\r\n selection = new SelectionModel(true, []);\r\n\r\n ngOnInit() {\r\n this.checklogin();\r\n this.route.paramMap.subscribe(params => {\r\n this.Id = +params.get(\"parentid\");\r\n })\r\n this.GetParentPage(this.Id);\r\n }\r\n getDetails(parentId) {\r\n debugger;\r\n this.list.fields = [\"PageId\", \"PageTitle\", \"ParentId\", \"PageHistories/PageHistoryId\", \"PageHistories/Published\", \"PageHistories/Version\", \"Active\"];\r\n this.list.PageName = \"Pages\";\r\n this.list.lookupFields = [\"PageHistories\"];\r\n this.list.filter = ['Active eq 1 and Module eq 1 and IsTemplate eq 1' + (parentId == 0 ? '' : \" and ParentId eq \" + parentId)];\r\n this.list.orderBy = \"PageId desc\";\r\n const columns = [\"PageId\", \"PageTitle\", \"ParentPage\", \"ParentId\", \"Published\", \"Action\"];\r\n\r\n this.naomitsuService\r\n .get(this.list)\r\n .subscribe({\r\n next: (arrPage: IPage[]) => {\r\n //console.log('arrpage', arrPage);\r\n this.DATA=[];\r\n let arr = [];\r\n Object.keys(arrPage).map(function (key) {\r\n arr.push({ [key]: arrPage[key] })\r\n return arr;\r\n });\r\n\r\n arr[1].value.forEach((ele, key) => {\r\n\r\n let pPage = this.ParentPages.filter(page => { return page.PageId === ele.ParentId });\r\n this.DATA.push({\r\n PageId: ele.PageId,\r\n PageTitle: ele.PageTitle,\r\n ParentId: ele.ParentId,\r\n ParentPage: pPage.length > 0 ? pPage[0].PageTitle : '',\r\n Active: ele.Active,\r\n Published: this.getmax(ele.PageHistories),\r\n Action: \"\"\r\n })\r\n });\r\n debugger;\r\n this.columns = columns.map(column => {\r\n return {\r\n columnDef: column,\r\n header: column,\r\n cell: (element: any) => `${element[column] ? element[column] : ``}`\r\n };\r\n });\r\n let SelectedArr = [];\r\n SelectedArr = this.DATA.filter(key => key.Active === 1)\r\n\r\n\r\n this.displayedColumns = this.columns.map(c => c.columnDef);\r\n this.dataSource = new MatTableDataSource(this.DATA);//.sort((n1,n2)=>n1.Published-n2.Published));\r\n this.dataSource.paginator = this.paginator;\r\n this.dataSource.sort = this.sort;\r\n this.selection = new SelectionModel(true, SelectedArr);\r\n // });\r\n },\r\n error: console.error\r\n });\r\n this.loading = false;\r\n }\r\n constructor(private naomitsuService: NaomitsuService,\r\n private navigate: Router,\r\n private route: ActivatedRoute,\r\n //private shareddata: SharedataService,\r\n private tokenStorage: TokenStorageService,\r\n private alert: AlertService,\r\n private dialog: DialogService,\r\n private messageService: MessageService) {\r\n this.list = new List();\r\n }\r\n getmax(pageHistory): number {\r\n let phid = 0;\r\n if (pageHistory.length > 1) {\r\n phid = pageHistory.filter(item => {\r\n return item.PageHistoryId == pageHistory.reduce((prev, current) => (prev.PageHistoryId > current.PageHistoryId) ? prev.PageHistoryId : current.PageHistoryId)\r\n })[0].Published;\r\n }\r\n else if (pageHistory.length == 1)\r\n phid = pageHistory[0].Published;\r\n\r\n return phid;\r\n }\r\n\r\n /**\r\n * Set the paginator and sort after the view init since this component will\r\n * be able to query its view for the initialized paginator and sort.\r\n */\r\n ngAfterViewInit() {\r\n // if (this.paginator != undefined) {\r\n // this.dataSource.paginator = this.paginator;\r\n // this.dataSource.sort = this.sort;\r\n // }\r\n }\r\n checklogin() {\r\n let options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n let token = this.tokenStorage.getToken();\r\n\r\n if (token == null) {\r\n this.alert.error(\"Access denied! login required.\", options);\r\n this.navigate.navigate(['/home']);\r\n }\r\n }\r\n createpage() {\r\n this.navigate.navigate(['/home/editor']);\r\n }\r\n view(pageId, pageTitle, parentId) {\r\n\r\n this.navigate.navigate(['/home/page/' + pageId], { queryParams: { pgid: parentId, pid: pageId, ptitle: pageTitle } });\r\n }\r\n\r\n createNew() {\r\n this.navigate.navigate(['/home/pages/']);\r\n }\r\n applyFilter(filterValue: string) {\r\n filterValue = filterValue.trim(); // Remove whitespace\r\n filterValue = filterValue.toLowerCase(); // Datasource defaults to lowercase matches\r\n this.dataSource.filter = filterValue;\r\n }\r\n isAllSelected() {\r\n const numSelected = this.selection.selected.length;\r\n const numRows = this.dataSource.data.length;\r\n return numSelected === numRows;\r\n }\r\n del(element, value) {\r\n value.stopPropagation();\r\n let confirmYesNo: Boolean = false;\r\n // if (value.length == 0 || value.length > 50) {\r\n // this.alert.error(\"Character should not be empty or less than 50!\");\r\n // return;\r\n // }\r\n this.dialog.openConfirmDialog(\"Are you sure you want to delete all photos in ${value} album?\")\r\n .afterClosed().subscribe(res => {\r\n confirmYesNo = res;\r\n if (confirmYesNo) {\r\n //this.uploadImage();\r\n let PageDetail = {\r\n UpdateDate: new Date(),\r\n Active: 0\r\n };\r\n //let checked = this.selection.toggle(element);\r\n //console.log('checked',checked);\r\n //PageDetail.Active = event.checked == true ? 1 : 0;\r\n PageDetail.UpdateDate = new Date();\r\n this.naomitsuService.postPatch('Pages', PageDetail, element.PageId, 'patch')\r\n .subscribe(\r\n (data: any) => {\r\n this.getDetails(0);\r\n this.alert.success('Item deleted successfully.',this.options);\r\n })\r\n }\r\n });\r\n }\r\n updateActive(element, event) {\r\n let PageDetail = {\r\n UpdateDate: new Date(),\r\n Active: 1\r\n };\r\n let checked = this.selection.toggle(element);\r\n //console.log('checked',checked);\r\n PageDetail.Active = event.checked == true ? 1 : 0;\r\n PageDetail.UpdateDate = new Date();\r\n this.naomitsuService.postPatch('Pages', PageDetail, element.PageId, 'patch')\r\n .subscribe(\r\n (data: any) => {\r\n //alert('data updated.')\r\n })\r\n }\r\n // confirm(event: Event, element, value) {\r\n // debugger;\r\n // try {\r\n // this.confirmationService.confirm({\r\n // target: event.target,\r\n // message: 'Album already exists! Do you want to add to existing album?',\r\n // icon: 'pi pi-exclamation-triangle',\r\n // accept: () => {\r\n // this.updateActive(element, value)\r\n // this.messageService.add({ severity: 'info', summary: 'Confirmed', detail: 'Added to existing album.' });\r\n // },\r\n // reject: () => {\r\n // this.messageService.add({ severity: 'error', summary: 'Rejected', detail: 'Image not added' });\r\n // }\r\n // });\r\n // } catch ({ error }) {\r\n // console.log(error)\r\n // }\r\n // }\r\n /** Selects all rows if they are not all selected; otherwise clear selection. */\r\n masterToggle() {\r\n this.isAllSelected() ?\r\n this.selection.clear() :\r\n this.dataSource.data.forEach(row => this.selection.select(row));\r\n }\r\n\r\n GetParentPage(parentId) {\r\n let list: List = new List();\r\n list.fields = [\"PageId\", \"PageTitle\"];\r\n list.PageName = \"Pages\";\r\n if (parentId == undefined)\r\n list.filter = [\"Active eq 1 and ParentId eq 0 and Module eq 1\"];\r\n else\r\n list.filter = [\"Active eq 1 and ParentId eq \" + parentId + ' and Module eq 1'];\r\n this.loading = true;\r\n this.naomitsuService.get(list)\r\n .subscribe((data: any) => {\r\n this.ParentPages = data.value;\r\n //console.log(\"parent pages\", this.ParentPages);\r\n\r\n this.getDetails(parentId);\r\n //return data.value;\r\n\r\n });\r\n\r\n }\r\n}\r\n\r\nfunction flatten(data) {\r\n var result = {};\r\n function recurse(cur, prop) {\r\n if (Object(cur) !== cur) {\r\n result[prop] = cur;\r\n } else if (Array.isArray(cur)) {\r\n for (var i = 0, l = cur.length; i < l; i++)\r\n recurse(cur[i], prop + \"[\" + i + \"]\");\r\n if (l == 0)\r\n result[prop] = [];\r\n } else {\r\n var isEmpty = true;\r\n for (var p in cur) {\r\n isEmpty = false;\r\n recurse(cur[p], prop ? prop + \".\" + p : p);\r\n }\r\n if (isEmpty && prop)\r\n result[prop] = {};\r\n }\r\n }\r\n recurse(data, \"\");\r\n return result;\r\n}\r\n\r\n","\r\n\r\n
\r\n Manage Page\r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n Page Title \r\n {{element.PageTitle}} \r\n \r\n \r\n \r\n Parent \r\n {{element.ParentPage}} \r\n \r\n \r\n Published \r\n {{element.Published}} \r\n \r\n \r\n Parent Id\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n\r\n \r\n
\r\n
\r\n
","import { Component, OnInit } from '@angular/core'; \r\nimport { Router, ActivatedRoute, Params } from '@angular/router'; \r\nimport { ContentService } from '../../../shared/content.service'; \r\n\r\n@Component({ \r\n selector: 'app-pageView', \r\n templateUrl: './pageView.component.html', \r\n styleUrls: ['./pageView.component.scss'] \r\n}) \r\n\r\nexport class pageViewComponent implements OnInit { \r\n res: any; \r\n Title: any; \r\n content: any; \r\n constructor( private route: ActivatedRoute,private contentservice:ContentService) { } \r\n ngOnInit() { \r\n let Id = this.route.snapshot.queryParams[\"Id\"] \r\n this.GetcontentById(Id); \r\n } \r\n GetcontentById(Id:any) \r\n { \r\n this.contentservice.GetcontentById(Id).subscribe((data: any)=>{ \r\n this.res=data.value[0]; \r\n this.Title=this.res.PageHeader \r\n this.content=this.res.PageBody \r\n //console.log(this.res); \r\n }); \r\n } \r\n} ","import { Injectable, OnInit } from '@angular/core'; \r\nimport { HttpClient,HttpHeaders } from '@angular/common/http'; \r\nimport { PageDetail } from '../content';\r\nimport {globalconstants} from './globalconstant';\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ContentService { \r\n\r\n url :any; \r\n constructor(private http: HttpClient) { } \r\n ngOnInit(): void {\r\n throw new Error('Method not implemented.');\r\n }\r\n AddUpdateContent(pagecontent:any) { \r\n //debugger \r\n this.url = globalconstants.apiUrl + '/odata/Pages';\r\n //this.url =\"/odata/Pages\"; \r\n return this.http.post(this.url, pagecontent); \r\n} \r\nGetcontent(title:string,query:string) { \r\n debugger \r\n this.url = globalconstants.apiUrl + '/odata/' +title + '?' + query; \r\n //this.url = '/odata/' +title + '?' + query; \r\n //console.log(this.url);\r\n return this.http.get(this.url);//.map(res=>res.json());\r\n //.pipe(map((res:Response) => res.json()));\r\n // .pipe(map((res:any)=>{\r\n // var data = res.json();\r\n // return new (data.PageId, data.PageHeader, data.PageType.PageName,data.Version);\r\n}\r\n\r\nGetPageTypes() { \r\n //debugger \r\n this.url = globalconstants.apiUrl + '/odata/PageTypes?$filter=Active eq true'; \r\n //this.url = '/odata/PageTypes?$filter=Active eq true'; \r\n //var filter = ''\r\n return this.http.get(this.url); \r\n} \r\nGetcontentLatest(pageGroupId:number,pageName:string) { \r\n debugger \r\n let filter = \"PageName eq '\" + pageName + \"' and PageNameId eq \" + pageGroupId; \r\n this.url = globalconstants.apiUrl + '/odata/Pages?$select=PageId,Version&$orderby=Version desc&$top=1&$filter=' + filter; \r\n //this.url = '/odata/Pages?$select=PageId,Version&$orderby=Version desc&$top=1&$filter=' + filter; \r\n return this.http.get(this.url); \r\n}\r\nGetcontentById(Id:number) { \r\n debugger \r\n this.url = globalconstants.apiUrl + '/odata/Pages?$filter=PageId eq ' + Id; \r\n //this.url = '/odata/Pages?$filter=PageId eq ' + Id; \r\n return this.http.get(this.url); \r\n}\r\n\r\nUpdatecontentById(body:PageDetail,key:any) { \r\n const httpOptions = {\r\n headers: new HttpHeaders({\r\n 'Content-Type': 'application/json' \r\n })\r\n };\r\n//headers=headers.append('Access-Control-Allow-Origin', '*') \r\n this.url = globalconstants.apiUrl + '/odata/Pages/(' + key +')'; \r\n //this.url = '/odata/Pages/(' + key +')'; \r\n return this.http.patch(this.url,body,httpOptions ) \r\n }\r\n}\r\n","
\r\n
\r\n
{{this.Title}}
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
","import { Directive, Component, Input, Output, EventEmitter, HostBinding, HostListener, Injectable, ViewChild, ContentChildren, Self, NgModule } from '@angular/core';\nimport { __awaiter } from 'tslib';\nimport { DomSanitizer } from '@angular/platform-browser';\nimport { CommonModule } from '@angular/common';\n\n/**\n * @fileoverview added by tsickle\n * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\nimport * as ɵngcc0 from '@angular/core';\nimport * as ɵngcc1 from '@angular/platform-browser';\nimport * as ɵngcc2 from '@angular/common';\n\nfunction NgxDropzonePreviewComponent_ngx_dropzone_remove_badge_1_Template(rf, ctx) { if (rf & 1) {\n const _r2 = ɵngcc0.ɵɵgetCurrentView();\n ɵngcc0.ɵɵelementStart(0, \"ngx-dropzone-remove-badge\", 1);\n ɵngcc0.ɵɵlistener(\"click\", function NgxDropzonePreviewComponent_ngx_dropzone_remove_badge_1_Template_ngx_dropzone_remove_badge_click_0_listener($event) { ɵngcc0.ɵɵrestoreView(_r2); const ctx_r1 = ɵngcc0.ɵɵnextContext(); return ctx_r1._remove($event); });\n ɵngcc0.ɵɵelementEnd();\n} }\nconst _c0 = [[[\"ngx-dropzone-label\"]]];\nconst _c1 = [\"ngx-dropzone-label\"];\nconst _c2 = [\"fileInput\"];\nfunction NgxDropzoneComponent_ng_content_2_Template(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵprojection(0, 2, [\"*ngIf\", \"!_hasPreviews\"]);\n} }\nconst _c3 = [[[\"ngx-dropzone-preview\"]], \"*\", [[\"ngx-dropzone-label\"]]];\nconst _c4 = [\"ngx-dropzone-preview\", \"*\", \"ngx-dropzone-label\"];\nfunction NgxDropzoneImagePreviewComponent_ngx_dropzone_remove_badge_2_Template(rf, ctx) { if (rf & 1) {\n const _r2 = ɵngcc0.ɵɵgetCurrentView();\n ɵngcc0.ɵɵelementStart(0, \"ngx-dropzone-remove-badge\", 2);\n ɵngcc0.ɵɵlistener(\"click\", function NgxDropzoneImagePreviewComponent_ngx_dropzone_remove_badge_2_Template_ngx_dropzone_remove_badge_click_0_listener($event) { ɵngcc0.ɵɵrestoreView(_r2); const ctx_r1 = ɵngcc0.ɵɵnextContext(); return ctx_r1._remove($event); });\n ɵngcc0.ɵɵelementEnd();\n} }\nfunction NgxDropzoneVideoPreviewComponent_video_0_Template(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵelementStart(0, \"video\", 2);\n ɵngcc0.ɵɵlistener(\"click\", function NgxDropzoneVideoPreviewComponent_video_0_Template_video_click_0_listener($event) { return $event.stopPropagation(); });\n ɵngcc0.ɵɵelement(1, \"source\", 3);\n ɵngcc0.ɵɵelementEnd();\n} if (rf & 2) {\n const ctx_r0 = ɵngcc0.ɵɵnextContext();\n ɵngcc0.ɵɵadvance(1);\n ɵngcc0.ɵɵproperty(\"src\", ctx_r0.sanitizedVideoSrc, ɵngcc0.ɵɵsanitizeUrl);\n} }\nfunction NgxDropzoneVideoPreviewComponent_ngx_dropzone_remove_badge_2_Template(rf, ctx) { if (rf & 1) {\n const _r4 = ɵngcc0.ɵɵgetCurrentView();\n ɵngcc0.ɵɵelementStart(0, \"ngx-dropzone-remove-badge\", 4);\n ɵngcc0.ɵɵlistener(\"click\", function NgxDropzoneVideoPreviewComponent_ngx_dropzone_remove_badge_2_Template_ngx_dropzone_remove_badge_click_0_listener($event) { ɵngcc0.ɵɵrestoreView(_r4); const ctx_r3 = ɵngcc0.ɵɵnextContext(); return ctx_r3._remove($event); });\n ɵngcc0.ɵɵelementEnd();\n} }\nclass NgxDropzoneLabelDirective {\n}\nNgxDropzoneLabelDirective.ɵfac = function NgxDropzoneLabelDirective_Factory(t) { return new (t || NgxDropzoneLabelDirective)(); };\nNgxDropzoneLabelDirective.ɵdir = ɵngcc0.ɵɵdefineDirective({ type: NgxDropzoneLabelDirective, selectors: [[\"ngx-dropzone-label\"]] });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(NgxDropzoneLabelDirective, [{\n type: Directive,\n args: [{\n selector: 'ngx-dropzone-label'\n }]\n }], null, null); })();\n\n/**\n * @fileoverview added by tsickle\n * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\n/**\n * Coerces a data-bound value (typically a string) to a boolean.\n * Taken from https://github.com/angular/components/blob/master/src/cdk/coercion/boolean-property.ts\n * @param {?} value\n * @return {?}\n */\nfunction coerceBooleanProperty(value) {\n return value != null && `${value}` !== 'false';\n}\n/**\n * Whether the provided value is considered a number.\n * Taken from https://github.com/angular/components/blob/master/src/cdk/coercion/number-property.ts\n * @param {?} value\n * @return {?}\n */\nfunction coerceNumberProperty(value) {\n // parseFloat(value) handles most of the cases we're interested in (it treats null, empty string,\n // and other non-number values as NaN, where Number just uses 0) but it considers the string\n // '123hello' to be a valid number. Therefore we also check if Number(value) is NaN.\n return (!isNaN(parseFloat((/** @type {?} */ (value)))) && !isNaN(Number(value))) ? Number(value) : null;\n}\n\n/**\n * @fileoverview added by tsickle\n * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\n/** @enum {number} */\nconst KEY_CODE = {\n BACKSPACE: 8,\n DELETE: 46,\n};\nKEY_CODE[KEY_CODE.BACKSPACE] = 'BACKSPACE';\nKEY_CODE[KEY_CODE.DELETE] = 'DELETE';\nclass NgxDropzonePreviewComponent {\n /**\n * @param {?} sanitizer\n */\n constructor(sanitizer) {\n this.sanitizer = sanitizer;\n this._removable = false;\n /**\n * Emitted when the element should be removed.\n */\n this.removed = new EventEmitter();\n /**\n * Make the preview item focusable using the tab key.\n */\n this.tabIndex = 0;\n }\n /**\n * Allow the user to remove files.\n * @return {?}\n */\n get removable() {\n return this._removable;\n }\n /**\n * @param {?} value\n * @return {?}\n */\n set removable(value) {\n this._removable = coerceBooleanProperty(value);\n }\n /**\n * @param {?} event\n * @return {?}\n */\n keyEvent(event) {\n switch (event.keyCode) {\n case KEY_CODE.BACKSPACE:\n case KEY_CODE.DELETE:\n this.remove();\n break;\n default:\n break;\n }\n }\n /**\n * We use the HostBinding to pass these common styles to child components.\n * @return {?}\n */\n get hostStyle() {\n /** @type {?} */\n const styles = `\n\t\t\tdisplay: flex;\n\t\t\theight: 140px;\n\t\t\tmin-height: 140px;\n\t\t\tmin-width: 180px;\n\t\t\tmax-width: 180px;\n\t\t\tjustify-content: center;\n\t\t\talign-items: center;\n\t\t\tpadding: 0 20px;\n\t\t\tmargin: 10px;\n\t\t\tborder-radius: 5px;\n\t\t\tposition: relative;\n\t\t`;\n return this.sanitizer.bypassSecurityTrustStyle(styles);\n }\n /**\n * Remove method to be used from the template.\n * @param {?} event\n * @return {?}\n */\n _remove(event) {\n event.stopPropagation();\n this.remove();\n }\n /**\n * Remove the preview item (use from component code).\n * @return {?}\n */\n remove() {\n if (this._removable) {\n this.removed.next(this.file);\n }\n }\n /**\n * @protected\n * @return {?}\n */\n readFile() {\n return __awaiter(this, void 0, void 0, function* () {\n return new Promise((/**\n * @param {?} resolve\n * @param {?} reject\n * @return {?}\n */\n (resolve, reject) => {\n /** @type {?} */\n const reader = new FileReader();\n reader.onload = (/**\n * @param {?} e\n * @return {?}\n */\n e => {\n resolve(((/** @type {?} */ (e.target))).result);\n });\n reader.onerror = (/**\n * @param {?} e\n * @return {?}\n */\n e => {\n console.error(`FileReader failed on file ${this.file.name}.`);\n reject(e);\n });\n if (!this.file) {\n return reject('No file to read. Please provide a file using the [file] Input property.');\n }\n reader.readAsDataURL(this.file);\n }));\n });\n }\n}\nNgxDropzonePreviewComponent.ɵfac = function NgxDropzonePreviewComponent_Factory(t) { return new (t || NgxDropzonePreviewComponent)(ɵngcc0.ɵɵdirectiveInject(ɵngcc1.DomSanitizer)); };\nNgxDropzonePreviewComponent.ɵcmp = ɵngcc0.ɵɵdefineComponent({ type: NgxDropzonePreviewComponent, selectors: [[\"ngx-dropzone-preview\"]], hostVars: 3, hostBindings: function NgxDropzonePreviewComponent_HostBindings(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵlistener(\"keyup\", function NgxDropzonePreviewComponent_keyup_HostBindingHandler($event) { return ctx.keyEvent($event); });\n } if (rf & 2) {\n ɵngcc0.ɵɵhostProperty(\"tabindex\", ctx.tabIndex);\n ɵngcc0.ɵɵstyleMap(ctx.hostStyle);\n } }, inputs: { removable: \"removable\", file: \"file\" }, outputs: { removed: \"removed\" }, ngContentSelectors: _c1, decls: 2, vars: 1, consts: [[3, \"click\", 4, \"ngIf\"], [3, \"click\"]], template: function NgxDropzonePreviewComponent_Template(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵprojectionDef(_c0);\n ɵngcc0.ɵɵprojection(0);\n ɵngcc0.ɵɵtemplate(1, NgxDropzonePreviewComponent_ngx_dropzone_remove_badge_1_Template, 1, 0, \"ngx-dropzone-remove-badge\", 0);\n } if (rf & 2) {\n ɵngcc0.ɵɵadvance(1);\n ɵngcc0.ɵɵproperty(\"ngIf\", ctx.removable);\n } }, directives: function () { return [ɵngcc2.NgIf, NgxDropzoneRemoveBadgeComponent]; }, styles: [\"[_nghost-%COMP%]{background-image:linear-gradient(to top,#ededed,#efefef,#f1f1f1,#f4f4f4,#f6f6f6)}[_nghost-%COMP%]:focus, [_nghost-%COMP%]:hover{background-image:linear-gradient(to top,#e3e3e3,#ebeaea,#e8e7e7,#ebeaea,#f4f4f4);outline:0}[_nghost-%COMP%]:focus ngx-dropzone-remove-badge[_ngcontent-%COMP%], [_nghost-%COMP%]:hover ngx-dropzone-remove-badge[_ngcontent-%COMP%]{opacity:1}[_nghost-%COMP%] ngx-dropzone-remove-badge[_ngcontent-%COMP%]{opacity:0}[_nghost-%COMP%] ngx-dropzone-label{overflow-wrap:break-word}\"] });\n/** @nocollapse */\nNgxDropzonePreviewComponent.ctorParameters = () => [\n { type: DomSanitizer }\n];\nNgxDropzonePreviewComponent.propDecorators = {\n file: [{ type: Input }],\n removable: [{ type: Input }],\n removed: [{ type: Output }],\n keyEvent: [{ type: HostListener, args: ['keyup', ['$event'],] }],\n hostStyle: [{ type: HostBinding, args: ['style',] }],\n tabIndex: [{ type: HostBinding, args: ['tabindex',] }]\n};\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(NgxDropzonePreviewComponent, [{\n type: Component,\n args: [{\n selector: 'ngx-dropzone-preview',\n template: `\n\t\t\n\t\t\n\t\t\n\t`,\n styles: [`:host(){background-image:linear-gradient(to top,#ededed,#efefef,#f1f1f1,#f4f4f4,#f6f6f6)}:host():focus,:host():hover{background-image:linear-gradient(to top,#e3e3e3,#ebeaea,#e8e7e7,#ebeaea,#f4f4f4);outline:0}:host():focus ngx-dropzone-remove-badge,:host():hover ngx-dropzone-remove-badge{opacity:1}:host() ngx-dropzone-remove-badge{opacity:0}:host() ::ng-deep ngx-dropzone-label{overflow-wrap:break-word}`]\n }]\n }], function () { return [{ type: ɵngcc1.DomSanitizer }]; }, { removed: [{\n type: Output\n }], tabIndex: [{\n type: HostBinding,\n args: ['tabindex']\n }], removable: [{\n type: Input\n }], \n /**\n * @param {?} event\n * @return {?}\n */\n keyEvent: [{\n type: HostListener,\n args: ['keyup', ['$event']]\n }], hostStyle: [{\n type: HostBinding,\n args: ['style']\n }], file: [{\n type: Input\n }] }); })();\n\n/**\n * @fileoverview added by tsickle\n * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\n/**\n * This service contains the filtering logic to be applied to\n * any dropped or selected file. If a file matches all criteria\n * like maximum size or accept type, it will be emitted in the\n * addedFiles array, otherwise in the rejectedFiles array.\n */\nclass NgxDropzoneService {\n /**\n * @param {?} files\n * @param {?} accept\n * @param {?} maxFileSize\n * @param {?} multiple\n * @return {?}\n */\n parseFileList(files, accept, maxFileSize, multiple) {\n /** @type {?} */\n const addedFiles = [];\n /** @type {?} */\n const rejectedFiles = [];\n for (let i = 0; i < files.length; i++) {\n /** @type {?} */\n const file = files.item(i);\n if (!this.isAccepted(file, accept)) {\n this.rejectFile(rejectedFiles, file, 'type');\n continue;\n }\n if (maxFileSize && file.size > maxFileSize) {\n this.rejectFile(rejectedFiles, file, 'size');\n continue;\n }\n if (!multiple && addedFiles.length >= 1) {\n this.rejectFile(rejectedFiles, file, 'no_multiple');\n continue;\n }\n addedFiles.push(file);\n }\n /** @type {?} */\n const result = {\n addedFiles,\n rejectedFiles\n };\n return result;\n }\n /**\n * @private\n * @param {?} file\n * @param {?} accept\n * @return {?}\n */\n isAccepted(file, accept) {\n if (accept === '*') {\n return true;\n }\n /** @type {?} */\n const acceptFiletypes = accept.split(',').map((/**\n * @param {?} it\n * @return {?}\n */\n it => it.toLowerCase().trim()));\n /** @type {?} */\n const filetype = file.type.toLowerCase();\n /** @type {?} */\n const filename = file.name.toLowerCase();\n /** @type {?} */\n const matchedFileType = acceptFiletypes.find((/**\n * @param {?} acceptFiletype\n * @return {?}\n */\n acceptFiletype => {\n // check for wildcard mimetype (e.g. image/*)\n if (acceptFiletype.endsWith('/*')) {\n return filetype.split('/')[0] === acceptFiletype.split('/')[0];\n }\n // check for file extension (e.g. .csv)\n if (acceptFiletype.startsWith(\".\")) {\n return filename.endsWith(acceptFiletype);\n }\n // check for exact mimetype match (e.g. image/jpeg)\n return acceptFiletype == filetype;\n }));\n return !!matchedFileType;\n }\n /**\n * @private\n * @param {?} rejectedFiles\n * @param {?} file\n * @param {?} reason\n * @return {?}\n */\n rejectFile(rejectedFiles, file, reason) {\n /** @type {?} */\n const rejectedFile = (/** @type {?} */ (file));\n rejectedFile.reason = reason;\n rejectedFiles.push(rejectedFile);\n }\n}\nNgxDropzoneService.ɵfac = function NgxDropzoneService_Factory(t) { return new (t || NgxDropzoneService)(); };\nNgxDropzoneService.ɵprov = ɵngcc0.ɵɵdefineInjectable({ token: NgxDropzoneService, factory: NgxDropzoneService.ɵfac });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(NgxDropzoneService, [{\n type: Injectable\n }], null, null); })();\n\n/**\n * @fileoverview added by tsickle\n * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\nclass NgxDropzoneComponent {\n /**\n * @param {?} service\n */\n constructor(service) {\n this.service = service;\n /**\n * Emitted when any files were added or rejected.\n */\n this.change = new EventEmitter();\n /**\n * Set the accepted file types. Defaults to '*'.\n */\n this.accept = '*';\n this._disabled = false;\n this._multiple = true;\n this._maxFileSize = undefined;\n this._expandable = false;\n this._disableClick = false;\n this._isHovered = false;\n }\n /**\n * @return {?}\n */\n get _hasPreviews() {\n return !!this._previewChildren.length;\n }\n /**\n * Disable any user interaction with the component.\n * @return {?}\n */\n get disabled() {\n return this._disabled;\n }\n /**\n * @param {?} value\n * @return {?}\n */\n set disabled(value) {\n this._disabled = coerceBooleanProperty(value);\n if (this._isHovered) {\n this._isHovered = false;\n }\n }\n /**\n * Allow the selection of multiple files.\n * @return {?}\n */\n get multiple() {\n return this._multiple;\n }\n /**\n * @param {?} value\n * @return {?}\n */\n set multiple(value) {\n this._multiple = coerceBooleanProperty(value);\n }\n /**\n * Set the maximum size a single file may have.\n * @return {?}\n */\n get maxFileSize() {\n return this._maxFileSize;\n }\n /**\n * @param {?} value\n * @return {?}\n */\n set maxFileSize(value) {\n this._maxFileSize = coerceNumberProperty(value);\n }\n /**\n * Allow the dropzone container to expand vertically.\n * @return {?}\n */\n get expandable() {\n return this._expandable;\n }\n /**\n * @param {?} value\n * @return {?}\n */\n set expandable(value) {\n this._expandable = coerceBooleanProperty(value);\n }\n /**\n * Open the file selector on click.\n * @return {?}\n */\n get disableClick() {\n return this._disableClick;\n }\n /**\n * @param {?} value\n * @return {?}\n */\n set disableClick(value) {\n this._disableClick = coerceBooleanProperty(value);\n }\n /**\n * Show the native OS file explorer to select files.\n * @return {?}\n */\n _onClick() {\n if (!this.disableClick) {\n this.showFileSelector();\n }\n }\n /**\n * @param {?} event\n * @return {?}\n */\n _onDragOver(event) {\n if (this.disabled) {\n return;\n }\n this.preventDefault(event);\n this._isHovered = true;\n }\n /**\n * @return {?}\n */\n _onDragLeave() {\n this._isHovered = false;\n }\n /**\n * @param {?} event\n * @return {?}\n */\n _onDrop(event) {\n if (this.disabled) {\n return;\n }\n this.preventDefault(event);\n this._isHovered = false;\n this.handleFileDrop(event.dataTransfer.files);\n }\n /**\n * @return {?}\n */\n showFileSelector() {\n if (!this.disabled) {\n ((/** @type {?} */ (this._fileInput.nativeElement))).click();\n }\n }\n /**\n * @param {?} event\n * @return {?}\n */\n _onFilesSelected(event) {\n /** @type {?} */\n const files = event.target.files;\n this.handleFileDrop(files);\n // Reset the native file input element to allow selecting the same file again\n this._fileInput.nativeElement.value = '';\n // fix(#32): Prevent the default event behaviour which caused the change event to emit twice.\n this.preventDefault(event);\n }\n /**\n * @private\n * @param {?} files\n * @return {?}\n */\n handleFileDrop(files) {\n /** @type {?} */\n const result = this.service.parseFileList(files, this.accept, this.maxFileSize, this.multiple);\n this.change.next({\n addedFiles: result.addedFiles,\n rejectedFiles: result.rejectedFiles,\n source: this\n });\n }\n /**\n * @private\n * @param {?} event\n * @return {?}\n */\n preventDefault(event) {\n event.preventDefault();\n event.stopPropagation();\n }\n}\nNgxDropzoneComponent.ɵfac = function NgxDropzoneComponent_Factory(t) { return new (t || NgxDropzoneComponent)(ɵngcc0.ɵɵdirectiveInject(NgxDropzoneService, 2)); };\nNgxDropzoneComponent.ɵcmp = ɵngcc0.ɵɵdefineComponent({ type: NgxDropzoneComponent, selectors: [[\"ngx-dropzone\"], [\"\", \"ngx-dropzone\", \"\"]], contentQueries: function NgxDropzoneComponent_ContentQueries(rf, ctx, dirIndex) { if (rf & 1) {\n ɵngcc0.ɵɵcontentQuery(dirIndex, NgxDropzonePreviewComponent, true);\n } if (rf & 2) {\n let _t;\n ɵngcc0.ɵɵqueryRefresh(_t = ɵngcc0.ɵɵloadQuery()) && (ctx._previewChildren = _t);\n } }, viewQuery: function NgxDropzoneComponent_Query(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵviewQuery(_c2, true);\n } if (rf & 2) {\n let _t;\n ɵngcc0.ɵɵqueryRefresh(_t = ɵngcc0.ɵɵloadQuery()) && (ctx._fileInput = _t.first);\n } }, hostVars: 8, hostBindings: function NgxDropzoneComponent_HostBindings(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵlistener(\"click\", function NgxDropzoneComponent_click_HostBindingHandler() { return ctx._onClick(); })(\"dragover\", function NgxDropzoneComponent_dragover_HostBindingHandler($event) { return ctx._onDragOver($event); })(\"dragleave\", function NgxDropzoneComponent_dragleave_HostBindingHandler() { return ctx._onDragLeave(); })(\"drop\", function NgxDropzoneComponent_drop_HostBindingHandler($event) { return ctx._onDrop($event); });\n } if (rf & 2) {\n ɵngcc0.ɵɵclassProp(\"ngx-dz-hovered\", ctx._isHovered)(\"ngx-dz-disabled\", ctx.disabled)(\"expandable\", ctx.expandable)(\"unclickable\", ctx.disableClick);\n } }, inputs: { accept: \"accept\", disabled: \"disabled\", multiple: \"multiple\", maxFileSize: \"maxFileSize\", expandable: \"expandable\", disableClick: \"disableClick\", id: \"id\", ariaLabel: [\"aria-label\", \"ariaLabel\"], ariaLabelledby: [\"aria-labelledby\", \"ariaLabelledby\"], ariaDescribedBy: [\"aria-describedby\", \"ariaDescribedBy\"] }, outputs: { change: \"change\" }, features: [ɵngcc0.ɵɵProvidersFeature([NgxDropzoneService])], ngContentSelectors: _c4, decls: 5, vars: 8, consts: [[\"type\", \"file\", 3, \"id\", \"multiple\", \"accept\", \"disabled\", \"change\"], [\"fileInput\", \"\"], [4, \"ngIf\"]], template: function NgxDropzoneComponent_Template(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵprojectionDef(_c3);\n ɵngcc0.ɵɵelementStart(0, \"input\", 0, 1);\n ɵngcc0.ɵɵlistener(\"change\", function NgxDropzoneComponent_Template_input_change_0_listener($event) { return ctx._onFilesSelected($event); });\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵtemplate(2, NgxDropzoneComponent_ng_content_2_Template, 1, 0, \"ng-content\", 2);\n ɵngcc0.ɵɵprojection(3);\n ɵngcc0.ɵɵprojection(4, 1);\n } if (rf & 2) {\n ɵngcc0.ɵɵproperty(\"id\", ctx.id)(\"multiple\", ctx.multiple)(\"accept\", ctx.accept)(\"disabled\", ctx.disabled);\n ɵngcc0.ɵɵattribute(\"aria-label\", ctx.ariaLabel)(\"aria-labelledby\", ctx.ariaLabelledby)(\"aria-describedby\", ctx.ariaDescribedBy);\n ɵngcc0.ɵɵadvance(2);\n ɵngcc0.ɵɵproperty(\"ngIf\", !ctx._hasPreviews);\n } }, directives: [ɵngcc2.NgIf], styles: [\"[_nghost-%COMP%]{display:flex;align-items:center;height:180px;background:#fff;cursor:pointer;color:#717386;border:2px dashed #717386;border-radius:5px;font-size:16px;overflow-x:auto}.ngx-dz-hovered[_nghost-%COMP%]{border-style:solid}.ngx-dz-disabled[_nghost-%COMP%]{opacity:.5;cursor:no-drop;pointer-events:none}.expandable[_nghost-%COMP%]{overflow:hidden;height:unset;min-height:180px;flex-wrap:wrap}.unclickable[_nghost-%COMP%]{cursor:default}[_nghost-%COMP%] ngx-dropzone-label{text-align:center;z-index:10;margin:10px auto}[_nghost-%COMP%] input[_ngcontent-%COMP%]{width:.1px;height:.1px;opacity:0;overflow:hidden;position:absolute;z-index:-1}[_nghost-%COMP%] input[_ngcontent-%COMP%]:focus + ngx-dropzone-label{outline:#000 dotted 1px;outline:-webkit-focus-ring-color auto 5px}\"] });\n/** @nocollapse */\nNgxDropzoneComponent.ctorParameters = () => [\n { type: NgxDropzoneService, decorators: [{ type: Self }] }\n];\nNgxDropzoneComponent.propDecorators = {\n _previewChildren: [{ type: ContentChildren, args: [NgxDropzonePreviewComponent, { descendants: true },] }],\n _fileInput: [{ type: ViewChild, args: ['fileInput',] }],\n change: [{ type: Output }],\n accept: [{ type: Input }],\n disabled: [{ type: Input }, { type: HostBinding, args: ['class.ngx-dz-disabled',] }],\n multiple: [{ type: Input }],\n maxFileSize: [{ type: Input }],\n expandable: [{ type: Input }, { type: HostBinding, args: ['class.expandable',] }],\n disableClick: [{ type: Input }, { type: HostBinding, args: ['class.unclickable',] }],\n id: [{ type: Input }],\n ariaLabel: [{ type: Input, args: ['aria-label',] }],\n ariaLabelledby: [{ type: Input, args: ['aria-labelledby',] }],\n ariaDescribedBy: [{ type: Input, args: ['aria-describedby',] }],\n _isHovered: [{ type: HostBinding, args: ['class.ngx-dz-hovered',] }],\n _onClick: [{ type: HostListener, args: ['click',] }],\n _onDragOver: [{ type: HostListener, args: ['dragover', ['$event'],] }],\n _onDragLeave: [{ type: HostListener, args: ['dragleave',] }],\n _onDrop: [{ type: HostListener, args: ['drop', ['$event'],] }]\n};\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(NgxDropzoneComponent, [{\n type: Component,\n args: [{\n selector: 'ngx-dropzone, [ngx-dropzone]',\n template: `\n\n\n\n`,\n styles: [`:host(){display:flex;align-items:center;height:180px;background:#fff;cursor:pointer;color:#717386;border:2px dashed #717386;border-radius:5px;font-size:16px;overflow-x:auto}:host().ngx-dz-hovered{border-style:solid}:host().ngx-dz-disabled{opacity:.5;cursor:no-drop;pointer-events:none}:host().expandable{overflow:hidden;height:unset;min-height:180px;flex-wrap:wrap}:host().unclickable{cursor:default}:host() ::ng-deep ngx-dropzone-label{text-align:center;z-index:10;margin:10px auto}:host() input{width:.1px;height:.1px;opacity:0;overflow:hidden;position:absolute;z-index:-1}:host() input:focus+::ng-deep ngx-dropzone-label{outline:#000 dotted 1px;outline:-webkit-focus-ring-color auto 5px}`],\n providers: [NgxDropzoneService]\n }]\n }], function () { return [{ type: NgxDropzoneService, decorators: [{\n type: Self\n }] }]; }, { change: [{\n type: Output\n }], accept: [{\n type: Input\n }], _isHovered: [{\n type: HostBinding,\n args: ['class.ngx-dz-hovered']\n }], disabled: [{\n type: Input\n }, {\n type: HostBinding,\n args: ['class.ngx-dz-disabled']\n }], multiple: [{\n type: Input\n }], maxFileSize: [{\n type: Input\n }], expandable: [{\n type: Input\n }, {\n type: HostBinding,\n args: ['class.expandable']\n }], disableClick: [{\n type: Input\n }, {\n type: HostBinding,\n args: ['class.unclickable']\n }], \n /**\n * Show the native OS file explorer to select files.\n * @return {?}\n */\n _onClick: [{\n type: HostListener,\n args: ['click']\n }], \n /**\n * @param {?} event\n * @return {?}\n */\n _onDragOver: [{\n type: HostListener,\n args: ['dragover', ['$event']]\n }], \n /**\n * @return {?}\n */\n _onDragLeave: [{\n type: HostListener,\n args: ['dragleave']\n }], \n /**\n * @param {?} event\n * @return {?}\n */\n _onDrop: [{\n type: HostListener,\n args: ['drop', ['$event']]\n }], _previewChildren: [{\n type: ContentChildren,\n args: [NgxDropzonePreviewComponent, { descendants: true }]\n }], _fileInput: [{\n type: ViewChild,\n args: ['fileInput']\n }], id: [{\n type: Input\n }], ariaLabel: [{\n type: Input,\n args: ['aria-label']\n }], ariaLabelledby: [{\n type: Input,\n args: ['aria-labelledby']\n }], ariaDescribedBy: [{\n type: Input,\n args: ['aria-describedby']\n }] }); })();\n\n/**\n * @fileoverview added by tsickle\n * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\nclass NgxDropzoneImagePreviewComponent extends NgxDropzonePreviewComponent {\n /**\n * @param {?} sanitizer\n */\n constructor(sanitizer) {\n super(sanitizer);\n /**\n * The image data source.\n */\n this.defualtImgLoading = 'data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4KPHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBzdHlsZT0ibWFyZ2luOiBhdXRvOyBiYWNrZ3JvdW5kOiByZ2IoMjQxLCAyNDIsIDI0Mykgbm9uZSByZXBlYXQgc2Nyb2xsIDAlIDAlOyBkaXNwbGF5OiBibG9jazsgc2hhcGUtcmVuZGVyaW5nOiBhdXRvOyIgd2lkdGg9IjIyNHB4IiBoZWlnaHQ9IjIyNHB4IiB2aWV3Qm94PSIwIDAgMTAwIDEwMCIgcHJlc2VydmVBc3BlY3RSYXRpbz0ieE1pZFlNaWQiPgo8Y2lyY2xlIGN4P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rc = this.sanitizer.bypassSecurityTrustUrl(this.defualtImgLoading);\n }\n /**\n * @return {?}\n */\n ngOnInit() {\n this.readFile()\n .then((/**\n * @param {?} img\n * @return {?}\n */\n img => setTimeout((/**\n * @return {?}\n */\n () => this.imageSrc = img))))\n .catch((/**\n * @param {?} err\n * @return {?}\n */\n err => console.error(err)));\n }\n}\nNgxDropzoneImagePreviewComponent.ɵfac = function NgxDropzoneImagePreviewComponent_Factory(t) { return new (t || NgxDropzoneImagePreviewComponent)(ɵngcc0.ɵɵdirectiveInject(ɵngcc1.DomSanitizer)); };\nNgxDropzoneImagePreviewComponent.ɵcmp = ɵngcc0.ɵɵdefineComponent({ type: NgxDropzoneImagePreviewComponent, selectors: [[\"ngx-dropzone-image-preview\"]], features: [ɵngcc0.ɵɵProvidersFeature([\n {\n provide: NgxDropzonePreviewComponent,\n useExisting: NgxDropzoneImagePreviewComponent\n }\n ]), ɵngcc0.ɵɵInheritDefinitionFeature], ngContentSelectors: _c1, decls: 3, vars: 2, consts: [[3, \"src\"], [3, \"click\", 4, \"ngIf\"], [3, \"click\"]], template: function NgxDropzoneImagePreviewComponent_Template(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵprojectionDef(_c0);\n ɵngcc0.ɵɵelement(0, \"img\", 0);\n ɵngcc0.ɵɵprojection(1);\n ɵngcc0.ɵɵtemplate(2, NgxDropzoneImagePreviewComponent_ngx_dropzone_remove_badge_2_Template, 1, 0, \"ngx-dropzone-remove-badge\", 1);\n } if (rf & 2) {\n ɵngcc0.ɵɵproperty(\"src\", ctx.imageSrc, ɵngcc0.ɵɵsanitizeUrl);\n ɵngcc0.ɵɵadvance(2);\n ɵngcc0.ɵɵproperty(\"ngIf\", ctx.removable);\n } }, directives: function () { return [ɵngcc2.NgIf, NgxDropzoneRemoveBadgeComponent]; }, styles: [\"[_nghost-%COMP%]{min-width:unset!important;max-width:unset!important;padding:0!important}[_nghost-%COMP%]:focus img[_ngcontent-%COMP%], [_nghost-%COMP%]:hover img[_ngcontent-%COMP%]{opacity:.7}[_nghost-%COMP%]:focus ngx-dropzone-remove-badge[_ngcontent-%COMP%], [_nghost-%COMP%]:hover ngx-dropzone-remove-badge[_ngcontent-%COMP%]{opacity:1}[_nghost-%COMP%] ngx-dropzone-remove-badge[_ngcontent-%COMP%]{opacity:0}[_nghost-%COMP%] img[_ngcontent-%COMP%]{max-height:100%;border-radius:5px;opacity:.8}[_nghost-%COMP%] ngx-dropzone-label{position:absolute;overflow-wrap:break-word}\"] });\n/** @nocollapse */\nNgxDropzoneImagePreviewComponent.ctorParameters = () => [\n { type: DomSanitizer }\n];\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(NgxDropzoneImagePreviewComponent, [{\n type: Component,\n args: [{\n selector: 'ngx-dropzone-image-preview',\n template: `\n \n\t\t\n \n \n\t`,\n styles: [`:host(){min-width:unset!important;max-width:unset!important;padding:0!important}:host():focus img,:host():hover img{opacity:.7}:host():focus ngx-dropzone-remove-badge,:host():hover ngx-dropzone-remove-badge{opacity:1}:host() ngx-dropzone-remove-badge{opacity:0}:host() img{max-height:100%;border-radius:5px;opacity:.8}:host() ::ng-deep ngx-dropzone-label{position:absolute;overflow-wrap:break-word}`],\n providers: [\n {\n provide: NgxDropzonePreviewComponent,\n useExisting: NgxDropzoneImagePreviewComponent\n }\n ]\n }]\n }], function () { return [{ type: ɵngcc1.DomSanitizer }]; }, null); })();\n\n/**\n * @fileoverview added by tsickle\n * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\nclass NgxDropzoneRemoveBadgeComponent {\n}\nNgxDropzoneRemoveBadgeComponent.ɵfac = function NgxDropzoneRemoveBadgeComponent_Factory(t) { return new (t || NgxDropzoneRemoveBadgeComponent)(); };\nNgxDropzoneRemoveBadgeComponent.ɵcmp = ɵngcc0.ɵɵdefineComponent({ type: NgxDropzoneRemoveBadgeComponent, selectors: [[\"ngx-dropzone-remove-badge\"]], decls: 3, vars: 0, consts: [[\"x1\", \"0\", \"y1\", \"0\", \"x2\", \"10\", \"y2\", \"10\"], [\"x1\", \"0\", \"y1\", \"10\", \"x2\", \"10\", \"y2\", \"0\"]], template: function NgxDropzoneRemoveBadgeComponent_Template(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵnamespaceSVG();\n ɵngcc0.ɵɵelementStart(0, \"svg\");\n ɵngcc0.ɵɵelement(1, \"line\", 0);\n ɵngcc0.ɵɵelement(2, \"line\", 1);\n ɵngcc0.ɵɵelementEnd();\n } }, styles: [\"[_nghost-%COMP%]{display:flex;justify-content:center;align-items:center;height:22px;width:22px;position:absolute;top:5px;right:5px;border-radius:50%;background:#bbb;color:#333;cursor:pointer}[_nghost-%COMP%]:hover{background:#aeaeae}[_nghost-%COMP%] > svg[_ngcontent-%COMP%]{height:10px;width:10px}[_nghost-%COMP%] > svg[_ngcontent-%COMP%] > line[_ngcontent-%COMP%]{stroke-width:2px;stroke:#fff}\"] });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(NgxDropzoneRemoveBadgeComponent, [{\n type: Component,\n args: [{\n selector: 'ngx-dropzone-remove-badge',\n template: `\n \n \n \n \n `,\n styles: [`:host(){display:flex;justify-content:center;align-items:center;height:22px;width:22px;position:absolute;top:5px;right:5px;border-radius:50%;background:#bbb;color:#333;cursor:pointer}:host():hover{background:#aeaeae}:host()>svg{height:10px;width:10px}:host()>svg>line{stroke-width:2px;stroke:#fff}`]\n }]\n }], null, null); })();\n\n/**\n * @fileoverview added by tsickle\n * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\nclass NgxDropzoneVideoPreviewComponent extends NgxDropzonePreviewComponent {\n /**\n * @param {?} sanitizer\n */\n constructor(sanitizer) {\n super(sanitizer);\n }\n /**\n * @return {?}\n */\n ngOnInit() {\n if (!this.file) {\n console.error('No file to read. Please provide a file using the [file] Input property.');\n return;\n }\n /**\n * We sanitize the URL here to enable the preview.\n * Please note that this could cause security issues!\n **/\n this.videoSrc = URL.createObjectURL(this.file);\n this.sanitizedVideoSrc = this.sanitizer.bypassSecurityTrustUrl(this.videoSrc);\n }\n /**\n * @return {?}\n */\n ngOnDestroy() {\n URL.revokeObjectURL(this.videoSrc);\n }\n}\nNgxDropzoneVideoPreviewComponent.ɵfac = function NgxDropzoneVideoPreviewComponent_Factory(t) { return new (t || NgxDropzoneVideoPreviewComponent)(ɵngcc0.ɵɵdirectiveInject(ɵngcc1.DomSanitizer)); };\nNgxDropzoneVideoPreviewComponent.ɵcmp = ɵngcc0.ɵɵdefineComponent({ type: NgxDropzoneVideoPreviewComponent, selectors: [[\"ngx-dropzone-video-preview\"]], features: [ɵngcc0.ɵɵProvidersFeature([\n {\n provide: NgxDropzonePreviewComponent,\n useExisting: NgxDropzoneVideoPreviewComponent\n }\n ]), ɵngcc0.ɵɵInheritDefinitionFeature], ngContentSelectors: _c1, decls: 3, vars: 2, consts: [[\"controls\", \"\", 3, \"click\", 4, \"ngIf\"], [3, \"click\", 4, \"ngIf\"], [\"controls\", \"\", 3, \"click\"], [3, \"src\"], [3, \"click\"]], template: function NgxDropzoneVideoPreviewComponent_Template(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵprojectionDef(_c0);\n ɵngcc0.ɵɵtemplate(0, NgxDropzoneVideoPreviewComponent_video_0_Template, 2, 1, \"video\", 0);\n ɵngcc0.ɵɵprojection(1);\n ɵngcc0.ɵɵtemplate(2, NgxDropzoneVideoPreviewComponent_ngx_dropzone_remove_badge_2_Template, 1, 0, \"ngx-dropzone-remove-badge\", 1);\n } if (rf & 2) {\n ɵngcc0.ɵɵproperty(\"ngIf\", ctx.sanitizedVideoSrc);\n ɵngcc0.ɵɵadvance(2);\n ɵngcc0.ɵɵproperty(\"ngIf\", ctx.removable);\n } }, directives: [ɵngcc2.NgIf, NgxDropzoneRemoveBadgeComponent], styles: [\"[_nghost-%COMP%]{min-width:unset!important;max-width:unset!important;padding:0!important}[_nghost-%COMP%]:focus video[_ngcontent-%COMP%], [_nghost-%COMP%]:hover video[_ngcontent-%COMP%]{opacity:.7}[_nghost-%COMP%]:focus ngx-dropzone-remove-badge[_ngcontent-%COMP%], [_nghost-%COMP%]:hover ngx-dropzone-remove-badge[_ngcontent-%COMP%]{opacity:1}[_nghost-%COMP%] ngx-dropzone-remove-badge[_ngcontent-%COMP%]{opacity:0}[_nghost-%COMP%] video[_ngcontent-%COMP%]{max-height:100%;border-radius:5px}[_nghost-%COMP%] ngx-dropzone-label{position:absolute;overflow-wrap:break-word}\"] });\n/** @nocollapse */\nNgxDropzoneVideoPreviewComponent.ctorParameters = () => [\n { type: DomSanitizer }\n];\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(NgxDropzoneVideoPreviewComponent, [{\n type: Component,\n args: [{\n selector: 'ngx-dropzone-video-preview',\n template: `\n \n \n \n \n\t`,\n styles: [`:host(){min-width:unset!important;max-width:unset!important;padding:0!important}:host():focus video,:host():hover video{opacity:.7}:host():focus ngx-dropzone-remove-badge,:host():hover ngx-dropzone-remove-badge{opacity:1}:host() ngx-dropzone-remove-badge{opacity:0}:host() video{max-height:100%;border-radius:5px}:host() ::ng-deep ngx-dropzone-label{position:absolute;overflow-wrap:break-word}`],\n providers: [\n {\n provide: NgxDropzonePreviewComponent,\n useExisting: NgxDropzoneVideoPreviewComponent\n }\n ]\n }]\n }], function () { return [{ type: ɵngcc1.DomSanitizer }]; }, null); })();\n\n/**\n * @fileoverview added by tsickle\n * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\nclass NgxDropzoneModule {\n}\nNgxDropzoneModule.ɵmod = ɵngcc0.ɵɵdefineNgModule({ type: NgxDropzoneModule });\nNgxDropzoneModule.ɵinj = ɵngcc0.ɵɵdefineInjector({ factory: function NgxDropzoneModule_Factory(t) { return new (t || NgxDropzoneModule)(); }, imports: [[\n CommonModule\n ]] });\n(function () { (typeof ngJitMode === \"undefined\" || ngJitMode) && ɵngcc0.ɵɵsetNgModuleScope(NgxDropzoneModule, { declarations: function () { return [NgxDropzoneComponent, NgxDropzoneLabelDirective, NgxDropzonePreviewComponent, NgxDropzoneImagePreviewComponent, NgxDropzoneRemoveBadgeComponent, NgxDropzoneVideoPreviewComponent]; }, imports: function () { return [CommonModule]; }, exports: function () { return [NgxDropzoneComponent, NgxDropzoneLabelDirective, NgxDropzonePreviewComponent, NgxDropzoneImagePreviewComponent, NgxDropzoneRemoveBadgeComponent, NgxDropzoneVideoPreviewComponent]; } }); })();\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(NgxDropzoneModule, [{\n type: NgModule,\n args: [{\n imports: [\n CommonModule\n ],\n declarations: [\n NgxDropzoneComponent,\n NgxDropzoneLabelDirective,\n NgxDropzonePreviewComponent,\n NgxDropzoneImagePreviewComponent,\n NgxDropzoneRemoveBadgeComponent,\n NgxDropzoneVideoPreviewComponent,\n ],\n exports: [\n NgxDropzoneComponent,\n NgxDropzoneLabelDirective,\n NgxDropzonePreviewComponent,\n NgxDropzoneImagePreviewComponent,\n NgxDropzoneRemoveBadgeComponent,\n NgxDropzoneVideoPreviewComponent,\n ]\n }]\n }], null, null); })();\n\n/**\n * @fileoverview added by tsickle\n * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\n\n/**\n * @fileoverview added by tsickle\n * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\n */\n\nexport { NgxDropzoneModule, NgxDropzoneComponent, NgxDropzonePreviewComponent, NgxDropzoneImagePreviewComponent, NgxDropzoneVideoPreviewComponent, NgxDropzoneRemoveBadgeComponent, NgxDropzoneLabelDirective as ɵb, NgxDropzoneService as ɵa };\n\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibmd4LWRyb3B6b25lLmpzIiwic291cmNlcyI6WyJuZ3gtZHJ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LFxuXHRcdE5neERyb3B6b25lVmlkZW9QcmV2aWV3Q29tcG9uZW50LFxuXHRdXG59KVxuZXhwb3J0IGNsYXNzIE5neERyb3B6b25lTW9kdWxlIHsgfVxuIl19","\n\n\n\n","\n\t\t\n\t\t\n\t\t\n\t","\n \n \n \n \n ","import { Component, OnInit } from '@angular/core';\r\n//import { HttpClient } from '@angular/common/http';\r\nimport { FileUploadService } from '../../../shared/upload.service'\r\nimport { AlertService } from '../../../shared/components/alert/alert.service'\r\nimport { FormControl, FormGroup, Validators } from '@angular/forms';\r\nimport { List } from 'src/app/shared/interface';\r\nimport { NaomitsuService } from '../../../shared/databaseService'\r\nimport { DialogService } from '../../../shared/dialog.service';\r\nimport { Router } from '@angular/router';\r\nimport { Ng2ImgMaxService } from 'ng2-img-max';\r\nimport { base64ToFile } from 'ngx-image-cropper';\r\nimport { TokenStorageService } from 'src/app/_services/token-storage.service';\r\nimport { async } from '@angular/core/testing';\r\nimport { globalconstants } from 'src/app/shared/globalconstant';\r\n@Component({\r\n selector: 'app-file-drag-and-drop',\r\n templateUrl: './imgDragAndDrop.html',\r\n styleUrls: ['./imgDragAndDrop.scss'],\r\n //providers:[Ng2ImgMaxModule,Ng2ImgMaxService]\r\n})\r\nexport class ImgDragAndDropComponent implements OnInit {\r\n options = {\r\n autoClose: false,\r\n keepAfterRouteChange: true\r\n };\r\n Processing=false;\r\n Albums: any[];\r\n title = 'Dropzone';\r\n files: File[] = [];\r\n formData: FormData;\r\n uploadedImage: File;\r\n errorMessage = '';\r\n Requestsize = 0;\r\n constructor(\r\n private naomitsuService: NaomitsuService,\r\n private alert: AlertService,\r\n private uploadService: FileUploadService,\r\n private dialog: DialogService,\r\n private route: Router,\r\n private ng2ImgMax: Ng2ImgMaxService,\r\n private tokenStorage: TokenStorageService\r\n ) { }\r\n dragdropForm = new FormGroup({\r\n UpdatedFileFolderName: new FormControl(''),\r\n parentId: new FormControl(0),\r\n\r\n });\r\n ngOnInit() {\r\n this.checklogin();\r\n this.getAlbums();\r\n }\r\n checklogin() {\r\n let options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n let token = this.tokenStorage.getToken();\r\n\r\n if (token == null) {\r\n this.alert.error(\"Access denied! login required.\", options);\r\n this.route.navigate(['/home']);\r\n }\r\n }\r\n onSelect(event) {\r\n debugger;\r\n this.files.push(...event.addedFiles);\r\n\r\n this.formData = new FormData();\r\n this.errorMessage = '';\r\n this.Processing =true;\r\n let resultCount=0;\r\n for (var i = 0; i < this.files.length; i++) {\r\n this.Requestsize += this.files[i].size;\r\n if (this.Requestsize + this.files[i].size > globalconstants.RequestLimit) {\r\n this.alert.error('File upload limit is 20mb!', this.options);\r\n this.alert.info('File size is : ' + (this.Requestsize/(1024*1024)).toFixed(2) + 'mb' )\r\n break;\r\n }\r\n this.ng2ImgMax.resizeImage(this.files[i], 2500, 1000)\r\n .subscribe(result => {\r\n resultCount +=1;\r\n this.uploadedImage = result;\r\n this.formData.append(result.name, this.uploadedImage, result.name);\r\n if(resultCount+1 >= this.files.length)\r\n {\r\n this.Processing =false;\r\n }\r\n },\r\n error => {\r\n this.Processing =false;\r\n this.alert.error(error.reason,this.options);\r\n //this.files.splice(i,1);\r\n this.errorMessage += error.reason;\r\n //console.log('error:', error);\r\n })\r\n }\r\n \r\n console.log('request', this.Requestsize)\r\n }\r\n onImageChange(event) {\r\n let image = event.target.files[0];\r\n\r\n this.ng2ImgMax.compressImage(image, 0.075).subscribe(\r\n result => {\r\n this.uploadedImage = new File([result], result.name);\r\n //this.getImagePreview(this.uploadedImage);\r\n },\r\n error => {\r\n console.log('😢 Oh no!', error);\r\n }\r\n );\r\n }\r\n Upload() {\r\n debugger;\r\n if (this.Requestsize > globalconstants.RequestLimit) {\r\n this.alert.error(\"File upload limit is 20mb!\", this.options);\r\n return;\r\n }\r\n if (this.files.length > 15) {\r\n this.alert.error(\"File count exceeded the maximum of 15\");\r\n return;\r\n }\r\n else if (this.errorMessage.length > 0) {\r\n return;\r\n }\r\n let error: boolean = false;\r\n let selectedAlbum = this.dragdropForm.get(\"UpdatedFileFolderName\").value;\r\n let selectedAlbumId = this.dragdropForm.get(\"parentId\").value;\r\n if (this.files.length < 1) {\r\n error = true;\r\n this.alert.warn(\"No image to upload\", this.options);\r\n }\r\n\r\n if (selectedAlbum == '' && selectedAlbumId == 0) {\r\n error = true;\r\n this.alert.error(\"Please enter album or existing album\", this.options);\r\n }\r\n else {\r\n if (selectedAlbumId != 0) {\r\n selectedAlbum = this.Albums.filter(item => item.FileId == selectedAlbumId)[0].UpdatedFileFolderName;\r\n }\r\n this.formData.append(\"fileOrPhoto\", \"1\");\r\n this.formData.append(\"description\", \"\");\r\n this.formData.append(\"folderName\", selectedAlbum);\r\n this.formData.append(\"parentId\", selectedAlbumId);\r\n //console.log('formdata',this.formData);\r\n let filteredAlbum: any[] = [];\r\n if (this.Albums.length > 0) {\r\n filteredAlbum = this.Albums.filter(item => {\r\n return item.UpdatedFolder == selectedAlbum\r\n }\r\n );\r\n }\r\n this.uploadFile();\r\n\r\n }\r\n }\r\n uploadFile() {\r\n let options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n this.uploadService.postFiles(this.formData).subscribe(res => {\r\n //console.log(\"Upload complete\");\r\n this.alert.success(\"Files Uploaded successfully.\", options);\r\n this.formData = null;\r\n this.files = [];\r\n this.getAlbums();\r\n this.route.navigate(['/home/managefile']);\r\n //this.messages.push(\"Upload complete\");\r\n //album.value=null;\r\n //image.value =null;\r\n });\r\n }\r\n onRemove(event) {\r\n\r\n this.files.splice(this.files.indexOf(event), 1);\r\n this.Requestsize -= event.size;\r\n this.alert.info('File size: ' + (this.Requestsize/(1024*1024)).toFixed(2) + 'mb', this.options);\r\n\r\n }\r\n\r\n getAlbums() {\r\n let list: List = new List();\r\n list.fields = [\"FileId\", \"UpdatedFileFolderName\"];\r\n list.PageName = \"FilesNPhotoes\";\r\n list.filter = [\"Active eq 1 and FileOrFolder eq 1 and FileOrPhoto eq 1\"];\r\n debugger;\r\n this.naomitsuService.get(list)\r\n .subscribe((data: any) => {\r\n if (data.value.length > 0) {\r\n this.Albums = [...data.value];\r\n }\r\n else\r\n this.Albums = [];\r\n });\r\n }\r\n\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport * as exifr from 'exifr/dist/mini.legacy.umd';\r\nimport * as ɵngcc0 from '@angular/core';\nvar ImgExifService = /** @class */ (function () {\r\n function ImgExifService() {\r\n }\r\n ImgExifService.prototype.getOrientedImage = function (image) {\r\n return new Promise(function (resolve) {\r\n var img;\r\n exifr.orientation(image).catch(function (err) { return undefined; }).then(function (orientation) {\r\n if (orientation != 1) {\r\n var canvas = document.createElement(\"canvas\"), ctx = canvas.getContext(\"2d\"), cw = image.width, ch = image.height, cx = 0, cy = 0, deg = 0;\r\n switch (orientation) {\r\n case 3:\r\n case 4:\r\n cx = -image.width;\r\n cy = -image.height;\r\n deg = 180;\r\n break;\r\n case 5:\r\n case 6:\r\n cw = image.height;\r\n ch = image.width;\r\n cy = -image.height;\r\n deg = 90;\r\n break;\r\n case 7:\r\n case 8:\r\n cw = image.height;\r\n ch = image.width;\r\n cx = -image.width;\r\n deg = 270;\r\n break;\r\n default:\r\n break;\r\n }\r\n canvas.width = cw;\r\n canvas.height = ch;\r\n if ([2, 4, 5, 7].indexOf(orientation) > -1) {\r\n //flip image\r\n ctx.translate(cw, 0);\r\n ctx.scale(-1, 1);\r\n }\r\n ctx.rotate(deg * Math.PI / 180);\r\n ctx.drawImage(image, cx, cy);\r\n img = document.createElement(\"img\");\r\n img.width = cw;\r\n img.height = ch;\r\n img.addEventListener('load', function () {\r\n resolve(img);\r\n });\r\n img.src = canvas.toDataURL(\"image/png\");\r\n }\r\n else {\r\n resolve(image);\r\n }\r\n });\r\n });\r\n };\nImgExifService.ɵfac = function ImgExifService_Factory(t) { return new (t || ImgExifService)(); };\nImgExifService.ɵprov = ɵngcc0.ɵɵdefineInjectable({ token: ImgExifService, factory: function (t) { return ImgExifService.ɵfac(t); } });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(ImgExifService, [{\n type: Injectable\n }], function () { return []; }, null); })();\r\n return ImgExifService;\r\n}());\r\nexport { ImgExifService };\r\n\n//# sourceMappingURL=img-exif.service.js.map","import { Injectable, Inject, forwardRef } from '@angular/core';\r\nimport { Subject } from 'rxjs';\r\nimport { ImgExifService } from './img-exif.service';\r\nimport * as ɵngcc0 from '@angular/core';\nimport * as ɵngcc1 from './img-exif.service';\nvar MAX_STEPS = 15;\r\nvar ImgMaxSizeService = /** @class */ (function () {\r\n function ImgMaxSizeService(imageExifService) {\r\n this.imageExifService = imageExifService;\r\n }\r\n ImgMaxSizeService.prototype.compressImage = function (file, maxSizeInMB, ignoreAlpha, logExecutionTime) {\r\n var _this = this;\r\n if (ignoreAlpha === void 0) { ignoreAlpha = false; }\r\n if (logExecutionTime === void 0) { logExecutionTime = false; }\r\n var compressedFileSubject = new Subject();\r\n this.timeAtStart = new Date().getTime();\r\n this.initialFile = file;\r\n if (file.type !== \"image/jpeg\" && file.type !== \"image/png\") {\r\n //END OF COMPRESSION\r\n setTimeout(function () {\r\n compressedFileSubject.error({ compressedFile: file, reason: \"File provided is neither of type jpg nor of type png.\", error: \"INVALID_EXTENSION\" });\r\n }, 0);\r\n return compressedFileSubject.asObservable();\r\n }\r\n var oldFileSize = file.size / 1024 / 1024;\r\n if (oldFileSize < maxSizeInMB) {\r\n // END OF COMPRESSION\r\n // FILE SIZE ALREADY BELOW MAX_SIZE -> no compression needed\r\n setTimeout(function () { compressedFileSubject.next(file); }, 0);\r\n return compressedFileSubject.asObservable();\r\n }\r\n var cvs = document.createElement('canvas');\r\n var ctx = cvs.getContext('2d');\r\n var img = new Image();\r\n var self = this;\r\n img.onload = function () {\r\n _this.imageExifService.getOrientedImage(img).then(function (orientedImg) {\r\n window.URL.revokeObjectURL(img.src);\r\n cvs.width = orientedImg.width;\r\n cvs.height = orientedImg.height;\r\n ctx.drawImage(orientedImg, 0, 0);\r\n var imageData = ctx.getImageData(0, 0, orientedImg.width, orientedImg.height);\r\n if (file.type === \"image/png\" && _this.isImgUsingAlpha(imageData) && !ignoreAlpha) {\r\n //png image with alpha\r\n compressedFileSubject.error({ compressedFile: file, reason: \"File provided is a png image which uses the alpha channel. No compression possible.\", error: \"PNG_WITH_ALPHA\" });\r\n }\r\n ctx = cvs.getContext('2d', { 'alpha': false });\r\n ctx.drawImage(orientedImg, 0, 0);\r\n self.getCompressedFile(cvs, 50, maxSizeInMB, 1).then(function (compressedFile) {\r\n compressedFileSubject.next(compressedFile);\r\n self.logExecutionTime(logExecutionTime);\r\n }).catch(function (error) {\r\n compressedFileSubject.error(error);\r\n self.logExecutionTime(logExecutionTime);\r\n });\r\n });\r\n };\r\n img.src = window.URL.createObjectURL(file);\r\n return compressedFileSubject.asObservable();\r\n };\r\n ;\r\n ImgMaxSizeService.prototype.getCompressedFile = function (cvs, quality, maxSizeInMB, currentStep) {\r\n var _this = this;\r\n var result = new Promise(function (resolve, reject) {\r\n cvs.toBlob(function (blob) {\r\n if (currentStep + 1 > MAX_STEPS) {\r\n //COMPRESSION END\r\n //maximal steps reached\r\n reject({ compressedFile: _this.getResultFile(blob), reason: \"Could not find the correct compression quality in \" + MAX_STEPS + \" steps.\", error: \"MAX_STEPS_EXCEEDED\" });\r\n }\r\n else {\r\n var newQuality = _this.getCalculatedQuality(blob, quality, maxSizeInMB, currentStep);\r\n _this.checkCompressionStatus(cvs, blob, quality, maxSizeInMB, currentStep, newQuality)\r\n .then(function (result) {\r\n resolve(result);\r\n })\r\n .catch(function (result) {\r\n reject(result);\r\n });\r\n }\r\n }, \"image/jpeg\", quality / 100);\r\n });\r\n return result;\r\n };\r\n ImgMaxSizeService.prototype.getResultFile = function (blob) {\r\n return this.generateResultFile(blob, this.initialFile.name, this.initialFile.type, new Date().getTime());\r\n };\r\n ImgMaxSizeService.prototype.generateResultFile = function (blob, name, type, lastModified) {\r\n var resultFile = new Blob([blob], { type: type });\r\n return this.blobToFile(resultFile, name, lastModified);\r\n };\r\n ImgMaxSizeService.prototype.blobToFile = function (blob, name, lastModified) {\r\n var file = blob;\r\n file.name = name;\r\n file.lastModified = lastModified;\r\n //Cast to a File() type\r\n return file;\r\n };\r\n ImgMaxSizeService.prototype.getCalculatedQuality = function (blob, quality, maxSizeInMB, currentStep) {\r\n //CALCULATE NEW QUALITY\r\n var currentSize = blob.size / 1024 / 1024;\r\n var ratioMaxSizeToCurrentSize = maxSizeInMB / currentSize;\r\n if (ratioMaxSizeToCurrentSize > 5) {\r\n //max ratio to avoid extreme quality values\r\n ratioMaxSizeToCurrentSize = 5;\r\n }\r\n var ratioMaxSizeToInitialSize = currentSize / (this.initialFile.size / 1024 / 1024);\r\n if (ratioMaxSizeToInitialSize < 0.05) {\r\n //min ratio to avoid extreme quality values\r\n ratioMaxSizeToInitialSize = 0.05;\r\n }\r\n var newQuality = 0;\r\n var multiplicator = Math.abs(ratioMaxSizeToInitialSize - 1) * 10 / (currentStep * 1.7) / ratioMaxSizeToCurrentSize;\r\n if (multiplicator < 1) {\r\n multiplicator = 1;\r\n }\r\n if (ratioMaxSizeToCurrentSize >= 1) {\r\n newQuality = quality + (ratioMaxSizeToCurrentSize - 1) * 10 * multiplicator;\r\n }\r\n else {\r\n newQuality = quality - (1 - ratioMaxSizeToCurrentSize) * 10 * multiplicator;\r\n }\r\n if (newQuality > 100) {\r\n //max quality = 100, so let's set the new quality to the value in between the old quality and 100 in case of > 100\r\n newQuality = quality + (100 - quality) / 2;\r\n }\r\n if (newQuality < 0) {\r\n //min quality = 0, so let's set the new quality to the value in between the old quality and 0 in case of < 0\r\n newQuality = quality - quality / 2;\r\n }\r\n return newQuality;\r\n };\r\n ImgMaxSizeService.prototype.checkCompressionStatus = function (cvs, blob, quality, maxSizeInMB, currentStep, newQuality) {\r\n var _this = this;\r\n var result = new Promise(function (resolve, reject) {\r\n if (quality === 100 && newQuality >= 100) {\r\n //COMPRESSION END\r\n //Seems like quality 100 is max but file still too small, case that shouldn't exist as the compression shouldn't even have started in the first place\r\n reject({ compressedFile: _this.initialFile, reason: \"Unfortunately there was an error while compressing the file.\", error: \"FILE_BIGGER_THAN_INITIAL_FILE\" });\r\n }\r\n else if ((quality < 1) && (newQuality < quality)) {\r\n //COMPRESSION END\r\n //File size still too big but can't compress further than quality=0\r\n reject({ compressedFile: _this.getResultFile(blob), reason: \"Could not compress image enough to fit the maximal file size limit.\", error: \"UNABLE_TO_COMPRESS_ENOUGH\" });\r\n }\r\n else if ((newQuality > quality) && (Math.round(quality) == Math.round(newQuality))) {\r\n //COMPRESSION END\r\n //next steps quality would be the same quality but newQuality is slightly bigger than old one, means we most likely found the nearest quality to compress to maximal size\r\n resolve(_this.getResultFile(blob));\r\n }\r\n else if (currentStep > 5 && (newQuality > quality) && (newQuality < quality + 2)) {\r\n //COMPRESSION END\r\n //for some rare occasions the algorithm might be stuck around e.g. 98.5 and 97.4 because of the maxQuality of 100, the current quality is the nearest possible quality in that case\r\n resolve(_this.getResultFile(blob));\r\n }\r\n else if ((newQuality > quality) && Number.isInteger(quality) && (Math.floor(newQuality) == quality)) {\r\n //COMPRESSION END\r\n /*\r\n in the previous step if ((quality > newQuality) && (Math.round(quality) == Math.round(newQuality))) applied, so\r\n newQuality = Math.round(newQuality) - 1; this was done to reduce the quality at least a full integer down to not waste a step\r\n with the same compression rate quality as before. Now, the newQuality is still only in between the old quality (e.g. 93)\r\n and the newQuality (e.g. 94) which most likely means that the value for the newQuality (the bigger one) would make the filesize\r\n too big so we should just stick with the current, lower quality and return that file.\r\n */\r\n resolve(_this.getResultFile(blob));\r\n }\r\n else {\r\n //CONTINUE COMPRESSION\r\n if ((quality > newQuality) && (Math.round(quality) == Math.round(newQuality))) {\r\n //quality can only be an integer -> make sure difference between old quality and new one is at least a whole integer number\r\n // - it would be nonsense to compress again with the same quality\r\n newQuality = Math.round(newQuality) - 1;\r\n }\r\n //recursively call function again\r\n resolve(_this.getCompressedFile(cvs, newQuality, maxSizeInMB, currentStep + 1));\r\n }\r\n });\r\n return result;\r\n };\r\n ImgMaxSizeService.prototype.isImgUsingAlpha = function (imageData) {\r\n for (var i = 0; i < imageData.data.length; i += 4) {\r\n if (imageData.data[i + 3] !== 255) {\r\n return true;\r\n }\r\n }\r\n return false;\r\n };\r\n ImgMaxSizeService.prototype.logExecutionTime = function (logExecutionTime) {\r\n if (logExecutionTime) {\r\n console.info(\"Execution time: \", new Date().getTime() - this.timeAtStart + \"ms\");\r\n }\r\n };\r\n /** @nocollapse */\r\n ImgMaxSizeService.ctorParameters = function () { return [\r\n { type: ImgExifService, decorators: [{ type: Inject, args: [forwardRef(function () { return ImgExifService; }),] }] }\r\n ]; };\nImgMaxSizeService.ɵfac = function ImgMaxSizeService_Factory(t) { return new (t || ImgMaxSizeService)(ɵngcc0.ɵɵinject(forwardRef(function () { return ImgExifService; }))); };\nImgMaxSizeService.ɵprov = ɵngcc0.ɵɵdefineInjectable({ token: ImgMaxSizeService, factory: function (t) { return ImgMaxSizeService.ɵfac(t); } });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(ImgMaxSizeService, [{\n type: Injectable\n }], function () { return [{ type: ɵngcc1.ImgExifService, decorators: [{\n type: Inject,\n args: [forwardRef(function () { return ImgExifService; })]\n }] }]; }, null); })();\r\n return ImgMaxSizeService;\r\n}());\r\nexport { ImgMaxSizeService };\r\n\n//# sourceMappingURL=img-max-size.service.js.map","import { Injectable } from '@angular/core';\r\nimport * as exifr from 'exifr/dist/mini.legacy.umd';\r\nimport * as ɵngcc0 from '@angular/core';\nvar ImgExifService = /** @class */ (function () {\r\n function ImgExifService() {\r\n }\r\n ImgExifService.prototype.getOrientedImage = function (image) {\r\n return new Promise(function (resolve) {\r\n var img;\r\n exifr.orientation(image).catch(function (err) { return undefined; }).then(function (orientation) {\r\n if (orientation != 1) {\r\n var canvas = document.createElement(\"canvas\"), ctx = canvas.getContext(\"2d\"), cw = image.width, ch = image.height, cx = 0, cy = 0, deg = 0;\r\n switch (orientation) {\r\n case 3:\r\n case 4:\r\n cx = -image.width;\r\n cy = -image.height;\r\n deg = 180;\r\n break;\r\n case 5:\r\n case 6:\r\n cw = image.height;\r\n ch = image.width;\r\n cy = -image.height;\r\n deg = 90;\r\n break;\r\n case 7:\r\n case 8:\r\n cw = image.height;\r\n ch = image.width;\r\n cx = -image.width;\r\n deg = 270;\r\n break;\r\n default:\r\n break;\r\n }\r\n canvas.width = cw;\r\n canvas.height = ch;\r\n if ([2, 4, 5, 7].indexOf(orientation) > -1) {\r\n //flip image\r\n ctx.translate(cw, 0);\r\n ctx.scale(-1, 1);\r\n }\r\n ctx.rotate(deg * Math.PI / 180);\r\n ctx.drawImage(image, cx, cy);\r\n img = document.createElement(\"img\");\r\n img.width = cw;\r\n img.height = ch;\r\n img.addEventListener('load', function () {\r\n resolve(img);\r\n });\r\n img.src = canvas.toDataURL(\"image/png\");\r\n }\r\n else {\r\n resolve(image);\r\n }\r\n });\r\n });\r\n };\nImgExifService.ɵfac = function ImgExifService_Factory(t) { return new (t || ImgExifService)(); };\nImgExifService.ɵprov = ɵngcc0.ɵɵdefineInjectable({ token: ImgExifService, factory: function (t) { return ImgExifService.ɵfac(t); } });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(ImgExifService, [{\n type: Injectable\n }], function () { return []; }, null); })();\r\n return ImgExifService;\r\n}());\r\nexport { ImgExifService };\r\n\n//# sourceMappingURL=img-exif.service.js.map","import { Injectable, Inject, forwardRef } from '@angular/core';\r\nimport { Subject } from 'rxjs';\r\nimport pica from 'pica/dist/pica';\r\nimport { ImgExifService } from './img-exif.service';\r\nimport * as ɵngcc0 from '@angular/core';\nimport * as ɵngcc1 from './img-exif.service';\nvar Ng2PicaService = /** @class */ (function () {\r\n function Ng2PicaService(imageExifService) {\r\n this.imageExifService = imageExifService;\r\n }\r\n Ng2PicaService.prototype.resize = function (files, width, height, keepAspectRatio) {\r\n if (keepAspectRatio === void 0) { keepAspectRatio = false; }\r\n var resizedFile = new Subject();\r\n for (var i = 0; i < files.length; i++) {\r\n this.resizeFile(files[i], width, height, keepAspectRatio).then(function (returnedFile) {\r\n resizedFile.next(returnedFile);\r\n }).catch(function (error) {\r\n resizedFile.error(error);\r\n });\r\n }\r\n return resizedFile.asObservable();\r\n };\r\n Ng2PicaService.prototype.resizeCanvas = function (from, to, options) {\r\n var result = new Promise(function (resolve, reject) {\r\n var curPica = new pica();\r\n if (!curPica || !curPica.resize) {\r\n curPica = new window.pica();\r\n }\r\n curPica.resize(from, to, options)\r\n .then(function (response) {\r\n resolve(response);\r\n }, function (error) {\r\n reject(error);\r\n });\r\n });\r\n return result;\r\n };\r\n Ng2PicaService.prototype.resizeBuffer = function (options) {\r\n var result = new Promise(function (resolve, reject) {\r\n var curPica = new pica();\r\n if (!curPica || !curPica.resizeBuffer) {\r\n curPica = new window.pica();\r\n }\r\n curPica.resizeBuffer(options)\r\n .then(function (response) {\r\n resolve(response);\r\n }, function (error) {\r\n reject(error);\r\n });\r\n });\r\n return result;\r\n };\r\n Ng2PicaService.prototype.resizeFile = function (file, width, height, keepAspectRatio) {\r\n var _this = this;\r\n if (keepAspectRatio === void 0) { keepAspectRatio = false; }\r\n var result = new Promise(function (resolve, reject) {\r\n var fromCanvas = document.createElement('canvas');\r\n var ctx = fromCanvas.getContext('2d');\r\n var img = new Image();\r\n img.onload = function () {\r\n _this.imageExifService.getOrientedImage(img).then(function (orientedImg) {\r\n window.URL.revokeObjectURL(img.src);\r\n fromCanvas.width = orientedImg.width;\r\n fromCanvas.height = orientedImg.height;\r\n ctx.drawImage(orientedImg, 0, 0);\r\n var imageData = ctx.getImageData(0, 0, orientedImg.width, orientedImg.height);\r\n if (keepAspectRatio) {\r\n var ratio = Math.min(width / imageData.width, height / imageData.height);\r\n width = Math.round(imageData.width * ratio);\r\n height = Math.round(imageData.height * ratio);\r\n }\r\n var useAlpha = true;\r\n if (file.type === \"image/jpeg\" || (file.type === \"image/png\" && !_this.isImgUsingAlpha(imageData))) {\r\n //image without alpha\r\n useAlpha = false;\r\n ctx = fromCanvas.getContext('2d', { 'alpha': false });\r\n ctx.drawImage(orientedImg, 0, 0);\r\n }\r\n var toCanvas = document.createElement('canvas');\r\n toCanvas.width = width;\r\n toCanvas.height = height;\r\n _this.resizeCanvas(fromCanvas, toCanvas, { 'alpha': useAlpha })\r\n .then(function (resizedCanvas) {\r\n resizedCanvas.toBlob(function (blob) {\r\n var newFile = _this.generateResultFile(blob, file.name, file.type, new Date().getTime());\r\n resolve(newFile);\r\n }, file.type);\r\n })\r\n .catch(function (error) {\r\n reject(error);\r\n });\r\n });\r\n };\r\n img.src = window.URL.createObjectURL(file);\r\n });\r\n return result;\r\n };\r\n Ng2PicaService.prototype.isImgUsingAlpha = function (imageData) {\r\n for (var i = 0; i < imageData.data.length; i += 4) {\r\n if (imageData.data[i + 3] !== 255) {\r\n return true;\r\n }\r\n }\r\n return false;\r\n };\r\n Ng2PicaService.prototype.generateResultFile = function (blob, name, type, lastModified) {\r\n var resultFile = new Blob([blob], { type: type });\r\n return this.blobToFile(resultFile, name, lastModified);\r\n };\r\n Ng2PicaService.prototype.blobToFile = function (blob, name, lastModified) {\r\n var file = blob;\r\n file.name = name;\r\n file.lastModified = lastModified;\r\n //Cast to a File() type\r\n return file;\r\n };\r\n /** @nocollapse */\r\n Ng2PicaService.ctorParameters = function () { return [\r\n { type: ImgExifService, decorators: [{ type: Inject, args: [forwardRef(function () { return ImgExifService; }),] }] }\r\n ]; };\nNg2PicaService.ɵfac = function Ng2PicaService_Factory(t) { return new (t || Ng2PicaService)(ɵngcc0.ɵɵinject(forwardRef(function () { return ImgExifService; }))); };\nNg2PicaService.ɵprov = ɵngcc0.ɵɵdefineInjectable({ token: Ng2PicaService, factory: function (t) { return Ng2PicaService.ɵfac(t); } });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(Ng2PicaService, [{\n type: Injectable\n }], function () { return [{ type: ɵngcc1.ImgExifService, decorators: [{\n type: Inject,\n args: [forwardRef(function () { return ImgExifService; })]\n }] }]; }, null); })();\r\n return Ng2PicaService;\r\n}());\r\nexport { Ng2PicaService };\r\n\n//# sourceMappingURL=ng2-pica.service.js.map","import { NgModule } from \"@angular/core\";\r\nimport { Ng2PicaService } from \"./ng2-pica.service\";\r\nimport { ImgExifService } from \"./img-exif.service\";\r\nimport * as ɵngcc0 from '@angular/core';\nvar Ng2PicaModule = /** @class */ (function () {\r\n function Ng2PicaModule() {\r\n }\nNg2PicaModule.ɵmod = ɵngcc0.ɵɵdefineNgModule({ type: Ng2PicaModule });\nNg2PicaModule.ɵinj = ɵngcc0.ɵɵdefineInjector({ factory: function Ng2PicaModule_Factory(t) { return new (t || Ng2PicaModule)(); }, providers: [\n { provide: Ng2PicaService, useClass: Ng2PicaService },\n { provide: ImgExifService, useClass: ImgExifService }\n ] });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(Ng2PicaModule, [{\n type: NgModule,\n args: [{\n providers: [\n { provide: Ng2PicaService, useClass: Ng2PicaService },\n { provide: ImgExifService, useClass: ImgExifService }\n ]\n }]\n }], function () { return []; }, null); })();\r\n return Ng2PicaModule;\r\n}());\r\nexport { Ng2PicaModule };\r\n\n//# sourceMappingURL=ng2-pica.module.js.map","import { Injectable, Inject, forwardRef } from '@angular/core';\r\nimport { Subject } from 'rxjs';\r\nimport { Ng2PicaService } from 'ng2-pica';\r\nimport { ImgExifService } from './img-exif.service';\r\nimport * as ɵngcc0 from '@angular/core';\nimport * as ɵngcc1 from 'ng2-pica';\nimport * as ɵngcc2 from './img-exif.service';\nvar ImgMaxPXSizeService = /** @class */ (function () {\r\n function ImgMaxPXSizeService(ng2PicaService, imageExifService) {\r\n this.ng2PicaService = ng2PicaService;\r\n this.imageExifService = imageExifService;\r\n }\r\n ImgMaxPXSizeService.prototype.resizeImage = function (file, maxWidth, maxHeight, logExecutionTime) {\r\n var _this = this;\r\n if (logExecutionTime === void 0) { logExecutionTime = false; }\r\n var resizedFileSubject = new Subject();\r\n this.timeAtStart = new Date().getTime();\r\n if (file.type !== \"image/jpeg\" && file.type !== \"image/png\") {\r\n //END OF RESIZE\r\n setTimeout(function () {\r\n resizedFileSubject.error({ resizedFile: file, reason: \"The provided File is neither of type jpg nor of type png.\", error: \"INVALID_EXTENSION\" });\r\n }, 0);\r\n return resizedFileSubject.asObservable();\r\n }\r\n var img = new Image();\r\n var self = this;\r\n img.onload = function () {\r\n _this.imageExifService.getOrientedImage(img).then(function (orientedImg) {\r\n window.URL.revokeObjectURL(img.src);\r\n var currentWidth = orientedImg.width;\r\n var currentHeight = orientedImg.height;\r\n var newWidth = currentWidth;\r\n var newHeight = currentHeight;\r\n if (newWidth > maxWidth) {\r\n newWidth = maxWidth;\r\n //resize height proportionally\r\n var ratio = maxWidth / currentWidth; //is gonna be <1\r\n newHeight = newHeight * ratio;\r\n }\r\n currentHeight = newHeight;\r\n if (newHeight > maxHeight) {\r\n newHeight = maxHeight;\r\n //resize width proportionally\r\n var ratio = maxHeight / currentHeight; //is gonna be <1\r\n newWidth = newWidth * ratio;\r\n }\r\n if (newHeight === orientedImg.height && newWidth === orientedImg.width) {\r\n //no resizing necessary\r\n resizedFileSubject.next(file);\r\n self.logExecutionTime(logExecutionTime);\r\n }\r\n else {\r\n self.ng2PicaService.resize([file], newWidth, newHeight).subscribe(function (result) {\r\n //all good, result is a file\r\n resizedFileSubject.next(result);\r\n self.logExecutionTime(logExecutionTime);\r\n }, function (error) {\r\n //something went wrong \r\n resizedFileSubject.error({ resizedFile: file, reason: error, error: \"PICA_ERROR\" });\r\n self.logExecutionTime(logExecutionTime);\r\n });\r\n }\r\n });\r\n };\r\n img.src = window.URL.createObjectURL(file);\r\n return resizedFileSubject.asObservable();\r\n };\r\n ;\r\n ImgMaxPXSizeService.prototype.logExecutionTime = function (logExecutionTime) {\r\n if (logExecutionTime) {\r\n console.info(\"Execution time: \", new Date().getTime() - this.timeAtStart + \"ms\");\r\n }\r\n };\r\n /** @nocollapse */\r\n ImgMaxPXSizeService.ctorParameters = function () { return [\r\n { type: Ng2PicaService, decorators: [{ type: Inject, args: [forwardRef(function () { return Ng2PicaService; }),] }] },\r\n { type: ImgExifService, decorators: [{ type: Inject, args: [forwardRef(function () { return ImgExifService; }),] }] }\r\n ]; };\nImgMaxPXSizeService.ɵfac = function ImgMaxPXSizeService_Factory(t) { return new (t || ImgMaxPXSizeService)(ɵngcc0.ɵɵinject(forwardRef(function () { return Ng2PicaService; })), ɵngcc0.ɵɵinject(forwardRef(function () { return ImgExifService; }))); };\nImgMaxPXSizeService.ɵprov = ɵngcc0.ɵɵdefineInjectable({ token: ImgMaxPXSizeService, factory: function (t) { return ImgMaxPXSizeService.ɵfac(t); } });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(ImgMaxPXSizeService, [{\n type: Injectable\n }], function () { return [{ type: ɵngcc1.Ng2PicaService, decorators: [{\n type: Inject,\n args: [forwardRef(function () { return Ng2PicaService; })]\n }] }, { type: ɵngcc2.ImgExifService, decorators: [{\n type: Inject,\n args: [forwardRef(function () { return ImgExifService; })]\n }] }]; }, null); })();\r\n return ImgMaxPXSizeService;\r\n}());\r\nexport { ImgMaxPXSizeService };\r\n\n//# sourceMappingURL=img-maxpx-size.service.js.map","import { Injectable, Inject, forwardRef } from '@angular/core';\r\nimport { Subject } from 'rxjs';\r\nimport { ImgMaxSizeService } from './img-max-size.service';\r\nimport { ImgMaxPXSizeService } from './img-maxpx-size.service';\r\nimport { ImgExifService } from './img-exif.service';\r\nimport * as ɵngcc0 from '@angular/core';\nimport * as ɵngcc1 from './img-max-size.service';\nimport * as ɵngcc2 from './img-maxpx-size.service';\nimport * as ɵngcc3 from './img-exif.service';\nvar Ng2ImgMaxService = /** @class */ (function () {\r\n function Ng2ImgMaxService(imgMaxSizeService, imgMaxPXSizeService, imageExifService) {\r\n this.imgMaxSizeService = imgMaxSizeService;\r\n this.imgMaxPXSizeService = imgMaxPXSizeService;\r\n this.imageExifService = imageExifService;\r\n }\r\n Ng2ImgMaxService.prototype.compress = function (files, maxSizeInMB, ignoreAlpha, logExecutionTime) {\r\n var _this = this;\r\n if (ignoreAlpha === void 0) { ignoreAlpha = false; }\r\n if (logExecutionTime === void 0) { logExecutionTime = false; }\r\n var compressedFileSubject = new Subject();\r\n files.forEach(function (file) {\r\n _this.compressImage(file, maxSizeInMB, ignoreAlpha, logExecutionTime).subscribe(function (value) {\r\n compressedFileSubject.next(value);\r\n }, function (error) {\r\n compressedFileSubject.error(error);\r\n });\r\n });\r\n return compressedFileSubject.asObservable();\r\n };\r\n Ng2ImgMaxService.prototype.resize = function (files, maxWidth, maxHeight, logExecutionTime) {\r\n var _this = this;\r\n if (logExecutionTime === void 0) { logExecutionTime = false; }\r\n var resizedFileSubject = new Subject();\r\n files.forEach(function (file) {\r\n _this.resizeImage(file, maxWidth, maxHeight, logExecutionTime).subscribe(function (value) {\r\n resizedFileSubject.next(value);\r\n }, function (error) {\r\n resizedFileSubject.error(error);\r\n });\r\n });\r\n return resizedFileSubject.asObservable();\r\n };\r\n Ng2ImgMaxService.prototype.compressImage = function (file, maxSizeInMB, ignoreAlpha, logExecutionTime) {\r\n if (ignoreAlpha === void 0) { ignoreAlpha = false; }\r\n if (logExecutionTime === void 0) { logExecutionTime = false; }\r\n return this.imgMaxSizeService.compressImage(file, maxSizeInMB, ignoreAlpha, logExecutionTime);\r\n };\r\n Ng2ImgMaxService.prototype.resizeImage = function (file, maxWidth, maxHeight, logExecutionTime) {\r\n if (logExecutionTime === void 0) { logExecutionTime = false; }\r\n return this.imgMaxPXSizeService.resizeImage(file, maxWidth, maxHeight, logExecutionTime);\r\n };\r\n Ng2ImgMaxService.prototype.getEXIFOrientedImage = function (image) {\r\n return this.imageExifService.getOrientedImage(image);\r\n };\r\n /** @nocollapse */\r\n Ng2ImgMaxService.ctorParameters = function () { return [\r\n { type: ImgMaxSizeService, decorators: [{ type: Inject, args: [forwardRef(function () { return ImgMaxSizeService; }),] }] },\r\n { type: ImgMaxPXSizeService, decorators: [{ type: Inject, args: [forwardRef(function () { return ImgMaxPXSizeService; }),] }] },\r\n { type: ImgExifService, decorators: [{ type: Inject, args: [forwardRef(function () { return ImgExifService; }),] }] }\r\n ]; };\nNg2ImgMaxService.ɵfac = function Ng2ImgMaxService_Factory(t) { return new (t || Ng2ImgMaxService)(ɵngcc0.ɵɵinject(forwardRef(function () { return ImgMaxSizeService; })), ɵngcc0.ɵɵinject(forwardRef(function () { return ImgMaxPXSizeService; })), ɵngcc0.ɵɵinject(forwardRef(function () { return ImgExifService; }))); };\nNg2ImgMaxService.ɵprov = ɵngcc0.ɵɵdefineInjectable({ token: Ng2ImgMaxService, factory: function (t) { return Ng2ImgMaxService.ɵfac(t); } });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(Ng2ImgMaxService, [{\n type: Injectable\n }], function () { return [{ type: ɵngcc1.ImgMaxSizeService, decorators: [{\n type: Inject,\n args: [forwardRef(function () { return ImgMaxSizeService; })]\n }] }, { type: ɵngcc2.ImgMaxPXSizeService, decorators: [{\n type: Inject,\n args: [forwardRef(function () { return ImgMaxPXSizeService; })]\n }] }, { type: ɵngcc3.ImgExifService, decorators: [{\n type: Inject,\n args: [forwardRef(function () { return ImgExifService; })]\n }] }]; }, null); })();\r\n return Ng2ImgMaxService;\r\n}());\r\nexport { Ng2ImgMaxService };\r\n\n//# sourceMappingURL=ng2-img-max.service.js.map","\r\n Upload Photo\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n Drag and drop images here!\r\n \r\n {{ f.name }} ({{ f.type }})\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n Enter album\r\n \r\n \r\n \r\n or \r\n \r\n Existing albums\r\n \r\n {{album.UpdatedFileFolderName}}\r\n \r\n \r\n \r\n
 
\r\n
\r\n
\r\n
\r\n
","import { Component, OnInit } from '@angular/core';\r\nimport { FormControl, FormGroup } from '@angular/forms';\r\nimport { Router } from '@angular/router';\r\nimport { NgxFileDropEntry, FileSystemFileEntry, FileSystemDirectoryEntry } from 'ngx-file-drop';\r\nimport { AlertService } from 'src/app/shared/components/alert/alert.service';\r\nimport { NaomitsuService } from 'src/app/shared/databaseService';\r\nimport { globalconstants } from 'src/app/shared/globalconstant';\r\nimport { List } from 'src/app/shared/interface';\r\nimport { FileUploadService } from 'src/app/shared/upload.service';\r\nimport { TokenStorageService } from 'src/app/_services/token-storage.service';\r\n\r\n@Component({\r\n selector: 'app-filedrag-and-drop',\r\n templateUrl: './filedrag-and-drop.component.html',\r\n styleUrls: ['./filedrag-and-drop.component.scss']\r\n})\r\nexport class FiledragAndDropComponent implements OnInit {\r\n options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n optionsNoAutoClose = {\r\n autoClose: false,\r\n keepAfterRouteChange: true\r\n };\r\n Processing = false;\r\n Requestsize = 0;\r\n Albums: any[];\r\n errorMessage = '';\r\n formdata: FormData;\r\n dragdropForm = new FormGroup({\r\n folderName: new FormControl(''),\r\n FileId: new FormControl(0),\r\n parentId: new FormControl(0)\r\n\r\n });\r\n constructor(private uploadService: FileUploadService,\r\n private naomitsuService: NaomitsuService,\r\n private route: Router,\r\n private tokenStorage: TokenStorageService,\r\n private alert: AlertService) { }\r\n\r\n ngOnInit(): void {\r\n this.formdata = new FormData();\r\n this.checklogin();\r\n this.getAlbums();\r\n }\r\n checklogin() {\r\n \r\n let token = this.tokenStorage.getToken();\r\n\r\n if (token == null) {\r\n this.alert.error(\"Access denied! login required.\", this.options);\r\n this.route.navigate(['/home']);\r\n }\r\n }\r\n public files: NgxFileDropEntry[] = [];\r\n\r\n public dropped(files: NgxFileDropEntry[]) {\r\n this.files = files;\r\n //console.log('this.files', this.files)\r\n debugger;\r\n this.Processing = true;\r\n for (const droppedFile of files) {\r\n\r\n //20971520\r\n // Is it a file?\r\n if (droppedFile.fileEntry.isFile) {\r\n const fileEntry = droppedFile.fileEntry as FileSystemFileEntry;\r\n fileEntry.file((file: File) => {\r\n\r\n if (this.Requestsize + file.size > globalconstants.RequestLimit) {\r\n let mb = (globalconstants.RequestLimit / (1024 * 1024)).toFixed(2);\r\n this.alert.error('File upload limit is ${mb}mb!', this.optionsNoAutoClose);\r\n return;\r\n }\r\n this.Requestsize += file.size\r\n // Here you can access the real file\r\n //console.log(droppedFile.relativePath, file);\r\n if (file.type.includes(\"image\") || file.type == \"application/pdf\" ||\r\n file.type == \"application/vnd.ms-excel\" ||\r\n file.type == \"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet\") {\r\n //this.filesForDisplayOnly.push(file);\r\n this.formdata.append(droppedFile.fileEntry.name, file, droppedFile.fileEntry.name)\r\n }\r\n else\r\n this.errorMessage = \"Only pdf/images/excel/word are allowed to upload.\";\r\n\r\n });\r\n } else {\r\n // It was a directory (empty directories are added, otherwise only files)\r\n const fileEntry = droppedFile.fileEntry as FileSystemDirectoryEntry;\r\n //console.log(droppedFile.relativePath, fileEntry);\r\n }\r\n }\r\n if (this.errorMessage.length > 0)\r\n this.alert.error(this.errorMessage, this.options);\r\n this.Processing =false;\r\n //console.log('this.formdata',this.filesForDisplayOnly);\r\n }\r\n Upload() {\r\n\r\n if (this.Requestsize > globalconstants.RequestLimit) {\r\n this.alert.error(\"File upload limit is 20mb!\", this.optionsNoAutoClose);\r\n return;\r\n }\r\n\r\n let error: boolean = false;\r\n debugger;\r\n\r\n let selectedAlbum = this.dragdropForm.get(\"folderName\").value;\r\n let selectedAlbumId = this.dragdropForm.get(\"parentId\").value;\r\n //console.log(this.Albums);//alert(selectedAlbum);\r\n if (this.files.length < 1) {\r\n error = true;\r\n this.alert.warn(\"No image to upload\", this.options);\r\n }\r\n\r\n if (selectedAlbum == '' && selectedAlbumId == 0) {\r\n error = true;\r\n this.alert.error(\"Please enter folder or select existing folder\", this.options);\r\n return;\r\n }\r\n else {\r\n if (selectedAlbumId != 0) {\r\n selectedAlbum = this.Albums.filter(item => item.FileId == selectedAlbumId)[0].UpdatedFileFolderName;\r\n }\r\n\r\n this.formdata.append(\"folderName\", selectedAlbum);\r\n this.formdata.append(\"FileId\", selectedAlbumId);\r\n //if ()\r\n this.formdata.append(\"parentId\", this.dragdropForm.get(\"parentId\") != null ? this.dragdropForm.get(\"parentId\").value : \"0\");\r\n this.formdata.append(\"description\", \"\");\r\n this.formdata.append(\"fileOrPhoto\", \"0\");\r\n let filteredAlbum: any[] = [];\r\n if (this.Albums.length > 0) {\r\n filteredAlbum = this.Albums.filter(item => {\r\n return item.UpdatableName == selectedAlbum\r\n }\r\n );\r\n }\r\n this.uploadFile();\r\n\r\n\r\n }\r\n }\r\n uploadFile() {\r\n //console.log('form dasta',this.formdata);\r\n this.Processing =true;\r\n this.uploadService.postFiles(this.formdata).subscribe(res => {\r\n //console.log(\"Upload complete\");\r\n this.alert.success(\"Files Uploaded successfully.\", this.options);\r\n this.formdata = null;\r\n this.files = [];\r\n this.getAlbums();\r\n this.Processing =false;\r\n this.route.navigate(['/home/managefile']);\r\n\r\n });\r\n }\r\n getAlbums() {\r\n let list: List = new List();\r\n list.fields = [\"FileId\", \"UpdatedFileFolderName\"];\r\n list.PageName = \"FilesNPhotoes\";\r\n list.filter = [\"Active eq 1 and FileOrFolder eq 1 and FileOrPhoto eq 0\"];\r\n this.naomitsuService.get(list)\r\n .subscribe((data: any) => {\r\n if (data.value.length > 0) {\r\n this.Albums = data.value;\r\n }\r\n else\r\n this.Albums = [];\r\n\r\n });\r\n }\r\n public fileOver(event) {\r\n //console.log(event);\r\n }\r\n\r\n public fileLeave(event) {\r\n //console.log(event);\r\n }\r\n}\r\n","\r\n \r\n Upload Files\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n \r\n \r\n drag and drop files here\r\n \r\n \r\n \r\n
\r\n
0\">\r\n
\r\n
\r\n \r\n Enter folder\r\n \r\n {{album.value?.length || 0}}/100\r\n \r\n or\r\n \r\n Existing albums\r\n \r\n \r\n {{album.UpdatedFileFolderName}}\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n
Name
{{ item.relativePath }}
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
","import { Component, OnInit } from '@angular/core';\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport { AlertService } from 'src/app/shared/components/alert/alert.service';\r\nimport { NaomitsuService } from 'src/app/shared/databaseService';\r\nimport { DialogService } from 'src/app/shared/dialog.service';\r\nimport { List } from 'src/app/shared/interface';\r\nimport { TokenStorageService } from 'src/app/_services/token-storage.service';\r\nimport { globalconstants } from '../../../shared/globalconstant';\r\n\r\n@Component({\r\n selector: 'app-photos',\r\n templateUrl: './photos.component.html',\r\n styleUrls: ['./photos.component.scss']\r\n})\r\nexport class PhotosComponent implements OnInit {\r\n options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n selectedAlbum: string;\r\n selectedAlbumId: number;\r\n loading = true;\r\n error = '';\r\n title = '';\r\n images = [\r\n {\r\n PhotoId: 0,\r\n PhotoPath: \"\",\r\n Description: \"\",\r\n UpdatableName: \"\",\r\n ImagePath:\"\"\r\n }\r\n ];\r\n constructor(private dataservice: NaomitsuService,\r\n private route: ActivatedRoute,\r\n private nav: Router,\r\n private alert: AlertService,\r\n private dialog: DialogService,\r\n private tokenStorage:TokenStorageService) {\r\n this.route.paramMap.subscribe(item => {\r\n this.selectedAlbumId = +this.route.snapshot.queryParamMap.get('AlbumId');//item.get('AlbumId')\r\n //console.log('this.selectedAlbum',item);\r\n })\r\n }\r\n\r\n ngOnInit(): void {\r\n this.checklogin();\r\n this.getPhotos();\r\n }\r\n checklogin() {\r\n let options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n let token = this.tokenStorage.getToken();\r\n\r\n if (token == null) {\r\n this.alert.error(\"Access denied! login required.\", options);\r\n this.nav.navigate(['/home']);\r\n }\r\n}\r\n getPhotos() {\r\n let list: List = new List();\r\n list.fields = [\"PhotoId\", \"PhotoPath\", \"Description\", \"Album/UpdatableName\", \"Album/AlbumName\"];\r\n list.lookupFields = [\"Album\"];\r\n list.PageName = \"PhotoGalleries\";\r\n list.filter = [\"Active eq 1 and AlbumId eq \" + this.selectedAlbumId];\r\n list.orderBy = \"UploadDate desc\";\r\n this.loading = true;\r\n this.dataservice.get(list)\r\n .subscribe((data: any) => {\r\n if (data.value.length > 0) {\r\n debugger;\r\n var browsePath = '';\r\n this.images = data.value.map(item => {\r\n browsePath = globalconstants.apiUrl + \"/Image/\" + item.Album.AlbumName + \"/\" + item.PhotoPath;\r\n return {\r\n PhotoId:item.PhotoId,\r\n PhotoPath: browsePath,\r\n ImagePath:item.PhotoPath,\r\n Description: item.Description\r\n }\r\n });\r\n\r\n this.selectedAlbum = data.value[0].Album.UpdatableName;// this.images[0].Album.AlbumName;\r\n this.title = this.selectedAlbum;\r\n //console.log('this.images',this.images)\r\n }\r\n else\r\n this.error = \"No image to display\";\r\n this.loading = false;\r\n //setTimeout(()=>{this.loading=false},3000); \r\n })\r\n\r\n\r\n }\r\n display(albumId)\r\n {\r\n this.nav.navigate([\"/home/photos\"],{queryParams:{\"photoId\":albumId}});\r\n }\r\n Update(event,button, photoPath) {\r\n console.log('button._elementRef.nativeElement.id',button);\r\n event.stopPropagation();\r\n let confirmYesNo: Boolean = false;\r\n this.dialog.openConfirmDialog(\"Are you sure you want to delete this photo?\")\r\n .afterClosed().subscribe(res => {\r\n confirmYesNo = res;\r\n if (confirmYesNo) {\r\n //this.uploadImage();\r\n let albumtoUpdate = {\r\n PhotoPath: photoPath,\r\n Description:button._elementRef.nativeElement.name,\r\n Active: 0,\r\n AlbumId:this.selectedAlbumId,\r\n UploadDate: new Date()\r\n }\r\n //console.log('albumtoUpdate',albumtoUpdate);\r\n this.dataservice.postPatch('PhotoGalleries', albumtoUpdate, button._elementRef.nativeElement.id, 'patch')\r\n .subscribe(res => {\r\n\r\n this.images.splice(this.images.findIndex((item)=>{item.PhotoId==button._elementRef.nativeElement.id}),1);\r\n this.alert.success(\"Album name updated!\", this.options);\r\n },\r\n error => console.log(error));\r\n\r\n }\r\n });\r\n }\r\n back(){\r\n this.nav.navigate([\"/home/managefile\"]); \r\n }\r\n\r\n}\r\n","\r\n {{title}}\r\n \r\n
\r\n
\r\n
\r\n \"{{image.Description}}\"\r\n
\r\n {{image.Description}}\r\n
\r\n
 
\r\n
\r\n
\r\n
\r\n  \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'album-edit-input',\r\n templateUrl: './albumedit-input.component.html',\r\n styleUrls: ['./albumedit-input.component.scss'],\r\n})\r\nexport class AlbumEditInputComponent implements OnInit {\r\n @Input() data: string;\r\n @Output() focusOut: EventEmitter = new EventEmitter();\r\n @Output() tried: EventEmitter = new EventEmitter();\r\n currency = '$';\r\n editMode = false;\r\n constructor() {}\r\n\r\n ngOnInit() {}\r\n\r\n onFocusOut() {\r\n this.focusOut.emit(this.data);\r\n }\r\n oninputfocus(){\r\n this.tried.emit(this.data);\r\n //console.log(this.data);\r\n }\r\n}\r\n","
{{ data }}
\r\n\r\n","import { DOCUMENT } from '@angular/common';\nimport { ɵɵdefineInjectable, ɵɵinject, Injectable, Inject, InjectionToken, EventEmitter, Directive, NgZone, Optional, Input, Output, NgModule } from '@angular/core';\n\n/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n/**\n * A pending copy-to-clipboard operation.\n *\n * The implementation of copying text to the clipboard modifies the DOM and\n * forces a relayout. This relayout can take too long if the string is large,\n * causing the execCommand('copy') to happen too long after the user clicked.\n * This results in the browser refusing to copy. This object lets the\n * relayout happen in a separate tick from copying by providing a copy function\n * that can be called later.\n *\n * Destroy must be called when no longer in use, regardless of whether `copy` is\n * called.\n */\nimport * as ɵngcc0 from '@angular/core';\nclass PendingCopy {\n constructor(text, _document) {\n this._document = _document;\n const textarea = this._textarea = this._document.createElement('textarea');\n const styles = textarea.style;\n // Hide the element for display and accessibility. Set a fixed position so the page layout\n // isn't affected. We use `fixed` with `top: 0`, because focus is moved into the textarea\n // for a split second and if it's off-screen, some browsers will attempt to scroll it into view.\n styles.position = 'fixed';\n styles.top = styles.opacity = '0';\n styles.left = '-999em';\n textarea.setAttribute('aria-hidden', 'true');\n textarea.value = text;\n this._document.body.appendChild(textarea);\n }\n /** Finishes copying the text. */\n copy() {\n const textarea = this._textarea;\n let successful = false;\n try { // Older browsers could throw if copy is not supported.\n if (textarea) {\n const currentFocus = this._document.activeElement;\n textarea.select();\n textarea.setSelectionRange(0, textarea.value.length);\n successful = this._document.execCommand('copy');\n if (currentFocus) {\n currentFocus.focus();\n }\n }\n }\n catch (_a) {\n // Discard error.\n // Initial setting of {@code successful} will represent failure here.\n }\n return successful;\n }\n /** Cleans up DOM changes used to perform the copy operation. */\n destroy() {\n const textarea = this._textarea;\n if (textarea) {\n if (textarea.parentNode) {\n textarea.parentNode.removeChild(textarea);\n }\n this._textarea = undefined;\n }\n }\n}\n\n/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n/**\n * A service for copying text to the clipboard.\n */\nclass Clipboard {\n constructor(document) {\n this._document = document;\n }\n /**\n * Copies the provided text into the user's clipboard.\n *\n * @param text The string to copy.\n * @returns Whether the operation was successful.\n */\n copy(text) {\n const pendingCopy = this.beginCopy(text);\n const successful = pendingCopy.copy();\n pendingCopy.destroy();\n return successful;\n }\n /**\n * Prepares a string to be copied later. This is useful for large strings\n * which take too long to successfully render and be copied in the same tick.\n *\n * The caller must call `destroy` on the returned `PendingCopy`.\n *\n * @param text The string to copy.\n * @returns the pending copy operation.\n */\n beginCopy(text) {\n return new PendingCopy(text, this._document);\n }\n}\nClipboard.ɵfac = function Clipboard_Factory(t) { return new (t || Clipboard)(ɵngcc0.ɵɵinject(DOCUMENT)); };\nClipboard.ɵprov = ɵɵdefineInjectable({ factory: function Clipboard_Factory() { return new Clipboard(ɵɵinject(DOCUMENT)); }, token: Clipboard, providedIn: \"root\" });\nClipboard.ctorParameters = () => [\n { type: undefined, decorators: [{ type: Inject, args: [DOCUMENT,] }] }\n];\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(Clipboard, [{\n type: Injectable,\n args: [{ providedIn: 'root' }]\n }], function () { return [{ type: undefined, decorators: [{\n type: Inject,\n args: [DOCUMENT]\n }] }]; }, null); })();\n\n/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n/** Injection token that can be used to provide the default options to `CdkCopyToClipboard`. */\nconst CKD_COPY_TO_CLIPBOARD_CONFIG = new InjectionToken('CKD_COPY_TO_CLIPBOARD_CONFIG');\n/**\n * Provides behavior for a button that when clicked copies content into user's\n * clipboard.\n */\nclass CdkCopyToClipboard {\n constructor(_clipboard, _ngZone, config) {\n this._clipboard = _clipboard;\n this._ngZone = _ngZone;\n /** Content to be copied. */\n this.text = '';\n /**\n * How many times to attempt to copy the text. This may be necessary for longer text, because\n * the browser needs time to fill an intermediate textarea element and copy the content.\n */\n this.attempts = 1;\n /**\n * Emits when some text is copied to the clipboard. The\n * emitted value indicates whether copying was successful.\n */\n this.copied = new EventEmitter();\n /** Copies that are currently being attempted. */\n this._pending = new Set();\n if (config && config.attempts != null) {\n this.attempts = config.attempts;\n }\n }\n /** Copies the current text to the clipboard. */\n copy(attempts = this.attempts) {\n if (attempts > 1) {\n let remainingAttempts = attempts;\n const pending = this._clipboard.beginCopy(this.text);\n this._pending.add(pending);\n const attempt = () => {\n const successful = pending.copy();\n if (!successful && --remainingAttempts && !this._destroyed) {\n // We use 1 for the timeout since it's more predictable when flushing in unit tests.\n this._currentTimeout = this._ngZone.runOutsideAngular(() => setTimeout(attempt, 1));\n }\n else {\n this._currentTimeout = null;\n this._pending.delete(pending);\n pending.destroy();\n this.copied.emit(successful);\n }\n };\n attempt();\n }\n else {\n this.copied.emit(this._clipboard.copy(this.text));\n }\n }\n ngOnDestroy() {\n if (this._currentTimeout) {\n clearTimeout(this._currentTimeout);\n }\n this._pending.forEach(copy => copy.destroy());\n this._pending.clear();\n this._destroyed = true;\n }\n}\nCdkCopyToClipboard.ɵfac = function CdkCopyToClipboard_Factory(t) { return new (t || CdkCopyToClipboard)(ɵngcc0.ɵɵdirectiveInject(Clipboard), ɵngcc0.ɵɵdirectiveInject(ɵngcc0.NgZone), ɵngcc0.ɵɵdirectiveInject(CKD_COPY_TO_CLIPBOARD_CONFIG, 8)); };\nCdkCopyToClipboard.ɵdir = ɵngcc0.ɵɵdefineDirective({ type: CdkCopyToClipboard, selectors: [[\"\", \"cdkCopyToClipboard\", \"\"]], hostBindings: function CdkCopyToClipboard_HostBindings(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵlistener(\"click\", function CdkCopyToClipboard_click_HostBindingHandler() { return ctx.copy(); });\n } }, inputs: { text: [\"cdkCopyToClipboard\", \"text\"], attempts: [\"cdkCopyToClipboardAttempts\", \"attempts\"] }, outputs: { copied: \"cdkCopyToClipboardCopied\" } });\nCdkCopyToClipboard.ctorParameters = () => [\n { type: Clipboard },\n { type: NgZone },\n { type: undefined, decorators: [{ type: Optional }, { type: Inject, args: [CKD_COPY_TO_CLIPBOARD_CONFIG,] }] }\n];\nCdkCopyToClipboard.propDecorators = {\n text: [{ type: Input, args: ['cdkCopyToClipboard',] }],\n attempts: [{ type: Input, args: ['cdkCopyToClipboardAttempts',] }],\n copied: [{ type: Output, args: ['cdkCopyToClipboardCopied',] }]\n};\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(CdkCopyToClipboard, [{\n type: Directive,\n args: [{\n selector: '[cdkCopyToClipboard]',\n host: {\n '(click)': 'copy()'\n }\n }]\n }], function () { return [{ type: Clipboard }, { type: ɵngcc0.NgZone }, { type: undefined, decorators: [{\n type: Optional\n }, {\n type: Inject,\n args: [CKD_COPY_TO_CLIPBOARD_CONFIG]\n }] }]; }, { text: [{\n type: Input,\n args: ['cdkCopyToClipboard']\n }], attempts: [{\n type: Input,\n args: ['cdkCopyToClipboardAttempts']\n }], copied: [{\n type: Output,\n args: ['cdkCopyToClipboardCopied']\n }] }); })();\n\n/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\nclass ClipboardModule {\n}\nClipboardModule.ɵmod = ɵngcc0.ɵɵdefineNgModule({ type: ClipboardModule });\nClipboardModule.ɵinj = ɵngcc0.ɵɵdefineInjector({ factory: function ClipboardModule_Factory(t) { return new (t || ClipboardModule)(); } });\n(function () { (typeof ngJitMode === \"undefined\" || ngJitMode) && ɵngcc0.ɵɵsetNgModuleScope(ClipboardModule, { declarations: [CdkCopyToClipboard], exports: [CdkCopyToClipboard] }); })();\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(ClipboardModule, [{\n type: NgModule,\n args: [{\n declarations: [CdkCopyToClipboard],\n exports: [CdkCopyToClipboard]\n }]\n }], null, null); })();\n\n/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\n/**\n * Generated bundle index. Do not edit.\n */\n\nexport { CKD_COPY_TO_CLIPBOARD_CONFIG, CdkCopyToClipboard, Clipboard, ClipboardModule, PendingCopy };\n\n//# sourceMappingURL=clipboard.js.map","import { Component, ElementRef, OnInit, ViewChild } from '@angular/core';\r\nimport { Router } from '@angular/router';\r\nimport { NaomitsuService } from 'src/app/shared/databaseService';\r\nimport { List } from 'src/app/shared/interface';\r\nimport { AlertService } from 'src/app/shared/components/alert/alert.service';\r\nimport { DialogService } from 'src/app/shared/dialog.service';\r\nimport { TokenStorageService } from 'src/app/_services/token-storage.service';\r\nimport { FormControl, FormGroup, Validators } from '@angular/forms';\r\nimport { globalconstants } from 'src/app/shared/globalconstant';\r\nimport { MatTableDataSource } from '@angular/material/table';\r\n\r\n@Component({\r\n selector: 'app-albums',\r\n templateUrl: './albums.component.html',\r\n styleUrls: ['./albums.component.scss']\r\n})\r\nexport class AlbumsComponent implements OnInit {\r\n @ViewChild('button') button: ElementRef;\r\n FileOrImage: number = 1;\r\n activeSkill() {\r\n (this.button).color = 'accent';\r\n }\r\n dataSource: MatTableDataSource;\r\n displayedColumns=[\"UpdatedFileFolderName\",\"UploadDate\",\"Copy\",\"View\"]\r\n ParentId = 0;\r\n folderHierarachy: string = 'Image/';\r\n folderDisplayHierachy:string='Image/';\r\n title: string = '';\r\n loading: boolean=false;\r\n error: string = '';\r\n options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n searchForm = new FormGroup(\r\n {\r\n UpdatedFileFolderName: new FormControl('', [Validators.required]),\r\n parentId: new FormControl(0),\r\n //FilesNPhoto: new FormControl(0, [Validators.required])\r\n }\r\n );\r\n images: any[];\r\n Albums: any[]=[];\r\n AllAlbums: any[];\r\n unique: any[];\r\n selectedAlbum: string;\r\n oldvalue: string;\r\n absoluteurl = '';\r\n constructor(\r\n private dataservice: NaomitsuService,\r\n private route: Router,\r\n private alert: AlertService,\r\n private dialog: DialogService,\r\n private tokenStorage: TokenStorageService,\r\n //private globalconstants\r\n ) {\r\n //this.absoluteurl =window.location.origin;\r\n }\r\n\r\n ngOnInit() {\r\n this.checklogin();\r\n this.getAlbums();\r\n //this.getPhotos(0, \"\");\r\n\r\n }\r\n applyFilter(strFilter) {\r\n if (strFilter.length > 2)\r\n this.Albums = [...this.AllAlbums.filter(item => { return item.UpdatedFileFolderName.includes(strFilter) || item.UploadDate.toString().includes(strFilter) })];\r\n else if (strFilter.length == 0) {\r\n this.Albums == this.AllAlbums.filter((item, indx) => {\r\n return indx < 10;\r\n });\r\n }\r\n }\r\n checklogin() {\r\n let options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n let token = this.tokenStorage.getToken();\r\n\r\n if (token == null) {\r\n this.alert.error(\"Access denied! login required.\", options);\r\n this.route.navigate(['/home']);\r\n }\r\n }\r\n getAlbums() {\r\n\r\n let list: List = new List();\r\n list.fields = [\"FileId\", \"FileName\", \"UpdatedFileFolderName\", \"FileOrFolder\", \"UploadDate\", \"ParentId\", \"Active\"];\r\n list.PageName = \"FilesNPhotoes\";\r\n list.filter = ['Active eq 1 and FileOrFolder eq 1'];// and FileOrPhoto eq ' + this.searchForm.get(\"FilesNPhoto\").value];\r\n list.orderBy = \"UploadDate desc\";\r\n //list.limitTo =10;\r\n this.dataservice.get(list)\r\n .subscribe((data: any) => {\r\n this.AllAlbums = [...data.value];\r\n // .filter((item, indx) => {\r\n // // return indx < 10;\r\n // });\r\n })\r\n }\r\n getNestedFolders(parentId) {\r\n let ParentItem = this.AllAlbums.filter(item => item.FileId == parentId);\r\n debugger;\r\n while (ParentItem.length > 0) {\r\n this.folderHierarachy += ParentItem[0].FileName + \"/\";\r\n this.folderDisplayHierachy += ParentItem[0].UpdatedFileFolderName + \"/\";\r\n ParentItem = this.AllAlbums.filter(item => item.FileId == ParentItem[0].ParentId)\r\n }\r\n }\r\n message() {\r\n this.alert.success(\"url copied\", this.options);\r\n }\r\n getFiles(album, mode) {\r\n debugger;\r\n let folderSearch = '';\r\n\r\n if (album != undefined) {\r\n if (album.FileOrFolder == 0 && mode=='open') {\r\n //let folderHierarachy='Image/';\r\n //this.getNestedFolders(album.ParentId);\r\n //let url = globalconstants.apiUrl + \"/\" + folderHierarachy + album.FileName;\r\n \r\n window.open(album.FilePath, \"_blank\");\r\n return;\r\n }\r\n\r\n if (album.FileId == undefined && this.searchForm.get(\"UpdatedFileFolderName\").value == \"\") {\r\n this.alert.error(\"Please enter folder name to search\", this.options);\r\n return;\r\n }\r\n\r\n if (album.FileId != undefined)\r\n folderSearch = \" and ParentId eq \" + album.FileId;\r\n else if (album.FileId == undefined && this.searchForm.get(\"UpdatedFileFolderName\").value != \"\")\r\n folderSearch = \" and substringof('\" + this.searchForm.get(\"UpdatedFileFolderName\").value + \"',UpdatedFileFolderName)\";\r\n }\r\n else if(this.searchForm.get(\"UpdatedFileFolderName\").value!='') {\r\n folderSearch = \" and substringof('\" + this.searchForm.get(\"UpdatedFileFolderName\").value + \"',UpdatedFileFolderName)\";\r\n }\r\n else\r\n {\r\n return;\r\n }\r\n let list: List = new List();\r\n list.fields = [\"FileId\", \"FileName\", \"FileOrFolder\", \"Description\", \"ParentId\", \"UpdatedFileFolderName\", \"UploadDate\"];\r\n list.PageName = \"FilesNPhotoes\";\r\n list.filter = [\"Active eq 1\" + folderSearch];\r\n list.orderBy = \"UploadDate desc\";\r\n this.loading = true;\r\n this.dataservice.get(list)\r\n .subscribe((data: any) => {\r\n if (data.value.length > 0) {\r\n debugger;\r\n var browsePath = '';\r\n this.Albums = data.value.map(item => {\r\n this.folderHierarachy='Image/';\r\n this.folderDisplayHierachy ='Image/';\r\n this.getNestedFolders(item.ParentId);\r\n \r\n if (this.folderHierarachy.length > 0)\r\n browsePath = globalconstants.apiUrl + \"/\" + this.folderHierarachy + item.FileName;\r\n return {\r\n FileId: item.FileId,\r\n FilePath: browsePath,\r\n DisplayPath: globalconstants.apiUrl + \"/\" + this.folderDisplayHierachy + item.FileName,\r\n FileName: item.FileName,\r\n Description: item.Description,\r\n UploadDate: item.UploadDate,\r\n FileOrFolder: item.FileOrFolder,\r\n ParentId: item.ParentId,\r\n UpdatedFileFolderName: item.UpdatedFileFolderName,\r\n Copy:'',\r\n View:''\r\n }\r\n });\r\n this.error ='';\r\n this.selectedAlbum = data.value[0].UpdatedFileFolderName;// this.images[0].Album.AlbumName;\r\n this.title = this.selectedAlbum;\r\n //this.AllAlbums =[...this.Albums];\r\n }\r\n else {\r\n this.error = \"No file/folder found.\";\r\n this.Albums = [];\r\n }\r\n this.dataSource = new MatTableDataSource(this.Albums);\r\n this.loading = false;\r\n //setTimeout(()=>{this.loading=false},3000); \r\n })\r\n }\r\n updateActive(value,album) {\r\n this.dialog.openConfirmDialog(\"Are you sure you want to delete File/Folder \" + value._elementRef.nativeElement.name + \"?\")\r\n .afterClosed().subscribe(res => {\r\n\r\n if (res) {\r\n let albumtoUpdate = {\r\n UpdatedFileFolderName: value._elementRef.nativeElement.name,\r\n Active: value.checked == true ? 1 : 0,\r\n UploadDate: new Date()\r\n }\r\n\r\n this.dataservice.postPatch('FilesNPhotoes', albumtoUpdate, value._elementRef.nativeElement.id, 'patch')\r\n .subscribe(res => {\r\n this.getFiles(album,\"\");\r\n this.alert.success(\"File/Folder deleted successfully.\", this.options);\r\n //console.lothisg(res);\r\n });\r\n }\r\n });\r\n }\r\n\r\n selected(event) {\r\n //console.log('event',event)\r\n this.selectedAlbum = event.target.value;\r\n // console.log('this.selectedAlbum', this.selectedAlbum)\r\n // let tempImages = this.Albums.filter((item)=>{\r\n // return item.Album == this.selectedAlbum\r\n // })\r\n // this.images = tempImages.map(item=> {return item.PhotoPath});\r\n }\r\n getoldvalue(value: string) {\r\n this.oldvalue = value;\r\n // console.log('old value', this.oldvalue);\r\n }\r\n updateAlbum(value) {\r\n //console.log(value);\r\n //value.stopPropagation();\r\n if (this.oldvalue == value)\r\n return;\r\n let confirmYesNo: Boolean = false;\r\n if (value.length == 0 || value.length > 50) {\r\n this.alert.error(\"Character should not be empty or less than 50!\");\r\n return;\r\n }\r\n\r\n let albumtoUpdate = {\r\n UpdatedFileFolderName: value,\r\n Active: 1,\r\n UploadDate: new Date()\r\n }\r\n\r\n let selectedAlbumId = this.Albums.filter(item => {\r\n return item.UpdatedFileFolderName == this.oldvalue\r\n })[0].FileId;\r\n\r\n this.dataservice.postPatch('FilesNPhotoes', albumtoUpdate, selectedAlbumId, 'patch')\r\n .subscribe(res => {\r\n this.alert.success(\"File/Folder name updated!\", this.options);\r\n });\r\n }\r\n display(albumId) {\r\n this.route.navigate([\"/home/photos\"], { queryParams: { \"AlbumId\": albumId } });\r\n }\r\n Delete(value) {\r\n //console.log(value);\r\n value.stopPropagation();\r\n let confirmYesNo: Boolean = false;\r\n if (value.length == 0 || value.length > 50) {\r\n this.alert.error(\"Character should not be empty or less than 50!\");\r\n return;\r\n }\r\n this.dialog.openConfirmDialog(\"Are you sure you want to delete all photos in ${value} album?\")\r\n .afterClosed().subscribe(res => {\r\n confirmYesNo = res;\r\n if (confirmYesNo) {\r\n //this.uploadImage();\r\n let albumtoUpdate = {\r\n UpdatedFileFolderName: value,\r\n Active: 1,\r\n UploadDate: new Date()\r\n }\r\n let selectedAlbumId = this.Albums.filter(item => {\r\n return item.UpdatedFileFolderName == this.oldvalue\r\n })[0].FileId;\r\n // console.log('selectedAlbumId', selectedAlbumId);\r\n // this.dataservice.get('Albums', albumtoUpdate, selectedAlbumId, 'patch')\r\n // .subscribe(res => {\r\n // console.log(res);\r\n // });\r\n\r\n }\r\n });\r\n }\r\n}\r\nexport interface IAlbum{\r\n FileId:number; \r\n FileOrFolder:number;\r\n UpdatedFileFolderName:string;\r\n UploadDate:Date;\r\n FilePath:string;\r\n\r\n}\r\n","\r\n Manage Files/Folders\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n Enter folder name\r\n \r\n \r\n \r\n
 
\r\n
\r\n
\r\n
\r\n
\r\n 0\"> {{error}}\r\n 0\">{{folderDisplayHierachy|slice:6}}\r\n
\r\n \r\n \r\n \r\n Folder/File \r\n \r\n \r\n \r\n \r\n \r\n Upload Date \r\n {{element.UploadDate|date:'dd/MM/yyyy'}} \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n  \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n \r\n\r\n
\r\n
\r\n
","import { Component, OnInit } from '@angular/core';\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport { MatTableDataSource } from '@angular/material/table';\r\nimport { ViewChild } from '@angular/core';\r\nimport { MatPaginator } from '@angular/material/paginator';\r\nimport { MatSort } from '@angular/material/sort';\r\nimport { IMessage, IPage, List } from '../../../shared/interface';\r\nimport { NaomitsuService } from '../../../shared/databaseService';\r\nimport { SharedataService } from '../../../shared/sharedata.service';\r\nimport { SelectionModel } from '@angular/cdk/collections';\r\nimport { globalconstants } from 'src/app/shared/globalconstant';\r\nimport { AlertService } from 'src/app/shared/components/alert/alert.service';\r\nimport { TokenStorageService } from 'src/app/_services/token-storage.service';\r\n\r\n@Component({\r\n selector: 'app-contactdashboard',\r\n templateUrl: './contactdashboard.component.html',\r\n styleUrls: ['./contactdashboard.component.scss']\r\n})\r\nexport class ContactdashboardComponent implements OnInit {\r\n options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n //ParentPages: [{ PageId, PageTitle }];\r\n //PageDetail: IPage;\r\n //SelectedData:PageDetail[] = [];\r\n DATA: IMessage[] = [];\r\n messageDetail: IMessage;\r\n columns: Array;\r\n title: string;\r\n Id: number;\r\n query: string;//displayedColumns: Array;\r\n list: List;\r\n\r\n displayedColumns = [];// ['id', 'name', 'progress', 'color'];\r\n dataSource: MatTableDataSource;\r\n\r\n @ViewChild(MatPaginator) paginator: MatPaginator;\r\n @ViewChild(MatSort) sort: MatSort;\r\n\r\n selection = new SelectionModel(true, []);\r\n constructor(private dataservice: NaomitsuService,\r\n private navigate: Router,\r\n private route: ActivatedRoute,\r\n private shareddata: SharedataService,\r\n private alert: AlertService,\r\n private tokenStorage:TokenStorageService) {\r\n this.list = new List();\r\n }\r\n ngOnInit() {\r\n this.checklogin();\r\n this.getDetails();\r\n }\r\n checklogin() {\r\n let token = this.tokenStorage.getToken();\r\n\r\n if (token == null) {\r\n this.alert.error(\"Access denied! login required.\", this.options);\r\n this.navigate.navigate(['/home']);\r\n }\r\n }\r\n getDetails() {\r\n\r\n this.list.fields = [\"*\"];\r\n //this.list.lookupFields = [\"Messages\"];\r\n this.list.PageName = \"Messages\";\r\n //this.list.filter=['IsTemplate eq 1'];\r\n this.list.orderBy = \"MessageId desc\";\r\n const columns = [\"MessageId\", \"Name\", \"Email\", \"Subject\", \"MessageBody\", \"Active\", \"Action\"];\r\n\r\n this.dataservice.get(this.list)\r\n .subscribe((data: any) => {\r\n if (data.value.length > 0) {\r\n this.DATA = data.value\r\n\r\n this.columns = columns.map(column => {\r\n return {\r\n columnDef: column,\r\n header: column,\r\n cell: (element: any) => `${element[column] ? element[column] : ``}`\r\n };\r\n });\r\n let SelectedArr = [];\r\n SelectedArr = this.DATA.filter(key => key.Active === 1)\r\n\r\n //console.log(\"DATA\",this.DATA); \r\n this.displayedColumns = this.columns.map(c => c.columnDef);\r\n this.dataSource = new MatTableDataSource(this.DATA);\r\n this.dataSource.paginator = this.paginator;\r\n this.dataSource.sort = this.sort;\r\n this.selection = new SelectionModel(true, SelectedArr);\r\n // });\r\n }\r\n },\r\n error => console.log(error)\r\n );\r\n }\r\n\r\n /**\r\n * Set the paginator and sort after the view init since this component will\r\n * be able to query its view for the initialized paginator and sort.\r\n */\r\n ngAfterViewInit() {\r\n // if (this.paginator != undefined) {\r\n // this.dataSource.paginator = this.paginator;\r\n // this.dataSource.sort = this.sort;\r\n // }\r\n }\r\n\r\n view(MessageId) {\r\n this.navigate.navigate(['/home/message/' + MessageId]);\r\n }\r\n\r\n applyFilter(filterValue: string) {\r\n filterValue = filterValue.trim(); // Remove whitespace\r\n filterValue = filterValue.toLowerCase(); // Datasource defaults to lowercase matches\r\n this.dataSource.filter = filterValue;\r\n }\r\n isAllSelected() {\r\n const numSelected = this.selection.selected.length;\r\n const numRows = this.dataSource.data.length;\r\n return numSelected === numRows;\r\n }\r\n updateActive(element, event) {\r\n\r\n\r\n let checked = this.selection.toggle(element);\r\n let messageDetail ={\r\n Active: event.checked == true ? 1 : 0,\r\n CreatedDate: new Date()\r\n } \r\n // this.DATA.filter(item => { return item.MessageId == element.MessageId })\r\n // .map(item => {\r\n // return {\r\n // // Name: item.Name,\r\n // // Email: item.Email,\r\n // // Subject: item.Subject,\r\n // // MessageBody: item.MessageBody,\r\n // Active: event.checked == true ? 1 : 0,\r\n // CreatedDate: new Date()\r\n // }\r\n // })[0];\r\n // console.log(element.MessageId);\r\n this.dataservice.postPatch('Messages', messageDetail, element.MessageId, 'patch')\r\n .subscribe(\r\n (data: any) => {\r\n this.alert.success(\"Message updated!\", this.options);\r\n })\r\n }\r\n /** Selects all rows if they are not all selected; otherwise clear selection. */\r\n masterToggle() {\r\n this.isAllSelected() ?\r\n this.selection.clear() :\r\n this.dataSource.data.forEach(row => this.selection.select(row));\r\n }\r\n}\r\n\r\nfunction flatten(data) {\r\n var result = {};\r\n function recurse(cur, prop) {\r\n if (Object(cur) !== cur) {\r\n result[prop] = cur;\r\n } else if (Array.isArray(cur)) {\r\n for (var i = 0, l = cur.length; i < l; i++)\r\n recurse(cur[i], prop + \"[\" + i + \"]\");\r\n if (l == 0)\r\n result[prop] = [];\r\n } else {\r\n var isEmpty = true;\r\n for (var p in cur) {\r\n isEmpty = false;\r\n recurse(cur[p], prop ? prop + \".\" + p : p);\r\n }\r\n if (isEmpty && prop)\r\n result[prop] = {};\r\n }\r\n }\r\n recurse(data, \"\");\r\n return result;\r\n}\r\n\r\n","\r\n Messages\r\n \r\n \r\n
\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n Name \r\n {{element.Name}} \r\n \r\n \r\n Email \r\n {{element.Email}} \r\n \r\n \r\n \r\n Subject \r\n {{element.Subject}} \r\n \r\n \r\n Message\r\n \r\n \r\n \r\n \r\n \r\n Read\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
","import { Component, OnInit } from '@angular/core';\r\nimport { FormControl, FormGroup, Validators } from '@angular/forms';\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport { AlertService } from 'src/app/shared/components/alert/alert.service';\r\nimport { NaomitsuService } from 'src/app/shared/databaseService';\r\nimport { List } from 'src/app/shared/interface';\r\n\r\n@Component({\r\n selector: 'app-contact',\r\n templateUrl: './contact.component.html',\r\n styleUrls: ['./contact.component.scss']\r\n})\r\nexport class ContactComponent implements OnInit {\r\n options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n SuccessMessage='';\r\n title: string;\r\n Id: number = 0;\r\n ContactForm = new FormGroup({\r\n Name: new FormControl(\"\", [Validators.required, Validators.maxLength(25)]),\r\n Email: new FormControl(\"\", [Validators.required,Validators.email, Validators.maxLength(25)]),\r\n Subject: new FormControl(\"\", [Validators.required, Validators.maxLength(25)]),\r\n MessageBody: new FormControl(\"\", [Validators.required, Validators.maxLength(250)]),\r\n CreatedDate: new FormControl(new Date()),\r\n Active: new FormControl(0),\r\n MessageId: new FormControl(0)\r\n });\r\n\r\n constructor(private naomitsuService: NaomitsuService,\r\n private alert: AlertService,\r\n private route: Router,\r\n private activeUrl: ActivatedRoute) {\r\n this.activeUrl.paramMap.subscribe(params => {\r\n this.Id = +params.get(\"id\");\r\n //console.log(\"id\",this.Id);\r\n })\r\n }\r\n\r\n ngOnInit(): void {\r\n if (this.Id > 0) {\r\n this.title = \"Message\";\r\n this.GetContactEntry();\r\n }\r\n else\r\n this.title = \"Contact Us\";\r\n\r\n }\r\n get f() { return this.ContactForm.controls; }\r\n\r\n onSubmit() {\r\n this.insert();\r\n }\r\n\r\n updateAsRead() {\r\n\r\n let messageDetail ={\r\n Active: 1,\r\n CreatedDate: new Date()\r\n } \r\n this.naomitsuService.postPatch('Messages', messageDetail, this.Id, 'patch')\r\n .subscribe(\r\n (data: any) => {\r\n //this.alert.success(\"Message updated!\", this.options);\r\n })\r\n }\r\n insert() {\r\n debugger;\r\n this.naomitsuService.postPatch('Messages', this.ContactForm.value, 0, 'post')\r\n .subscribe(\r\n (data: any) => {\r\n //this.alert.success(\"Data saved Successfully\", this.options);\r\n this.SuccessMessage =\"We have received your message! Thank you for contacting us.\";\r\n //this.route.navigate([\"/home\"]);\r\n },\r\n (error) => {\r\n console.log('messages page', error);\r\n });\r\n }\r\n GetContactEntry() {\r\n let list: List = new List();\r\n list.fields = [\"MessageId\", \"Name\", \"Email\", \"Subject\", \"MessageBody\", \"Active\", \"CreatedDate\"];\r\n list.PageName = \"Messages\";\r\n list.filter = [\"MessageId eq \" + this.Id];\r\n //list.orderBy = \"MessageId desc\";\r\n this.naomitsuService.get(list)\r\n .subscribe((data: any) => {\r\n this.ContactForm.setValue(data.value[0]);\r\n this.updateAsRead();\r\n });\r\n\r\n }\r\n back(){\r\n this.route.navigate(['/home/messages']);\r\n }\r\n\r\n}\r\n","\r\n {{title}}\r\n  \r\n \r\n
\r\n
\r\n \r\n Name\r\n \r\n \r\n Name\r\n is required.\r\n \r\n \r\n Email\r\n \r\n \r\n Email\r\n is required.\r\n Invalid\r\n Email.\r\n \r\n \r\n Subject\r\n \r\n \r\n Subject\r\n is required.\r\n \r\n \r\n Message\r\n \r\n \r\n Message\r\n is required.\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
0\">\r\n {{SuccessMessage}}\r\n
\r\n
\r\n \r\n \r\n \r\n
","import { Component, OnInit } from '@angular/core';\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport { MatTableDataSource } from '@angular/material/table';\r\nimport { ViewChild } from '@angular/core';\r\nimport { MatPaginator } from '@angular/material/paginator';\r\nimport { MatSort } from '@angular/material/sort';\r\nimport { IPage, List } from '../../../shared/interface';\r\nimport { NaomitsuService } from '../../../shared/databaseService';\r\nimport { SharedataService } from '../../../shared/sharedata.service';\r\nimport { SelectionModel } from '@angular/cdk/collections';\r\nimport { TokenStorageService } from 'src/app/_services/token-storage.service';\r\nimport { AlertService } from 'src/app/shared/components/alert/alert.service';\r\n\r\n@Component({\r\n selector: 'app-menu-config',\r\n templateUrl: './menu-config.component.html',\r\n styleUrls: ['./menu-config.component.scss']\r\n})\r\nexport class MenuConfigComponent implements OnInit {\r\n oldvalue: any;\r\n AllData: any[] = [];\r\n ParentPages: [{ PageId, PageTitle }];\r\n PageDetail: IPage;\r\n //SelectedData:PageDetail[] = [];\r\n DATA: any[] = [];\r\n\r\n columns: Array;\r\n title: string;\r\n Id: number;\r\n query: string;//displayedColumns: Array;\r\n list: List;\r\n\r\n displayedColumns = [];// ['id', 'name', 'progress', 'color'];\r\n dataSource: MatTableDataSource;\r\n\r\n @ViewChild(MatPaginator) paginator: MatPaginator;\r\n @ViewChild(MatSort) sort: MatSort;\r\n\r\n selection = new SelectionModel(true, []);\r\n\r\n ngOnInit() {\r\n this.checklogin();\r\n this.route.paramMap.subscribe(params => {\r\n this.Id = +params.get(\"parentid\");\r\n })\r\n this.GetParentPage(this.Id);\r\n }\r\n checklogin() {\r\n let options = {\r\n autoClose: true,\r\n keepAfterRouteChange: true\r\n };\r\n let token = this.tokenStorage.getToken();\r\n\r\n if (token == null) {\r\n this.alert.error(\"Access denied! login required.\", options);\r\n this.navigate.navigate(['/home']);\r\n }\r\n }\r\n getDetails(parentId) {\r\n\r\n this.list.fields = [\"*\", \"PageHistories/PageBody\", \"PageHistories/Version\"];\r\n this.list.lookupFields = [\"PageHistories\"];\r\n this.list.PageName = \"Pages\";\r\n //this.list.filter = ['Module eq 1'];\r\n this.list.orderBy = \"PageId desc\";\r\n const columns = [\"PageId\", \"PageTitle\", \"ParentPage\", \"ParentId\", \"Active\", \"Action\"];\r\n\r\n this.naomitsuService\r\n .get(this.list)\r\n .subscribe({\r\n next: (arrPage) => {\r\n //console.log('arrpage', arrPage);\r\n let arr = [];\r\n Object.keys(arrPage).map(function (key) {\r\n arr.push({ [key]: arrPage[key] })\r\n return arr;\r\n });\r\n\r\n arr[1].value.forEach((ele, key) => {\r\n\r\n let pPage = this.ParentPages.filter(page => { return page.PageId === ele.ParentId });\r\n this.DATA.push({\r\n PageId: ele.PageId,\r\n PageTitle: ele.PageTitle,\r\n ParentId: ele.ParentId,\r\n label: ele.label,\r\n faIcon: ele.faIcon,\r\n link: ele.link,\r\n IsTemplate: ele.IsTemplate,\r\n DisplayOrder: ele.DisplayOrder,\r\n HasSubmenu: ele.HasSubmenu,\r\n ParentPage: pPage.length > 0 ? pPage[0].PageTitle : '',\r\n Active: ele.Active,\r\n UpdateDate: ele.UpdateDate,\r\n HomePage: ele.HomePage,\r\n Action: \"\"\r\n })\r\n });\r\n this.AllData = [...this.DATA];\r\n\r\n },\r\n error: console.error\r\n });\r\n\r\n }\r\n constructor(private naomitsuService: NaomitsuService,\r\n private navigate: Router,\r\n private route: ActivatedRoute,\r\n private shareddata: SharedataService,\r\n private tokenStorage:TokenStorageService,\r\n private alert:AlertService) {\r\n this.list = new List();\r\n }\r\n\r\n\r\n /**\r\n * Set the paginator and sort after the view init since this component will\r\n * be able to query its view for the initialized paginator and sort.\r\n */\r\n ngAfterViewInit() {\r\n // if (this.paginator != undefined) {\r\n // this.dataSource.paginator = this.paginator;\r\n // this.dataSource.sort = this.sort;\r\n // }\r\n }\r\n createpage() {\r\n this.navigate.navigate(['/home/editor']);\r\n }\r\n view(pageId, pageTitle, parentId) {\r\n\r\n this.navigate.navigate(['/home/page/' + pageId], { queryParams: { pgid: parentId, pid: pageId, ptitle: pageTitle } });\r\n }\r\n createNew() {\r\n this.navigate.navigate(['/home/pages/']);\r\n }\r\n applyFilter(filterValue: string) {\r\n //console.log(\"this.AllData\", this.AllData.length)\r\n if (filterValue.length > 2) {\r\n let filtered = this.AllData.filter(item => {\r\n let parentPage=false;\r\n let title= item.PageTitle.toUpperCase().includes(filterValue.toUpperCase())\r\n if(item.ParentPage.length>0)\r\n {\r\n parentPage= item.ParentPage.toUpperCase().includes(filterValue.toUpperCase())\r\n }\r\n else\r\n parentPage= false;\r\n return (title || parentPage)\r\n \r\n });\r\n\r\n if (filtered.length > 0)\r\n this.DATA = [...filtered];\r\n else\r\n this.DATA = [];\r\n }\r\n else if (filterValue.length==0) {\r\n this.DATA =[...this.AllData];\r\n }\r\n\r\n // else if (filterValue == \"\")\r\n // this.DATA == this.AllData.filter((item, indx) => {\r\n // return indx < 10;\r\n // });\r\n }\r\n isAllSelected() {\r\n const numSelected = this.selection.selected.length;\r\n const numRows = this.dataSource.data.length;\r\n return numSelected === numRows;\r\n }\r\n getoldvalue(value: string) {\r\n this.oldvalue = value;\r\n // console.log('old value', this.oldvalue);\r\n }\r\n updateActive(columnName, element, event) {\r\n if (this.oldvalue == event)\r\n return;\r\n\r\n let PartialPage = {};\r\n debugger;\r\n switch (columnName) {\r\n case \"falcon\":\r\n element.falcon = event;\r\n //PartialPage.push({ \"falcon\": event });\r\n break;\r\n case \"link\":\r\n element.link = event;\r\n //PartialPage.push({ \"link\": event });\r\n break;\r\n case \"label\":\r\n element.label = event;\r\n //PartialPage.push({ \"label\": event });\r\n break;\r\n case \"DisplayOrder\":\r\n element.DisplayOrder = +event;\r\n //PartialPage.push({ \"DisplayOrder\": event });\r\n break;\r\n case \"HasSubmenu\":\r\n element.HasSubmenu = +event;\r\n //PartialPage.push({ \"HasSubmenu\": event });\r\n break;\r\n case \"IsTemplate\":\r\n element.IsTemplate = +event;\r\n //PartialPage.push({ \"IsTemplate\": event });\r\n break;\r\n case \"Active\":\r\n element.Active = +event;\r\n //PartialPage.push({ \"Active\": event });\r\n break;\r\n case \"PageTitle\":\r\n element.PageTitle = event;\r\n //PartialPage.push({ \"PageTitle\": event });\r\n break;\r\n case \"HomePage\":\r\n element.HomePage = event;\r\n //PartialPage.push({ \"PageTitle\": event });\r\n break;\r\n }\r\n //let checked = this.selection.toggle(element);\r\n //console.log('event', event);\r\n element.DisplayOrder = element.DisplayOrder == null ? 0 : element.DisplayOrder;\r\n element.faIcon = element.faIcon == undefined ? \"\" : element.faIcon;\r\n element.UpdateDate = new Date();\r\n let Id = element.PageId;\r\n delete element.PageId;\r\n delete element.Action;\r\n delete element.ParentPage;\r\n //PartialPage.push(element.faIcon);\r\n //PartialPage.UpdateDate = new Date();\r\n //console.log('PageDetail', PartialPage);\r\n //PageDetail.Active = event.checked == true ? 1 : 0;\r\n //PageDetail.UpdateDate = new Date();\r\n PartialPage = element;\r\n this.naomitsuService.postPatch('Pages', PartialPage, Id, 'patch')\r\n .subscribe(\r\n (data: any) => {\r\n //alert('data updated.')\r\n this.getDetails(Id);\r\n })\r\n }\r\n /** Selects all rows if they are not all selected; otherwise clear selection. */\r\n masterToggle() {\r\n this.isAllSelected() ?\r\n this.selection.clear() :\r\n this.dataSource.data.forEach(row => this.selection.select(row));\r\n }\r\n\r\n GetParentPage(parentId) {\r\n let list: List = new List();\r\n list.fields = [\"PageId\", \"PageTitle\"];\r\n list.PageName = \"Pages\";\r\n if (parentId == undefined)\r\n list.filter = [\"Active eq 1 and ParentId eq 0\"];\r\n else\r\n list.filter = [\"Active eq 1 and ParentId eq \" + parentId];\r\n\r\n this.naomitsuService.get(list)\r\n .subscribe((data: any) => {\r\n this.ParentPages = data.value;\r\n //console.log(\"parent pages\", this.ParentPages);\r\n\r\n this.getDetails(parentId);\r\n //return data.value;\r\n\r\n });\r\n\r\n }\r\n}\r\n\r\nfunction flatten(data) {\r\n var result = {};\r\n function recurse(cur, prop) {\r\n if (Object(cur) !== cur) {\r\n result[prop] = cur;\r\n } else if (Array.isArray(cur)) {\r\n for (var i = 0, l = cur.length; i < l; i++)\r\n recurse(cur[i], prop + \"[\" + i + \"]\");\r\n if (l == 0)\r\n result[prop] = [];\r\n } else {\r\n var isEmpty = true;\r\n for (var p in cur) {\r\n isEmpty = false;\r\n recurse(cur[p], prop ? prop + \".\" + p : p);\r\n }\r\n if (isEmpty && prop)\r\n result[prop] = {};\r\n }\r\n }\r\n recurse(data, \"\");\r\n return result;\r\n}\r\n\r\n","\r\n Configuration\r\n \r\n \r\n
\r\n \r\n \r\n \r\n
\r\n\r\n
\r\n
\r\n Title\r\n
\r\n
\r\n Parent\r\n
\r\n
\r\n Icon\r\n
\r\n
\r\n Link\r\n
\r\n
\r\n label\r\n
\r\n
\r\n Order\r\n
\r\n
\r\n Has submenu\r\n
\r\n
\r\n Template\r\n
\r\n
\r\n Home Page\r\n
\r\n
\r\n Active\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
","import { Component, OnInit } from '@angular/core';\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport { MatTableDataSource } from '@angular/material/table';\r\nimport { ViewChild } from '@angular/core';\r\nimport { MatPaginator } from '@angular/material/paginator';\r\n//import { MatSort } from '@angular/material/sort';\r\nimport { INews, IPage, List } from '../../shared/interface';\r\nimport { NaomitsuService } from '../../shared/databaseService';\r\nimport { SharedataService } from '../../shared/sharedata.service';\r\n//import { SelectionModel } from '@angular/cdk/collections';\r\nimport { DomSanitizer } from '@angular/platform-browser';\r\nimport { DatePipe } from '@angular/common';\r\nimport { MatSort } from '@angular/material/sort';\r\n@Component({\r\n selector: 'app-allnewsdashboard',\r\n templateUrl: './allnewsdashboard.component.html',\r\n styleUrls: ['./allnewsdashboard.component.scss']\r\n})\r\nexport class AllNewsdashboardComponent implements OnInit {\r\n PageTitle: string = \"News & Events\";\r\n ParentPages: [{ PageId, PageTitle }];\r\n PageDetail: IPage;\r\n //SelectedData:PageDetail[] = [];\r\n DATA = [];\r\n AllData = [];\r\n //columns: Array;\r\n title: string;\r\n Id: number = 0;\r\n query: string;//displayedColumns: Array;\r\n list: List;\r\n\r\n displayedColumns = [];// ['id', 'name', 'progress', 'color'];\r\n dataSource: MatTableDataSource;\r\n\r\n @ViewChild(MatPaginator) paginator: MatPaginator;\r\n @ViewChild(MatSort) sort: MatSort;\r\n\r\n //selection = new SelectionModel(true, []);\r\n\r\n ngOnInit() {\r\n // this.route.paramMap.subscribe(params => {\r\n // this.Id = +params.get(\"parentid\");\r\n // })\r\n // if (this.Id == 0)\r\n // this.getNewsNEventID()\r\n // else\r\n \r\n this.shareddata.CurrentNewsNEventId.subscribe(e => {\r\n this.Id = e\r\n //this.getDetails(this.Id);\r\n this.shareddata.CurrentPagesData.subscribe(m=>{\r\n this.DATA=m\r\n this.getDetails();\r\n })\r\n \r\n });\r\n \r\n // console.log('shared data', this.shareddata.getData());\r\n } \r\n getDetails() {\r\n\r\n this.AllData = this.DATA.filter(f=>{\r\n return f.ParentId==this.Id;\r\n }).sort((a,b)=> {\r\n return +new Date(b.UpdateDate) - +new Date(a.UpdateDate)\r\n })\r\n .map(item=>{\r\n return {\r\n Title:item.label,\r\n //:item.link.split('/')[3],\r\n Link:item.link,\r\n UpdateDate: item.UpdateDate\r\n }\r\n })\r\n this.displayedColumns = [\"Title\",\"UpdateDate\"];//this.columns.map(c => c.columnDef);\r\n this.dataSource = new MatTableDataSource(this.AllData);\r\n this.dataSource.paginator = this.paginator;\r\n this.dataSource.sort = this.sort;\r\n\r\n }\r\n constructor(private naomitsuService: NaomitsuService,\r\n private navigate: Router,\r\n private route: ActivatedRoute,\r\n private shareddata: SharedataService,\r\n private sanitize: DomSanitizer,\r\n private datePipe: DatePipe) {\r\n this.list = new List();\r\n }\r\n\r\n\r\n /**\r\n * Set the paginator and sort after the view init since this component will\r\n * be able to query its view for the initialized paginator and sort.\r\n */\r\n ngAfterViewInit() {\r\n // if (this.paginator != undefined) {\r\n // this.dataSource.paginator = this.paginator;\r\n // this.dataSource.sort = this.sort;\r\n // }\r\n }\r\n HiddenBadge(newsdate): boolean {\r\n //return false;\r\n let today = new Date();\r\n let badgeDate = this.datePipe.transform(today, 'yyyy/MM/dd');//today.setDate(today.getDate()-2);\r\n let NewsDate = this.datePipe.transform(newsdate, 'yyyy/MM/dd');\r\n //console.log('newsdate',NewsDate)\r\n //console.log('badgeDate',badgeDate)\r\n //console.log(newsdate 2) {\r\n filterValue = filterValue.trim(); // Remove whitespace\r\n //filterValue = filterValue.toLowerCase(); // Datasource defaults to lowercase matches\r\n this.DATA = this.AllData.filter(item => item.Body.toUpperCase().includes(filterValue.toUpperCase()) || item.Title.toUpperCase().includes(filterValue.toUpperCase()))\r\n this.dataSource = new MatTableDataSource(this.DATA);//.filter = filterValue;\r\n }\r\n else if (filterValue.length == 0) {\r\n this.dataSource = new MatTableDataSource(this.AllData);\r\n }\r\n }\r\n\r\n}\r\n\r\n","\r\n All {{PageTitle}}\r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n Title \r\n \r\n \r\n \r\n
{{element.Title}}\r\n
\r\n {{element.UpdateDate|date:'dd/MM/yyyy'}}\r\n
\r\n
\r\n \r\n
\r\n \r\n Date \r\n {{element.UpdateDate|date:'dd/MM/yyyy'}} \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
","import { NgModule } from \"@angular/core\";\r\nimport { Ng2ImgMaxService } from \"./ng2-img-max.service\";\r\nimport { ImgMaxSizeService } from \"./img-max-size.service\";\r\nimport { ImgMaxPXSizeService } from \"./img-maxpx-size.service\";\r\nimport { ImgExifService } from \"./img-exif.service\";\r\nimport { Ng2PicaModule } from \"ng2-pica\";\r\nimport * as ɵngcc0 from '@angular/core';\nvar Ng2ImgMaxModule = /** @class */ (function () {\r\n function Ng2ImgMaxModule() {\r\n }\nNg2ImgMaxModule.ɵmod = ɵngcc0.ɵɵdefineNgModule({ type: Ng2ImgMaxModule });\nNg2ImgMaxModule.ɵinj = ɵngcc0.ɵɵdefineInjector({ factory: function Ng2ImgMaxModule_Factory(t) { return new (t || Ng2ImgMaxModule)(); }, providers: [\n { provide: ImgMaxPXSizeService, useClass: ImgMaxPXSizeService },\n { provide: ImgMaxSizeService, useClass: ImgMaxSizeService },\n { provide: ImgExifService, useClass: ImgExifService },\n { provide: Ng2ImgMaxService, useClass: Ng2ImgMaxService }\n ], imports: [[\n Ng2PicaModule\n ]] });\n(function () { (typeof ngJitMode === \"undefined\" || ngJitMode) && ɵngcc0.ɵɵsetNgModuleScope(Ng2ImgMaxModule, { imports: function () { return [Ng2PicaModule]; } }); })();\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(Ng2ImgMaxModule, [{\n type: NgModule,\n args: [{\n imports: [\n Ng2PicaModule\n ],\n providers: [\n { provide: ImgMaxPXSizeService, useClass: ImgMaxPXSizeService },\n { provide: ImgMaxSizeService, useClass: ImgMaxSizeService },\n { provide: ImgExifService, useClass: ImgExifService },\n { provide: Ng2ImgMaxService, useClass: Ng2ImgMaxService }\n ]\n }]\n }], function () { return []; }, null); })();\r\n return Ng2ImgMaxModule;\r\n}());\r\nexport { Ng2ImgMaxModule };\r\n\n//# sourceMappingURL=ng2-img-max.module.js.map","import { Injectable, ɵɵdefineInjectable, EventEmitter, Component, ViewEncapsulation, ViewChild, Input, Output, NgModule } from '@angular/core';\nimport Cropper from 'cropperjs';\nimport { NgbModal, NgbModalModule } from '@ng-bootstrap/ng-bootstrap';\n\n/**\r\n * @fileoverview added by tsickle\r\n * Generated from: lib/ngx-photo-editor.service.ts\r\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\r\n */\r\nimport * as ɵngcc0 from '@angular/core';\nimport * as ɵngcc1 from '@ng-bootstrap/ng-bootstrap';\n\nconst _c0 = [\"ngxPhotoEditorContent\"];\nfunction NgxPhotoEditorComponent_ng_template_0_Template(rf, ctx) { if (rf & 1) {\n const _r5 = ɵngcc0.ɵɵgetCurrentView();\n ɵngcc0.ɵɵelementStart(0, \"div\", 2);\n ɵngcc0.ɵɵelementStart(1, \"h5\", 3);\n ɵngcc0.ɵɵtext(2);\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(3, \"div\", 4);\n ɵngcc0.ɵɵelementStart(4, \"img\", 5, 6);\n ɵngcc0.ɵɵlistener(\"load\", function NgxPhotoEditorComponent_ng_template_0_Template_img_load_4_listener() { ɵngcc0.ɵɵrestoreView(_r5); const _r3 = ɵngcc0.ɵɵreference(5); const ctx_r4 = ɵngcc0.ɵɵnextContext(); return ctx_r4.onImageLoad(_r3); });\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(6, \"div\", 7);\n ɵngcc0.ɵɵelementStart(7, \"i\", 8);\n ɵngcc0.ɵɵlistener(\"click\", function NgxPhotoEditorComponent_ng_template_0_Template_i_click_7_listener() { ɵngcc0.ɵɵrestoreView(_r5); const ctx_r6 = ɵngcc0.ɵɵnextContext(); return ctx_r6.crop(); });\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(8, \"i\", 9);\n ɵngcc0.ɵɵlistener(\"click\", function NgxPhotoEditorComponent_ng_template_0_Template_i_click_8_listener() { ɵngcc0.ɵɵrestoreView(_r5); const ctx_r7 = ɵngcc0.ɵɵnextContext(); return ctx_r7.move(); });\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(9, \"i\", 10);\n ɵngcc0.ɵɵlistener(\"click\", function NgxPhotoEditorComponent_ng_template_0_Template_i_click_9_listener() { ɵngcc0.ɵɵrestoreView(_r5); const ctx_r8 = ɵngcc0.ɵɵnextContext(); return ctx_r8.zoomIn(); });\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(10, \"i\", 11);\n ɵngcc0.ɵɵlistener(\"click\", function NgxPhotoEditorComponent_ng_template_0_Template_i_click_10_listener() { ɵngcc0.ɵɵrestoreView(_r5); const ctx_r9 = ɵngcc0.ɵɵnextContext(); return ctx_r9.zoomOut(); });\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(11, \"i\", 12);\n ɵngcc0.ɵɵlistener(\"click\", function NgxPhotoEditorComponent_ng_template_0_Template_i_click_11_listener() { ɵngcc0.ɵɵrestoreView(_r5); const ctx_r10 = ɵngcc0.ɵɵnextContext(); return ctx_r10.flipV(); });\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(12, \"i\", 13);\n ɵngcc0.ɵɵlistener(\"click\", function NgxPhotoEditorComponent_ng_template_0_Template_i_click_12_listener() { ɵngcc0.ɵɵrestoreView(_r5); const ctx_r11 = ɵngcc0.ɵɵnextContext(); return ctx_r11.flipH(); });\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(13, \"i\", 14);\n ɵngcc0.ɵɵlistener(\"click\", function NgxPhotoEditorComponent_ng_template_0_Template_i_click_13_listener() { ɵngcc0.ɵɵrestoreView(_r5); const ctx_r12 = ɵngcc0.ɵɵnextContext(); return ctx_r12.rotateLeft(); });\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(14, \"i\", 15);\n ɵngcc0.ɵɵlistener(\"click\", function NgxPhotoEditorComponent_ng_template_0_Template_i_click_14_listener() { ɵngcc0.ɵɵrestoreView(_r5); const ctx_r13 = ɵngcc0.ɵɵnextContext(); return ctx_r13.rotateRight(); });\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(15, \"i\", 16);\n ɵngcc0.ɵɵlistener(\"click\", function NgxPhotoEditorComponent_ng_template_0_Template_i_click_15_listener() { ɵngcc0.ɵɵrestoreView(_r5); const ctx_r14 = ɵngcc0.ɵɵnextContext(); return ctx_r14.reset(); });\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(16, \"div\", 17);\n ɵngcc0.ɵɵelementStart(17, \"button\", 18);\n ɵngcc0.ɵɵlistener(\"click\", function NgxPhotoEditorComponent_ng_template_0_Template_button_click_17_listener() { ɵngcc0.ɵɵrestoreView(_r5); const modal_r2 = ctx.$implicit; const ctx_r15 = ɵngcc0.ɵɵnextContext(); ctx_r15.export(); return modal_r2.close(); });\n ɵngcc0.ɵɵtext(18, \"Apply\");\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementStart(19, \"button\", 19);\n ɵngcc0.ɵɵlistener(\"click\", function NgxPhotoEditorComponent_ng_template_0_Template_button_click_19_listener() { const modal_r2 = ctx.$implicit; return modal_r2.close(); });\n ɵngcc0.ɵɵtext(20, \"Cancel \");\n ɵngcc0.ɵɵelementEnd();\n ɵngcc0.ɵɵelementEnd();\n} if (rf & 2) {\n const ctx_r1 = ɵngcc0.ɵɵnextContext();\n ɵngcc0.ɵɵstyleProp(\"background-color\", ctx_r1.darkTheme ? \"#36393F\" : \"#D8D8D8\");\n ɵngcc0.ɵɵadvance(1);\n ɵngcc0.ɵɵstyleProp(\"color\", ctx_r1.darkTheme ? \"white\" : \"black\");\n ɵngcc0.ɵɵadvance(1);\n ɵngcc0.ɵɵtextInterpolate(ctx_r1.modalTitle);\n ɵngcc0.ɵɵadvance(1);\n ɵngcc0.ɵɵstyleProp(\"height\", ctx_r1.canvasHeight + \"px\");\n ɵngcc0.ɵɵadvance(1);\n ɵngcc0.ɵɵproperty(\"src\", ctx_r1.url, ɵngcc0.ɵɵsanitizeUrl);\n ɵngcc0.ɵɵadvance(12);\n ɵngcc0.ɵɵstyleProp(\"background-color\", ctx_r1.darkTheme ? \"#36393F\" : \"#D8D8D8\");\n ɵngcc0.ɵɵadvance(3);\n ɵngcc0.ɵɵclassProp(\"btn-outline-dark\", !ctx_r1.darkTheme)(\"btn-outline-light\", ctx_r1.darkTheme);\n} }\nclass NgxPhotoEditorService {\r\n constructor() {\r\n }\r\n}\nNgxPhotoEditorService.ɵfac = function NgxPhotoEditorService_Factory(t) { return new (t || NgxPhotoEditorService)(); };\nNgxPhotoEditorService.ɵprov = ɵngcc0.ɵɵdefineInjectable({ token: NgxPhotoEditorService, factory: NgxPhotoEditorService.ɵfac, providedIn: 'root' });\r\n/** @nocollapse */\r\nNgxPhotoEditorService.ctorParameters = () => [];\r\n/** @nocollapse */ NgxPhotoEditorService.ngInjectableDef = ɵɵdefineInjectable({ factory: function NgxPhotoEditorService_Factory() { return new NgxPhotoEditorService(); }, token: NgxPhotoEditorService, providedIn: \"root\" });\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(NgxPhotoEditorService, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], function () { return []; }, null); })();\n\n/**\r\n * @fileoverview added by tsickle\r\n * Generated from: lib/ngx-photo-editor.component.ts\r\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\r\n */\r\nclass NgxPhotoEditorComponent {\r\n /**\r\n * @param {?} modalService\r\n */\r\n constructor(modalService) {\r\n this.modalService = modalService;\r\n this.prevZoom = 0;\r\n this.modalTitle = 'Photo Editor';\r\n this.aspectRatio = 1;\r\n this.autoCropArea = 1;\r\n this.autoCrop = true;\r\n this.mask = true;\r\n this.guides = true;\r\n this.centerIndicator = true;\r\n this.viewMode = 0;\r\n this.modalCentered = false;\r\n this.scalable = true;\r\n this.zoomable = true;\r\n this.cropBoxMovable = true;\r\n this.cropBoxResizable = true;\r\n this.darkTheme = true;\r\n this.roundCropper = false;\r\n this.canvasHeight = 400;\r\n this.imageSmoothingEnabled = true;\r\n this.imageSmoothingQuality = 'high';\r\n this.lastUpdate = Date.now();\r\n this.format = 'png';\r\n this.quality = 92;\r\n this.isFormatDefined = false;\r\n this.imageCropped = new EventEmitter();\r\n }\r\n /**\r\n * @param {?} value\r\n * @return {?}\r\n */\r\n set imageQuality(value) {\r\n if (value > 0 && value <= 100) {\r\n this.quality = value;\r\n }\r\n }\r\n /**\r\n * @param {?} type\r\n * @return {?}\r\n */\r\n set imageFormat(type) {\r\n if ((/^(gif|jpe?g|tiff|png|webp|bmp)$/i).test(type)) {\r\n this.format = type;\r\n this.isFormatDefined = true;\r\n }\r\n }\r\n /**\r\n * @param {?} url\r\n * @return {?}\r\n */\r\n set imageUrl(url) {\r\n if (url) {\r\n this.url = url;\r\n if (this.lastUpdate !== Date.now()) {\r\n this.open();\r\n this.lastUpdate = Date.now();\r\n }\r\n }\r\n }\r\n /**\r\n * @param {?} base64\r\n * @return {?}\r\n */\r\n set imageBase64(base64) {\r\n if (base64 && (/^data:image\\/([a-zA-Z]*);base64,([^\\\"]*)$/).test(base64)) {\r\n this.imageUrl = base64;\r\n if (!this.isFormatDefined) {\r\n this.format = ((base64.split(',')[0]).split(';')[0]).split(':')[1].split('/')[1];\r\n }\r\n }\r\n }\r\n /**\r\n * @param {?} event\r\n * @return {?}\r\n */\r\n set imageChanedEvent(event) {\r\n if (event) {\r\n /** @type {?} */\r\n const file = event.target.files[0];\r\n if (file && (/\\.(gif|jpe?g|tiff|png|webp|bmp)$/i).test(file.name)) {\r\n if (!this.isFormatDefined) {\r\n this.format = event.target.files[0].type.split('/')[1];\r\n }\r\n /** @type {?} */\r\n const reader = new FileReader();\r\n reader.onload = (/**\r\n * @param {?} ev\r\n * @return {?}\r\n */\r\n (ev) => {\r\n this.imageUrl = ev.target.result;\r\n });\r\n reader.readAsDataURL(event.target.files[0]);\r\n }\r\n }\r\n }\r\n /**\r\n * @param {?} file\r\n * @return {?}\r\n */\r\n set imageFile(file) {\r\n if (file && (/\\.(gif|jpe?g|tiff|png|webp|bmp)$/i).test(file.name)) {\r\n if (!this.isFormatDefined) {\r\n this.format = file.type.split('/')[1];\r\n }\r\n /** @type {?} */\r\n const reader = new FileReader();\r\n reader.onload = (/**\r\n * @param {?} ev\r\n * @return {?}\r\n */\r\n (ev) => {\r\n this.imageUrl = ev.target.result;\r\n });\r\n reader.readAsDataURL(file);\r\n }\r\n }\r\n /**\r\n * @param {?} image\r\n * @return {?}\r\n */\r\n onImageLoad(image) {\r\n image.addEventListener('ready', (/**\r\n * @return {?}\r\n */\r\n () => {\r\n if (this.roundCropper) {\r\n ((/** @type {?} */ (document.getElementsByClassName('cropper-view-box')[0]))).style.borderRadius = '50%';\r\n ((/** @type {?} */ (document.getElementsByClassName('cropper-face')[0]))).style.borderRadius = '50%';\r\n }\r\n }));\r\n this.cropper = new Cropper(image, {\r\n aspectRatio: this.aspectRatio,\r\n autoCropArea: this.autoCropArea,\r\n autoCrop: this.autoCrop,\r\n modal: this.mask,\r\n // black mask\r\n guides: this.guides,\r\n // grid\r\n center: this.centerIndicator,\r\n // center indicator\r\n viewMode: this.viewMode,\r\n scalable: this.scalable,\r\n zoomable: this.zoomable,\r\n cropBoxMovable: this.cropBoxMovable,\r\n cropBoxResizable: this.cropBoxResizable,\r\n });\r\n }\r\n /**\r\n * @return {?}\r\n */\r\n rotateRight() {\r\n this.cropper.rotate(45);\r\n }\r\n /**\r\n * @return {?}\r\n */\r\n rotateLeft() {\r\n this.cropper.rotate(-45);\r\n }\r\n /**\r\n * @return {?}\r\n */\r\n crop() {\r\n this.cropper.setDragMode('crop');\r\n }\r\n /**\r\n * @return {?}\r\n */\r\n move() {\r\n this.cropper.setDragMode('move');\r\n }\r\n /**\r\n * @param {?} event\r\n * @return {?}\r\n */\r\n zoom(event) {\r\n /** @type {?} */\r\n const value = Number(event.target.value);\r\n this.cropper.zoom(value - this.prevZoom);\r\n this.prevZoom = value;\r\n }\r\n /**\r\n * @return {?}\r\n */\r\n zoomIn() {\r\n this.cropper.zoom(0.1);\r\n }\r\n /**\r\n * @return {?}\r\n */\r\n zoomOut() {\r\n this.cropper.zoom(-0.1);\r\n }\r\n /**\r\n * @return {?}\r\n */\r\n flipH() {\r\n this.cropper.scaleX(-this.cropper.getImageData().scaleX);\r\n }\r\n /**\r\n * @return {?}\r\n */\r\n flipV() {\r\n this.cropper.scaleY(-this.cropper.getImageData().scaleY);\r\n }\r\n /**\r\n * @return {?}\r\n */\r\n reset() {\r\n this.cropper.reset();\r\n }\r\n /**\r\n * @return {?}\r\n */\r\n export() {\r\n /** @type {?} */\r\n let cropedImage;\r\n if (this.resizeToWidth && this.resizeToHeight) {\r\n cropedImage = this.cropper.getCroppedCanvas({\r\n width: this.resizeToWidth,\r\n imageSmoothingEnabled: this.imageSmoothingEnabled,\r\n imageSmoothingQuality: this.imageSmoothingQuality\r\n });\r\n }\r\n else if (this.resizeToHeight) {\r\n cropedImage = this.cropper.getCroppedCanvas({\r\n height: this.resizeToHeight,\r\n imageSmoothingEnabled: this.imageSmoothingEnabled,\r\n imageSmoothingQuality: this.imageSmoothingQuality\r\n });\r\n }\r\n else if (this.resizeToWidth) {\r\n cropedImage = this.cropper.getCroppedCanvas({\r\n width: this.resizeToWidth,\r\n imageSmoothingEnabled: this.imageSmoothingEnabled,\r\n imageSmoothingQuality: this.imageSmoothingQuality\r\n });\r\n }\r\n else {\r\n cropedImage = this.cropper.getCroppedCanvas({\r\n imageSmoothingEnabled: this.imageSmoothingEnabled,\r\n imageSmoothingQuality: this.imageSmoothingQuality\r\n });\r\n }\r\n this.outputImage = cropedImage.toDataURL('image/' + this.format, this.quality);\r\n cropedImage.toBlob((/**\r\n * @param {?} blob\r\n * @return {?}\r\n */\r\n blob => {\r\n this.imageCropped.emit({\r\n base64: this.outputImage,\r\n file: new File([blob], Date.now() + '.' + this.format, { type: 'image/' + this.format })\r\n });\r\n }), 'image/' + this.format, this.quality / 100);\r\n }\r\n /**\r\n * @return {?}\r\n */\r\n open() {\r\n this.modalService.open(this.content, { size: this.modalSize, centered: this.modalCentered, backdrop: 'static' });\r\n }\r\n}\nNgxPhotoEditorComponent.ɵfac = function NgxPhotoEditorComponent_Factory(t) { return new (t || NgxPhotoEditorComponent)(ɵngcc0.ɵɵdirectiveInject(ɵngcc1.NgbModal)); };\nNgxPhotoEditorComponent.ɵcmp = ɵngcc0.ɵɵdefineComponent({ type: NgxPhotoEditorComponent, selectors: [[\"ngx-photo-editor\"]], viewQuery: function NgxPhotoEditorComponent_Query(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵviewQuery(_c0, true);\n } if (rf & 2) {\n let _t;\n ɵngcc0.ɵɵqueryRefresh(_t = ɵngcc0.ɵɵloadQuery()) && (ctx.content = _t.first);\n } }, inputs: { modalTitle: \"modalTitle\", aspectRatio: \"aspectRatio\", autoCropArea: \"autoCropArea\", autoCrop: \"autoCrop\", mask: \"mask\", guides: \"guides\", centerIndicator: \"centerIndicator\", viewMode: \"viewMode\", modalCentered: \"modalCentered\", scalable: \"scalable\", zoomable: \"zoomable\", cropBoxMovable: \"cropBoxMovable\", cropBoxResizable: \"cropBoxResizable\", darkTheme: \"darkTheme\", roundCropper: \"roundCropper\", canvasHeight: \"canvasHeight\", imageSmoothingEnabled: \"imageSmoothingEnabled\", imageSmoothingQuality: \"imageSmoothingQuality\", imageQuality: \"imageQuality\", imageFormat: \"imageFormat\", imageUrl: \"imageUrl\", imageBase64: \"imageBase64\", imageChanedEvent: \"imageChanedEvent\", imageFile: \"imageFile\", modalSize: \"modalSize\", resizeToWidth: \"resizeToWidth\", resizeToHeight: \"resizeToHeight\" }, outputs: { imageCropped: \"imageCropped\" }, decls: 2, vars: 0, consts: [[\"id\", \"ngx-photo-editor-modal\"], [\"ngxPhotoEditorContent\", \"\"], [1, \"modal-body\", 2, \"padding-bottom\", \"0\"], [2, \"margin-bottom\", \"16px\"], [1, \"ngx-photo-editor-img-container\"], [\"crossorigin\", \"\", \"id\", \"ngx-photo-editor-image\", 3, \"src\", \"load\"], [\"image\", \"\"], [1, \"ngx-photo-editor-icons-container\"], [1, \"fas\", \"fa-crop-alt\", 3, \"click\"], [1, \"fas\", \"fa-arrows-alt\", 3, \"click\"], [1, \"fas\", \"fa-search-plus\", 3, \"click\"], [1, \"fas\", \"fa-search-minus\", 3, \"click\"], [1, \"fas\", \"fa-arrows-alt-v\", 3, \"click\"], [1, \"fas\", \"fa-arrows-alt-h\", 3, \"click\"], [1, \"fas\", \"fa-undo-alt\", 3, \"click\"], [1, \"fas\", \"fa-redo-alt\", 3, \"click\"], [1, \"fas\", \"fa-sync-alt\", 3, \"click\"], [1, \"ngx-photo-editor-custom-modal-footer\"], [\"type\", \"button\", 1, \"btn\", \"btn-primary\", 3, \"click\"], [\"type\", \"button\", 1, \"btn\", 3, \"click\"]], template: function NgxPhotoEditorComponent_Template(rf, ctx) { if (rf & 1) {\n ɵngcc0.ɵɵtemplate(0, NgxPhotoEditorComponent_ng_template_0_Template, 21, 14, \"ng-template\", 0, 1, ɵngcc0.ɵɵtemplateRefExtractor);\n } }, styles: [\"@import url(https://use.fontawesome.com/releases/v5.8.2/css/all.css);@import url(https://stackpath.bootstrapcdn.com/bootstrap/4.4.1/css/bootstrap.min.css);.ngx-photo-editor-ngx-photo-editor-img-container{width:100%;float:left}#ngx-photo-editor-image{display:block;max-width:100%}.ngx-photo-editor-modal-content{border:none;border-radius:5px;overflow:hidden}.ngx-photo-editor-icons-container{background-color:#8f8f8f;color:#fff;padding:15px;text-align:center;outline:0;border:none}.ngx-photo-editor-icons-container>i{padding-right:15px;transition:color .5s;cursor:pointer}.ngx-photo-editor-icons-container>i:nth-child(even){padding-right:30px}.ngx-photo-editor-icons-container>i:last-child{padding-right:0}.ngx-photo-editor-icons-container>i:hover{color:#000}.ngx-photo-editor-custom-modal-footer{padding:16px}.ngx-photo-editor-custom-modal-footer>button{padding:5px 20px!important;font-size:12px!important;float:right;margin-left:10px}/*!\\r\\n * Cropper.js v1.5.7\\r\\n * https://fengyuanchen.github.io/cropperjs\\r\\n *\\r\\n * Copyright 2015-present Chen Fengyuan\\r\\n * Released under the MIT license\\r\\n *\\r\\n * Date: 2020-05-23T05:22:57.283Z\\r\\n */.cropper-container{direction:ltr;font-size:0;line-height:0;position:relative;touch-action:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.cropper-container img{display:block;height:100%;image-orientation:0deg;max-height:none!important;max-width:none!important;min-height:0!important;min-width:0!important;width:100%}.cropper-canvas,.cropper-crop-box,.cropper-drag-box,.cropper-modal,.cropper-wrap-box{bottom:0;left:0;position:absolute;right:0;top:0}.cropper-canvas,.cropper-wrap-box{overflow:hidden}.cropper-drag-box{background-color:#fff;opacity:0}.cropper-modal{background-color:#000;opacity:.5}.cropper-view-box{display:block;height:100%;outline:rgba(51,153,255,.75) solid 1px;overflow:hidden;width:100%}.cropper-dashed{border:0 dashed #eee;display:block;opacity:.5;position:absolute}.cropper-dashed.dashed-h{border-bottom-width:1px;border-top-width:1px;height:calc(100% / 3);left:0;top:calc(100% / 3);width:100%}.cropper-dashed.dashed-v{border-left-width:1px;border-right-width:1px;height:100%;left:calc(100% / 3);top:0;width:calc(100% / 3)}.cropper-center{display:block;height:0;left:50%;opacity:.75;position:absolute;top:50%;width:0}.cropper-center::after,.cropper-center::before{background-color:#eee;content:' ';display:block;position:absolute}.cropper-center::before{height:1px;left:-3px;top:0;width:7px}.cropper-center::after{height:7px;left:0;top:-3px;width:1px}.cropper-face,.cropper-line,.cropper-point{display:block;height:100%;opacity:.1;position:absolute;width:100%}.cropper-face{background-color:#fff;left:0;top:0}.cropper-line{background-color:#39f}.cropper-line.line-e{cursor:ew-resize;right:-3px;top:0;width:5px}.cropper-line.line-n{cursor:ns-resize;height:5px;left:0;top:-3px}.cropper-line.line-w{cursor:ew-resize;left:-3px;top:0;width:5px}.cropper-line.line-s{bottom:-3px;cursor:ns-resize;height:5px;left:0}.cropper-point{background-color:#39f;height:5px;opacity:.75;width:5px}.cropper-point.point-e{cursor:ew-resize;margin-top:-3px;right:-3px;top:50%}.cropper-point.point-n{cursor:ns-resize;left:50%;margin-left:-3px;top:-3px}.cropper-point.point-w{cursor:ew-resize;left:-3px;margin-top:-3px;top:50%}.cropper-point.point-s{bottom:-3px;cursor:s-resize;left:50%;margin-left:-3px}.cropper-point.point-ne{cursor:nesw-resize;right:-3px;top:-3px}.cropper-point.point-nw{cursor:nwse-resize;left:-3px;top:-3px}.cropper-point.point-sw{bottom:-3px;cursor:nesw-resize;left:-3px}.cropper-point.point-se{bottom:-3px;cursor:nwse-resize;height:20px;opacity:1;right:-3px;width:20px}@media (min-width:768px){.cropper-point.point-se{height:15px;width:15px}}@media (min-width:992px){.cropper-point.point-se{height:10px;width:10px}}@media (min-width:1200px){.cropper-point.point-se{height:5px;opacity:.75;width:5px}}.cropper-point.point-se::before{background-color:#39f;bottom:-50%;content:' ';display:block;height:200%;opacity:0;position:absolute;right:-50%;width:200%}.cropper-invisible{opacity:0}.cropper-bg{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAAA3NCSVQICAjb4U/gAAAABlBMVEXMzMz////TjRV2AAAACXBIWXMAAArrAAAK6wGCiw1aAAAAHHRFWHRTb2Z0d2FyZQBBZG9iZSBGaXJld29ya3MgQ1M26LyyjAAAABFJREFUCJlj+M/AgBVhF/0PAH6/D/HkDxOGAAAAAElFTkSuQmCC)}.cropper-hide{display:block;height:0;position:absolute;width:0}.cropper-hidden{display:none!important}.cropper-move{cursor:move}.cropper-crop{cursor:crosshair}.cropper-disabled .cropper-drag-box,.cropper-disabled .cropper-face,.cropper-disabled .cropper-line,.cropper-disabled .cropper-point{cursor:not-allowed}\"], encapsulation: 2 });\r\n/** @nocollapse */\r\nNgxPhotoEditorComponent.ctorParameters = () => [\r\n { type: NgbModal }\r\n];\r\nNgxPhotoEditorComponent.propDecorators = {\r\n content: [{ type: ViewChild, args: ['ngxPhotoEditorContent', { static: false },] }],\r\n modalTitle: [{ type: Input }],\r\n aspectRatio: [{ type: Input }],\r\n autoCropArea: [{ type: Input }],\r\n autoCrop: [{ type: Input }],\r\n mask: [{ type: Input }],\r\n guides: [{ type: Input }],\r\n centerIndicator: [{ type: Input }],\r\n viewMode: [{ type: Input }],\r\n modalSize: [{ type: Input }],\r\n modalCentered: [{ type: Input }],\r\n scalable: [{ type: Input }],\r\n zoomable: [{ type: Input }],\r\n cropBoxMovable: [{ type: Input }],\r\n cropBoxResizable: [{ type: Input }],\r\n darkTheme: [{ type: Input }],\r\n roundCropper: [{ type: Input }],\r\n canvasHeight: [{ type: Input }],\r\n resizeToWidth: [{ type: Input }],\r\n resizeToHeight: [{ type: Input }],\r\n imageSmoothingEnabled: [{ type: Input }],\r\n imageSmoothingQuality: [{ type: Input }],\r\n imageCropped: [{ type: Output }],\r\n imageQuality: [{ type: Input }],\r\n imageFormat: [{ type: Input }],\r\n imageUrl: [{ type: Input }],\r\n imageBase64: [{ type: Input }],\r\n imageChanedEvent: [{ type: Input }],\r\n imageFile: [{ type: Input }]\r\n};\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(NgxPhotoEditorComponent, [{\n type: Component,\n args: [{\n // tslint:disable-next-line:component-selector\n selector: 'ngx-photo-editor',\n template: \"\\r\\n
\\r\\n
{{modalTitle}}
\\r\\n
\\r\\n \\r\\n
\\r\\n
\\r\\n \\r\\n \\r\\n \\r\\n
\\r\\n \\r\\n \\r\\n \\r\\n \\r\\n \\r\\n \\r\\n \\r\\n \\r\\n \\r\\n
\\r\\n
\\r\\n \\r\\n \\r\\n
\\r\\n
\\r\\n\",\n encapsulation: ViewEncapsulation.None,\n styles: [\"@import url(https://use.fontawesome.com/releases/v5.8.2/css/all.css);@import url(https://stackpath.bootstrapcdn.com/bootstrap/4.4.1/css/bootstrap.min.css);.ngx-photo-editor-ngx-photo-editor-img-container{width:100%;float:left}#ngx-photo-editor-image{display:block;max-width:100%}.ngx-photo-editor-modal-content{border:none;border-radius:5px;overflow:hidden}.ngx-photo-editor-icons-container{background-color:#8f8f8f;color:#fff;padding:15px;text-align:center;outline:0;border:none}.ngx-photo-editor-icons-container>i{padding-right:15px;transition:color .5s;cursor:pointer}.ngx-photo-editor-icons-container>i:nth-child(even){padding-right:30px}.ngx-photo-editor-icons-container>i:last-child{padding-right:0}.ngx-photo-editor-icons-container>i:hover{color:#000}.ngx-photo-editor-custom-modal-footer{padding:16px}.ngx-photo-editor-custom-modal-footer>button{padding:5px 20px!important;font-size:12px!important;float:right;margin-left:10px}/*!\\r\\n * Cropper.js v1.5.7\\r\\n * https://fengyuanchen.github.io/cropperjs\\r\\n *\\r\\n * Copyright 2015-present Chen Fengyuan\\r\\n * Released under the MIT license\\r\\n *\\r\\n * Date: 2020-05-23T05:22:57.283Z\\r\\n */.cropper-container{direction:ltr;font-size:0;line-height:0;position:relative;touch-action:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.cropper-container img{display:block;height:100%;image-orientation:0deg;max-height:none!important;max-width:none!important;min-height:0!important;min-width:0!important;width:100%}.cropper-canvas,.cropper-crop-box,.cropper-drag-box,.cropper-modal,.cropper-wrap-box{bottom:0;left:0;position:absolute;right:0;top:0}.cropper-canvas,.cropper-wrap-box{overflow:hidden}.cropper-drag-box{background-color:#fff;opacity:0}.cropper-modal{background-color:#000;opacity:.5}.cropper-view-box{display:block;height:100%;outline:rgba(51,153,255,.75) solid 1px;overflow:hidden;width:100%}.cropper-dashed{border:0 dashed #eee;display:block;opacity:.5;position:absolute}.cropper-dashed.dashed-h{border-bottom-width:1px;border-top-width:1px;height:calc(100% / 3);left:0;top:calc(100% / 3);width:100%}.cropper-dashed.dashed-v{border-left-width:1px;border-right-width:1px;height:100%;left:calc(100% / 3);top:0;width:calc(100% / 3)}.cropper-center{display:block;height:0;left:50%;opacity:.75;position:absolute;top:50%;width:0}.cropper-center::after,.cropper-center::before{background-color:#eee;content:' ';display:block;position:absolute}.cropper-center::before{height:1px;left:-3px;top:0;width:7px}.cropper-center::after{height:7px;left:0;top:-3px;width:1px}.cropper-face,.cropper-line,.cropper-point{display:block;height:100%;opacity:.1;position:absolute;width:100%}.cropper-face{background-color:#fff;left:0;top:0}.cropper-line{background-color:#39f}.cropper-line.line-e{cursor:ew-resize;right:-3px;top:0;width:5px}.cropper-line.line-n{cursor:ns-resize;height:5px;left:0;top:-3px}.cropper-line.line-w{cursor:ew-resize;left:-3px;top:0;width:5px}.cropper-line.line-s{bottom:-3px;cursor:ns-resize;height:5px;left:0}.cropper-point{background-color:#39f;height:5px;opacity:.75;width:5px}.cropper-point.point-e{cursor:ew-resize;margin-top:-3px;right:-3px;top:50%}.cropper-point.point-n{cursor:ns-resize;left:50%;margin-left:-3px;top:-3px}.cropper-point.point-w{cursor:ew-resize;left:-3px;margin-top:-3px;top:50%}.cropper-point.point-s{bottom:-3px;cursor:s-resize;left:50%;margin-left:-3px}.cropper-point.point-ne{cursor:nesw-resize;right:-3px;top:-3px}.cropper-point.point-nw{cursor:nwse-resize;left:-3px;top:-3px}.cropper-point.point-sw{bottom:-3px;cursor:nesw-resize;left:-3px}.cropper-point.point-se{bottom:-3px;cursor:nwse-resize;height:20px;opacity:1;right:-3px;width:20px}@media (min-width:768px){.cropper-point.point-se{height:15px;width:15px}}@media (min-width:992px){.cropper-point.point-se{height:10px;width:10px}}@media (min-width:1200px){.cropper-point.point-se{height:5px;opacity:.75;width:5px}}.cropper-point.point-se::before{background-color:#39f;bottom:-50%;content:' ';display:block;height:200%;opacity:0;position:absolute;right:-50%;width:200%}.cropper-invisible{opacity:0}.cropper-bg{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAAA3NCSVQICAjb4U/gAAAABlBMVEXMzMz////TjRV2AAAACXBIWXMAAArrAAAK6wGCiw1aAAAAHHRFWHRTb2Z0d2FyZQBBZG9iZSBGaXJld29ya3MgQ1M26LyyjAAAABFJREFUCJlj+M/AgBVhF/0PAH6/D/HkDxOGAAAAAElFTkSuQmCC)}.cropper-hide{display:block;height:0;position:absolute;width:0}.cropper-hidden{display:none!important}.cropper-move{cursor:move}.cropper-crop{cursor:crosshair}.cropper-disabled .cropper-drag-box,.cropper-disabled .cropper-face,.cropper-disabled .cropper-line,.cropper-disabled .cropper-point{cursor:not-allowed}\"]\n }]\n }], function () { return [{ type: ɵngcc1.NgbModal }]; }, { modalTitle: [{\n type: Input\n }], aspectRatio: [{\n type: Input\n }], autoCropArea: [{\n type: Input\n }], autoCrop: [{\n type: Input\n }], mask: [{\n type: Input\n }], guides: [{\n type: Input\n }], centerIndicator: [{\n type: Input\n }], viewMode: [{\n type: Input\n }], modalCentered: [{\n type: Input\n }], scalable: [{\n type: Input\n }], zoomable: [{\n type: Input\n }], cropBoxMovable: [{\n type: Input\n }], cropBoxResizable: [{\n type: Input\n }], darkTheme: [{\n type: Input\n }], roundCropper: [{\n type: Input\n }], canvasHeight: [{\n type: Input\n }], imageSmoothingEnabled: [{\n type: Input\n }], imageSmoothingQuality: [{\n type: Input\n }], imageCropped: [{\n type: Output\n }], imageQuality: [{\n type: Input\n }], imageFormat: [{\n type: Input\n }], imageUrl: [{\n type: Input\n }], imageBase64: [{\n type: Input\n }], imageChanedEvent: [{\n type: Input\n }], imageFile: [{\n type: Input\n }], content: [{\n type: ViewChild,\n args: ['ngxPhotoEditorContent', { static: false }]\n }], modalSize: [{\n type: Input\n }], resizeToWidth: [{\n type: Input\n }], resizeToHeight: [{\n type: Input\n }] }); })();\r\nif (false) {\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.content;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.cropper;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.outputImage;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.prevZoom;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.modalTitle;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.aspectRatio;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.autoCropArea;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.autoCrop;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.mask;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.guides;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.centerIndicator;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.viewMode;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.modalSize;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.modalCentered;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.scalable;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.zoomable;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.cropBoxMovable;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.cropBoxResizable;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.darkTheme;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.roundCropper;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.canvasHeight;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.resizeToWidth;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.resizeToHeight;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.imageSmoothingEnabled;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.imageSmoothingQuality;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.url;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.lastUpdate;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.format;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.quality;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.isFormatDefined;\r\n /** @type {?} */\r\n NgxPhotoEditorComponent.prototype.imageCropped;\r\n /**\r\n * @type {?}\r\n * @private\r\n */\r\n NgxPhotoEditorComponent.prototype.modalService;\r\n}\r\n/**\r\n * @record\r\n */\r\nfunction CroppedEvent() { }\r\nif (false) {\r\n /** @type {?|undefined} */\r\n CroppedEvent.prototype.base64;\r\n /** @type {?|undefined} */\r\n CroppedEvent.prototype.file;\r\n}\n\n/**\r\n * @fileoverview added by tsickle\r\n * Generated from: lib/ngx-photo-editor.module.ts\r\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\r\n */\r\nclass NgxPhotoEditorModule {\r\n}\nNgxPhotoEditorModule.ɵmod = ɵngcc0.ɵɵdefineNgModule({ type: NgxPhotoEditorModule });\nNgxPhotoEditorModule.ɵinj = ɵngcc0.ɵɵdefineInjector({ factory: function NgxPhotoEditorModule_Factory(t) { return new (t || NgxPhotoEditorModule)(); }, imports: [[NgbModalModule]] });\n(function () { (typeof ngJitMode === \"undefined\" || ngJitMode) && ɵngcc0.ɵɵsetNgModuleScope(NgxPhotoEditorModule, { declarations: function () { return [NgxPhotoEditorComponent]; }, imports: function () { return [NgbModalModule]; }, exports: function () { return [NgxPhotoEditorComponent]; } }); })();\n/*@__PURE__*/ (function () { ɵngcc0.ɵsetClassMetadata(NgxPhotoEditorModule, [{\n type: NgModule,\n args: [{\n declarations: [NgxPhotoEditorComponent],\n imports: [NgbModalModule],\n exports: [NgxPhotoEditorComponent]\n }]\n }], null, null); })();\n\n/**\r\n * @fileoverview added by tsickle\r\n * Generated from: public-api.ts\r\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\r\n */\n\n/**\r\n * @fileoverview added by tsickle\r\n * Generated from: ngx-photo-editor.ts\r\n * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc\r\n */\n\nexport { NgxPhotoEditorComponent, NgxPhotoEditorModule, NgxPhotoEditorService };\n\n//# sourceMappingURL=ngx-photo-editor.js.map","import { NgModule } from '@angular/core';\r\nimport { RouterModule, Routes } from '@angular/router';\r\nimport { HomeComponent } from '../shared/components/home/home.component';\r\nimport { NewsdashboardComponent } from './newsdashboard/newsdashboard.component';\r\nimport { ContactComponent } from './contact/addMessage/contact.component';\r\nimport { ContactdashboardComponent } from './contact/contactdashboard/contactdashboard.component';\r\nimport { DisplaypageComponent } from './define-pages/displaypage/displaypage.component';\r\nimport { MenuConfigComponent } from './define-pages/menu-config/menu-config.component';\r\nimport { pageDashboardComponent } from './define-pages/pageDashboard/pageDashboard.component';\r\nimport { pageViewComponent } from './define-pages/pageView/pageView.component';\r\nimport { TextEditorComponent } from './define-pages/texteditor/texteditor.component';\r\nimport { FiledragAndDropComponent } from './files/filedrag-and-drop/filedrag-and-drop.component';\r\nimport { AlbumsComponent } from './photogallery/albums/albums.component';\r\nimport { CarouselComponent } from './photogallery/carousel/carousel.component';\r\nimport { cropNUploadphotoComponent } from './photogallery/cropNuploadphoto/cropNuploadphoto.component';\r\nimport { ImgDragAndDropComponent } from './photogallery/imgDragAndDrop/imgDragAndDrop';\r\nimport { PhotobrowserComponent } from './photogallery/photobrowser/photobrowser.component';\r\nimport { PhotosComponent } from './photogallery/photos/photos.component';\r\nimport { AllNewsdashboardComponent } from './allnewsdashboard/allnewsdashboard.component';\r\n//import { EncodeHTMLPipe } from '../encode-html.pipe';\r\n//import { AlbumEditInputComponent } from './photogallery/albumedit-input/albumedit-input.component';\r\n//import { CdkCopyToClipboard } from '@angular/cdk/clipboard';\r\n//import { MatConfirmDialogComponent } from '../shared/components/mat-confirm-dialog/mat-confirm-dialog.component';\r\n\r\nconst routes: Routes = [\r\n \r\n {path: '', component: HomeComponent,\r\n children:\r\n [\r\n { path: '',redirectTo:'display/0/0',pathMatch:'full'}, \r\n { path: 'display/:phid/:pid', component: DisplaypageComponent },\r\n { path: 'photocarousel', component: CarouselComponent },\r\n { path: 'uploadphoto', component: cropNUploadphotoComponent },\r\n { path: 'browsephoto', component: PhotobrowserComponent },\r\n { path: 'editor', component: TextEditorComponent },\r\n { path: 'page/:id', component: TextEditorComponent },\r\n { path: 'pages/:id', component: pageDashboardComponent },\r\n { path: 'pages', component: pageDashboardComponent }, \r\n { path: 'details', component: pageViewComponent },\r\n { path: 'dragdrop', component: ImgDragAndDropComponent },\r\n { path: 'filedragdrop', component: FiledragAndDropComponent },\r\n { path: 'photos', component: PhotosComponent },\r\n { path: 'managefile', component: AlbumsComponent },\r\n { path: 'messages', component: ContactdashboardComponent },\r\n { path: 'addmessage', component: ContactComponent },\r\n { path: 'message/:id', component: ContactComponent },\r\n { path: 'about/:parentid', component: NewsdashboardComponent },\r\n { path: 'config', component: MenuConfigComponent },\r\n { path: 'allnews', component: AllNewsdashboardComponent },\r\n ]\r\n }\r\n];\r\n\r\n@NgModule({\r\n //declarations:[]\r\n imports: [RouterModule.forChild(routes)],\r\n exports: [RouterModule]\r\n})\r\nexport class WebsiteRoutingModule { }\r\nexport const WebsiteComponents=[\r\n CarouselComponent,\r\n cropNUploadphotoComponent ,\r\n PhotobrowserComponent ,\r\n ImgDragAndDropComponent,\r\n FiledragAndDropComponent,\r\n PhotosComponent,\r\n ContactdashboardComponent,\r\n ContactComponent,\r\n AllNewsdashboardComponent \r\n]\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { AlbumsComponent } from './albums.component';\r\nimport {ClipboardModule} from '@angular/cdk/clipboard'\r\nimport { MaterialModule } from 'src/app/shared/material/material.module';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { AlbumEditInputComponent } from '../albumedit-input/albumedit-input.component';\r\n\r\n@NgModule({\r\n declarations: [AlbumsComponent,\r\n AlbumEditInputComponent],\r\n imports: [\r\n CommonModule,\r\n ClipboardModule,\r\n MaterialModule,\r\n FormsModule,\r\n ReactiveFormsModule,\r\n \r\n ],\r\n exports:[\r\n AlbumsComponent,\r\n AlbumEditInputComponent\r\n ]\r\n})\r\nexport class AlbumsModule { }\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { CKEditorModule } from 'ng2-ckeditor';\r\nimport { TextEditorComponent } from './texteditor/texteditor.component';\r\nimport { pageDashboardComponent } from './pageDashboard/pageDashboard.component';\r\nimport { pageViewComponent } from './pageView/pageView.component';\r\nimport { MaterialModule } from '../../shared/material/material.module';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { DisplaypageComponent } from './displaypage/displaypage.component';\r\nimport { EncodeHTMLPipe } from '../../encode-html.pipe'\r\nimport { SharedModule } from '../../shared/shared.module';\r\nimport { MatFormFieldModule } from '@angular/material/form-field';\r\nimport { MatCardModule } from '@angular/material/card';\r\nimport { RouterModule } from '@angular/router';\r\nimport { MenuConfigComponent } from './menu-config/menu-config.component';\r\nimport { FlexLayoutModule } from '@angular/flex-layout';\r\n//import { ContactComponent } from '../contact/addMessage/contact.component';\r\n//import { ContactdashboardComponent } from '../contact/contactdashboard/contactdashboard.component';\r\nimport { SharedhomepageModule } from '../sharedhomepage.module';\r\nimport { AlbumsModule } from '../photogallery/albums/albums.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n TextEditorComponent,\r\n pageDashboardComponent,\r\n pageViewComponent,\r\n DisplaypageComponent,\r\n EncodeHTMLPipe,\r\n MenuConfigComponent,\r\n //ContactComponent,\r\n //ContactdashboardComponent\r\n\r\n ],\r\n imports: [\r\n CommonModule,\r\n CKEditorModule,\r\n MaterialModule,\r\n FormsModule,\r\n ReactiveFormsModule,\r\n SharedModule,\r\n SharedhomepageModule,\r\n MatFormFieldModule,\r\n MatCardModule,\r\n RouterModule,\r\n FlexLayoutModule,\r\n AlbumsModule\r\n ],\r\n exports: [\r\n TextEditorComponent,\r\n pageDashboardComponent,\r\n pageViewComponent,\r\n //MaterialModule,\r\n //MatFormFieldModule,\r\n //MatCardModule,\r\n ]\r\n})\r\nexport class DefinePagesModule { }\r\n","!function(e,t){\"object\"==typeof exports&&\"undefined\"!=typeof module?t(exports):\"function\"==typeof define&&define.amd?define(\"exifr\",[\"exports\"],t):t((e=e||self).exifr={})}(this,(function(e){\"use strict\";function t(e,t){if(!(e instanceof t))throw new TypeError(\"Cannot call a class as a function\")}function n(e,t){for(var n=0;n1?t-1:0),r=1;r1&&void 0!==arguments[1]?arguments[1]:0;return this.substring(t,t+e.length)===e}),String.prototype.endsWith||(String.prototype.endsWith=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.length;return this.substring(t-e.length,t)===e});var b=\"undefined\"!=typeof self?self:global,w=b.fetch||function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return new Promise((function(n,r){var i=new XMLHttpRequest;if(i.open(\"get\",e,!0),i.responseType=\"arraybuffer\",i.onerror=r,t.headers)for(var s in t.headers)i.setRequestHeader(s,t.headers[s]);i.onload=function(){n({ok:i.status>=200&&i.status<300,status:i.status,arrayBuffer:function(){return Promise.resolve(i.response)}})},i.send(null)}))},A=function(e){var t=[];if(Object.defineProperties(t,{size:{get:function(){return this.length}},has:{value:function(e){return-1!==this.indexOf(e)}},add:{value:function(e){this.has(e)||this.push(e)}},delete:{value:function(e){if(this.has(e)){var t=this.indexOf(e);this.splice(t,1)}}}}),Array.isArray(e))for(var n=0;n=0}},{key:\"delete\",value:function(e){var t=this._keys.indexOf(e);return!(t<0)&&(delete this._map[\"map_\"+e],this._keys.splice(t,1),!0)}},{key:\"keys\",value:function(){return this._keys.slice(0)}},{key:\"values\",value:function(){var e=this;return this._keys.map((function(t){return e.get(t)}))}},{key:\"entries\",value:function(){var e=this;return this._keys.map((function(t){return[t,e.get(t)]}))}},{key:\"forEach\",value:function(e,t){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:0,i=arguments.length>2?arguments[2]:void 0,s=arguments.length>3?arguments[3]:void 0;if(t(this,e),\"boolean\"==typeof s&&(this.le=s),Array.isArray(n)&&(n=new Uint8Array(n)),0===n)this.byteOffset=0,this.byteLength=0;else if(n instanceof ArrayBuffer){void 0===i&&(i=n.byteLength-r);var a=new DataView(n,r,i);this._swapDataView(a)}else if(n instanceof Uint8Array||n instanceof DataView||n instanceof e){if(void 0===i&&(i=n.byteLength-r),(r+=n.byteOffset)+i>n.byteOffset+n.byteLength)throw I(\"Creating view outside of available memory in ArrayBuffer\");var u=new DataView(n.buffer,r,i);this._swapDataView(u)}else{if(\"number\"!=typeof n)throw I(\"Invalid input argument for BufferView: \"+n);var o=new DataView(new ArrayBuffer(n));this._swapDataView(o)}}return r(e,null,[{key:\"from\",value:function(t,n){return t instanceof this&&t.le===n?t:new e(t,void 0,void 0,n)}}]),r(e,[{key:\"_swapArrayBuffer\",value:function(e){this._swapDataView(new DataView(e))}},{key:\"_swapBuffer\",value:function(e){this._swapDataView(new DataView(e.buffer,e.byteOffset,e.byteLength))}},{key:\"_swapDataView\",value:function(e){this.dataView=e,this.buffer=e.buffer,this.byteOffset=e.byteOffset,this.byteLength=e.byteLength}},{key:\"_lengthToEnd\",value:function(e){return this.byteLength-e}},{key:\"set\",value:function(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e;if(t instanceof DataView||t instanceof e?t=new Uint8Array(t.buffer,t.byteOffset,t.byteLength):t instanceof ArrayBuffer&&(t=new Uint8Array(t)),!(t instanceof Uint8Array))throw I(\"BufferView.set(): Invalid data argument.\");var i=this.toUint8();return i.set(t,n),new r(this,n,t.byteLength)}},{key:\"subarray\",value:function(t,n){return new e(this,t,n=n||this._lengthToEnd(t))}},{key:\"toUint8\",value:function(){return new Uint8Array(this.buffer,this.byteOffset,this.byteLength)}},{key:\"getUint8Array\",value:function(e,t){return new Uint8Array(this.buffer,this.byteOffset+e,t)}},{key:\"getString\",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.byteLength,n=this.getUint8Array(e,t);return F(n)}},{key:\"getUnicodeString\",value:function(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.byteLength,n=[],r=0;r1&&void 0!==arguments[1]?arguments[1]:this.le;return this.dataView.getInt16(e,t)}},{key:\"getInt32\",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.le;return this.dataView.getInt32(e,t)}},{key:\"getUint16\",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.le;return this.dataView.getUint16(e,t)}},{key:\"getUint32\",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.le;return this.dataView.getUint32(e,t)}},{key:\"getFloat32\",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.le;return this.dataView.getFloat32(e,t)}},{key:\"getFloat64\",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.le;return this.dataView.getFloat64(e,t)}},{key:\"getFloat\",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.le;return this.dataView.getFloat32(e,t)}},{key:\"getDouble\",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.le;return this.dataView.getFloat64(e,t)}},{key:\"getUint64\",value:function(e){var t=this.getUint32(e),n=this.getUint32(e+4);if(t<1048575)return t<<32|n;if(void 0!==typeof j)return console.warn(\"Using BigInt because of type 64uint but JS can only handle 53b numbers.\"),j(t)<1e4)return q(e,t,\"base64\");if(U)return Q(e,t,\"url\",J);if(B)return q(e,t,\"fs\");throw I(\"Invalid input argument\");var n}var Z=function(e){function n(){return t(this,n),l(this,a(n).apply(this,arguments))}return s(n,e),r(n,[{key:\"tagKeys\",get:function(){return this.allKeys||(this.allKeys=k(this.keys())),this.allKeys}},{key:\"tagValues\",get:function(){return this.allValues||(this.allValues=k(this.values())),this.allValues}}]),n}(h(S));function $(e,t,n){var r=new Z,i=n;Array.isArray(i)||(\"function\"==typeof i.entries&&(i=i.entries()),i=k(i));for(var s=0;s0&&o.translateTagSet(s,o.pick);else if(\"object\"==typeof s){if(o.enabled=!0,o.parse=!1!==s.parse,o.canBeFiltered){var f=s.pick,h=s.skip;f&&f.length>0&&o.translateTagSet(f,o.pick),h&&h.length>0&&o.translateTagSet(h,o.skip)}o.applyInheritables(s)}else{if(!0!==s&&!1!==s)throw I(\"Invalid options argument: \".concat(s));o.parse=o.enabled=s}return o}return s(n,e),r(n,[{key:\"needed\",get:function(){return this.enabled||this.deps.size>0}}]),r(n,[{key:\"applyInheritables\",value:function(e){var t,n,r=he;Array.isArray(r)||(\"function\"==typeof r.entries&&(r=r.entries()),r=k(r));for(var i=0;i0?(this.enabled=!0,me(this.pick,this.deps)):this.enabled&&this.pick.size>0&&me(this.pick,this.deps)}}]),n}(le),ve={jfif:!1,tiff:!0,xmp:!1,icc:!1,iptc:!1,ifd0:!0,ifd1:!1,exif:!0,gps:!0,interop:!1,makerNote:!1,userComment:!1,multiSegment:!1,skip:[],pick:[],translateKeys:!0,translateValues:!0,reviveValues:!0,sanitize:!0,mergeOutput:!0,silentErrors:!0,chunked:!0,firstChunkSize:void 0,firstChunkSizeNode:512,firstChunkSizeBrowser:65536,chunkSize:65536,chunkLimit:5},pe=O(),ye=function(e){function n(e){var r;if(t(this,n),r=l(this,a(n).call(this)),!0===e)r.setupFromTrue();else if(void 0===e)r.setupFromUndefined();else if(Array.isArray(e))r.setupFromArray(e);else{if(\"object\"!=typeof e)throw I(\"Invalid options argument \".concat(e));r.setupFromObject(e)}return void 0===r.firstChunkSize&&(r.firstChunkSize=U?r.firstChunkSizeBrowser:r.firstChunkSizeNode),r.mergeOutput&&(r.ifd1.enabled=!1),r.filterNestedSegmentTags(),r.traverseTiffDependencyTree(),r.checkLoadedPlugins(),r}return s(n,e),r(n,null,[{key:\"useCached\",value:function(e){var t=pe.get(e);return void 0!==t?t:(t=new this(e),pe.set(e,t),t)}}]),r(n,[{key:\"setupFromUndefined\",value:function(){var e,t=ie;Array.isArray(t)||(\"function\"==typeof t.entries&&(t=t.entries()),t=k(t));for(var n=0;n3&&void 0!==arguments[3]?arguments[3]:n;if(e&&e.length){var i=r;Array.isArray(i)||(\"function\"==typeof i.entries&&(i=i.entries()),i=k(i));for(var s=0;s50)return!1;for(var n=16,r=[];n0&&(n.errors=r),n=T(t=n)?void 0:t,e.file.close&&e.file.close(),n}))}))}catch(e){return Promise.reject(e)}}},{key:\"extractThumbnail\",value:function(){try{var e=this;e.setup();var t,n=M.get(\"tiff\",e.options);return Pe((function(){if(!e.file.isTiff)return function(e){var t=e();if(t&&t.then)return t.then(Ue)}((function(){if(e.file.isJpeg)return Se(e.fileParser.getOrFindSegment(\"tiff\"),(function(e){t=e}))}));t={start:0,type:\"tiff\"}}),(function(){if(void 0!==t)return Se(e.fileParser.ensureSegmentChunk(t),(function(t){return Se((e.parsers.tiff=new n(t,e.options,e.file)).extractThumbnail(),(function(t){return e.file.close&&e.file.close(),t}))}))}))}catch(e){return Promise.reject(e)}}}]),e}();function Be(e,t,n){return n?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}function Ce(e){return function(){for(var t=[],n=0;nthis.byteLength){var s=this._extend(i).dataView;this._swapDataView(s)}}}},{key:\"_extend\",value:function(e){var t;t=_?C.allocUnsafe(e):new Uint8Array(e);var n=new DataView(t.buffer,t.byteOffset,t.byteLength);return t.set(new Uint8Array(this.buffer,this.byteOffset,this.byteLength),0),{uintView:t,dataView:n}}},{key:\"subarray\",value:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return t=t||this._lengthToEnd(e),r&&this._tryExtend(e,t),this.ranges.add(e,t),d(a(n.prototype),\"subarray\",this).call(this,e,t)}},{key:\"set\",value:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];r&&this._tryExtend(t,e.byteLength,e);var i=d(a(n.prototype),\"set\",this).call(this,e,t);return this.ranges.add(t,i.byteLength),i}},{key:\"ensureChunk\",value:function(e,t){try{if(!this.chunked)return;if(this.ranges.available(e,t))return;return function(e,t){if(!t)return e&&e.then?e.then(ze):Promise.resolve()}(this.readChunk(e,t))}catch(e){return Promise.reject(e)}}},{key:\"available\",value:function(e,t){return this.ranges.available(e,t)}}]),n}(E),Ee=function(){function e(){t(this,e),i(this,\"list\",[])}return r(e,[{key:\"add\",value:function(e,t){var n=e+t,r=this.list.filter((function(t){return De(e,t.offset,n)||De(e,t.end,n)}));if(r.length>0){e=Math.min.apply(Math,[e].concat(r.map((function(e){return e.offset})))),t=(n=Math.max.apply(Math,[n].concat(r.map((function(e){return e.end})))))-e;var i=r.shift();i.offset=e,i.length=t,i.end=n,this.list=this.list.filter((function(e){return!r.includes(e)}))}else this.list.push({offset:e,length:t,end:n})}},{key:\"available\",value:function(e,t){var n=e+t;return this.list.some((function(t){return t.offset<=e&&n<=t.end}))}},{key:\"length\",get:function(){return this.list.length}}]),e}();function De(e,t,n){return e<=t&&t<=n}function Re(){}function Ne(e,t){if(!t)return e&&e.then?e.then(Re):Promise.resolve()}function Me(e,t,n){return n?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}var We=function(e){function n(){return t(this,n),l(this,a(n).apply(this,arguments))}return s(n,e),r(n,[{key:\"readWhole\",value:function(){try{var e=this;return e.chunked=!1,Me(G(e.input),(function(t){e._swapArrayBuffer(t)}))}catch(e){return Promise.reject(e)}}},{key:\"readChunked\",value:function(){return this.chunked=!0,this.size=this.input.size,d(a(n.prototype),\"readChunked\",this).call(this)}},{key:\"_readChunk\",value:function(e,t){try{var n=this,r=t?e+t:void 0,i=n.input.slice(e,r);return Me(G(i),(function(t){return n.set(t,e,!0)}))}catch(e){return Promise.reject(e)}}}]),n}(function(e){function n(e,r){var s;return t(this,n),i(c(s=l(this,a(n).call(this,0))),\"chunksRead\",0),s.input=e,s.options=r,s}return s(n,e),r(n,[{key:\"readWhole\",value:function(){try{return this.chunked=!1,Ne(this.readChunk(this.nextChunkOffset))}catch(e){return Promise.reject(e)}}},{key:\"readChunked\",value:function(){try{return this.chunked=!0,Ne(this.readChunk(0,this.options.firstChunkSize))}catch(e){return Promise.reject(e)}}},{key:\"readNextChunk\",value:function(e){try{if(void 0===e&&(e=this.nextChunkOffset),this.fullyRead)return this.chunksRead++,!1;var t=this.options.chunkSize;return n=this.readChunk(e,t),r=function(e){return!!e&&e.byteLength===t},i?r?r(n):n:(n&&n.then||(n=Promise.resolve(n)),r?n.then(r):n)}catch(e){return Promise.reject(e)}var n,r,i}},{key:\"readChunk\",value:function(e,t){try{if(this.chunksRead++,0===(t=this.safeWrapAddress(e,t)))return;return this._readChunk(e,t)}catch(e){return Promise.reject(e)}}},{key:\"safeWrapAddress\",value:function(e,t){return void 0!==this.size&&e+t>this.size?Math.max(0,this.size-e):t}},{key:\"read\",value:function(){return this.options.chunked?this.readChunked():this.readWhole()}},{key:\"close\",value:function(){}},{key:\"nextChunkOffset\",get:function(){if(0!==this.ranges.list.length)return this.ranges.list[0].length}},{key:\"canReadNextChunk\",get:function(){return this.chunksReadi+s)e.chunk=u.file.subarray(i,s);else{if(void 0!==e.size)throw I(\"Segment unreachable: \"+JSON.stringify(e));e.chunk=u.file.subarray(i)}},n=function(t){return e.chunk},(r=t())&&r.then?r.then(n):n(r)},function(){for(var e=[],t=0;t1&&void 0!==arguments[1]?arguments[1]:{},a=arguments.length>2?arguments[2]:void 0;t(this,e),i(this,\"errors\",[]),i(this,\"raw\",O()),i(this,\"handleError\",(function(e){if(!r.options.silentErrors)throw e;r.errors.push(e.message)})),this.chunk=this.normalizeInput(n),this.file=a,this.type=this.constructor.type,this.globalOptions=this.options=s,this.localOptions=s[this.type],this.canTranslate=this.localOptions&&this.localOptions.translate}return r(e,[{key:\"normalizeInput\",value:function(e){return e instanceof E?e:new E(e)}}],[{key:\"findPosition\",value:function(e,t){var n=e.getUint16(t+2)+2,r=\"function\"==typeof this.headerLength?this.headerLength(e,t,n):this.headerLength,i=t+r,s=n-r;return{offset:t,length:n,headerLength:r,start:i,size:s,end:i+s}}},{key:\"parse\",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=new ye(i({},this.type,t)),r=new this(e,n);return r.parse()}}]),r(e,[{key:\"translate\",value:function(){this.canTranslate&&(this.translated=this.translateBlock(this.raw,this.type))}},{key:\"translateBlock\",value:function(e,t){var n=re.get(t),r=ne.get(t),i=te.get(t),s=this.options[t],a=s.reviveValues&&!!n,u=s.translateValues&&!!r,o=s.translateKeys&&!!i,f={},h=e;Array.isArray(h)||(\"function\"==typeof h.entries&&(h=h.entries()),h=k(h));for(var c=0;c=224&&e<=239}function rt(e,t){var n=M;Array.isArray(n)||(\"function\"==typeof n.entries&&(n=n.entries()),n=k(n));for(var r=0;r0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1?arguments[1]:void 0;try{var n=this;n.setupSegmentFinderArgs(t);var r=n.file,i=n.findAll,s=n.wanted,a=n.remaining;return Qe((function(){if(!i&&n.file.chunked)return i=k(s).some((function(e){var t=M.get(e),r=n.options[e];return t.multiSegment&&r.multiSegment})),qe((function(){if(i)return Xe(n.file.readWhole())}))}),(function(){var t=!1;if(e=n._findAppSegments(e,r.byteLength,i,s,a),!n.options.onlyTiff)return function(){if(r.chunked){var i=!1;return et((function(){return!t&&a.size>0&&!i&&(!!r.canReadNextChunk||!!n.unfinishedMultiSegment)}),void 0,(function(){var s=r.nextChunkOffset,a=n.appSegments.some((function(e){return!n.file.available(e.offset||e.start,e.length||e.size)}));return Qe((function(){return e>s&&!a?Ge(r.readNextChunk(e),(function(e){i=!e})):Ge(r.readNextChunk(s),(function(e){i=!e}))}),(function(){void 0===(e=n._findAppSegments(e,r.byteLength))&&(t=!0)}))}))}}()}))}catch(e){return Promise.reject(e)}}},{key:\"_findAppSegments\",value:function(e,t){for(var n,r,i,s,a,u,o=this.file,f=this.findAll,h=this.wanted,c=this.remaining,l=this.options;ee.file.byteLength)throw I(\"IFD0 offset points to outside of file.\\nthis.ifd0Offset: \".concat(e.ifd0Offset,\", file.byteLength: \").concat(e.file.byteLength));return ut((function(){if(e.file.isTiff)return at(e.file.ensureChunk(e.ifd0Offset,L(e.options)))}),(function(){var t=e.parseBlock(e.ifd0Offset,\"ifd0\");if(0!==t.size)return e.exifOffset=t.get(34665),e.interopOffset=t.get(40965),e.gpsOffset=t.get(34853),e.xmp=t.get(700),e.iptc=t.get(33723),e.icc=t.get(34675),e.options.sanitize&&(t.delete(34665),t.delete(40965),t.delete(34853),t.delete(700),t.delete(33723),t.delete(34675)),t}))}catch(e){return Promise.reject(e)}}},{key:\"ensureBlockChunk\",value:function(e,t){try{var n=this;return ut((function(){if(n.file.isTiff)return at(n.file.ensureChunk(e,t))}),(function(){e>n.chunk.byteLength&&(n.chunk=E.from(n.file,n.le))}))}catch(e){return Promise.reject(e)}}},{key:\"parseExifBlock\",value:function(){try{var e=this;if(e.exif)return;return ut((function(){if(!e.ifd0)return at(e.parseIfd0Block())}),(function(){if(void 0!==e.exifOffset)return ut((function(){if(e.file.isTiff)return at(e.file.ensureChunk(e.exifOffset,L(e.options)))}),(function(){var t=e.parseBlock(e.exifOffset,\"exif\");return e.interopOffset||(e.interopOffset=t.get(40965)),e.makerNote=t.get(37500),e.userComment=t.get(37510),e.options.sanitize&&(t.delete(40965),t.delete(37500),t.delete(37510)),e.unpack(t,41728),e.unpack(t,41729),t}))}))}catch(e){return Promise.reject(e)}}},{key:\"unpack\",value:function(e,t){var n=e.get(t);n&&1===n.length&&e.set(t,n[0])}},{key:\"parseGpsBlock\",value:function(){try{var e=this;if(e.gps)return;return ut((function(){if(!e.ifd0)return at(e.parseIfd0Block())}),(function(){if(void 0!==e.gpsOffset){var t=e.parseBlock(e.gpsOffset,\"gps\");return t&&t.has(2)&&t.has(4)&&(t.set(\"latitude\",ht.apply(void 0,t.get(2).concat([t.get(1)]))),t.set(\"longitude\",ht.apply(void 0,t.get(4).concat([t.get(3)])))),t}}))}catch(e){return Promise.reject(e)}}},{key:\"parseInteropBlock\",value:function(){try{var e=this;if(e.interop)return;return ut((function(){if(!e.ifd0)return at(e.parseIfd0Block())}),(function(){return ut((function(){if(void 0===e.interopOffset&&!e.exif)return at(e.parseExifBlock())}),(function(){if(void 0!==e.interopOffset)return e.parseBlock(e.interopOffset,\"interop\")}))}))}catch(e){return Promise.reject(e)}}},{key:\"parseThumbnailBlock\",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];try{var t=this;if(t.ifd1||t.ifd1Parsed)return;if(t.options.mergeOutput&&!e)return;return t.findIfd1Offset(),t.ifd1Offset>0&&(t.parseBlock(t.ifd1Offset,\"ifd1\"),t.ifd1Parsed=!0),t.ifd1}catch(e){return Promise.reject(e)}}},{key:\"extractThumbnail\",value:function(){try{var e=this;return e.headerParsed||e.parseHeader(),ut((function(){if(!e.ifd1Parsed)return at(e.parseThumbnailBlock(!0))}),(function(){if(void 0!==e.ifd1){var t=e.ifd1.get(513),n=e.ifd1.get(514);return e.chunk.getUint8Array(t,n)}}))}catch(e){return Promise.reject(e)}}},{key:\"createOutput\",value:function(){var e,t,n,r={},i=ue;Array.isArray(i)||(\"function\"==typeof i.entries&&(i=i.entries()),i=k(i));for(var s=0;s2&&void 0!==arguments[2]?arguments[2]:O(),r=this.options[t],i=r.pick,s=r.skip,a=(i=A(i)).size>0,u=0===s.size,o=this.chunk.getUint16(e);e+=2;for(var f=0;f13)throw I(\"Invalid TIFF value type. block: \".concat(n.toUpperCase(),\", tag: \").concat(t.toString(16),\", type: \").concat(i,\", offset \").concat(e));if(e>this.chunk.byteLength)throw I(\"Invalid TIFF value offset. block: \".concat(n.toUpperCase(),\", tag: \").concat(t.toString(16),\", type: \").concat(i,\", offset \").concat(e,\" is outside of chunk size \").concat(this.chunk.byteLength));if(1===i)return this.chunk.getUint8Array(e,s);if(2===i)return\"\"===(r=function(e){for(;e.endsWith(\"\\0\");)e=e.slice(0,-1);return e}(r=this.chunk.getString(e,s)).trim())?void 0:r;if(7===i)return this.chunk.getUint8Array(e,s);if(1===s)return this.parseTagValue(i,e);for(var u=new(function(e){switch(e){case 1:return Uint8Array;case 3:return Uint16Array;case 4:return Uint32Array;case 5:return Array;case 6:return Int8Array;case 8:return Int16Array;case 9:return Int32Array;case 10:return Array;case 11:return Float32Array;case 12:return Float64Array;default:return Array}}(i))(s),o=a,f=0;f= 0,\n wasm: __requested_features.indexOf('wasm') >= 0\n };\n Multimath.call(this, features);\n this.features = {\n js: features.js,\n wasm: features.wasm && this.has_wasm()\n };\n this.use(mm_unsharp_mask);\n this.use(mm_resize);\n}\n\ninherits(MathLib, Multimath);\n\nMathLib.prototype.resizeAndUnsharp = function resizeAndUnsharp(options, cache) {\n var result = this.resize(options, cache);\n\n if (options.unsharpAmount) {\n this.unsharp_mask(result, options.toWidth, options.toHeight, options.unsharpAmount, options.unsharpRadius, options.unsharpThreshold);\n }\n\n return result;\n};\n\nmodule.exports = MathLib;\n\n},{\"./mm_resize\":4,\"inherits\":15,\"multimath\":16,\"multimath/lib/unsharp_mask\":19}],2:[function(_dereq_,module,exports){\n// Resize convolvers, pure JS implementation\n//\n'use strict'; // Precision of fixed FP values\n//var FIXED_FRAC_BITS = 14;\n\nfunction clampTo8(i) {\n return i < 0 ? 0 : i > 255 ? 255 : i;\n} // Convolve image in horizontal directions and transpose output. In theory,\n// transpose allow:\n//\n// - use the same convolver for both passes (this fails due different\n// types of input array and temporary buffer)\n// - making vertical pass by horisonltal lines inprove CPU cache use.\n//\n// But in real life this doesn't work :)\n//\n\n\nfunction convolveHorizontally(src, dest, srcW, srcH, destW, filters) {\n var r, g, b, a;\n var filterPtr, filterShift, filterSize;\n var srcPtr, srcY, destX, filterVal;\n var srcOffset = 0,\n destOffset = 0; // For each row\n\n for (srcY = 0; srcY < srcH; srcY++) {\n filterPtr = 0; // Apply precomputed filters to each destination row point\n\n for (destX = 0; destX < destW; destX++) {\n // Get the filter that determines the current output pixel.\n filterShift = filters[filterPtr++];\n filterSize = filters[filterPtr++];\n srcPtr = srcOffset + filterShift * 4 | 0;\n r = g = b = a = 0; // Apply the filter to the row to get the destination pixel r, g, b, a\n\n for (; filterSize > 0; filterSize--) {\n filterVal = filters[filterPtr++]; // Use reverse order to workaround deopts in old v8 (node v.10)\n // Big thanks to @mraleph (Vyacheslav Egorov) for the tip.\n\n a = a + filterVal * src[srcPtr + 3] | 0;\n b = b + filterVal * src[srcPtr + 2] | 0;\n g = g + filterVal * src[srcPtr + 1] | 0;\n r = r + filterVal * src[srcPtr] | 0;\n srcPtr = srcPtr + 4 | 0;\n } // Bring this value back in range. All of the filter scaling factors\n // are in fixed point with FIXED_FRAC_BITS bits of fractional part.\n //\n // (!) Add 1/2 of value before clamping to get proper rounding. In other\n // case brightness loss will be noticeable if you resize image with white\n // border and place it on white background.\n //\n\n\n dest[destOffset + 3] = clampTo8(a + (1 << 13) >> 14\n /*FIXED_FRAC_BITS*/\n );\n dest[destOffset + 2] = clampTo8(b + (1 << 13) >> 14\n /*FIXED_FRAC_BITS*/\n );\n dest[destOffset + 1] = clampTo8(g + (1 << 13) >> 14\n /*FIXED_FRAC_BITS*/\n );\n dest[destOffset] = clampTo8(r + (1 << 13) >> 14\n /*FIXED_FRAC_BITS*/\n );\n destOffset = destOffset + srcH * 4 | 0;\n }\n\n destOffset = (srcY + 1) * 4 | 0;\n srcOffset = (srcY + 1) * srcW * 4 | 0;\n }\n} // Technically, convolvers are the same. But input array and temporary\n// buffer can be of different type (especially, in old browsers). So,\n// keep code in separate functions to avoid deoptimizations & speed loss.\n\n\nfunction convolveVertically(src, dest, srcW, srcH, destW, filters) {\n var r, g, b, a;\n var filterPtr, filterShift, filterSize;\n var srcPtr, srcY, destX, filterVal;\n var srcOffset = 0,\n destOffset = 0; // For each row\n\n for (srcY = 0; srcY < srcH; srcY++) {\n filterPtr = 0; // Apply precomputed filters to each destination row point\n\n for (destX = 0; destX < destW; destX++) {\n // Get the filter that determines the current output pixel.\n filterShift = filters[filterPtr++];\n filterSize = filters[filterPtr++];\n srcPtr = srcOffset + filterShift * 4 | 0;\n r = g = b = a = 0; // Apply the filter to the row to get the destination pixel r, g, b, a\n\n for (; filterSize > 0; filterSize--) {\n filterVal = filters[filterPtr++]; // Use reverse order to workaround deopts in old v8 (node v.10)\n // Big thanks to @mraleph (Vyacheslav Egorov) for the tip.\n\n a = a + filterVal * src[srcPtr + 3] | 0;\n b = b + filterVal * src[srcPtr + 2] | 0;\n g = g + filterVal * src[srcPtr + 1] | 0;\n r = r + filterVal * src[srcPtr] | 0;\n srcPtr = srcPtr + 4 | 0;\n } // Bring this value back in range. All of the filter scaling factors\n // are in fixed point with FIXED_FRAC_BITS bits of fractional part.\n //\n // (!) Add 1/2 of value before clamping to get proper rounding. In other\n // case brightness loss will be noticeable if you resize image with white\n // border and place it on white background.\n //\n\n\n dest[destOffset + 3] = clampTo8(a + (1 << 13) >> 14\n /*FIXED_FRAC_BITS*/\n );\n dest[destOffset + 2] = clampTo8(b + (1 << 13) >> 14\n /*FIXED_FRAC_BITS*/\n );\n dest[destOffset + 1] = clampTo8(g + (1 << 13) >> 14\n /*FIXED_FRAC_BITS*/\n );\n dest[destOffset] = clampTo8(r + (1 << 13) >> 14\n /*FIXED_FRAC_BITS*/\n );\n destOffset = destOffset + srcH * 4 | 0;\n }\n\n destOffset = (srcY + 1) * 4 | 0;\n srcOffset = (srcY + 1) * srcW * 4 | 0;\n }\n}\n\nmodule.exports = {\n convolveHorizontally: convolveHorizontally,\n convolveVertically: convolveVertically\n};\n\n},{}],3:[function(_dereq_,module,exports){\n// This is autogenerated file from math.wasm, don't edit.\n//\n'use strict';\n/* eslint-disable max-len */\n\nmodule.exports = 'AGFzbQEAAAABFAJgBn9/f39/fwBgB39/f39/f38AAg8BA2VudgZtZW1vcnkCAAEDAwIAAQQEAXAAAAcZAghjb252b2x2ZQAACmNvbnZvbHZlSFYAAQkBAArmAwLBAwEQfwJAIANFDQAgBEUNACAFQQRqIRVBACEMQQAhDQNAIA0hDkEAIRFBACEHA0AgB0ECaiESAn8gBSAHQQF0IgdqIgZBAmouAQAiEwRAQQAhCEEAIBNrIRQgFSAHaiEPIAAgDCAGLgEAakECdGohEEEAIQlBACEKQQAhCwNAIBAoAgAiB0EYdiAPLgEAIgZsIAtqIQsgB0H/AXEgBmwgCGohCCAHQRB2Qf8BcSAGbCAKaiEKIAdBCHZB/wFxIAZsIAlqIQkgD0ECaiEPIBBBBGohECAUQQFqIhQNAAsgEiATagwBC0EAIQtBACEKQQAhCUEAIQggEgshByABIA5BAnRqIApBgMAAakEOdSIGQf8BIAZB/wFIG0EQdEGAgPwHcUEAIAZBAEobIAtBgMAAakEOdSIGQf8BIAZB/wFIG0EYdEEAIAZBAEobciAJQYDAAGpBDnUiBkH/ASAGQf8BSBtBCHRBgP4DcUEAIAZBAEobciAIQYDAAGpBDnUiBkH/ASAGQf8BSBtB/wFxQQAgBkEAShtyNgIAIA4gA2ohDiARQQFqIhEgBEcNAAsgDCACaiEMIA1BAWoiDSADRw0ACwsLIQACQEEAIAIgAyAEIAUgABAAIAJBACAEIAUgBiABEAALCw==';\n\n},{}],4:[function(_dereq_,module,exports){\n'use strict';\n\nmodule.exports = {\n name: 'resize',\n fn: _dereq_('./resize'),\n wasm_fn: _dereq_('./resize_wasm'),\n wasm_src: _dereq_('./convolve_wasm_base64')\n};\n\n},{\"./convolve_wasm_base64\":3,\"./resize\":5,\"./resize_wasm\":8}],5:[function(_dereq_,module,exports){\n'use strict';\n\nvar createFilters = _dereq_('./resize_filter_gen');\n\nvar convolveHorizontally = _dereq_('./convolve').convolveHorizontally;\n\nvar convolveVertically = _dereq_('./convolve').convolveVertically;\n\nfunction resetAlpha(dst, width, height) {\n var ptr = 3,\n len = width * height * 4 | 0;\n\n while (ptr < len) {\n dst[ptr] = 0xFF;\n ptr = ptr + 4 | 0;\n }\n}\n\nmodule.exports = function resize(options) {\n var src = options.src;\n var srcW = options.width;\n var srcH = options.height;\n var destW = options.toWidth;\n var destH = options.toHeight;\n var scaleX = options.scaleX || options.toWidth / options.width;\n var scaleY = options.scaleY || options.toHeight / options.height;\n var offsetX = options.offsetX || 0;\n var offsetY = options.offsetY || 0;\n var dest = options.dest || new Uint8Array(destW * destH * 4);\n var quality = typeof options.quality === 'undefined' ? 3 : options.quality;\n var alpha = options.alpha || false;\n var filtersX = createFilters(quality, srcW, destW, scaleX, offsetX),\n filtersY = createFilters(quality, srcH, destH, scaleY, offsetY);\n var tmp = new Uint8Array(destW * srcH * 4); // To use single function we need src & tmp of the same type.\n // But src can be CanvasPixelArray, and tmp - Uint8Array. So, keep\n // vertical and horizontal passes separately to avoid deoptimization.\n\n convolveHorizontally(src, tmp, srcW, srcH, destW, filtersX);\n convolveVertically(tmp, dest, srcH, destW, destH, filtersY); // That's faster than doing checks in convolver.\n // !!! Note, canvas data is not premultipled. We don't need other\n // alpha corrections.\n\n if (!alpha) resetAlpha(dest, destW, destH);\n return dest;\n};\n\n},{\"./convolve\":2,\"./resize_filter_gen\":6}],6:[function(_dereq_,module,exports){\n// Calculate convolution filters for each destination point,\n// and pack data to Int16Array:\n//\n// [ shift, length, data..., shift2, length2, data..., ... ]\n//\n// - shift - offset in src image\n// - length - filter length (in src points)\n// - data - filter values sequence\n//\n'use strict';\n\nvar FILTER_INFO = _dereq_('./resize_filter_info'); // Precision of fixed FP values\n\n\nvar FIXED_FRAC_BITS = 14;\n\nfunction toFixedPoint(num) {\n return Math.round(num * ((1 << FIXED_FRAC_BITS) - 1));\n}\n\nmodule.exports = function resizeFilterGen(quality, srcSize, destSize, scale, offset) {\n var filterFunction = FILTER_INFO[quality].filter;\n var scaleInverted = 1.0 / scale;\n var scaleClamped = Math.min(1.0, scale); // For upscale\n // Filter window (averaging interval), scaled to src image\n\n var srcWindow = FILTER_INFO[quality].win / scaleClamped;\n var destPixel, srcPixel, srcFirst, srcLast, filterElementSize, floatFilter, fxpFilter, total, pxl, idx, floatVal, filterTotal, filterVal;\n var leftNotEmpty, rightNotEmpty, filterShift, filterSize;\n var maxFilterElementSize = Math.floor((srcWindow + 1) * 2);\n var packedFilter = new Int16Array((maxFilterElementSize + 2) * destSize);\n var packedFilterPtr = 0;\n var slowCopy = !packedFilter.subarray || !packedFilter.set; // For each destination pixel calculate source range and built filter values\n\n for (destPixel = 0; destPixel < destSize; destPixel++) {\n // Scaling should be done relative to central pixel point\n srcPixel = (destPixel + 0.5) * scaleInverted + offset;\n srcFirst = Math.max(0, Math.floor(srcPixel - srcWindow));\n srcLast = Math.min(srcSize - 1, Math.ceil(srcPixel + srcWindow));\n filterElementSize = srcLast - srcFirst + 1;\n floatFilter = new Float32Array(filterElementSize);\n fxpFilter = new Int16Array(filterElementSize);\n total = 0.0; // Fill filter values for calculated range\n\n for (pxl = srcFirst, idx = 0; pxl <= srcLast; pxl++, idx++) {\n floatVal = filterFunction((pxl + 0.5 - srcPixel) * scaleClamped);\n total += floatVal;\n floatFilter[idx] = floatVal;\n } // Normalize filter, convert to fixed point and accumulate conversion error\n\n\n filterTotal = 0;\n\n for (idx = 0; idx < floatFilter.length; idx++) {\n filterVal = floatFilter[idx] / total;\n filterTotal += filterVal;\n fxpFilter[idx] = toFixedPoint(filterVal);\n } // Compensate normalization error, to minimize brightness drift\n\n\n fxpFilter[destSize >> 1] += toFixedPoint(1.0 - filterTotal); //\n // Now pack filter to useable form\n //\n // 1. Trim heading and tailing zero values, and compensate shitf/length\n // 2. Put all to single array in this format:\n //\n // [ pos shift, data length, value1, value2, value3, ... ]\n //\n\n leftNotEmpty = 0;\n\n while (leftNotEmpty < fxpFilter.length && fxpFilter[leftNotEmpty] === 0) {\n leftNotEmpty++;\n }\n\n if (leftNotEmpty < fxpFilter.length) {\n rightNotEmpty = fxpFilter.length - 1;\n\n while (rightNotEmpty > 0 && fxpFilter[rightNotEmpty] === 0) {\n rightNotEmpty--;\n }\n\n filterShift = srcFirst + leftNotEmpty;\n filterSize = rightNotEmpty - leftNotEmpty + 1;\n packedFilter[packedFilterPtr++] = filterShift; // shift\n\n packedFilter[packedFilterPtr++] = filterSize; // size\n\n if (!slowCopy) {\n packedFilter.set(fxpFilter.subarray(leftNotEmpty, rightNotEmpty + 1), packedFilterPtr);\n packedFilterPtr += filterSize;\n } else {\n // fallback for old IE < 11, without subarray/set methods\n for (idx = leftNotEmpty; idx <= rightNotEmpty; idx++) {\n packedFilter[packedFilterPtr++] = fxpFilter[idx];\n }\n }\n } else {\n // zero data, write header only\n packedFilter[packedFilterPtr++] = 0; // shift\n\n packedFilter[packedFilterPtr++] = 0; // size\n }\n }\n\n return packedFilter;\n};\n\n},{\"./resize_filter_info\":7}],7:[function(_dereq_,module,exports){\n// Filter definitions to build tables for\n// resizing convolvers.\n//\n// Presets for quality 0..3. Filter functions + window size\n//\n'use strict';\n\nmodule.exports = [{\n // Nearest neibor (Box)\n win: 0.5,\n filter: function filter(x) {\n return x >= -0.5 && x < 0.5 ? 1.0 : 0.0;\n }\n}, {\n // Hamming\n win: 1.0,\n filter: function filter(x) {\n if (x <= -1.0 || x >= 1.0) {\n return 0.0;\n }\n\n if (x > -1.19209290E-07 && x < 1.19209290E-07) {\n return 1.0;\n }\n\n var xpi = x * Math.PI;\n return Math.sin(xpi) / xpi * (0.54 + 0.46 * Math.cos(xpi / 1.0));\n }\n}, {\n // Lanczos, win = 2\n win: 2.0,\n filter: function filter(x) {\n if (x <= -2.0 || x >= 2.0) {\n return 0.0;\n }\n\n if (x > -1.19209290E-07 && x < 1.19209290E-07) {\n return 1.0;\n }\n\n var xpi = x * Math.PI;\n return Math.sin(xpi) / xpi * Math.sin(xpi / 2.0) / (xpi / 2.0);\n }\n}, {\n // Lanczos, win = 3\n win: 3.0,\n filter: function filter(x) {\n if (x <= -3.0 || x >= 3.0) {\n return 0.0;\n }\n\n if (x > -1.19209290E-07 && x < 1.19209290E-07) {\n return 1.0;\n }\n\n var xpi = x * Math.PI;\n return Math.sin(xpi) / xpi * Math.sin(xpi / 3.0) / (xpi / 3.0);\n }\n}];\n\n},{}],8:[function(_dereq_,module,exports){\n'use strict';\n\nvar createFilters = _dereq_('./resize_filter_gen');\n\nfunction resetAlpha(dst, width, height) {\n var ptr = 3,\n len = width * height * 4 | 0;\n\n while (ptr < len) {\n dst[ptr] = 0xFF;\n ptr = ptr + 4 | 0;\n }\n}\n\nfunction asUint8Array(src) {\n return new Uint8Array(src.buffer, 0, src.byteLength);\n}\n\nvar IS_LE = true; // should not crash everything on module load in old browsers\n\ntry {\n IS_LE = new Uint32Array(new Uint8Array([1, 0, 0, 0]).buffer)[0] === 1;\n} catch (__) {}\n\nfunction copyInt16asLE(src, target, target_offset) {\n if (IS_LE) {\n target.set(asUint8Array(src), target_offset);\n return;\n }\n\n for (var ptr = target_offset, i = 0; i < src.length; i++) {\n var data = src[i];\n target[ptr++] = data & 0xFF;\n target[ptr++] = data >> 8 & 0xFF;\n }\n}\n\nmodule.exports = function resize_wasm(options) {\n var src = options.src;\n var srcW = options.width;\n var srcH = options.height;\n var destW = options.toWidth;\n var destH = options.toHeight;\n var scaleX = options.scaleX || options.toWidth / options.width;\n var scaleY = options.scaleY || options.toHeight / options.height;\n var offsetX = options.offsetX || 0.0;\n var offsetY = options.offsetY || 0.0;\n var dest = options.dest || new Uint8Array(destW * destH * 4);\n var quality = typeof options.quality === 'undefined' ? 3 : options.quality;\n var alpha = options.alpha || false;\n var filtersX = createFilters(quality, srcW, destW, scaleX, offsetX),\n filtersY = createFilters(quality, srcH, destH, scaleY, offsetY); // destination is 0 too.\n\n var src_offset = 0; // buffer between convolve passes\n\n var tmp_offset = this.__align(src_offset + Math.max(src.byteLength, dest.byteLength));\n\n var filtersX_offset = this.__align(tmp_offset + srcH * destW * 4);\n\n var filtersY_offset = this.__align(filtersX_offset + filtersX.byteLength);\n\n var alloc_bytes = filtersY_offset + filtersY.byteLength;\n\n var instance = this.__instance('resize', alloc_bytes); //\n // Fill memory block with data to process\n //\n\n\n var mem = new Uint8Array(this.__memory.buffer);\n var mem32 = new Uint32Array(this.__memory.buffer); // 32-bit copy is much faster in chrome\n\n var src32 = new Uint32Array(src.buffer);\n mem32.set(src32); // We should guarantee LE bytes order. Filters are not big, so\n // speed difference is not significant vs direct .set()\n\n copyInt16asLE(filtersX, mem, filtersX_offset);\n copyInt16asLE(filtersY, mem, filtersY_offset); //\n // Now call webassembly method\n // emsdk does method names with '_'\n\n var fn = instance.exports.convolveHV || instance.exports._convolveHV;\n fn(filtersX_offset, filtersY_offset, tmp_offset, srcW, srcH, destW, destH); //\n // Copy data back to typed array\n //\n // 32-bit copy is much faster in chrome\n\n var dest32 = new Uint32Array(dest.buffer);\n dest32.set(new Uint32Array(this.__memory.buffer, 0, destH * destW)); // That's faster than doing checks in convolver.\n // !!! Note, canvas data is not premultipled. We don't need other\n // alpha corrections.\n\n if (!alpha) resetAlpha(dest, destW, destH);\n return dest;\n};\n\n},{\"./resize_filter_gen\":6}],9:[function(_dereq_,module,exports){\n'use strict';\n\nvar GC_INTERVAL = 100;\n\nfunction Pool(create, idle) {\n this.create = create;\n this.available = [];\n this.acquired = {};\n this.lastId = 1;\n this.timeoutId = 0;\n this.idle = idle || 2000;\n}\n\nPool.prototype.acquire = function () {\n var _this = this;\n\n var resource;\n\n if (this.available.length !== 0) {\n resource = this.available.pop();\n } else {\n resource = this.create();\n resource.id = this.lastId++;\n\n resource.release = function () {\n return _this.release(resource);\n };\n }\n\n this.acquired[resource.id] = resource;\n return resource;\n};\n\nPool.prototype.release = function (resource) {\n var _this2 = this;\n\n delete this.acquired[resource.id];\n resource.lastUsed = Date.now();\n this.available.push(resource);\n\n if (this.timeoutId === 0) {\n this.timeoutId = setTimeout(function () {\n return _this2.gc();\n }, GC_INTERVAL);\n }\n};\n\nPool.prototype.gc = function () {\n var _this3 = this;\n\n var now = Date.now();\n this.available = this.available.filter(function (resource) {\n if (now - resource.lastUsed > _this3.idle) {\n resource.destroy();\n return false;\n }\n\n return true;\n });\n\n if (this.available.length !== 0) {\n this.timeoutId = setTimeout(function () {\n return _this3.gc();\n }, GC_INTERVAL);\n } else {\n this.timeoutId = 0;\n }\n};\n\nmodule.exports = Pool;\n\n},{}],10:[function(_dereq_,module,exports){\n// Add intermediate resizing steps when scaling down by a very large factor.\n//\n// For example, when resizing 10000x10000 down to 10x10, it'll resize it to\n// 300x300 first.\n//\n// It's needed because tiler has issues when the entire tile is scaled down\n// to a few pixels (1024px source tile with border size 3 should result in\n// at least 3+3+2 = 8px target tile, so max scale factor is 128 here).\n//\n// Also, adding intermediate steps can speed up processing if we use lower\n// quality algorithms for first stages.\n//\n'use strict'; // min size = 0 results in infinite loop,\n// min size = 1 can consume large amount of memory\n\nvar MIN_INNER_TILE_SIZE = 2;\n\nmodule.exports = function createStages(fromWidth, fromHeight, toWidth, toHeight, srcTileSize, destTileBorder) {\n var scaleX = toWidth / fromWidth;\n var scaleY = toHeight / fromHeight; // derived from createRegions equation:\n // innerTileWidth = pixelFloor(srcTileSize * scaleX) - 2 * destTileBorder;\n\n var minScale = (2 * destTileBorder + MIN_INNER_TILE_SIZE + 1) / srcTileSize; // refuse to scale image multiple times by less than twice each time,\n // it could only happen because of invalid options\n\n if (minScale > 0.5) return [[toWidth, toHeight]];\n var stageCount = Math.ceil(Math.log(Math.min(scaleX, scaleY)) / Math.log(minScale)); // no additional resizes are necessary,\n // stageCount can be zero or be negative when enlarging the image\n\n if (stageCount <= 1) return [[toWidth, toHeight]];\n var result = [];\n\n for (var i = 0; i < stageCount; i++) {\n var width = Math.round(Math.pow(Math.pow(fromWidth, stageCount - i - 1) * Math.pow(toWidth, i + 1), 1 / stageCount));\n var height = Math.round(Math.pow(Math.pow(fromHeight, stageCount - i - 1) * Math.pow(toHeight, i + 1), 1 / stageCount));\n result.push([width, height]);\n }\n\n return result;\n};\n\n},{}],11:[function(_dereq_,module,exports){\n// Split original image into multiple 1024x1024 chunks to reduce memory usage\n// (images have to be unpacked into typed arrays for resizing) and allow\n// parallel processing of multiple tiles at a time.\n//\n'use strict';\n/*\n * pixelFloor and pixelCeil are modified versions of Math.floor and Math.ceil\n * functions which take into account floating point arithmetic errors.\n * Those errors can cause undesired increments/decrements of sizes and offsets:\n * Math.ceil(36 / (36 / 500)) = 501\n * pixelCeil(36 / (36 / 500)) = 500\n */\n\nvar PIXEL_EPSILON = 1e-5;\n\nfunction pixelFloor(x) {\n var nearest = Math.round(x);\n\n if (Math.abs(x - nearest) < PIXEL_EPSILON) {\n return nearest;\n }\n\n return Math.floor(x);\n}\n\nfunction pixelCeil(x) {\n var nearest = Math.round(x);\n\n if (Math.abs(x - nearest) < PIXEL_EPSILON) {\n return nearest;\n }\n\n return Math.ceil(x);\n}\n\nmodule.exports = function createRegions(options) {\n var scaleX = options.toWidth / options.width;\n var scaleY = options.toHeight / options.height;\n var innerTileWidth = pixelFloor(options.srcTileSize * scaleX) - 2 * options.destTileBorder;\n var innerTileHeight = pixelFloor(options.srcTileSize * scaleY) - 2 * options.destTileBorder; // prevent infinite loop, this should never happen\n\n if (innerTileWidth < 1 || innerTileHeight < 1) {\n throw new Error('Internal error in pica: target tile width/height is too small.');\n }\n\n var x, y;\n var innerX, innerY, toTileWidth, toTileHeight;\n var tiles = [];\n var tile; // we go top-to-down instead of left-to-right to make image displayed from top to\n // doesn in the browser\n\n for (innerY = 0; innerY < options.toHeight; innerY += innerTileHeight) {\n for (innerX = 0; innerX < options.toWidth; innerX += innerTileWidth) {\n x = innerX - options.destTileBorder;\n\n if (x < 0) {\n x = 0;\n }\n\n toTileWidth = innerX + innerTileWidth + options.destTileBorder - x;\n\n if (x + toTileWidth >= options.toWidth) {\n toTileWidth = options.toWidth - x;\n }\n\n y = innerY - options.destTileBorder;\n\n if (y < 0) {\n y = 0;\n }\n\n toTileHeight = innerY + innerTileHeight + options.destTileBorder - y;\n\n if (y + toTileHeight >= options.toHeight) {\n toTileHeight = options.toHeight - y;\n }\n\n tile = {\n toX: x,\n toY: y,\n toWidth: toTileWidth,\n toHeight: toTileHeight,\n toInnerX: innerX,\n toInnerY: innerY,\n toInnerWidth: innerTileWidth,\n toInnerHeight: innerTileHeight,\n offsetX: x / scaleX - pixelFloor(x / scaleX),\n offsetY: y / scaleY - pixelFloor(y / scaleY),\n scaleX: scaleX,\n scaleY: scaleY,\n x: pixelFloor(x / scaleX),\n y: pixelFloor(y / scaleY),\n width: pixelCeil(toTileWidth / scaleX),\n height: pixelCeil(toTileHeight / scaleY)\n };\n tiles.push(tile);\n }\n }\n\n return tiles;\n};\n\n},{}],12:[function(_dereq_,module,exports){\n'use strict';\n\nfunction objClass(obj) {\n return Object.prototype.toString.call(obj);\n}\n\nmodule.exports.isCanvas = function isCanvas(element) {\n var cname = objClass(element);\n return cname === '[object HTMLCanvasElement]'\n /* browser */\n || cname === '[object OffscreenCanvas]' || cname === '[object Canvas]'\n /* node-canvas */\n ;\n};\n\nmodule.exports.isImage = function isImage(element) {\n return objClass(element) === '[object HTMLImageElement]';\n};\n\nmodule.exports.isImageBitmap = function isImageBitmap(element) {\n return objClass(element) === '[object ImageBitmap]';\n};\n\nmodule.exports.limiter = function limiter(concurrency) {\n var active = 0,\n queue = [];\n\n function roll() {\n if (active < concurrency && queue.length) {\n active++;\n queue.shift()();\n }\n }\n\n return function limit(fn) {\n return new Promise(function (resolve, reject) {\n queue.push(function () {\n fn().then(function (result) {\n resolve(result);\n active--;\n roll();\n }, function (err) {\n reject(err);\n active--;\n roll();\n });\n });\n roll();\n });\n };\n};\n\nmodule.exports.cib_quality_name = function cib_quality_name(num) {\n switch (num) {\n case 0:\n return 'pixelated';\n\n case 1:\n return 'low';\n\n case 2:\n return 'medium';\n }\n\n return 'high';\n};\n\nmodule.exports.cib_support = function cib_support(createCanvas) {\n return Promise.resolve().then(function () {\n if (typeof createImageBitmap === 'undefined') {\n return false;\n }\n\n var c = createCanvas(100, 100);\n return createImageBitmap(c, 0, 0, 100, 100, {\n resizeWidth: 10,\n resizeHeight: 10,\n resizeQuality: 'high'\n }).then(function (bitmap) {\n var status = bitmap.width === 10; // Branch below is filtered on upper level. We do not call resize\n // detection for basic ImageBitmap.\n //\n // https://developer.mozilla.org/en-US/docs/Web/API/ImageBitmap\n // old Crome 51 has ImageBitmap without .close(). Then this code\n // will throw and return 'false' as expected.\n //\n\n bitmap.close();\n c = null;\n return status;\n });\n })[\"catch\"](function () {\n return false;\n });\n};\n\n},{}],13:[function(_dereq_,module,exports){\n// Web Worker wrapper for image resize function\n'use strict';\n\nmodule.exports = function () {\n var MathLib = _dereq_('./mathlib');\n\n var mathLib;\n /* eslint-disable no-undef */\n\n onmessage = function onmessage(ev) {\n var opts = ev.data.opts;\n if (!mathLib) mathLib = new MathLib(ev.data.features); // Use multimath's sync auto-init. Avoid Promise use in old browsers,\n // because polyfills are not propagated to webworker.\n\n var result = mathLib.resizeAndUnsharp(opts);\n postMessage({\n result: result\n }, [result.buffer]);\n };\n};\n\n},{\"./mathlib\":1}],14:[function(_dereq_,module,exports){\n// Calculate Gaussian blur of an image using IIR filter\n// The method is taken from Intel's white paper and code example attached to it:\n// https://software.intel.com/en-us/articles/iir-gaussian-blur-filter\n// -implementation-using-intel-advanced-vector-extensions\n\nvar a0, a1, a2, a3, b1, b2, left_corner, right_corner;\n\nfunction gaussCoef(sigma) {\n if (sigma < 0.5) {\n sigma = 0.5;\n }\n\n var a = Math.exp(0.726 * 0.726) / sigma,\n g1 = Math.exp(-a),\n g2 = Math.exp(-2 * a),\n k = (1 - g1) * (1 - g1) / (1 + 2 * a * g1 - g2);\n\n a0 = k;\n a1 = k * (a - 1) * g1;\n a2 = k * (a + 1) * g1;\n a3 = -k * g2;\n b1 = 2 * g1;\n b2 = -g2;\n left_corner = (a0 + a1) / (1 - b1 - b2);\n right_corner = (a2 + a3) / (1 - b1 - b2);\n\n // Attempt to force type to FP32.\n return new Float32Array([ a0, a1, a2, a3, b1, b2, left_corner, right_corner ]);\n}\n\nfunction convolveMono16(src, out, line, coeff, width, height) {\n // takes src image and writes the blurred and transposed result into out\n\n var prev_src, curr_src, curr_out, prev_out, prev_prev_out;\n var src_index, out_index, line_index;\n var i, j;\n var coeff_a0, coeff_a1, coeff_b1, coeff_b2;\n\n for (i = 0; i < height; i++) {\n src_index = i * width;\n out_index = i;\n line_index = 0;\n\n // left to right\n prev_src = src[src_index];\n prev_prev_out = prev_src * coeff[6];\n prev_out = prev_prev_out;\n\n coeff_a0 = coeff[0];\n coeff_a1 = coeff[1];\n coeff_b1 = coeff[4];\n coeff_b2 = coeff[5];\n\n for (j = 0; j < width; j++) {\n curr_src = src[src_index];\n\n curr_out = curr_src * coeff_a0 +\n prev_src * coeff_a1 +\n prev_out * coeff_b1 +\n prev_prev_out * coeff_b2;\n\n prev_prev_out = prev_out;\n prev_out = curr_out;\n prev_src = curr_src;\n\n line[line_index] = prev_out;\n line_index++;\n src_index++;\n }\n\n src_index--;\n line_index--;\n out_index += height * (width - 1);\n\n // right to left\n prev_src = src[src_index];\n prev_prev_out = prev_src * coeff[7];\n prev_out = prev_prev_out;\n curr_src = prev_src;\n\n coeff_a0 = coeff[2];\n coeff_a1 = coeff[3];\n\n for (j = width - 1; j >= 0; j--) {\n curr_out = curr_src * coeff_a0 +\n prev_src * coeff_a1 +\n prev_out * coeff_b1 +\n prev_prev_out * coeff_b2;\n\n prev_prev_out = prev_out;\n prev_out = curr_out;\n\n prev_src = curr_src;\n curr_src = src[src_index];\n\n out[out_index] = line[line_index] + prev_out;\n\n src_index--;\n line_index--;\n out_index -= height;\n }\n }\n}\n\n\nfunction blurMono16(src, width, height, radius) {\n // Quick exit on zero radius\n if (!radius) { return; }\n\n var out = new Uint16Array(src.length),\n tmp_line = new Float32Array(Math.max(width, height));\n\n var coeff = gaussCoef(radius);\n\n convolveMono16(src, out, tmp_line, coeff, width, height, radius);\n convolveMono16(out, src, tmp_line, coeff, height, width, radius);\n}\n\nmodule.exports = blurMono16;\n\n},{}],15:[function(_dereq_,module,exports){\nif (typeof Object.create === 'function') {\n // implementation from standard node.js 'util' module\n module.exports = function inherits(ctor, superCtor) {\n if (superCtor) {\n ctor.super_ = superCtor\n ctor.prototype = Object.create(superCtor.prototype, {\n constructor: {\n value: ctor,\n enumerable: false,\n writable: true,\n configurable: true\n }\n })\n }\n };\n} else {\n // old school shim for old browsers\n module.exports = function inherits(ctor, superCtor) {\n if (superCtor) {\n ctor.super_ = superCtor\n var TempCtor = function () {}\n TempCtor.prototype = superCtor.prototype\n ctor.prototype = new TempCtor()\n ctor.prototype.constructor = ctor\n }\n }\n}\n\n},{}],16:[function(_dereq_,module,exports){\n'use strict';\n\n\nvar assign = _dereq_('object-assign');\nvar base64decode = _dereq_('./lib/base64decode');\nvar hasWebAssembly = _dereq_('./lib/wa_detect');\n\n\nvar DEFAULT_OPTIONS = {\n js: true,\n wasm: true\n};\n\n\nfunction MultiMath(options) {\n if (!(this instanceof MultiMath)) return new MultiMath(options);\n\n var opts = assign({}, DEFAULT_OPTIONS, options || {});\n\n this.options = opts;\n\n this.__cache = {};\n\n this.__init_promise = null;\n this.__modules = opts.modules || {};\n this.__memory = null;\n this.__wasm = {};\n\n this.__isLE = ((new Uint32Array((new Uint8Array([ 1, 0, 0, 0 ])).buffer))[0] === 1);\n\n if (!this.options.js && !this.options.wasm) {\n throw new Error('mathlib: at least \"js\" or \"wasm\" should be enabled');\n }\n}\n\n\nMultiMath.prototype.has_wasm = hasWebAssembly;\n\n\nMultiMath.prototype.use = function (module) {\n this.__modules[module.name] = module;\n\n // Pin the best possible implementation\n if (this.options.wasm && this.has_wasm() && module.wasm_fn) {\n this[module.name] = module.wasm_fn;\n } else {\n this[module.name] = module.fn;\n }\n\n return this;\n};\n\n\nMultiMath.prototype.init = function () {\n if (this.__init_promise) return this.__init_promise;\n\n if (!this.options.js && this.options.wasm && !this.has_wasm()) {\n return Promise.reject(new Error('mathlib: only \"wasm\" was enabled, but it\\'s not supported'));\n }\n\n var self = this;\n\n this.__init_promise = Promise.all(Object.keys(self.__modules).map(function (name) {\n var module = self.__modules[name];\n\n if (!self.options.wasm || !self.has_wasm() || !module.wasm_fn) return null;\n\n // If already compiled - exit\n if (self.__wasm[name]) return null;\n\n // Compile wasm source\n return WebAssembly.compile(self.__base64decode(module.wasm_src))\n .then(function (m) { self.__wasm[name] = m; });\n }))\n .then(function () { return self; });\n\n return this.__init_promise;\n};\n\n\n////////////////////////////////////////////////////////////////////////////////\n// Methods below are for internal use from plugins\n\n\n// Simple decode base64 to typed array. Useful to load embedded webassembly\n// code. You probably don't need to call this method directly.\n//\nMultiMath.prototype.__base64decode = base64decode;\n\n\n// Increase current memory to include specified number of bytes. Do nothing if\n// size is already ok. You probably don't need to call this method directly,\n// because it will be invoked from `.__instance()`.\n//\nMultiMath.prototype.__reallocate = function mem_grow_to(bytes) {\n if (!this.__memory) {\n this.__memory = new WebAssembly.Memory({\n initial: Math.ceil(bytes / (64 * 1024))\n });\n return this.__memory;\n }\n\n var mem_size = this.__memory.buffer.byteLength;\n\n if (mem_size < bytes) {\n this.__memory.grow(Math.ceil((bytes - mem_size) / (64 * 1024)));\n }\n\n return this.__memory;\n};\n\n\n// Returns instantinated webassembly item by name, with specified memory size\n// and environment.\n// - use cache if available\n// - do sync module init, if async init was not called earlier\n// - allocate memory if not enougth\n// - can export functions to webassembly via \"env_extra\",\n// for example, { exp: Math.exp }\n//\nMultiMath.prototype.__instance = function instance(name, memsize, env_extra) {\n if (memsize) this.__reallocate(memsize);\n\n // If .init() was not called, do sync compile\n if (!this.__wasm[name]) {\n var module = this.__modules[name];\n this.__wasm[name] = new WebAssembly.Module(this.__base64decode(module.wasm_src));\n }\n\n if (!this.__cache[name]) {\n var env_base = {\n memoryBase: 0,\n memory: this.__memory,\n tableBase: 0,\n table: new WebAssembly.Table({ initial: 0, element: 'anyfunc' })\n };\n\n this.__cache[name] = new WebAssembly.Instance(this.__wasm[name], {\n env: assign(env_base, env_extra || {})\n });\n }\n\n return this.__cache[name];\n};\n\n\n// Helper to calculate memory aligh for pointers. Webassembly does not require\n// this, but you may wish to experiment. Default base = 8;\n//\nMultiMath.prototype.__align = function align(number, base) {\n base = base || 8;\n var reminder = number % base;\n return number + (reminder ? base - reminder : 0);\n};\n\n\nmodule.exports = MultiMath;\n\n},{\"./lib/base64decode\":17,\"./lib/wa_detect\":23,\"object-assign\":24}],17:[function(_dereq_,module,exports){\n// base64 decode str -> Uint8Array, to load WA modules\n//\n'use strict';\n\n\nvar BASE64_MAP = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/';\n\n\nmodule.exports = function base64decode(str) {\n var input = str.replace(/[\\r\\n=]/g, ''), // remove CR/LF & padding to simplify scan\n max = input.length;\n\n var out = new Uint8Array((max * 3) >> 2);\n\n // Collect by 6*4 bits (3 bytes)\n\n var bits = 0;\n var ptr = 0;\n\n for (var idx = 0; idx < max; idx++) {\n if ((idx % 4 === 0) && idx) {\n out[ptr++] = (bits >> 16) & 0xFF;\n out[ptr++] = (bits >> 8) & 0xFF;\n out[ptr++] = bits & 0xFF;\n }\n\n bits = (bits << 6) | BASE64_MAP.indexOf(input.charAt(idx));\n }\n\n // Dump tail\n\n var tailbits = (max % 4) * 6;\n\n if (tailbits === 0) {\n out[ptr++] = (bits >> 16) & 0xFF;\n out[ptr++] = (bits >> 8) & 0xFF;\n out[ptr++] = bits & 0xFF;\n } else if (tailbits === 18) {\n out[ptr++] = (bits >> 10) & 0xFF;\n out[ptr++] = (bits >> 2) & 0xFF;\n } else if (tailbits === 12) {\n out[ptr++] = (bits >> 4) & 0xFF;\n }\n\n return out;\n};\n\n},{}],18:[function(_dereq_,module,exports){\n// Calculates 16-bit precision HSL lightness from 8-bit rgba buffer\n//\n'use strict';\n\n\nmodule.exports = function hsl_l16_js(img, width, height) {\n var size = width * height;\n var out = new Uint16Array(size);\n var r, g, b, min, max;\n for (var i = 0; i < size; i++) {\n r = img[4 * i];\n g = img[4 * i + 1];\n b = img[4 * i + 2];\n max = (r >= g && r >= b) ? r : (g >= b && g >= r) ? g : b;\n min = (r <= g && r <= b) ? r : (g <= b && g <= r) ? g : b;\n out[i] = (max + min) * 257 >> 1;\n }\n return out;\n};\n\n},{}],19:[function(_dereq_,module,exports){\n'use strict';\n\nmodule.exports = {\n name: 'unsharp_mask',\n fn: _dereq_('./unsharp_mask'),\n wasm_fn: _dereq_('./unsharp_mask_wasm'),\n wasm_src: _dereq_('./unsharp_mask_wasm_base64')\n};\n\n},{\"./unsharp_mask\":20,\"./unsharp_mask_wasm\":21,\"./unsharp_mask_wasm_base64\":22}],20:[function(_dereq_,module,exports){\n// Unsharp mask filter\n//\n// http://stackoverflow.com/a/23322820/1031804\n// USM(O) = O + (2 * (Amount / 100) * (O - GB))\n// GB - gaussian blur.\n//\n// Image is converted from RGB to HSL, unsharp mask is applied to the\n// lightness channel and then image is converted back to RGB.\n//\n'use strict';\n\n\nvar glur_mono16 = _dereq_('glur/mono16');\nvar hsl_l16 = _dereq_('./hsl_l16');\n\n\nmodule.exports = function unsharp(img, width, height, amount, radius, threshold) {\n var r, g, b;\n var h, s, l;\n var min, max;\n var m1, m2, hShifted;\n var diff, iTimes4;\n\n if (amount === 0 || radius < 0.5) {\n return;\n }\n if (radius > 2.0) {\n radius = 2.0;\n }\n\n var lightness = hsl_l16(img, width, height);\n\n var blured = new Uint16Array(lightness); // copy, because blur modify src\n\n glur_mono16(blured, width, height, radius);\n\n var amountFp = (amount / 100 * 0x1000 + 0.5)|0;\n var thresholdFp = (threshold * 257)|0;\n\n var size = width * height;\n\n /* eslint-disable indent */\n for (var i = 0; i < size; i++) {\n diff = 2 * (lightness[i] - blured[i]);\n\n if (Math.abs(diff) >= thresholdFp) {\n iTimes4 = i * 4;\n r = img[iTimes4];\n g = img[iTimes4 + 1];\n b = img[iTimes4 + 2];\n\n // convert RGB to HSL\n // take RGB, 8-bit unsigned integer per each channel\n // save HSL, H and L are 16-bit unsigned integers, S is 12-bit unsigned integer\n // math is taken from here: http://www.easyrgb.com/index.php?X=MATH&H=18\n // and adopted to be integer (fixed point in fact) for sake of performance\n max = (r >= g && r >= b) ? r : (g >= r && g >= b) ? g : b; // min and max are in [0..0xff]\n min = (r <= g && r <= b) ? r : (g <= r && g <= b) ? g : b;\n l = (max + min) * 257 >> 1; // l is in [0..0xffff] that is caused by multiplication by 257\n\n if (min === max) {\n h = s = 0;\n } else {\n s = (l <= 0x7fff) ?\n (((max - min) * 0xfff) / (max + min))|0 :\n (((max - min) * 0xfff) / (2 * 0xff - max - min))|0; // s is in [0..0xfff]\n // h could be less 0, it will be fixed in backward conversion to RGB, |h| <= 0xffff / 6\n h = (r === max) ? (((g - b) * 0xffff) / (6 * (max - min)))|0\n : (g === max) ? 0x5555 + ((((b - r) * 0xffff) / (6 * (max - min)))|0) // 0x5555 == 0xffff / 3\n : 0xaaaa + ((((r - g) * 0xffff) / (6 * (max - min)))|0); // 0xaaaa == 0xffff * 2 / 3\n }\n\n // add unsharp mask mask to the lightness channel\n l += (amountFp * diff + 0x800) >> 12;\n if (l > 0xffff) {\n l = 0xffff;\n } else if (l < 0) {\n l = 0;\n }\n\n // convert HSL back to RGB\n // for information about math look above\n if (s === 0) {\n r = g = b = l >> 8;\n } else {\n m2 = (l <= 0x7fff) ? (l * (0x1000 + s) + 0x800) >> 12 :\n l + (((0xffff - l) * s + 0x800) >> 12);\n m1 = 2 * l - m2 >> 8;\n m2 >>= 8;\n // save result to RGB channels\n // R channel\n hShifted = (h + 0x5555) & 0xffff; // 0x5555 == 0xffff / 3\n r = (hShifted >= 0xaaaa) ? m1 // 0xaaaa == 0xffff * 2 / 3\n : (hShifted >= 0x7fff) ? m1 + ((m2 - m1) * 6 * (0xaaaa - hShifted) + 0x8000 >> 16)\n : (hShifted >= 0x2aaa) ? m2 // 0x2aaa == 0xffff / 6\n : m1 + ((m2 - m1) * 6 * hShifted + 0x8000 >> 16);\n // G channel\n hShifted = h & 0xffff;\n g = (hShifted >= 0xaaaa) ? m1 // 0xaaaa == 0xffff * 2 / 3\n : (hShifted >= 0x7fff) ? m1 + ((m2 - m1) * 6 * (0xaaaa - hShifted) + 0x8000 >> 16)\n : (hShifted >= 0x2aaa) ? m2 // 0x2aaa == 0xffff / 6\n : m1 + ((m2 - m1) * 6 * hShifted + 0x8000 >> 16);\n // B channel\n hShifted = (h - 0x5555) & 0xffff;\n b = (hShifted >= 0xaaaa) ? m1 // 0xaaaa == 0xffff * 2 / 3\n : (hShifted >= 0x7fff) ? m1 + ((m2 - m1) * 6 * (0xaaaa - hShifted) + 0x8000 >> 16)\n : (hShifted >= 0x2aaa) ? m2 // 0x2aaa == 0xffff / 6\n : m1 + ((m2 - m1) * 6 * hShifted + 0x8000 >> 16);\n }\n\n img[iTimes4] = r;\n img[iTimes4 + 1] = g;\n img[iTimes4 + 2] = b;\n }\n }\n};\n\n},{\"./hsl_l16\":18,\"glur/mono16\":14}],21:[function(_dereq_,module,exports){\n'use strict';\n\n\nmodule.exports = function unsharp(img, width, height, amount, radius, threshold) {\n if (amount === 0 || radius < 0.5) {\n return;\n }\n\n if (radius > 2.0) {\n radius = 2.0;\n }\n\n var pixels = width * height;\n\n var img_bytes_cnt = pixels * 4;\n var hsl_bytes_cnt = pixels * 2;\n var blur_bytes_cnt = pixels * 2;\n var blur_line_byte_cnt = Math.max(width, height) * 4; // float32 array\n var blur_coeffs_byte_cnt = 8 * 4; // float32 array\n\n var img_offset = 0;\n var hsl_offset = img_bytes_cnt;\n var blur_offset = hsl_offset + hsl_bytes_cnt;\n var blur_tmp_offset = blur_offset + blur_bytes_cnt;\n var blur_line_offset = blur_tmp_offset + blur_bytes_cnt;\n var blur_coeffs_offset = blur_line_offset + blur_line_byte_cnt;\n\n var instance = this.__instance(\n 'unsharp_mask',\n img_bytes_cnt + hsl_bytes_cnt + blur_bytes_cnt * 2 + blur_line_byte_cnt + blur_coeffs_byte_cnt,\n { exp: Math.exp }\n );\n\n // 32-bit copy is much faster in chrome\n var img32 = new Uint32Array(img.buffer);\n var mem32 = new Uint32Array(this.__memory.buffer);\n mem32.set(img32);\n\n // HSL\n var fn = instance.exports.hsl_l16 || instance.exports._hsl_l16;\n fn(img_offset, hsl_offset, width, height);\n\n // BLUR\n fn = instance.exports.blurMono16 || instance.exports._blurMono16;\n fn(hsl_offset, blur_offset, blur_tmp_offset,\n blur_line_offset, blur_coeffs_offset, width, height, radius);\n\n // UNSHARP\n fn = instance.exports.unsharp || instance.exports._unsharp;\n fn(img_offset, img_offset, hsl_offset,\n blur_offset, width, height, amount, threshold);\n\n // 32-bit copy is much faster in chrome\n img32.set(new Uint32Array(this.__memory.buffer, 0, pixels));\n};\n\n},{}],22:[function(_dereq_,module,exports){\n// This is autogenerated file from math.wasm, don't edit.\n//\n'use strict';\n\n/* eslint-disable max-len */\nmodule.exports = 'AGFzbQEAAAABMQZgAXwBfGACfX8AYAZ/f39/f38AYAh/f39/f39/fQBgBH9/f38AYAh/f39/f39/fwACGQIDZW52A2V4cAAAA2VudgZtZW1vcnkCAAEDBgUBAgMEBQQEAXAAAAdMBRZfX2J1aWxkX2dhdXNzaWFuX2NvZWZzAAEOX19nYXVzczE2X2xpbmUAAgpibHVyTW9ubzE2AAMHaHNsX2wxNgAEB3Vuc2hhcnAABQkBAAqJEAXZAQEGfAJAIAFE24a6Q4Ia+z8gALujIgOaEAAiBCAEoCIGtjgCECABIANEAAAAAAAAAMCiEAAiBbaMOAIUIAFEAAAAAAAA8D8gBKEiAiACoiAEIAMgA6CiRAAAAAAAAPA/oCAFoaMiArY4AgAgASAEIANEAAAAAAAA8L+gIAKioiIHtjgCBCABIAQgA0QAAAAAA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CAAmpBEHYgBmohBAsCfyAGIgUgCUH//wNxIghBqdUCSw0AGkGq1QIgCGsgByAGa2xBBmxBgIACakEQdiAGaiAIQf//AU8NABogByIFIAhBqdUASw0AGiAIIAcgBmtsQQZsQYCAAmpBEHYgBmoLIQUgCUGr1QJqQf//A3EiCEGp1QJLDQAgCEH//wFPBEBBqtUCIAhrIAcgBmtsQQZsQYCAAmpBEHYgBmohBgwBCyAIQanVAEsEQCAHIQYMAQsgCCAHIAZrbEEGbEGAgAJqQRB2IAZqIQYLIAEgBDoAACABQQFqIAU6AAAgAUECaiAGOgAACyADQQJqIQMgAkECaiECIABBBGohACABQQRqIQEgC0F/aiILDQALCwsL';\n\n},{}],23:[function(_dereq_,module,exports){\n// Detect WebAssembly support.\n// - Check global WebAssembly object\n// - Try to load simple module (can be disabled via CSP)\n//\n'use strict';\n\n\nvar wa;\n\n\nmodule.exports = function hasWebAssembly() {\n // use cache if called before;\n if (typeof wa !== 'undefined') return wa;\n\n wa = false;\n\n if (typeof WebAssembly === 'undefined') return wa;\n\n // If WebAssenbly is disabled, code can throw on compile\n try {\n // https://github.com/brion/min-wasm-fail/blob/master/min-wasm-fail.in.js\n // Additional check that WA internals are correct\n\n /* eslint-disable comma-spacing, max-len */\n var bin = new Uint8Array([ 0,97,115,109,1,0,0,0,1,6,1,96,1,127,1,127,3,2,1,0,5,3,1,0,1,7,8,1,4,116,101,115,116,0,0,10,16,1,14,0,32,0,65,1,54,2,0,32,0,40,2,0,11 ]);\n var module = new WebAssembly.Module(bin);\n var instance = new WebAssembly.Instance(module, {});\n\n // test storing to and loading from a non-zero location via a parameter.\n // Safari on iOS 11.2.5 returns 0 unexpectedly at non-zero locations\n if (instance.exports.test(4) !== 0) wa = true;\n\n return wa;\n } catch (__) {}\n\n return wa;\n};\n\n},{}],24:[function(_dereq_,module,exports){\n/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n\n},{}],25:[function(_dereq_,module,exports){\nvar bundleFn = arguments[3];\nvar sources = arguments[4];\nvar cache = arguments[5];\n\nvar stringify = JSON.stringify;\n\nmodule.exports = function (fn, options) {\n var wkey;\n var cacheKeys = Object.keys(cache);\n\n for (var i = 0, l = cacheKeys.length; i < l; i++) {\n var key = cacheKeys[i];\n var exp = cache[key].exports;\n // Using babel as a transpiler to use esmodule, the export will always\n // be an object with the default export as a property of it. To ensure\n // the existing api and babel esmodule exports are both supported we\n // check for both\n if (exp === fn || exp && exp.default === fn) {\n wkey = key;\n break;\n }\n }\n\n if (!wkey) {\n wkey = Math.floor(Math.pow(16, 8) * Math.random()).toString(16);\n var wcache = {};\n for (var i = 0, l = cacheKeys.length; i < l; i++) {\n var key = cacheKeys[i];\n wcache[key] = key;\n }\n sources[wkey] = [\n 'function(require,module,exports){' + fn + '(self); }',\n wcache\n ];\n }\n var skey = Math.floor(Math.pow(16, 8) * Math.random()).toString(16);\n\n var scache = {}; scache[wkey] = wkey;\n sources[skey] = [\n 'function(require,module,exports){' +\n // try to call default if defined to also support babel esmodule exports\n 'var f = require(' + stringify(wkey) + ');' +\n '(f.default ? f.default : f)(self);' +\n '}',\n scache\n ];\n\n var workerSources = {};\n resolveSources(skey);\n\n function resolveSources(key) {\n workerSources[key] = true;\n\n for (var depPath in sources[key][1]) {\n var depKey = sources[key][1][depPath];\n if (!workerSources[depKey]) {\n resolveSources(depKey);\n }\n }\n }\n\n var src = '(' + bundleFn + ')({'\n + Object.keys(workerSources).map(function (key) {\n return stringify(key) + ':['\n + sources[key][0]\n + ',' + stringify(sources[key][1]) + ']'\n ;\n }).join(',')\n + '},{},[' + stringify(skey) + '])'\n ;\n\n var URL = window.URL || window.webkitURL || window.mozURL || window.msURL;\n\n var blob = new Blob([src], { type: 'text/javascript' });\n if (options && options.bare) { return blob; }\n var workerUrl = URL.createObjectURL(blob);\n var worker = new Worker(workerUrl);\n worker.objectURL = workerUrl;\n return worker;\n};\n\n},{}],\"/index.js\":[function(_dereq_,module,exports){\n'use strict';\n\nfunction _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }\n\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\n\nfunction _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === \"string\") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === \"Object\" && o.constructor) n = o.constructor.name; if (n === \"Map\" || n === \"Set\") return Array.from(o); if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }\n\nfunction _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }\n\nfunction _iterableToArrayLimit(arr, i) { if (typeof Symbol === \"undefined\" || !(Symbol.iterator in Object(arr))) return; var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i[\"return\"] != null) _i[\"return\"](); } finally { if (_d) throw _e; } } return _arr; }\n\nfunction _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }\n\nvar assign = _dereq_('object-assign');\n\nvar webworkify = _dereq_('webworkify');\n\nvar MathLib = _dereq_('./lib/mathlib');\n\nvar Pool = _dereq_('./lib/pool');\n\nvar utils = _dereq_('./lib/utils');\n\nvar worker = _dereq_('./lib/worker');\n\nvar createStages = _dereq_('./lib/stepper');\n\nvar createRegions = _dereq_('./lib/tiler'); // Deduplicate pools & limiters with the same configs\n// when user creates multiple pica instances.\n\n\nvar singletones = {};\nvar NEED_SAFARI_FIX = false;\n\ntry {\n if (typeof navigator !== 'undefined' && navigator.userAgent) {\n NEED_SAFARI_FIX = navigator.userAgent.indexOf('Safari') >= 0;\n }\n} catch (e) {}\n\nvar concurrency = 1;\n\nif (typeof navigator !== 'undefined') {\n concurrency = Math.min(navigator.hardwareConcurrency || 1, 4);\n}\n\nvar DEFAULT_PICA_OPTS = {\n tile: 1024,\n concurrency: concurrency,\n features: ['js', 'wasm', 'ww'],\n idle: 2000,\n createCanvas: function createCanvas(width, height) {\n var tmpCanvas = document.createElement('canvas');\n tmpCanvas.width = width;\n tmpCanvas.height = height;\n return tmpCanvas;\n }\n};\nvar DEFAULT_RESIZE_OPTS = {\n quality: 3,\n alpha: false,\n unsharpAmount: 0,\n unsharpRadius: 0.0,\n unsharpThreshold: 0\n};\nvar CAN_NEW_IMAGE_DATA;\nvar CAN_CREATE_IMAGE_BITMAP;\n\nfunction workerFabric() {\n return {\n value: webworkify(worker),\n destroy: function destroy() {\n this.value.terminate();\n\n if (typeof window !== 'undefined') {\n var url = window.URL || window.webkitURL || window.mozURL || window.msURL;\n\n if (url && url.revokeObjectURL && this.value.objectURL) {\n url.revokeObjectURL(this.value.objectURL);\n }\n }\n }\n };\n} ////////////////////////////////////////////////////////////////////////////////\n// API methods\n\n\nfunction Pica(options) {\n if (!(this instanceof Pica)) return new Pica(options);\n this.options = assign({}, DEFAULT_PICA_OPTS, options || {});\n var limiter_key = \"lk_\".concat(this.options.concurrency); // Share limiters to avoid multiple parallel workers when user creates\n // multiple pica instances.\n\n this.__limit = singletones[limiter_key] || utils.limiter(this.options.concurrency);\n if (!singletones[limiter_key]) singletones[limiter_key] = this.__limit; // List of supported features, according to options & browser/node.js\n\n this.features = {\n js: false,\n // pure JS implementation, can be disabled for testing\n wasm: false,\n // webassembly implementation for heavy functions\n cib: false,\n // resize via createImageBitmap (only FF at this moment)\n ww: false // webworkers\n\n };\n this.__workersPool = null; // Store requested features for webworkers\n\n this.__requested_features = [];\n this.__mathlib = null;\n}\n\nPica.prototype.init = function () {\n var _this = this;\n\n if (this.__initPromise) return this.__initPromise; // Test if we can create ImageData without canvas and memory copy\n\n if (CAN_NEW_IMAGE_DATA !== false && CAN_NEW_IMAGE_DATA !== true) {\n CAN_NEW_IMAGE_DATA = false;\n\n if (typeof ImageData !== 'undefined' && typeof Uint8ClampedArray !== 'undefined') {\n try {\n /* eslint-disable no-new */\n new ImageData(new Uint8ClampedArray(400), 10, 10);\n CAN_NEW_IMAGE_DATA = true;\n } catch (__) {}\n }\n } // ImageBitmap can be effective in 2 places:\n //\n // 1. Threaded jpeg unpack (basic)\n // 2. Built-in resize (blocked due problem in chrome, see issue #89)\n //\n // For basic use we also need ImageBitmap wo support .close() method,\n // see https://developer.mozilla.org/ru/docs/Web/API/ImageBitmap\n\n\n if (CAN_CREATE_IMAGE_BITMAP !== false && CAN_CREATE_IMAGE_BITMAP !== true) {\n CAN_CREATE_IMAGE_BITMAP = false;\n\n if (typeof ImageBitmap !== 'undefined') {\n if (ImageBitmap.prototype && ImageBitmap.prototype.close) {\n CAN_CREATE_IMAGE_BITMAP = true;\n } else {\n this.debug('ImageBitmap does not support .close(), disabled');\n }\n }\n }\n\n var features = this.options.features.slice();\n\n if (features.indexOf('all') >= 0) {\n features = ['cib', 'wasm', 'js', 'ww'];\n }\n\n this.__requested_features = features;\n this.__mathlib = new MathLib(features); // Check WebWorker support if requested\n\n if (features.indexOf('ww') >= 0) {\n if (typeof window !== 'undefined' && 'Worker' in window) {\n // IE <= 11 don't allow to create webworkers from string. We should check it.\n // https://connect.microsoft.com/IE/feedback/details/801810/web-workers-from-blob-urls-in-ie-10-and-11\n try {\n var wkr = _dereq_('webworkify')(function () {});\n\n wkr.terminate();\n this.features.ww = true; // pool uniqueness depends on pool config + webworker config\n\n var wpool_key = \"wp_\".concat(JSON.stringify(this.options));\n\n if (singletones[wpool_key]) {\n this.__workersPool = singletones[wpool_key];\n } else {\n this.__workersPool = new Pool(workerFabric, this.options.idle);\n singletones[wpool_key] = this.__workersPool;\n }\n } catch (__) {}\n }\n }\n\n var initMath = this.__mathlib.init().then(function (mathlib) {\n // Copy detected features\n assign(_this.features, mathlib.features);\n });\n\n var checkCibResize;\n\n if (!CAN_CREATE_IMAGE_BITMAP) {\n checkCibResize = Promise.resolve(false);\n } else {\n checkCibResize = utils.cib_support(this.options.createCanvas).then(function (status) {\n if (_this.features.cib && features.indexOf('cib') < 0) {\n _this.debug('createImageBitmap() resize supported, but disabled by config');\n\n return;\n }\n\n if (features.indexOf('cib') >= 0) _this.features.cib = status;\n });\n } // Init math lib. That's async because can load some\n\n\n this.__initPromise = Promise.all([initMath, checkCibResize]).then(function () {\n return _this;\n });\n return this.__initPromise;\n};\n\nPica.prototype.resize = function (from, to, options) {\n var _this2 = this;\n\n this.debug('Start resize...');\n var opts = assign({}, DEFAULT_RESIZE_OPTS);\n\n if (!isNaN(options)) {\n opts = assign(opts, {\n quality: options\n });\n } else if (options) {\n opts = assign(opts, options);\n }\n\n opts.toWidth = to.width;\n opts.toHeight = to.height;\n opts.width = from.naturalWidth || from.width;\n opts.height = from.naturalHeight || from.height; // Prevent stepper from infinite loop\n\n if (to.width === 0 || to.height === 0) {\n return Promise.reject(new Error(\"Invalid output size: \".concat(to.width, \"x\").concat(to.height)));\n }\n\n if (opts.unsharpRadius > 2) opts.unsharpRadius = 2;\n var canceled = false;\n var cancelToken = null;\n\n if (opts.cancelToken) {\n // Wrap cancelToken to avoid successive resolve & set flag\n cancelToken = opts.cancelToken.then(function (data) {\n canceled = true;\n throw data;\n }, function (err) {\n canceled = true;\n throw err;\n });\n }\n\n var DEST_TILE_BORDER = 3; // Max possible filter window size\n\n var destTileBorder = Math.ceil(Math.max(DEST_TILE_BORDER, 2.5 * opts.unsharpRadius | 0));\n return this.init().then(function () {\n if (canceled) return cancelToken; // if createImageBitmap supports resize, just do it and return\n\n if (_this2.features.cib) {\n var toCtx = to.getContext('2d', {\n alpha: Boolean(opts.alpha)\n });\n\n _this2.debug('Resize via createImageBitmap()');\n\n return createImageBitmap(from, {\n resizeWidth: opts.toWidth,\n resizeHeight: opts.toHeight,\n resizeQuality: utils.cib_quality_name(opts.quality)\n }).then(function (imageBitmap) {\n if (canceled) return cancelToken; // if no unsharp - draw directly to output canvas\n\n if (!opts.unsharpAmount) {\n toCtx.drawImage(imageBitmap, 0, 0);\n imageBitmap.close();\n toCtx = null;\n\n _this2.debug('Finished!');\n\n return to;\n }\n\n _this2.debug('Unsharp result');\n\n var tmpCanvas = _this2.options.createCanvas(opts.toWidth, opts.toHeight);\n\n var tmpCtx = tmpCanvas.getContext('2d', {\n alpha: Boolean(opts.alpha)\n });\n tmpCtx.drawImage(imageBitmap, 0, 0);\n imageBitmap.close();\n var iData = tmpCtx.getImageData(0, 0, opts.toWidth, opts.toHeight);\n\n _this2.__mathlib.unsharp_mask(iData.data, opts.toWidth, opts.toHeight, opts.unsharpAmount, opts.unsharpRadius, opts.unsharpThreshold);\n\n toCtx.putImageData(iData, 0, 0); // Safari 12 workaround\n // https://github.com/nodeca/pica/issues/199\n\n tmpCanvas.width = tmpCanvas.height = 0;\n iData = tmpCtx = tmpCanvas = toCtx = null;\n\n _this2.debug('Finished!');\n\n return to;\n });\n } //\n // No easy way, let's resize manually via arrays\n //\n // Share cache between calls:\n //\n // - wasm instance\n // - wasm memory object\n //\n\n\n var cache = {}; // Call resizer in webworker or locally, depending on config\n\n var invokeResize = function invokeResize(opts) {\n return Promise.resolve().then(function () {\n if (!_this2.features.ww) return _this2.__mathlib.resizeAndUnsharp(opts, cache);\n return new Promise(function (resolve, reject) {\n var w = _this2.__workersPool.acquire();\n\n if (cancelToken) cancelToken[\"catch\"](function (err) {\n return reject(err);\n });\n\n w.value.onmessage = function (ev) {\n w.release();\n if (ev.data.err) reject(ev.data.err);else resolve(ev.data.result);\n };\n\n w.value.postMessage({\n opts: opts,\n features: _this2.__requested_features,\n preload: {\n wasm_nodule: _this2.__mathlib.__\n }\n }, [opts.src.buffer]);\n });\n });\n };\n\n var tileAndResize = function tileAndResize(from, to, opts) {\n var srcCtx;\n var srcImageBitmap;\n var isImageBitmapReused = false;\n var toCtx;\n\n var processTile = function processTile(tile) {\n return _this2.__limit(function () {\n if (canceled) return cancelToken;\n var srcImageData; // Extract tile RGBA buffer, depending on input type\n\n if (utils.isCanvas(from)) {\n _this2.debug('Get tile pixel data'); // If input is Canvas - extract region data directly\n\n\n srcImageData = srcCtx.getImageData(tile.x, tile.y, tile.width, tile.height);\n } else {\n // If input is Image or decoded to ImageBitmap,\n // draw region to temporary canvas and extract data from it\n //\n // Note! Attempt to reuse this canvas causes significant slowdown in chrome\n //\n _this2.debug('Draw tile imageBitmap/image to temporary canvas');\n\n var tmpCanvas = _this2.options.createCanvas(tile.width, tile.height);\n\n var tmpCtx = tmpCanvas.getContext('2d', {\n alpha: Boolean(opts.alpha)\n });\n tmpCtx.globalCompositeOperation = 'copy';\n tmpCtx.drawImage(srcImageBitmap || from, tile.x, tile.y, tile.width, tile.height, 0, 0, tile.width, tile.height);\n\n _this2.debug('Get tile pixel data');\n\n srcImageData = tmpCtx.getImageData(0, 0, tile.width, tile.height); // Safari 12 workaround\n // https://github.com/nodeca/pica/issues/199\n\n tmpCanvas.width = tmpCanvas.height = 0;\n tmpCtx = tmpCanvas = null;\n }\n\n var o = {\n src: srcImageData.data,\n width: tile.width,\n height: tile.height,\n toWidth: tile.toWidth,\n toHeight: tile.toHeight,\n scaleX: tile.scaleX,\n scaleY: tile.scaleY,\n offsetX: tile.offsetX,\n offsetY: tile.offsetY,\n quality: opts.quality,\n alpha: opts.alpha,\n unsharpAmount: opts.unsharpAmount,\n unsharpRadius: opts.unsharpRadius,\n unsharpThreshold: opts.unsharpThreshold\n };\n\n _this2.debug('Invoke resize math');\n\n return Promise.resolve().then(function () {\n return invokeResize(o);\n }).then(function (result) {\n if (canceled) return cancelToken;\n srcImageData = null;\n var toImageData;\n\n _this2.debug('Convert raw rgba tile result to ImageData');\n\n if (CAN_NEW_IMAGE_DATA) {\n // this branch is for modern browsers\n // If `new ImageData()` & Uint8ClampedArray suported\n toImageData = new ImageData(new Uint8ClampedArray(result), tile.toWidth, tile.toHeight);\n } else {\n // fallback for `node-canvas` and old browsers\n // (IE11 has ImageData but does not support `new ImageData()`)\n toImageData = toCtx.createImageData(tile.toWidth, tile.toHeight);\n\n if (toImageData.data.set) {\n toImageData.data.set(result);\n } else {\n // IE9 don't have `.set()`\n for (var i = toImageData.data.length - 1; i >= 0; i--) {\n toImageData.data[i] = result[i];\n }\n }\n }\n\n _this2.debug('Draw tile');\n\n if (NEED_SAFARI_FIX) {\n // Safari draws thin white stripes between tiles without this fix\n toCtx.putImageData(toImageData, tile.toX, tile.toY, tile.toInnerX - tile.toX, tile.toInnerY - tile.toY, tile.toInnerWidth + 1e-5, tile.toInnerHeight + 1e-5);\n } else {\n toCtx.putImageData(toImageData, tile.toX, tile.toY, tile.toInnerX - tile.toX, tile.toInnerY - tile.toY, tile.toInnerWidth, tile.toInnerHeight);\n }\n\n return null;\n });\n });\n }; // Need to normalize data source first. It can be canvas or image.\n // If image - try to decode in background if possible\n\n\n return Promise.resolve().then(function () {\n toCtx = to.getContext('2d', {\n alpha: Boolean(opts.alpha)\n });\n\n if (utils.isCanvas(from)) {\n srcCtx = from.getContext('2d', {\n alpha: Boolean(opts.alpha)\n });\n return null;\n }\n\n if (utils.isImageBitmap(from)) {\n srcImageBitmap = from;\n isImageBitmapReused = true;\n return null;\n }\n\n if (utils.isImage(from)) {\n // try do decode image in background for faster next operations\n if (!CAN_CREATE_IMAGE_BITMAP) return null;\n\n _this2.debug('Decode image via createImageBitmap');\n\n return createImageBitmap(from).then(function (imageBitmap) {\n srcImageBitmap = imageBitmap;\n }) // Suppress error to use fallback, if method fails\n // https://github.com/nodeca/pica/issues/190\n\n /* eslint-disable no-unused-vars */\n [\"catch\"](function (e) {\n return null;\n });\n }\n\n throw new Error('Pica: \".from\" should be Image, Canvas or ImageBitmap');\n }).then(function () {\n if (canceled) return cancelToken;\n\n _this2.debug('Calculate tiles'); //\n // Here we are with \"normalized\" source,\n // follow to tiling\n //\n\n\n var regions = createRegions({\n width: opts.width,\n height: opts.height,\n srcTileSize: _this2.options.tile,\n toWidth: opts.toWidth,\n toHeight: opts.toHeight,\n destTileBorder: destTileBorder\n });\n var jobs = regions.map(function (tile) {\n return processTile(tile);\n });\n\n function cleanup() {\n if (srcImageBitmap) {\n if (!isImageBitmapReused) srcImageBitmap.close();\n srcImageBitmap = null;\n }\n }\n\n _this2.debug('Process tiles');\n\n return Promise.all(jobs).then(function () {\n _this2.debug('Finished!');\n\n cleanup();\n return to;\n }, function (err) {\n cleanup();\n throw err;\n });\n });\n };\n\n var processStages = function processStages(stages, from, to, opts) {\n if (canceled) return cancelToken;\n\n var _stages$shift = stages.shift(),\n _stages$shift2 = _slicedToArray(_stages$shift, 2),\n toWidth = _stages$shift2[0],\n toHeight = _stages$shift2[1];\n\n var isLastStage = stages.length === 0;\n opts = assign({}, opts, {\n toWidth: toWidth,\n toHeight: toHeight,\n // only use user-defined quality for the last stage,\n // use simpler (Hamming) filter for the first stages where\n // scale factor is large enough (more than 2-3)\n quality: isLastStage ? opts.quality : Math.min(1, opts.quality)\n });\n var tmpCanvas;\n\n if (!isLastStage) {\n // create temporary canvas\n tmpCanvas = _this2.options.createCanvas(toWidth, toHeight);\n }\n\n return tileAndResize(from, isLastStage ? to : tmpCanvas, opts).then(function () {\n if (isLastStage) return to;\n opts.width = toWidth;\n opts.height = toHeight;\n return processStages(stages, tmpCanvas, to, opts);\n }).then(function (res) {\n if (tmpCanvas) {\n // Safari 12 workaround\n // https://github.com/nodeca/pica/issues/199\n tmpCanvas.width = tmpCanvas.height = 0;\n }\n\n return res;\n });\n };\n\n var stages = createStages(opts.width, opts.height, opts.toWidth, opts.toHeight, _this2.options.tile, destTileBorder);\n return processStages(stages, from, to, opts);\n });\n}; // RGBA buffer resize\n//\n\n\nPica.prototype.resizeBuffer = function (options) {\n var _this3 = this;\n\n var opts = assign({}, DEFAULT_RESIZE_OPTS, options);\n return this.init().then(function () {\n return _this3.__mathlib.resizeAndUnsharp(opts);\n });\n};\n\nPica.prototype.toBlob = function (canvas, mimeType, quality) {\n mimeType = mimeType || 'image/png';\n return new Promise(function (resolve) {\n if (canvas.toBlob) {\n canvas.toBlob(function (blob) {\n return resolve(blob);\n }, mimeType, quality);\n return;\n }\n\n if (canvas.convertToBlob) {\n resolve(canvas.convertToBlob({\n type: mimeType,\n quality: quality\n }));\n return;\n } // Fallback for old browsers\n\n\n var asString = atob(canvas.toDataURL(mimeType, quality).split(',')[1]);\n var len = asString.length;\n var asBuffer = new Uint8Array(len);\n\n for (var i = 0; i < len; i++) {\n asBuffer[i] = asString.charCodeAt(i);\n }\n\n resolve(new Blob([asBuffer], {\n type: mimeType\n }));\n });\n};\n\nPica.prototype.debug = function () {};\n\nmodule.exports = Pica;\n\n},{\"./lib/mathlib\":1,\"./lib/pool\":9,\"./lib/stepper\":10,\"./lib/tiler\":11,\"./lib/utils\":12,\"./lib/worker\":13,\"object-assign\":24,\"webworkify\":25}]},{},[])(\"/index.js\")\n});\n","/*!\n * Cropper.js v1.5.9\n * https://fengyuanchen.github.io/cropperjs\n *\n * Copyright 2015-present Chen Fengyuan\n * Released under the MIT license\n *\n * Date: 2020-09-10T13:16:26.743Z\n */\n\n(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :\n typeof define === 'function' && define.amd ? define(factory) :\n (global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.Cropper = factory());\n}(this, (function () { 'use strict';\n\n function _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") {\n _typeof = function (obj) {\n return typeof obj;\n };\n } else {\n _typeof = function (obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n };\n }\n\n return _typeof(obj);\n }\n\n function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n }\n\n function _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n }\n\n function _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n return Constructor;\n }\n\n function _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n }\n\n function ownKeys(object, enumerableOnly) {\n var keys = Object.keys(object);\n\n if (Object.getOwnPropertySymbols) {\n var symbols = Object.getOwnPropertySymbols(object);\n if (enumerableOnly) symbols = symbols.filter(function (sym) {\n return Object.getOwnPropertyDescriptor(object, sym).enumerable;\n });\n keys.push.apply(keys, symbols);\n }\n\n return keys;\n }\n\n function _objectSpread2(target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i] != null ? arguments[i] : {};\n\n if (i % 2) {\n ownKeys(Object(source), true).forEach(function (key) {\n _defineProperty(target, key, source[key]);\n });\n } else if (Object.getOwnPropertyDescriptors) {\n Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));\n } else {\n ownKeys(Object(source)).forEach(function (key) {\n Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));\n });\n }\n }\n\n return target;\n }\n\n function _toConsumableArray(arr) {\n return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();\n }\n\n function _arrayWithoutHoles(arr) {\n if (Array.isArray(arr)) return _arrayLikeToArray(arr);\n }\n\n function _iterableToArray(iter) {\n if (typeof Symbol !== \"undefined\" && Symbol.iterator in Object(iter)) return Array.from(iter);\n }\n\n function _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return _arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);\n }\n\n function _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n\n for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];\n\n return arr2;\n }\n\n function _nonIterableSpread() {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n }\n\n var IS_BROWSER = typeof window !== 'undefined' && typeof window.document !== 'undefined';\n var WINDOW = IS_BROWSER ? window : {};\n var IS_TOUCH_DEVICE = IS_BROWSER && WINDOW.document.documentElement ? 'ontouchstart' in WINDOW.document.documentElement : false;\n var HAS_POINTER_EVENT = IS_BROWSER ? 'PointerEvent' in WINDOW : false;\n var NAMESPACE = 'cropper'; // Actions\n\n var ACTION_ALL = 'all';\n var ACTION_CROP = 'crop';\n var ACTION_MOVE = 'move';\n var ACTION_ZOOM = 'zoom';\n var ACTION_EAST = 'e';\n var ACTION_WEST = 'w';\n var ACTION_SOUTH = 's';\n var ACTION_NORTH = 'n';\n var ACTION_NORTH_EAST = 'ne';\n var ACTION_NORTH_WEST = 'nw';\n var ACTION_SOUTH_EAST = 'se';\n var ACTION_SOUTH_WEST = 'sw'; // Classes\n\n var CLASS_CROP = \"\".concat(NAMESPACE, \"-crop\");\n var CLASS_DISABLED = \"\".concat(NAMESPACE, \"-disabled\");\n var CLASS_HIDDEN = \"\".concat(NAMESPACE, \"-hidden\");\n var CLASS_HIDE = \"\".concat(NAMESPACE, \"-hide\");\n var CLASS_INVISIBLE = \"\".concat(NAMESPACE, \"-invisible\");\n var CLASS_MODAL = \"\".concat(NAMESPACE, \"-modal\");\n var CLASS_MOVE = \"\".concat(NAMESPACE, \"-move\"); // Data keys\n\n var DATA_ACTION = \"\".concat(NAMESPACE, \"Action\");\n var DATA_PREVIEW = \"\".concat(NAMESPACE, \"Preview\"); // Drag modes\n\n var DRAG_MODE_CROP = 'crop';\n var DRAG_MODE_MOVE = 'move';\n var DRAG_MODE_NONE = 'none'; // Events\n\n var EVENT_CROP = 'crop';\n var EVENT_CROP_END = 'cropend';\n var EVENT_CROP_MOVE = 'cropmove';\n var EVENT_CROP_START = 'cropstart';\n var EVENT_DBLCLICK = 'dblclick';\n var EVENT_TOUCH_START = IS_TOUCH_DEVICE ? 'touchstart' : 'mousedown';\n var EVENT_TOUCH_MOVE = IS_TOUCH_DEVICE ? 'touchmove' : 'mousemove';\n var EVENT_TOUCH_END = IS_TOUCH_DEVICE ? 'touchend touchcancel' : 'mouseup';\n var EVENT_POINTER_DOWN = HAS_POINTER_EVENT ? 'pointerdown' : EVENT_TOUCH_START;\n var EVENT_POINTER_MOVE = HAS_POINTER_EVENT ? 'pointermove' : EVENT_TOUCH_MOVE;\n var EVENT_POINTER_UP = HAS_POINTER_EVENT ? 'pointerup pointercancel' : EVENT_TOUCH_END;\n var EVENT_READY = 'ready';\n var EVENT_RESIZE = 'resize';\n var EVENT_WHEEL = 'wheel';\n var EVENT_ZOOM = 'zoom'; // Mime types\n\n var MIME_TYPE_JPEG = 'image/jpeg'; // RegExps\n\n var REGEXP_ACTIONS = /^e|w|s|n|se|sw|ne|nw|all|crop|move|zoom$/;\n var REGEXP_DATA_URL = /^data:/;\n var REGEXP_DATA_URL_JPEG = /^data:image\\/jpeg;base64,/;\n var REGEXP_TAG_NAME = /^img|canvas$/i; // Misc\n // Inspired by the default width and height of a canvas element.\n\n var MIN_CONTAINER_WIDTH = 200;\n var MIN_CONTAINER_HEIGHT = 100;\n\n var DEFAULTS = {\n // Define the view mode of the cropper\n viewMode: 0,\n // 0, 1, 2, 3\n // Define the dragging mode of the cropper\n dragMode: DRAG_MODE_CROP,\n // 'crop', 'move' or 'none'\n // Define the initial aspect ratio of the crop box\n initialAspectRatio: NaN,\n // Define the aspect ratio of the crop box\n aspectRatio: NaN,\n // An object with the previous cropping result data\n data: null,\n // A selector for adding extra containers to preview\n preview: '',\n // Re-render the cropper when resize the window\n responsive: true,\n // Restore the cropped area after resize the window\n restore: true,\n // Check if the current image is a cross-origin image\n checkCrossOrigin: true,\n // Check the current image's Exif Orientation information\n checkOrientation: true,\n // Show the black modal\n modal: true,\n // Show the dashed lines for guiding\n guides: true,\n // Show the center indicator for guiding\n center: true,\n // Show the white modal to highlight the crop box\n highlight: true,\n // Show the grid background\n background: true,\n // Enable to crop the image automatically when initialize\n autoCrop: true,\n // Define the percentage of automatic cropping area when initializes\n autoCropArea: 0.8,\n // Enable to move the image\n movable: true,\n // Enable to rotate the image\n rotatable: true,\n // Enable to scale the image\n scalable: true,\n // Enable to zoom the image\n zoomable: true,\n // Enable to zoom the image by dragging touch\n zoomOnTouch: true,\n // Enable to zoom the image by wheeling mouse\n zoomOnWheel: true,\n // Define zoom ratio when zoom the image by wheeling mouse\n wheelZoomRatio: 0.1,\n // Enable to move the crop box\n cropBoxMovable: true,\n // Enable to resize the crop box\n cropBoxResizable: true,\n // Toggle drag mode between \"crop\" and \"move\" when click twice on the cropper\n toggleDragModeOnDblclick: true,\n // Size limitation\n minCanvasWidth: 0,\n minCanvasHeight: 0,\n minCropBoxWidth: 0,\n minCropBoxHeight: 0,\n minContainerWidth: MIN_CONTAINER_WIDTH,\n minContainerHeight: MIN_CONTAINER_HEIGHT,\n // Shortcuts of events\n ready: null,\n cropstart: null,\n cropmove: null,\n cropend: null,\n crop: null,\n zoom: null\n };\n\n var TEMPLATE = '
' + '
' + '
' + '
' + '
' + '
' + '' + '' + '' + '' + '' + '' + '' + '' + '' + '' + '' + '' + '' + '' + '' + '' + '' + '
' + '
';\n\n /**\n * Check if the given value is not a number.\n */\n\n var isNaN = Number.isNaN || WINDOW.isNaN;\n /**\n * Check if the given value is a number.\n * @param {*} value - The value to check.\n * @returns {boolean} Returns `true` if the given value is a number, else `false`.\n */\n\n function isNumber(value) {\n return typeof value === 'number' && !isNaN(value);\n }\n /**\n * Check if the given value is a positive number.\n * @param {*} value - The value to check.\n * @returns {boolean} Returns `true` if the given value is a positive number, else `false`.\n */\n\n var isPositiveNumber = function isPositiveNumber(value) {\n return value > 0 && value < Infinity;\n };\n /**\n * Check if the given value is undefined.\n * @param {*} value - The value to check.\n * @returns {boolean} Returns `true` if the given value is undefined, else `false`.\n */\n\n function isUndefined(value) {\n return typeof value === 'undefined';\n }\n /**\n * Check if the given value is an object.\n * @param {*} value - The value to check.\n * @returns {boolean} Returns `true` if the given value is an object, else `false`.\n */\n\n function isObject(value) {\n return _typeof(value) === 'object' && value !== null;\n }\n var hasOwnProperty = Object.prototype.hasOwnProperty;\n /**\n * Check if the given value is a plain object.\n * @param {*} value - The value to check.\n * @returns {boolean} Returns `true` if the given value is a plain object, else `false`.\n */\n\n function isPlainObject(value) {\n if (!isObject(value)) {\n return false;\n }\n\n try {\n var _constructor = value.constructor;\n var prototype = _constructor.prototype;\n return _constructor && prototype && hasOwnProperty.call(prototype, 'isPrototypeOf');\n } catch (error) {\n return false;\n }\n }\n /**\n * Check if the given value is a function.\n * @param {*} value - The value to check.\n * @returns {boolean} Returns `true` if the given value is a function, else `false`.\n */\n\n function isFunction(value) {\n return typeof value === 'function';\n }\n var slice = Array.prototype.slice;\n /**\n * Convert array-like or iterable object to an array.\n * @param {*} value - The value to convert.\n * @returns {Array} Returns a new array.\n */\n\n function toArray(value) {\n return Array.from ? Array.from(value) : slice.call(value);\n }\n /**\n * Iterate the given data.\n * @param {*} data - The data to iterate.\n * @param {Function} callback - The process function for each element.\n * @returns {*} The original data.\n */\n\n function forEach(data, callback) {\n if (data && isFunction(callback)) {\n if (Array.isArray(data) || isNumber(data.length)\n /* array-like */\n ) {\n toArray(data).forEach(function (value, key) {\n callback.call(data, value, key, data);\n });\n } else if (isObject(data)) {\n Object.keys(data).forEach(function (key) {\n callback.call(data, data[key], key, data);\n });\n }\n }\n\n return data;\n }\n /**\n * Extend the given object.\n * @param {*} target - The target object to extend.\n * @param {*} args - The rest objects for merging to the target object.\n * @returns {Object} The extended object.\n */\n\n var assign = Object.assign || function assign(target) {\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n if (isObject(target) && args.length > 0) {\n args.forEach(function (arg) {\n if (isObject(arg)) {\n Object.keys(arg).forEach(function (key) {\n target[key] = arg[key];\n });\n }\n });\n }\n\n return target;\n };\n var REGEXP_DECIMALS = /\\.\\d*(?:0|9){12}\\d*$/;\n /**\n * Normalize decimal number.\n * Check out {@link https://0.30000000000000004.com/}\n * @param {number} value - The value to normalize.\n * @param {number} [times=100000000000] - The times for normalizing.\n * @returns {number} Returns the normalized number.\n */\n\n function normalizeDecimalNumber(value) {\n var times = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 100000000000;\n return REGEXP_DECIMALS.test(value) ? Math.round(value * times) / times : value;\n }\n var REGEXP_SUFFIX = /^width|height|left|top|marginLeft|marginTop$/;\n /**\n * Apply styles to the given element.\n * @param {Element} element - The target element.\n * @param {Object} styles - The styles for applying.\n */\n\n function setStyle(element, styles) {\n var style = element.style;\n forEach(styles, function (value, property) {\n if (REGEXP_SUFFIX.test(property) && isNumber(value)) {\n value = \"\".concat(value, \"px\");\n }\n\n style[property] = value;\n });\n }\n /**\n * Check if the given element has a special class.\n * @param {Element} element - The element to check.\n * @param {string} value - The class to search.\n * @returns {boolean} Returns `true` if the special class was found.\n */\n\n function hasClass(element, value) {\n return element.classList ? element.classList.contains(value) : element.className.indexOf(value) > -1;\n }\n /**\n * Add classes to the given element.\n * @param {Element} element - The target element.\n * @param {string} value - The classes to be added.\n */\n\n function addClass(element, value) {\n if (!value) {\n return;\n }\n\n if (isNumber(element.length)) {\n forEach(element, function (elem) {\n addClass(elem, value);\n });\n return;\n }\n\n if (element.classList) {\n element.classList.add(value);\n return;\n }\n\n var className = element.className.trim();\n\n if (!className) {\n element.className = value;\n } else if (className.indexOf(value) < 0) {\n element.className = \"\".concat(className, \" \").concat(value);\n }\n }\n /**\n * Remove classes from the given element.\n * @param {Element} element - The target element.\n * @param {string} value - The classes to be removed.\n */\n\n function removeClass(element, value) {\n if (!value) {\n return;\n }\n\n if (isNumber(element.length)) {\n forEach(element, function (elem) {\n removeClass(elem, value);\n });\n return;\n }\n\n if (element.classList) {\n element.classList.remove(value);\n return;\n }\n\n if (element.className.indexOf(value) >= 0) {\n element.className = element.className.replace(value, '');\n }\n }\n /**\n * Add or remove classes from the given element.\n * @param {Element} element - The target element.\n * @param {string} value - The classes to be toggled.\n * @param {boolean} added - Add only.\n */\n\n function toggleClass(element, value, added) {\n if (!value) {\n return;\n }\n\n if (isNumber(element.length)) {\n forEach(element, function (elem) {\n toggleClass(elem, value, added);\n });\n return;\n } // IE10-11 doesn't support the second parameter of `classList.toggle`\n\n\n if (added) {\n addClass(element, value);\n } else {\n removeClass(element, value);\n }\n }\n var REGEXP_CAMEL_CASE = /([a-z\\d])([A-Z])/g;\n /**\n * Transform the given string from camelCase to kebab-case\n * @param {string} value - The value to transform.\n * @returns {string} The transformed value.\n */\n\n function toParamCase(value) {\n return value.replace(REGEXP_CAMEL_CASE, '$1-$2').toLowerCase();\n }\n /**\n * Get data from the given element.\n * @param {Element} element - The target element.\n * @param {string} name - The data key to get.\n * @returns {string} The data value.\n */\n\n function getData(element, name) {\n if (isObject(element[name])) {\n return element[name];\n }\n\n if (element.dataset) {\n return element.dataset[name];\n }\n\n return element.getAttribute(\"data-\".concat(toParamCase(name)));\n }\n /**\n * Set data to the given element.\n * @param {Element} element - The target element.\n * @param {string} name - The data key to set.\n * @param {string} data - The data value.\n */\n\n function setData(element, name, data) {\n if (isObject(data)) {\n element[name] = data;\n } else if (element.dataset) {\n element.dataset[name] = data;\n } else {\n element.setAttribute(\"data-\".concat(toParamCase(name)), data);\n }\n }\n /**\n * Remove data from the given element.\n * @param {Element} element - The target element.\n * @param {string} name - The data key to remove.\n */\n\n function removeData(element, name) {\n if (isObject(element[name])) {\n try {\n delete element[name];\n } catch (error) {\n element[name] = undefined;\n }\n } else if (element.dataset) {\n // #128 Safari not allows to delete dataset property\n try {\n delete element.dataset[name];\n } catch (error) {\n element.dataset[name] = undefined;\n }\n } else {\n element.removeAttribute(\"data-\".concat(toParamCase(name)));\n }\n }\n var REGEXP_SPACES = /\\s\\s*/;\n\n var onceSupported = function () {\n var supported = false;\n\n if (IS_BROWSER) {\n var once = false;\n\n var listener = function listener() {};\n\n var options = Object.defineProperty({}, 'once', {\n get: function get() {\n supported = true;\n return once;\n },\n\n /**\n * This setter can fix a `TypeError` in strict mode\n * {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Errors/Getter_only}\n * @param {boolean} value - The value to set\n */\n set: function set(value) {\n once = value;\n }\n });\n WINDOW.addEventListener('test', listener, options);\n WINDOW.removeEventListener('test', listener, options);\n }\n\n return supported;\n }();\n /**\n * Remove event listener from the target element.\n * @param {Element} element - The event target.\n * @param {string} type - The event type(s).\n * @param {Function} listener - The event listener.\n * @param {Object} options - The event options.\n */\n\n\n function removeListener(element, type, listener) {\n var options = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};\n var handler = listener;\n type.trim().split(REGEXP_SPACES).forEach(function (event) {\n if (!onceSupported) {\n var listeners = element.listeners;\n\n if (listeners && listeners[event] && listeners[event][listener]) {\n handler = listeners[event][listener];\n delete listeners[event][listener];\n\n if (Object.keys(listeners[event]).length === 0) {\n delete listeners[event];\n }\n\n if (Object.keys(listeners).length === 0) {\n delete element.listeners;\n }\n }\n }\n\n element.removeEventListener(event, handler, options);\n });\n }\n /**\n * Add event listener to the target element.\n * @param {Element} element - The event target.\n * @param {string} type - The event type(s).\n * @param {Function} listener - The event listener.\n * @param {Object} options - The event options.\n */\n\n function addListener(element, type, listener) {\n var options = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};\n var _handler = listener;\n type.trim().split(REGEXP_SPACES).forEach(function (event) {\n if (options.once && !onceSupported) {\n var _element$listeners = element.listeners,\n listeners = _element$listeners === void 0 ? {} : _element$listeners;\n\n _handler = function handler() {\n delete listeners[event][listener];\n element.removeEventListener(event, _handler, options);\n\n for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {\n args[_key2] = arguments[_key2];\n }\n\n listener.apply(element, args);\n };\n\n if (!listeners[event]) {\n listeners[event] = {};\n }\n\n if (listeners[event][listener]) {\n element.removeEventListener(event, listeners[event][listener], options);\n }\n\n listeners[event][listener] = _handler;\n element.listeners = listeners;\n }\n\n element.addEventListener(event, _handler, options);\n });\n }\n /**\n * Dispatch event on the target element.\n * @param {Element} element - The event target.\n * @param {string} type - The event type(s).\n * @param {Object} data - The additional event data.\n * @returns {boolean} Indicate if the event is default prevented or not.\n */\n\n function dispatchEvent(element, type, data) {\n var event; // Event and CustomEvent on IE9-11 are global objects, not constructors\n\n if (isFunction(Event) && isFunction(CustomEvent)) {\n event = new CustomEvent(type, {\n detail: data,\n bubbles: true,\n cancelable: true\n });\n } else {\n event = document.createEvent('CustomEvent');\n event.initCustomEvent(type, true, true, data);\n }\n\n return element.dispatchEvent(event);\n }\n /**\n * Get the offset base on the document.\n * @param {Element} element - The target element.\n * @returns {Object} The offset data.\n */\n\n function getOffset(element) {\n var box = element.getBoundingClientRect();\n return {\n left: box.left + (window.pageXOffset - document.documentElement.clientLeft),\n top: box.top + (window.pageYOffset - document.documentElement.clientTop)\n };\n }\n var location = WINDOW.location;\n var REGEXP_ORIGINS = /^(\\w+:)\\/\\/([^:/?#]*):?(\\d*)/i;\n /**\n * Check if the given URL is a cross origin URL.\n * @param {string} url - The target URL.\n * @returns {boolean} Returns `true` if the given URL is a cross origin URL, else `false`.\n */\n\n function isCrossOriginURL(url) {\n var parts = url.match(REGEXP_ORIGINS);\n return parts !== null && (parts[1] !== location.protocol || parts[2] !== location.hostname || parts[3] !== location.port);\n }\n /**\n * Add timestamp to the given URL.\n * @param {string} url - The target URL.\n * @returns {string} The result URL.\n */\n\n function addTimestamp(url) {\n var timestamp = \"timestamp=\".concat(new Date().getTime());\n return url + (url.indexOf('?') === -1 ? '?' : '&') + timestamp;\n }\n /**\n * Get transforms base on the given object.\n * @param {Object} obj - The target object.\n * @returns {string} A string contains transform values.\n */\n\n function getTransforms(_ref) {\n var rotate = _ref.rotate,\n scaleX = _ref.scaleX,\n scaleY = _ref.scaleY,\n translateX = _ref.translateX,\n translateY = _ref.translateY;\n var values = [];\n\n if (isNumber(translateX) && translateX !== 0) {\n values.push(\"translateX(\".concat(translateX, \"px)\"));\n }\n\n if (isNumber(translateY) && translateY !== 0) {\n values.push(\"translateY(\".concat(translateY, \"px)\"));\n } // Rotate should come first before scale to match orientation transform\n\n\n if (isNumber(rotate) && rotate !== 0) {\n values.push(\"rotate(\".concat(rotate, \"deg)\"));\n }\n\n if (isNumber(scaleX) && scaleX !== 1) {\n values.push(\"scaleX(\".concat(scaleX, \")\"));\n }\n\n if (isNumber(scaleY) && scaleY !== 1) {\n values.push(\"scaleY(\".concat(scaleY, \")\"));\n }\n\n var transform = values.length ? values.join(' ') : 'none';\n return {\n WebkitTransform: transform,\n msTransform: transform,\n transform: transform\n };\n }\n /**\n * Get the max ratio of a group of pointers.\n * @param {string} pointers - The target pointers.\n * @returns {number} The result ratio.\n */\n\n function getMaxZoomRatio(pointers) {\n var pointers2 = _objectSpread2({}, pointers);\n\n var maxRatio = 0;\n forEach(pointers, function (pointer, pointerId) {\n delete pointers2[pointerId];\n forEach(pointers2, function (pointer2) {\n var x1 = Math.abs(pointer.startX - pointer2.startX);\n var y1 = Math.abs(pointer.startY - pointer2.startY);\n var x2 = Math.abs(pointer.endX - pointer2.endX);\n var y2 = Math.abs(pointer.endY - pointer2.endY);\n var z1 = Math.sqrt(x1 * x1 + y1 * y1);\n var z2 = Math.sqrt(x2 * x2 + y2 * y2);\n var ratio = (z2 - z1) / z1;\n\n if (Math.abs(ratio) > Math.abs(maxRatio)) {\n maxRatio = ratio;\n }\n });\n });\n return maxRatio;\n }\n /**\n * Get a pointer from an event object.\n * @param {Object} event - The target event object.\n * @param {boolean} endOnly - Indicates if only returns the end point coordinate or not.\n * @returns {Object} The result pointer contains start and/or end point coordinates.\n */\n\n function getPointer(_ref2, endOnly) {\n var pageX = _ref2.pageX,\n pageY = _ref2.pageY;\n var end = {\n endX: pageX,\n endY: pageY\n };\n return endOnly ? end : _objectSpread2({\n startX: pageX,\n startY: pageY\n }, end);\n }\n /**\n * Get the center point coordinate of a group of pointers.\n * @param {Object} pointers - The target pointers.\n * @returns {Object} The center point coordinate.\n */\n\n function getPointersCenter(pointers) {\n var pageX = 0;\n var pageY = 0;\n var count = 0;\n forEach(pointers, function (_ref3) {\n var startX = _ref3.startX,\n startY = _ref3.startY;\n pageX += startX;\n pageY += startY;\n count += 1;\n });\n pageX /= count;\n pageY /= count;\n return {\n pageX: pageX,\n pageY: pageY\n };\n }\n /**\n * Get the max sizes in a rectangle under the given aspect ratio.\n * @param {Object} data - The original sizes.\n * @param {string} [type='contain'] - The adjust type.\n * @returns {Object} The result sizes.\n */\n\n function getAdjustedSizes(_ref4) // or 'cover'\n {\n var aspectRatio = _ref4.aspectRatio,\n height = _ref4.height,\n width = _ref4.width;\n var type = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'contain';\n var isValidWidth = isPositiveNumber(width);\n var isValidHeight = isPositiveNumber(height);\n\n if (isValidWidth && isValidHeight) {\n var adjustedWidth = height * aspectRatio;\n\n if (type === 'contain' && adjustedWidth > width || type === 'cover' && adjustedWidth < width) {\n height = width / aspectRatio;\n } else {\n width = height * aspectRatio;\n }\n } else if (isValidWidth) {\n height = width / aspectRatio;\n } else if (isValidHeight) {\n width = height * aspectRatio;\n }\n\n return {\n width: width,\n height: height\n };\n }\n /**\n * Get the new sizes of a rectangle after rotated.\n * @param {Object} data - The original sizes.\n * @returns {Object} The result sizes.\n */\n\n function getRotatedSizes(_ref5) {\n var width = _ref5.width,\n height = _ref5.height,\n degree = _ref5.degree;\n degree = Math.abs(degree) % 180;\n\n if (degree === 90) {\n return {\n width: height,\n height: width\n };\n }\n\n var arc = degree % 90 * Math.PI / 180;\n var sinArc = Math.sin(arc);\n var cosArc = Math.cos(arc);\n var newWidth = width * cosArc + height * sinArc;\n var newHeight = width * sinArc + height * cosArc;\n return degree > 90 ? {\n width: newHeight,\n height: newWidth\n } : {\n width: newWidth,\n height: newHeight\n };\n }\n /**\n * Get a canvas which drew the given image.\n * @param {HTMLImageElement} image - The image for drawing.\n * @param {Object} imageData - The image data.\n * @param {Object} canvasData - The canvas data.\n * @param {Object} options - The options.\n * @returns {HTMLCanvasElement} The result canvas.\n */\n\n function getSourceCanvas(image, _ref6, _ref7, _ref8) {\n var imageAspectRatio = _ref6.aspectRatio,\n imageNaturalWidth = _ref6.naturalWidth,\n imageNaturalHeight = _ref6.naturalHeight,\n _ref6$rotate = _ref6.rotate,\n rotate = _ref6$rotate === void 0 ? 0 : _ref6$rotate,\n _ref6$scaleX = _ref6.scaleX,\n scaleX = _ref6$scaleX === void 0 ? 1 : _ref6$scaleX,\n _ref6$scaleY = _ref6.scaleY,\n scaleY = _ref6$scaleY === void 0 ? 1 : _ref6$scaleY;\n var aspectRatio = _ref7.aspectRatio,\n naturalWidth = _ref7.naturalWidth,\n naturalHeight = _ref7.naturalHeight;\n var _ref8$fillColor = _ref8.fillColor,\n fillColor = _ref8$fillColor === void 0 ? 'transparent' : _ref8$fillColor,\n _ref8$imageSmoothingE = _ref8.imageSmoothingEnabled,\n imageSmoothingEnabled = _ref8$imageSmoothingE === void 0 ? true : _ref8$imageSmoothingE,\n _ref8$imageSmoothingQ = _ref8.imageSmoothingQuality,\n imageSmoothingQuality = _ref8$imageSmoothingQ === void 0 ? 'low' : _ref8$imageSmoothingQ,\n _ref8$maxWidth = _ref8.maxWidth,\n maxWidth = _ref8$maxWidth === void 0 ? Infinity : _ref8$maxWidth,\n _ref8$maxHeight = _ref8.maxHeight,\n maxHeight = _ref8$maxHeight === void 0 ? Infinity : _ref8$maxHeight,\n _ref8$minWidth = _ref8.minWidth,\n minWidth = _ref8$minWidth === void 0 ? 0 : _ref8$minWidth,\n _ref8$minHeight = _ref8.minHeight,\n minHeight = _ref8$minHeight === void 0 ? 0 : _ref8$minHeight;\n var canvas = document.createElement('canvas');\n var context = canvas.getContext('2d');\n var maxSizes = getAdjustedSizes({\n aspectRatio: aspectRatio,\n width: maxWidth,\n height: maxHeight\n });\n var minSizes = getAdjustedSizes({\n aspectRatio: aspectRatio,\n width: minWidth,\n height: minHeight\n }, 'cover');\n var width = Math.min(maxSizes.width, Math.max(minSizes.width, naturalWidth));\n var height = Math.min(maxSizes.height, Math.max(minSizes.height, naturalHeight)); // Note: should always use image's natural sizes for drawing as\n // imageData.naturalWidth === canvasData.naturalHeight when rotate % 180 === 90\n\n var destMaxSizes = getAdjustedSizes({\n aspectRatio: imageAspectRatio,\n width: maxWidth,\n height: maxHeight\n });\n var destMinSizes = getAdjustedSizes({\n aspectRatio: imageAspectRatio,\n width: minWidth,\n height: minHeight\n }, 'cover');\n var destWidth = Math.min(destMaxSizes.width, Math.max(destMinSizes.width, imageNaturalWidth));\n var destHeight = Math.min(destMaxSizes.height, Math.max(destMinSizes.height, imageNaturalHeight));\n var params = [-destWidth / 2, -destHeight / 2, destWidth, destHeight];\n canvas.width = normalizeDecimalNumber(width);\n canvas.height = normalizeDecimalNumber(height);\n context.fillStyle = fillColor;\n context.fillRect(0, 0, width, height);\n context.save();\n context.translate(width / 2, height / 2);\n context.rotate(rotate * Math.PI / 180);\n context.scale(scaleX, scaleY);\n context.imageSmoothingEnabled = imageSmoothingEnabled;\n context.imageSmoothingQuality = imageSmoothingQuality;\n context.drawImage.apply(context, [image].concat(_toConsumableArray(params.map(function (param) {\n return Math.floor(normalizeDecimalNumber(param));\n }))));\n context.restore();\n return canvas;\n }\n var fromCharCode = String.fromCharCode;\n /**\n * Get string from char code in data view.\n * @param {DataView} dataView - The data view for read.\n * @param {number} start - The start index.\n * @param {number} length - The read length.\n * @returns {string} The read result.\n */\n\n function getStringFromCharCode(dataView, start, length) {\n var str = '';\n length += start;\n\n for (var i = start; i < length; i += 1) {\n str += fromCharCode(dataView.getUint8(i));\n }\n\n return str;\n }\n var REGEXP_DATA_URL_HEAD = /^data:.*,/;\n /**\n * Transform Data URL to array buffer.\n * @param {string} dataURL - The Data URL to transform.\n * @returns {ArrayBuffer} The result array buffer.\n */\n\n function dataURLToArrayBuffer(dataURL) {\n var base64 = dataURL.replace(REGEXP_DATA_URL_HEAD, '');\n var binary = atob(base64);\n var arrayBuffer = new ArrayBuffer(binary.length);\n var uint8 = new Uint8Array(arrayBuffer);\n forEach(uint8, function (value, i) {\n uint8[i] = binary.charCodeAt(i);\n });\n return arrayBuffer;\n }\n /**\n * Transform array buffer to Data URL.\n * @param {ArrayBuffer} arrayBuffer - The array buffer to transform.\n * @param {string} mimeType - The mime type of the Data URL.\n * @returns {string} The result Data URL.\n */\n\n function arrayBufferToDataURL(arrayBuffer, mimeType) {\n var chunks = []; // Chunk Typed Array for better performance (#435)\n\n var chunkSize = 8192;\n var uint8 = new Uint8Array(arrayBuffer);\n\n while (uint8.length > 0) {\n // XXX: Babel's `toConsumableArray` helper will throw error in IE or Safari 9\n // eslint-disable-next-line prefer-spread\n chunks.push(fromCharCode.apply(null, toArray(uint8.subarray(0, chunkSize))));\n uint8 = uint8.subarray(chunkSize);\n }\n\n return \"data:\".concat(mimeType, \";base64,\").concat(btoa(chunks.join('')));\n }\n /**\n * Get orientation value from given array buffer.\n * @param {ArrayBuffer} arrayBuffer - The array buffer to read.\n * @returns {number} The read orientation value.\n */\n\n function resetAndGetOrientation(arrayBuffer) {\n var dataView = new DataView(arrayBuffer);\n var orientation; // Ignores range error when the image does not have correct Exif information\n\n try {\n var littleEndian;\n var app1Start;\n var ifdStart; // Only handle JPEG image (start by 0xFFD8)\n\n if (dataView.getUint8(0) === 0xFF && dataView.getUint8(1) === 0xD8) {\n var length = dataView.byteLength;\n var offset = 2;\n\n while (offset + 1 < length) {\n if (dataView.getUint8(offset) === 0xFF && dataView.getUint8(offset + 1) === 0xE1) {\n app1Start = offset;\n break;\n }\n\n offset += 1;\n }\n }\n\n if (app1Start) {\n var exifIDCode = app1Start + 4;\n var tiffOffset = app1Start + 10;\n\n if (getStringFromCharCode(dataView, exifIDCode, 4) === 'Exif') {\n var endianness = dataView.getUint16(tiffOffset);\n littleEndian = endianness === 0x4949;\n\n if (littleEndian || endianness === 0x4D4D\n /* bigEndian */\n ) {\n if (dataView.getUint16(tiffOffset + 2, littleEndian) === 0x002A) {\n var firstIFDOffset = dataView.getUint32(tiffOffset + 4, littleEndian);\n\n if (firstIFDOffset >= 0x00000008) {\n ifdStart = tiffOffset + firstIFDOffset;\n }\n }\n }\n }\n }\n\n if (ifdStart) {\n var _length = dataView.getUint16(ifdStart, littleEndian);\n\n var _offset;\n\n var i;\n\n for (i = 0; i < _length; i += 1) {\n _offset = ifdStart + i * 12 + 2;\n\n if (dataView.getUint16(_offset, littleEndian) === 0x0112\n /* Orientation */\n ) {\n // 8 is the offset of the current tag's value\n _offset += 8; // Get the original orientation value\n\n orientation = dataView.getUint16(_offset, littleEndian); // Override the orientation with its default value\n\n dataView.setUint16(_offset, 1, littleEndian);\n break;\n }\n }\n }\n } catch (error) {\n orientation = 1;\n }\n\n return orientation;\n }\n /**\n * Parse Exif Orientation value.\n * @param {number} orientation - The orientation to parse.\n * @returns {Object} The parsed result.\n */\n\n function parseOrientation(orientation) {\n var rotate = 0;\n var scaleX = 1;\n var scaleY = 1;\n\n switch (orientation) {\n // Flip horizontal\n case 2:\n scaleX = -1;\n break;\n // Rotate left 180°\n\n case 3:\n rotate = -180;\n break;\n // Flip vertical\n\n case 4:\n scaleY = -1;\n break;\n // Flip vertical and rotate right 90°\n\n case 5:\n rotate = 90;\n scaleY = -1;\n break;\n // Rotate right 90°\n\n case 6:\n rotate = 90;\n break;\n // Flip horizontal and rotate right 90°\n\n case 7:\n rotate = 90;\n scaleX = -1;\n break;\n // Rotate left 90°\n\n case 8:\n rotate = -90;\n break;\n }\n\n return {\n rotate: rotate,\n scaleX: scaleX,\n scaleY: scaleY\n };\n }\n\n var render = {\n render: function render() {\n this.initContainer();\n this.initCanvas();\n this.initCropBox();\n this.renderCanvas();\n\n if (this.cropped) {\n this.renderCropBox();\n }\n },\n initContainer: function initContainer() {\n var element = this.element,\n options = this.options,\n container = this.container,\n cropper = this.cropper;\n var minWidth = Number(options.minContainerWidth);\n var minHeight = Number(options.minContainerHeight);\n addClass(cropper, CLASS_HIDDEN);\n removeClass(element, CLASS_HIDDEN);\n var containerData = {\n width: Math.max(container.offsetWidth, minWidth >= 0 ? minWidth : MIN_CONTAINER_WIDTH),\n height: Math.max(container.offsetHeight, minHeight >= 0 ? minHeight : MIN_CONTAINER_HEIGHT)\n };\n this.containerData = containerData;\n setStyle(cropper, {\n width: containerData.width,\n height: containerData.height\n });\n addClass(element, CLASS_HIDDEN);\n removeClass(cropper, CLASS_HIDDEN);\n },\n // Canvas (image wrapper)\n initCanvas: function initCanvas() {\n var containerData = this.containerData,\n imageData = this.imageData;\n var viewMode = this.options.viewMode;\n var rotated = Math.abs(imageData.rotate) % 180 === 90;\n var naturalWidth = rotated ? imageData.naturalHeight : imageData.naturalWidth;\n var naturalHeight = rotated ? imageData.naturalWidth : imageData.naturalHeight;\n var aspectRatio = naturalWidth / naturalHeight;\n var canvasWidth = containerData.width;\n var canvasHeight = containerData.height;\n\n if (containerData.height * aspectRatio > containerData.width) {\n if (viewMode === 3) {\n canvasWidth = containerData.height * aspectRatio;\n } else {\n canvasHeight = containerData.width / aspectRatio;\n }\n } else if (viewMode === 3) {\n canvasHeight = containerData.width / aspectRatio;\n } else {\n canvasWidth = containerData.height * aspectRatio;\n }\n\n var canvasData = {\n aspectRatio: aspectRatio,\n naturalWidth: naturalWidth,\n naturalHeight: naturalHeight,\n width: canvasWidth,\n height: canvasHeight\n };\n this.canvasData = canvasData;\n this.limited = viewMode === 1 || viewMode === 2;\n this.limitCanvas(true, true);\n canvasData.width = Math.min(Math.max(canvasData.width, canvasData.minWidth), canvasData.maxWidth);\n canvasData.height = Math.min(Math.max(canvasData.height, canvasData.minHeight), canvasData.maxHeight);\n canvasData.left = (containerData.width - canvasData.width) / 2;\n canvasData.top = (containerData.height - canvasData.height) / 2;\n canvasData.oldLeft = canvasData.left;\n canvasData.oldTop = canvasData.top;\n this.initialCanvasData = assign({}, canvasData);\n },\n limitCanvas: function limitCanvas(sizeLimited, positionLimited) {\n var options = this.options,\n containerData = this.containerData,\n canvasData = this.canvasData,\n cropBoxData = this.cropBoxData;\n var viewMode = options.viewMode;\n var aspectRatio = canvasData.aspectRatio;\n var cropped = this.cropped && cropBoxData;\n\n if (sizeLimited) {\n var minCanvasWidth = Number(options.minCanvasWidth) || 0;\n var minCanvasHeight = Number(options.minCanvasHeight) || 0;\n\n if (viewMode > 1) {\n minCanvasWidth = Math.max(minCanvasWidth, containerData.width);\n minCanvasHeight = Math.max(minCanvasHeight, containerData.height);\n\n if (viewMode === 3) {\n if (minCanvasHeight * aspectRatio > minCanvasWidth) {\n minCanvasWidth = minCanvasHeight * aspectRatio;\n } else {\n minCanvasHeight = minCanvasWidth / aspectRatio;\n }\n }\n } else if (viewMode > 0) {\n if (minCanvasWidth) {\n minCanvasWidth = Math.max(minCanvasWidth, cropped ? cropBoxData.width : 0);\n } else if (minCanvasHeight) {\n minCanvasHeight = Math.max(minCanvasHeight, cropped ? cropBoxData.height : 0);\n } else if (cropped) {\n minCanvasWidth = cropBoxData.width;\n minCanvasHeight = cropBoxData.height;\n\n if (minCanvasHeight * aspectRatio > minCanvasWidth) {\n minCanvasWidth = minCanvasHeight * aspectRatio;\n } else {\n minCanvasHeight = minCanvasWidth / aspectRatio;\n }\n }\n }\n\n var _getAdjustedSizes = getAdjustedSizes({\n aspectRatio: aspectRatio,\n width: minCanvasWidth,\n height: minCanvasHeight\n });\n\n minCanvasWidth = _getAdjustedSizes.width;\n minCanvasHeight = _getAdjustedSizes.height;\n canvasData.minWidth = minCanvasWidth;\n canvasData.minHeight = minCanvasHeight;\n canvasData.maxWidth = Infinity;\n canvasData.maxHeight = Infinity;\n }\n\n if (positionLimited) {\n if (viewMode > (cropped ? 0 : 1)) {\n var newCanvasLeft = containerData.width - canvasData.width;\n var newCanvasTop = containerData.height - canvasData.height;\n canvasData.minLeft = Math.min(0, newCanvasLeft);\n canvasData.minTop = Math.min(0, newCanvasTop);\n canvasData.maxLeft = Math.max(0, newCanvasLeft);\n canvasData.maxTop = Math.max(0, newCanvasTop);\n\n if (cropped && this.limited) {\n canvasData.minLeft = Math.min(cropBoxData.left, cropBoxData.left + (cropBoxData.width - canvasData.width));\n canvasData.minTop = Math.min(cropBoxData.top, cropBoxData.top + (cropBoxData.height - canvasData.height));\n canvasData.maxLeft = cropBoxData.left;\n canvasData.maxTop = cropBoxData.top;\n\n if (viewMode === 2) {\n if (canvasData.width >= containerData.width) {\n canvasData.minLeft = Math.min(0, newCanvasLeft);\n canvasData.maxLeft = Math.max(0, newCanvasLeft);\n }\n\n if (canvasData.height >= containerData.height) {\n canvasData.minTop = Math.min(0, newCanvasTop);\n canvasData.maxTop = Math.max(0, newCanvasTop);\n }\n }\n }\n } else {\n canvasData.minLeft = -canvasData.width;\n canvasData.minTop = -canvasData.height;\n canvasData.maxLeft = containerData.width;\n canvasData.maxTop = containerData.height;\n }\n }\n },\n renderCanvas: function renderCanvas(changed, transformed) {\n var canvasData = this.canvasData,\n imageData = this.imageData;\n\n if (transformed) {\n var _getRotatedSizes = getRotatedSizes({\n width: imageData.naturalWidth * Math.abs(imageData.scaleX || 1),\n height: imageData.naturalHeight * Math.abs(imageData.scaleY || 1),\n degree: imageData.rotate || 0\n }),\n naturalWidth = _getRotatedSizes.width,\n naturalHeight = _getRotatedSizes.height;\n\n var width = canvasData.width * (naturalWidth / canvasData.naturalWidth);\n var height = canvasData.height * (naturalHeight / canvasData.naturalHeight);\n canvasData.left -= (width - canvasData.width) / 2;\n canvasData.top -= (height - canvasData.height) / 2;\n canvasData.width = width;\n canvasData.height = height;\n canvasData.aspectRatio = naturalWidth / naturalHeight;\n canvasData.naturalWidth = naturalWidth;\n canvasData.naturalHeight = naturalHeight;\n this.limitCanvas(true, false);\n }\n\n if (canvasData.width > canvasData.maxWidth || canvasData.width < canvasData.minWidth) {\n canvasData.left = canvasData.oldLeft;\n }\n\n if (canvasData.height > canvasData.maxHeight || canvasData.height < canvasData.minHeight) {\n canvasData.top = canvasData.oldTop;\n }\n\n canvasData.width = Math.min(Math.max(canvasData.width, canvasData.minWidth), canvasData.maxWidth);\n canvasData.height = Math.min(Math.max(canvasData.height, canvasData.minHeight), canvasData.maxHeight);\n this.limitCanvas(false, true);\n canvasData.left = Math.min(Math.max(canvasData.left, canvasData.minLeft), canvasData.maxLeft);\n canvasData.top = Math.min(Math.max(canvasData.top, canvasData.minTop), canvasData.maxTop);\n canvasData.oldLeft = canvasData.left;\n canvasData.oldTop = canvasData.top;\n setStyle(this.canvas, assign({\n width: canvasData.width,\n height: canvasData.height\n }, getTransforms({\n translateX: canvasData.left,\n translateY: canvasData.top\n })));\n this.renderImage(changed);\n\n if (this.cropped && this.limited) {\n this.limitCropBox(true, true);\n }\n },\n renderImage: function renderImage(changed) {\n var canvasData = this.canvasData,\n imageData = this.imageData;\n var width = imageData.naturalWidth * (canvasData.width / canvasData.naturalWidth);\n var height = imageData.naturalHeight * (canvasData.height / canvasData.naturalHeight);\n assign(imageData, {\n width: width,\n height: height,\n left: (canvasData.width - width) / 2,\n top: (canvasData.height - height) / 2\n });\n setStyle(this.image, assign({\n width: imageData.width,\n height: imageData.height\n }, getTransforms(assign({\n translateX: imageData.left,\n translateY: imageData.top\n }, imageData))));\n\n if (changed) {\n this.output();\n }\n },\n initCropBox: function initCropBox() {\n var options = this.options,\n canvasData = this.canvasData;\n var aspectRatio = options.aspectRatio || options.initialAspectRatio;\n var autoCropArea = Number(options.autoCropArea) || 0.8;\n var cropBoxData = {\n width: canvasData.width,\n height: canvasData.height\n };\n\n if (aspectRatio) {\n if (canvasData.height * aspectRatio > canvasData.width) {\n cropBoxData.height = cropBoxData.width / aspectRatio;\n } else {\n cropBoxData.width = cropBoxData.height * aspectRatio;\n }\n }\n\n this.cropBoxData = cropBoxData;\n this.limitCropBox(true, true); // Initialize auto crop area\n\n cropBoxData.width = Math.min(Math.max(cropBoxData.width, cropBoxData.minWidth), cropBoxData.maxWidth);\n cropBoxData.height = Math.min(Math.max(cropBoxData.height, cropBoxData.minHeight), cropBoxData.maxHeight); // The width/height of auto crop area must large than \"minWidth/Height\"\n\n cropBoxData.width = Math.max(cropBoxData.minWidth, cropBoxData.width * autoCropArea);\n cropBoxData.height = Math.max(cropBoxData.minHeight, cropBoxData.height * autoCropArea);\n cropBoxData.left = canvasData.left + (canvasData.width - cropBoxData.width) / 2;\n cropBoxData.top = canvasData.top + (canvasData.height - cropBoxData.height) / 2;\n cropBoxData.oldLeft = cropBoxData.left;\n cropBoxData.oldTop = cropBoxData.top;\n this.initialCropBoxData = assign({}, cropBoxData);\n },\n limitCropBox: function limitCropBox(sizeLimited, positionLimited) {\n var options = this.options,\n containerData = this.containerData,\n canvasData = this.canvasData,\n cropBoxData = this.cropBoxData,\n limited = this.limited;\n var aspectRatio = options.aspectRatio;\n\n if (sizeLimited) {\n var minCropBoxWidth = Number(options.minCropBoxWidth) || 0;\n var minCropBoxHeight = Number(options.minCropBoxHeight) || 0;\n var maxCropBoxWidth = limited ? Math.min(containerData.width, canvasData.width, canvasData.width + canvasData.left, containerData.width - canvasData.left) : containerData.width;\n var maxCropBoxHeight = limited ? Math.min(containerData.height, canvasData.height, canvasData.height + canvasData.top, containerData.height - canvasData.top) : containerData.height; // The min/maxCropBoxWidth/Height must be less than container's width/height\n\n minCropBoxWidth = Math.min(minCropBoxWidth, containerData.width);\n minCropBoxHeight = Math.min(minCropBoxHeight, containerData.height);\n\n if (aspectRatio) {\n if (minCropBoxWidth && minCropBoxHeight) {\n if (minCropBoxHeight * aspectRatio > minCropBoxWidth) {\n minCropBoxHeight = minCropBoxWidth / aspectRatio;\n } else {\n minCropBoxWidth = minCropBoxHeight * aspectRatio;\n }\n } else if (minCropBoxWidth) {\n minCropBoxHeight = minCropBoxWidth / aspectRatio;\n } else if (minCropBoxHeight) {\n minCropBoxWidth = minCropBoxHeight * aspectRatio;\n }\n\n if (maxCropBoxHeight * aspectRatio > maxCropBoxWidth) {\n maxCropBoxHeight = maxCropBoxWidth / aspectRatio;\n } else {\n maxCropBoxWidth = maxCropBoxHeight * aspectRatio;\n }\n } // The minWidth/Height must be less than maxWidth/Height\n\n\n cropBoxData.minWidth = Math.min(minCropBoxWidth, maxCropBoxWidth);\n cropBoxData.minHeight = Math.min(minCropBoxHeight, maxCropBoxHeight);\n cropBoxData.maxWidth = maxCropBoxWidth;\n cropBoxData.maxHeight = maxCropBoxHeight;\n }\n\n if (positionLimited) {\n if (limited) {\n cropBoxData.minLeft = Math.max(0, canvasData.left);\n cropBoxData.minTop = Math.max(0, canvasData.top);\n cropBoxData.maxLeft = Math.min(containerData.width, canvasData.left + canvasData.width) - cropBoxData.width;\n cropBoxData.maxTop = Math.min(containerData.height, canvasData.top + canvasData.height) - cropBoxData.height;\n } else {\n cropBoxData.minLeft = 0;\n cropBoxData.minTop = 0;\n cropBoxData.maxLeft = containerData.width - cropBoxData.width;\n cropBoxData.maxTop = containerData.height - cropBoxData.height;\n }\n }\n },\n renderCropBox: function renderCropBox() {\n var options = this.options,\n containerData = this.containerData,\n cropBoxData = this.cropBoxData;\n\n if (cropBoxData.width > cropBoxData.maxWidth || cropBoxData.width < cropBoxData.minWidth) {\n cropBoxData.left = cropBoxData.oldLeft;\n }\n\n if (cropBoxData.height > cropBoxData.maxHeight || cropBoxData.height < cropBoxData.minHeight) {\n cropBoxData.top = cropBoxData.oldTop;\n }\n\n cropBoxData.width = Math.min(Math.max(cropBoxData.width, cropBoxData.minWidth), cropBoxData.maxWidth);\n cropBoxData.height = Math.min(Math.max(cropBoxData.height, cropBoxData.minHeight), cropBoxData.maxHeight);\n this.limitCropBox(false, true);\n cropBoxData.left = Math.min(Math.max(cropBoxData.left, cropBoxData.minLeft), cropBoxData.maxLeft);\n cropBoxData.top = Math.min(Math.max(cropBoxData.top, cropBoxData.minTop), cropBoxData.maxTop);\n cropBoxData.oldLeft = cropBoxData.left;\n cropBoxData.oldTop = cropBoxData.top;\n\n if (options.movable && options.cropBoxMovable) {\n // Turn to move the canvas when the crop box is equal to the container\n setData(this.face, DATA_ACTION, cropBoxData.width >= containerData.width && cropBoxData.height >= containerData.height ? ACTION_MOVE : ACTION_ALL);\n }\n\n setStyle(this.cropBox, assign({\n width: cropBoxData.width,\n height: cropBoxData.height\n }, getTransforms({\n translateX: cropBoxData.left,\n translateY: cropBoxData.top\n })));\n\n if (this.cropped && this.limited) {\n this.limitCanvas(true, true);\n }\n\n if (!this.disabled) {\n this.output();\n }\n },\n output: function output() {\n this.preview();\n dispatchEvent(this.element, EVENT_CROP, this.getData());\n }\n };\n\n var preview = {\n initPreview: function initPreview() {\n var element = this.element,\n crossOrigin = this.crossOrigin;\n var preview = this.options.preview;\n var url = crossOrigin ? this.crossOriginUrl : this.url;\n var alt = element.alt || 'The image to preview';\n var image = document.createElement('img');\n\n if (crossOrigin) {\n image.crossOrigin = crossOrigin;\n }\n\n image.src = url;\n image.alt = alt;\n this.viewBox.appendChild(image);\n this.viewBoxImage = image;\n\n if (!preview) {\n return;\n }\n\n var previews = preview;\n\n if (typeof preview === 'string') {\n previews = element.ownerDocument.querySelectorAll(preview);\n } else if (preview.querySelector) {\n previews = [preview];\n }\n\n this.previews = previews;\n forEach(previews, function (el) {\n var img = document.createElement('img'); // Save the original size for recover\n\n setData(el, DATA_PREVIEW, {\n width: el.offsetWidth,\n height: el.offsetHeight,\n html: el.innerHTML\n });\n\n if (crossOrigin) {\n img.crossOrigin = crossOrigin;\n }\n\n img.src = url;\n img.alt = alt;\n /**\n * Override img element styles\n * Add `display:block` to avoid margin top issue\n * Add `height:auto` to override `height` attribute on IE8\n * (Occur only when margin-top <= -height)\n */\n\n img.style.cssText = 'display:block;' + 'width:100%;' + 'height:auto;' + 'min-width:0!important;' + 'min-height:0!important;' + 'max-width:none!important;' + 'max-height:none!important;' + 'image-orientation:0deg!important;\"';\n el.innerHTML = '';\n el.appendChild(img);\n });\n },\n resetPreview: function resetPreview() {\n forEach(this.previews, function (element) {\n var data = getData(element, DATA_PREVIEW);\n setStyle(element, {\n width: data.width,\n height: data.height\n });\n element.innerHTML = data.html;\n removeData(element, DATA_PREVIEW);\n });\n },\n preview: function preview() {\n var imageData = this.imageData,\n canvasData = this.canvasData,\n cropBoxData = this.cropBoxData;\n var cropBoxWidth = cropBoxData.width,\n cropBoxHeight = cropBoxData.height;\n var width = imageData.width,\n height = imageData.height;\n var left = cropBoxData.left - canvasData.left - imageData.left;\n var top = cropBoxData.top - canvasData.top - imageData.top;\n\n if (!this.cropped || this.disabled) {\n return;\n }\n\n setStyle(this.viewBoxImage, assign({\n width: width,\n height: height\n }, getTransforms(assign({\n translateX: -left,\n translateY: -top\n }, imageData))));\n forEach(this.previews, function (element) {\n var data = getData(element, DATA_PREVIEW);\n var originalWidth = data.width;\n var originalHeight = data.height;\n var newWidth = originalWidth;\n var newHeight = originalHeight;\n var ratio = 1;\n\n if (cropBoxWidth) {\n ratio = originalWidth / cropBoxWidth;\n newHeight = cropBoxHeight * ratio;\n }\n\n if (cropBoxHeight && newHeight > originalHeight) {\n ratio = originalHeight / cropBoxHeight;\n newWidth = cropBoxWidth * ratio;\n newHeight = originalHeight;\n }\n\n setStyle(element, {\n width: newWidth,\n height: newHeight\n });\n setStyle(element.getElementsByTagName('img')[0], assign({\n width: width * ratio,\n height: height * ratio\n }, getTransforms(assign({\n translateX: -left * ratio,\n translateY: -top * ratio\n }, imageData))));\n });\n }\n };\n\n var events = {\n bind: function bind() {\n var element = this.element,\n options = this.options,\n cropper = this.cropper;\n\n if (isFunction(options.cropstart)) {\n addListener(element, EVENT_CROP_START, options.cropstart);\n }\n\n if (isFunction(options.cropmove)) {\n addListener(element, EVENT_CROP_MOVE, options.cropmove);\n }\n\n if (isFunction(options.cropend)) {\n addListener(element, EVENT_CROP_END, options.cropend);\n }\n\n if (isFunction(options.crop)) {\n addListener(element, EVENT_CROP, options.crop);\n }\n\n if (isFunction(options.zoom)) {\n addListener(element, EVENT_ZOOM, options.zoom);\n }\n\n addListener(cropper, EVENT_POINTER_DOWN, this.onCropStart = this.cropStart.bind(this));\n\n if (options.zoomable && options.zoomOnWheel) {\n addListener(cropper, EVENT_WHEEL, this.onWheel = this.wheel.bind(this), {\n passive: false,\n capture: true\n });\n }\n\n if (options.toggleDragModeOnDblclick) {\n addListener(cropper, EVENT_DBLCLICK, this.onDblclick = this.dblclick.bind(this));\n }\n\n addListener(element.ownerDocument, EVENT_POINTER_MOVE, this.onCropMove = this.cropMove.bind(this));\n addListener(element.ownerDocument, EVENT_POINTER_UP, this.onCropEnd = this.cropEnd.bind(this));\n\n if (options.responsive) {\n addListener(window, EVENT_RESIZE, this.onResize = this.resize.bind(this));\n }\n },\n unbind: function unbind() {\n var element = this.element,\n options = this.options,\n cropper = this.cropper;\n\n if (isFunction(options.cropstart)) {\n removeListener(element, EVENT_CROP_START, options.cropstart);\n }\n\n if (isFunction(options.cropmove)) {\n removeListener(element, EVENT_CROP_MOVE, options.cropmove);\n }\n\n if (isFunction(options.cropend)) {\n removeListener(element, EVENT_CROP_END, options.cropend);\n }\n\n if (isFunction(options.crop)) {\n removeListener(element, EVENT_CROP, options.crop);\n }\n\n if (isFunction(options.zoom)) {\n removeListener(element, EVENT_ZOOM, options.zoom);\n }\n\n removeListener(cropper, EVENT_POINTER_DOWN, this.onCropStart);\n\n if (options.zoomable && options.zoomOnWheel) {\n removeListener(cropper, EVENT_WHEEL, this.onWheel, {\n passive: false,\n capture: true\n });\n }\n\n if (options.toggleDragModeOnDblclick) {\n removeListener(cropper, EVENT_DBLCLICK, this.onDblclick);\n }\n\n removeListener(element.ownerDocument, EVENT_POINTER_MOVE, this.onCropMove);\n removeListener(element.ownerDocument, EVENT_POINTER_UP, this.onCropEnd);\n\n if (options.responsive) {\n removeListener(window, EVENT_RESIZE, this.onResize);\n }\n }\n };\n\n var handlers = {\n resize: function resize() {\n if (this.disabled) {\n return;\n }\n\n var options = this.options,\n container = this.container,\n containerData = this.containerData;\n var ratio = container.offsetWidth / containerData.width; // Resize when width changed or height changed\n\n if (ratio !== 1 || container.offsetHeight !== containerData.height) {\n var canvasData;\n var cropBoxData;\n\n if (options.restore) {\n canvasData = this.getCanvasData();\n cropBoxData = this.getCropBoxData();\n }\n\n this.render();\n\n if (options.restore) {\n this.setCanvasData(forEach(canvasData, function (n, i) {\n canvasData[i] = n * ratio;\n }));\n this.setCropBoxData(forEach(cropBoxData, function (n, i) {\n cropBoxData[i] = n * ratio;\n }));\n }\n }\n },\n dblclick: function dblclick() {\n if (this.disabled || this.options.dragMode === DRAG_MODE_NONE) {\n return;\n }\n\n this.setDragMode(hasClass(this.dragBox, CLASS_CROP) ? DRAG_MODE_MOVE : DRAG_MODE_CROP);\n },\n wheel: function wheel(event) {\n var _this = this;\n\n var ratio = Number(this.options.wheelZoomRatio) || 0.1;\n var delta = 1;\n\n if (this.disabled) {\n return;\n }\n\n event.preventDefault(); // Limit wheel speed to prevent zoom too fast (#21)\n\n if (this.wheeling) {\n return;\n }\n\n this.wheeling = true;\n setTimeout(function () {\n _this.wheeling = false;\n }, 50);\n\n if (event.deltaY) {\n delta = event.deltaY > 0 ? 1 : -1;\n } else if (event.wheelDelta) {\n delta = -event.wheelDelta / 120;\n } else if (event.detail) {\n delta = event.detail > 0 ? 1 : -1;\n }\n\n this.zoom(-delta * ratio, event);\n },\n cropStart: function cropStart(event) {\n var buttons = event.buttons,\n button = event.button;\n\n if (this.disabled // Handle mouse event and pointer event and ignore touch event\n || (event.type === 'mousedown' || event.type === 'pointerdown' && event.pointerType === 'mouse') && ( // No primary button (Usually the left button)\n isNumber(buttons) && buttons !== 1 || isNumber(button) && button !== 0 // Open context menu\n || event.ctrlKey)) {\n return;\n }\n\n var options = this.options,\n pointers = this.pointers;\n var action;\n\n if (event.changedTouches) {\n // Handle touch event\n forEach(event.changedTouches, function (touch) {\n pointers[touch.identifier] = getPointer(touch);\n });\n } else {\n // Handle mouse event and pointer event\n pointers[event.pointerId || 0] = getPointer(event);\n }\n\n if (Object.keys(pointers).length > 1 && options.zoomable && options.zoomOnTouch) {\n action = ACTION_ZOOM;\n } else {\n action = getData(event.target, DATA_ACTION);\n }\n\n if (!REGEXP_ACTIONS.test(action)) {\n return;\n }\n\n if (dispatchEvent(this.element, EVENT_CROP_START, {\n originalEvent: event,\n action: action\n }) === false) {\n return;\n } // This line is required for preventing page zooming in iOS browsers\n\n\n event.preventDefault();\n this.action = action;\n this.cropping = false;\n\n if (action === ACTION_CROP) {\n this.cropping = true;\n addClass(this.dragBox, CLASS_MODAL);\n }\n },\n cropMove: function cropMove(event) {\n var action = this.action;\n\n if (this.disabled || !action) {\n return;\n }\n\n var pointers = this.pointers;\n event.preventDefault();\n\n if (dispatchEvent(this.element, EVENT_CROP_MOVE, {\n originalEvent: event,\n action: action\n }) === false) {\n return;\n }\n\n if (event.changedTouches) {\n forEach(event.changedTouches, function (touch) {\n // The first parameter should not be undefined (#432)\n assign(pointers[touch.identifier] || {}, getPointer(touch, true));\n });\n } else {\n assign(pointers[event.pointerId || 0] || {}, getPointer(event, true));\n }\n\n this.change(event);\n },\n cropEnd: function cropEnd(event) {\n if (this.disabled) {\n return;\n }\n\n var action = this.action,\n pointers = this.pointers;\n\n if (event.changedTouches) {\n forEach(event.changedTouches, function (touch) {\n delete pointers[touch.identifier];\n });\n } else {\n delete pointers[event.pointerId || 0];\n }\n\n if (!action) {\n return;\n }\n\n event.preventDefault();\n\n if (!Object.keys(pointers).length) {\n this.action = '';\n }\n\n if (this.cropping) {\n this.cropping = false;\n toggleClass(this.dragBox, CLASS_MODAL, this.cropped && this.options.modal);\n }\n\n dispatchEvent(this.element, EVENT_CROP_END, {\n originalEvent: event,\n action: action\n });\n }\n };\n\n var change = {\n change: function change(event) {\n var options = this.options,\n canvasData = this.canvasData,\n containerData = this.containerData,\n cropBoxData = this.cropBoxData,\n pointers = this.pointers;\n var action = this.action;\n var aspectRatio = options.aspectRatio;\n var left = cropBoxData.left,\n top = cropBoxData.top,\n width = cropBoxData.width,\n height = cropBoxData.height;\n var right = left + width;\n var bottom = top + height;\n var minLeft = 0;\n var minTop = 0;\n var maxWidth = containerData.width;\n var maxHeight = containerData.height;\n var renderable = true;\n var offset; // Locking aspect ratio in \"free mode\" by holding shift key\n\n if (!aspectRatio && event.shiftKey) {\n aspectRatio = width && height ? width / height : 1;\n }\n\n if (this.limited) {\n minLeft = cropBoxData.minLeft;\n minTop = cropBoxData.minTop;\n maxWidth = minLeft + Math.min(containerData.width, canvasData.width, canvasData.left + canvasData.width);\n maxHeight = minTop + Math.min(containerData.height, canvasData.height, canvasData.top + canvasData.height);\n }\n\n var pointer = pointers[Object.keys(pointers)[0]];\n var range = {\n x: pointer.endX - pointer.startX,\n y: pointer.endY - pointer.startY\n };\n\n var check = function check(side) {\n switch (side) {\n case ACTION_EAST:\n if (right + range.x > maxWidth) {\n range.x = maxWidth - right;\n }\n\n break;\n\n case ACTION_WEST:\n if (left + range.x < minLeft) {\n range.x = minLeft - left;\n }\n\n break;\n\n case ACTION_NORTH:\n if (top + range.y < minTop) {\n range.y = minTop - top;\n }\n\n break;\n\n case ACTION_SOUTH:\n if (bottom + range.y > maxHeight) {\n range.y = maxHeight - bottom;\n }\n\n break;\n }\n };\n\n switch (action) {\n // Move crop box\n case ACTION_ALL:\n left += range.x;\n top += range.y;\n break;\n // Resize crop box\n\n case ACTION_EAST:\n if (range.x >= 0 && (right >= maxWidth || aspectRatio && (top <= minTop || bottom >= maxHeight))) {\n renderable = false;\n break;\n }\n\n check(ACTION_EAST);\n width += range.x;\n\n if (width < 0) {\n action = ACTION_WEST;\n width = -width;\n left -= width;\n }\n\n if (aspectRatio) {\n height = width / aspectRatio;\n top += (cropBoxData.height - height) / 2;\n }\n\n break;\n\n case ACTION_NORTH:\n if (range.y <= 0 && (top <= minTop || aspectRatio && (left <= minLeft || right >= maxWidth))) {\n renderable = false;\n break;\n }\n\n check(ACTION_NORTH);\n height -= range.y;\n top += range.y;\n\n if (height < 0) {\n action = ACTION_SOUTH;\n height = -height;\n top -= height;\n }\n\n if (aspectRatio) {\n width = height * aspectRatio;\n left += (cropBoxData.width - width) / 2;\n }\n\n break;\n\n case ACTION_WEST:\n if (range.x <= 0 && (left <= minLeft || aspectRatio && (top <= minTop || bottom >= maxHeight))) {\n renderable = false;\n break;\n }\n\n check(ACTION_WEST);\n width -= range.x;\n left += range.x;\n\n if (width < 0) {\n action = ACTION_EAST;\n width = -width;\n left -= width;\n }\n\n if (aspectRatio) {\n height = width / aspectRatio;\n top += (cropBoxData.height - height) / 2;\n }\n\n break;\n\n case ACTION_SOUTH:\n if (range.y >= 0 && (bottom >= maxHeight || aspectRatio && (left <= minLeft || right >= maxWidth))) {\n renderable = false;\n break;\n }\n\n check(ACTION_SOUTH);\n height += range.y;\n\n if (height < 0) {\n action = ACTION_NORTH;\n height = -height;\n top -= height;\n }\n\n if (aspectRatio) {\n width = height * aspectRatio;\n left += (cropBoxData.width - width) / 2;\n }\n\n break;\n\n case ACTION_NORTH_EAST:\n if (aspectRatio) {\n if (range.y <= 0 && (top <= minTop || right >= maxWidth)) {\n renderable = false;\n break;\n }\n\n check(ACTION_NORTH);\n height -= range.y;\n top += range.y;\n width = height * aspectRatio;\n } else {\n check(ACTION_NORTH);\n check(ACTION_EAST);\n\n if (range.x >= 0) {\n if (right < maxWidth) {\n width += range.x;\n } else if (range.y <= 0 && top <= minTop) {\n renderable = false;\n }\n } else {\n width += range.x;\n }\n\n if (range.y <= 0) {\n if (top > minTop) {\n height -= range.y;\n top += range.y;\n }\n } else {\n height -= range.y;\n top += range.y;\n }\n }\n\n if (width < 0 && height < 0) {\n action = ACTION_SOUTH_WEST;\n height = -height;\n width = -width;\n top -= height;\n left -= width;\n } else if (width < 0) {\n action = ACTION_NORTH_WEST;\n width = -width;\n left -= width;\n } else if (height < 0) {\n action = ACTION_SOUTH_EAST;\n height = -height;\n top -= height;\n }\n\n break;\n\n case ACTION_NORTH_WEST:\n if (aspectRatio) {\n if (range.y <= 0 && (top <= minTop || left <= minLeft)) {\n renderable = false;\n break;\n }\n\n check(ACTION_NORTH);\n height -= range.y;\n top += range.y;\n width = height * aspectRatio;\n left += cropBoxData.width - width;\n } else {\n check(ACTION_NORTH);\n check(ACTION_WEST);\n\n if (range.x <= 0) {\n if (left > minLeft) {\n width -= range.x;\n left += range.x;\n } else if (range.y <= 0 && top <= minTop) {\n renderable = false;\n }\n } else {\n width -= range.x;\n left += range.x;\n }\n\n if (range.y <= 0) {\n if (top > minTop) {\n height -= range.y;\n top += range.y;\n }\n } else {\n height -= range.y;\n top += range.y;\n }\n }\n\n if (width < 0 && height < 0) {\n action = ACTION_SOUTH_EAST;\n height = -height;\n width = -width;\n top -= height;\n left -= width;\n } else if (width < 0) {\n action = ACTION_NORTH_EAST;\n width = -width;\n left -= width;\n } else if (height < 0) {\n action = ACTION_SOUTH_WEST;\n height = -height;\n top -= height;\n }\n\n break;\n\n case ACTION_SOUTH_WEST:\n if (aspectRatio) {\n if (range.x <= 0 && (left <= minLeft || bottom >= maxHeight)) {\n renderable = false;\n break;\n }\n\n check(ACTION_WEST);\n width -= range.x;\n left += range.x;\n height = width / aspectRatio;\n } else {\n check(ACTION_SOUTH);\n check(ACTION_WEST);\n\n if (range.x <= 0) {\n if (left > minLeft) {\n width -= range.x;\n left += range.x;\n } else if (range.y >= 0 && bottom >= maxHeight) {\n renderable = false;\n }\n } else {\n width -= range.x;\n left += range.x;\n }\n\n if (range.y >= 0) {\n if (bottom < maxHeight) {\n height += range.y;\n }\n } else {\n height += range.y;\n }\n }\n\n if (width < 0 && height < 0) {\n action = ACTION_NORTH_EAST;\n height = -height;\n width = -width;\n top -= height;\n left -= width;\n } else if (width < 0) {\n action = ACTION_SOUTH_EAST;\n width = -width;\n left -= width;\n } else if (height < 0) {\n action = ACTION_NORTH_WEST;\n height = -height;\n top -= height;\n }\n\n break;\n\n case ACTION_SOUTH_EAST:\n if (aspectRatio) {\n if (range.x >= 0 && (right >= maxWidth || bottom >= maxHeight)) {\n renderable = false;\n break;\n }\n\n check(ACTION_EAST);\n width += range.x;\n height = width / aspectRatio;\n } else {\n check(ACTION_SOUTH);\n check(ACTION_EAST);\n\n if (range.x >= 0) {\n if (right < maxWidth) {\n width += range.x;\n } else if (range.y >= 0 && bottom >= maxHeight) {\n renderable = false;\n }\n } else {\n width += range.x;\n }\n\n if (range.y >= 0) {\n if (bottom < maxHeight) {\n height += range.y;\n }\n } else {\n height += range.y;\n }\n }\n\n if (width < 0 && height < 0) {\n action = ACTION_NORTH_WEST;\n height = -height;\n width = -width;\n top -= height;\n left -= width;\n } else if (width < 0) {\n action = ACTION_SOUTH_WEST;\n width = -width;\n left -= width;\n } else if (height < 0) {\n action = ACTION_NORTH_EAST;\n height = -height;\n top -= height;\n }\n\n break;\n // Move canvas\n\n case ACTION_MOVE:\n this.move(range.x, range.y);\n renderable = false;\n break;\n // Zoom canvas\n\n case ACTION_ZOOM:\n this.zoom(getMaxZoomRatio(pointers), event);\n renderable = false;\n break;\n // Create crop box\n\n case ACTION_CROP:\n if (!range.x || !range.y) {\n renderable = false;\n break;\n }\n\n offset = getOffset(this.cropper);\n left = pointer.startX - offset.left;\n top = pointer.startY - offset.top;\n width = cropBoxData.minWidth;\n height = cropBoxData.minHeight;\n\n if (range.x > 0) {\n action = range.y > 0 ? ACTION_SOUTH_EAST : ACTION_NORTH_EAST;\n } else if (range.x < 0) {\n left -= width;\n action = range.y > 0 ? ACTION_SOUTH_WEST : ACTION_NORTH_WEST;\n }\n\n if (range.y < 0) {\n top -= height;\n } // Show the crop box if is hidden\n\n\n if (!this.cropped) {\n removeClass(this.cropBox, CLASS_HIDDEN);\n this.cropped = true;\n\n if (this.limited) {\n this.limitCropBox(true, true);\n }\n }\n\n break;\n }\n\n if (renderable) {\n cropBoxData.width = width;\n cropBoxData.height = height;\n cropBoxData.left = left;\n cropBoxData.top = top;\n this.action = action;\n this.renderCropBox();\n } // Override\n\n\n forEach(pointers, function (p) {\n p.startX = p.endX;\n p.startY = p.endY;\n });\n }\n };\n\n var methods = {\n // Show the crop box manually\n crop: function crop() {\n if (this.ready && !this.cropped && !this.disabled) {\n this.cropped = true;\n this.limitCropBox(true, true);\n\n if (this.options.modal) {\n addClass(this.dragBox, CLASS_MODAL);\n }\n\n removeClass(this.cropBox, CLASS_HIDDEN);\n this.setCropBoxData(this.initialCropBoxData);\n }\n\n return this;\n },\n // Reset the image and crop box to their initial states\n reset: function reset() {\n if (this.ready && !this.disabled) {\n this.imageData = assign({}, this.initialImageData);\n this.canvasData = assign({}, this.initialCanvasData);\n this.cropBoxData = assign({}, this.initialCropBoxData);\n this.renderCanvas();\n\n if (this.cropped) {\n this.renderCropBox();\n }\n }\n\n return this;\n },\n // Clear the crop box\n clear: function clear() {\n if (this.cropped && !this.disabled) {\n assign(this.cropBoxData, {\n left: 0,\n top: 0,\n width: 0,\n height: 0\n });\n this.cropped = false;\n this.renderCropBox();\n this.limitCanvas(true, true); // Render canvas after crop box rendered\n\n this.renderCanvas();\n removeClass(this.dragBox, CLASS_MODAL);\n addClass(this.cropBox, CLASS_HIDDEN);\n }\n\n return this;\n },\n\n /**\n * Replace the image's src and rebuild the cropper\n * @param {string} url - The new URL.\n * @param {boolean} [hasSameSize] - Indicate if the new image has the same size as the old one.\n * @returns {Cropper} this\n */\n replace: function replace(url) {\n var hasSameSize = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n\n if (!this.disabled && url) {\n if (this.isImg) {\n this.element.src = url;\n }\n\n if (hasSameSize) {\n this.url = url;\n this.image.src = url;\n\n if (this.ready) {\n this.viewBoxImage.src = url;\n forEach(this.previews, function (element) {\n element.getElementsByTagName('img')[0].src = url;\n });\n }\n } else {\n if (this.isImg) {\n this.replaced = true;\n }\n\n this.options.data = null;\n this.uncreate();\n this.load(url);\n }\n }\n\n return this;\n },\n // Enable (unfreeze) the cropper\n enable: function enable() {\n if (this.ready && this.disabled) {\n this.disabled = false;\n removeClass(this.cropper, CLASS_DISABLED);\n }\n\n return this;\n },\n // Disable (freeze) the cropper\n disable: function disable() {\n if (this.ready && !this.disabled) {\n this.disabled = true;\n addClass(this.cropper, CLASS_DISABLED);\n }\n\n return this;\n },\n\n /**\n * Destroy the cropper and remove the instance from the image\n * @returns {Cropper} this\n */\n destroy: function destroy() {\n var element = this.element;\n\n if (!element[NAMESPACE]) {\n return this;\n }\n\n element[NAMESPACE] = undefined;\n\n if (this.isImg && this.replaced) {\n element.src = this.originalUrl;\n }\n\n this.uncreate();\n return this;\n },\n\n /**\n * Move the canvas with relative offsets\n * @param {number} offsetX - The relative offset distance on the x-axis.\n * @param {number} [offsetY=offsetX] - The relative offset distance on the y-axis.\n * @returns {Cropper} this\n */\n move: function move(offsetX) {\n var offsetY = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : offsetX;\n var _this$canvasData = this.canvasData,\n left = _this$canvasData.left,\n top = _this$canvasData.top;\n return this.moveTo(isUndefined(offsetX) ? offsetX : left + Number(offsetX), isUndefined(offsetY) ? offsetY : top + Number(offsetY));\n },\n\n /**\n * Move the canvas to an absolute point\n * @param {number} x - The x-axis coordinate.\n * @param {number} [y=x] - The y-axis coordinate.\n * @returns {Cropper} this\n */\n moveTo: function moveTo(x) {\n var y = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : x;\n var canvasData = this.canvasData;\n var changed = false;\n x = Number(x);\n y = Number(y);\n\n if (this.ready && !this.disabled && this.options.movable) {\n if (isNumber(x)) {\n canvasData.left = x;\n changed = true;\n }\n\n if (isNumber(y)) {\n canvasData.top = y;\n changed = true;\n }\n\n if (changed) {\n this.renderCanvas(true);\n }\n }\n\n return this;\n },\n\n /**\n * Zoom the canvas with a relative ratio\n * @param {number} ratio - The target ratio.\n * @param {Event} _originalEvent - The original event if any.\n * @returns {Cropper} this\n */\n zoom: function zoom(ratio, _originalEvent) {\n var canvasData = this.canvasData;\n ratio = Number(ratio);\n\n if (ratio < 0) {\n ratio = 1 / (1 - ratio);\n } else {\n ratio = 1 + ratio;\n }\n\n return this.zoomTo(canvasData.width * ratio / canvasData.naturalWidth, null, _originalEvent);\n },\n\n /**\n * Zoom the canvas to an absolute ratio\n * @param {number} ratio - The target ratio.\n * @param {Object} pivot - The zoom pivot point coordinate.\n * @param {Event} _originalEvent - The original event if any.\n * @returns {Cropper} this\n */\n zoomTo: function zoomTo(ratio, pivot, _originalEvent) {\n var options = this.options,\n canvasData = this.canvasData;\n var width = canvasData.width,\n height = canvasData.height,\n naturalWidth = canvasData.naturalWidth,\n naturalHeight = canvasData.naturalHeight;\n ratio = Number(ratio);\n\n if (ratio >= 0 && this.ready && !this.disabled && options.zoomable) {\n var newWidth = naturalWidth * ratio;\n var newHeight = naturalHeight * ratio;\n\n if (dispatchEvent(this.element, EVENT_ZOOM, {\n ratio: ratio,\n oldRatio: width / naturalWidth,\n originalEvent: _originalEvent\n }) === false) {\n return this;\n }\n\n if (_originalEvent) {\n var pointers = this.pointers;\n var offset = getOffset(this.cropper);\n var center = pointers && Object.keys(pointers).length ? getPointersCenter(pointers) : {\n pageX: _originalEvent.pageX,\n pageY: _originalEvent.pageY\n }; // Zoom from the triggering point of the event\n\n canvasData.left -= (newWidth - width) * ((center.pageX - offset.left - canvasData.left) / width);\n canvasData.top -= (newHeight - height) * ((center.pageY - offset.top - canvasData.top) / height);\n } else if (isPlainObject(pivot) && isNumber(pivot.x) && isNumber(pivot.y)) {\n canvasData.left -= (newWidth - width) * ((pivot.x - canvasData.left) / width);\n canvasData.top -= (newHeight - height) * ((pivot.y - canvasData.top) / height);\n } else {\n // Zoom from the center of the canvas\n canvasData.left -= (newWidth - width) / 2;\n canvasData.top -= (newHeight - height) / 2;\n }\n\n canvasData.width = newWidth;\n canvasData.height = newHeight;\n this.renderCanvas(true);\n }\n\n return this;\n },\n\n /**\n * Rotate the canvas with a relative degree\n * @param {number} degree - The rotate degree.\n * @returns {Cropper} this\n */\n rotate: function rotate(degree) {\n return this.rotateTo((this.imageData.rotate || 0) + Number(degree));\n },\n\n /**\n * Rotate the canvas to an absolute degree\n * @param {number} degree - The rotate degree.\n * @returns {Cropper} this\n */\n rotateTo: function rotateTo(degree) {\n degree = Number(degree);\n\n if (isNumber(degree) && this.ready && !this.disabled && this.options.rotatable) {\n this.imageData.rotate = degree % 360;\n this.renderCanvas(true, true);\n }\n\n return this;\n },\n\n /**\n * Scale the image on the x-axis.\n * @param {number} scaleX - The scale ratio on the x-axis.\n * @returns {Cropper} this\n */\n scaleX: function scaleX(_scaleX) {\n var scaleY = this.imageData.scaleY;\n return this.scale(_scaleX, isNumber(scaleY) ? scaleY : 1);\n },\n\n /**\n * Scale the image on the y-axis.\n * @param {number} scaleY - The scale ratio on the y-axis.\n * @returns {Cropper} this\n */\n scaleY: function scaleY(_scaleY) {\n var scaleX = this.imageData.scaleX;\n return this.scale(isNumber(scaleX) ? scaleX : 1, _scaleY);\n },\n\n /**\n * Scale the image\n * @param {number} scaleX - The scale ratio on the x-axis.\n * @param {number} [scaleY=scaleX] - The scale ratio on the y-axis.\n * @returns {Cropper} this\n */\n scale: function scale(scaleX) {\n var scaleY = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : scaleX;\n var imageData = this.imageData;\n var transformed = false;\n scaleX = Number(scaleX);\n scaleY = Number(scaleY);\n\n if (this.ready && !this.disabled && this.options.scalable) {\n if (isNumber(scaleX)) {\n imageData.scaleX = scaleX;\n transformed = true;\n }\n\n if (isNumber(scaleY)) {\n imageData.scaleY = scaleY;\n transformed = true;\n }\n\n if (transformed) {\n this.renderCanvas(true, true);\n }\n }\n\n return this;\n },\n\n /**\n * Get the cropped area position and size data (base on the original image)\n * @param {boolean} [rounded=false] - Indicate if round the data values or not.\n * @returns {Object} The result cropped data.\n */\n getData: function getData() {\n var rounded = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;\n var options = this.options,\n imageData = this.imageData,\n canvasData = this.canvasData,\n cropBoxData = this.cropBoxData;\n var data;\n\n if (this.ready && this.cropped) {\n data = {\n x: cropBoxData.left - canvasData.left,\n y: cropBoxData.top - canvasData.top,\n width: cropBoxData.width,\n height: cropBoxData.height\n };\n var ratio = imageData.width / imageData.naturalWidth;\n forEach(data, function (n, i) {\n data[i] = n / ratio;\n });\n\n if (rounded) {\n // In case rounding off leads to extra 1px in right or bottom border\n // we should round the top-left corner and the dimension (#343).\n var bottom = Math.round(data.y + data.height);\n var right = Math.round(data.x + data.width);\n data.x = Math.round(data.x);\n data.y = Math.round(data.y);\n data.width = right - data.x;\n data.height = bottom - data.y;\n }\n } else {\n data = {\n x: 0,\n y: 0,\n width: 0,\n height: 0\n };\n }\n\n if (options.rotatable) {\n data.rotate = imageData.rotate || 0;\n }\n\n if (options.scalable) {\n data.scaleX = imageData.scaleX || 1;\n data.scaleY = imageData.scaleY || 1;\n }\n\n return data;\n },\n\n /**\n * Set the cropped area position and size with new data\n * @param {Object} data - The new data.\n * @returns {Cropper} this\n */\n setData: function setData(data) {\n var options = this.options,\n imageData = this.imageData,\n canvasData = this.canvasData;\n var cropBoxData = {};\n\n if (this.ready && !this.disabled && isPlainObject(data)) {\n var transformed = false;\n\n if (options.rotatable) {\n if (isNumber(data.rotate) && data.rotate !== imageData.rotate) {\n imageData.rotate = data.rotate;\n transformed = true;\n }\n }\n\n if (options.scalable) {\n if (isNumber(data.scaleX) && data.scaleX !== imageData.scaleX) {\n imageData.scaleX = data.scaleX;\n transformed = true;\n }\n\n if (isNumber(data.scaleY) && data.scaleY !== imageData.scaleY) {\n imageData.scaleY = data.scaleY;\n transformed = true;\n }\n }\n\n if (transformed) {\n this.renderCanvas(true, true);\n }\n\n var ratio = imageData.width / imageData.naturalWidth;\n\n if (isNumber(data.x)) {\n cropBoxData.left = data.x * ratio + canvasData.left;\n }\n\n if (isNumber(data.y)) {\n cropBoxData.top = data.y * ratio + canvasData.top;\n }\n\n if (isNumber(data.width)) {\n cropBoxData.width = data.width * ratio;\n }\n\n if (isNumber(data.height)) {\n cropBoxData.height = data.height * ratio;\n }\n\n this.setCropBoxData(cropBoxData);\n }\n\n return this;\n },\n\n /**\n * Get the container size data.\n * @returns {Object} The result container data.\n */\n getContainerData: function getContainerData() {\n return this.ready ? assign({}, this.containerData) : {};\n },\n\n /**\n * Get the image position and size data.\n * @returns {Object} The result image data.\n */\n getImageData: function getImageData() {\n return this.sized ? assign({}, this.imageData) : {};\n },\n\n /**\n * Get the canvas position and size data.\n * @returns {Object} The result canvas data.\n */\n getCanvasData: function getCanvasData() {\n var canvasData = this.canvasData;\n var data = {};\n\n if (this.ready) {\n forEach(['left', 'top', 'width', 'height', 'naturalWidth', 'naturalHeight'], function (n) {\n data[n] = canvasData[n];\n });\n }\n\n return data;\n },\n\n /**\n * Set the canvas position and size with new data.\n * @param {Object} data - The new canvas data.\n * @returns {Cropper} this\n */\n setCanvasData: function setCanvasData(data) {\n var canvasData = this.canvasData;\n var aspectRatio = canvasData.aspectRatio;\n\n if (this.ready && !this.disabled && isPlainObject(data)) {\n if (isNumber(data.left)) {\n canvasData.left = data.left;\n }\n\n if (isNumber(data.top)) {\n canvasData.top = data.top;\n }\n\n if (isNumber(data.width)) {\n canvasData.width = data.width;\n canvasData.height = data.width / aspectRatio;\n } else if (isNumber(data.height)) {\n canvasData.height = data.height;\n canvasData.width = data.height * aspectRatio;\n }\n\n this.renderCanvas(true);\n }\n\n return this;\n },\n\n /**\n * Get the crop box position and size data.\n * @returns {Object} The result crop box data.\n */\n getCropBoxData: function getCropBoxData() {\n var cropBoxData = this.cropBoxData;\n var data;\n\n if (this.ready && this.cropped) {\n data = {\n left: cropBoxData.left,\n top: cropBoxData.top,\n width: cropBoxData.width,\n height: cropBoxData.height\n };\n }\n\n return data || {};\n },\n\n /**\n * Set the crop box position and size with new data.\n * @param {Object} data - The new crop box data.\n * @returns {Cropper} this\n */\n setCropBoxData: function setCropBoxData(data) {\n var cropBoxData = this.cropBoxData;\n var aspectRatio = this.options.aspectRatio;\n var widthChanged;\n var heightChanged;\n\n if (this.ready && this.cropped && !this.disabled && isPlainObject(data)) {\n if (isNumber(data.left)) {\n cropBoxData.left = data.left;\n }\n\n if (isNumber(data.top)) {\n cropBoxData.top = data.top;\n }\n\n if (isNumber(data.width) && data.width !== cropBoxData.width) {\n widthChanged = true;\n cropBoxData.width = data.width;\n }\n\n if (isNumber(data.height) && data.height !== cropBoxData.height) {\n heightChanged = true;\n cropBoxData.height = data.height;\n }\n\n if (aspectRatio) {\n if (widthChanged) {\n cropBoxData.height = cropBoxData.width / aspectRatio;\n } else if (heightChanged) {\n cropBoxData.width = cropBoxData.height * aspectRatio;\n }\n }\n\n this.renderCropBox();\n }\n\n return this;\n },\n\n /**\n * Get a canvas drawn the cropped image.\n * @param {Object} [options={}] - The config options.\n * @returns {HTMLCanvasElement} - The result canvas.\n */\n getCroppedCanvas: function getCroppedCanvas() {\n var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n\n if (!this.ready || !window.HTMLCanvasElement) {\n return null;\n }\n\n var canvasData = this.canvasData;\n var source = getSourceCanvas(this.image, this.imageData, canvasData, options); // Returns the source canvas if it is not cropped.\n\n if (!this.cropped) {\n return source;\n }\n\n var _this$getData = this.getData(),\n initialX = _this$getData.x,\n initialY = _this$getData.y,\n initialWidth = _this$getData.width,\n initialHeight = _this$getData.height;\n\n var ratio = source.width / Math.floor(canvasData.naturalWidth);\n\n if (ratio !== 1) {\n initialX *= ratio;\n initialY *= ratio;\n initialWidth *= ratio;\n initialHeight *= ratio;\n }\n\n var aspectRatio = initialWidth / initialHeight;\n var maxSizes = getAdjustedSizes({\n aspectRatio: aspectRatio,\n width: options.maxWidth || Infinity,\n height: options.maxHeight || Infinity\n });\n var minSizes = getAdjustedSizes({\n aspectRatio: aspectRatio,\n width: options.minWidth || 0,\n height: options.minHeight || 0\n }, 'cover');\n\n var _getAdjustedSizes = getAdjustedSizes({\n aspectRatio: aspectRatio,\n width: options.width || (ratio !== 1 ? source.width : initialWidth),\n height: options.height || (ratio !== 1 ? source.height : initialHeight)\n }),\n width = _getAdjustedSizes.width,\n height = _getAdjustedSizes.height;\n\n width = Math.min(maxSizes.width, Math.max(minSizes.width, width));\n height = Math.min(maxSizes.height, Math.max(minSizes.height, height));\n var canvas = document.createElement('canvas');\n var context = canvas.getContext('2d');\n canvas.width = normalizeDecimalNumber(width);\n canvas.height = normalizeDecimalNumber(height);\n context.fillStyle = options.fillColor || 'transparent';\n context.fillRect(0, 0, width, height);\n var _options$imageSmoothi = options.imageSmoothingEnabled,\n imageSmoothingEnabled = _options$imageSmoothi === void 0 ? true : _options$imageSmoothi,\n imageSmoothingQuality = options.imageSmoothingQuality;\n context.imageSmoothingEnabled = imageSmoothingEnabled;\n\n if (imageSmoothingQuality) {\n context.imageSmoothingQuality = imageSmoothingQuality;\n } // https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D.drawImage\n\n\n var sourceWidth = source.width;\n var sourceHeight = source.height; // Source canvas parameters\n\n var srcX = initialX;\n var srcY = initialY;\n var srcWidth;\n var srcHeight; // Destination canvas parameters\n\n var dstX;\n var dstY;\n var dstWidth;\n var dstHeight;\n\n if (srcX <= -initialWidth || srcX > sourceWidth) {\n srcX = 0;\n srcWidth = 0;\n dstX = 0;\n dstWidth = 0;\n } else if (srcX <= 0) {\n dstX = -srcX;\n srcX = 0;\n srcWidth = Math.min(sourceWidth, initialWidth + srcX);\n dstWidth = srcWidth;\n } else if (srcX <= sourceWidth) {\n dstX = 0;\n srcWidth = Math.min(initialWidth, sourceWidth - srcX);\n dstWidth = srcWidth;\n }\n\n if (srcWidth <= 0 || srcY <= -initialHeight || srcY > sourceHeight) {\n srcY = 0;\n srcHeight = 0;\n dstY = 0;\n dstHeight = 0;\n } else if (srcY <= 0) {\n dstY = -srcY;\n srcY = 0;\n srcHeight = Math.min(sourceHeight, initialHeight + srcY);\n dstHeight = srcHeight;\n } else if (srcY <= sourceHeight) {\n dstY = 0;\n srcHeight = Math.min(initialHeight, sourceHeight - srcY);\n dstHeight = srcHeight;\n }\n\n var params = [srcX, srcY, srcWidth, srcHeight]; // Avoid \"IndexSizeError\"\n\n if (dstWidth > 0 && dstHeight > 0) {\n var scale = width / initialWidth;\n params.push(dstX * scale, dstY * scale, dstWidth * scale, dstHeight * scale);\n } // All the numerical parameters should be integer for `drawImage`\n // https://github.com/fengyuanchen/cropper/issues/476\n\n\n context.drawImage.apply(context, [source].concat(_toConsumableArray(params.map(function (param) {\n return Math.floor(normalizeDecimalNumber(param));\n }))));\n return canvas;\n },\n\n /**\n * Change the aspect ratio of the crop box.\n * @param {number} aspectRatio - The new aspect ratio.\n * @returns {Cropper} this\n */\n setAspectRatio: function setAspectRatio(aspectRatio) {\n var options = this.options;\n\n if (!this.disabled && !isUndefined(aspectRatio)) {\n // 0 -> NaN\n options.aspectRatio = Math.max(0, aspectRatio) || NaN;\n\n if (this.ready) {\n this.initCropBox();\n\n if (this.cropped) {\n this.renderCropBox();\n }\n }\n }\n\n return this;\n },\n\n /**\n * Change the drag mode.\n * @param {string} mode - The new drag mode.\n * @returns {Cropper} this\n */\n setDragMode: function setDragMode(mode) {\n var options = this.options,\n dragBox = this.dragBox,\n face = this.face;\n\n if (this.ready && !this.disabled) {\n var croppable = mode === DRAG_MODE_CROP;\n var movable = options.movable && mode === DRAG_MODE_MOVE;\n mode = croppable || movable ? mode : DRAG_MODE_NONE;\n options.dragMode = mode;\n setData(dragBox, DATA_ACTION, mode);\n toggleClass(dragBox, CLASS_CROP, croppable);\n toggleClass(dragBox, CLASS_MOVE, movable);\n\n if (!options.cropBoxMovable) {\n // Sync drag mode to crop box when it is not movable\n setData(face, DATA_ACTION, mode);\n toggleClass(face, CLASS_CROP, croppable);\n toggleClass(face, CLASS_MOVE, movable);\n }\n }\n\n return this;\n }\n };\n\n var AnotherCropper = WINDOW.Cropper;\n\n var Cropper = /*#__PURE__*/function () {\n /**\n * Create a new Cropper.\n * @param {Element} element - The target element for cropping.\n * @param {Object} [options={}] - The configuration options.\n */\n function Cropper(element) {\n var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n\n _classCallCheck(this, Cropper);\n\n if (!element || !REGEXP_TAG_NAME.test(element.tagName)) {\n throw new Error('The first argument is required and must be an or element.');\n }\n\n this.element = element;\n this.options = assign({}, DEFAULTS, isPlainObject(options) && options);\n this.cropped = false;\n this.disabled = false;\n this.pointers = {};\n this.ready = false;\n this.reloading = false;\n this.replaced = false;\n this.sized = false;\n this.sizing = false;\n this.init();\n }\n\n _createClass(Cropper, [{\n key: \"init\",\n value: function init() {\n var element = this.element;\n var tagName = element.tagName.toLowerCase();\n var url;\n\n if (element[NAMESPACE]) {\n return;\n }\n\n element[NAMESPACE] = this;\n\n if (tagName === 'img') {\n this.isImg = true; // e.g.: \"img/picture.jpg\"\n\n url = element.getAttribute('src') || '';\n this.originalUrl = url; // Stop when it's a blank image\n\n if (!url) {\n return;\n } // e.g.: \"https://example.com/img/picture.jpg\"\n\n\n url = element.src;\n } else if (tagName === 'canvas' && window.HTMLCanvasElement) {\n url = element.toDataURL();\n }\n\n this.load(url);\n }\n }, {\n key: \"load\",\n value: function load(url) {\n var _this = this;\n\n if (!url) {\n return;\n }\n\n this.url = url;\n this.imageData = {};\n var element = this.element,\n options = this.options;\n\n if (!options.rotatable && !options.scalable) {\n options.checkOrientation = false;\n } // Only IE10+ supports Typed Arrays\n\n\n if (!options.checkOrientation || !window.ArrayBuffer) {\n this.clone();\n return;\n } // Detect the mime type of the image directly if it is a Data URL\n\n\n if (REGEXP_DATA_URL.test(url)) {\n // Read ArrayBuffer from Data URL of JPEG images directly for better performance\n if (REGEXP_DATA_URL_JPEG.test(url)) {\n this.read(dataURLToArrayBuffer(url));\n } else {\n // Only a JPEG image may contains Exif Orientation information,\n // the rest types of Data URLs are not necessary to check orientation at all.\n this.clone();\n }\n\n return;\n } // 1. Detect the mime type of the image by a XMLHttpRequest.\n // 2. Load the image as ArrayBuffer for reading orientation if its a JPEG image.\n\n\n var xhr = new XMLHttpRequest();\n var clone = this.clone.bind(this);\n this.reloading = true;\n this.xhr = xhr; // 1. Cross origin requests are only supported for protocol schemes:\n // http, https, data, chrome, chrome-extension.\n // 2. Access to XMLHttpRequest from a Data URL will be blocked by CORS policy\n // in some browsers as IE11 and Safari.\n\n xhr.onabort = clone;\n xhr.onerror = clone;\n xhr.ontimeout = clone;\n\n xhr.onprogress = function () {\n // Abort the request directly if it not a JPEG image for better performance\n if (xhr.getResponseHeader('content-type') !== MIME_TYPE_JPEG) {\n xhr.abort();\n }\n };\n\n xhr.onload = function () {\n _this.read(xhr.response);\n };\n\n xhr.onloadend = function () {\n _this.reloading = false;\n _this.xhr = null;\n }; // Bust cache when there is a \"crossOrigin\" property to avoid browser cache error\n\n\n if (options.checkCrossOrigin && isCrossOriginURL(url) && element.crossOrigin) {\n url = addTimestamp(url);\n }\n\n xhr.open('GET', url);\n xhr.responseType = 'arraybuffer';\n xhr.withCredentials = element.crossOrigin === 'use-credentials';\n xhr.send();\n }\n }, {\n key: \"read\",\n value: function read(arrayBuffer) {\n var options = this.options,\n imageData = this.imageData; // Reset the orientation value to its default value 1\n // as some iOS browsers will render image with its orientation\n\n var orientation = resetAndGetOrientation(arrayBuffer);\n var rotate = 0;\n var scaleX = 1;\n var scaleY = 1;\n\n if (orientation > 1) {\n // Generate a new URL which has the default orientation value\n this.url = arrayBufferToDataURL(arrayBuffer, MIME_TYPE_JPEG);\n\n var _parseOrientation = parseOrientation(orientation);\n\n rotate = _parseOrientation.rotate;\n scaleX = _parseOrientation.scaleX;\n scaleY = _parseOrientation.scaleY;\n }\n\n if (options.rotatable) {\n imageData.rotate = rotate;\n }\n\n if (options.scalable) {\n imageData.scaleX = scaleX;\n imageData.scaleY = scaleY;\n }\n\n this.clone();\n }\n }, {\n key: \"clone\",\n value: function clone() {\n var element = this.element,\n url = this.url;\n var crossOrigin = element.crossOrigin;\n var crossOriginUrl = url;\n\n if (this.options.checkCrossOrigin && isCrossOriginURL(url)) {\n if (!crossOrigin) {\n crossOrigin = 'anonymous';\n } // Bust cache when there is not a \"crossOrigin\" property (#519)\n\n\n crossOriginUrl = addTimestamp(url);\n }\n\n this.crossOrigin = crossOrigin;\n this.crossOriginUrl = crossOriginUrl;\n var image = document.createElement('img');\n\n if (crossOrigin) {\n image.crossOrigin = crossOrigin;\n }\n\n image.src = crossOriginUrl || url;\n image.alt = element.alt || 'The image to crop';\n this.image = image;\n image.onload = this.start.bind(this);\n image.onerror = this.stop.bind(this);\n addClass(image, CLASS_HIDE);\n element.parentNode.insertBefore(image, element.nextSibling);\n }\n }, {\n key: \"start\",\n value: function start() {\n var _this2 = this;\n\n var image = this.image;\n image.onload = null;\n image.onerror = null;\n this.sizing = true; // Match all browsers that use WebKit as the layout engine in iOS devices,\n // such as Safari for iOS, Chrome for iOS, and in-app browsers.\n\n var isIOSWebKit = WINDOW.navigator && /(?:iPad|iPhone|iPod).*?AppleWebKit/i.test(WINDOW.navigator.userAgent);\n\n var done = function done(naturalWidth, naturalHeight) {\n assign(_this2.imageData, {\n naturalWidth: naturalWidth,\n naturalHeight: naturalHeight,\n aspectRatio: naturalWidth / naturalHeight\n });\n _this2.initialImageData = assign({}, _this2.imageData);\n _this2.sizing = false;\n _this2.sized = true;\n\n _this2.build();\n }; // Most modern browsers (excepts iOS WebKit)\n\n\n if (image.naturalWidth && !isIOSWebKit) {\n done(image.naturalWidth, image.naturalHeight);\n return;\n }\n\n var sizingImage = document.createElement('img');\n var body = document.body || document.documentElement;\n this.sizingImage = sizingImage;\n\n sizingImage.onload = function () {\n done(sizingImage.width, sizingImage.height);\n\n if (!isIOSWebKit) {\n body.removeChild(sizingImage);\n }\n };\n\n sizingImage.src = image.src; // iOS WebKit will convert the image automatically\n // with its orientation once append it into DOM (#279)\n\n if (!isIOSWebKit) {\n sizingImage.style.cssText = 'left:0;' + 'max-height:none!important;' + 'max-width:none!important;' + 'min-height:0!important;' + 'min-width:0!important;' + 'opacity:0;' + 'position:absolute;' + 'top:0;' + 'z-index:-1;';\n body.appendChild(sizingImage);\n }\n }\n }, {\n key: \"stop\",\n value: function stop() {\n var image = this.image;\n image.onload = null;\n image.onerror = null;\n image.parentNode.removeChild(image);\n this.image = null;\n }\n }, {\n key: \"build\",\n value: function build() {\n if (!this.sized || this.ready) {\n return;\n }\n\n var element = this.element,\n options = this.options,\n image = this.image; // Create cropper elements\n\n var container = element.parentNode;\n var template = document.createElement('div');\n template.innerHTML = TEMPLATE;\n var cropper = template.querySelector(\".\".concat(NAMESPACE, \"-container\"));\n var canvas = cropper.querySelector(\".\".concat(NAMESPACE, \"-canvas\"));\n var dragBox = cropper.querySelector(\".\".concat(NAMESPACE, \"-drag-box\"));\n var cropBox = cropper.querySelector(\".\".concat(NAMESPACE, \"-crop-box\"));\n var face = cropBox.querySelector(\".\".concat(NAMESPACE, \"-face\"));\n this.container = container;\n this.cropper = cropper;\n this.canvas = canvas;\n this.dragBox = dragBox;\n this.cropBox = cropBox;\n this.viewBox = cropper.querySelector(\".\".concat(NAMESPACE, \"-view-box\"));\n this.face = face;\n canvas.appendChild(image); // Hide the original image\n\n addClass(element, CLASS_HIDDEN); // Inserts the cropper after to the current image\n\n container.insertBefore(cropper, element.nextSibling); // Show the image if is hidden\n\n if (!this.isImg) {\n removeClass(image, CLASS_HIDE);\n }\n\n this.initPreview();\n this.bind();\n options.initialAspectRatio = Math.max(0, options.initialAspectRatio) || NaN;\n options.aspectRatio = Math.max(0, options.aspectRatio) || NaN;\n options.viewMode = Math.max(0, Math.min(3, Math.round(options.viewMode))) || 0;\n addClass(cropBox, CLASS_HIDDEN);\n\n if (!options.guides) {\n addClass(cropBox.getElementsByClassName(\"\".concat(NAMESPACE, \"-dashed\")), CLASS_HIDDEN);\n }\n\n if (!options.center) {\n addClass(cropBox.getElementsByClassName(\"\".concat(NAMESPACE, \"-center\")), CLASS_HIDDEN);\n }\n\n if (options.background) {\n addClass(cropper, \"\".concat(NAMESPACE, \"-bg\"));\n }\n\n if (!options.highlight) {\n addClass(face, CLASS_INVISIBLE);\n }\n\n if (options.cropBoxMovable) {\n addClass(face, CLASS_MOVE);\n setData(face, DATA_ACTION, ACTION_ALL);\n }\n\n if (!options.cropBoxResizable) {\n addClass(cropBox.getElementsByClassName(\"\".concat(NAMESPACE, \"-line\")), CLASS_HIDDEN);\n addClass(cropBox.getElementsByClassName(\"\".concat(NAMESPACE, \"-point\")), CLASS_HIDDEN);\n }\n\n this.render();\n this.ready = true;\n this.setDragMode(options.dragMode);\n\n if (options.autoCrop) {\n this.crop();\n }\n\n this.setData(options.data);\n\n if (isFunction(options.ready)) {\n addListener(element, EVENT_READY, options.ready, {\n once: true\n });\n }\n\n dispatchEvent(element, EVENT_READY);\n }\n }, {\n key: \"unbuild\",\n value: function unbuild() {\n if (!this.ready) {\n return;\n }\n\n this.ready = false;\n this.unbind();\n this.resetPreview();\n this.cropper.parentNode.removeChild(this.cropper);\n removeClass(this.element, CLASS_HIDDEN);\n }\n }, {\n key: \"uncreate\",\n value: function uncreate() {\n if (this.ready) {\n this.unbuild();\n this.ready = false;\n this.cropped = false;\n } else if (this.sizing) {\n this.sizingImage.onload = null;\n this.sizing = false;\n this.sized = false;\n } else if (this.reloading) {\n this.xhr.onabort = null;\n this.xhr.abort();\n } else if (this.image) {\n this.stop();\n }\n }\n /**\n * Get the no conflict cropper class.\n * @returns {Cropper} The cropper class.\n */\n\n }], [{\n key: \"noConflict\",\n value: function noConflict() {\n window.Cropper = AnotherCropper;\n return Cropper;\n }\n /**\n * Change the default options.\n * @param {Object} options - The new default options.\n */\n\n }, {\n key: \"setDefaults\",\n value: function setDefaults(options) {\n assign(DEFAULTS, isPlainObject(options) && options);\n }\n }]);\n\n return Cropper;\n }();\n\n assign(Cropper.prototype, render, preview, events, handlers, change, methods);\n\n return Cropper;\n\n})));\n"],"sourceRoot":"webpack:///"}