{"id":22154,"date":"2023-05-22T15:13:49","date_gmt":"2023-05-22T19:13:49","guid":{"rendered":"https:\/\/www.tradewindfinance.com\/?page_id=22154"},"modified":"2023-06-13T16:22:25","modified_gmt":"2023-06-13T20:22:25","slug":"current-openings","status":"publish","type":"page","link":"https:\/\/dev.tradewindfinance.com\/ar\/current-openings\/","title":{"rendered":"Current Openings"},"content":{"rendered":"\t\t<div data-elementor-type=\"wp-page\" data-elementor-id=\"22154\" class=\"elementor elementor-22154\" data-elementor-post-type=\"page\">\n\t\t\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-5a0c1ae elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"5a0c1ae\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-9d54054\" data-id=\"9d54054\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-6f6dfc5 elementor-widget elementor-widget-shortcode\" data-id=\"6f6dfc5\" data-element_type=\"widget\" data-widget_type=\"shortcode.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"elementor-shortcode\">[jobs]<\/div>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-c1ef93f elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"c1ef93f\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-71948d3\" data-id=\"71948d3\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-c65087c elementor-widget elementor-widget-shortcode\" data-id=\"c65087c\" data-element_type=\"widget\" data-widget_type=\"shortcode.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"elementor-shortcode\">[contact-form-7 id=\"22744\" title=\"Job Application\"]<\/div>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-a930d5a elementor-widget elementor-widget-html\" data-id=\"a930d5a\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<script src='https:\/\/code.jquery.com\/jquery-3.4.1.min.js'><\/script>\r\n<script src='https:\/\/cdn.jsdelivr.net\/npm\/popper.js@1.16.0\/dist\/umd\/popper.min.js'><\/script>\r\n<script src='https:\/\/stackpath.bootstrapcdn.com\/bootstrap\/4.4.1\/js\/bootstrap.min.js'><\/script>\r\n<script src='https:\/\/cdnjs.cloudflare.com\/ajax\/libs\/bootstrap-fileinput\/5.2.3\/js\/plugins\/sortable.min.js'><\/script>\r\n<script src='https:\/\/cdnjs.cloudflare.com\/ajax\/libs\/bootstrap-fileinput\/5.2.3\/themes\/fas\/theme.min.js'><\/script>\r\n\r\n<script>\/*!\r\n * bootstrap-fileinput v5.2.3\r\n * http:\/\/plugins.krajee.com\/file-input\r\n *\r\n * Author: Kartik Visweswaran\r\n * Copyright: 2014 - 2021, Kartik Visweswaran, Krajee.com\r\n *\r\n * Licensed under the BSD-3-Clause\r\n * https:\/\/github.com\/kartik-v\/bootstrap-fileinput\/blob\/master\/LICENSE.md\r\n *\/\r\n! function(e) {\r\n    \"use strict\";\r\n    \"function\" == typeof define && define.amd ? define([\"jquery\"], e) : \"object\" == typeof module && module.exports ? module.exports = e(require(\"jquery\")) : e(window.jQuery)\r\n}(function(e) {\r\n    \"use strict\";\r\n    var t, i;\r\n    e.fn.fileinputLocales = {}, e.fn.fileinputThemes = {}, e.fn.fileinputBsVersion || (e.fn.fileinputBsVersion = window.Alert && window.Alert.VERSION || window.bootstrap && window.bootstrap.Alert && bootstrap.Alert.VERSION || \"3.x.x\"), String.prototype.setTokens = function(e) {\r\n        var t, i, a = this.toString();\r\n        for (t in e) e.hasOwnProperty(t) && (i = new RegExp(\"{\" + t + \"}\", \"g\"), a = a.replace(i, e[t]));\r\n        return a\r\n    }, Array.prototype.flatMap || (Array.prototype.flatMap = function(e) {\r\n        return [].concat(this.map(e))\r\n    }), t = {\r\n        FRAMES: \".kv-preview-thumb\",\r\n        SORT_CSS: \"file-sortable\",\r\n        INIT_FLAG: \"init-\",\r\n        ZOOM_VAR: \"?kvTemp__2873389129__=\",\r\n        OBJECT_PARAMS: '<param name=\"controller\" value=\"true\" \/>\\n<param name=\"allowFullScreen\" value=\"true\" \/>\\n<param name=\"allowScriptAccess\" value=\"always\" \/>\\n<param name=\"autoPlay\" value=\"false\" \/>\\n<param name=\"autoStart\" value=\"false\" \/>\\n<param name=\"quality\" value=\"high\" \/>\\n',\r\n        DEFAULT_PREVIEW: '<div class=\"file-preview-other\">\\n<span class=\"{previewFileIconClass}\">{previewFileIcon}<\/span>\\n<\/div>',\r\n        MODAL_ID: \"kvFileinputModal\",\r\n        MODAL_EVENTS: [\"show\", \"shown\", \"hide\", \"hidden\", \"loaded\"],\r\n        logMessages: {\r\n            ajaxError: \"{status}: {error}. Error Details: {text}.\",\r\n            badDroppedFiles: \"Error scanning dropped files!\",\r\n            badExifParser: \"Error loading the piexif.js library. {details}\",\r\n            badInputType: 'The input \"type\" must be set to \"file\" for initializing the \"bootstrap-fileinput\" plugin.',\r\n            exifWarning: 'To avoid this warning, either set \"autoOrientImage\" to \"false\" OR ensure you have loaded the \"piexif.js\" library correctly on your page before the \"fileinput.js\" script.',\r\n            invalidChunkSize: 'Invalid upload chunk size: \"{chunkSize}\". Resumable uploads are disabled.',\r\n            invalidThumb: 'Invalid thumb frame with id: \"{id}\".',\r\n            noResumableSupport: \"The browser does not support resumable or chunk uploads.\",\r\n            noUploadUrl: 'The \"uploadUrl\" is not set. Ajax uploads and resumable uploads have been disabled.',\r\n            retryStatus: \"Retrying upload for chunk # {chunk} for {filename}... retry # {retry}.\",\r\n            chunkQueueError: \"Could not push task to ajax pool for chunk index # {index}.\",\r\n            resumableMaxRetriesReached: \"Maximum resumable ajax retries ({n}) reached.\",\r\n            resumableRetryError: \"Could not retry the resumable request (try # {n})... aborting.\",\r\n            resumableAborting: \"Aborting \/ cancelling the resumable request.\",\r\n            resumableRequestError: \"Error processing resumable request. {msg}\"\r\n        },\r\n        objUrl: window.URL || window.webkitURL,\r\n        isBs: function(t) {\r\n            var i = e.trim((e.fn.fileinputBsVersion || \"\") + \"\");\r\n            return t = parseInt(t, 10), i ? t === parseInt(i.charAt(0), 10) : 4 === t\r\n        },\r\n        defaultButtonCss: function(e) {\r\n            return \"btn-default btn-\" + (e ? \"\" : \"outline-\") + \"secondary\"\r\n        },\r\n        now: function() {\r\n            return (new Date).getTime()\r\n        },\r\n        round: function(e) {\r\n            return e = parseFloat(e), isNaN(e) ? 0 : Math.floor(Math.round(e))\r\n        },\r\n        getArray: function(e) {\r\n            var t, i = [],\r\n                a = e && e.length || 0;\r\n            for (t = 0; t < a; t++) i.push(e[t]);\r\n            return i\r\n        },\r\n        getFileRelativePath: function(e) {\r\n            return String(e.newPath || e.relativePath || e.webkitRelativePath || t.getFileName(e) || null)\r\n        },\r\n        getFileId: function(e, i) {\r\n            var a = t.getFileRelativePath(e);\r\n            return \"function\" == typeof i ? i(e) : e && a ? e.size + \"_\" + encodeURIComponent(a).replace(\/%\/g, \"_\") : null\r\n        },\r\n        getFrameSelector: function(e, t) {\r\n            return '[id=\"' + e + '\"]' + (t = t || \"\")\r\n        },\r\n        getZoomSelector: function(e, i) {\r\n            return t.getFrameSelector(\"zoom-\" + e, i)\r\n        },\r\n        getFrameElement: function(e, i, a) {\r\n            return e.find(t.getFrameSelector(i, a))\r\n        },\r\n        getZoomElement: function(e, i, a) {\r\n            return e.find(t.getZoomSelector(i, a))\r\n        },\r\n        getElapsed: function(i) {\r\n            var a = i,\r\n                r = \"\",\r\n                s = {},\r\n                n = {\r\n                    year: 31536e3,\r\n                    month: 2592e3,\r\n                    week: 604800,\r\n                    day: 86400,\r\n                    hour: 3600,\r\n                    minute: 60,\r\n                    second: 1\r\n                };\r\n            return t.getObjectKeys(n).forEach(function(e) {\r\n                s[e] = Math.floor(a \/ n[e]), a -= s[e] * n[e]\r\n            }), e.each(s, function(e, t) {\r\n                t > 0 && (r += (r ? \" \" : \"\") + t + e.substring(0, 1))\r\n            }), r\r\n        },\r\n        debounce: function(e, t) {\r\n            var i;\r\n            return function() {\r\n                var a = arguments,\r\n                    r = this;\r\n                clearTimeout(i), i = setTimeout(function() {\r\n                    e.apply(r, a)\r\n                }, t)\r\n            }\r\n        },\r\n        stopEvent: function(e) {\r\n            e.stopPropagation(), e.preventDefault()\r\n        },\r\n        getFileName: function(e) {\r\n            return e && (e.fileName || e.name) || \"\"\r\n        },\r\n        createObjectURL: function(e) {\r\n            return t.objUrl && t.objUrl.createObjectURL && e ? t.objUrl.createObjectURL(e) : \"\"\r\n        },\r\n        revokeObjectURL: function(e) {\r\n            t.objUrl && t.objUrl.revokeObjectURL && e && t.objUrl.revokeObjectURL(e)\r\n        },\r\n        compare: function(e, t, i) {\r\n            return void 0 !== e && (i ? e === t : e.match(t))\r\n        },\r\n        isIE: function(e) {\r\n            var t, i;\r\n            return \"Microsoft Internet Explorer\" === navigator.appName && (10 === e ? new RegExp(\"msie\\\\s\" + e, \"i\").test(navigator.userAgent) : ((t = document.createElement(\"div\")).innerHTML = \"\\x3c!--[if IE \" + e + \"]> <i><\/i> <![endif]--\\x3e\", i = t.getElementsByTagName(\"i\").length, document.body.appendChild(t), t.parentNode.removeChild(t), i))\r\n        },\r\n        canOrientImage: function(t) {\r\n            var i = e(document.createElement(\"img\")).css({\r\n                    width: \"1px\",\r\n                    height: \"1px\"\r\n                }).insertAfter(t),\r\n                a = i.css(\"image-orientation\");\r\n            return i.remove(), !!a\r\n        },\r\n        canAssignFilesToInput: function() {\r\n            var e = document.createElement(\"input\");\r\n            try {\r\n                return e.type = \"file\", e.files = null, !0\r\n            } catch (e) {\r\n                return !1\r\n            }\r\n        },\r\n        getDragDropFolders: function(e) {\r\n            var t, i, a = e ? e.length : 0,\r\n                r = 0;\r\n            if (a > 0 && e[0].webkitGetAsEntry())\r\n                for (t = 0; t < a; t++)(i = e[t].webkitGetAsEntry()) && i.isDirectory && r++;\r\n            return r\r\n        },\r\n        initModal: function(t) {\r\n            var i = e(\"body\");\r\n            i.length && t.appendTo(i)\r\n        },\r\n        isFunction: function(e) {\r\n            return \"function\" == typeof e\r\n        },\r\n        isEmpty: function(i, a) {\r\n            return null == i || \"\" === i || (t.isString(i) && a ? \"\" === e.trim(i) : t.isArray(i) ? 0 === i.length : !(!e.isPlainObject(i) || !e.isEmptyObject(i)))\r\n        },\r\n        isArray: function(e) {\r\n            return Array.isArray(e) || \"[object Array]\" === Object.prototype.toString.call(e)\r\n        },\r\n        isString: function(e) {\r\n            return \"[object String]\" === Object.prototype.toString.call(e)\r\n        },\r\n        ifSet: function(e, t, i) {\r\n            return i = i || \"\", t && \"object\" == typeof t && e in t ? t[e] : i\r\n        },\r\n        cleanArray: function(e) {\r\n            return e instanceof Array || (e = []), e.filter(function(e) {\r\n                return null != e\r\n            })\r\n        },\r\n        spliceArray: function(t, i, a) {\r\n            var r, s, n = 0,\r\n                o = [];\r\n            if (!(t instanceof Array)) return [];\r\n            for (s = e.extend(!0, [], t), a && s.reverse(), r = 0; r < s.length; r++) r !== i && (o[n] = s[r], n++);\r\n            return a && o.reverse(), o\r\n        },\r\n        getNum: function(e, t) {\r\n            return t = t || 0, \"number\" == typeof e ? e : (\"string\" == typeof e && (e = parseFloat(e)), isNaN(e) ? t : e)\r\n        },\r\n        hasFileAPISupport: function() {\r\n            return !(!window.File || !window.FileReader)\r\n        },\r\n        hasDragDropSupport: function() {\r\n            var e = document.createElement(\"div\");\r\n            return !t.isIE(9) && (void 0 !== e.draggable || void 0 !== e.ondragstart && void 0 !== e.ondrop)\r\n        },\r\n        hasFileUploadSupport: function() {\r\n            return t.hasFileAPISupport() && window.FormData\r\n        },\r\n        hasBlobSupport: function() {\r\n            try {\r\n                return !!window.Blob && Boolean(new Blob)\r\n            } catch (e) {\r\n                return !1\r\n            }\r\n        },\r\n        hasArrayBufferViewSupport: function() {\r\n            try {\r\n                return 100 === new Blob([new Uint8Array(100)]).size\r\n            } catch (e) {\r\n                return !1\r\n            }\r\n        },\r\n        hasResumableUploadSupport: function() {\r\n            return t.hasFileUploadSupport() && t.hasBlobSupport() && t.hasArrayBufferViewSupport() && (!!Blob.prototype.webkitSlice || !!Blob.prototype.mozSlice || !!Blob.prototype.slice || !1)\r\n        },\r\n        dataURI2Blob: function(e) {\r\n            var i, a, r, s, n, o, l = window.BlobBuilder || window.WebKitBlobBuilder || window.MozBlobBuilder || window.MSBlobBuilder,\r\n                d = t.hasBlobSupport();\r\n            if (!((d || l) && window.atob && window.ArrayBuffer && window.Uint8Array)) return null;\r\n            for (i = e.split(\",\")[0].indexOf(\"base64\") >= 0 ? atob(e.split(\",\")[1]) : decodeURIComponent(e.split(\",\")[1]), a = new ArrayBuffer(i.length), r = new Uint8Array(a), s = 0; s < i.length; s += 1) r[s] = i.charCodeAt(s);\r\n            return n = e.split(\",\")[0].split(\":\")[1].split(\";\")[0], d ? new Blob([t.hasArrayBufferViewSupport() ? r : a], {\r\n                type: n\r\n            }) : ((o = new l).append(a), o.getBlob(n))\r\n        },\r\n        arrayBuffer2String: function(e) {\r\n            if (window.TextDecoder) return new TextDecoder(\"utf-8\").decode(e);\r\n            var t, i, a, r, s = Array.prototype.slice.apply(new Uint8Array(e)),\r\n                n = \"\",\r\n                o = 0;\r\n            for (t = s.length; o < t;) switch ((i = s[o++]) >> 4) {\r\n                case 0:\r\n                case 1:\r\n                case 2:\r\n                case 3:\r\n                case 4:\r\n                case 5:\r\n                case 6:\r\n                case 7:\r\n                    n += String.fromCharCode(i);\r\n                    break;\r\n                case 12:\r\n                case 13:\r\n                    a = s[o++], n += String.fromCharCode((31 & i) << 6 | 63 & a);\r\n                    break;\r\n                case 14:\r\n                    a = s[o++], r = s[o++], n += String.fromCharCode((15 & i) << 12 | (63 & a) << 6 | (63 & r) << 0)\r\n            }\r\n            return n\r\n        },\r\n        isHtml: function(e) {\r\n            var t = document.createElement(\"div\");\r\n            t.innerHTML = e;\r\n            for (var i = t.childNodes, a = i.length; a--;)\r\n                if (1 === i[a].nodeType) return !0;\r\n            return !1\r\n        },\r\n        isSvg: function(e) {\r\n            return e.match(\/^\\s*<\\?xml\/i) && (e.match(\/<!DOCTYPE svg\/i) || e.match(\/<svg\/i))\r\n        },\r\n        getMimeType: function(e, t, i) {\r\n            switch (e) {\r\n                case \"ffd8ffe0\":\r\n                case \"ffd8ffe1\":\r\n                case \"ffd8ffe2\":\r\n                    return \"image\/jpeg\";\r\n                case \"89504e47\":\r\n                    return \"image\/png\";\r\n                case \"47494638\":\r\n                    return \"image\/gif\";\r\n                case \"49492a00\":\r\n                    return \"image\/tiff\";\r\n                case \"52494646\":\r\n                    return \"image\/webp\";\r\n                case \"66747970\":\r\n                    return \"video\/3gp\";\r\n                case \"4f676753\":\r\n                    return \"video\/ogg\";\r\n                case \"1a45dfa3\":\r\n                    return \"video\/mkv\";\r\n                case \"000001ba\":\r\n                case \"000001b3\":\r\n                    return \"video\/mpeg\";\r\n                case \"3026b275\":\r\n                    return \"video\/wmv\";\r\n                case \"25504446\":\r\n                    return \"application\/pdf\";\r\n                case \"25215053\":\r\n                    return \"application\/ps\";\r\n                case \"504b0304\":\r\n                case \"504b0506\":\r\n                case \"504b0508\":\r\n                    return \"application\/zip\";\r\n                case \"377abcaf\":\r\n                    return \"application\/7z\";\r\n                case \"75737461\":\r\n                    return \"application\/tar\";\r\n                case \"7801730d\":\r\n                    return \"application\/dmg\";\r\n                default:\r\n                    switch (e.substring(0, 6)) {\r\n                        case \"435753\":\r\n                            return \"application\/x-shockwave-flash\";\r\n                        case \"494433\":\r\n                            return \"audio\/mp3\";\r\n                        case \"425a68\":\r\n                            return \"application\/bzip\";\r\n                        default:\r\n                            switch (e.substring(0, 4)) {\r\n                                case \"424d\":\r\n                                    return \"image\/bmp\";\r\n                                case \"fffb\":\r\n                                    return \"audio\/mp3\";\r\n                                case \"4d5a\":\r\n                                    return \"application\/exe\";\r\n                                case \"1f9d\":\r\n                                case \"1fa0\":\r\n                                    return \"application\/zip\";\r\n                                case \"1f8b\":\r\n                                    return \"application\/gzip\";\r\n                                default:\r\n                                    return t && !t.match(\/[^\\u0000-\\u007f]\/) ? \"application\/text-plain\" : i\r\n                            }\r\n                    }\r\n            }\r\n        },\r\n        addCss: function(e, t) {\r\n            e.removeClass(t).addClass(t)\r\n        },\r\n        getElement: function(i, a, r) {\r\n            return t.isEmpty(i) || t.isEmpty(i[a]) ? r : e(i[a])\r\n        },\r\n        createElement: function(t, i) {\r\n            return i = i || \"div\", e(e.parseHTML(\"<\" + i + \">\" + t + \"<\/\" + i + \">\"))\r\n        },\r\n        uniqId: function() {\r\n            return ((new Date).getTime() + Math.floor(Math.random() * Math.pow(10, 15))).toString(36)\r\n        },\r\n        cspBuffer: {\r\n            CSP_ATTRIB: \"data-csp-01928735\",\r\n            domElementsStyles: {},\r\n            stash: function(i) {\r\n                var a = this,\r\n                    r = e.parseHTML(\"<div>\" + i + \"<\/div>\"),\r\n                    s = e(r);\r\n                return s.find(\"[style]\").each(function(i, r) {\r\n                    var s = e(r),\r\n                        n = s[0].style,\r\n                        o = t.uniqId(),\r\n                        l = {};\r\n                    n && n.length && (e(n).each(function() {\r\n                        l[this] = n[this]\r\n                    }), a.domElementsStyles[o] = l, s.removeAttr(\"style\").attr(a.CSP_ATTRIB, o))\r\n                }), s.filter(\"*\").removeAttr(\"style\"), (Object.values ? Object.values(r) : Object.keys(r).map(function(e) {\r\n                    return r[e]\r\n                })).flatMap(function(e) {\r\n                    return e.innerHTML\r\n                }).join(\"\")\r\n            },\r\n            apply: function(t) {\r\n                var i = this;\r\n                e(t).find(\"[\" + i.CSP_ATTRIB + \"]\").each(function(t, a) {\r\n                    var r = e(a),\r\n                        s = r.attr(i.CSP_ATTRIB),\r\n                        n = i.domElementsStyles[s];\r\n                    n && r.css(n), r.removeAttr(i.CSP_ATTRIB)\r\n                }), i.domElementsStyles = {}\r\n            }\r\n        },\r\n        setHtml: function(e, i) {\r\n            var a = t.cspBuffer;\r\n            return e.html(a.stash(i)), a.apply(e), e\r\n        },\r\n        htmlEncode: function(e, t) {\r\n            return void 0 === e ? t || null : e.replace(\/&\/g, \"&amp;\").replace(\/<\/g, \"&lt;\").replace(\/>\/g, \"&gt;\").replace(\/\"\/g, \"&quot;\").replace(\/'\/g, \"&apos;\")\r\n        },\r\n        replaceTags: function(t, i) {\r\n            var a = t;\r\n            return i ? (e.each(i, function(e, t) {\r\n                \"function\" == typeof t && (t = t()), a = a.split(e).join(t)\r\n            }), a) : a\r\n        },\r\n        cleanMemory: function(e) {\r\n            var i = e.is(\"img\") ? e.attr(\"src\") : e.find(\"source\").attr(\"src\");\r\n            t.revokeObjectURL(i)\r\n        },\r\n        findFileName: function(e) {\r\n            var t = e.lastIndexOf(\"\/\");\r\n            return -1 === t && (t = e.lastIndexOf(\"\\\\\")), e.split(e.substring(t, t + 1)).pop()\r\n        },\r\n        checkFullScreen: function() {\r\n            return document.fullscreenElement || document.mozFullScreenElement || document.webkitFullscreenElement || document.msFullscreenElement\r\n        },\r\n        toggleFullScreen: function(e) {\r\n            var i = document,\r\n                a = i.documentElement,\r\n                r = t.checkFullScreen();\r\n            a && e && !r ? a.requestFullscreen ? a.requestFullscreen() : a.msRequestFullscreen ? a.msRequestFullscreen() : a.mozRequestFullScreen ? a.mozRequestFullScreen() : a.webkitRequestFullscreen && a.webkitRequestFullscreen(Element.ALLOW_KEYBOARD_INPUT) : r && (i.exitFullscreen ? i.exitFullscreen() : i.msExitFullscreen ? i.msExitFullscreen() : i.mozCancelFullScreen ? i.mozCancelFullScreen() : i.webkitExitFullscreen && i.webkitExitFullscreen())\r\n        },\r\n        moveArray: function(t, i, a, r) {\r\n            var s = e.extend(!0, [], t);\r\n            if (r && s.reverse(), a >= s.length)\r\n                for (var n = a - s.length; 1 + n--;) s.push(void 0);\r\n            return s.splice(a, 0, s.splice(i, 1)[0]), r && s.reverse(), s\r\n        },\r\n        closeButton: function(e) {\r\n            return '<button type=\"button\" class=\"' + (e = (t.isBs(5) ? \"btn-close\" : \"close\") + (e ? \" \" + e : \"\")) + '\" aria-label=\"Close\">\\n' + (t.isBs(5) ? \"\" : '  <span aria-hidden=\"true\">&times;<\/span>\\n') + \"<\/button>\"\r\n        },\r\n        getRotation: function(e) {\r\n            switch (e) {\r\n                case 2:\r\n                    return \"rotateY(180deg)\";\r\n                case 3:\r\n                    return \"rotate(180deg)\";\r\n                case 4:\r\n                    return \"rotate(180deg) rotateY(180deg)\";\r\n                case 5:\r\n                    return \"rotate(270deg) rotateY(180deg)\";\r\n                case 6:\r\n                    return \"rotate(90deg)\";\r\n                case 7:\r\n                    return \"rotate(90deg) rotateY(180deg)\";\r\n                case 8:\r\n                    return \"rotate(270deg)\";\r\n                default:\r\n                    return \"\"\r\n            }\r\n        },\r\n        setTransform: function(e, t) {\r\n            e && (e.style.transform = t, e.style.webkitTransform = t, e.style[\"-moz-transform\"] = t, e.style[\"-ms-transform\"] = t, e.style[\"-o-transform\"] = t)\r\n        },\r\n        getObjectKeys: function(t) {\r\n            var i = [];\r\n            return t && e.each(t, function(e) {\r\n                i.push(e)\r\n            }), i\r\n        },\r\n        getObjectSize: function(e) {\r\n            return t.getObjectKeys(e).length\r\n        },\r\n        whenAll: function(i) {\r\n            var a, r, s, n, o, l, d = [].slice,\r\n                c = 1 === arguments.length && t.isArray(i) ? i : d.call(arguments),\r\n                u = e.Deferred(),\r\n                p = 0,\r\n                f = c.length,\r\n                h = f;\r\n            for (s = n = o = Array(f), l = function(e, t, i) {\r\n                    return function() {\r\n                        i !== c && p++, u.notifyWith(t[e] = this, i[e] = d.call(arguments)), --h || u[(p ? \"reject\" : \"resolve\") + \"With\"](t, i)\r\n                    }\r\n                }, a = 0; a < f; a++)(r = c[a]) && e.isFunction(r.promise) ? r.promise().done(l(a, o, c)).fail(l(a, s, n)) : (u.notifyWith(this, r), --h);\r\n            return h || u.resolveWith(o, c), u.promise()\r\n        }\r\n    }, (i = function(i, a) {\r\n        this.$element = e(i), this.$parent = this.$element.parent(), this._validate() && (this.isPreviewable = t.hasFileAPISupport(), this.isIE9 = t.isIE(9), this.isIE10 = t.isIE(10), (this.isPreviewable || this.isIE9) && (this._init(a), this._listen()), this.$element.removeClass(\"file-loading\"))\r\n    }).prototype = {\r\n        constructor: i,\r\n        _cleanup: function() {\r\n            this.reader = null, this.clearFileStack(), this.fileBatchCompleted = !0, this.isError = !1, this.isDuplicateError = !1, this.isPersistentError = !1, this.cancelling = !1, this.paused = !1, this.lastProgress = 0, this._initAjax()\r\n        },\r\n        _isAborted: function() {\r\n            return this.cancelling || this.paused\r\n        },\r\n        _initAjax: function() {\r\n            var i = this.taskManager = {\r\n                pool: {},\r\n                addPool: function(e) {\r\n                    return i.pool[e] = new i.TasksPool(e)\r\n                },\r\n                getPool: function(e) {\r\n                    return i.pool[e]\r\n                },\r\n                addTask: function(e, t) {\r\n                    return new i.Task(e, t)\r\n                },\r\n                TasksPool: function(a) {\r\n                    var r = this;\r\n                    r.id = a, r.cancelled = !1, r.cancelledDeferrer = e.Deferred(), r.tasks = {}, r.addTask = function(e, t) {\r\n                        return r.tasks[e] = new i.Task(e, t)\r\n                    }, r.size = function() {\r\n                        return t.getObjectSize(r.tasks)\r\n                    }, r.run = function(i) {\r\n                        var a, s, n, o = 0,\r\n                            l = !1,\r\n                            d = t.getObjectKeys(r.tasks).map(function(e) {\r\n                                return r.tasks[e]\r\n                            }),\r\n                            c = [],\r\n                            u = e.Deferred();\r\n                        if (r.cancelled) return r.cancelledDeferrer.resolve(), u.reject();\r\n                        if (!i) {\r\n                            var p = t.getObjectKeys(r.tasks).map(function(e) {\r\n                                return r.tasks[e].deferred\r\n                            });\r\n                            return t.whenAll(p).done(function() {\r\n                                var e = t.getArray(arguments);\r\n                                r.cancelled ? (u.reject.apply(null, e), r.cancelledDeferrer.resolve()) : (u.resolve.apply(null, e), r.cancelledDeferrer.reject())\r\n                            }).fail(function() {\r\n                                var e = t.getArray(arguments);\r\n                                u.reject.apply(null, e), r.cancelled ? r.cancelledDeferrer.resolve() : r.cancelledDeferrer.reject()\r\n                            }), e.each(r.tasks, function(e) {\r\n                                (a = r.tasks[e]).run()\r\n                            }), u\r\n                        }\r\n                        for (s = function(t) {\r\n                                e.when(t.deferred).fail(function() {\r\n                                    l = !0, n.apply(null, arguments)\r\n                                }).always(n)\r\n                            }, n = function() {\r\n                                var e = t.getArray(arguments);\r\n                                if (u.notify(e), c.push(e), r.cancelled) return u.reject.apply(null, c), void r.cancelledDeferrer.resolve();\r\n                                c.length === r.size() && (l ? u.reject.apply(null, c) : u.resolve.apply(null, c)), d.length && (a = d.shift(), s(a), a.run())\r\n                            }; d.length && o++ < i;) a = d.shift(), s(a), a.run();\r\n                        return u\r\n                    }, r.cancel = function() {\r\n                        return r.cancelled = !0, r.cancelledDeferrer\r\n                    }\r\n                },\r\n                Task: function(i, a) {\r\n                    var r = this;\r\n                    r.id = i, r.deferred = e.Deferred(), r.logic = a, r.context = null, r.run = function() {\r\n                        var e = t.getArray(arguments);\r\n                        return e.unshift(r.deferred), a.apply(r.context, e), r.deferred\r\n                    }, r.runWithContext = function(e) {\r\n                        return r.context = e, r.run()\r\n                    }\r\n                }\r\n            };\r\n            this.ajaxQueue = [], this.ajaxRequests = [], this.ajaxAborted = !1\r\n        },\r\n        _init: function(i, a) {\r\n            var r, s, n, o, l = this,\r\n                d = l.$element;\r\n            l.options = i, l.canOrientImage = t.canOrientImage(d), e.each(i, function(e, i) {\r\n                switch (e) {\r\n                    case \"minFileCount\":\r\n                    case \"maxFileCount\":\r\n                    case \"maxTotalFileCount\":\r\n                    case \"minFileSize\":\r\n                    case \"maxFileSize\":\r\n                    case \"maxFilePreviewSize\":\r\n                    case \"resizeQuality\":\r\n                    case \"resizeIfSizeMoreThan\":\r\n                    case \"progressUploadThreshold\":\r\n                    case \"initialPreviewCount\":\r\n                    case \"zoomModalHeight\":\r\n                    case \"minImageHeight\":\r\n                    case \"maxImageHeight\":\r\n                    case \"minImageWidth\":\r\n                    case \"maxImageWidth\":\r\n                    case \"bytesToKB\":\r\n                        l[e] = t.getNum(i);\r\n                        break;\r\n                    default:\r\n                        l[e] = i\r\n                }\r\n            }), (!l.bytesToKB || l.bytesToKB <= 0) && (l.bytesToKB = 1024), void 0 === l.errorCloseButton && (l.errorCloseButton = t.closeButton(\"kv-error-close\" + (t.isBs(5) ? \"  float-end\" : \"\"))), l.maxTotalFileCount > 0 && l.maxTotalFileCount < l.maxFileCount && (l.maxTotalFileCount = l.maxFileCount), l.rtl && (o = l.previewZoomButtonIcons.prev, l.previewZoomButtonIcons.prev = l.previewZoomButtonIcons.next, l.previewZoomButtonIcons.next = o), !isNaN(l.maxAjaxThreads) && l.maxAjaxThreads < l.resumableUploadOptions.maxThreads && (l.resumableUploadOptions.maxThreads = l.maxAjaxThreads), l._initFileManager(), \"function\" == typeof l.autoOrientImage && (l.autoOrientImage = l.autoOrientImage()), \"function\" == typeof l.autoOrientImageInitial && (l.autoOrientImageInitial = l.autoOrientImageInitial()), a || l._cleanup(), l.duplicateErrors = [], l.$form = d.closest(\"form\"), l._initTemplateDefaults(), l.uploadFileAttr = t.isEmpty(d.attr(\"name\")) ? \"file_data\" : d.attr(\"name\"), n = l._getLayoutTemplate(\"progress\"), l.progressTemplate = n.replace(\"{class}\", l.progressClass), l.progressInfoTemplate = n.replace(\"{class}\", l.progressInfoClass), l.progressPauseTemplate = n.replace(\"{class}\", l.progressPauseClass), l.progressCompleteTemplate = n.replace(\"{class}\", l.progressCompleteClass), l.progressErrorTemplate = n.replace(\"{class}\", l.progressErrorClass), l.isDisabled = d.attr(\"disabled\") || d.attr(\"readonly\"), l.isDisabled && d.attr(\"disabled\", !0), l.isClickable = l.browseOnZoneClick && l.showPreview && (l.dropZoneEnabled || !t.isEmpty(l.defaultPreviewContent)), l.isAjaxUpload = t.hasFileUploadSupport() && !t.isEmpty(l.uploadUrl), l.dropZoneEnabled = t.hasDragDropSupport() && l.dropZoneEnabled, l.isAjaxUpload || (l.dropZoneEnabled = l.dropZoneEnabled && t.canAssignFilesToInput()), l.slug = \"function\" == typeof i.slugCallback ? i.slugCallback : l._slugDefault, l.mainTemplate = l.showCaption ? l._getLayoutTemplate(\"main1\") : l._getLayoutTemplate(\"main2\"), l.captionTemplate = l._getLayoutTemplate(\"caption\"), l.previewGenericTemplate = l._getPreviewTemplate(\"generic\"), !l.imageCanvas && l.resizeImage && (l.maxImageWidth || l.maxImageHeight) && (l.imageCanvas = document.createElement(\"canvas\"), l.imageCanvasContext = l.imageCanvas.getContext(\"2d\")), t.isEmpty(d.attr(\"id\")) && d.attr(\"id\", t.uniqId()), l.namespace = \".fileinput_\" + d.attr(\"id\").replace(\/-\/g, \"_\"), void 0 === l.$container ? l.$container = l._createContainer() : l._refreshContainer(), s = l.$container, l.$dropZone = s.find(\".file-drop-zone\"), l.$progress = s.find(\".kv-upload-progress\"), l.$btnUpload = s.find(\".fileinput-upload\"), l.$captionContainer = t.getElement(i, \"elCaptionContainer\", s.find(\".file-caption\")), l.$caption = t.getElement(i, \"elCaptionText\", s.find(\".file-caption-name\")), t.isEmpty(l.msgPlaceholder) || (r = d.attr(\"multiple\") ? l.filePlural : l.fileSingle, l.$caption.attr(\"placeholder\", l.msgPlaceholder.replace(\"{files}\", r))), l.$captionIcon = l.$captionContainer.find(\".file-caption-icon\"), l.$previewContainer = t.getElement(i, \"elPreviewContainer\", s.find(\".file-preview\")), l.$preview = t.getElement(i, \"elPreviewImage\", s.find(\".file-preview-thumbnails\")), l.$previewStatus = t.getElement(i, \"elPreviewStatus\", s.find(\".file-preview-status\")), l.$errorContainer = t.getElement(i, \"elErrorContainer\", l.$previewContainer.find(\".kv-fileinput-error\")), l._validateDisabled(), t.isEmpty(l.msgErrorClass) || t.addCss(l.$errorContainer, l.msgErrorClass), a ? l._errorsExist() || l.$errorContainer.hide() : (l._resetErrors(), l.$errorContainer.hide(), l.previewInitId = \"thumb-\" + d.attr(\"id\"), l._initPreviewCache(), l._initPreview(!0), l._initPreviewActions(), l.$parent.hasClass(\"file-loading\") && (l.$container.insertBefore(l.$parent), l.$parent.remove())), l._setFileDropZoneTitle(), d.attr(\"disabled\") && l.disable(), l._initZoom(), l.hideThumbnailContent && t.addCss(l.$preview, \"hide-content\")\r\n        },\r\n        _initFileManager: function() {\r\n            var i = this;\r\n            i.uploadStartTime = t.now(), i.fileManager = {\r\n                stack: {},\r\n                filesProcessed: [],\r\n                errors: [],\r\n                loadedImages: {},\r\n                totalImages: 0,\r\n                totalFiles: null,\r\n                totalSize: null,\r\n                uploadedSize: 0,\r\n                stats: {},\r\n                bpsLog: [],\r\n                bps: 0,\r\n                initStats: function(e) {\r\n                    var a = {\r\n                        started: t.now()\r\n                    };\r\n                    e ? i.fileManager.stats[e] = a : i.fileManager.stats = a\r\n                },\r\n                getUploadStats: function(e, a, r) {\r\n                    var s, n = i.fileManager,\r\n                        o = e ? n.stats[e] && n.stats[e].started || t.now() : i.uploadStartTime,\r\n                        l = (t.now() - o) \/ 1e3,\r\n                        d = Math.ceil(l ? a \/ l : 0),\r\n                        c = r - a,\r\n                        u = n.bpsLog.length ? i.bitrateUpdateDelay : 0;\r\n                    return setTimeout(function() {\r\n                        var e, t, i, a = 0,\r\n                            r = 0;\r\n                        for (n.bpsLog.push(d), n.bpsLog.sort(function(e, t) {\r\n                                return e - t\r\n                            }), i = (t = n.bpsLog.length) > 10 ? t - 10 : Math.ceil(t \/ 2), e = t; e > i; e--) r = parseFloat(n.bpsLog[e]), a++;\r\n                        n.bps = 64 * (a > 0 ? r \/ a : 0)\r\n                    }, u), s = {\r\n                        fileId: e,\r\n                        started: o,\r\n                        elapsed: l,\r\n                        loaded: a,\r\n                        total: r,\r\n                        bps: n.bps,\r\n                        bitrate: i._getSize(n.bps, i.bitRateUnits),\r\n                        pendingBytes: c\r\n                    }, e ? n.stats[e] = s : n.stats = s, s\r\n                },\r\n                exists: function(t) {\r\n                    return -1 !== e.inArray(t, i.fileManager.getIdList())\r\n                },\r\n                count: function() {\r\n                    return i.fileManager.getIdList().length\r\n                },\r\n                total: function() {\r\n                    var e = i.fileManager;\r\n                    return e.totalFiles || (e.totalFiles = e.count()), e.totalFiles\r\n                },\r\n                getTotalSize: function() {\r\n                    var t = i.fileManager;\r\n                    return t.totalSize ? t.totalSize : (t.totalSize = 0, e.each(i.getFileStack(), function(e, i) {\r\n                        var a = parseFloat(i.size);\r\n                        t.totalSize += isNaN(a) ? 0 : a\r\n                    }), t.totalSize)\r\n                },\r\n                add: function(e, a) {\r\n                    a || (a = i.fileManager.getId(e)), a && (i.fileManager.stack[a] = {\r\n                        file: e,\r\n                        name: t.getFileName(e),\r\n                        relativePath: t.getFileRelativePath(e),\r\n                        size: e.size,\r\n                        nameFmt: i._getFileName(e, \"\"),\r\n                        sizeFmt: i._getSize(e.size)\r\n                    })\r\n                },\r\n                remove: function(e) {\r\n                    var t = i._getThumbFileId(e);\r\n                    i.fileManager.removeFile(t)\r\n                },\r\n                removeFile: function(e) {\r\n                    var t = i.fileManager;\r\n                    e && (delete t.stack[e], delete t.loadedImages[e])\r\n                },\r\n                move: function(t, a) {\r\n                    var r = {},\r\n                        s = i.fileManager.stack;\r\n                    (t || a) && t !== a && (e.each(s, function(e, i) {\r\n                        e !== t && (r[e] = i), e === a && (r[t] = s[t])\r\n                    }), i.fileManager.stack = r)\r\n                },\r\n                list: function() {\r\n                    var t = [];\r\n                    return e.each(i.getFileStack(), function(e, i) {\r\n                        i && i.file && t.push(i.file)\r\n                    }), t\r\n                },\r\n                isPending: function(t) {\r\n                    return -1 === e.inArray(t, i.fileManager.filesProcessed) && i.fileManager.exists(t)\r\n                },\r\n                isProcessed: function() {\r\n                    var t = !0,\r\n                        a = i.fileManager;\r\n                    return e.each(i.getFileStack(), function(e) {\r\n                        a.isPending(e) && (t = !1)\r\n                    }), t\r\n                },\r\n                clear: function() {\r\n                    var e = i.fileManager;\r\n                    i.isDuplicateError = !1, i.isPersistentError = !1, e.totalFiles = null, e.totalSize = null, e.uploadedSize = 0, e.stack = {}, e.errors = [], e.filesProcessed = [], e.stats = {}, e.bpsLog = [], e.bps = 0, e.clearImages()\r\n                },\r\n                clearImages: function() {\r\n                    i.fileManager.loadedImages = {}, i.fileManager.totalImages = 0\r\n                },\r\n                addImage: function(e, t) {\r\n                    i.fileManager.loadedImages[e] = t\r\n                },\r\n                removeImage: function(e) {\r\n                    delete i.fileManager.loadedImages[e]\r\n                },\r\n                getImageIdList: function() {\r\n                    return t.getObjectKeys(i.fileManager.loadedImages)\r\n                },\r\n                getImageCount: function() {\r\n                    return i.fileManager.getImageIdList().length\r\n                },\r\n                getId: function(e) {\r\n                    return i._getFileId(e)\r\n                },\r\n                getIndex: function(e) {\r\n                    return i.fileManager.getIdList().indexOf(e)\r\n                },\r\n                getThumb: function(t) {\r\n                    var a = null;\r\n                    return i._getThumbs().each(function() {\r\n                        var r = e(this);\r\n                        i._getThumbFileId(r) === t && (a = r)\r\n                    }), a\r\n                },\r\n                getThumbIndex: function(e) {\r\n                    var t = i._getThumbFileId(e);\r\n                    return i.fileManager.getIndex(t)\r\n                },\r\n                getIdList: function() {\r\n                    return t.getObjectKeys(i.fileManager.stack)\r\n                },\r\n                getFile: function(e) {\r\n                    return i.fileManager.stack[e] || null\r\n                },\r\n                getFileName: function(e, t) {\r\n                    var a = i.fileManager.getFile(e);\r\n                    return a ? t ? a.nameFmt || \"\" : a.name || \"\" : \"\"\r\n                },\r\n                getFirstFile: function() {\r\n                    var e = i.fileManager.getIdList(),\r\n                        t = e && e.length ? e[0] : null;\r\n                    return i.fileManager.getFile(t)\r\n                },\r\n                setFile: function(e, t) {\r\n                    i.fileManager.getFile(e) ? i.fileManager.stack[e].file = t : i.fileManager.add(t, e)\r\n                },\r\n                setProcessed: function(e) {\r\n                    i.fileManager.filesProcessed.push(e)\r\n                },\r\n                getProgress: function() {\r\n                    var e = i.fileManager.total(),\r\n                        t = i.fileManager.filesProcessed.length;\r\n                    return e ? Math.ceil(t \/ e * 100) : 0\r\n                },\r\n                setProgress: function(e, t) {\r\n                    var a = i.fileManager.getFile(e);\r\n                    !isNaN(t) && a && (a.progress = t)\r\n                }\r\n            }\r\n        },\r\n        _setUploadData: function(i, a) {\r\n            var r = this;\r\n            e.each(a, function(e, a) {\r\n                var s = r.uploadParamNames[e] || e;\r\n                t.isArray(a) ? i.append(s, a[0], a[1]) : i.append(s, a)\r\n            })\r\n        },\r\n        _initResumableUpload: function() {\r\n            var i, a = this,\r\n                r = a.resumableUploadOptions,\r\n                s = t.logMessages,\r\n                n = a.fileManager;\r\n            if (a.enableResumableUpload)\r\n                if (!1 !== r.fallback && \"function\" != typeof r.fallback && (r.fallback = function(e) {\r\n                        e._log(s.noResumableSupport), e.enableResumableUpload = !1\r\n                    }), t.hasResumableUploadSupport() || !1 === r.fallback) {\r\n                    if (!a.uploadUrl && a.enableResumableUpload) return a._log(s.noUploadUrl), void(a.enableResumableUpload = !1);\r\n                    if (r.chunkSize = parseFloat(r.chunkSize), r.chunkSize <= 0 || isNaN(r.chunkSize)) return a._log(s.invalidChunkSize, {\r\n                        chunkSize: r.chunkSize\r\n                    }), void(a.enableResumableUpload = !1);\r\n                    (i = a.resumableManager = {\r\n                        init: function(e, t, s) {\r\n                            i.logs = [], i.stack = [], i.error = \"\", i.id = e, i.file = t.file, i.fileName = t.name, i.fileIndex = s, i.completed = !1, i.lastProgress = 0, a.showPreview && (i.$thumb = n.getThumb(e) || null, i.$progress = i.$btnDelete = null, i.$thumb && i.$thumb.length && (i.$progress = i.$thumb.find(\".file-thumb-progress\"), i.$btnDelete = i.$thumb.find(\".kv-file-remove\"))), i.chunkSize = r.chunkSize * a.bytesToKB, i.chunkCount = i.getTotalChunks()\r\n                        },\r\n                        setAjaxError: function(e, t, n, o) {\r\n                            e.responseJSON && e.responseJSON.error && (n = e.responseJSON.error.toString()), o || (i.error = n), r.showErrorLog && a._log(s.ajaxError, {\r\n                                status: e.status,\r\n                                error: n,\r\n                                text: e.responseText || \"\"\r\n                            })\r\n                        },\r\n                        reset: function() {\r\n                            i.stack = [], i.chunksProcessed = {}\r\n                        },\r\n                        setProcessed: function(t) {\r\n                            var s, o, l = i.id,\r\n                                d = i.$thumb,\r\n                                c = i.$progress,\r\n                                u = d && d.length,\r\n                                p = {\r\n                                    id: u ? d.attr(\"id\") : \"\",\r\n                                    index: n.getIndex(l),\r\n                                    fileId: l\r\n                                },\r\n                                f = a.resumableUploadOptions.skipErrorsAndProceed;\r\n                            i.completed = !0, i.lastProgress = 0, u && d.removeClass(\"file-uploading\"), \"success\" === t ? (n.uploadedSize += i.file.size, a.showPreview && (a._setProgress(101, c), a._setThumbStatus(d, \"Success\"), a._initUploadSuccess(i.chunksProcessed[l].data, d)), n.removeFile(l), delete i.chunksProcessed[l], a._raise(\"fileuploaded\", [p.id, p.index, p.fileId]), n.isProcessed() && a._setProgress(101)) : \"cancel\" !== t && (a.showPreview && (a._setThumbStatus(d, \"Error\"), a._setPreviewError(d, !0), a._setProgress(101, c, a.msgProgressError), a._setProgress(101, a.$progress, a.msgProgressError), a.cancelling = !f), a.$errorContainer.find('li[data-file-id=\"' + p.fileId + '\"]').length || (o = {\r\n                                file: i.fileName,\r\n                                max: r.maxRetries,\r\n                                error: i.error\r\n                            }, s = a.msgResumableUploadRetriesExceeded.setTokens(o), e.extend(p, o), a._showFileError(s, p, \"filemaxretries\"), f && (n.removeFile(l), delete i.chunksProcessed[l], n.isProcessed() && a._setProgress(101)))), n.isProcessed() && i.reset()\r\n                        },\r\n                        check: function() {\r\n                            e.each(i.logs, function(e, t) {\r\n                                if (!t) return !1, !1\r\n                            })\r\n                        },\r\n                        processedResumables: function() {\r\n                            var e, t = i.logs,\r\n                                a = 0;\r\n                            if (!t || !t.length) return 0;\r\n                            for (e = 0; e < t.length; e++) !0 === t[e] && a++;\r\n                            return a\r\n                        },\r\n                        getUploadedSize: function() {\r\n                            var e = i.processedResumables() * i.chunkSize;\r\n                            return e > i.file.size ? i.file.size : e\r\n                        },\r\n                        getTotalChunks: function() {\r\n                            var e = parseFloat(i.chunkSize);\r\n                            return !isNaN(e) && e > 0 ? Math.ceil(i.file.size \/ e) : 0\r\n                        },\r\n                        getProgress: function() {\r\n                            var e = i.processedResumables(),\r\n                                t = i.chunkCount;\r\n                            return 0 === t ? 0 : Math.ceil(e \/ t * 100)\r\n                        },\r\n                        checkAborted: function(e) {\r\n                            a._isAborted() && (clearInterval(e), a.unlock())\r\n                        },\r\n                        upload: function() {\r\n                            var e, r = n.getIdList(),\r\n                                s = \"new\";\r\n                            e = setInterval(function() {\r\n                                var o;\r\n                                if (i.checkAborted(e), \"new\" === s && (a.lock(), s = \"processing\", o = r.shift(), n.initStats(o), n.stack[o] && (i.init(o, n.stack[o], n.getIndex(o)), i.processUpload())), !n.isPending(o) && i.completed && (s = \"new\"), n.isProcessed()) {\r\n                                    var l = a.$preview.find(\".file-preview-initial\");\r\n                                    l.length && (t.addCss(l, t.SORT_CSS), a._initSortable()), clearInterval(e), a._clearFileInput(), a.unlock(), setTimeout(function() {\r\n                                        var e = a.previewCache.data;\r\n                                        e && (a.initialPreview = e.content, a.initialPreviewConfig = e.config, a.initialPreviewThumbTags = e.tags), a._raise(\"filebatchuploadcomplete\", [a.initialPreview, a.initialPreviewConfig, a.initialPreviewThumbTags, a._getExtraData()])\r\n                                    }, a.processDelay)\r\n                                }\r\n                            }, a.processDelay)\r\n                        },\r\n                        uploadResumable: function() {\r\n                            var e, t, s = a.taskManager,\r\n                                n = i.chunkCount;\r\n                            for (t = s.addPool(i.id), e = 0; e < n; e++) i.logs[e] = !(!i.chunksProcessed[i.id] || !i.chunksProcessed[i.id][e]), i.logs[e] || i.pushAjax(e, 0);\r\n                            t.run(r.maxThreads).done(function() {\r\n                                i.setProcessed(\"success\")\r\n                            }).fail(function() {\r\n                                i.setProcessed(t.cancelled ? \"cancel\" : \"error\")\r\n                            })\r\n                        },\r\n                        processUpload: function() {\r\n                            var s, o, l, d, c, u, p, f = i.id;\r\n                            r.testUrl ? (s = new FormData, o = n.stack[f], a._setUploadData(s, {\r\n                                fileId: f,\r\n                                fileName: o.fileName,\r\n                                fileSize: o.size,\r\n                                fileRelativePath: o.relativePath,\r\n                                chunkSize: i.chunkSize,\r\n                                chunkCount: i.chunkCount\r\n                            }), l = function(e) {\r\n                                p = a._getOutData(s, e), a._raise(\"filetestbeforesend\", [f, n, i, p])\r\n                            }, d = function(r, o, l) {\r\n                                p = a._getOutData(s, l, r);\r\n                                var d = a.uploadParamNames.chunksUploaded || \"chunksUploaded\",\r\n                                    c = [f, n, i, p];\r\n                                r[d] && t.isArray(r[d]) ? (i.chunksProcessed[f] || (i.chunksProcessed[f] = {}), e.each(r[d], function(e, t) {\r\n                                    i.logs[t] = !0, i.chunksProcessed[f][t] = !0\r\n                                }), i.chunksProcessed[f].data = r, a._raise(\"filetestsuccess\", c)) : a._raise(\"filetesterror\", c), i.uploadResumable()\r\n                            }, c = function(e, t, r) {\r\n                                p = a._getOutData(s, e), a._raise(\"filetestajaxerror\", [f, n, i, p]), i.setAjaxError(e, t, r, !0), i.uploadResumable()\r\n                            }, u = function() {\r\n                                a._raise(\"filetestcomplete\", [f, n, i, a._getOutData(s)])\r\n                            }, a._ajaxSubmit(l, d, u, c, s, f, i.fileIndex, r.testUrl)) : i.uploadResumable()\r\n                        },\r\n                        pushAjax: function(e, t) {\r\n                            var r = a.taskManager.getPool(i.id);\r\n                            r.addTask(r.size() + 1, function(e) {\r\n                                var t, r = i.stack.shift();\r\n                                t = r[0], i.chunksProcessed[i.id] && i.chunksProcessed[i.id][t] ? a._log(s.chunkQueueError, {\r\n                                    index: t\r\n                                }) : i.sendAjax(t, r[1], e)\r\n                            }), i.stack.push([e, t])\r\n                        },\r\n                        sendAjax: function(e, o, l) {\r\n                            var d, c = i.chunkSize,\r\n                                u = i.id,\r\n                                p = i.file,\r\n                                f = i.$thumb,\r\n                                h = t.logMessages,\r\n                                m = i.$btnDelete,\r\n                                g = function(e, t) {\r\n                                    t && (e = e.setTokens(t)), e = h.resumableRequestError.setTokens({\r\n                                        msg: e\r\n                                    }), a._log(e), l.reject(e)\r\n                                };\r\n                            if (!i.chunksProcessed[u] || !i.chunksProcessed[u][e]) {\r\n                                if (o > r.maxRetries) return g(h.resumableMaxRetriesReached, {\r\n                                    n: r.maxRetries\r\n                                }), void i.setProcessed(\"error\");\r\n                                var v, w, b, _, C, x, y = p[p.slice ? \"slice\" : p.mozSlice ? \"mozSlice\" : p.webkitSlice ? \"webkitSlice\" : \"slice\"](c * e, c * (e + 1));\r\n                                v = new FormData, d = n.stack[u], a._setUploadData(v, {\r\n                                    chunkCount: i.chunkCount,\r\n                                    chunkIndex: e,\r\n                                    chunkSize: c,\r\n                                    chunkSizeStart: c * e,\r\n                                    fileBlob: [y, i.fileName],\r\n                                    fileId: u,\r\n                                    fileName: i.fileName,\r\n                                    fileRelativePath: d.relativePath,\r\n                                    fileSize: p.size,\r\n                                    retryCount: o\r\n                                }), i.$progress && i.$progress.length && i.$progress.show(), b = function(r) {\r\n                                    w = a._getOutData(v, r), a.showPreview && (f.hasClass(\"file-preview-success\") || (a._setThumbStatus(f, \"Loading\"), t.addCss(f, \"file-uploading\")), m.attr(\"disabled\", !0)), a._raise(\"filechunkbeforesend\", [u, e, o, n, i, w])\r\n                                }, _ = function(t, d, c) {\r\n                                    if (a._isAborted()) g(h.resumableAborting);\r\n                                    else {\r\n                                        w = a._getOutData(v, c, t);\r\n                                        var p = a.uploadParamNames.chunkIndex || \"chunkIndex\",\r\n                                            f = [u, e, o, n, i, w];\r\n                                        t.error ? (r.showErrorLog && a._log(s.retryStatus, {\r\n                                            retry: o + 1,\r\n                                            filename: i.fileName,\r\n                                            chunk: e\r\n                                        }), a._raise(\"filechunkerror\", f), i.pushAjax(e, o + 1), i.error = t.error, g(t.error)) : (i.logs[t[p]] = !0, i.chunksProcessed[u] || (i.chunksProcessed[u] = {}), i.chunksProcessed[u][t[p]] = !0, i.chunksProcessed[u].data = t, l.resolve.call(null, t), a._raise(\"filechunksuccess\", f), i.check())\r\n                                    }\r\n                                }, C = function(t, r, s) {\r\n                                    a._isAborted() ? g(h.resumableAborting) : (w = a._getOutData(v, t), i.setAjaxError(t, r, s), a._raise(\"filechunkajaxerror\", [u, e, o, n, i, w]), i.pushAjax(e, o + 1), g(h.resumableRetryError, {\r\n                                        n: o - 1\r\n                                    }))\r\n                                }, x = function() {\r\n                                    a._isAborted() || a._raise(\"filechunkcomplete\", [u, e, o, n, i, a._getOutData(v)])\r\n                                }, a._ajaxSubmit(b, _, x, C, v, u, i.fileIndex)\r\n                            }\r\n                        }\r\n                    }).reset()\r\n                } else r.fallback(a)\r\n        },\r\n        _initTemplateDefaults: function() {\r\n            var i, a, r, s, n, o, l, d, c, u, p, f, h, m, g, v, w, b, _, C = this,\r\n                x = function(e, i) {\r\n                    return '<object class=\"kv-preview-data file-preview-' + e + '\" title=\"{caption}\" data=\"{data}\" type=\"' + i + '\"' + w + \">\\n\" + t.DEFAULT_PREVIEW + \"\\n<\/object>\\n\"\r\n                },\r\n                y = \"btn btn-sm btn-kv \" + t.defaultButtonCss();\r\n            i = '{preview}\\n<div class=\"kv-upload-progress kv-hidden\"><\/div><div class=\"clearfix\"><\/div>\\n<div class=\"file-caption {class}\">\\n  <div class=\"input-group {inputGroupClass}\">\\n      {caption}\\n<span class=\"file-caption-icon\"><\/span>\\n' + (t.isBs(5) ? \"\" : '<div class=\"input-group-btn input-group-append\">\\n') + \"      {remove}\\n      {cancel}\\n      {pause}\\n      {upload}\\n      {browse}\\n\" + (t.isBs(5) ? \"\" : \"    <\/div>\\n\") + \"  <\/div>\", a = t.closeButton(\"fileinput-remove\"), _ = t.MODAL_ID + \"Label\", r = '<div id=\"' + t.MODAL_ID + '\" class=\"file-zoom-dialog modal fade\" aria-labelledby=\"' + _ + '\" {tabIndexConfig}><\/div>', s = '<div class=\"modal-dialog modal-lg{rtl}\" role=\"document\">\\n  <div class=\"modal-content\">\\n    <div class=\"modal-header kv-zoom-header\">\\n      <h6 class=\"modal-title kv-zoom-title\" id=\"' + _ + '\"><span class=\"kv-zoom-caption\"><\/span> <span class=\"kv-zoom-size\"><\/span><\/h6>\\n      <div class=\"kv-zoom-actions\">{toggleheader}{fullscreen}{borderless}{close}<\/div>\\n    <\/div>\\n    <div class=\"floating-buttons\"><\/div>\\n    <div class=\"kv-zoom-body file-zoom-content {zoomFrameClass}\"><\/div>\\n{prev} {next}\\n    <div class=\"kv-zoom-description\"><\/div>\\n  <\/div>\\n<\/div>\\n', n = '<div class=\"file-preview-frame {frameClass}\" id=\"{previewId}\" data-fileindex=\"{fileindex}\" data-fileid=\"{fileid}\" data-template=\"{template}\" data-zoom=\"{zoomData}\"', w = \" {style}\", o = x(\"html\", \"text\/html\"), d = x(\"text\", \"text\/plain;charset=UTF-8\"), g = x(\"pdf\", \"application\/pdf\"), l = '<img decoding=\"async\" src=\"{data}\" class=\"file-preview-image kv-preview-data\" title=\"{title}\" alt=\"{alt}\"' + w + \">\\n\", c = '<iframe class=\"kv-preview-data file-preview-office\" src=\"https:\/\/view.officeapps.live.com\/op\/embed.aspx?src={data}\"' + w + \"><\/iframe>\", u = '<iframe class=\"kv-preview-data file-preview-gdocs\" src=\"https:\/\/docs.google.com\/gview?url={data}&embedded=true\"' + w + \"><\/iframe>\", p = '<video class=\"kv-preview-data file-preview-video\" controls' + w + '>\\n<source src=\"{data}\" type=\"{type}\">\\n' + t.DEFAULT_PREVIEW + \"\\n<\/video>\\n\", f = '\\x3c!--suppress ALL --\\x3e<audio class=\"kv-preview-data file-preview-audio\" controls' + w + '>\\n<source src=\"{data}\" type=\"{type}\">\\n' + t.DEFAULT_PREVIEW + \"\\n<\/audio>\\n\", h = '<embed class=\"kv-preview-data file-preview-flash\" src=\"{data}\" type=\"application\/x-shockwave-flash\"' + w + \">\\n\", m = '<object class=\"kv-preview-data file-preview-object file-object {typeCss}\" data=\"{data}\" type=\"{type}\"' + w + '>\\n<param name=\"movie\" value=\"{caption}\" \/>\\n' + t.OBJECT_PARAMS + \" \" + t.DEFAULT_PREVIEW + \"\\n<\/object>\\n\", v = '<div class=\"kv-preview-data file-preview-other-frame\"' + w + \">\\n\" + t.DEFAULT_PREVIEW + \"\\n<\/div>\\n\", b = {\r\n                width: \"100%\",\r\n                height: \"100%\",\r\n                \"min-height\": \"480px\"\r\n            }, C._isPdfRendered() && (g = C.pdfRendererTemplate.replace(\"{renderer}\", C._encodeURI(C.pdfRendererUrl))), C.defaults = {\r\n                layoutTemplates: {\r\n                    main1: i,\r\n                    main2: '{preview}\\n<div class=\"kv-upload-progress kv-hidden\"><\/div>\\n<div class=\"clearfix\"><\/div>\\n<span class=\"{class}\">{remove}\\n{cancel}\\n{upload}\\n{browse}\\n<\/span>',\r\n                    preview: '<div class=\"file-preview {class}\">\\n  {close}  <div class=\"{dropClass} clearfix\">\\n    <div class=\"file-preview-thumbnails clearfix\">\\n    <\/div>\\n    <div class=\"file-preview-status text-center text-success\"><\/div>\\n    <div class=\"kv-fileinput-error\"><\/div>\\n  <\/div>\\n<\/div>',\r\n                    close: a,\r\n                    fileIcon: '<i class=\"bi-file-earmark-arrow-up\"><\/i>',\r\n                    caption: '<input readonly class=\"file-caption-name form-control {class}\">\\n',\r\n                    modalMain: r,\r\n                    modal: s,\r\n                    descriptionClose: '<button type=\"button\" class=\"kv-desc-hide\" aria-label=\"Close\">{closeIcon}<\/button>',\r\n                    progress: '<div class=\"progress\">\\n    <div class=\"{class}\" role=\"progressbar\" aria-valuenow=\"{percent}\" aria-valuemin=\"0\" aria-valuemax=\"100\" style=\"width:{percent}%;\">\\n        {status}\\n     <\/div>\\n<\/div>{stats}',\r\n                    stats: '<div class=\"text-primary file-upload-stats\"><span class=\"pending-time\">{pendingTime}<\/span> <span class=\"upload-speed\">{uploadSpeed}<\/span><\/div>',\r\n                    size: \" <samp>({sizeText})<\/samp>\",\r\n                    footer: '<div class=\"file-thumbnail-footer\">\\n    <div class=\"file-footer-caption\" title=\"{caption}\">\\n        <div class=\"file-caption-info\">{caption}<\/div>\\n        <div class=\"file-size-info\">{size}<\/div>\\n    <\/div>\\n    {progress}\\n{indicator}\\n{actions}\\n<\/div>',\r\n                    indicator: '<div class=\"file-upload-indicator\" title=\"{indicatorTitle}\">{indicator}<\/div>',\r\n                    actions: '<div class=\"file-actions\">\\n    <div class=\"file-footer-buttons\">\\n        {download} {upload} {delete} {zoom} {other}    <\/div>\\n<\/div>\\n{drag}\\n<div class=\"clearfix\"><\/div>',\r\n                    actionDelete: '<button type=\"button\" class=\"kv-file-remove {removeClass}\" title=\"{removeTitle}\" {dataUrl}{dataKey}>{removeIcon}<\/button>\\n',\r\n                    actionUpload: '<button type=\"button\" class=\"kv-file-upload {uploadClass}\" title=\"{uploadTitle}\">{uploadIcon}<\/button>',\r\n                    actionDownload: '<a class=\"kv-file-download {downloadClass}\" title=\"{downloadTitle}\" href=\"{downloadUrl}\" download=\"{caption}\" target=\"_blank\">{downloadIcon}<\/a>',\r\n                    actionZoom: '<button type=\"button\" class=\"kv-file-zoom {zoomClass}\" title=\"{zoomTitle}\">{zoomIcon}<\/button>',\r\n                    actionDrag: '<span class=\"file-drag-handle {dragClass}\" title=\"{dragTitle}\">{dragIcon}<\/span>',\r\n                    btnDefault: '<button type=\"{type}\" title=\"{title}\" class=\"{css}\" {status} {tabIndexConfig}>{icon} {label}<\/button>',\r\n                    btnLink: '<a href=\"{href}\" title=\"{title}\" class=\"{css}\" {status} {tabIndexConfig}>{icon} {label}<\/a>',\r\n                    btnBrowse: '<div class=\"{css}\" {status} {tabIndexConfig}>{icon} {label}<\/div>',\r\n                    zoomCache: '<div class=\"kv-zoom-cache\">{zoomContent}<\/div>'\r\n                },\r\n                previewMarkupTags: {\r\n                    tagBefore1: '<div class=\"file-preview-frame {frameClass}\" id=\"{previewId}\" data-fileindex=\"{fileindex}\" data-fileid=\"{fileid}\" data-template=\"{template}\" data-zoom=\"{zoomData}\"><div class=\"kv-file-content\">\\n',\r\n                    tagBefore2: '<div class=\"file-preview-frame {frameClass}\" id=\"{previewId}\" data-fileindex=\"{fileindex}\" data-fileid=\"{fileid}\" data-template=\"{template}\" data-zoom=\"{zoomData}\" title=\"{caption}\"><div class=\"kv-file-content\">\\n',\r\n                    tagAfter: \"<\/div>{footer}\\n{zoomCache}<\/div>\\n\"\r\n                },\r\n                previewContentTemplates: {\r\n                    generic: \"{content}\\n\",\r\n                    html: o,\r\n                    image: l,\r\n                    text: d,\r\n                    office: c,\r\n                    gdocs: u,\r\n                    video: p,\r\n                    audio: f,\r\n                    flash: h,\r\n                    object: m,\r\n                    pdf: g,\r\n                    other: v\r\n                },\r\n                allowedPreviewTypes: [\"image\", \"html\", \"text\", \"video\", \"audio\", \"flash\", \"pdf\", \"object\"],\r\n                previewTemplates: {},\r\n                previewSettings: {\r\n                    image: {\r\n                        width: \"auto\",\r\n                        height: \"auto\",\r\n                        \"max-width\": \"100%\",\r\n                        \"max-height\": \"100%\"\r\n                    },\r\n                    html: {\r\n                        width: \"213px\",\r\n                        height: \"160px\"\r\n                    },\r\n                    text: {\r\n                        width: \"213px\",\r\n                        height: \"160px\"\r\n                    },\r\n                    office: {\r\n                        width: \"213px\",\r\n                        height: \"160px\"\r\n                    },\r\n                    gdocs: {\r\n                        width: \"213px\",\r\n                        height: \"160px\"\r\n                    },\r\n                    video: {\r\n                        width: \"213px\",\r\n                        height: \"160px\"\r\n                    },\r\n                    audio: {\r\n                        width: \"100%\",\r\n                        height: \"30px\"\r\n                    },\r\n                    flash: {\r\n                        width: \"213px\",\r\n                        height: \"160px\"\r\n                    },\r\n                    object: {\r\n                        width: \"213px\",\r\n                        height: \"160px\"\r\n                    },\r\n                    pdf: {\r\n                        width: \"100%\",\r\n                        height: \"160px\",\r\n                        position: \"relative\"\r\n                    },\r\n                    other: {\r\n                        width: \"213px\",\r\n                        height: \"160px\"\r\n                    }\r\n                },\r\n                previewSettingsSmall: {\r\n                    image: {\r\n                        width: \"auto\",\r\n                        height: \"auto\",\r\n                        \"max-width\": \"100%\",\r\n                        \"max-height\": \"100%\"\r\n                    },\r\n                    html: {\r\n                        width: \"100%\",\r\n                        height: \"160px\"\r\n                    },\r\n                    text: {\r\n                        width: \"100%\",\r\n                        height: \"160px\"\r\n                    },\r\n                    office: {\r\n                        width: \"100%\",\r\n                        height: \"160px\"\r\n                    },\r\n                    gdocs: {\r\n                        width: \"100%\",\r\n                        height: \"160px\"\r\n                    },\r\n                    video: {\r\n                        width: \"100%\",\r\n                        height: \"auto\"\r\n                    },\r\n                    audio: {\r\n                        width: \"100%\",\r\n                        height: \"30px\"\r\n                    },\r\n                    flash: {\r\n                        width: \"100%\",\r\n                        height: \"auto\"\r\n                    },\r\n                    object: {\r\n                        width: \"100%\",\r\n                        height: \"auto\"\r\n                    },\r\n                    pdf: {\r\n                        width: \"100%\",\r\n                        height: \"160px\"\r\n                    },\r\n                    other: {\r\n                        width: \"100%\",\r\n                        height: \"160px\"\r\n                    }\r\n                },\r\n                previewZoomSettings: {\r\n                    image: {\r\n                        width: \"auto\",\r\n                        height: \"auto\",\r\n                        \"max-width\": \"100%\",\r\n                        \"max-height\": \"100%\"\r\n                    },\r\n                    html: b,\r\n                    text: b,\r\n                    office: {\r\n                        width: \"100%\",\r\n                        height: \"100%\",\r\n                        \"max-width\": \"100%\",\r\n                        \"min-height\": \"480px\"\r\n                    },\r\n                    gdocs: {\r\n                        width: \"100%\",\r\n                        height: \"100%\",\r\n                        \"max-width\": \"100%\",\r\n                        \"min-height\": \"480px\"\r\n                    },\r\n                    video: {\r\n                        width: \"auto\",\r\n                        height: \"100%\",\r\n                        \"max-width\": \"100%\"\r\n                    },\r\n                    audio: {\r\n                        width: \"100%\",\r\n                        height: \"30px\"\r\n                    },\r\n                    flash: {\r\n                        width: \"auto\",\r\n                        height: \"480px\"\r\n                    },\r\n                    object: {\r\n                        width: \"auto\",\r\n                        height: \"100%\",\r\n                        \"max-width\": \"100%\",\r\n                        \"min-height\": \"480px\"\r\n                    },\r\n                    pdf: b,\r\n                    other: {\r\n                        width: \"auto\",\r\n                        height: \"100%\",\r\n                        \"min-height\": \"480px\"\r\n                    }\r\n                },\r\n                mimeTypeAliases: {\r\n                    \"video\/quicktime\": \"video\/mp4\"\r\n                },\r\n                fileTypeSettings: {\r\n                    image: function(e, i) {\r\n                        return t.compare(e, \"image.*\") && !t.compare(e, \/(tiff?|wmf)$\/i) || t.compare(i, \/\\.(gif|png|jpe?g)$\/i)\r\n                    },\r\n                    html: function(e, i) {\r\n                        return t.compare(e, \"text\/html\") || t.compare(i, \/\\.(htm|html)$\/i)\r\n                    },\r\n                    office: function(e, i) {\r\n                        return t.compare(e, \/(word|excel|powerpoint|office)$\/i) || t.compare(i, \/\\.(docx?|xlsx?|pptx?|pps|potx?)$\/i)\r\n                    },\r\n                    gdocs: function(e, i) {\r\n                        return t.compare(e, \/(word|excel|powerpoint|office|iwork-pages|tiff?)$\/i) || t.compare(i, \/\\.(docx?|xlsx?|pptx?|pps|potx?|rtf|ods|odt|pages|ai|dxf|ttf|tiff?|wmf|e?ps)$\/i)\r\n                    },\r\n                    text: function(e, i) {\r\n                        return t.compare(e, \"text.*\") || t.compare(i, \/\\.(xml|javascript)$\/i) || t.compare(i, \/\\.(txt|md|nfo|ini|json|php|js|css)$\/i)\r\n                    },\r\n                    video: function(e, i) {\r\n                        return t.compare(e, \"video.*\") && (t.compare(e, \/(ogg|mp4|mp?g|mov|webm|3gp)$\/i) || t.compare(i, \/\\.(og?|mp4|webm|mp?g|mov|3gp)$\/i))\r\n                    },\r\n                    audio: function(e, i) {\r\n                        return t.compare(e, \"audio.*\") && (t.compare(i, \/(ogg|mp3|mp?g|wav)$\/i) || t.compare(i, \/\\.(og?|mp3|mp?g|wav)$\/i))\r\n                    },\r\n                    flash: function(e, i) {\r\n                        return t.compare(e, \"application\/x-shockwave-flash\", !0) || t.compare(i, \/\\.(swf)$\/i)\r\n                    },\r\n                    pdf: function(e, i) {\r\n                        return t.compare(e, \"application\/pdf\", !0) || t.compare(i, \/\\.(pdf)$\/i)\r\n                    },\r\n                    object: function() {\r\n                        return !0\r\n                    },\r\n                    other: function() {\r\n                        return !0\r\n                    }\r\n                },\r\n                fileActionSettings: {\r\n                    showRemove: !0,\r\n                    showUpload: !0,\r\n                    showDownload: !0,\r\n                    showZoom: !0,\r\n                    showDrag: !0,\r\n                    removeIcon: '<i class=\"bi-trash\"><\/i>',\r\n                    removeClass: y,\r\n                    removeErrorClass: \"btn btn-sm btn-kv btn-danger\",\r\n                    removeTitle: \"Remove file\",\r\n                    uploadIcon: '<i class=\"bi-upload\"><\/i>',\r\n                    uploadClass: y,\r\n                    uploadTitle: \"Upload file\",\r\n                    uploadRetryIcon: '<i class=\"bi-arrow-clockwise\"><\/i>',\r\n                    uploadRetryTitle: \"Retry upload\",\r\n                    downloadIcon: '<i class=\"bi-download\"><\/i>',\r\n                    downloadClass: y,\r\n                    downloadTitle: \"Download file\",\r\n                    zoomIcon: '<i class=\"bi-zoom-in\"><\/i>',\r\n                    zoomClass: y,\r\n                    zoomTitle: \"View Details\",\r\n                    dragIcon: '<i class=\"bi-arrows-move\"><\/i>',\r\n                    dragClass: \"text-primary\",\r\n                    dragTitle: \"Move \/ Rearrange\",\r\n                    dragSettings: {},\r\n                    indicatorNew: '<i class=\"bi-plus-lg text-warning\"><\/i>',\r\n                    indicatorSuccess: '<i class=\"bi-check-lg text-success\"><\/i>',\r\n                    indicatorError: '<i class=\"bi-exclamation-lg text-danger\"><\/i>',\r\n                    indicatorLoading: '<i class=\"bi-hourglass-bottom text-muted\"><\/i>',\r\n                    indicatorPaused: '<i class=\"bi-pause-fill text-primary\"><\/i>',\r\n                    indicatorNewTitle: \"Not uploaded yet\",\r\n                    indicatorSuccessTitle: \"Uploaded\",\r\n                    indicatorErrorTitle: \"Upload Error\",\r\n                    indicatorLoadingTitle: \"Uploading &hellip;\",\r\n                    indicatorPausedTitle: \"Upload Paused\"\r\n                }\r\n            }, e.each(C.defaults, function(t, i) {\r\n                \"allowedPreviewTypes\" !== t ? C[t] = e.extend(!0, {}, i, C[t]) : void 0 === C.allowedPreviewTypes && (C.allowedPreviewTypes = i)\r\n            }), C._initPreviewTemplates()\r\n        },\r\n        _initPreviewTemplates: function() {\r\n            var i, a = this,\r\n                r = a.previewMarkupTags,\r\n                s = r.tagAfter;\r\n            e.each(a.previewContentTemplates, function(e, n) {\r\n                t.isEmpty(a.previewTemplates[e]) && (i = r.tagBefore2, \"generic\" !== e && \"image\" !== e || (i = r.tagBefore1), a._isPdfRendered() && \"pdf\" === e && (i = i.replace(\"kv-file-content\", \"kv-file-content kv-pdf-rendered\")), a.previewTemplates[e] = i + n + s)\r\n            })\r\n        },\r\n        _initPreviewCache: function() {\r\n            var i = this;\r\n            i.previewCache = {\r\n                data: {},\r\n                init: function() {\r\n                    var e = i.initialPreview;\r\n                    e.length > 0 && !t.isArray(e) && (e = e.split(i.initialPreviewDelimiter)), i.previewCache.data = {\r\n                        content: e,\r\n                        config: i.initialPreviewConfig,\r\n                        tags: i.initialPreviewThumbTags\r\n                    }\r\n                },\r\n                count: function(e) {\r\n                    return i.previewCache.data && i.previewCache.data.content ? e ? i.previewCache.data.content.filter(function(e) {\r\n                        return null !== e\r\n                    }).length : i.previewCache.data.content.length : 0\r\n                },\r\n                get: function(e, a) {\r\n                    var r, s, n, o, l, d, c, u = t.INIT_FLAG + e,\r\n                        p = i.previewCache.data,\r\n                        f = p.config[e],\r\n                        h = p.content[e],\r\n                        m = t.ifSet(\"previewAsData\", f, i.initialPreviewAsData),\r\n                        g = f ? {\r\n                            title: f.title || null,\r\n                            alt: f.alt || null\r\n                        } : {\r\n                            title: null,\r\n                            alt: null\r\n                        },\r\n                        v = function(e, a, r, s, n, o, l, d) {\r\n                            var c = \" file-preview-initial \" + t.SORT_CSS + (l ? \" \" + l : \"\"),\r\n                                u = i.previewInitId + \"-\" + o,\r\n                                p = f && f.fileId || u;\r\n                            return i._generatePreviewTemplate(e, a, r, s, u, p, !1, null, c, n, o, d, g, f && f.zoomData || a)\r\n                        };\r\n                    return h && h.length ? (a = void 0 === a || a, n = t.ifSet(\"type\", f, i.initialPreviewFileType || \"generic\"), l = t.ifSet(\"filename\", f, t.ifSet(\"caption\", f)), d = t.ifSet(\"filetype\", f, n), o = i.previewCache.footer(e, a, f && f.size || null), c = t.ifSet(\"frameClass\", f), r = m ? v(n, h, l, d, o, u, c) : v(\"generic\", h, l, d, o, u, c, n).setTokens({\r\n                        content: p.content[e]\r\n                    }), p.tags.length && p.tags[e] && (r = t.replaceTags(r, p.tags[e])), t.isEmpty(f) || t.isEmpty(f.frameAttr) || ((s = t.createElement(r)).find(\".file-preview-initial\").attr(f.frameAttr), r = s.html(), s.remove()), r) : \"\"\r\n                },\r\n                clean: function(e) {\r\n                    e.content = t.cleanArray(e.content), e.config = t.cleanArray(e.config), e.tags = t.cleanArray(e.tags), i.previewCache.data = e\r\n                },\r\n                add: function(e, a, r, s) {\r\n                    var n, o = i.previewCache.data;\r\n                    return e && e.length ? (n = e.length - 1, t.isArray(e) || (e = e.split(i.initialPreviewDelimiter)), s && o.content ? (n = o.content.push(e[0]) - 1, o.config[n] = a, o.tags[n] = r) : (o.content = e, o.config = a, o.tags = r), i.previewCache.clean(o), n) : 0\r\n                },\r\n                set: function(e, a, r, s) {\r\n                    var n, o = i.previewCache.data;\r\n                    if (e && e.length && (t.isArray(e) || (e = e.split(i.initialPreviewDelimiter)), e.filter(function(e) {\r\n                            return null !== e\r\n                        }).length)) {\r\n                        if (void 0 === o.content && (o.content = []), void 0 === o.config && (o.config = []), void 0 === o.tags && (o.tags = []), s) {\r\n                            for (n = 0; n < e.length; n++) e[n] && o.content.push(e[n]);\r\n                            for (n = 0; n < a.length; n++) a[n] && o.config.push(a[n]);\r\n                            for (n = 0; n < r.length; n++) r[n] && o.tags.push(r[n])\r\n                        } else o.content = e, o.config = a, o.tags = r;\r\n                        i.previewCache.clean(o)\r\n                    }\r\n                },\r\n                unset: function(a) {\r\n                    var r = i.previewCache.count(),\r\n                        s = i.reversePreviewOrder;\r\n                    if (r) {\r\n                        if (1 === r) return i.previewCache.data.content = [], i.previewCache.data.config = [], i.previewCache.data.tags = [], i.initialPreview = [], i.initialPreviewConfig = [], void(i.initialPreviewThumbTags = []);\r\n                        i.previewCache.data.content = t.spliceArray(i.previewCache.data.content, a, s), i.previewCache.data.config = t.spliceArray(i.previewCache.data.config, a, s), i.previewCache.data.tags = t.spliceArray(i.previewCache.data.tags, a, s);\r\n                        var n = e.extend(!0, {}, i.previewCache.data);\r\n                        i.previewCache.clean(n)\r\n                    }\r\n                },\r\n                out: function() {\r\n                    var e, t, a = \"\",\r\n                        r = i.previewCache.count();\r\n                    if (0 === r) return {\r\n                        content: \"\",\r\n                        caption: \"\"\r\n                    };\r\n                    for (e = 0; e < r; e++) t = i.previewCache.get(e), a = i.reversePreviewOrder ? t + a : a + t;\r\n                    return {\r\n                        content: a,\r\n                        caption: i._getMsgSelected(r)\r\n                    }\r\n                },\r\n                footer: function(e, a, r) {\r\n                    var s = i.previewCache.data || {};\r\n                    if (t.isEmpty(s.content)) return \"\";\r\n                    (t.isEmpty(s.config) || t.isEmpty(s.config[e])) && (s.config[e] = {}), a = void 0 === a || a;\r\n                    var n, o = s.config[e],\r\n                        l = t.ifSet(\"caption\", o),\r\n                        d = t.ifSet(\"width\", o, \"auto\"),\r\n                        c = t.ifSet(\"url\", o, !1),\r\n                        u = t.ifSet(\"key\", o, null),\r\n                        p = t.ifSet(\"fileId\", o, null),\r\n                        f = i.fileActionSettings,\r\n                        h = i.initialPreviewShowDelete || !1,\r\n                        m = i.initialPreviewDownloadUrl ? i.initialPreviewDownloadUrl + \"?key=\" + u + (p ? \"&fileId=\" + p : \"\") : \"\",\r\n                        g = o.downloadUrl || m,\r\n                        v = o.filename || o.caption || \"\",\r\n                        w = !!g,\r\n                        b = t.ifSet(\"showRemove\", o, h),\r\n                        _ = t.ifSet(\"showDownload\", o, t.ifSet(\"showDownload\", f, w)),\r\n                        C = t.ifSet(\"showZoom\", o, t.ifSet(\"showZoom\", f, !0)),\r\n                        x = t.ifSet(\"showDrag\", o, t.ifSet(\"showDrag\", f, !0)),\r\n                        y = !1 === c && a;\r\n                    return _ = _ && !1 !== o.downloadUrl && !!g, n = i._renderFileActions(o, !1, _, b, C, x, y, c, u, !0, g, v), i._getLayoutTemplate(\"footer\").setTokens({\r\n                        progress: i._renderThumbProgress(),\r\n                        actions: n,\r\n                        caption: l,\r\n                        size: i._getSize(r),\r\n                        width: d,\r\n                        indicator: \"\"\r\n                    })\r\n                }\r\n            }, i.previewCache.init()\r\n        },\r\n        _isPdfRendered: function() {\r\n            var e = this.usePdfRenderer;\r\n            return (\"function\" == typeof e ? e() : !!e) && this.pdfRendererUrl\r\n        },\r\n        _handler: function(e, t, i) {\r\n            var a = this.namespace,\r\n                r = t.split(\" \").join(a + \" \") + a;\r\n            e && e.length && e.off(r).on(r, i)\r\n        },\r\n        _encodeURI: function(e) {\r\n            return this.encodeUrl ? encodeURI(e) : e\r\n        },\r\n        _log: function(e, t) {\r\n            var i = this.$element.attr(\"id\");\r\n            this.showConsoleLogs && (i && (e = '\"' + i + '\": ' + e), e = \"bootstrap-fileinput: \" + e, \"object\" == typeof t && (e = e.setTokens(t)), window.console && void 0 !== window.console.log ? window.console.log(e) : window.alert(e))\r\n        },\r\n        _validate: function() {\r\n            var e = \"file\" === this.$element.attr(\"type\");\r\n            return e || this._log(t.logMessages.badInputType), e\r\n        },\r\n        _errorsExist: function() {\r\n            var i;\r\n            return !!this.$errorContainer.find(\"li\").length || ((i = t.createElement(this.$errorContainer.html())).find(\".kv-error-close\").remove(), i.find(\"ul\").remove(), !!e.trim(i.text()).length)\r\n        },\r\n        _errorHandler: function(e, t) {\r\n            var i = this,\r\n                a = e.target.error,\r\n                r = function(e) {\r\n                    i._showError(e.replace(\"{name}\", t))\r\n                };\r\n            a.code === a.NOT_FOUND_ERR ? r(i.msgFileNotFound) : a.code === a.SECURITY_ERR ? r(i.msgFileSecured) : a.code === a.NOT_READABLE_ERR ? r(i.msgFileNotReadable) : a.code === a.ABORT_ERR ? r(i.msgFilePreviewAborted) : r(i.msgFilePreviewError)\r\n        },\r\n        _addError: function(e) {\r\n            var i = this,\r\n                a = i.$errorContainer;\r\n            e && a.length && (t.setHtml(a, i.errorCloseButton + e), i._handler(a.find(\".kv-error-close\"), \"click\", function() {\r\n                setTimeout(function() {\r\n                    i.showPreview && !i.getFrames().length && i.clear(), a.fadeOut(\"slow\")\r\n                }, i.processDelay)\r\n            }))\r\n        },\r\n        _setValidationError: function(e) {\r\n            e = (e ? e + \" \" : \"\") + \"has-error\", this.$container.removeClass(e).addClass(\"has-error\"), t.addCss(this.$caption, \"is-invalid\")\r\n        },\r\n        _resetErrors: function(e) {\r\n            var t = this.$errorContainer,\r\n                i = this.resumableUploadOptions.retainErrorHistory;\r\n            this.isPersistentError || this.enableResumableUpload && i || (this.isError = !1, this.$container.removeClass(\"has-error\"), this.$caption.removeClass(\"is-invalid is-valid file-processing\"), t.html(\"\"), e ? t.fadeOut(\"slow\") : t.hide())\r\n        },\r\n        _showFolderError: function(e) {\r\n            var t, i = this.$errorContainer;\r\n            e && (this.isAjaxUpload || this._clearFileInput(), t = this.msgFoldersNotAllowed.replace(\"{n}\", e), this._addError(t), this._setValidationError(), i.fadeIn(this.fadeDelay), this._raise(\"filefoldererror\", [e, t]))\r\n        },\r\n        _showFileError: function(e, t, i) {\r\n            var a = this.$errorContainer,\r\n                r = i || \"fileuploaderror\",\r\n                s = t && t.fileId || \"\",\r\n                n = t && t.id ? '<li data-thumb-id=\"' + t.id + '\" data-file-id=\"' + s + '\">' + e + \"<\/li>\" : \"<li>\" + e + \"<\/li>\";\r\n            return 0 === a.find(\"ul\").length ? this._addError(\"<ul>\" + n + \"<\/ul>\") : a.find(\"ul\").append(n), a.fadeIn(this.fadeDelay), this._raise(r, [t, e]), this._setValidationError(\"file-input-new\"), !0\r\n        },\r\n        _showError: function(e, t, i) {\r\n            var a = this.$errorContainer,\r\n                r = i || \"fileerror\";\r\n            return (t = t || {}).reader = this.reader, this._addError(e), a.fadeIn(this.fadeDelay), this._raise(r, [t, e]), this.isAjaxUpload || this._clearFileInput(), this._setValidationError(\"file-input-new\"), this.$btnUpload.attr(\"disabled\", !0), !0\r\n        },\r\n        _noFilesError: function(e) {\r\n            var t = this.minFileCount > 1 ? this.filePlural : this.fileSingle,\r\n                i = this.msgFilesTooLess.replace(\"{n}\", this.minFileCount).replace(\"{files}\", t),\r\n                a = this.$errorContainer;\r\n            i = \"<li>\" + i + \"<\/li>\", 0 === a.find(\"ul\").length ? this._addError(\"<ul>\" + i + \"<\/ul>\") : a.find(\"ul\").append(i), this.isError = !0, this._updateFileDetails(0), a.fadeIn(this.fadeDelay), this._raise(\"fileerror\", [e, i]), this._clearFileInput(), this._setValidationError()\r\n        },\r\n        _parseError: function(t, i, a, r) {\r\n            var s, n, o, l = e.trim(a + \"\");\r\n            return o = (n = i.responseJSON && i.responseJSON.error ? i.responseJSON.error.toString() : \"\") || i.responseText, this.cancelling && this.msgUploadAborted && (l = this.msgUploadAborted), this.showAjaxErrorDetails && o && (n ? l = e.trim(n + \"\") : (s = (o = e.trim(o.replace(\/\\n\\s*\\n\/g, \"\\n\"))).length ? \"<pre>\" + o + \"<\/pre>\" : \"\", l += l ? s : o)), l || (l = this.msgAjaxError.replace(\"{operation}\", t)), this.cancelling = !1, r ? \"<b>\" + r + \": <\/b>\" + l : l\r\n        },\r\n        _parseFileType: function(e, i) {\r\n            var a, r, s, n = this.allowedPreviewTypes || [];\r\n            if (\"application\/text-plain\" === e) return \"text\";\r\n            for (s = 0; s < n.length; s++)\r\n                if (r = n[s], a = (0, this.fileTypeSettings[r])(e, i) ? r : \"\", !t.isEmpty(a)) return a;\r\n            return \"other\"\r\n        },\r\n        _getPreviewIcon: function(t) {\r\n            var i, a = this,\r\n                r = null;\r\n            return t && t.indexOf(\".\") > -1 && (i = t.split(\".\").pop(), a.previewFileIconSettings && (r = a.previewFileIconSettings[i] || a.previewFileIconSettings[i.toLowerCase()] || null), a.previewFileExtSettings && e.each(a.previewFileExtSettings, function(e, t) {\r\n                a.previewFileIconSettings[e] && t(i) && (r = a.previewFileIconSettings[e])\r\n            })), r || a.previewFileIcon\r\n        },\r\n        _parseFilePreviewIcon: function(e, t) {\r\n            var i = this._getPreviewIcon(t),\r\n                a = e;\r\n            return a.indexOf(\"{previewFileIcon}\") > -1 && (a = a.setTokens({\r\n                previewFileIconClass: this.previewFileIconClass,\r\n                previewFileIcon: i\r\n            })), a\r\n        },\r\n        _raise: function(t, i) {\r\n            var a = e.Event(t);\r\n            void 0 !== i ? this.$element.trigger(a, i) : this.$element.trigger(a);\r\n            var r = a.result,\r\n                s = !1 === r;\r\n            if (a.isDefaultPrevented() || s) return !1;\r\n            if (\"filebatchpreupload\" === a.type && (r || s)) return this.ajaxAborted = r, !1;\r\n            switch (t) {\r\n                case \"filebatchuploadcomplete\":\r\n                case \"filebatchuploadsuccess\":\r\n                case \"fileuploaded\":\r\n                case \"fileclear\":\r\n                case \"filecleared\":\r\n                case \"filereset\":\r\n                case \"fileerror\":\r\n                case \"filefoldererror\":\r\n                case \"fileuploaderror\":\r\n                case \"filebatchuploaderror\":\r\n                case \"filedeleteerror\":\r\n                case \"filecustomerror\":\r\n                case \"filesuccessremove\":\r\n                    break;\r\n                default:\r\n                    this.ajaxAborted || (this.ajaxAborted = r)\r\n            }\r\n            return !0\r\n        },\r\n        _listenFullScreen: function(e) {\r\n            var t, i, a = this.$modal;\r\n            a && a.length && (t = a && a.find(\".btn-kv-fullscreen\"), i = a && a.find(\".btn-kv-borderless\"), t.length && i.length && (t.removeClass(\"active\").attr(\"aria-pressed\", \"false\"), i.removeClass(\"active\").attr(\"aria-pressed\", \"false\"), e ? t.addClass(\"active\").attr(\"aria-pressed\", \"true\") : i.addClass(\"active\").attr(\"aria-pressed\", \"true\"), a.hasClass(\"file-zoom-fullscreen\") ? this._maximizeZoomDialog() : e ? this._maximizeZoomDialog() : i.removeClass(\"active\").attr(\"aria-pressed\", \"false\")))\r\n        },\r\n        _listen: function() {\r\n            var i = this,\r\n                a = i.$element,\r\n                r = i.$form,\r\n                s = i.$container;\r\n            i._handler(a, \"click\", function(e) {\r\n                i._initFileSelected(), a.hasClass(\"file-no-browse\") && (a.data(\"zoneClicked\") ? a.data(\"zoneClicked\", !1) : e.preventDefault())\r\n            }), i._handler(a, \"change\", e.proxy(i._change, i)), i._handler(i.$caption, \"paste\", e.proxy(i.paste, i)), i.showBrowse && (i._handler(i.$btnFile, \"click\", e.proxy(i._browse, i)), i._handler(i.$btnFile, \"keypress\", function(e) {\r\n                13 === (e.keyCode || e.which) && (a.trigger(\"click\"), i._browse(e))\r\n            })), i._handler(s.find(\".fileinput-remove:not([disabled])\"), \"click\", e.proxy(i.clear, i)), i._handler(s.find(\".fileinput-cancel\"), \"click\", e.proxy(i.cancel, i)), i._handler(s.find(\".fileinput-pause\"), \"click\", e.proxy(i.pause, i)), i._initDragDrop(), i._handler(r, \"reset\", e.proxy(i.clear, i)), i.isAjaxUpload || i._handler(r, \"submit\", e.proxy(i._submitForm, i)), i._handler(i.$container.find(\".fileinput-upload\"), \"click\", e.proxy(i._uploadClick, i)), i._handler(e(window), \"resize\", function() {\r\n                i._listenFullScreen(screen.width === window.innerWidth && screen.height === window.innerHeight)\r\n            }), i._handler(e(document), \"webkitfullscreenchange mozfullscreenchange fullscreenchange MSFullscreenChange\", function() {\r\n                i._listenFullScreen(t.checkFullScreen())\r\n            }), i.$caption.on(\"focus\", function() {\r\n                i.$captionContainer.focus()\r\n            }), i._autoFitContent(), i._initClickable(), i._refreshPreview()\r\n        },\r\n        _autoFitContent: function() {\r\n            var t, i = window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth,\r\n                a = this,\r\n                r = i < 400 ? a.previewSettingsSmall || a.defaults.previewSettingsSmall : a.previewSettings || a.defaults.previewSettings;\r\n            e.each(r, function(e, i) {\r\n                t = \".file-preview-frame .file-preview-\" + e, a.$preview.find(t + \".kv-preview-data,\" + t + \" .kv-preview-data\").css(i)\r\n            })\r\n        },\r\n        _scanDroppedItems: function(e, i, a) {\r\n            a = a || \"\";\r\n            var r, s, n, o = this,\r\n                l = function(e) {\r\n                    o._log(t.logMessages.badDroppedFiles), o._log(e)\r\n                };\r\n            e.isFile ? e.file(function(e) {\r\n                a && (e.newPath = a + e.name), i.push(e)\r\n            }, l) : e.isDirectory && (s = e.createReader(), (n = function() {\r\n                s.readEntries(function(t) {\r\n                    if (t && t.length > 0) {\r\n                        for (r = 0; r < t.length; r++) o._scanDroppedItems(t[r], i, a + e.name + \"\/\");\r\n                        n()\r\n                    }\r\n                    return null\r\n                }, l)\r\n            })())\r\n        },\r\n        _initDragDrop: function() {\r\n            var t = this.$dropZone;\r\n            this.dropZoneEnabled && this.showPreview && (this._handler(t, \"dragenter dragover\", e.proxy(this._zoneDragEnter, this)), this._handler(t, \"dragleave\", e.proxy(this._zoneDragLeave, this)), this._handler(t, \"drop\", e.proxy(this._zoneDrop, this)), this._handler(e(document), \"dragenter dragover drop\", this._zoneDragDropInit))\r\n        },\r\n        _zoneDragDropInit: function(e) {\r\n            e.stopPropagation(), e.preventDefault()\r\n        },\r\n        _zoneDragEnter: function(i) {\r\n            var a = i.originalEvent.dataTransfer,\r\n                r = e.inArray(\"Files\", a.types) > -1;\r\n            if (this._zoneDragDropInit(i), this.isDisabled || !r) return a.effectAllowed = \"none\", void(a.dropEffect = \"none\");\r\n            a.dropEffect = \"copy\", this._raise(\"fileDragEnter\", {\r\n                sourceEvent: i,\r\n                files: a.types.Files\r\n            }) && t.addCss(this.$dropZone, \"file-highlighted\")\r\n        },\r\n        _zoneDragLeave: function(e) {\r\n            this._zoneDragDropInit(e), this.isDisabled || this._raise(\"fileDragLeave\", {\r\n                sourceEvent: e\r\n            }) && this.$dropZone.removeClass(\"file-highlighted\")\r\n        },\r\n        _dropFiles: function(e, t) {\r\n            var i = this,\r\n                a = i.$element;\r\n            i.isAjaxUpload ? i._change(e, t) : (i.changeTriggered = !0, a.get(0).files = t, setTimeout(function() {\r\n                i.changeTriggered = !1, a.trigger(\"change\" + i.namespace)\r\n            }, i.processDelay)), i.$dropZone.removeClass(\"file-highlighted\")\r\n        },\r\n        _zoneDrop: function(e) {\r\n            var i, a = this,\r\n                r = (a.$element, e.originalEvent.dataTransfer),\r\n                s = r.files,\r\n                n = r.items,\r\n                o = t.getDragDropFolders(n);\r\n            if (e.preventDefault(), !a.isDisabled && !t.isEmpty(s) && a._raise(\"fileDragDrop\", {\r\n                    sourceEvent: e,\r\n                    files: s\r\n                }))\r\n                if (o > 0) {\r\n                    if (!a.isAjaxUpload) return void a._showFolderError(o);\r\n                    for (s = [], i = 0; i < n.length; i++) {\r\n                        var l = n[i].webkitGetAsEntry();\r\n                        l && a._scanDroppedItems(l, s)\r\n                    }\r\n                    setTimeout(function() {\r\n                        a._dropFiles(e, s)\r\n                    }, 500)\r\n                } else a._dropFiles(e, s)\r\n        },\r\n        _uploadClick: function(e) {\r\n            var i, a = this.$container.find(\".fileinput-upload\"),\r\n                r = !a.hasClass(\"disabled\") && t.isEmpty(a.attr(\"disabled\"));\r\n            e && e.isDefaultPrevented() || (this.isAjaxUpload ? (e.preventDefault(), r && this.upload()) : r && \"submit\" !== a.attr(\"type\") && ((i = a.closest(\"form\")).length && i.trigger(\"submit\"), e.preventDefault()))\r\n        },\r\n        _submitForm: function() {\r\n            return this._isFileSelectionValid() && !this._abort({})\r\n        },\r\n        _clearPreview: function() {\r\n            (this.showUploadedThumbs ? this.getFrames(\":not(.file-preview-success)\") : this.getFrames()).each(function() {\r\n                e(this).remove()\r\n            }), this.getFrames().length && this.showPreview || this._resetUpload(), this._validateDefaultPreview()\r\n        },\r\n        _initSortable: function() {\r\n            var i, a, r, s, n = this,\r\n                o = n.$preview,\r\n                l = \".\" + t.SORT_CSS,\r\n                d = e(\"body\"),\r\n                c = e(\"html\"),\r\n                u = n.reversePreviewOrder,\r\n                p = window.Sortable;\r\n            p && 0 !== o.find(l).length && (a = d.length ? d : c.length ? c : n.$container, i = {\r\n                handle: \".drag-handle-init\",\r\n                dataIdAttr: \"data-fileid\",\r\n                animation: 400,\r\n                draggable: l,\r\n                scroll: !0,\r\n                forceFallback: !0,\r\n                onChoose: r = function() {\r\n                    a.addClass(\"file-grabbing\")\r\n                },\r\n                onStart: r,\r\n                onUnchoose: s = function() {\r\n                    a.removeClass(\"file-grabbing\")\r\n                },\r\n                onEnd: s,\r\n                onSort: function(i) {\r\n                    var a = i.oldIndex,\r\n                        r = i.newIndex,\r\n                        s = 0,\r\n                        o = n.initialPreviewConfig.length,\r\n                        l = o > 0 && r >= o,\r\n                        d = e(i.item);\r\n                    l && (r = o - 1), n.initialPreview = t.moveArray(n.initialPreview, a, r, u), n.initialPreviewConfig = t.moveArray(n.initialPreviewConfig, a, r, u), n.previewCache.init(), n.getFrames(\".file-preview-initial\").each(function() {\r\n                        e(this).attr(\"data-fileindex\", t.INIT_FLAG + s), s++\r\n                    }), n._raise(\"filesorted\", {\r\n                        previewId: d.attr(\"id\"),\r\n                        oldIndex: a,\r\n                        newIndex: r,\r\n                        stack: n.initialPreviewConfig\r\n                    })\r\n                }\r\n            }, e.extend(!0, i, n.fileActionSettings.dragSettings), n.sortable && n.sortable.destroy(), n.sortable = p.create(o[0], i))\r\n        },\r\n        _setPreviewContent: function(e) {\r\n            t.setHtml(this.$preview, e), this._autoFitContent()\r\n        },\r\n        _initPreviewImageOrientations: function() {\r\n            var t = this,\r\n                i = 0,\r\n                a = t.canOrientImage;\r\n            (t.autoOrientImageInitial || a) && t.getFrames(\".file-preview-initial\").each(function() {\r\n                var r, s, n, o = e(this),\r\n                    l = t.initialPreviewConfig[i];\r\n                l && l.exif && l.exif.Orientation && (n = o.attr(\"id\"), r = o.find(\">.kv-file-content img\"), s = t._getZoom(n, \" >.kv-file-content img\"), a ? r.css(\"image-orientation\", t.autoOrientImageInitial ? \"from-image\" : \"none\") : t.setImageOrientation(r, s, l.exif.Orientation, o)), i++\r\n            })\r\n        },\r\n        _initPreview: function(e) {\r\n            var i, a = this.initialCaption || \"\";\r\n            if (!this.previewCache.count(!0)) return this._clearPreview(), void(e ? this._setCaption(a) : this._initCaption());\r\n            i = this.previewCache.out(), a = e && this.initialCaption ? this.initialCaption : i.caption, this._setPreviewContent(i.content), this._setInitThumbAttr(), this._setCaption(a), this._initSortable(), t.isEmpty(i.content) || this.$container.removeClass(\"file-input-new\"), this._initPreviewImageOrientations()\r\n        },\r\n        _getZoomButton: function(e) {\r\n            var i = this.previewZoomButtonIcons[e],\r\n                a = this.previewZoomButtonClasses[e],\r\n                r = ' title=\"' + (this.previewZoomButtonTitles[e] || \"\") + '\" ',\r\n                s = t.isBs(5) ? \"bs-\" : \"\",\r\n                n = r + (\"close\" === e ? \" data-\" + s + 'dismiss=\"modal\" aria-hidden=\"true\"' : \"\");\r\n            return \"fullscreen\" !== e && \"borderless\" !== e && \"toggleheader\" !== e || (n += ' data-toggle=\"button\" aria-pressed=\"false\" autocomplete=\"off\"'), '<button type=\"button\" class=\"' + a + \" btn-kv-\" + e + '\"' + n + \">\" + i + \"<\/button>\"\r\n        },\r\n        _getModalContent: function() {\r\n            return this._getLayoutTemplate(\"modal\").setTokens({\r\n                rtl: this.rtl ? \" kv-rtl\" : \"\",\r\n                zoomFrameClass: this.frameClass,\r\n                prev: this._getZoomButton(\"prev\"),\r\n                next: this._getZoomButton(\"next\"),\r\n                toggleheader: this._getZoomButton(\"toggleheader\"),\r\n                fullscreen: this._getZoomButton(\"fullscreen\"),\r\n                borderless: this._getZoomButton(\"borderless\"),\r\n                close: this._getZoomButton(\"close\")\r\n            })\r\n        },\r\n        _listenModalEvent: function(e) {\r\n            var i = this,\r\n                a = i.$modal;\r\n            a.on(e + \".bs.modal\", function(r) {\r\n                if (\"bs.modal\" === r.namespace) {\r\n                    var s = a.find(\".btn-fullscreen\"),\r\n                        n = a.find(\".btn-borderless\");\r\n                    a.data(\"fileinputPluginId\") === i.$element.attr(\"id\") && i._raise(\"filezoom\" + e, function(e) {\r\n                        return {\r\n                            sourceEvent: e,\r\n                            previewId: a.data(\"previewId\"),\r\n                            modal: a\r\n                        }\r\n                    }(r)), \"shown\" === e && (n.removeClass(\"active\").attr(\"aria-pressed\", \"false\"), s.removeClass(\"active\").attr(\"aria-pressed\", \"false\"), a.hasClass(\"file-zoom-fullscreen\") && (i._maximizeZoomDialog(), t.checkFullScreen() ? s.addClass(\"active\").attr(\"aria-pressed\", \"true\") : n.addClass(\"active\").attr(\"aria-pressed\", \"true\")))\r\n                }\r\n            })\r\n        },\r\n        _initZoom: function() {\r\n            var i, a = this,\r\n                r = a._getLayoutTemplate(\"modalMain\"),\r\n                s = \"#\" + t.MODAL_ID;\r\n            r = a._setTabIndex(\"modal\", r), a.showPreview && (a.$modal = e(s), a.$modal && a.$modal.length || (i = t.createElement(t.cspBuffer.stash(r)).insertAfter(a.$container), a.$modal = e(s).insertBefore(i), t.cspBuffer.apply(a.$modal), i.remove()), t.initModal(a.$modal), a.$modal.html(t.cspBuffer.stash(a._getModalContent())), t.cspBuffer.apply(a.$modal), e.each(t.MODAL_EVENTS, function(e, t) {\r\n                a._listenModalEvent(t)\r\n            }))\r\n        },\r\n        _initZoomButtons: function() {\r\n            var t, i, a = this.$modal.data(\"previewId\") || \"\",\r\n                r = this.getFrames().toArray(),\r\n                s = r.length,\r\n                n = this.$modal.find(\".btn-kv-prev\"),\r\n                o = this.$modal.find(\".btn-kv-next\");\r\n            if (r.length < 2) return n.hide(), void o.hide();\r\n            n.show(), o.show(), s && (t = e(r[0]), i = e(r[s - 1]), n.removeAttr(\"disabled\"), o.removeAttr(\"disabled\"), this.reversePreviewOrder && ([n, o] = [o, n]), t.length && t.attr(\"id\") === a && n.attr(\"disabled\", !0), i.length && i.attr(\"id\") === a && o.attr(\"disabled\", !0))\r\n        },\r\n        _maximizeZoomDialog: function() {\r\n            var t = this.$modal,\r\n                i = t.find(\".modal-header:visible\"),\r\n                a = t.find(\".modal-footer:visible\"),\r\n                r = t.find(\".kv-zoom-body\"),\r\n                s = e(window).height();\r\n            t.addClass(\"file-zoom-fullscreen\"), i && i.length && (s -= i.outerHeight(!0)), a && a.length && (s -= a.outerHeight(!0)), r && r.length && (s -= r.outerHeight(!0) - r.height()), t.find(\".kv-zoom-body\").height(s)\r\n        },\r\n        _resizeZoomDialog: function(e) {\r\n            var i = this.$modal,\r\n                a = i.find(\".btn-kv-fullscreen\"),\r\n                r = i.find(\".btn-kv-borderless\");\r\n            if (i.hasClass(\"file-zoom-fullscreen\")) t.toggleFullScreen(!1), e ? a.hasClass(\"active\") || (i.removeClass(\"file-zoom-fullscreen\"), this._resizeZoomDialog(!0), r.hasClass(\"active\") && r.removeClass(\"active\").attr(\"aria-pressed\", \"false\")) : a.hasClass(\"active\") ? a.removeClass(\"active\").attr(\"aria-pressed\", \"false\") : (i.removeClass(\"file-zoom-fullscreen\"), this.$modal.find(\".kv-zoom-body\").css(\"height\", this.zoomModalHeight));\r\n            else {\r\n                if (!e) return void this._maximizeZoomDialog();\r\n                t.toggleFullScreen(!0)\r\n            }\r\n            i.focus()\r\n        },\r\n        _setZoomContent: function(i, a) {\r\n            var r, s, n, o, l, d, c, u, p, f, h, m, g = this,\r\n                v = i.attr(\"id\"),\r\n                w = g._getZoom(v),\r\n                b = g.$modal,\r\n                _ = b.find(\".btn-kv-fullscreen\"),\r\n                C = b.find(\".btn-kv-borderless\"),\r\n                x = b.find(\".btn-kv-toggleheader\"),\r\n                y = i.data(\"zoom\");\r\n            y && (y = decodeURIComponent(y), m = w.html().replace(t.ZOOM_VAR, \"\").setTokens({\r\n                zoomData: y\r\n            }), w.html(m), i.data(\"zoom\", \"\"), w.attr(\"data-zoom\", y)), s = w.attr(\"data-template\") || \"generic\", n = (r = w.find(\".kv-file-content\")).length ? '<span class=\"kv-spacer\"><\/span>\\n' + r.html() : \"\", f = i.data(\"caption\") || g.msgZoomModalHeading, h = i.data(\"size\") || \"\", u = i.data(\"description\") || \"\", b.find(\".kv-zoom-caption\").attr(\"title\", f).html(f), b.find(\".kv-zoom-size\").html(h), p = b.find(\".kv-zoom-description\").hide(), u && (g.showDescriptionClose && (u = g._getLayoutTemplate(\"descriptionClose\").setTokens({\r\n                closeIcon: g.previewZoomButtonIcons.close\r\n            }) + \"<\/button>\" + u), p.show().html(u), g.showDescriptionClose && g._handler(b.find(\".kv-desc-hide\"), \"click\", function() {\r\n                e(this).parent().fadeOut(\"fast\", function() {\r\n                    b.focus()\r\n                })\r\n            })), o = b.find(\".kv-zoom-body\"), b.removeClass(\"kv-single-content\"), a ? (c = o.addClass(\"file-thumb-loading\").clone().insertAfter(o), t.setHtml(o, n).hide(), c.fadeOut(\"fast\", function() {\r\n                o.fadeIn(\"fast\", function() {\r\n                    o.removeClass(\"file-thumb-loading\")\r\n                }), c.remove()\r\n            })) : t.setHtml(o, n), (d = g.previewZoomSettings[s]) && (l = o.find(\".kv-preview-data\"), t.addCss(l, \"file-zoom-detail\"), e.each(d, function(e, t) {\r\n                l.css(e, t), (l.attr(\"width\") && \"width\" === e || l.attr(\"height\") && \"height\" === e) && l.removeAttr(e)\r\n            })), b.data(\"previewId\", v), g._handler(b.find(\".btn-kv-prev\"), \"click\", function() {\r\n                g._zoomSlideShow(\"prev\", v)\r\n            }), g._handler(b.find(\".btn-kv-next\"), \"click\", function() {\r\n                g._zoomSlideShow(\"next\", v)\r\n            }), g._handler(_, \"click\", function() {\r\n                g._resizeZoomDialog(!0)\r\n            }), g._handler(C, \"click\", function() {\r\n                g._resizeZoomDialog(!1)\r\n            }), g._handler(x, \"click\", function() {\r\n                var e, t = b.find(\".modal-header\"),\r\n                    i = b.find(\".floating-buttons\"),\r\n                    a = t.find(\".kv-zoom-actions\"),\r\n                    r = function(e) {\r\n                        var i = g.$modal.find(\".kv-zoom-body\"),\r\n                            a = g.zoomModalHeight;\r\n                        b.hasClass(\"file-zoom-fullscreen\") && (a = i.outerHeight(!0), e || (a -= t.outerHeight(!0))), i.css(\"height\", e ? a + e : a)\r\n                    };\r\n                t.is(\":visible\") ? (e = t.outerHeight(!0), t.slideUp(\"slow\", function() {\r\n                    a.find(\".btn\").appendTo(i), r(e)\r\n                })) : (i.find(\".btn\").appendTo(a), t.slideDown(\"slow\", function() {\r\n                    r()\r\n                })), b.focus()\r\n            }), g._handler(b, \"keydown\", function(t) {\r\n                var i, a, r = t.which || t.keyCode,\r\n                    s = g.processDelay + 1,\r\n                    n = e(this).find(\".btn-kv-prev\"),\r\n                    o = e(this).find(\".btn-kv-next\"),\r\n                    l = e(this).data(\"previewId\");\r\n                [i, a] = g.rtl ? [39, 37] : [37, 39], e.each({\r\n                    prev: [n, i],\r\n                    next: [o, a]\r\n                }, function(e, t) {\r\n                    var i = t[0],\r\n                        a = t[1];\r\n                    r === a && i.length && (b.focus(), i.attr(\"disabled\") || (i.focus(), g._zoomSlideShow(e, l), setTimeout(function() {\r\n                        i.attr(\"disabled\") && b.focus()\r\n                    }, s)))\r\n                })\r\n            })\r\n        },\r\n        _showModal: function(e) {\r\n            var i = this.$modal;\r\n            e && e.length && (t.initModal(i), t.setHtml(i, this._getModalContent()), this._setZoomContent(e), i.data({\r\n                backdrop: !1\r\n            }), i.modal(\"show\"), this._initZoomButtons())\r\n        },\r\n        _zoomPreview: function(e) {\r\n            var i;\r\n            if (!e.length) throw \"Cannot zoom to detailed preview!\";\r\n            i = e.closest(t.FRAMES), this._showModal(i)\r\n        },\r\n        _zoomSlideShow: function(t, i) {\r\n            var a, r, s, n, o = this.$modal.find(\".kv-zoom-actions .btn-kv-\" + t),\r\n                l = this.getFrames().toArray(),\r\n                d = [],\r\n                c = l.length;\r\n            if (this.reversePreviewOrder && (t = \"prev\" === t ? \"next\" : \"prev\"), !o.attr(\"disabled\")) {\r\n                for (r = 0; r < c; r++)(s = e(l[r])) && s.length && s.find(\".kv-file-zoom:visible\").length && d.push(l[r]);\r\n                for (c = d.length, r = 0; r < c; r++)\r\n                    if (e(d[r]).attr(\"id\") === i) {\r\n                        n = \"prev\" === t ? r - 1 : r + 1;\r\n                        break\r\n                    } n < 0 || n >= c || !d[n] || ((a = e(d[n])).length && this._setZoomContent(a, t), this._initZoomButtons(), this._raise(\"filezoom\" + t, {\r\n                    previewId: i,\r\n                    modal: this.$modal\r\n                }))\r\n            }\r\n        },\r\n        _initZoomButton: function() {\r\n            var t = this;\r\n            t.$preview.find(\".kv-file-zoom\").each(function() {\r\n                var i = e(this);\r\n                t._handler(i, \"click\", function() {\r\n                    t._zoomPreview(i)\r\n                })\r\n            })\r\n        },\r\n        _inputFileCount: function() {\r\n            return this.$element[0].files.length\r\n        },\r\n        _refreshPreview: function() {\r\n            var t;\r\n            (this._inputFileCount() || this.isAjaxUpload) && this.showPreview && this.isPreviewable && (this.isAjaxUpload && this.fileManager.count() > 0 ? (t = e.extend(!0, {}, this.getFileList()), this.fileManager.clear(), this._clearFileInput()) : t = this.$element[0].files, t && t.length && (this.readFiles(t), this._setFileDropZoneTitle()))\r\n        },\r\n        _clearObjects: function(t) {\r\n            t.find(\"video audio\").each(function() {\r\n                this.pause(), e(this).remove()\r\n            }), t.find(\"img object div\").each(function() {\r\n                e(this).remove()\r\n            })\r\n        },\r\n        _clearFileInput: function() {\r\n            var t, i, a, r = this.$element;\r\n            this._inputFileCount() && (t = r.closest(\"form\"), i = e(document.createElement(\"form\")), a = e(document.createElement(\"div\")), r.before(a), t.length ? t.after(i) : a.after(i), i.append(r).trigger(\"reset\"), a.before(r).remove(), i.remove())\r\n        },\r\n        _resetUpload: function() {\r\n            this.uploadStartTime = t.now(), this.uploadCache = [], this.$btnUpload.removeAttr(\"disabled\"), this._setProgress(0), this._hideProgress(), this._resetErrors(!1), this._initAjax(), this.fileManager.clearImages(), this._resetCanvas(), this.overwriteInitial && (this.initialPreview = [], this.initialPreviewConfig = [], this.initialPreviewThumbTags = [], this.previewCache.data = {\r\n                content: [],\r\n                config: [],\r\n                tags: []\r\n            })\r\n        },\r\n        _resetCanvas: function() {\r\n            this.imageCanvas && this.imageCanvasContext && this.imageCanvasContext.clearRect(0, 0, this.imageCanvas.width, this.imageCanvas.height)\r\n        },\r\n        _hasInitialPreview: function() {\r\n            return !this.overwriteInitial && this.previewCache.count(!0)\r\n        },\r\n        _resetPreview: function() {\r\n            var i, a, r, s = this.showUploadedThumbs,\r\n                n = !this.removeFromPreviewOnError,\r\n                o = (s || n) && this.isDuplicateError;\r\n            this.previewCache.count(!0) ? (i = this.previewCache.out(), o && (r = t.createElement(\"\").insertAfter(this.$container), this.getFrames().each(function() {\r\n                var t = e(this);\r\n                (s && t.hasClass(\"file-preview-success\") || n && t.hasClass(\"file-preview-error\")) && r.append(t)\r\n            })), this._setPreviewContent(i.content), this._setInitThumbAttr(), a = this.initialCaption ? this.initialCaption : i.caption, this._setCaption(a), o && (r.contents().appendTo(this.$preview), r.remove())) : (this._clearPreview(), this._initCaption()), this.showPreview && (this._initZoom(), this._initSortable()), this.isDuplicateError = !1\r\n        },\r\n        _clearDefaultPreview: function() {\r\n            this.$preview.find(\".file-default-preview\").remove()\r\n        },\r\n        _validateDefaultPreview: function() {\r\n            this.showPreview && !t.isEmpty(this.defaultPreviewContent) && (this._setPreviewContent('<div class=\"file-default-preview\">' + this.defaultPreviewContent + \"<\/div>\"), this.$container.removeClass(\"file-input-new\"), this._initClickable())\r\n        },\r\n        _resetPreviewThumbs: function(e) {\r\n            var t;\r\n            if (e) return this._clearPreview(), void this.clearFileStack();\r\n            this._hasInitialPreview() ? (t = this.previewCache.out(), this._setPreviewContent(t.content), this._setInitThumbAttr(), this._setCaption(t.caption), this._initPreviewActions()) : this._clearPreview()\r\n        },\r\n        _getLayoutTemplate: function(e) {\r\n            var i = this.layoutTemplates[e];\r\n            return t.isEmpty(this.customLayoutTags) ? i : t.replaceTags(i, this.customLayoutTags)\r\n        },\r\n        _getPreviewTemplate: function(e) {\r\n            var i = this.previewTemplates,\r\n                a = i[e] || i.other;\r\n            return t.isEmpty(this.customPreviewTags) ? a : t.replaceTags(a, this.customPreviewTags)\r\n        },\r\n        _getOutData: function(e, t, i, a) {\r\n            return t = t || {}, i = i || {}, {\r\n                formdata: e,\r\n                files: a = a || this.fileManager.list(),\r\n                filenames: this.filenames,\r\n                filescount: this.getFilesCount(),\r\n                extra: this._getExtraData(),\r\n                response: i,\r\n                reader: this.reader,\r\n                jqXHR: t\r\n            }\r\n        },\r\n        _getMsgSelected: function(e, t) {\r\n            var i = 1 === e ? this.fileSingle : this.filePlural;\r\n            return e > 0 ? this.msgSelected.replace(\"{n}\", e).replace(\"{files}\", i) : t ? this.msgProcessing : this.msgNoFilesSelected\r\n        },\r\n        _getFrame: function(e, i) {\r\n            var a = t.getFrameElement(this.$preview, e);\r\n            return !this.showPreview || i || a.length || this._log(t.logMessages.invalidThumb, {\r\n                id: e\r\n            }), a\r\n        },\r\n        _getZoom: function(e, i) {\r\n            var a = t.getZoomElement(this.$preview, e, i);\r\n            return this.showPreview && !a.length && this._log(t.logMessages.invalidThumb, {\r\n                id: e\r\n            }), a\r\n        },\r\n        _getThumbs: function(e) {\r\n            return e = e || \"\", this.getFrames(\":not(.file-preview-initial)\" + e)\r\n        },\r\n        _getThumbId: function(e) {\r\n            return this.previewInitId + \"-\" + e\r\n        },\r\n        _getExtraData: function(e, t) {\r\n            var i = this.uploadExtraData;\r\n            return \"function\" == typeof this.uploadExtraData && (i = this.uploadExtraData(e, t)), i\r\n        },\r\n        _initXhr: function(e, i) {\r\n            var a = this,\r\n                r = a.fileManager,\r\n                s = function(e) {\r\n                    var s = 0,\r\n                        n = e.total,\r\n                        o = e.loaded || e.position,\r\n                        l = r.getUploadStats(i, o, n);\r\n                    e.lengthComputable && !a.enableResumableUpload && (s = t.round(o \/ n * 100)), i ? a._setFileUploadStats(i, s, l) : a._setProgress(s, null, null, a._getStats(l)), a._raise(\"fileajaxprogress\", [l])\r\n                };\r\n            return e.upload && (a.progressDelay && (s = t.debounce(s, a.progressDelay)), e.upload.addEventListener(\"progress\", s, !1)), e\r\n        },\r\n        _initAjaxSettings: function() {\r\n            this._ajaxSettings = e.extend(!0, {}, this.ajaxSettings), this._ajaxDeleteSettings = e.extend(!0, {}, this.ajaxDeleteSettings)\r\n        },\r\n        _mergeAjaxCallback: function(e, t, i) {\r\n            var a, r = this._ajaxSettings,\r\n                s = this.mergeAjaxCallbacks;\r\n            \"delete\" === i && (r = this._ajaxDeleteSettings, s = this.mergeAjaxDeleteCallbacks), a = r[e], r[e] = s && \"function\" == typeof a ? \"before\" === s ? function() {\r\n                a.apply(this, arguments), t.apply(this, arguments)\r\n            } : function() {\r\n                t.apply(this, arguments), a.apply(this, arguments)\r\n            } : t\r\n        },\r\n        _ajaxSubmit: function(t, i, a, r, s, n, o, l) {\r\n            var d, c, u, p, f = this;\r\n            f._raise(\"filepreajax\", [s, n, o]) && (s.append(\"initialPreview\", JSON.stringify(f.initialPreview)), s.append(\"initialPreviewConfig\", JSON.stringify(f.initialPreviewConfig)), s.append(\"initialPreviewThumbTags\", JSON.stringify(f.initialPreviewThumbTags)), f._initAjaxSettings(), f._mergeAjaxCallback(\"beforeSend\", t), f._mergeAjaxCallback(\"success\", i), f._mergeAjaxCallback(\"complete\", a), f._mergeAjaxCallback(\"error\", r), \"function\" == typeof(l = l || f.uploadUrlThumb || f.uploadUrl) && (l = l()), \"object\" == typeof(u = f._getExtraData(n, o) || {}) && e.each(u, function(e, t) {\r\n                s.append(e, t)\r\n            }), c = {\r\n                xhr: function() {\r\n                    var t = e.ajaxSettings.xhr();\r\n                    return f._initXhr(t, n)\r\n                },\r\n                url: f._encodeURI(l),\r\n                type: \"POST\",\r\n                dataType: \"json\",\r\n                data: s,\r\n                cache: !1,\r\n                processData: !1,\r\n                contentType: !1\r\n            }, d = e.extend(!0, {}, c, f._ajaxSettings), p = f.taskManager.addTask(n + \"-\" + o, function() {\r\n                var t, i, a = this.self;\r\n                t = a.ajaxQueue.shift(), i = e.ajax(t), a.ajaxRequests.push(i)\r\n            }), f.ajaxQueue.push(d), p.runWithContext({\r\n                self: f\r\n            }))\r\n        },\r\n        _mergeArray: function(e, i) {\r\n            var a = t.cleanArray(this[e]),\r\n                r = t.cleanArray(i);\r\n            this[e] = a.concat(r)\r\n        },\r\n        _initUploadSuccess: function(i, a, r) {\r\n            var s, n, o, l, d, c, u, p, f, h = this;\r\n            h.showPreview && \"object\" == typeof i && !e.isEmptyObject(i) ? (void 0 !== i.initialPreview && i.initialPreview.length > 0 && (h.hasInitData = !0, d = i.initialPreview || [], c = i.initialPreviewConfig || [], u = i.initialPreviewThumbTags || [], s = void 0 === i.append || i.append, d.length > 0 && !t.isArray(d) && (d = d.split(h.initialPreviewDelimiter)), d.length && (h._mergeArray(\"initialPreview\", d), h._mergeArray(\"initialPreviewConfig\", c), h._mergeArray(\"initialPreviewThumbTags\", u)), void 0 !== a ? r ? (p = a.attr(\"id\"), null !== (f = h._getUploadCacheIndex(p)) && (h.uploadCache[f] = {\r\n                id: p,\r\n                content: d[0],\r\n                config: c[0] || [],\r\n                tags: u[0] || [],\r\n                append: s\r\n            })) : (o = h.previewCache.add(d[0], c[0], u[0], s), n = h.previewCache.get(o, !1), l = t.createElement(n).hide().appendTo(a), a.fadeOut(\"slow\", function() {\r\n                var e = l.find(\"> .file-preview-frame\");\r\n                e && e.length && e.insertBefore(a).fadeIn(\"slow\").css(\"display:inline-block\"), h._initPreviewActions(), h._clearFileInput(), a.remove(), l.remove(), h._initSortable()\r\n            })) : (h.previewCache.set(d, c, u, s), h._initPreview(), h._initPreviewActions())), h._resetCaption()) : h._resetCaption()\r\n        },\r\n        _getUploadCacheIndex: function(e) {\r\n            var t, i = this.uploadCache.length;\r\n            for (t = 0; t < i; t++)\r\n                if (this.uploadCache[t].id === e) return t;\r\n            return null\r\n        },\r\n        _initSuccessThumbs: function() {\r\n            var i = this;\r\n            i.showPreview && setTimeout(function() {\r\n                i._getThumbs(t.FRAMES + \".file-preview-success\").each(function() {\r\n                    var a = e(this),\r\n                        r = a.find(\".kv-file-remove\");\r\n                    r.removeAttr(\"disabled\"), i._handler(r, \"click\", function() {\r\n                        var e = a.attr(\"id\"),\r\n                            r = i._raise(\"filesuccessremove\", [e, a.attr(\"data-fileindex\")]);\r\n                        t.cleanMemory(a), !1 !== r && (i.$caption.attr(\"title\", \"\"), a.fadeOut(\"slow\", function() {\r\n                            i.fileManager;\r\n                            a.remove(), i.getFrames().length || i.reset()\r\n                        }))\r\n                    })\r\n                })\r\n            }, i.processDelay)\r\n        },\r\n        _updateInitialPreview: function() {\r\n            var t = this,\r\n                i = t.uploadCache;\r\n            t.showPreview && (e.each(i, function(e, i) {\r\n                t.previewCache.add(i.content, i.config, i.tags, i.append)\r\n            }), t.hasInitData && (t._initPreview(), t._initPreviewActions()))\r\n        },\r\n        _getThumbFileId: function(e) {\r\n            return this.showPreview && void 0 !== e ? e.attr(\"data-fileid\") : null\r\n        },\r\n        _getThumbFile: function(e) {\r\n            var t = this._getThumbFileId(e);\r\n            return t ? this.fileManager.getFile(t) : null\r\n        },\r\n        _uploadSingle: function(i, a, r) {\r\n            var s, n, o, l, d, c, u, p, f, h, m, g, v, w = this,\r\n                b = w.fileManager,\r\n                _ = b.count(),\r\n                C = new FormData,\r\n                x = w._getThumbId(a),\r\n                y = _ > 0 || !e.isEmptyObject(w.uploadExtraData),\r\n                T = w.ajaxOperations.uploadThumb,\r\n                P = b.getFile(a),\r\n                k = {\r\n                    id: x,\r\n                    index: i,\r\n                    fileId: a\r\n                },\r\n                F = w.fileManager.getFileName(a, !0);\r\n            w.enableResumableUpload || (w.showPreview && (n = b.getThumb(a), u = n.find(\".file-thumb-progress\"), l = n.find(\".kv-file-upload\"), d = n.find(\".kv-file-remove\"), u.show()), 0 === _ || !y || w.showPreview && l && l.hasClass(\"disabled\") || w._abort(k) || (v = function() {\r\n                c ? b.errors.push(a) : b.removeFile(a), b.setProcessed(a), b.isProcessed() && (w.fileBatchCompleted = !0, o())\r\n            }, o = function() {\r\n                var e;\r\n                w.fileBatchCompleted && setTimeout(function() {\r\n                    var i = 0 === b.count(),\r\n                        a = b.errors.length;\r\n                    w._updateInitialPreview(), w.unlock(i), i && w._clearFileInput(), e = w.$preview.find(\".file-preview-initial\"), w.uploadAsync && e.length && (t.addCss(e, t.SORT_CSS), w._initSortable()), w._raise(\"filebatchuploadcomplete\", [b.stack, w._getExtraData()]), w.retryErrorUploads && 0 !== a || b.clear(), w._setProgress(101), w.ajaxAborted = !1\r\n                }, w.processDelay)\r\n            }, p = function(o) {\r\n                s = w._getOutData(C, o), b.initStats(a), w.fileBatchCompleted = !1, r || (w.ajaxAborted = !1), w.showPreview && (n.hasClass(\"file-preview-success\") || (w._setThumbStatus(n, \"Loading\"), t.addCss(n, \"file-uploading\")), l.attr(\"disabled\", !0), d.attr(\"disabled\", !0)), r || w.lock(), -1 !== b.errors.indexOf(a) && delete b.errors[a], w._raise(\"filepreupload\", [s, x, i, w._getThumbFileId(n)]), e.extend(!0, k, s), w._abort(k) && (o.abort(), r || (w._setThumbStatus(n, \"New\"), n.removeClass(\"file-uploading\"), l.removeAttr(\"disabled\"), d.removeAttr(\"disabled\")), w._setProgressCancelled())\r\n            }, h = function(o, d, p) {\r\n                var h = w.showPreview && n.attr(\"id\") ? n.attr(\"id\") : x;\r\n                s = w._getOutData(C, p, o), e.extend(!0, k, s), setTimeout(function() {\r\n                    t.isEmpty(o) || t.isEmpty(o.error) ? (w.showPreview && (w._setThumbStatus(n, \"Success\"), l.hide(), w._initUploadSuccess(o, n, r), w._setProgress(101, u)), w._raise(\"fileuploaded\", [s, h, i, w._getThumbFileId(n)]), r ? v() : w.fileManager.remove(n)) : (c = !0, f = w._parseError(T, p, w.msgUploadError, w.fileManager.getFileName(a)), w._showFileError(f, k), w._setPreviewError(n, !0), w.retryErrorUploads || l.hide(), r && v(), w._setProgress(101, w._getFrame(h).find(\".file-thumb-progress\"), w.msgUploadError))\r\n                }, w.processDelay)\r\n            }, m = function() {\r\n                w.showPreview && (l.removeAttr(\"disabled\"), d.removeAttr(\"disabled\"), n.removeClass(\"file-uploading\")), r ? o() : (w.unlock(!1), w._clearFileInput()), w._initSuccessThumbs()\r\n            }, g = function(t, i, s) {\r\n                f = w._parseError(T, t, s, w.fileManager.getFileName(a)), c = !0, setTimeout(function() {\r\n                    var i;\r\n                    r && v(), w.fileManager.setProgress(a, 100), w._setPreviewError(n, !0), w.retryErrorUploads || l.hide(), e.extend(!0, k, w._getOutData(C, t)), w._setProgress(101, w.$progress, w.msgAjaxProgressError.replace(\"{operation}\", T)), i = w.showPreview && n ? n.find(\".file-thumb-progress\") : \"\", w._setProgress(101, i, w.msgUploadError), w._showFileError(f, k)\r\n                }, w.processDelay)\r\n            }, w._setFileData(C, P.file, F, a), w._setUploadData(C, {\r\n                fileId: a\r\n            }), w._ajaxSubmit(p, h, m, g, C, a, i)))\r\n        },\r\n        _setFileData: function(e, t, i, a) {\r\n            var r = this.preProcessUpload;\r\n            r && \"function\" == typeof r ? e.append(this.uploadFileAttr, r(a, t)) : e.append(this.uploadFileAttr, t, i)\r\n        },\r\n        _checkBatchPreupload: function(t, i) {\r\n            var a = this;\r\n            return !!a._raise(\"filebatchpreupload\", [t]) || (a._abort(t), i && i.abort(), a._getThumbs().each(function() {\r\n                var t = e(this),\r\n                    i = t.find(\".kv-file-upload\"),\r\n                    r = t.find(\".kv-file-remove\");\r\n                t.hasClass(\"file-preview-loading\") && (a._setThumbStatus(t, \"New\"), t.removeClass(\"file-uploading\")), i.removeAttr(\"disabled\"), r.removeAttr(\"disabled\")\r\n            }), a._setProgressCancelled(), !1)\r\n        },\r\n        _uploadBatch: function() {\r\n            var i, a, r, s, n, o, l = this,\r\n                d = l.fileManager,\r\n                c = d.total(),\r\n                u = c > 0 || !e.isEmptyObject(l.uploadExtraData),\r\n                p = new FormData,\r\n                f = l.ajaxOperations.uploadBatch;\r\n            if (0 !== c && u && !l._abort({})) {\r\n                o = function() {\r\n                    l.fileManager.clear(), l._clearFileInput()\r\n                }, i = function(i) {\r\n                    l.lock(), d.initStats();\r\n                    var a = l._getOutData(p, i);\r\n                    l.ajaxAborted = !1, l.showPreview && l._getThumbs().each(function() {\r\n                        var i = e(this),\r\n                            a = i.find(\".kv-file-upload\"),\r\n                            r = i.find(\".kv-file-remove\");\r\n                        i.hasClass(\"file-preview-success\") || (l._setThumbStatus(i, \"Loading\"), t.addCss(i, \"file-uploading\")), a.attr(\"disabled\", !0), r.attr(\"disabled\", !0)\r\n                    }), l._checkBatchPreupload(a, i)\r\n                }, a = function(i, a, r) {\r\n                    var s = l._getOutData(p, r, i),\r\n                        d = 0,\r\n                        c = l._getThumbs(\":not(.file-preview-success)\"),\r\n                        u = t.isEmpty(i) || t.isEmpty(i.errorkeys) ? [] : i.errorkeys;\r\n                    t.isEmpty(i) || t.isEmpty(i.error) ? (l._raise(\"filebatchuploadsuccess\", [s]), o(), l.showPreview ? (c.each(function() {\r\n                        var t = e(this);\r\n                        l._setThumbStatus(t, \"Success\"), t.removeClass(\"file-uploading\"), t.find(\".kv-file-upload\").hide().removeAttr(\"disabled\")\r\n                    }), l._initUploadSuccess(i)) : l.reset(), l._setProgress(101)) : (l.showPreview && (c.each(function() {\r\n                        var t = e(this);\r\n                        t.removeClass(\"file-uploading\"), t.find(\".kv-file-upload\").removeAttr(\"disabled\"), t.find(\".kv-file-remove\").removeAttr(\"disabled\"), 0 === u.length || -1 !== e.inArray(d, u) ? (l._setPreviewError(t, !0), l.retryErrorUploads || (t.find(\".kv-file-upload\").hide(), l.fileManager.remove(t))) : (t.find(\".kv-file-upload\").hide(), l._setThumbStatus(t, \"Success\"), l.fileManager.remove(t)), t.hasClass(\"file-preview-error\") && !l.retryErrorUploads || d++\r\n                    }), l._initUploadSuccess(i)), n = l._parseError(f, r, l.msgUploadError), l._showFileError(n, s, \"filebatchuploaderror\"), l._setProgress(101, l.$progress, l.msgUploadError))\r\n                }, s = function() {\r\n                    l.unlock(), l._initSuccessThumbs(), l._clearFileInput(), l._raise(\"filebatchuploadcomplete\", [l.fileManager.stack, l._getExtraData()])\r\n                }, r = function(t, i, a) {\r\n                    var r = l._getOutData(p, t);\r\n                    n = l._parseError(f, t, a), l._showFileError(n, r, \"filebatchuploaderror\"), l.uploadFileCount = c - 1, l.showPreview && (l._getThumbs().each(function() {\r\n                        var t = e(this);\r\n                        t.removeClass(\"file-uploading\"), l._getThumbFile(t) && l._setPreviewError(t)\r\n                    }), l._getThumbs().removeClass(\"file-uploading\"), l._getThumbs(\" .kv-file-upload\").removeAttr(\"disabled\"), l._getThumbs(\" .kv-file-delete\").removeAttr(\"disabled\"), l._setProgress(101, l.$progress, l.msgAjaxProgressError.replace(\"{operation}\", f)))\r\n                };\r\n                var h = 0;\r\n                e.each(l.fileManager.stack, function(e, i) {\r\n                    t.isEmpty(i.file) || l._setFileData(p, i.file, i.nameFmt || \"untitled_\" + h, e), h++\r\n                }), l._ajaxSubmit(i, a, s, r, p)\r\n            }\r\n        },\r\n        _uploadExtraOnly: function() {\r\n            var e, i, a, r, s, n = this,\r\n                o = {},\r\n                l = new FormData,\r\n                d = n.ajaxOperations.uploadExtra;\r\n            e = function(e) {\r\n                n.lock();\r\n                var t = n._getOutData(l, e);\r\n                n._setProgress(50), o.data = t, o.xhr = e, n._checkBatchPreupload(t, e)\r\n            }, i = function(e, i, a) {\r\n                var r = n._getOutData(l, a, e);\r\n                t.isEmpty(e) || t.isEmpty(e.error) ? (n._raise(\"filebatchuploadsuccess\", [r]), n._clearFileInput(), n._initUploadSuccess(e), n._setProgress(101)) : (s = n._parseError(d, a, n.msgUploadError), n._showFileError(s, r, \"filebatchuploaderror\"))\r\n            }, a = function() {\r\n                n.unlock(), n._clearFileInput(), n._raise(\"filebatchuploadcomplete\", [n.fileManager.stack, n._getExtraData()])\r\n            }, r = function(e, t, i) {\r\n                var a = n._getOutData(l, e);\r\n                s = n._parseError(d, e, i), o.data = a, n._showFileError(s, a, \"filebatchuploaderror\"), n._setProgress(101, n.$progress, n.msgAjaxProgressError.replace(\"{operation}\", d))\r\n            }, n._ajaxSubmit(e, i, a, r, l)\r\n        },\r\n        _deleteFileIndex: function(i) {\r\n            var a = i.attr(\"data-fileindex\"),\r\n                r = this.reversePreviewOrder;\r\n            a.substring(0, 5) === t.INIT_FLAG && (a = parseInt(a.replace(t.INIT_FLAG, \"\")), this.initialPreview = t.spliceArray(this.initialPreview, a, r), this.initialPreviewConfig = t.spliceArray(this.initialPreviewConfig, a, r), this.initialPreviewThumbTags = t.spliceArray(this.initialPreviewThumbTags, a, r), this.getFrames().each(function() {\r\n                var i = e(this),\r\n                    r = i.attr(\"data-fileindex\");\r\n                r.substring(0, 5) === t.INIT_FLAG && (r = parseInt(r.replace(t.INIT_FLAG, \"\"))) > a && (r--, i.attr(\"data-fileindex\", t.INIT_FLAG + r))\r\n            }))\r\n        },\r\n        _resetCaption: function() {\r\n            var e = this;\r\n            setTimeout(function() {\r\n                var t, i, a, r = \"\",\r\n                    s = e.previewCache.count(!0),\r\n                    n = e.fileManager.count(),\r\n                    o = e.showPreview && e.getFrames(\":not(.file-preview-success):not(.file-preview-error)\").length;\r\n                0 !== n || 0 !== s || o ? ((t = s + n) > 1 ? r = e._getMsgSelected(t) : 0 === n ? (r = \"\", (a = e.initialPreviewConfig[0]) && (r = a.caption || a.filename || \"\"), r || (r = e._getMsgSelected(t))) : r = (i = e.fileManager.getFirstFile()) ? i.nameFmt : \"_\", e._setCaption(r)) : e.reset()\r\n            }, e.processDelay)\r\n        },\r\n        _initFileActions: function() {\r\n            var i = this;\r\n            i.showPreview && (i._initZoomButton(), i.getFrames(\" .kv-file-remove\").each(function() {\r\n                var a, r = e(this),\r\n                    s = r.closest(t.FRAMES),\r\n                    n = s.attr(\"id\"),\r\n                    o = s.attr(\"data-fileindex\");\r\n                i.fileManager;\r\n                i._handler(r, \"click\", function() {\r\n                    if (!1 === i._raise(\"filepreremove\", [n, o]) || !i._validateMinCount()) return !1;\r\n                    a = s.hasClass(\"file-preview-error\"), t.cleanMemory(s), s.fadeOut(\"slow\", function() {\r\n                        i.fileManager.remove(s), i._clearObjects(s), s.remove(), n && a && i.$errorContainer.find('li[data-thumb-id=\"' + n + '\"]').fadeOut(\"fast\", function() {\r\n                            e(this).remove(), i._errorsExist() || i._resetErrors()\r\n                        }), i._clearFileInput(), i._resetCaption(), i._raise(\"fileremoved\", [n, o])\r\n                    })\r\n                })\r\n            }), i.getFrames(\" .kv-file-upload\").each(function() {\r\n                var a = e(this);\r\n                i._handler(a, \"click\", function() {\r\n                    var e = a.closest(t.FRAMES),\r\n                        r = i._getThumbFileId(e);\r\n                    i._hideProgress(), e.hasClass(\"file-preview-error\") && !i.retryErrorUploads || i._uploadSingle(i.fileManager.getIndex(r), r, !1)\r\n                })\r\n            }))\r\n        },\r\n        _initPreviewActions: function() {\r\n            var i = this,\r\n                a = i.$preview,\r\n                r = i.deleteExtraData || {},\r\n                s = t.FRAMES + \" .kv-file-remove\",\r\n                n = i.fileActionSettings,\r\n                o = n.removeClass,\r\n                l = n.removeErrorClass,\r\n                d = function() {\r\n                    var e = i.isAjaxUpload ? i.previewCache.count(!0) : i._inputFileCount();\r\n                    i.getFrames().length || e ? i._resetCaption() : (i._setCaption(\"\"), i.reset(), i.initialCaption = \"\")\r\n                };\r\n            i._initZoomButton(), a.find(s).each(function() {\r\n                var a, s, n, c, u = e(this),\r\n                    p = u.data(\"url\") || i.deleteUrl,\r\n                    f = u.data(\"key\"),\r\n                    h = i.ajaxOperations.deleteThumb;\r\n                if (!t.isEmpty(p) && void 0 !== f) {\r\n                    \"function\" == typeof p && (p = p());\r\n                    var m, g, v, w, b, _ = u.closest(t.FRAMES),\r\n                        C = i.previewCache.data,\r\n                        x = _.attr(\"data-fileindex\");\r\n                    x = parseInt(x.replace(t.INIT_FLAG, \"\")), v = t.isEmpty(C.config) && t.isEmpty(C.config[x]) ? null : C.config[x], b = t.isEmpty(v) || t.isEmpty(v.extra) ? r : v.extra, w = v && (v.filename || v.caption) || \"\", \"function\" == typeof b && (b = b()), g = {\r\n                        id: u.attr(\"id\"),\r\n                        key: f,\r\n                        extra: b\r\n                    }, s = function(e) {\r\n                        i.ajaxAborted = !1, i._raise(\"filepredelete\", [f, e, b]), i._abort() ? e.abort() : (u.removeClass(l), t.addCss(_, \"file-uploading\"), t.addCss(u, \"disabled \" + o))\r\n                    }, n = function(e, r, s) {\r\n                        var n, c;\r\n                        if (!t.isEmpty(e) && !t.isEmpty(e.error)) return g.jqXHR = s, g.response = e, a = i._parseError(h, s, i.msgDeleteError, w), i._showFileError(a, g, \"filedeleteerror\"), _.removeClass(\"file-uploading\"), u.removeClass(\"disabled \" + o).addClass(l), void d();\r\n                        _.removeClass(\"file-uploading\").addClass(\"file-deleted\"), _.fadeOut(\"slow\", function() {\r\n                            x = parseInt(_.attr(\"data-fileindex\").replace(t.INIT_FLAG, \"\")), i.previewCache.unset(x), i._deleteFileIndex(_), n = i.previewCache.count(!0), c = n > 0 ? i._getMsgSelected(n) : \"\", i._setCaption(c), i._raise(\"filedeleted\", [f, s, b]), i._clearObjects(_), _.remove(), d()\r\n                        })\r\n                    }, c = function(e, t, a) {\r\n                        var r = i._parseError(h, e, a, w);\r\n                        g.jqXHR = e, g.response = {}, i._showFileError(r, g, \"filedeleteerror\"), _.removeClass(\"file-uploading\"), u.removeClass(\"disabled \" + o).addClass(l), d()\r\n                    }, i._initAjaxSettings(), i._mergeAjaxCallback(\"beforeSend\", s, \"delete\"), i._mergeAjaxCallback(\"success\", n, \"delete\"), i._mergeAjaxCallback(\"error\", c, \"delete\"), m = e.extend(!0, {}, {\r\n                        url: i._encodeURI(p),\r\n                        type: \"POST\",\r\n                        dataType: \"json\",\r\n                        data: e.extend(!0, {}, {\r\n                            key: f\r\n                        }, b)\r\n                    }, i._ajaxDeleteSettings), i._handler(u, \"click\", function() {\r\n                        if (!i._validateMinCount()) return !1;\r\n                        i.ajaxAborted = !1, i._raise(\"filebeforedelete\", [f, b]), i.ajaxAborted instanceof Promise ? i.ajaxAborted.then(function(t) {\r\n                            t || e.ajax(m)\r\n                        }) : i.ajaxAborted || e.ajax(m)\r\n                    })\r\n                }\r\n            })\r\n        },\r\n        _hideFileIcon: function() {\r\n            this.overwriteInitial && this.$captionContainer.removeClass(\"icon-visible\")\r\n        },\r\n        _showFileIcon: function() {\r\n            t.addCss(this.$captionContainer, \"icon-visible\")\r\n        },\r\n        _getSize: function(t, i) {\r\n            var a, r, s = parseFloat(t),\r\n                n = this.fileSizeGetter;\r\n            return e.isNumeric(t) && e.isNumeric(s) ? (\"function\" == typeof n ? r = n(s) : 0 === s ? r = \"0.00 B\" : (i || (i = this.sizeUnits), a = Math.floor(Math.log(s) \/ Math.log(this.bytesToKB)), r = (s \/ Math.pow(this.bytesToKB, a)).toFixed(2) + \" \" + i[a]), this._getLayoutTemplate(\"size\").replace(\"{sizeText}\", r)) : \"\"\r\n        },\r\n        _getFileType: function(e) {\r\n            return this.mimeTypeAliases[e] || e\r\n        },\r\n        _generatePreviewTemplate: function(i, a, r, s, n, o, l, d, c, u, p, f, h, m) {\r\n            var g, v, w = this,\r\n                b = w.slug(r),\r\n                _ = \"\",\r\n                C = \"\",\r\n                x = window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth,\r\n                y = b,\r\n                T = b,\r\n                P = \"type-default\",\r\n                k = u || w._renderFileFooter(i, b, d, \"auto\", l),\r\n                F = w.preferIconicPreview,\r\n                S = w.preferIconicZoomPreview,\r\n                E = F ? \"other\" : i;\r\n            return (g = x < 400 ? w.previewSettingsSmall[E] || w.defaults.previewSettingsSmall[E] : w.previewSettings[E] || w.defaults.previewSettings[E]) && e.each(g, function(e, t) {\r\n                C += e + \":\" + t + \";\"\r\n            }), v = function(a, l, d, u, m) {\r\n                var g, v = d ? \"zoom-\" + n : n,\r\n                    _ = w._getPreviewTemplate(a),\r\n                    x = (c || \"\") + \" \" + u;\r\n                return w.frameClass && (x = w.frameClass + \" \" + x), d && (x = x.replace(\" \" + t.SORT_CSS, \"\")), _ = w._parseFilePreviewIcon(_, r), \"object\" !== i || s || e.each(w.defaults.fileTypeSettings, function(e, t) {\r\n                    \"object\" !== e && \"other\" !== e && t(r, s) && (P = \"type-\" + e)\r\n                }), t.isEmpty(h) || (void 0 !== h.title && null !== h.title && (y = h.title), void 0 !== h.alt && null !== h.alt && (y = h.alt)), g = {\r\n                    previewId: v,\r\n                    caption: b,\r\n                    title: y,\r\n                    alt: T,\r\n                    frameClass: x,\r\n                    type: w._getFileType(s),\r\n                    fileindex: p,\r\n                    fileid: o || \"\",\r\n                    typeCss: P,\r\n                    footer: k,\r\n                    data: d && m ? t.ZOOM_VAR + \"{zoomData}\" : l,\r\n                    template: f || i,\r\n                    style: C ? 'style=\"' + C + '\"' : \"\",\r\n                    zoomData: m ? encodeURIComponent(m) : \"\"\r\n                }, d && (g.zoomCache = \"\", g.zoomData = \"{zoomData}\"), _.setTokens(g)\r\n            }, p = p || n.slice(n.lastIndexOf(\"-\") + 1), w.fileActionSettings.showZoom && (_ = v(S ? \"other\" : i, a, !0, \"kv-zoom-thumb\", m)), _ = \"\\n\" + w._getLayoutTemplate(\"zoomCache\").replace(\"{zoomContent}\", _), \"function\" == typeof w.sanitizeZoomCache && (_ = w.sanitizeZoomCache(_)), v(F ? \"other\" : i, a, !1, \"kv-preview-thumb\", m).setTokens({\r\n                zoomCache: _\r\n            })\r\n        },\r\n        _addToPreview: function(e, i) {\r\n            var a;\r\n            return i = t.cspBuffer.stash(i), a = this.reversePreviewOrder ? e.prepend(i) : e.append(i), t.cspBuffer.apply(e), a\r\n        },\r\n        _previewDefault: function(e, i) {\r\n            var a = this.$preview;\r\n            if (this.showPreview) {\r\n                var r, s = t.getFileName(e),\r\n                    n = e ? e.type : \"\",\r\n                    o = e.size || 0,\r\n                    l = this._getFileName(e, \"\"),\r\n                    d = !0 === i && !this.isAjaxUpload,\r\n                    c = t.createObjectURL(e),\r\n                    u = this.fileManager.getId(e),\r\n                    p = this._getThumbId(u);\r\n                this._clearDefaultPreview(), r = this._generatePreviewTemplate(\"other\", c, s, n, p, u, d, o), this._addToPreview(a, r), this._setThumbAttr(p, l, o), !0 === i && this.isAjaxUpload && this._setThumbStatus(this._getFrame(p), \"Error\")\r\n            }\r\n        },\r\n        _previewFile: function(e, i, a, r, s) {\r\n            if (this.showPreview) {\r\n                var n, o = t.getFileName(i),\r\n                    l = s.type,\r\n                    d = s.name,\r\n                    c = this._parseFileType(l, o),\r\n                    u = this.$preview,\r\n                    p = i.size || 0,\r\n                    f = \"image\" === c ? a.target.result : r,\r\n                    h = this.fileManager.getId(i),\r\n                    m = this._getThumbId(h);\r\n                n = this._generatePreviewTemplate(c, f, o, l, m, h, !1, p), this._clearDefaultPreview(), this._addToPreview(u, n);\r\n                var g = this._getFrame(m);\r\n                this._validateImageOrientation(g.find(\"img\"), i, m, h, d, l, p, f), this._setThumbAttr(m, d, p), this._initSortable()\r\n            }\r\n        },\r\n        _setThumbAttr: function(e, t, i, a) {\r\n            var r = this._getFrame(e);\r\n            r.length && (i = i && i > 0 ? this._getSize(i) : \"\", r.data({\r\n                caption: t,\r\n                size: i,\r\n                description: a || \"\"\r\n            }))\r\n        },\r\n        _setInitThumbAttr: function() {\r\n            var e, i, a, r, s, n = this.previewCache.data,\r\n                o = this.previewCache.count(!0);\r\n            if (0 !== o)\r\n                for (var l = 0; l < o; l++) e = n.config[l], s = this.previewInitId + \"-\" + t.INIT_FLAG + l, i = t.ifSet(\"caption\", e, t.ifSet(\"filename\", e)), a = t.ifSet(\"size\", e), r = t.ifSet(\"description\", e), this._setThumbAttr(s, i, a, r)\r\n        },\r\n        _slugDefault: function(e) {\r\n            return t.isEmpty(e, !0) ? \"\" : String(e).replace(\/[\\[\\]\\\/\\{}:;#%=\\(\\)\\*\\+\\?\\\\\\^\\$\\|<>&\"']\/g, \"_\")\r\n        },\r\n        _updateFileDetails: function(e) {\r\n            var i, a, r, s, n = this.$element,\r\n                o = t.isIE(9) && t.findFileName(n.val()) || n[0].files[0] && n[0].files[0].name;\r\n            i = !o && this.fileManager.count() > 0 ? this.fileManager.getFirstFile().nameFmt : o ? this.slug(o) : \"_\", a = this.isAjaxUpload ? this.fileManager.count() : e, s = this.previewCache.count(!0) + a, r = 1 === a ? i : this._getMsgSelected(s, !this.isAjaxUpload && !this.isError), this.isError ? (this.$previewContainer.removeClass(\"file-thumb-loading\"), this._initCapStatus(), this.$previewStatus.html(\"\"), this.$captionContainer.removeClass(\"icon-visible\")) : this._showFileIcon(), this._setCaption(r, this.isError), this.$container.removeClass(\"file-input-new file-input-ajax-new\"), this._raise(\"fileselect\", [e, i]), this.previewCache.count(!0) && this._initPreviewActions()\r\n        },\r\n        _setThumbStatus: function(e, i) {\r\n            if (this.showPreview) {\r\n                var a = \"indicator\" + i,\r\n                    r = a + \"Title\",\r\n                    s = \"file-preview-\" + i.toLowerCase(),\r\n                    n = e.find(\".file-upload-indicator\"),\r\n                    o = this.fileActionSettings;\r\n                e.removeClass(\"file-preview-success file-preview-error file-preview-paused file-preview-loading\"), \"Success\" === i && e.find(\".file-drag-handle\").remove(), t.setHtml(n, o[a]), n.attr(\"title\", o[r]), e.addClass(s), \"Error\" !== i || this.retryErrorUploads || e.find(\".kv-file-upload\").attr(\"disabled\", !0)\r\n            }\r\n        },\r\n        _setProgressCancelled: function() {\r\n            this._setProgress(101, this.$progress, this.msgCancelled)\r\n        },\r\n        _setProgress: function(e, i, a, r) {\r\n            if ((i = i || this.$progress).length) {\r\n                var s, n = Math.min(e, 100),\r\n                    o = this.progressUploadThreshold,\r\n                    l = e <= 100 ? this.progressTemplate : this.progressCompleteTemplate,\r\n                    d = n < 100 ? this.progressTemplate : a ? this.paused ? this.progressPauseTemplate : this.progressErrorTemplate : l;\r\n                e >= 100 && (r = \"\"), t.isEmpty(d) || (r = r || \"\", s = (s = o && n > o && e <= 100 ? d.setTokens({\r\n                    percent: o,\r\n                    status: this.msgUploadThreshold\r\n                }) : d.setTokens({\r\n                    percent: n,\r\n                    status: e > 100 ? this.msgUploadEnd : n + \"%\"\r\n                })).setTokens({\r\n                    stats: r\r\n                }), t.setHtml(i, s), a && t.setHtml(i.find('[role=\"progressbar\"]'), a))\r\n            }\r\n        },\r\n        _hasFiles: function() {\r\n            var e = this.$element[0];\r\n            return !!(e && e.files && e.files.length)\r\n        },\r\n        _setFileDropZoneTitle: function() {\r\n            var e, i = this.$container.find(\".file-drop-zone\"),\r\n                a = this.dropZoneTitle;\r\n            this.isClickable && (e = t.isEmpty(this.$element.attr(\"multiple\")) ? this.fileSingle : this.filePlural, a += this.dropZoneClickTitle.replace(\"{files}\", e)), i.find(\".\" + this.dropZoneTitleClass).remove(), !this.showPreview || 0 === i.length || this.fileManager.count() > 0 || !this.dropZoneEnabled || !this.isAjaxUpload && this._hasFiles() || (0 === i.find(t.FRAMES).length && t.isEmpty(this.defaultPreviewContent) && i.prepend('<div class=\"' + this.dropZoneTitleClass + '\">' + a + \"<\/div>\"), this.$container.removeClass(\"file-input-new\"), t.addCss(this.$container, \"file-input-ajax-new\"))\r\n        },\r\n        _getStats: function(e) {\r\n            var i, a;\r\n            return this.showUploadStats && e && e.bitrate ? (a = this._getLayoutTemplate(\"stats\"), i = e.elapsed && e.bps ? this.msgPendingTime.setTokens({\r\n                time: t.getElapsed(Math.ceil(e.pendingBytes \/ e.bps))\r\n            }) : this.msgCalculatingTime, a.setTokens({\r\n                uploadSpeed: e.bitrate,\r\n                pendingTime: i\r\n            })) : \"\"\r\n        },\r\n        _setResumableProgress: function(e, t, i) {\r\n            var a = this.resumableManager,\r\n                r = i ? a : this,\r\n                s = i ? i.find(\".file-thumb-progress\") : null;\r\n            0 === r.lastProgress && (r.lastProgress = e), e < r.lastProgress && (e = r.lastProgress), this._setProgress(e, s, null, this._getStats(t)), r.lastProgress = e\r\n        },\r\n        _toggleResumableProgress: function(e, i) {\r\n            var a = this.$progress;\r\n            a && a.length && t.setHtml(a, e.setTokens({\r\n                percent: 101,\r\n                status: i,\r\n                stats: \"\"\r\n            }))\r\n        },\r\n        _setFileUploadStats: function(i, a, r) {\r\n            var s = this.$progress;\r\n            if (this.showPreview || s && s.length) {\r\n                var n, o = this.fileManager,\r\n                    l = this.resumableManager,\r\n                    d = o.getThumb(i),\r\n                    c = 0,\r\n                    u = o.getTotalSize(),\r\n                    p = e.extend(!0, {}, r);\r\n                if (this.enableResumableUpload) {\r\n                    var f, h = r.loaded,\r\n                        m = l.getUploadedSize(),\r\n                        g = l.file.size;\r\n                    h += m, f = o.uploadedSize + h, a = t.round(100 * h \/ g), r.pendingBytes = g - m, this._setResumableProgress(a, r, d), n = Math.floor(100 * f \/ u), p.pendingBytes = u - f, this._setResumableProgress(n, p)\r\n                } else o.setProgress(i, a), s = d && d.length ? d.find(\".file-thumb-progress\") : null, this._setProgress(a, s, null, this._getStats(r)), e.each(o.stats, function(e, t) {\r\n                    c += t.loaded\r\n                }), p.pendingBytes = u - c, n = t.round(c \/ u * 100), this._setProgress(n, null, null, this._getStats(p))\r\n            }\r\n        },\r\n        _validateMinCount: function() {\r\n            var e = this.isAjaxUpload ? this.fileManager.count() : this._inputFileCount();\r\n            return !(this.validateInitialCount && this.minFileCount > 0 && this._getFileCount(e - 1) < this.minFileCount) || (this._noFilesError({}), !1)\r\n        },\r\n        _getFileCount: function(e, t) {\r\n            return void 0 === t && (t = this.validateInitialCount && !this.overwriteInitial), t && (e += this.previewCache.count(!0)), e\r\n        },\r\n        _getFileId: function(e) {\r\n            return t.getFileId(e, this.generateFileId)\r\n        },\r\n        _getFileName: function(e, i) {\r\n            var a = t.getFileName(e);\r\n            return a ? this.slug(a) : i\r\n        },\r\n        _getFileNames: function(e) {\r\n            return this.filenames.filter(function(t) {\r\n                return e ? void 0 !== t : null != t\r\n            })\r\n        },\r\n        _setPreviewError: function(e, t) {\r\n            var i = this.removeFromPreviewOnError && !this.retryErrorUploads;\r\n            t && !i || this.fileManager.remove(e), this.showPreview && (i ? e.remove() : (this._setThumbStatus(e, \"Error\"), this._refreshUploadButton(e)))\r\n        },\r\n        _refreshUploadButton: function(e) {\r\n            var i = e.find(\".kv-file-upload\"),\r\n                a = this.fileActionSettings,\r\n                r = a.uploadIcon,\r\n                s = a.uploadTitle;\r\n            i.length && (this.retryErrorUploads && (r = a.uploadRetryIcon, s = a.uploadRetryTitle), i.attr(\"title\", s), t.setHtml(i, r))\r\n        },\r\n        _checkDimensions: function(e, i, a, r, s, n, o) {\r\n            var l, d, c, u = this[(\"Small\" === i ? \"min\" : \"max\") + \"Image\" + n];\r\n            !t.isEmpty(u) && a.length && (c = a[0], d = \"Width\" === n ? c.naturalWidth || c.width : c.naturalHeight || c.height, (\"Small\" === i ? d >= u : d <= u) || (l = this[\"msgImage\" + n + i].setTokens({\r\n                name: s,\r\n                size: u\r\n            }), this._showFileError(l, o), this._setPreviewError(r)))\r\n        },\r\n        _getExifObj: function(e) {\r\n            var i, a = t.logMessages.exifWarning;\r\n            if (\"data:image\/jpeg;base64,\" === e.slice(0, 23) || \"data:image\/jpg;base64,\" === e.slice(0, 22)) {\r\n                try {\r\n                    i = window.piexif ? window.piexif.load(e) : null\r\n                } catch (e) {\r\n                    i = null, a = e && e.message || \"\"\r\n                }\r\n                return i || this._log(t.logMessages.badExifParser, {\r\n                    details: a\r\n                }), i\r\n            }\r\n            i = null\r\n        },\r\n        setImageOrientation: function(i, a, r, s) {\r\n            var n, o, l, d = this,\r\n                c = !i || !i.length,\r\n                u = !a || !a.length,\r\n                p = !1,\r\n                f = c && s && \"image\" === s.attr(\"data-template\");\r\n            c && u || (l = \"load.fileinputimageorient\", f ? (i = a, a = null, i.css(d.previewSettings.image), o = e(document.createElement(\"div\")).appendTo(s.find(\".kv-file-content\")), n = e(document.createElement(\"span\")).insertBefore(i), i.css(\"visibility\", \"hidden\").removeClass(\"file-zoom-detail\").appendTo(o)) : p = !i.is(\":visible\"), i.off(l).on(l, function() {\r\n                p && (d.$preview.removeClass(\"hide-content\"), s.find(\".kv-file-content\").css(\"visibility\", \"hidden\"));\r\n                var e = i[0],\r\n                    l = a && a.length ? a[0] : null,\r\n                    c = e.offsetHeight,\r\n                    u = e.offsetWidth,\r\n                    h = t.getRotation(r);\r\n                if (p && (s.find(\".kv-file-content\").css(\"visibility\", \"visible\"), d.$preview.addClass(\"hide-content\")), i.data(\"orientation\", r), l && a.data(\"orientation\", r), r < 5) return t.setTransform(e, h), void t.setTransform(l, h);\r\n                var m = Math.atan(u \/ c),\r\n                    g = Math.sqrt(Math.pow(c, 2) + Math.pow(u, 2)),\r\n                    v = g ? c \/ Math.cos(Math.PI \/ 2 + m) \/ g : 1,\r\n                    w = \" scale(\" + Math.abs(v) + \")\";\r\n                t.setTransform(e, h + w), t.setTransform(l, h + w), f && (i.css(\"visibility\", \"visible\").insertAfter(n).addClass(\"file-zoom-detail\"), n.remove(), o.remove())\r\n            }))\r\n        },\r\n        _validateImageOrientation: function(i, a, r, s, n, o, l, d) {\r\n            var c, u, p = null,\r\n                f = this.autoOrientImage;\r\n            if (this.canOrientImage) return i.css(\"image-orientation\", f ? \"from-image\" : \"none\"), void this._validateImage(r, s, n, o, l, d, p);\r\n            u = t.getZoomSelector(r, \" img\"), (c = (p = f ? this._getExifObj(d) : null) ? p[\"0th\"][piexif.ImageIFD.Orientation] : null) ? (this.setImageOrientation(i, e(u), c, this._getFrame(r)), this._raise(\"fileimageoriented\", {\r\n                $img: i,\r\n                file: a\r\n            }), this._validateImage(r, s, n, o, l, d, p)) : this._validateImage(r, s, n, o, l, d, p)\r\n        },\r\n        _validateImage: function(e, t, i, a, r, s, n) {\r\n            var o, l, d, c = this,\r\n                u = c.$preview,\r\n                p = c._getFrame(e),\r\n                f = p.attr(\"data-fileindex\"),\r\n                h = p.find(\"img\");\r\n            i = i || \"Untitled\", h.one(\"load\", function() {\r\n                l = p.width(), d = u.width(), l > d && h.css(\"width\", \"100%\"), o = {\r\n                    ind: f,\r\n                    id: e,\r\n                    fileId: t\r\n                }, c._checkDimensions(f, \"Small\", h, p, i, \"Width\", o), c._checkDimensions(f, \"Small\", h, p, i, \"Height\", o), c.resizeImage || (c._checkDimensions(f, \"Large\", h, p, i, \"Width\", o), c._checkDimensions(f, \"Large\", h, p, i, \"Height\", o)), c._raise(\"fileimageloaded\", [e]), c.fileManager.addImage(t, {\r\n                    ind: f,\r\n                    img: h,\r\n                    thumb: p,\r\n                    pid: e,\r\n                    typ: a,\r\n                    siz: r,\r\n                    validated: !1,\r\n                    imgData: s,\r\n                    exifObj: n\r\n                }), p.data(\"exif\", n), c._validateAllImages()\r\n            }).one(\"error\", function() {\r\n                c._raise(\"fileimageloaderror\", [e])\r\n            })\r\n        },\r\n        _validateAllImages: function() {\r\n            var t, i = this,\r\n                a = {\r\n                    val: 0\r\n                },\r\n                r = i.fileManager.getImageCount(),\r\n                s = i.resizeIfSizeMoreThan;\r\n            r === i.fileManager.totalImages && (i._raise(\"fileimagesloaded\"), i.resizeImage && e.each(i.fileManager.loadedImages, function(e, n) {\r\n                n.validated || ((t = n.siz) && t > s * i.bytesToKB && i._getResizedImage(e, n, a, r), n.validated = !0)\r\n            }))\r\n        },\r\n        _getResizedImage: function(i, a, r, s) {\r\n            var n, o, l, d, c, u, p, f, h, m = this,\r\n                g = e(a.img)[0],\r\n                v = g.naturalWidth,\r\n                w = g.naturalHeight,\r\n                b = 1,\r\n                _ = m.maxImageWidth || v,\r\n                C = m.maxImageHeight || w,\r\n                x = !(!v || !w),\r\n                y = m.imageCanvas,\r\n                T = m.imageCanvasContext,\r\n                P = a.typ,\r\n                k = a.pid,\r\n                F = a.ind,\r\n                S = a.thumb,\r\n                E = a.exifObj;\r\n            if (c = function(e, t, i) {\r\n                    m.isAjaxUpload ? m._showFileError(e, t, i) : m._showError(e, t, i), m._setPreviewError(S)\r\n                }, f = {\r\n                    id: k,\r\n                    index: F,\r\n                    fileId: i\r\n                }, h = [i, k, F], (p = m.fileManager.getFile(i)) && x && !(v <= _ && w <= C) || (x && p && m._raise(\"fileimageresized\", h), r.val++, r.val === s && m._raise(\"fileimagesresized\"), x)) {\r\n                P = P || m.resizeDefaultImageType, o = v > _, l = w > C, b = \"width\" === m.resizePreference ? o ? _ \/ v : l ? C \/ w : 1 : l ? C \/ w : o ? _ \/ v : 1, m._resetCanvas(), v *= b, w *= b, y.width = v, y.height = w;\r\n                try {\r\n                    T.drawImage(g, 0, 0, v, w), d = y.toDataURL(P, m.resizeQuality), E && (u = window.piexif.dump(E), d = window.piexif.insert(u, d)), n = t.dataURI2Blob(d), m.fileManager.setFile(i, n), m._raise(\"fileimageresized\", h), r.val++, r.val === s && m._raise(\"fileimagesresized\", [void 0, void 0]), n instanceof Blob || c(m.msgImageResizeError, f, \"fileimageresizeerror\")\r\n                } catch (e) {\r\n                    r.val++, r.val === s && m._raise(\"fileimagesresized\", [void 0, void 0]), c(m.msgImageResizeException.replace(\"{errors}\", e.message), f, \"fileimageresizeexception\")\r\n                }\r\n            } else c(m.msgImageResizeError, f, \"fileimageresizeerror\")\r\n        },\r\n        _showProgress: function() {\r\n            this.$progress && this.$progress.length && this.$progress.show()\r\n        },\r\n        _hideProgress: function() {\r\n            this.$progress && this.$progress.length && this.$progress.hide()\r\n        },\r\n        _initBrowse: function(e) {\r\n            var i = this.$element;\r\n            this.showBrowse ? this.$btnFile = e.find(\".btn-file\").append(i) : (i.appendTo(e).attr(\"tabindex\", -1), t.addCss(i, \"file-no-browse\"))\r\n        },\r\n        _initClickable: function() {\r\n            var i, a, r = this;\r\n            r.isClickable && (i = r.$dropZone, r.isAjaxUpload || (a = r.$preview.find(\".file-default-preview\")).length && (i = a), t.addCss(i, \"clickable\"), i.attr(\"tabindex\", -1), r._handler(i, \"click\", function(t) {\r\n                var a = e(t.target);\r\n                r.$errorContainer.is(\":visible\") || a.parents(\".file-preview-thumbnails\").length && !a.parents(\".file-default-preview\").length || (r.$element.data(\"zoneClicked\", !0).trigger(\"click\"), i.blur())\r\n            }))\r\n        },\r\n        _initCaption: function() {\r\n            var e = this.initialCaption || \"\";\r\n            return this.overwriteInitial || t.isEmpty(e) ? (this.$caption.val(\"\"), !1) : (this._setCaption(e), !0)\r\n        },\r\n        _setCaption: function(i, a) {\r\n            var r, s, n, o, l, d;\r\n            if (this.$caption.length) {\r\n                if (this.$captionContainer.removeClass(\"icon-visible\"), a) r = e(\"<div>\" + this.msgValidationError + \"<\/div>\").text(), (o = this.fileManager.count()) ? (d = this.fileManager.getFirstFile(), l = 1 === o && d ? d.nameFmt : this._getMsgSelected(o)) : l = this._getMsgSelected(this.msgNo), s = t.isEmpty(i) ? l : i, n = '<span class=\"' + this.msgValidationErrorClass + '\">' + this.msgValidationErrorIcon + \"<\/span>\";\r\n                else {\r\n                    if (t.isEmpty(i)) return void this.$caption.attr(\"title\", \"\");\r\n                    s = r = e(\"<div>\" + i + \"<\/div>\").text(), n = this._getLayoutTemplate(\"fileIcon\")\r\n                }\r\n                this.$captionContainer.addClass(\"icon-visible\"), this.$caption.attr(\"title\", r).val(s), t.setHtml(this.$captionIcon, n)\r\n            }\r\n        },\r\n        _createContainer: function() {\r\n            var e = {\r\n                    class: \"file-input file-input-new\" + (this.rtl ? \" kv-rtl\" : \"\")\r\n                },\r\n                i = t.createElement(t.cspBuffer.stash(this._renderMain()));\r\n            return t.cspBuffer.apply(i), i.insertBefore(this.$element).attr(e), this._initBrowse(i), this.theme && i.addClass(\"theme-\" + this.theme), i\r\n        },\r\n        _refreshContainer: function() {\r\n            var e = this.$container;\r\n            this.$element.insertAfter(e), t.setHtml(e, this._renderMain()), this._initBrowse(e), this._validateDisabled()\r\n        },\r\n        _validateDisabled: function() {\r\n            this.$caption.attr({\r\n                readonly: this.isDisabled\r\n            })\r\n        },\r\n        _setTabIndex: function(e, t) {\r\n            var i = this.tabIndexConfig[e];\r\n            return t.setTokens({\r\n                tabIndexConfig: null == i ? \"\" : 'tabindex=\"' + i + '\"'\r\n            })\r\n        },\r\n        _renderMain: function() {\r\n            var e = this.dropZoneEnabled ? \" file-drop-zone\" : \"file-drop-disabled\",\r\n                t = this.showClose ? this._getLayoutTemplate(\"close\") : \"\",\r\n                i = this.showPreview ? this._getLayoutTemplate(\"preview\").setTokens({\r\n                    class: this.previewClass,\r\n                    dropClass: e\r\n                }) : \"\",\r\n                a = this.isDisabled ? this.captionClass + \" file-caption-disabled\" : this.captionClass,\r\n                r = this.captionTemplate.setTokens({\r\n                    class: a + \" kv-fileinput-caption\"\r\n                });\r\n            return r = this._setTabIndex(\"caption\", r), this.mainTemplate.setTokens({\r\n                class: this.mainClass + (!this.showBrowse && this.showCaption ? \" no-browse\" : \"\"),\r\n                inputGroupClass: this.inputGroupClass,\r\n                preview: i,\r\n                close: t,\r\n                caption: r,\r\n                upload: this._renderButton(\"upload\"),\r\n                remove: this._renderButton(\"remove\"),\r\n                cancel: this._renderButton(\"cancel\"),\r\n                pause: this._renderButton(\"pause\"),\r\n                browse: this._renderButton(\"browse\")\r\n            })\r\n        },\r\n        _renderButton: function(e) {\r\n            var i = this._getLayoutTemplate(\"btnDefault\"),\r\n                a = this[e + \"Class\"],\r\n                r = this[e + \"Title\"],\r\n                s = this[e + \"Icon\"],\r\n                n = this[e + \"Label\"],\r\n                o = this.isDisabled ? \" disabled\" : \"\",\r\n                l = \"button\";\r\n            switch (e) {\r\n                case \"remove\":\r\n                    if (!this.showRemove) return \"\";\r\n                    break;\r\n                case \"cancel\":\r\n                    if (!this.showCancel) return \"\";\r\n                    a += \" kv-hidden\";\r\n                    break;\r\n                case \"pause\":\r\n                    if (!this.showPause) return \"\";\r\n                    a += \" kv-hidden\";\r\n                    break;\r\n                case \"upload\":\r\n                    if (!this.showUpload) return \"\";\r\n                    this.isAjaxUpload && !this.isDisabled ? i = this._getLayoutTemplate(\"btnLink\").replace(\"{href}\", this.uploadUrl) : l = \"submit\";\r\n                    break;\r\n                case \"browse\":\r\n                    if (!this.showBrowse) return \"\";\r\n                    i = this._getLayoutTemplate(\"btnBrowse\");\r\n                    break;\r\n                default:\r\n                    return \"\"\r\n            }\r\n            return i = this._setTabIndex(e, i), a += \"browse\" === e ? \" btn-file\" : \" fileinput-\" + e + \" fileinput-\" + e + \"-button\", t.isEmpty(n) || (n = ' <span class=\"' + this.buttonLabelClass + '\">' + n + \"<\/span>\"), i.setTokens({\r\n                type: l,\r\n                css: a,\r\n                title: r,\r\n                status: o,\r\n                icon: s,\r\n                label: n\r\n            })\r\n        },\r\n        _renderThumbProgress: function() {\r\n            return '<div class=\"file-thumb-progress kv-hidden\">' + this.progressInfoTemplate.setTokens({\r\n                percent: 101,\r\n                status: this.msgUploadBegin,\r\n                stats: \"\"\r\n            }) + \"<\/div>\"\r\n        },\r\n        _renderFileFooter: function(e, i, a, r, s) {\r\n            var n, o, l = this.fileActionSettings,\r\n                d = l.showRemove,\r\n                c = l.showDrag,\r\n                u = l.showUpload,\r\n                p = l.showZoom,\r\n                f = this._getLayoutTemplate(\"footer\"),\r\n                h = this._getLayoutTemplate(\"indicator\"),\r\n                m = s ? l.indicatorError : l.indicatorNew,\r\n                g = s ? l.indicatorErrorTitle : l.indicatorNewTitle,\r\n                v = h.setTokens({\r\n                    indicator: m,\r\n                    indicatorTitle: g\r\n                });\r\n            return o = {\r\n                type: e,\r\n                caption: i,\r\n                size: a = this._getSize(a),\r\n                width: r,\r\n                progress: \"\",\r\n                indicator: v\r\n            }, this.isAjaxUpload ? (o.progress = this._renderThumbProgress(), o.actions = this._renderFileActions(o, u, !1, d, p, c, !1, !1, !1)) : o.actions = this._renderFileActions(o, !1, !1, !1, p, c, !1, !1, !1), n = f.setTokens(o), n = t.replaceTags(n, this.previewThumbTags)\r\n        },\r\n        _renderFileActions: function(e, t, i, a, r, s, n, o, l, d, c, u) {\r\n            if (!e.type && d && (e.type = \"image\"), this.enableResumableUpload ? t = !1 : \"function\" == typeof t && (t = t(e)), \"function\" == typeof i && (i = i(e)), \"function\" == typeof a && (a = a(e)), \"function\" == typeof r && (r = r(e)), \"function\" == typeof s && (s = s(e)), !(t || i || a || r || s)) return \"\";\r\n            var p, f = !1 === o ? \"\" : ' data-url=\"' + o + '\"',\r\n                h = \"\",\r\n                m = \"\",\r\n                g = !1 === l ? \"\" : ' data-key=\"' + l + '\"',\r\n                v = \"\",\r\n                w = \"\",\r\n                b = \"\",\r\n                _ = this._getLayoutTemplate(\"actions\"),\r\n                C = this.fileActionSettings,\r\n                x = this.otherActionButtons.setTokens({\r\n                    dataKey: g,\r\n                    key: l\r\n                }),\r\n                y = n ? C.removeClass + \" disabled\" : C.removeClass;\r\n            return a && (v = this._getLayoutTemplate(\"actionDelete\").setTokens({\r\n                removeClass: y,\r\n                removeIcon: C.removeIcon,\r\n                removeTitle: C.removeTitle,\r\n                dataUrl: f,\r\n                dataKey: g,\r\n                key: l\r\n            })), t && (w = this._getLayoutTemplate(\"actionUpload\").setTokens({\r\n                uploadClass: C.uploadClass,\r\n                uploadIcon: C.uploadIcon,\r\n                uploadTitle: C.uploadTitle\r\n            })), i && (b = (b = this._getLayoutTemplate(\"actionDownload\").setTokens({\r\n                downloadClass: C.downloadClass,\r\n                downloadIcon: C.downloadIcon,\r\n                downloadTitle: C.downloadTitle,\r\n                downloadUrl: c || this.initialPreviewDownloadUrl\r\n            })).setTokens({\r\n                filename: u,\r\n                key: l\r\n            })), r && (h = this._getLayoutTemplate(\"actionZoom\").setTokens({\r\n                zoomClass: C.zoomClass,\r\n                zoomIcon: C.zoomIcon,\r\n                zoomTitle: C.zoomTitle\r\n            })), s && (p = \"drag-handle-init \" + C.dragClass, m = this._getLayoutTemplate(\"actionDrag\").setTokens({\r\n                dragClass: p,\r\n                dragTitle: C.dragTitle,\r\n                dragIcon: C.dragIcon\r\n            })), _.setTokens({\r\n                delete: v,\r\n                upload: w,\r\n                download: b,\r\n                zoom: h,\r\n                drag: m,\r\n                other: x\r\n            })\r\n        },\r\n        _browse: function(e) {\r\n            e && e.isDefaultPrevented() || !this._raise(\"filebrowse\") || (this.isError && !this.isAjaxUpload && this.clear(), this.focusCaptionOnBrowse && this.$captionContainer.focus())\r\n        },\r\n        _change: function(i) {\r\n            var a = this;\r\n            if (e(document.body).off(\"focusin.fileinput focusout.fileinput\"), !a.changeTriggered) {\r\n                a._setLoading(\"show\");\r\n                var r, s, n, o, l = a.$element,\r\n                    d = arguments.length > 1,\r\n                    c = a.isAjaxUpload,\r\n                    u = d ? arguments[1] : l[0].files,\r\n                    p = a.fileManager.count(),\r\n                    f = t.isEmpty(l.attr(\"multiple\")),\r\n                    h = !c && f ? 1 : a.maxFileCount,\r\n                    m = a.maxTotalFileCount,\r\n                    g = m > 0 && m > h,\r\n                    v = f && p > 0,\r\n                    w = function(t, i, r) {\r\n                        var s, n, o, l, d, p, f = r ? a.msgTotalFilesTooMany : a.msgFilesTooMany;\r\n                        f = f.replace(\"{m}\", i).replace(\"{n}\", t), a.isError = (s = f, n = null, o = null, l = null, d = e.extend(!0, {}, a._getOutData(null, {}, {}, u), {\r\n                            id: o,\r\n                            index: l\r\n                        }), p = {\r\n                            id: o,\r\n                            index: l,\r\n                            file: n,\r\n                            files: u\r\n                        }, a.isPersistentError = !0, a._setLoading(\"hide\"), c ? a._showFileError(s, d) : a._showError(s, p)), a.$captionContainer.removeClass(\"icon-visible\"), a._setCaption(\"\", !0), a.$container.removeClass(\"file-input-new file-input-ajax-new\")\r\n                    };\r\n                if (a.reader = null, a._resetUpload(), a._hideFileIcon(), a.dropZoneEnabled, c || (u = i.target && void 0 === i.target.files ? i.target.value ? [{\r\n                        name: i.target.value.replace(\/^.+\\\\\/, \"\")\r\n                    }] : [] : i.target.files || {}), r = u, t.isEmpty(r) || 0 === r.length) return c || a.clear(), void a._raise(\"fileselectnone\");\r\n                if (a._resetErrors(), o = r.length, n = c ? a.fileManager.count() + o : o, s = a._getFileCount(n, !g && void 0), h > 0 && s > h) {\r\n                    if (!a.autoReplace || o > h) return void w(a.autoReplace && o > h ? o : s, h);\r\n                    s > h && a._resetPreviewThumbs(c)\r\n                } else {\r\n                    if (g && (s = a._getFileCount(n, !0), m > 0 && s > m)) {\r\n                        if (!a.autoReplace || o > h) return void w(a.autoReplace && o > m ? o : s, m, !0);\r\n                        s > h && a._resetPreviewThumbs(c)\r\n                    }!c || v ? (a._resetPreviewThumbs(!1), v && a.clearFileStack()) : !c || 0 !== p || a.previewCache.count(!0) && !a.overwriteInitial || a._resetPreviewThumbs(!0)\r\n                }\r\n                a.readFiles(r), a._setLoading(\"hide\")\r\n            }\r\n        },\r\n        _abort: function(t) {\r\n            var i;\r\n            return this.ajaxAborted && \"object\" == typeof this.ajaxAborted && void 0 !== this.ajaxAborted.message ? ((i = e.extend(!0, {}, this._getOutData(null), t)).abortData = this.ajaxAborted.data || {}, i.abortMessage = this.ajaxAborted.message, this._setProgress(101, this.$progress, this.msgCancelled), this._showFileError(this.ajaxAborted.message, i, \"filecustomerror\"), this.cancel(), this.unlock(), !0) : !!this.ajaxAborted\r\n        },\r\n        _resetFileStack: function() {\r\n            var t = this,\r\n                i = 0;\r\n            t._getThumbs().each(function() {\r\n                var a = e(this),\r\n                    r = a.attr(\"data-fileindex\"),\r\n                    s = a.attr(\"id\");\r\n                \"-1\" !== r && -1 !== r && (t._getThumbFile(a) ? a.attr({\r\n                    \"data-fileindex\": \"-1\"\r\n                }) : (a.attr({\r\n                    \"data-fileindex\": i\r\n                }), i++), t._getZoom(s).attr({\r\n                    \"data-fileindex\": a.attr(\"data-fileindex\")\r\n                }))\r\n            })\r\n        },\r\n        _isFileSelectionValid: function(e) {\r\n            return e = e || 0, this.required && !this.getFilesCount() ? (this.$errorContainer.html(\"\"), this._showFileError(this.msgFileRequired), !1) : !(this.minFileCount > 0 && this._getFileCount(e) < this.minFileCount) || (this._noFilesError({}), !1)\r\n        },\r\n        _canPreview: function(e) {\r\n            if (!(e && this.showPreview && this.$preview && this.$preview.length)) return !1;\r\n            var i, a, r, s = e.name || \"\",\r\n                n = e.type || \"\",\r\n                o = (e.size || 0) \/ this.bytesToKB,\r\n                l = this._parseFileType(n, s),\r\n                d = this.allowedPreviewTypes,\r\n                c = this.allowedPreviewMimeTypes,\r\n                u = this.allowedPreviewExtensions || [],\r\n                p = this.disabledPreviewTypes,\r\n                f = this.disabledPreviewMimeTypes,\r\n                h = this.disabledPreviewExtensions || [],\r\n                m = this.maxFilePreviewSize && parseFloat(this.maxFilePreviewSize) || 0,\r\n                g = new RegExp(\"\\\\.(\" + u.join(\"|\") + \")$\", \"i\"),\r\n                v = new RegExp(\"\\\\.(\" + h.join(\"|\") + \")$\", \"i\");\r\n            return i = !d || -1 !== d.indexOf(l), a = !c || -1 !== c.indexOf(n), r = !u.length || t.compare(s, g), !(p && -1 !== p.indexOf(l) || f && -1 !== f.indexOf(n) || h.length && t.compare(s, v) || m && !isNaN(m) && o > m) && (i || a || r)\r\n        },\r\n        addToStack: function(e, t) {\r\n            this.fileManager.add(e, t)\r\n        },\r\n        clearFileStack: function() {\r\n            return this.fileManager.clear(), this._initResumableUpload(), this.enableResumableUpload ? (null === this.showPause && (this.showPause = !0), null === this.showCancel && (this.showCancel = !1)) : (this.showPause = !1, null === this.showCancel && (this.showCancel = !0)), this.$element\r\n        },\r\n        getFileStack: function() {\r\n            return this.fileManager.stack\r\n        },\r\n        getFileList: function() {\r\n            return this.fileManager.list()\r\n        },\r\n        getFilesSize: function() {\r\n            return this.fileManager.getTotalSize()\r\n        },\r\n        getFilesCount: function(e) {\r\n            var t = this.isAjaxUpload ? this.fileManager.count() : this._inputFileCount();\r\n            return e && (t += this.previewCache.count(!0)), this._getFileCount(t)\r\n        },\r\n        _initCapStatus: function(e) {\r\n            var t = this.$caption;\r\n            t.removeClass(\"is-valid file-processing\"), e && (\"processing\" === e ? t.addClass(\"file-processing\") : t.addClass(\"is-valid\"))\r\n        },\r\n        _setLoading: function(e) {\r\n            this.$previewStatus.html(\"hide\" === e ? \"\" : this.msgProcessing), this.$container.removeClass(\"file-thumb-loading\"), this._initCapStatus(\"hide\" === e ? \"\" : \"processing\"), \"hide\" !== e && (this.dropZoneEnabled, this.$container.addClass(\"file-thumb-loading\"))\r\n        },\r\n        _initFileSelected: function() {\r\n            var t = this,\r\n                i = t.$element,\r\n                a = e(document.body),\r\n                r = \"focusin.fileinput focusout.fileinput\";\r\n            a.length ? a.off(r).on(\"focusout.fileinput\", function() {\r\n                t._setLoading(\"show\")\r\n            }).on(\"focusin.fileinput\", function() {\r\n                setTimeout(function() {\r\n                    i.val() || (t._setLoading(\"hide\"), t._setFileDropZoneTitle()), a.off(r)\r\n                }, 2500)\r\n            }) : t._setLoading(\"hide\")\r\n        },\r\n        readFiles: function(i) {\r\n            this.reader = new FileReader;\r\n            var a, r = this,\r\n                s = r.reader,\r\n                n = r.$previewContainer,\r\n                o = r.$previewStatus,\r\n                l = r.msgLoading,\r\n                d = r.msgProgress,\r\n                c = r.previewInitId,\r\n                u = i.length,\r\n                p = r.fileTypeSettings,\r\n                f = r.allowedFileTypes,\r\n                h = f ? f.length : 0,\r\n                m = r.allowedFileExtensions,\r\n                g = t.isEmpty(m) ? \"\" : m.join(\", \"),\r\n                v = function(t, s, n, o, l) {\r\n                    var d, c = e.extend(!0, {}, r._getOutData(null, {}, {}, i), {\r\n                            id: n,\r\n                            index: o,\r\n                            fileId: l\r\n                        }),\r\n                        p = {\r\n                            id: n,\r\n                            index: o,\r\n                            fileId: l,\r\n                            file: s,\r\n                            files: i\r\n                        };\r\n                    r._previewDefault(s, !0), d = r._getFrame(n, !0), r._setLoading(\"hide\"), r.isAjaxUpload ? setTimeout(function() {\r\n                        a(o + 1)\r\n                    }, r.processDelay) : (r.unlock(), u = 0), r.removeFromPreviewOnError && d.length ? d.remove() : (r._initFileActions(), d.find(\".kv-file-upload\").remove()), r.isPersistentError = !0, r.isError = r.isAjaxUpload ? r._showFileError(t, c) : r._showError(t, p), r._updateFileDetails(u)\r\n                };\r\n            r.fileManager.clearImages(), e.each(i, function(e, t) {\r\n                var i = r.fileTypeSettings.image;\r\n                i && i(t.type) && r.fileManager.totalImages++\r\n            }), (a = function(w) {\r\n                var b, _ = r.$errorContainer,\r\n                    C = r.fileManager;\r\n                if (w >= u) return r.unlock(), r.duplicateErrors.length && (b = \"<li>\" + r.duplicateErrors.join(\"<\/li><li>\") + \"<\/li>\", 0 === _.find(\"ul\").length ? t.setHtml(_, r.errorCloseButton + \"<ul>\" + b + \"<\/ul>\") : _.find(\"ul\").append(b), _.fadeIn(r.fadeDelay), r._handler(_.find(\".kv-error-close\"), \"click\", function() {\r\n                    _.fadeOut(r.fadeDelay)\r\n                }), r.duplicateErrors = []), r.isAjaxUpload ? (r._raise(\"filebatchselected\", [C.stack]), 0 !== C.count() || r.isError || r.reset()) : r._raise(\"filebatchselected\", [i]), n.removeClass(\"file-thumb-loading\"), r._initCapStatus(\"valid\"), void o.html(\"\");\r\n                r.lock(!0);\r\n                var x, y, T, P, k, F, S, E, I, A, D, z = i[w],\r\n                    j = r._getFileId(z),\r\n                    U = c + \"-\" + j,\r\n                    $ = p.image,\r\n                    M = r._getFileName(z, \"\"),\r\n                    R = (z && z.size || 0) \/ r.bytesToKB,\r\n                    B = \"\",\r\n                    O = t.createObjectURL(z),\r\n                    L = 0,\r\n                    N = \"\",\r\n                    Z = !1,\r\n                    H = 0,\r\n                    W = function() {\r\n                        var e = !!C.loadedImages[j],\r\n                            t = d.setTokens({\r\n                                index: w + 1,\r\n                                files: u,\r\n                                percent: 50,\r\n                                name: M\r\n                            });\r\n                        setTimeout(function() {\r\n                            o.html(t), r._updateFileDetails(u), a(w + 1)\r\n                        }, r.processDelay), r._raise(\"fileloaded\", [z, U, j, w, s]) && r.isAjaxUpload ? e || C.add(z) : e && C.removeFile(j)\r\n                    };\r\n                if (z) {\r\n                    if (E = C.getId(z), h > 0)\r\n                        for (y = 0; y < h; y++) F = f[y], S = r.msgFileTypes[F] || F, N += 0 === y ? S : \", \" + S;\r\n                    if (!1 !== M) {\r\n                        if (0 === M.length) return T = r.msgInvalidFileName.replace(\"{name}\", t.htmlEncode(t.getFileName(z), \"[unknown]\")), void v(T, z, U, w, E);\r\n                        if (t.isEmpty(m) || (B = new RegExp(\"\\\\.(\" + m.join(\"|\") + \")$\", \"i\")), x = R.toFixed(2), r.isAjaxUpload && C.exists(E) || r._getFrame(U, !0).length) {\r\n                            var V = {\r\n                                id: U,\r\n                                index: w,\r\n                                fileId: E,\r\n                                file: z,\r\n                                files: i\r\n                            };\r\n                            return T = r.msgDuplicateFile.setTokens({\r\n                                name: M,\r\n                                size: x\r\n                            }), void(r.isAjaxUpload ? (r.duplicateErrors.push(T), r.isDuplicateError = !0, r._raise(\"fileduplicateerror\", [z, E, M, x, U, w]), a(w + 1), r._updateFileDetails(u)) : (r._showError(T, V), r.unlock(), u = 0, r._clearFileInput(), r.reset(), r._updateFileDetails(u)))\r\n                        }\r\n                        if (r.maxFileSize > 0 && R > r.maxFileSize) return T = r.msgSizeTooLarge.setTokens({\r\n                            name: M,\r\n                            size: x,\r\n                            maxSize: r.maxFileSize\r\n                        }), void v(T, z, U, w, E);\r\n                        if (null !== r.minFileSize && R <= t.getNum(r.minFileSize)) return T = r.msgSizeTooSmall.setTokens({\r\n                            name: M,\r\n                            size: x,\r\n                            minSize: r.minFileSize\r\n                        }), void v(T, z, U, w, E);\r\n                        if (!t.isEmpty(f) && t.isArray(f)) {\r\n                            for (y = 0; y < f.length; y += 1) P = f[y], L += (A = p[P]) && \"function\" == typeof A && A(z.type, t.getFileName(z)) ? 1 : 0;\r\n                            if (0 === L) return T = r.msgInvalidFileType.setTokens({\r\n                                name: M,\r\n                                types: N\r\n                            }), void v(T, z, U, w, E)\r\n                        }\r\n                        if (0 === L && !t.isEmpty(m) && t.isArray(m) && !t.isEmpty(B) && (k = t.compare(M, B), 0 === (L += t.isEmpty(k) ? 0 : k.length))) return T = r.msgInvalidFileExtension.setTokens({\r\n                            name: M,\r\n                            extensions: g\r\n                        }), void v(T, z, U, w, E);\r\n                        if (!r._canPreview(z)) return I = r.isAjaxUpload && r._raise(\"filebeforeload\", [z, w, s]), r.isAjaxUpload && I && C.add(z), r.showPreview && I && (n.addClass(\"file-thumb-loading\"), r._initCapStatus(\"processing\"), r._previewDefault(z), r._initFileActions()), void setTimeout(function() {\r\n                            I && r._updateFileDetails(u), a(w + 1), r._raise(\"fileloaded\", [z, U, j, w])\r\n                        }, 10);\r\n                        D = $(z.type, M), o.html(l.replace(\"{index}\", w + 1).replace(\"{files}\", u)), n.addClass(\"file-thumb-loading\"), r._initCapStatus(\"processing\"), s.onerror = function(e) {\r\n                            r._errorHandler(e, M)\r\n                        }, s.onload = function(i) {\r\n                            var a, l, d, c, u, f, h, m = [];\r\n                            if (l = {\r\n                                    name: M,\r\n                                    type: z.type\r\n                                }, e.each(p, function(e, t) {\r\n                                    \"object\" !== e && \"other\" !== e && \"function\" == typeof t && t(z.type, M) && H++\r\n                                }), 0 === H) {\r\n                                for (d = new Uint8Array(i.target.result), y = 0; y < d.length; y++) c = d[y].toString(16), m.push(c);\r\n                                if (a = m.join(\"\").toLowerCase().substring(0, 8), f = t.getMimeType(a, \"\", \"\"), t.isEmpty(f) && (u = t.arrayBuffer2String(s.result), f = t.isSvg(u) ? \"image\/svg+xml\" : t.getMimeType(a, u, z.type)), l = {\r\n                                        name: M,\r\n                                        type: f\r\n                                    }, D = $(f, \"\")) return (h = new FileReader).onerror = function(e) {\r\n                                    r._errorHandler(e, M)\r\n                                }, h.onload = function(e) {\r\n                                    if (r.isAjaxUpload && !r._raise(\"filebeforeload\", [z, w, s])) return Z = !0, r._resetCaption(), s.abort(), o.html(\"\"), n.removeClass(\"file-thumb-loading\"), r._initCapStatus(\"valid\"), void r.enable();\r\n                                    r._previewFile(w, z, e, O, l), r._initFileActions(), W()\r\n                                }, void h.readAsDataURL(z)\r\n                            }\r\n                            if (r.isAjaxUpload && !r._raise(\"filebeforeload\", [z, w, s])) return Z = !0, r._resetCaption(), s.abort(), o.html(\"\"), n.removeClass(\"file-thumb-loading\"), r._initCapStatus(\"valid\"), void r.enable();\r\n                            r._previewFile(w, z, i, O, l), r._initFileActions(), W()\r\n                        }, s.onprogress = function(e) {\r\n                            if (e.lengthComputable) {\r\n                                var t = e.loaded \/ e.total * 100,\r\n                                    i = Math.ceil(t);\r\n                                T = d.setTokens({\r\n                                    index: w + 1,\r\n                                    files: u,\r\n                                    percent: i,\r\n                                    name: M\r\n                                }), setTimeout(function() {\r\n                                    Z || o.html(T)\r\n                                }, r.processDelay)\r\n                            }\r\n                        }, D ? s.readAsDataURL(z) : s.readAsArrayBuffer(z)\r\n                    } else a(w + 1)\r\n                }\r\n            })(0), r._updateFileDetails(u)\r\n        },\r\n        lock: function(e) {\r\n            var t = this.$container;\r\n            return this._resetErrors(), this.disable(), !e && this.showCancel && t.find(\".fileinput-cancel\").show(), !e && this.showPause && t.find(\".fileinput-pause\").show(), this._initCapStatus(\"processing\"), this._raise(\"filelock\", [this.fileManager.stack, this._getExtraData()]), this.$element\r\n        },\r\n        unlock: function(e) {\r\n            var t = this.$container;\r\n            return void 0 === e && (e = !0), this.enable(), t.removeClass(\"is-locked\"), this.showCancel && t.find(\".fileinput-cancel\").hide(), this.showPause && t.find(\".fileinput-pause\").hide(), e && this._resetFileStack(), this._initCapStatus(), this._raise(\"fileunlock\", [this.fileManager.stack, this._getExtraData()]), this.$element\r\n        },\r\n        resume: function() {\r\n            var e = this.fileManager,\r\n                t = !1,\r\n                i = this.resumableManager;\r\n            return e.bpsLog = [], e.bps = 0, this.enableResumableUpload ? (this.paused ? this._toggleResumableProgress(this.progressPauseTemplate, this.msgUploadResume) : t = !0, this.paused = !1, t && this._toggleResumableProgress(this.progressInfoTemplate, this.msgUploadBegin), setTimeout(function() {\r\n                i.upload()\r\n            }, this.processDelay), this.$element) : this.$element\r\n        },\r\n        paste: function(e) {\r\n            var t = e.originalEvent,\r\n                i = t.clipboardData && t.clipboardData.files || null;\r\n            return i && this._dropFiles(e, i), this.$element\r\n        },\r\n        pause: function() {\r\n            var t, i = this,\r\n                a = i.resumableManager,\r\n                r = i.ajaxRequests,\r\n                s = r.length,\r\n                n = a.getProgress(),\r\n                o = i.fileActionSettings,\r\n                l = i.taskManager.getPool(a.id);\r\n            if (!i.enableResumableUpload) return i.$element;\r\n            if (l && l.cancel(), i._raise(\"fileuploadpaused\", [i.fileManager, a]), s > 0)\r\n                for (t = 0; t < s; t += 1) i.paused = !0, r[t].abort();\r\n            return i.showPreview && i._getThumbs().each(function() {\r\n                var t, a = e(this),\r\n                    r = i._getLayoutTemplate(\"stats\"),\r\n                    s = a.find(\".file-upload-indicator\");\r\n                a.removeClass(\"file-uploading\"), s.attr(\"title\") === o.indicatorLoadingTitle && (i._setThumbStatus(a, \"Paused\"), t = r.setTokens({\r\n                    pendingTime: i.msgPaused,\r\n                    uploadSpeed: \"\"\r\n                }), i.paused = !0, i._setProgress(n, a.find(\".file-thumb-progress\"), n + \"%\", t)), i._getThumbFile(a) || a.find(\".kv-file-remove\").removeClass(\"disabled\").removeAttr(\"disabled\")\r\n            }), i._setProgress(101, i.$progress, i.msgPaused), i.$element\r\n        },\r\n        cancel: function() {\r\n            var t, i = this,\r\n                a = i.ajaxRequests,\r\n                r = i.resumableManager,\r\n                s = i.taskManager,\r\n                n = r ? s.getPool(r.id) : void 0,\r\n                o = a.length;\r\n            if (i.enableResumableUpload && n ? (n.cancel().done(function() {\r\n                    i._setProgressCancelled()\r\n                }), r.reset(), i._raise(\"fileuploadcancelled\", [i.fileManager, r])) : i._raise(\"fileuploadcancelled\", [i.fileManager]), i._initAjax(), o > 0)\r\n                for (t = 0; t < o; t += 1) i.cancelling = !0, a[t].abort();\r\n            return i._getThumbs().each(function() {\r\n                var t = e(this),\r\n                    a = t.find(\".file-thumb-progress\");\r\n                t.removeClass(\"file-uploading\"), i._setProgress(0, a), a.hide(), i._getThumbFile(t) || (t.find(\".kv-file-upload\").removeClass(\"disabled\").removeAttr(\"disabled\"), t.find(\".kv-file-remove\").removeClass(\"disabled\").removeAttr(\"disabled\")), i.unlock()\r\n            }), setTimeout(function() {\r\n                i._setProgressCancelled()\r\n            }, i.processDelay), i.$element\r\n        },\r\n        clear: function() {\r\n            var i, a = this;\r\n            if (a._raise(\"fileclear\")) return a.$btnUpload.removeAttr(\"disabled\"), a._getThumbs().find(\"video,audio,img\").each(function() {\r\n                t.cleanMemory(e(this))\r\n            }), a._clearFileInput(), a._resetUpload(), a.clearFileStack(), a.isDuplicateError = !1, a.isPersistentError = !1, a._resetErrors(!0), a._hasInitialPreview() ? (a._showFileIcon(), a._resetPreview(), a._initPreviewActions(), a.$container.removeClass(\"file-input-new\")) : (a._getThumbs().each(function() {\r\n                a._clearObjects(e(this))\r\n            }), a.isAjaxUpload && (a.previewCache.data = {}), a.$preview.html(\"\"), i = !a.overwriteInitial && a.initialCaption.length > 0 ? a.initialCaption : \"\", a.$caption.attr(\"title\", \"\").val(i), t.addCss(a.$container, \"file-input-new\"), a._validateDefaultPreview()), 0 === a.$container.find(t.FRAMES).length && (a._initCaption() || a.$captionContainer.removeClass(\"icon-visible\")), a._hideFileIcon(), a.focusCaptionOnClear && a.$captionContainer.focus(), a._setFileDropZoneTitle(), a._raise(\"filecleared\"), a.$element\r\n        },\r\n        reset: function() {\r\n            if (this._raise(\"filereset\")) return this.lastProgress = 0, this._resetPreview(), this.$container.find(\".fileinput-filename\").text(\"\"), t.addCss(this.$container, \"file-input-new\"), this.getFrames().length && this.$container.removeClass(\"file-input-new\"), this.clearFileStack(), this._setFileDropZoneTitle(), this.$element\r\n        },\r\n        disable: function() {\r\n            var e = this.$container;\r\n            return this.isDisabled = !0, this._raise(\"filedisabled\"), this.$element.attr(\"disabled\", \"disabled\"), e.addClass(\"is-locked\"), t.addCss(e.find(\".btn-file\"), \"disabled\"), e.find(\".kv-fileinput-caption\").addClass(\"file-caption-disabled\"), e.find(\".fileinput-remove, .fileinput-upload, .file-preview-frame button\").attr(\"disabled\", !0), this._initDragDrop(), this.$element\r\n        },\r\n        enable: function() {\r\n            var e = this.$container;\r\n            return this.isDisabled = !1, this._raise(\"fileenabled\"), this.$element.removeAttr(\"disabled\"), e.removeClass(\"is-locked\"), e.find(\".kv-fileinput-caption\").removeClass(\"file-caption-disabled\"), e.find(\".fileinput-remove, .fileinput-upload, .file-preview-frame button\").removeAttr(\"disabled\"), e.find(\".btn-file\").removeClass(\"disabled\"), this._initDragDrop(), this.$element\r\n        },\r\n        upload: function() {\r\n            var i, a, r = this,\r\n                s = r.fileManager,\r\n                n = s.count(),\r\n                o = !e.isEmptyObject(r._getExtraData());\r\n            if (s.bpsLog = [], s.bps = 0, r.isAjaxUpload && !r.isDisabled && r._isFileSelectionValid(n)) {\r\n                if (r.lastProgress = 0, r._resetUpload(), 0 !== n || o) {\r\n                    if (r.cancelling = !1, r._showProgress(), r.lock(), 0 === n && o) return r._setProgress(2), void r._uploadExtraOnly();\r\n                    if (r.enableResumableUpload) return r.resume();\r\n                    if (r.uploadAsync || r.enableResumableUpload) {\r\n                        if (a = r._getOutData(null), !r._checkBatchPreupload(a)) return;\r\n                        r.fileBatchCompleted = !1, r.uploadCache = [], e.each(r.getFileStack(), function(e) {\r\n                            var t = r._getThumbId(e);\r\n                            r.uploadCache.push({\r\n                                id: t,\r\n                                content: null,\r\n                                config: null,\r\n                                tags: null,\r\n                                append: !0\r\n                            })\r\n                        }), r.$preview.find(\".file-preview-initial\").removeClass(t.SORT_CSS), r._initSortable()\r\n                    }\r\n                    return r._setProgress(2), r.hasInitData = !1, r.uploadAsync ? (i = 0, void e.each(r.getFileStack(), function(e) {\r\n                        r._uploadSingle(i, e, !0), i++\r\n                    })) : (r._uploadBatch(), r.$element)\r\n                }\r\n                r._showFileError(r.msgUploadEmpty)\r\n            }\r\n        },\r\n        destroy: function() {\r\n            var t = this.$form,\r\n                i = this.$container,\r\n                a = this.$element,\r\n                r = this.namespace;\r\n            return e(document).off(r), e(window).off(r), t && t.length && t.off(r), this.isAjaxUpload && this._clearFileInput(), this._cleanup(), this._initPreviewCache(), a.insertBefore(i).off(r).removeData(), i.off().remove(), a\r\n        },\r\n        refresh: function(i) {\r\n            var a = this.$element;\r\n            return i = \"object\" != typeof i || t.isEmpty(i) ? this.options : e.extend(!0, {}, this.options, i), this._init(i, !0), this._listen(), a\r\n        },\r\n        zoom: function(e) {\r\n            var t = this._getFrame(e);\r\n            this._showModal(t)\r\n        },\r\n        getExif: function(e) {\r\n            var t = this._getFrame(e);\r\n            return t && t.data(\"exif\") || null\r\n        },\r\n        getFrames: function(i) {\r\n            var a;\r\n            return i = i || \"\", a = this.$preview.find(t.FRAMES + i), this.reversePreviewOrder && (a = e(a.get().reverse())), a\r\n        },\r\n        getPreview: function() {\r\n            return {\r\n                content: this.initialPreview,\r\n                config: this.initialPreviewConfig,\r\n                tags: this.initialPreviewThumbTags\r\n            }\r\n        }\r\n    }, e.fn.fileinput = function(a) {\r\n        if (t.hasFileAPISupport() || t.isIE(9)) {\r\n            var r = Array.apply(null, arguments),\r\n                s = [];\r\n            switch (r.shift(), this.each(function() {\r\n                    var n, o = e(this),\r\n                        l = o.data(\"fileinput\"),\r\n                        d = \"object\" == typeof a && a,\r\n                        c = d.theme || o.data(\"theme\"),\r\n                        u = {},\r\n                        p = {},\r\n                        f = d.language || o.data(\"language\") || e.fn.fileinput.defaults.language || \"en\";\r\n                    l || (c && (p = e.fn.fileinputThemes[c] || {}), \"en\" === f || t.isEmpty(e.fn.fileinputLocales[f]) || (u = e.fn.fileinputLocales[f] || {}), n = e.extend(!0, {}, e.fn.fileinput.defaults, p, e.fn.fileinputLocales.en, u, d, o.data()), l = new i(this, n), o.data(\"fileinput\", l)), \"string\" == typeof a && s.push(l[a].apply(l, r))\r\n                }), s.length) {\r\n                case 0:\r\n                    return this;\r\n                case 1:\r\n                    return s[0];\r\n                default:\r\n                    return s\r\n            }\r\n        }\r\n    };\r\n    var a = \"btn btn-sm btn-kv \" + t.defaultButtonCss(),\r\n        r = \"btn \" + t.defaultButtonCss(!0);\r\n    e.fn.fileinput.defaults = {\r\n        language: \"en\",\r\n        bytesToKB: 1024,\r\n        showCaption: !0,\r\n        showBrowse: !0,\r\n        showPreview: !0,\r\n        showRemove: !0,\r\n        showUpload: !0,\r\n        showUploadStats: !0,\r\n        showCancel: null,\r\n        showPause: null,\r\n        showClose: !0,\r\n        showUploadedThumbs: !0,\r\n        showConsoleLogs: !1,\r\n        browseOnZoneClick: !1,\r\n        autoReplace: !1,\r\n        showDescriptionClose: !0,\r\n        autoOrientImage: function() {\r\n            var e = window.navigator.userAgent,\r\n                t = !!e.match(\/WebKit\/i);\r\n            return !(!!e.match(\/iP(od|ad|hone)\/i) && t && !e.match(\/CriOS\/i))\r\n        },\r\n        autoOrientImageInitial: !0,\r\n        required: !1,\r\n        rtl: !1,\r\n        hideThumbnailContent: !1,\r\n        encodeUrl: !0,\r\n        focusCaptionOnBrowse: !0,\r\n        focusCaptionOnClear: !0,\r\n        generateFileId: null,\r\n        previewClass: \"\",\r\n        captionClass: \"\",\r\n        frameClass: \"krajee-default\",\r\n        mainClass: \"\",\r\n        inputGroupClass: \"\",\r\n        mainTemplate: null,\r\n        fileSizeGetter: null,\r\n        initialCaption: \"\",\r\n        initialPreview: [],\r\n        initialPreviewDelimiter: \"*$$*\",\r\n        initialPreviewAsData: !1,\r\n        initialPreviewFileType: \"image\",\r\n        initialPreviewConfig: [],\r\n        initialPreviewThumbTags: [],\r\n        previewThumbTags: {},\r\n        initialPreviewShowDelete: !0,\r\n        initialPreviewDownloadUrl: \"\",\r\n        removeFromPreviewOnError: !1,\r\n        deleteUrl: \"\",\r\n        deleteExtraData: {},\r\n        overwriteInitial: !0,\r\n        sanitizeZoomCache: function(e) {\r\n            var i = t.createElement(e);\r\n            return i.find(\"input,textarea,select,datalist,form,.file-thumbnail-footer\").remove(), i.html()\r\n        },\r\n        previewZoomButtonIcons: {\r\n            prev: '<i class=\"bi-chevron-left\"><\/i>',\r\n            next: '<i class=\"bi-chevron-right\"><\/i>',\r\n            toggleheader: '<i class=\"bi-arrows-expand\"><\/i>',\r\n            fullscreen: '<i class=\"bi-arrows-fullscreen\"><\/i>',\r\n            borderless: '<i class=\"bi-arrows-angle-expand\"><\/i>',\r\n            close: '<i class=\"bi-x-lg\"><\/i>'\r\n        },\r\n        previewZoomButtonClasses: {\r\n            prev: \"btn btn-default btn-outline-secondary btn-navigate\",\r\n            next: \"btn btn-default btn-outline-secondary btn-navigate\",\r\n            toggleheader: a,\r\n            fullscreen: a,\r\n            borderless: a,\r\n            close: a\r\n        },\r\n        previewTemplates: {},\r\n        previewContentTemplates: {},\r\n        preferIconicPreview: !1,\r\n        preferIconicZoomPreview: !1,\r\n        allowedFileTypes: null,\r\n        allowedFileExtensions: null,\r\n        allowedPreviewTypes: void 0,\r\n        allowedPreviewMimeTypes: null,\r\n        allowedPreviewExtensions: null,\r\n        disabledPreviewTypes: void 0,\r\n        disabledPreviewExtensions: [\"msi\", \"exe\", \"com\", \"zip\", \"rar\", \"app\", \"vb\", \"scr\", \"pdf\"],\r\n        disabledPreviewMimeTypes: null,\r\n        defaultPreviewContent: null,\r\n        customLayoutTags: {},\r\n        customPreviewTags: {},\r\n        previewFileIcon: '<i class=\"bi-file-earmark-fill\"><\/i>',\r\n        previewFileIconClass: \"file-other-icon\",\r\n        previewFileIconSettings: {},\r\n        previewFileExtSettings: {},\r\n        buttonLabelClass: \"hidden-xs\",\r\n        browseIcon: '<i class=\"bi-folder2-open\"><\/i> ',\r\n        browseClass: \"btn btn-primary\",\r\n        removeIcon: '<i class=\"bi-trash\"><\/i>',\r\n        removeClass: r,\r\n        cancelIcon: '<i class=\"bi-slash-circle\"><\/i>',\r\n        cancelClass: r,\r\n        pauseIcon: '<i class=\"bi-pause-fill\"><\/i>',\r\n        pauseClass: r,\r\n        uploadIcon: '<i class=\"bi-upload\"><\/i>',\r\n        uploadClass: r,\r\n        uploadUrl: null,\r\n        uploadUrlThumb: null,\r\n        uploadAsync: !0,\r\n        uploadParamNames: {\r\n            chunkCount: \"chunkCount\",\r\n            chunkIndex: \"chunkIndex\",\r\n            chunkSize: \"chunkSize\",\r\n            chunkSizeStart: \"chunkSizeStart\",\r\n            chunksUploaded: \"chunksUploaded\",\r\n            fileBlob: \"fileBlob\",\r\n            fileId: \"fileId\",\r\n            fileName: \"fileName\",\r\n            fileRelativePath: \"fileRelativePath\",\r\n            fileSize: \"fileSize\",\r\n            retryCount: \"retryCount\"\r\n        },\r\n        maxAjaxThreads: 5,\r\n        fadeDelay: 800,\r\n        processDelay: 100,\r\n        bitrateUpdateDelay: 500,\r\n        queueDelay: 10,\r\n        progressDelay: 0,\r\n        enableResumableUpload: !1,\r\n        resumableUploadOptions: {\r\n            fallback: null,\r\n            testUrl: null,\r\n            chunkSize: 2048,\r\n            maxThreads: 4,\r\n            maxRetries: 3,\r\n            showErrorLog: !0,\r\n            retainErrorHistory: !0,\r\n            skipErrorsAndProceed: !1\r\n        },\r\n        uploadExtraData: {},\r\n        zoomModalHeight: 480,\r\n        minImageWidth: null,\r\n        minImageHeight: null,\r\n        maxImageWidth: null,\r\n        maxImageHeight: null,\r\n        resizeImage: !1,\r\n        resizePreference: \"width\",\r\n        resizeQuality: .92,\r\n        resizeDefaultImageType: \"image\/jpeg\",\r\n        resizeIfSizeMoreThan: 0,\r\n        minFileSize: -1,\r\n        maxFileSize: 0,\r\n        maxFilePreviewSize: 25600,\r\n        minFileCount: 0,\r\n        maxFileCount: 0,\r\n        maxTotalFileCount: 0,\r\n        validateInitialCount: !1,\r\n        msgValidationErrorClass: \"text-danger\",\r\n        msgValidationErrorIcon: '<i class=\"bi-exclamation-circle-fill\"><\/i> ',\r\n        msgErrorClass: \"file-error-message\",\r\n        progressThumbClass: \"progress-bar progress-bar-striped active progress-bar-animated\",\r\n        progressClass: \"progress-bar bg-success progress-bar-success progress-bar-striped active progress-bar-animated\",\r\n        progressInfoClass: \"progress-bar bg-info progress-bar-info progress-bar-striped active progress-bar-animated\",\r\n        progressCompleteClass: \"progress-bar bg-success progress-bar-success\",\r\n        progressPauseClass: \"progress-bar bg-primary progress-bar-primary progress-bar-striped active progress-bar-animated\",\r\n        progressErrorClass: \"progress-bar bg-danger progress-bar-danger\",\r\n        progressUploadThreshold: 99,\r\n        previewFileType: \"image\",\r\n        elCaptionContainer: null,\r\n        elCaptionText: null,\r\n        elPreviewContainer: null,\r\n        elPreviewImage: null,\r\n        elPreviewStatus: null,\r\n        elErrorContainer: null,\r\n        errorCloseButton: void 0,\r\n        slugCallback: null,\r\n        dropZoneEnabled: !0,\r\n        dropZoneTitleClass: \"file-drop-zone-title\",\r\n        fileActionSettings: {},\r\n        otherActionButtons: \"\",\r\n        textEncoding: \"UTF-8\",\r\n        preProcessUpload: null,\r\n        ajaxSettings: {},\r\n        ajaxDeleteSettings: {},\r\n        showAjaxErrorDetails: !0,\r\n        mergeAjaxCallbacks: !1,\r\n        mergeAjaxDeleteCallbacks: !1,\r\n        retryErrorUploads: !0,\r\n        reversePreviewOrder: !1,\r\n        usePdfRenderer: function() {\r\n            var e = !!window.MSInputMethodContext && !!document.documentMode;\r\n            return !!navigator.userAgent.match(\/(iPod|iPhone|iPad|Android)\/i) || e\r\n        },\r\n        pdfRendererUrl: \"\",\r\n        pdfRendererTemplate: '<iframe class=\"kv-preview-data file-preview-pdf\" src=\"{renderer}?file={data}\" {style}><\/iframe>',\r\n        tabIndexConfig: {\r\n            browse: 500,\r\n            remove: 500,\r\n            upload: 500,\r\n            cancel: null,\r\n            pause: null,\r\n            modal: -1\r\n        }\r\n    }, e.fn.fileinputLocales.en = {\r\n        sizeUnits: [\"B\", \"KB\", \"MB\", \"GB\", \"TB\", \"PB\", \"EB\", \"ZB\", \"YB\"],\r\n        bitRateUnits: [\"B\/s\", \"KB\/s\", \"MB\/s\", \"GB\/s\", \"TB\/s\", \"PB\/s\", \"EB\/s\", \"ZB\/s\", \"YB\/s\"],\r\n        fileSingle: \"file\",\r\n        filePlural: \"files\",\r\n        browseLabel: \"Browse &hellip;\",\r\n        removeLabel: \"Remove\",\r\n        removeTitle: \"Clear all unprocessed files\",\r\n        cancelLabel: \"Cancel\",\r\n        cancelTitle: \"Abort ongoing upload\",\r\n        pauseLabel: \"Pause\",\r\n        pauseTitle: \"Pause ongoing upload\",\r\n        uploadLabel: \"Upload\",\r\n        uploadTitle: \"Upload selected files\",\r\n        msgNo: \"No\",\r\n        msgNoFilesSelected: \"No files selected\",\r\n        msgCancelled: \"Cancelled\",\r\n        msgPaused: \"Paused\",\r\n        msgPlaceholder: \"Select {files} ...\",\r\n        msgZoomModalHeading: \"Detailed Preview\",\r\n        msgFileRequired: \"You must select a file to upload.\",\r\n        msgSizeTooSmall: 'File \"{name}\" (<b>{size} KB<\/b>) is too small and must be larger than <b>{minSize} KB<\/b>.',\r\n        msgSizeTooLarge: 'File \"{name}\" (<b>{size} KB<\/b>) exceeds maximum allowed upload size of <b>{maxSize} KB<\/b>.',\r\n        msgFilesTooLess: \"You must select at least <b>{n}<\/b> {files} to upload.\",\r\n        msgFilesTooMany: \"Number of files selected for upload <b>({n})<\/b> exceeds maximum allowed limit of <b>{m}<\/b>.\",\r\n        msgTotalFilesTooMany: \"You can upload a maximum of <b>{m}<\/b> files (<b>{n}<\/b> files detected).\",\r\n        msgFileNotFound: 'File \"{name}\" not found!',\r\n        msgFileSecured: 'Security restrictions prevent reading the file \"{name}\".',\r\n        msgFileNotReadable: 'File \"{name}\" is not readable.',\r\n        msgFilePreviewAborted: 'File preview aborted for \"{name}\".',\r\n        msgFilePreviewError: 'An error occurred while reading the file \"{name}\".',\r\n        msgInvalidFileName: 'Invalid or unsupported characters in file name \"{name}\".',\r\n        msgInvalidFileType: 'Invalid type for file \"{name}\". Only \"{types}\" files are supported.',\r\n        msgInvalidFileExtension: 'Invalid extension for file \"{name}\". Only \"{extensions}\" files are supported.',\r\n        msgFileTypes: {\r\n            image: \"image\",\r\n            html: \"HTML\",\r\n            text: \"text\",\r\n            video: \"video\",\r\n            audio: \"audio\",\r\n            flash: \"flash\",\r\n            pdf: \"PDF\",\r\n            object: \"object\"\r\n        },\r\n        msgUploadAborted: \"The file upload was aborted\",\r\n        msgUploadThreshold: \"Processing &hellip;\",\r\n        msgUploadBegin: \"Initializing &hellip;\",\r\n        msgUploadEnd: \"Done\",\r\n        msgUploadResume: \"Resuming upload &hellip;\",\r\n        msgUploadEmpty: \"No valid data available for upload.\",\r\n        msgUploadError: \"Upload Error\",\r\n        msgDeleteError: \"Delete Error\",\r\n        msgProgressError: \"Error\",\r\n        msgValidationError: \"Validation Error\",\r\n        msgLoading: \"Loading file {index} of {files} &hellip;\",\r\n        msgProgress: \"Loading file {index} of {files} - {name} - {percent}% completed.\",\r\n        msgSelected: \"{n} {files} selected\",\r\n        msgProcessing: \"Processing ...\",\r\n        msgFoldersNotAllowed: \"Drag & drop files only! {n} folder(s) dropped were skipped.\",\r\n        msgImageWidthSmall: 'Width of image file \"{name}\" must be at least {size} px.',\r\n        msgImageHeightSmall: 'Height of image file \"{name}\" must be at least {size} px.',\r\n        msgImageWidthLarge: 'Width of image file \"{name}\" cannot exceed {size} px.',\r\n        msgImageHeightLarge: 'Height of image file \"{name}\" cannot exceed {size} px.',\r\n        msgImageResizeError: \"Could not get the image dimensions to resize.\",\r\n        msgImageResizeException: \"Error while resizing the image.<pre>{errors}<\/pre>\",\r\n        msgAjaxError: \"Something went wrong with the {operation} operation. Please try again later!\",\r\n        msgAjaxProgressError: \"{operation} failed\",\r\n        msgDuplicateFile: 'File \"{name}\" of same size \"{size} KB\" has already been selected earlier. Skipping duplicate selection.',\r\n        msgResumableUploadRetriesExceeded: \"Upload aborted beyond <b>{max}<\/b> retries for file <b>{file}<\/b>! Error Details: <pre>{error}<\/pre>\",\r\n        msgPendingTime: \"{time} remaining\",\r\n        msgCalculatingTime: \"calculating time remaining\",\r\n        ajaxOperations: {\r\n            deleteThumb: \"file delete\",\r\n            uploadThumb: \"file upload\",\r\n            uploadBatch: \"batch file upload\",\r\n            uploadExtra: \"form data upload\"\r\n        },\r\n        dropZoneTitle: \"Drag & drop files here &hellip;\",\r\n        dropZoneClickTitle: \"<br>(or click to select {files})\",\r\n        previewZoomButtonTitles: {\r\n            prev: \"View previous file\",\r\n            next: \"View next file\",\r\n            toggleheader: \"Toggle header\",\r\n            fullscreen: \"Toggle full screen\",\r\n            borderless: \"Toggle borderless mode\",\r\n            close: \"Close detailed preview\"\r\n        }\r\n    }, e.fn.fileinput.Constructor = i, e(document).ready(function() {\r\n        var t = e(\"input.file[type=file]\");\r\n        t.length && t.fileinput()\r\n    })\r\n});\r\n\r\n\r\n\/\/ ----------multiplefile-upload---------\r\n$(\"#multiplefileupload\").fileinput({\r\n    theme: \"explorer-fas\",\r\n    uploadUrl: \"#\",\r\n    deleteUrl: \"#\",\r\n    initialPreviewAsData: true,\r\n    overwriteInitial: false,\r\n    dropZoneTitle: '<div class=\"upload-area\"><i class=\"far fa-images\"><\/i><p>Click to Browse or Drag and Drop .pdf<\/p> <div> <button>Browse File<\/button> <\/div><\/div>',\r\n    dropZoneClickTitle: \"\",\r\n    browseOnZoneClick: true,\r\n    showRemove: false,\r\n    showUpload: false,\r\n    showZoom: false,\r\n    showCaption: false,\r\n    showBrowse: false,\r\n    browseClass: \"btn btn-danger\",\r\n    browseLabel: \"\",\r\n    browseIcon: \"<i class='fa fa-plus'><\/i>\",\r\n    fileActionSettings: {\r\n        showUpload: false,\r\n        showDownload: false,\r\n        showZoom: false,\r\n        showDrag: true,\r\n        removeIcon: \"<i class='fa fa-times'><\/i>\",\r\n        uploadIcon: \"<i class='fa fa-upload'><\/i>\",\r\n        dragIcon: \"<i class='fa fa-arrows-alt'><\/i>\",\r\n        uploadRetryIcon: \"<i class='fa fa-undo-alt'><\/i>\",\r\n        dragClass: \"file-drag\",\r\n        removeClass: \"file-remove\",\r\n        removeErrorClass: 'file-remove',\r\n        uploadClass: \"file-upload\",\r\n    },\r\n    frameClass: \"file-sortable\",\r\n    layoutTemplates: {\r\n        preview:\r\n            '<div class=\"file-preview {class}\">\\n' +\r\n            '    <div class=\"{dropClass}\">\\n' +\r\n            '    <div class=\"clearfix\"><\/div>' +\r\n            '    <div class=\"file-preview-status text-center text-success\"><\/div>\\n' +\r\n            '    <div class=\"kv-fileinput-error\"><\/div>\\n' +\r\n            \"    <\/div>\\n\" +\r\n            \"<\/div>\" +\r\n            ' <div class=\"file-preview-thumbnails\">\\n' +\r\n            \" <\/div>\\n\",\r\n        actionDrag: '<button class=\"file-drag-handle {dragClass}\" title=\"{dragTitle}\">{dragIcon}<\/button>',\r\n        footer: '<div class=\"file-thumbnail-footer\">\\n' + '<div class=\"file-detail\">' + '<div class=\"file-caption-name\">{caption}<\/div>\\n' + '    <div class=\"file-size\">{size}<\/div>\\n' + \"<\/div>\" + \"   {actions}\\n\" + \"<\/div>\",\r\n    },\r\n});<\/script>\r\n<style>@import url('https:\/\/fonts.googleapis.com\/css2?family=Nunito:wght@200;300;400;600;700;800;900&display=swap');\r\n\r\nbutton:focus,\r\ninput:focus{\r\n  outline: none;\r\n  box-shadow: none;\r\n}\r\na,\r\na:hover{\r\n  text-decoration: none;\r\n}\r\n\r\nbody{\r\n  font-family: 'Nunito', sans-serif;\r\n}\r\n\r\n\/*----------multiple-file-upload-----------*\/\r\n.file-upload-contain{\r\n    position: relative;\r\n    margin-bottom: 40px;\r\n}\r\n.file-upload-contain .file-input,\r\n.file-upload-contain .file-preview{\r\n    position: initial;\r\n}\r\n.file-upload-contain .file-drop-zone{\r\n    border: 2px dashed #1e80e8;\r\n    transition: 0.3s;\r\n    margin: 0;\r\n    padding: 0;\r\n    border-radius: 20px;\r\n    background-color: #f1f8fe;\r\n    min-height: auto;\r\n}\r\n.file-upload-contain .file-drop-zone.clickable:hover,\r\n.file-upload-contain .file-drop-zone.clickable:focus,\r\n.file-upload-contain .file-highlighted{\r\n    border: 2px dashed #1e80e8 !important;\r\n    background-color: #dfedfc;\r\n}\r\n.upload-area i {\r\n    color: #1e80e8;\r\n    font-size: 50px;\r\n}\r\n.upload-area p {\r\n    margin-bottom: 30px;\r\n    margin-top: 30px;\r\n    font-size: 20px;\r\n    font-weight: 600;\r\n    color: #2580e8;\r\n}\r\n.upload-area p b {\r\n    color: #1e80e8;\r\n}\r\n.upload-area button {\r\n    padding: 8px 16px;\r\n    min-width: 150px;\r\n    font-size: 16px;\r\n    font-weight: 600;\r\n    color: #fff;\r\n    background-color: #1e80e8;\r\n    border: 2px solid #1e80e8;\r\n    border-radius: 50px;\r\n    transition: 0.3s;\r\n}\r\n.upload-area button:hover{\r\n    background-color: #1e80e8;\r\n    box-shadow: 0px 4px 8px rgb(37 128 232 \/ 48%);\r\n}\r\n.file-preview{\r\n    padding: 0;\r\n    border: none;\r\n    margin-bottom: 30px;\r\n}\r\n.file-preview .fileinput-remove{\r\n    display: none;\r\n}\r\n.file-drop-zone-title{\r\n    padding: 55px 10px;\r\n}\r\n.file-drop-zone .file-preview-thumbnails{\r\n    cursor: pointer;\r\n}\r\n.file-preview-frame{\r\n    cursor: default;\r\n    display: flex;\r\n    align-items: center;\r\n    border: none;\r\n    background-color: #2580e8;\r\n    box-shadow: none;\r\n    border-radius: 8px;\r\n    width: 100%;\r\n    padding: 15px;\r\n    margin: 8px 0px;\r\n}\r\n.file-preview-frame:not(.file-preview-error):hover{\r\n    border: none;\r\n    box-shadow: 0 0 10px 0 rgb(0 0 0 \/ 20%);\r\n}\r\n.file-preview-frame .kv-file-content{\r\n    min-width: 45px;\r\n    min-height: 45px;\r\n    width: 45px;\r\n    height: 45px;\r\n    border-radius: 4px;\r\n    margin-right: 10px;\r\n    background-color: #fff;\r\n    padding: 3px;\r\n    display: flex;\r\n    align-items: center;\r\n    justify-content: center;\r\n}\r\n.file-preview-image {\r\n    border-radius: 4px;\r\n}\r\n.file-preview-frame .file-footer-caption{\r\n    padding-top: 0;\r\n}\r\n.file-preview-frame .file-footer-caption{\r\n    text-align: left;\r\n    margin-bottom: 0;\r\n}\r\n.file-detail{\r\n    font-size: 14px;\r\n    height: auto;\r\n    width: 100%;\r\n    line-height: initial;\r\n}\r\n.file-detail .file-caption-name{\r\n    color: #fff;\r\n    font-size: 15px;\r\n    font-weight: 600;\r\n    margin-bottom: 6px;\r\n}\r\n.file-detail .file-size{\r\n    color: #f1f8fe;\r\n    font-size: 12px;\r\n}\r\n.kv-zoom-cache {\r\n    display: none;\r\n}\r\n.file-preview-frame .file-thumbnail-footer{\r\n    height: auto;\r\n    display: flex;\r\n    align-items: center;\r\n    justify-content: space-between;\r\n    width: 100%;\r\n}\r\n.file-preview-frame .file-drag-handle, \r\n.file-preview-frame .file-upload-indicator{\r\n    float: none;\r\n}\r\n.file-preview-frame .file-footer-buttons{\r\n    float: none;\r\n    display: flex;\r\n    align-items: center;\r\n}\r\n.file-preview-status.text-center {\r\n    display: none;\r\n}\r\n.kv-file-remove.file-remove {\r\n    border: none;\r\n    background-color: #ef2f2f;\r\n    color: #fff;\r\n    width: 25px;\r\n    height: 25px;\r\n    font-size: 12px;\r\n    border-radius: 4px;\r\n    margin: 0px 4px;\r\n}\r\n.file-drag-handle.file-drag {\r\n    border: none;\r\n    background-color: #fff;\r\n    color: #2580e8;\r\n    width: 25px;\r\n    height: 25px;\r\n    font-size: 12px;\r\n    border-radius: 4px;\r\n    margin: 0px 4px;\r\n}\r\n.kv-file-upload.file-upload{\r\n    border: none;\r\n    background-color: #48bd22;\r\n    color: #fff;\r\n    width: 25px;\r\n    height: 25px;\r\n    font-size: 12px;\r\n    border-radius: 4px;\r\n    margin: 0px 4px;\r\n}\r\n.file-thumb-loading{\r\n    background: none !important; \r\n}\r\n.file-preview-frame.sortable-chosen {\r\n    background-color: #64a5ef;\r\n    border-color: #64a5ef;\r\n    box-shadow: none!important;\r\n}<\/style>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<\/div>\n\t\t","protected":false},"excerpt":{"rendered":"<p>[jobs][contact-form-7 id=&#8221;22744&#8243; title=&#8221;Job Application&#8221;]<\/p>\n","protected":false},"author":3,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-22154","page","type-page","status-publish","hentry"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Current Openings - Tradewind Finance<\/title>\n<meta name=\"robots\" content=\"noindex, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<meta property=\"og:locale\" content=\"ar_AR\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Current Openings - Tradewind Finance\" \/>\n<meta property=\"og:description\" content=\"[jobs][contact-form-7 id=&#8221;22744&#8243; title=&#8221;Job Application&#8221;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/dev.tradewindfinance.com\/current-openings\/\" \/>\n<meta property=\"og:site_name\" content=\"Tradewind Finance\" \/>\n<meta property=\"article:modified_time\" content=\"2023-06-13T20:22:25+00:00\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"48 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/dev.tradewindfinance.com\\\/current-openings\\\/\",\"url\":\"https:\\\/\\\/dev.tradewindfinance.com\\\/current-openings\\\/\",\"name\":\"Current Openings - Tradewind Finance\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/dev.tradewindfinance.com\\\/#website\"},\"datePublished\":\"2023-05-22T19:13:49+00:00\",\"dateModified\":\"2023-06-13T20:22:25+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/dev.tradewindfinance.com\\\/current-openings\\\/#breadcrumb\"},\"inLanguage\":\"ar\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/dev.tradewindfinance.com\\\/current-openings\\\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/dev.tradewindfinance.com\\\/current-openings\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/dev.tradewindfinance.com\\\/ar\\\/home\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Current Openings\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/dev.tradewindfinance.com\\\/#website\",\"url\":\"https:\\\/\\\/dev.tradewindfinance.com\\\/\",\"name\":\"Tradewind Finance\",\"description\":\"Intelligent Trade Finance\",\"publisher\":{\"@id\":\"https:\\\/\\\/dev.tradewindfinance.com\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/dev.tradewindfinance.com\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"ar\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/dev.tradewindfinance.com\\\/#organization\",\"name\":\"Tradewind Finance\",\"url\":\"https:\\\/\\\/dev.tradewindfinance.com\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ar\",\"@id\":\"https:\\\/\\\/dev.tradewindfinance.com\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/dev.tradewindfinance.com\\\/wp-content\\\/uploads\\\/2022\\\/02\\\/Tradewind-Logo.svg\",\"contentUrl\":\"https:\\\/\\\/dev.tradewindfinance.com\\\/wp-content\\\/uploads\\\/2022\\\/02\\\/Tradewind-Logo.svg\",\"width\":200,\"height\":49,\"caption\":\"Tradewind Finance\"},\"image\":{\"@id\":\"https:\\\/\\\/dev.tradewindfinance.com\\\/#\\\/schema\\\/logo\\\/image\\\/\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Current Openings - Tradewind Finance","robots":{"index":"noindex","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"og_locale":"ar_AR","og_type":"article","og_title":"Current Openings - Tradewind Finance","og_description":"[jobs][contact-form-7 id=&#8221;22744&#8243; title=&#8221;Job Application&#8221;]","og_url":"https:\/\/dev.tradewindfinance.com\/current-openings\/","og_site_name":"Tradewind Finance","article_modified_time":"2023-06-13T20:22:25+00:00","twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"48 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/dev.tradewindfinance.com\/current-openings\/","url":"https:\/\/dev.tradewindfinance.com\/current-openings\/","name":"Current Openings - Tradewind Finance","isPartOf":{"@id":"https:\/\/dev.tradewindfinance.com\/#website"},"datePublished":"2023-05-22T19:13:49+00:00","dateModified":"2023-06-13T20:22:25+00:00","breadcrumb":{"@id":"https:\/\/dev.tradewindfinance.com\/current-openings\/#breadcrumb"},"inLanguage":"ar","potentialAction":[{"@type":"ReadAction","target":["https:\/\/dev.tradewindfinance.com\/current-openings\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/dev.tradewindfinance.com\/current-openings\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/dev.tradewindfinance.com\/ar\/home\/"},{"@type":"ListItem","position":2,"name":"Current Openings"}]},{"@type":"WebSite","@id":"https:\/\/dev.tradewindfinance.com\/#website","url":"https:\/\/dev.tradewindfinance.com\/","name":"Tradewind Finance","description":"Intelligent Trade Finance","publisher":{"@id":"https:\/\/dev.tradewindfinance.com\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/dev.tradewindfinance.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"ar"},{"@type":"Organization","@id":"https:\/\/dev.tradewindfinance.com\/#organization","name":"Tradewind Finance","url":"https:\/\/dev.tradewindfinance.com\/","logo":{"@type":"ImageObject","inLanguage":"ar","@id":"https:\/\/dev.tradewindfinance.com\/#\/schema\/logo\/image\/","url":"https:\/\/dev.tradewindfinance.com\/wp-content\/uploads\/2022\/02\/Tradewind-Logo.svg","contentUrl":"https:\/\/dev.tradewindfinance.com\/wp-content\/uploads\/2022\/02\/Tradewind-Logo.svg","width":200,"height":49,"caption":"Tradewind Finance"},"image":{"@id":"https:\/\/dev.tradewindfinance.com\/#\/schema\/logo\/image\/"}}]}},"_links":{"self":[{"href":"https:\/\/dev.tradewindfinance.com\/ar\/wp-json\/wp\/v2\/pages\/22154","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/dev.tradewindfinance.com\/ar\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/dev.tradewindfinance.com\/ar\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/dev.tradewindfinance.com\/ar\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/dev.tradewindfinance.com\/ar\/wp-json\/wp\/v2\/comments?post=22154"}],"version-history":[{"count":0,"href":"https:\/\/dev.tradewindfinance.com\/ar\/wp-json\/wp\/v2\/pages\/22154\/revisions"}],"wp:attachment":[{"href":"https:\/\/dev.tradewindfinance.com\/ar\/wp-json\/wp\/v2\/media?parent=22154"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}