"use strict";(self.webpackChunkflow_web_extension=self.webpackChunkflow_web_extension||[]).push([["85028"],{315719:function(e,i,t){t.r(i),t.d(i,{compressor:()=>d,getImageSizeLimit:()=>l});var r,n=t(771197),s=t(698127),a=t(154604),o=t(917612),u=t(31809),l=function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return(0,a.bH)()||e?0x1e00000:0xa00000},c=e=>"".concat(Number(e/1048576).toFixed(3)," MB"),p={maxSizeMB:10,maxWidthOrHeight:2560,useWebWorker:!0},d=(r=(0,n._)(function*(e,i,r){var n,l,d=(0,u.zQ)({eventName:"uploader_compress_image"});if(!(null==e?void 0:null===(n=e.type)||void 0===n?void 0:n.includes("image/gif"))&&((null==e?void 0:null===(l=e.type)||void 0===l?void 0:l.includes("image/svg"))||e.size.valueOf()<(null!=r?r:0xa00000)||(0,a.bH)()))return d.success({meta:{skip:1,type:e.type}}),e;try{var{default:m}=yield(0,o.C5)(()=>t.e("48554").then(t.bind(t,848079))),f=yield m(e,(0,s._)({},p,i));return d.success({meta:{skip:0,type:e.type,before_size:c(e.size),after_size:c(f.size)}}),f}catch(i){return d.error({reason:"uploader_compress_image_failed",error:i,meta:{type:e.type}}),e}}),function(e,i,t){return r.apply(this,arguments)})}}]);
//# sourceMappingURL=uploader-compressor.js.map