2 lines
71 KiB
JavaScript
2 lines
71 KiB
JavaScript
|
|
var FileUploadWithPreview=function(){"use strict";var A,e=(function(A){var e=function(A){var e,t=Object.prototype,g=t.hasOwnProperty,n="function"==typeof Symbol?Symbol:{},i=n.iterator||"@@iterator",B=n.asyncIterator||"@@asyncIterator",E=n.toStringTag||"@@toStringTag";function r(A,e,t,g){var n=e&&e.prototype instanceof c?e:c,i=Object.create(n.prototype),B=new k(g||[]);return i._invoke=function(A,e,t){var g=o;return function(n,i){if(g===Q)throw new Error("Generator is already running");if(g===a){if("throw"===n)throw i;return R()}for(t.method=n,t.arg=i;;){var B=t.delegate;if(B){var E=S(B,t);if(E){if(E===s)continue;return E}}if("next"===t.method)t.sent=t._sent=t.arg;else if("throw"===t.method){if(g===o)throw g=a,t.arg;t.dispatchException(t.arg)}else"return"===t.method&&t.abrupt("return",t.arg);g=Q;var r=C(A,e,t);if("normal"===r.type){if(g=t.done?a:I,r.arg===s)continue;return{value:r.arg,done:t.done}}"throw"===r.type&&(g=a,t.method="throw",t.arg=r.arg)}}}(A,t,B),i}function C(A,e,t){try{return{type:"normal",arg:A.call(e,t)}}catch(A){return{type:"throw",arg:A}}}A.wrap=r;var o="suspendedStart",I="suspendedYield",Q="executing",a="completed",s={};function c(){}function u(){}function l(){}var h={};h[i]=function(){return this};var m=Object.getPrototypeOf,f=m&&m(m(J([])));f&&f!==t&&g.call(f,i)&&(h=f);var d=l.prototype=c.prototype=Object.create(h);function p(A){["next","throw","return"].forEach(function(e){A[e]=function(A){return this._invoke(e,A)}})}function v(A){var e;this._invoke=function(t,n){function i(){return new Promise(function(e,i){!function e(t,n,i,B){var E=C(A[t],A,n);if("throw"!==E.type){var r=E.arg,o=r.value;return o&&"object"==typeof o&&g.call(o,"__await")?Promise.resolve(o.__await).then(function(A){e("next",A,i,B)},function(A){e("throw",A,i,B)}):Promise.resolve(o).then(function(A){r.value=A,i(r)},function(A){return e("throw",A,i,B)})}B(E.arg)}(t,n,e,i)})}return e=e?e.then(i,i):i()}}function S(A,t){var g=A.iterator[t.method];if(g===e){if(t.delegate=null,"throw"===t.method){if(A.iterator.return&&(t.method="return",t.arg=e,S(A,t),"throw"===t.method))return s;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return s}var n=C(g,A.iterator,t.arg);if("throw"===n.type)return t.method="throw",t.arg=n.arg,t.delegate=null,s;var i=n.arg;return i?i.done?(t[A.resultName]=i.value,t.next=A.nextLoc,"return"!==t.method&&(t.method="next",t.arg=e),t.delegate=null,s):i:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,s)}function y(A){var e={tryLoc:A[0]};1 in A&&(e.catchLoc=A[1]),2 in A&&(e.finallyLoc=A[2],e.afterLoc=A[3]),this.tryEntries.push(e)}function w(A){var e=A.completion||{};e.type="normal",delete e.arg,A.completion=e}function k(A){this.tryEntries=[{tryLoc:"root"}],A.forEach(y,this),this.reset(!0)}function J(A){if(A){var t=A[i];if(t)return t.call(A);if("function"==typeof A.next)return A;if(!isNaN(A.length)){var n=-1,B=function t(){for(;++n<A.length;)if(g.call(A,n))return t.value=A[n],t.done=!1,t;return t.value=e,t.done=!0,t};return B.next=B}}return{next:R}}function R(){return{value:e,done:!0}}return u.prototype=d.constructor=l,l.constructor=u,l[E]=u.displayName="GeneratorFunction",A.isGeneratorFunction=function(A){var e="function"==typeof A&&A.constructor;return!!e&&(e===u||"GeneratorFunction"===(e.displayName||e.name))},A.mark=function(A){return Object.setPrototypeOf?Object.setPrototypeOf(A,l):(A.__proto__=l,E in A||(A[E]="GeneratorFunction")),A.prototype=Object.create(d),A},A.awrap=function(A){return{__await:A}},p(v.prototype),v.prototype[B]=function(){return this},A.AsyncIterator=v,A.async=function(e,t,g,n){var i=new v(r(e,t,g,n));return A.isGeneratorFunction(t)?i:i.next().then(function(A){return A.done?A.value:i.next()})},p(d),d[E]="Generator",d[i]=function(){return this},d.toString=function(){return"[object Generator]"},A.keys=function(A){var e=[];for(var t in A)e.push(t);return e.reverse(),function t(){for(;e.length;){var g=e.pop();if(g in A)return t.value=g,t.done=!1,t}return t.done=!0,t}},A.values=J,k.prototype={constructor:k,reset:function(A){if(
|