{"version":3,"sources":["kendo.upload.js"],"names":["f","define","$","undefined","getFileName","input","map","inputFiles","file","name","join","$input","files","getAllFileInfo","stripPath","value","extension","getFileExtension","size","rawFiles","getFileInfo","rawFile","fileName","kendo","htmlEncode","fileSize","matches","match","rFileExtension","slashIndex","lastIndexOf","substr","assignGuidToFiles","unique","uid","guid","validateFiles","validationInfo","i","allowedExtensions","parseAllowedExtensions","maxFileSize","minFileSize","length","validateFileExtension","validateFileSize","extensions","ext","parsedExt","substring","toLowerCase","indexOf","validationErrors","inArray","INVALIDFILEEXTENSION","push","INVALIDMINFILESIZE","INVALIDMAXFILESIZE","getTotalFilesSizeMessage","totalSize","toFixed","shouldRemoveFileEntry","upload","multiple","wrapper","removeUploadedFile","fileEntry","eventArgs","shouldSendRemoveRequest","fileNames","_supportsRemove","data","_removeFileEntry","_submitRemove","textStatus","xhr","prevented","trigger","SUCCESS","operation","response","XMLHttpRequest","ERROR","logToConsole","responseText","tryParseJSON","onSuccess","onError","success","json","parseJSON","normalizeJSON","e","stopEvent","originalEvent","dataTransfer","dropEffect","stopPropagation","preventDefault","bindDragEventWrappers","element","namespace","onDragEnter","onDragLeave","hideInterval","lastDrag","on","Date","setInterval","sinceLastDrag","clearInterval","isFileUploadStarted","is","getFileEntry","target","closest","iframeUploadModule","formDataUploadModule","window","Widget","ui","antiForgeryTokens","NS","SELECT","UPLOAD","COMPLETE","CANCEL","CLEAR","PAUSE","RESUME","PROGRESS","REMOVE","VALIDATIONERRORS","PROGRESSHIDEDELAY","PROGRESSHIDEDURATION","headerStatusIcon","loading","warning","Upload","extend","init","options","activeInput","ns","that","this","fn","call","directory","localization","_wrapInput","_activeInput","toggle","enabled","_ns","proxy","_onParentFormSubmit","_onParentFormReset","_initUploadModule","_toggleDropZone","_onFileAction","_onClearSelected","_onUploadSelected","val","_onInputChange","events","showFileList","template","async","autoRetryAfter","bufferChunkSize","maxAutoRetries","removeVerb","autoUpload","withCredentials","accept","useArrayBuffer","select","cancel","retry","remove","pause","resume","clearSelectedFiles","uploadSelectedFiles","dropFilesHere","invalidFiles","statusUploading","statusUploaded","statusWarning","statusFailed","headerStatusUploading","headerStatusPaused","headerStatusUploaded","uploadSuccess","uploadFail","invalidMaxFileSize","invalidMinFileSize","invalidFileExtension","validation","dropZone","initialFiles","saveUrl","_module","_supportsFormData","_async","_renderInitialFiles","syncUploadModule","setOptions","off","attr","_supportsMultiple","enable","disable","toggleClass","prop","focus","destroy","customDropZone","document","add","onPause","pauseIcon","find","removeClass","addClass","parent","onResume","playIcon","onSaveSelected","getFiles","filesData","j","allFiles","listItems","clearAllFiles","each","index","_removeFileByDomElement","removeAllFiles","removeFileByUid","_removeFileByUid","clearFileByUid","clearFile","callback","_removeFile","removeFile","fileData","hasClass","onCancel","onRemove","_hideHeaderUploadstatus","_updateHeaderUploadStatus","_addInput","sourceInput","nodeType","clone","insertAfter","prefix","hide","removeAttr","_onInputKeyDown","firstButton","keyCode","keys","TAB","shiftKey","_inputFiles","_isAsyncNonBatch","onSelect","_readDirectory","item","deferred","Deferred","dirReader","createReader","allFolderFiles","readEntries","entries","concat","resolve","reject","promise","_readFile","fullpath","fullPath","relativePath","slice","droppedFolderFiles","droppedFolderCounter","setTimeout","_proceedDroppedItems","_traverseFileTree","skipCounter","then","items","isFile","isDirectory","_onDrop","entry","dt","droppedFiles","directoryDrop","webkitGetAsEntry","splice","_filesContainValidationErrors","hasErrors","batch","currentFile","idx","_enqueueFile","_fileAction","_prepareTemplateData","templateData","_prepareDefaultSingleFileEntryTemplate","fileGroup","getFileGroup","errors","_prepareDefaultMultipleFileEntriesTemplate","filesHaveValidationErrors","totalFileSize","sort","a","b","existingFileEntries","removeEventArgs","fileUid","fileList","appendTo","angular","elements","width","headers","allCompletedFiles","allInvalidFiles","_hideActionButtons","fileElement","actionKey","skipClear","firstActionButton","classDictionary","iconsClassDictionary","hasOwnProperty","_clearFileAction","first","next","append","show","_renderAction","_fileState","stateKey","states","uploading","text","uploaded","failed","currentState","actionClass","actionText","iconClass","empty","button","icon","hasValidationErrors","_retryClicked","_checkAllComplete","finish","onRetry","clearEventArgs","_onFileProgress","percentComplete","progressPct","prepend","_onUploadSuccess","fileInfo","_setUploadErrorState","after","_hideUploadProgress","_onUploadError","module","chunkSize","_decreasePosition","_autoRetryAfter","retries","performUpload","uploadPercentage","_updateUploadProgress","fileMetaData","metaData","totalChunks","Math","round","chunkIndex","delay","fadeOut","css","_showActionButtons","actionsWrapper","uploadButton","clearButton","_showHeaderUploadStatus","isUploading","headerUploadStatus","failedUploads","headerUploadStatusIcon","currentlyUploading","not","currentlyInvalid","currentlyFailed","currentlyPaused","concurrent","html","onAbort","FormData","windows","_userAgent","support","browser","opera","safari","_supportsDrop","userAgent","isChrome","test","isSafari","isWindowsSafari","navigator","_setupDropZone","_bindDocumentDragEventWrappers","_setupCustomDropZone","removeUrl","removeField","params","jQuery","ajax","type","dataType","dataFilter","url","traditional","error","xhrFields","wrap","prototype","filesContainErrors","relatedInput","iframes","_frameId","prepareUpload","iframe","form","saveField","createFrame","registerFrame","createForm","frame","key","dataInput","fileValidation","cleanupFrame","unregisterFrame","body","prependTo","one","onIframeLoad","submit","started","contents","ex","processResponse","fakeXHR","jsonResult","statusText","status","stopFrameSubmit","id","action","stop","execCommand","grep","position","cancelled","paused","prev","sourceElement","fileEntries","prepareChunk","enqueueFiles","filesLength","webkitRelativePath","formData","createFormData","createXHR","removeFileEntry","populateFormData","FileReader","postFormData","reader","onload","fileArrayBuffer","_appendBuffer","result","err","onerror","readAsArrayBuffer","_getCurrentChunk","buffer1","buffer2","tmp","Uint8Array","byteLength","set","buffer","filter","prevEntry","stopUploadRequest","_increaseChunkIndex","addEventListener","onRequestSuccess","onRequestError","onRequestProgress","open","setRequestHeader","send","chunk","serializedMetaData","JSON","stringify","raiseError","parseSuccess","cleanupFileEntry","_resetChunkIndex","uploadComplete","isUploadButtonVisible","loaded","total","abort","contentType","ceil","uploadUid","_decreaseChunkIndex","methodToInvoke","oldPosition","_getChunker","mozSlice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S,SAAUmiB,EAAIC,EAAIC,IACrEA,GAAMD","file":"kendo.upload.min.js","sourcesContent":["/*!\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n*/\n(function (f, define) {\n define('kendo.upload', ['kendo.core'], f);\n}(function () {\n var __meta__ = {\n id: 'upload',\n name: 'Upload',\n category: 'web',\n description: 'The Upload widget uses progressive enhancement to deliver the best possible uploading experience to users.',\n depends: ['core']\n };\n (function ($, undefined) {\n var kendo = window.kendo, Widget = kendo.ui.Widget, antiForgeryTokens = kendo.antiForgeryTokens, logToConsole = kendo.logToConsole, rFileExtension = /\\.([^\\.]+)$/, NS = '.kendoUpload', SELECT = 'select', UPLOAD = 'upload', SUCCESS = 'success', ERROR = 'error', COMPLETE = 'complete', CANCEL = 'cancel', CLEAR = 'clear', PAUSE = 'pause', RESUME = 'resume', PROGRESS = 'progress', REMOVE = 'remove', VALIDATIONERRORS = 'validationErrors', INVALIDMAXFILESIZE = 'invalidMaxFileSize', INVALIDMINFILESIZE = 'invalidMinFileSize', INVALIDFILEEXTENSION = 'invalidFileExtension', PROGRESSHIDEDELAY = 1000, PROGRESSHIDEDURATION = 2000;\n var headerStatusIcon = {\n loading: 'k-i-upload',\n warning: 'k-i-warning',\n success: 'k-i-check'\n };\n var Upload = Widget.extend({\n init: function (element, options) {\n var that = this;\n Widget.fn.init.call(that, element, options);\n that.name = element.name;\n that.multiple = that.options.multiple;\n that.directory = that.options.directory;\n that.localization = that.options.localization;\n var activeInput = that.element;\n that.wrapper = activeInput.closest('.k-upload');\n if (that.wrapper.length === 0) {\n that.wrapper = that._wrapInput(activeInput);\n }\n that._activeInput(activeInput);\n that.toggle(that.options.enabled);\n var ns = that._ns = NS + '-' + kendo.guid();\n activeInput.closest('form').on('submit' + ns, $.proxy(that._onParentFormSubmit, that)).on('reset' + ns, $.proxy(that._onParentFormReset, that));\n that._initUploadModule();\n that._toggleDropZone();\n that.wrapper.on('click', '.k-upload-action', $.proxy(that._onFileAction, that)).on('click', '.k-clear-selected', $.proxy(that._onClearSelected, that)).on('click', '.k-upload-selected', $.proxy(that._onUploadSelected, that));\n if (that.element.val()) {\n that._onInputChange({ target: that.element });\n }\n },\n events: [\n SELECT,\n UPLOAD,\n SUCCESS,\n ERROR,\n COMPLETE,\n CANCEL,\n CLEAR,\n PROGRESS,\n REMOVE,\n PAUSE,\n RESUME\n ],\n options: {\n name: 'Upload',\n enabled: true,\n multiple: true,\n directory: false,\n showFileList: true,\n template: '',\n files: [],\n async: {\n autoRetryAfter: 0,\n bufferChunkSize: 10000000,\n maxAutoRetries: 1,\n removeVerb: 'POST',\n autoUpload: true,\n withCredentials: true,\n accept: '*/*; q=0.5, application/json',\n useArrayBuffer: false\n },\n localization: {\n 'select': 'Select files...',\n 'cancel': 'Cancel',\n 'retry': 'Retry',\n 'remove': 'Remove',\n 'pause': 'Pause',\n 'resume': 'Resume',\n 'clearSelectedFiles': 'Clear',\n 'uploadSelectedFiles': 'Upload',\n 'dropFilesHere': 'Drop files here to upload',\n 'invalidFiles': 'Invalid file(s). Please check file upload requirements.',\n 'statusUploading': 'uploading',\n 'statusUploaded': 'uploaded',\n 'statusWarning': 'warning',\n 'statusFailed': 'failed',\n 'headerStatusUploading': 'Uploading...',\n 'headerStatusPaused': 'Paused',\n 'headerStatusUploaded': 'Done',\n 'uploadSuccess': 'File(s) uploaded successfully.',\n 'uploadFail': 'File(s) failed to upload.',\n 'invalidMaxFileSize': 'File size too large.',\n 'invalidMinFileSize': 'File size too small.',\n 'invalidFileExtension': 'File type not allowed.'\n },\n validation: {\n allowedExtensions: [],\n maxFileSize: 0,\n minFileSize: 0\n },\n dropZone: ''\n },\n _initUploadModule: function () {\n var that = this, options = that.options;\n if (options.async.saveUrl) {\n that._module = that._supportsFormData() ? new formDataUploadModule(that) : new iframeUploadModule(that);\n that._async = true;\n var initialFiles = options.files;\n if (initialFiles.length > 0) {\n that._renderInitialFiles(initialFiles);\n }\n } else {\n that._module = new syncUploadModule(that);\n }\n },\n setOptions: function (options) {\n var that = this, activeInput = that.element;\n $(that.options.dropZone).off(that._ns);\n Widget.fn.setOptions.call(that, options);\n that.multiple = that.options.multiple;\n that.directory = that.options.directory;\n activeInput.attr('multiple', that._supportsMultiple() ? that.multiple : false);\n if (that.directory) {\n activeInput.attr('webkitdirectory', that.directory);\n activeInput.attr('directory', that.directory);\n }\n that.toggle(that.options.enabled);\n that._initUploadModule();\n that._toggleDropZone();\n },\n enable: function (enable) {\n enable = typeof enable === 'undefined' ? true : enable;\n this.toggle(enable);\n },\n disable: function () {\n this.toggle(false);\n },\n toggle: function (enable) {\n enable = typeof enable === 'undefined' ? enable : !enable;\n this.wrapper.toggleClass('k-state-disabled', enable);\n this.element.prop('disabled', enable);\n },\n focus: function () {\n this.element.focus();\n },\n destroy: function () {\n var that = this;\n var customDropZone = $(that.options.dropZone);\n $(document).add($('.k-dropzone', that.wrapper)).add(that.wrapper.closest('form')).off(that._ns);\n if (customDropZone.length > 0) {\n customDropZone.off(that._ns);\n }\n $(that.element).off(NS);\n Widget.fn.destroy.call(that);\n },\n pause: function (fileEntry) {\n this._module.onPause({ target: $(fileEntry, this.wrapper) });\n var pauseIcon = fileEntry.find('.k-i-pause-sm');\n pauseIcon.removeClass('k-i-pause-sm').addClass('k-i-play-sm').attr('title', this.localization.resume);\n $(pauseIcon).parent().attr('aria-label', this.localization.resume);\n },\n resume: function (fileEntry) {\n this._module.onResume({ target: $(fileEntry, this.wrapper) });\n var playIcon = fileEntry.find('.k-i-play-sm');\n playIcon.removeClass('k-i-play-sm').addClass('k-i-pause-sm').attr('title', this.localization.pause);\n $(playIcon).parent().attr('aria-label', this.localization.pause);\n },\n upload: function () {\n var that = this;\n that._module.onSaveSelected();\n },\n getFiles: function () {\n var that = this;\n var filesData;\n var allFiles = [];\n var listItems = that.wrapper.find('.k-file');\n for (var i = 0; i < listItems.length; i++) {\n filesData = $(listItems[i]).data('fileNames');\n if (filesData) {\n for (var j = 0; j < filesData.length; j++) {\n allFiles.push(filesData[j]);\n }\n }\n }\n return allFiles;\n },\n clearAllFiles: function () {\n var that = this;\n var files = that.wrapper.find('.k-file');\n files.each(function (index, file) {\n that._removeFileByDomElement(file, false);\n });\n },\n removeAllFiles: function () {\n var that = this;\n var files = that.wrapper.find('.k-file');\n files.each(function (index, file) {\n that._removeFileByDomElement(file, true);\n });\n },\n removeFileByUid: function (uid) {\n this._removeFileByUid(uid, true);\n },\n clearFileByUid: function (uid) {\n this._removeFileByUid(uid, false);\n },\n _removeFileByUid: function (uid, shouldSendRemoveRequest) {\n var that = this;\n var fileEntry;\n if (typeof uid !== 'string') {\n return;\n }\n fileEntry = $('.k-file[' + kendo.attr('uid') + '=\"' + uid + '\"]', that.wrapper);\n if (fileEntry.length > 0) {\n that._removeFileByDomElement(fileEntry, shouldSendRemoveRequest);\n }\n },\n clearFile: function (callback) {\n this._removeFile(callback, false);\n },\n removeFile: function (callback) {\n this._removeFile(callback, true);\n },\n _removeFile: function (callback, shouldSendRemoveRequest) {\n var that = this;\n var files = that.wrapper.find('.k-file');\n var fileData;\n if (typeof callback === 'function') {\n files.each(function (index, file) {\n fileData = $(file).data('fileNames');\n if (callback(fileData)) {\n that._removeFileByDomElement(file, shouldSendRemoveRequest);\n }\n });\n }\n },\n _removeFileByDomElement: function (fileEntry, shouldSendRemoveRequest) {\n var that = this;\n var fileData = { target: $(fileEntry, that.wrapper) };\n var allFiles;\n if (that.options.async.saveUrl) {\n if ($(fileEntry).hasClass('k-file-progress')) {\n that._module.onCancel(fileData);\n } else {\n that._module.onRemove(fileData, {}, shouldSendRemoveRequest);\n }\n allFiles = $('.k-file', that.wrapper);\n if (allFiles.length === 0) {\n that._hideHeaderUploadstatus();\n } else {\n that._updateHeaderUploadStatus();\n }\n } else {\n that._module.onRemove(fileData, {}, shouldSendRemoveRequest);\n }\n },\n _addInput: function (sourceInput) {\n if (!sourceInput[0].nodeType) {\n return;\n }\n var that = this, input = sourceInput.clone().val('');\n input.insertAfter(that.element).data('kendo' + that.options.prefix + that.options.name, that);\n $(that.element).hide().attr('tabindex', '-1').removeAttr('id').off(NS);\n that._activeInput(input);\n that.element.focus();\n },\n _activeInput: function (input) {\n var that = this, wrapper = that.wrapper;\n that.element = input;\n if (that.directory) {\n input.attr('webkitdirectory', that.directory);\n input.attr('directory', that.directory);\n }\n input.attr('multiple', that._supportsMultiple() ? that.multiple : false).attr('autocomplete', 'off').on('click' + NS, function (e) {\n if (wrapper.hasClass('k-state-disabled')) {\n e.preventDefault();\n }\n }).on('focus' + NS, function () {\n $(this).parent().addClass('k-state-focused');\n }).on('blur' + NS, function () {\n $(this).parent().removeClass('k-state-focused');\n }).on('change' + NS, $.proxy(that._onInputChange, that)).on('keydown' + NS, $.proxy(that._onInputKeyDown, that));\n },\n _onInputKeyDown: function (e) {\n var that = this;\n var firstButton = that.wrapper.find('.k-upload-action:visible:first');\n if (e.keyCode === kendo.keys.TAB && firstButton.length > 0 && !e.shiftKey) {\n e.preventDefault();\n firstButton.focus();\n }\n },\n _onInputChange: function (e) {\n var that = this;\n var input = $(e.target);\n var files = assignGuidToFiles(that._inputFiles(input), that._isAsyncNonBatch());\n validateFiles(files, that.options.validation);\n var prevented = that.trigger(SELECT, { files: files });\n if (prevented) {\n that._addInput(input);\n input.remove();\n } else {\n that._module.onSelect({ target: input }, files);\n }\n },\n _readDirectory: function (item) {\n var deferred = new $.Deferred();\n var dirReader = item.createReader();\n var allFolderFiles = [];\n var readEntries = function () {\n dirReader.readEntries(function (entries) {\n if (!entries.length) {\n deferred.resolve(allFolderFiles);\n } else {\n allFolderFiles = allFolderFiles.concat(entries);\n readEntries();\n }\n }, deferred.reject);\n };\n readEntries();\n return deferred.promise();\n },\n _readFile: function (item) {\n var that = this;\n var fullpath = item.fullPath;\n item.file(function (file) {\n file.relativePath = fullpath.slice(1);\n that.droppedFolderFiles.push(file);\n that.droppedFolderCounter--;\n if (that.droppedFolderCounter === 0) {\n setTimeout(function () {\n if (that.droppedFolderCounter === 0) {\n if (that.droppedFolderFiles.length) {\n that._proceedDroppedItems(that.droppedFolderFiles);\n that.droppedFolderFiles = [];\n }\n }\n }, 0);\n }\n }, function () {\n logToConsole('File error.');\n });\n },\n _traverseFileTree: function (item, skipCounter) {\n var that = this;\n if (!skipCounter) {\n that.droppedFolderCounter--;\n }\n this._readDirectory(item).then(function (items) {\n that.droppedFolderCounter += items.length;\n for (var i = 0; i < items.length; i++) {\n if (items[i].isFile) {\n that._readFile(items[i]);\n } else if (items[i].isDirectory) {\n that._traverseFileTree(items[i]);\n }\n }\n });\n },\n _onDrop: function (e) {\n var dt = e.originalEvent.dataTransfer;\n var that = this;\n var droppedFiles = dt.files;\n var length;\n stopEvent(e);\n if (that.options.directoryDrop && dt.items) {\n length = dt.items.length;\n that.droppedFolderCounter = 0;\n that.droppedFolderFiles = [];\n for (var i = 0; i < length; i++) {\n if (dt.items[i].webkitGetAsEntry) {\n var entry = dt.items[i].webkitGetAsEntry();\n if (entry.isDirectory) {\n that._traverseFileTree(entry, true);\n } else if (entry.isFile) {\n that.droppedFolderFiles.push(dt.files[i]);\n }\n } else {\n that._proceedDroppedItems(droppedFiles);\n }\n }\n } else {\n that._proceedDroppedItems(droppedFiles);\n }\n },\n _proceedDroppedItems: function (droppedFiles) {\n var that = this;\n var files = assignGuidToFiles(getAllFileInfo(droppedFiles), that._isAsyncNonBatch());\n if (droppedFiles.length > 0 && !that.wrapper.hasClass('k-state-disabled')) {\n if (!that.multiple && files.length > 1) {\n files.splice(1, files.length - 1);\n }\n validateFiles(files, that.options.validation);\n var prevented = that.trigger(SELECT, { files: files });\n if (!prevented) {\n that._module.onSelect({ target: $('.k-dropzone', that.wrapper) }, files);\n }\n }\n },\n _filesContainValidationErrors: function (files) {\n var hasErrors = false;\n $(files).each(function (index, file) {\n if (file[VALIDATIONERRORS] && file[VALIDATIONERRORS].length > 0) {\n hasErrors = true;\n return false;\n }\n });\n return hasErrors;\n },\n _isAsyncNonBatch: function () {\n return this._async && !this.options.async.batch || false;\n },\n _renderInitialFiles: function (files) {\n var that = this;\n var idx = 0;\n files = assignGuidToFiles(files, true);\n for (idx = 0; idx < files.length; idx++) {\n var currentFile = files[idx];\n var fileEntry = that._enqueueFile(currentFile.name, { fileNames: [currentFile] });\n fileEntry.addClass('k-file-success').data('files', [files[idx]]);\n if (that._supportsRemove()) {\n that._fileAction(fileEntry, REMOVE);\n }\n }\n },\n _prepareTemplateData: function (name, data) {\n var filesData = data.fileNames, templateData = {}, totalSize = 0, idx = 0;\n for (idx = 0; idx < filesData.length; idx++) {\n totalSize += filesData[idx].size;\n }\n templateData.name = name;\n templateData.size = totalSize;\n templateData.files = data.fileNames;\n return templateData;\n },\n _prepareDefaultSingleFileEntryTemplate: function (data) {\n var that = this;\n var file = data.fileNames[0];\n var fileSize = getTotalFilesSizeMessage(data.fileNames);\n var fileGroup = kendo.getFileGroup(file.extension, true);\n var errors = file[VALIDATIONERRORS];\n var template = '';\n if (errors && errors.length > 0) {\n template += '