WordPress/wp-includes/js/plupload/moxie.min.js

1 line
86 KiB
JavaScript
Raw Normal View History

var MXI_DEBUG=!1;!function(a,v){"use strict";var s={};function e(e,t,i){if("string"!=typeof e)throw"invalid module definition, module id must be defined and be a string";if(t===v)throw"invalid module definition, dependencies must be specified";if(i===v)throw"invalid module definition, definition function must be specified";!function(e,t){for(var i,n=[],r=0;r<e.length;++r){if(!(i=s[e[r]]||o(e[r])))throw"module definition dependecy not found: "+e[r];n.push(i)}t.apply(null,n)}(t,function(){s[e]=i.apply(null,arguments)})}function o(e){for(var t=a,i=e.split(/[.\/]/),n=0;n<i.length;++n){if(!t[i[n]])return;t=t[i[n]]}return t}e("moxie/core/utils/Basic",[],function(){function o(e){return void 0===e?"undefined":null===e?"null":e.nodeType?"node":{}.toString.call(e).match(/\s([a-z|A-Z]+)/)[1].toLowerCase()}var n,r=function(i){return s(arguments,function(e,t){0<t&&s(e,function(e,t){void 0!==e&&(o(i[t])===o(e)&&~a(o(e),["array","object"])?r(i[t],e):i[t]=e)})}),i},s=function(e,t){var i,n,r;if(e)if("number"===o(e.length)){for(r=0,i=e.length;r<i;r++)if(!1===t(e[r],r))return}else if("object"===o(e))for(n in e)if(e.hasOwnProperty(n)&&!1===t(e[n],n))return},a=function(e,t){if(t){if(Array.prototype.indexOf)return Array.prototype.indexOf.call(t,e);for(var i=0,n=t.length;i<n;i++)if(t[i]===e)return i}return-1};return{guid:(n=0,function(e){var t,i=(new Date).getTime().toString(32);for(t=0;t<5;t++)i+=Math.floor(65535*Math.random()).toString(32);return(e||"o_")+i+(n++).toString(32)}),typeOf:o,extend:r,each:s,isEmptyObj:function(e){var t;if(!e||"object"!==o(e))return!0;for(t in e)return!1;return!0},inSeries:function(e,n){var r=e.length;"function"!==o(n)&&(n=function(){}),e&&e.length||n(),function t(i){"function"===o(e[i])&&e[i](function(e){++i<r&&!e?t(i):n(e)})}(0)},inParallel:function(e,n){var r=0,o=e.length,a=new Array(o);s(e,function(e,i){e(function(e){if(e)return n(e);var t=[].slice.call(arguments);t.shift(),a[i]=t,++r===o&&(a.unshift(null),n.apply(this,a))})})},inArray:a,arrayDiff:function(e,t){var i=[];for(var n in"array"!==o(e)&&(e=[e]),"array"!==o(t)&&(t=[t]),e)-1===a(e[n],t)&&i.push(e[n]);return!!i.length&&i},arrayIntersect:function(e,t){var i=[];return s(e,function(e){-1!==a(e,t)&&i.push(e)}),i.length?i:null},toArray:function(e){var t,i=[];for(t=0;t<e.length;t++)i[t]=e[t];return i},trim:function(e){return e?String.prototype.trim?String.prototype.trim.call(e):e.toString().replace(/^\s*/,"").replace(/\s*$/,""):e},sprintf:function(e){var t=[].slice.call(arguments,1);return e.replace(/%[a-z]/g,function(){var e=t.shift();return"undefined"!==o(e)?e:""})},parseSizeStr:function(e){if("string"!=typeof e)return e;var t,i={t:1099511627776,g:1073741824,m:1048576,k:1024};return t=(e=/^([0-9\.]+)([tmgk]?)$/.exec(e.toLowerCase().replace(/[^0-9\.tmkg]/g,"")))[2],e=+e[1],i.hasOwnProperty(t)&&(e*=i[t]),Math.floor(e)}}}),e("moxie/core/utils/Env",["moxie/core/utils/Basic"],function(n){var d,h,m,e,t,r,i,o,a,s=(h="function",m="object",r=function(e,t){return-1!==t.toLowerCase().indexOf(e.toLowerCase())},a={browser:[[/(opera\smini)\/([\w\.-]+)/i,/(opera\s[mobiletab]+).+version\/([\w\.-]+)/i,/(opera).+version\/([\w\.]+)/i,/(opera)[\/\s]+([\w\.]+)/i],[e="name",t="version"],[/\s(opr)\/([\w\.]+)/i],[[e,"Opera"],t],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer)[\/\s]?([\w\.]+)*/i,/(avant\s|iemobile|slim|baidu)(?:browser)?[\/\s]?([\w\.]*)/i,/(?:ms|\()(ie)\s([\w\.]+)/i,/(rekonq)\/([\w\.]+)*/i,/(chromium|flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi)\/([\w\.-]+)/i],[e,t],[/(trident).+rv[:\s]([\w\.]+).+like\sgecko/i],[[e,"IE"],t],[/(edge)\/((\d+)?[\w\.]+)/i],[e,t],[/(yabrowser)\/([\w\.]+)/i],[[e,"Yandex"],t],[/(comodo_dragon)\/([\w\.]+)/i],[[e,/_/g," "],t],[/(chrome|omniweb|arora|[tizenoka]{5}\s?browser)\/v?([\w\.]+)/i,/(uc\s?browser|qqbrowser)[\/\s]?([\w\.]+)/i],[e,t],[/(dolfin)\/([\w\.]+)/i],[[e,"Dolphin"],t],[/((?:android.+)crmo|crios)\/([\w\.]+)/i],[[e,"Chrome"],t],[/XiaoMi\/MiuiBrowser\/([\w\.]+)/i],[t,[e,"MIUI Browser"]],[/android.+version\/([\w\.]+)\s+(?:mobile\s?safari|safari)/i],[t,[e,"Android Browser"]],[/FBAV\/