11 lines
158 KiB
JavaScript
11 lines
158 KiB
JavaScript
|
|
import{g as Is,a as Es,p as Ot,U as lt,b as As,i as ks}from"./core-84ea94a2.js";import{y as o,T as it,_ as re,x as ve,p as be,h as st,F as Oi,j as te,d as Ds,a as Ni,b as ct}from"../@fullcalendar/core-bd0f45d9.js";import{g as ut}from"../vendor-8efd6c0a.js";import{n as zt,r as Bs}from"./aws-s3-98528360.js";var Gt=Number.isNaN||function(e){return typeof e=="number"&&e!==e};function Os(i,e){return!!(i===e||Gt(i)&&Gt(e))}function Ns(i,e){if(i.length!==e.length)return!1;for(var t=0;t<i.length;t++)if(!Os(i[t],e[t]))return!1;return!0}function Qt(i,e){e===void 0&&(e=Ns);var t=null;function s(){for(var n=[],a=0;a<arguments.length;a++)n[a]=arguments[a];if(t&&t.lastThis===this&&e(n,t.lastArgs))return t.lastResult;var r=i.apply(this,n);return t={lastResult:r,lastArgs:n,lastThis:this},r}return s.clear=function(){t=null},s}var _i={exports:{}};(function(i){var e=Object.prototype.hasOwnProperty,t="~";function s(){}Object.create&&(s.prototype=Object.create(null),new s().__proto__||(t=!1));function n(u,d,h){this.fn=u,this.context=d,this.once=h||!1}function a(u,d,h,c,p){if(typeof h!="function")throw new TypeError("The listener must be a function");var f=new n(h,c||u,p),m=t?t+d:d;return u._events[m]?u._events[m].fn?u._events[m]=[u._events[m],f]:u._events[m].push(f):(u._events[m]=f,u._eventsCount++),u}function r(u,d){--u._eventsCount===0?u._events=new s:delete u._events[d]}function l(){this._events=new s,this._eventsCount=0}l.prototype.eventNames=function(){var d=[],h,c;if(this._eventsCount===0)return d;for(c in h=this._events)e.call(h,c)&&d.push(t?c.slice(1):c);return Object.getOwnPropertySymbols?d.concat(Object.getOwnPropertySymbols(h)):d},l.prototype.listeners=function(d){var h=t?t+d:d,c=this._events[h];if(!c)return[];if(c.fn)return[c.fn];for(var p=0,f=c.length,m=new Array(f);p<f;p++)m[p]=c[p].fn;return m},l.prototype.listenerCount=function(d){var h=t?t+d:d,c=this._events[h];return c?c.fn?1:c.length:0},l.prototype.emit=function(d,h,c,p,f,m){var b=t?t+d:d;if(!this._events[b])return!1;var g=this._events[b],v=arguments.length,P,w;if(g.fn){switch(g.once&&this.removeListener(d,g.fn,void 0,!0),v){case 1:return g.fn.call(g.context),!0;case 2:return g.fn.call(g.context,h),!0;case 3:return g.fn.call(g.context,h,c),!0;case 4:return g.fn.call(g.context,h,c,p),!0;case 5:return g.fn.call(g.context,h,c,p,f),!0;case 6:return g.fn.call(g.context,h,c,p,f,m),!0}for(w=1,P=new Array(v-1);w<v;w++)P[w-1]=arguments[w];g.fn.apply(g.context,P)}else{var S=g.length,T;for(w=0;w<S;w++)switch(g[w].once&&this.removeListener(d,g[w].fn,void 0,!0),v){case 1:g[w].fn.call(g[w].context);break;case 2:g[w].fn.call(g[w].context,h);break;case 3:g[w].fn.call(g[w].context,h,c);break;case 4:g[w].fn.call(g[w].context,h,c,p);break;default:if(!P)for(T=1,P=new Array(v-1);T<v;T++)P[T-1]=arguments[T];g[w].fn.apply(g[w].context,P)}}return!0},l.prototype.on=function(d,h,c){return a(this,d,h,c,!1)},l.prototype.once=function(d,h,c){return a(this,d,h,c,!0)},l.prototype.removeListener=function(d,h,c,p){var f=t?t+d:d;if(!this._events[f])return this;if(!h)return r(this,f),this;var m=this._events[f];if(m.fn)m.fn===h&&(!p||m.once)&&(!c||m.context===c)&&r(this,f);else{for(var b=0,g=[],v=m.length;b<v;b++)(m[b].fn!==h||p&&!m[b].once||c&&m[b].context!==c)&&g.push(m[b]);g.length?this._events[f]=g.length===1?g[0]:g:r(this,f)}return this},l.prototype.removeAllListeners=function(d){var h;return d?(h=t?t+d:d,this._events[h]&&r(this,h)):(this._events=new s,this._eventsCount=0),this},l.prototype.off=l.prototype.removeListener,l.prototype.addListener=l.prototype.on,l.prefixed=t,l.EventEmitter=l,i.exports=l})(_i);var _s=_i.exports;const xs=ut(_s);class xi extends Error{constructor(e){super(e),this.name="TimeoutError"}}let Rs=class extends Error{constructor(e){super(),this.name="AbortError",this.message=e}};const Kt=i=>globalThis.DOMException===void 0?new Rs(i):new DOMException(i),Xt=i=>{const e=i.reason===void 0?Kt("This operation was aborted."):i.reason;return e instanceof Error?e:Kt(e)};function Us(i,e,t,s){let n;const a=new Promise((r,l)=>{if(typeof e!="number"||Math.sign(e)!==1)throw new TypeError(`Expect
|
||
|
|
Copyright (c) 2018 Jed Watson.
|
||
|
|
Licensed under the MIT License (MIT), see
|
||
|
|
http://jedwatson.github.io/classnames
|
||
|
|
*/(function(i){(function(){var e={}.hasOwnProperty;function t(){for(var a="",r=0;r<arguments.length;r++){var l=arguments[r];l&&(a=n(a,s(l)))}return a}function s(a){if(typeof a=="string"||typeof a=="number")return a;if(typeof a!="object")return"";if(Array.isArray(a))return t.apply(null,a);if(a.toString!==Object.prototype.toString&&!a.toString.toString().includes("[native code]"))return a.toString();var r="";for(var l in a)e.call(a,l)&&a[l]&&(r=n(r,l));return r}function n(a,r){return r?a?a+" "+r:a+r:a}i.exports?(t.default=t,i.exports=t):window.classNames=t})()})(Mi);var Ks=Mi.exports;const x=ut(Ks);function zi(i){return{...i,type:i.mimeType,extension:i.name?Is(i.name).extension:null}}function Nt(){return Nt=Object.assign?Object.assign.bind():function(i){for(var e=1;e<arguments.length;e++){var t=arguments[e];for(var s in t)Object.prototype.hasOwnProperty.call(t,s)&&(i[s]=t[s])}return i},Nt.apply(this,arguments)}const Xs={position:"relative",width:"100%",minHeight:"100%"},Ys={position:"absolute",top:0,left:0,width:"100%",overflow:"visible"};class $i extends ve{constructor(e){super(e),this.handleScroll=()=>{this.setState({offset:this.base.scrollTop})},this.handleResize=()=>{this.resize()},this.focusElement=null,this.state={offset:0,height:0}}componentDidMount(){this.resize(),window.addEventListener("resize",this.handleResize)}componentWillUpdate(){this.base.contains(document.activeElement)&&(this.focusElement=document.activeElement)}componentDidUpdate(){this.focusElement&&this.focusElement.parentNode&&document.activeElement!==this.focusElement&&this.focusElement.focus(),this.focusElement=null,this.resize()}componentWillUnmount(){window.removeEventListener("resize",this.handleResize)}resize(){const{height:e}=this.state;e!==this.base.offsetHeight&&this.setState({height:this.base.offsetHeight})}render(e){let{data:t,rowHeight:s,renderRow:n,overscanCount:a=10,...r}=e;const{offset:l,height:u}=this.state;let d=Math.floor(l/s),h=Math.floor(u/s);a&&(d=Math.max(0,d-d%a),h+=a);const c=d+h+4,p=t.slice(d,c),f={...Xs,height:t.length*s},m={...Ys,top:d*s};return o("div",Nt({onScroll:this.handleScroll},r),o("div",{role:"presentation",style:f},o("div",{role:"presentation",style:m},p.map(n))))}}function Hi(i){const{search:e,searchOnInput:t,searchTerm:s,showButton:n,inputLabel:a,clearSearchLabel:r,buttonLabel:l,clearSearch:u,inputClassName:d,buttonCSSClassName:h}=i,[c,p]=be(s??""),f=it(v=>{v.preventDefault(),e(c)},[e,c]),m=it(v=>{const P=v.target.value;p(P),t&&e(P)},[p,t,e]),b=()=>{p(""),u&&u()},[g]=be(()=>{const v=document.createElement("form");return v.setAttribute("tabindex","-1"),v.id=zt(),v});return st(()=>(document.body.appendChild(g),g.addEventListener("submit",f),()=>{g.removeEventListener("submit",f),document.body.removeChild(g)}),[g,f]),o(re,null,o("input",{className:`uppy-u-reset ${d}`,type:"search","aria-label":a,placeholder:a,value:c,onInput:m,form:g.id,"data-uppy-super-focusable":!0}),!n&&o("svg",{"aria-hidden":"true",focusable:"false",className:"uppy-c-icon uppy-ProviderBrowser-searchFilterIcon",width:"12",height:"12",viewBox:"0 0 12 12"},o("path",{d:"M8.638 7.99l3.172 3.172a.492.492 0 1 1-.697.697L7.91 8.656a4.977 4.977 0 0 1-2.983.983C2.206 9.639 0 7.481 0 4.819 0 2.158 2.206 0 4.927 0c2.721 0 4.927 2.158 4.927 4.82a4.74 4.74 0 0 1-1.216 3.17zm-3.71.685c2.176 0 3.94-1.726 3.94-3.856 0-2.129-1.764-3.855-3.94-3.855C2.75.964.984 2.69.984 4.819c0 2.13 1.765 3.856 3.942 3.856z"})),!n&&c&&o("button",{className:"uppy-u-reset uppy-ProviderBrowser-searchFilterReset",type:"button","aria-label":r,title:r,onClick:b},o("svg",{"aria-hidden":"true",focusable:"false",className:"uppy-c-icon",viewBox:"0 0 19 19"},o("path",{d:"M17.318 17.232L9.94 9.854 9.586 9.5l-.354.354-7.378 7.378h.707l-.62-.62v.706L9.318 9.94l.354-.354-.354-.354L1.94 1.854v.707l.62-.62h-.706l7.378 7.378.354.354.354-.354 7.378-7.378h-.707l.622.62v-.706L9.854 9.232l-.354.354.354.354 7.378 7.378.708-.707-7.38-7.378v.708l7.38-7.38.353-.353-.353-.353-.622-.622-.353-.353-.354.352-7.378 7.38h.708L2.56 1.23 2.208.88l-.353.353-.622.62-.353.355.352.353 7.38 7.38v-.708l-7.38 7.38-.353.3
|
||
|
|
|
||
|
|
${e}`;alert(r)}return o("div",{className:"uppy-StatusBar-content",title:t("uploadFailed")},o("svg",{"aria-hidden":"true",focusable:"false",className:"uppy-StatusBar-statusIndicator uppy-c-icon",width:"11",height:"11",viewBox:"0 0 11 11"},o("path",{d:"M4.278 5.5L0 1.222 1.222 0 5.5 4.278 9.778 0 11 1.222 6.722 5.5 11 9.778 9.778 11 5.5 6.722 1.222 11 0 9.778z"})),o("div",{className:"uppy-StatusBar-status"},o("div",{className:"uppy-StatusBar-statusPrimary"},t("uploadFailed"),o("button",{className:"uppy-u-reset uppy-StatusBar-details","aria-label":t("showErrorDetails"),"data-microtip-position":"top-right","data-microtip-size":"medium",onClick:a,type:"button"},"?")),o(Gi,{i18n:t,complete:s,numUploads:n})))}const{STATE_ERROR:li,STATE_WAITING:ui,STATE_PREPROCESSING:gt,STATE_UPLOADING:Ve,STATE_POSTPROCESSING:yt,STATE_COMPLETE:qe}=X;function Qi(i){const{newFiles:e,allowNewUpload:t,isUploadInProgress:s,isAllPaused:n,resumableUploads:a,error:r,hideUploadButton:l,hidePauseResumeButton:u,hideCancelButton:d,hideRetryButton:h,recoveredState:c,uploadState:p,totalProgress:f,files:m,supportsUploadProgress:b,hideAfterFinish:g,isSomeGhost:v,doneButtonHandler:P,isUploadStarted:w,i18n:S,startUpload:T,uppy:R,isAllComplete:I,showProgressDetails:D,numUploads:N,complete:me,totalSize:Pe,totalETA:ae,totalUploadedSize:oe}=i;function Q(){switch(p){case yt:case gt:{const He=mt(m);return He.mode==="determinate"?He.value*100:f}case li:return null;case Ve:return b?f:null;default:return f}}function le(){switch(p){case yt:case gt:{const{mode:He}=mt(m);return He==="indeterminate"}case Ve:return!b;default:return!1}}function dt(){if(c)return!1;switch(p){case ui:return l||e===0;case qe:return g;default:return!1}}const Fe=Q(),bs=dt(),ht=Fe??100,vs=!r&&e&&!s&&!n&&t&&!l,ws=!d&&p!==ui&&p!==qe,Ps=a&&!u&&p===Ve,Fs=r&&!I&&!h,Ss=P&&p===qe,Cs=x("uppy-StatusBar-progress",{"is-indeterminate":le()}),Ts=x("uppy-StatusBar",`is-${p}`,{"has-ghosts":v});return o("div",{className:Ts,"aria-hidden":bs},o("div",{className:Cs,style:{width:`${ht}%`},role:"progressbar","aria-label":`${ht}%`,"aria-valuetext":`${ht}%`,"aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":Fe}),(()=>{switch(p){case gt:case yt:return o(kn,{progress:mt(m)});case qe:return o(Nn,{i18n:S});case li:return o(_n,{error:r,i18n:S,numUploads:N,complete:me});case Ve:return o(On,{i18n:S,supportsUploadProgress:b,totalProgress:f,showProgressDetails:D,isUploadStarted:w,isAllComplete:I,isAllPaused:n,newFiles:e,numUploads:N,complete:me,totalUploadedSize:oe,totalSize:Pe,totalETA:ae,startUpload:T});default:return null}})(),o("div",{className:"uppy-StatusBar-actions"},c||vs?o(Cn,{newFiles:e,isUploadStarted:w,recoveredState:c,i18n:S,isSomeGhost:v,startUpload:T,uploadState:p}):null,Fs?o(Tn,{i18n:S,uppy:R}):null,Ps?o(En,{isAllPaused:n,i18n:S,isAllComplete:I,resumableUploads:a,uppy:R}):null,ws?o(In,{i18n:S,uppy:R}):null,Ss?o(An,{i18n:S,doneButtonHandler:P}):null))}Qi.defaultProps={doneButtonHandler:void 0,hideAfterFinish:!1,hideCancelButton:!1,hidePauseResumeButton:!1,hideRetryButton:!1,hideUploadButton:void 0,showProgressDetails:void 0};const xn={strings:{uploading:"Uploading",complete:"Complete",uploadFailed:"Upload failed",paused:"Paused",retry:"Retry",cancel:"Cancel",pause:"Pause",resume:"Resume",done:"Done",filesUploadedOfTotal:{0:"%{complete} of %{smart_count} file uploaded",1:"%{complete} of %{smart_count} files uploaded"},dataUploadedOfTotal:"%{complete} of %{total}",xTimeLeft:"%{time} left",uploadXFiles:{0:"Upload %{smart_count} file",1:"Upload %{smart_count} files"},uploadXNewFiles:{0:"Upload +%{smart_count} file",1:"Upload +%{smart_count} files"},upload:"Upload",retryUpload:"Retry upload",xMoreFilesAdded:{0:"%{smart_count} more file added",1:"%{smart_count} more files added"},showErrorDetails:"Show error details"}};function A(i,e){if(!Object.prototype.hasOwnProperty.call(i,e))throw new TypeError("attempted to use private field on non-instance");return i}var Rn=0;function we(i){return"__private_"+Rn+++"_"+i}const Un={version:"3.3.3"},Ln=2e3,Mn=2e3;function zn(i,e,t,s){if(i)return X.STATE_ERROR;if(e)return X.STATE_CO
|
||
|
|
|
||
|
|
${n.details}`)},"?")))))),this.type="progressindicator",this.id=this.opts.id||"Informer",this.title="Informer"}install(){const{target:e}=this.opts;e&&this.mount(e,this)}}Yi.VERSION=Kn.version;const Xn=/^data:([^/]+\/[^,;]+(?:[^,]*?))(;base64)?,([\s\S]*)$/;function Yn(i,e,t){var s,n;const a=Xn.exec(i),r=(s=(n=e.mimeType)!=null?n:a==null?void 0:a[1])!=null?s:"plain/text";let l;if((a==null?void 0:a[2])!=null){const u=atob(decodeURIComponent(a[3])),d=new Uint8Array(u.length);for(let h=0;h<u.length;h++)d[h]=u.charCodeAt(h);l=[d]}else(a==null?void 0:a[3])!=null&&(l=[decodeURIComponent(a[3])]);return t?new File(l,e.name||"",{type:r}):new Blob(l,{type:r})}function hi(i){return i.startsWith("blob:")}function ci(i){return i?/^[^/]+\/(jpe?g|gif|png|svg|svg\+xml|bmp|webp|avif)$/.test(i):!1}function F(i,e,t){return e in i?Object.defineProperty(i,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):i[e]=t,i}var Ji=typeof self<"u"?self:global;const ze=typeof navigator<"u",Jn=ze&&typeof HTMLImageElement>"u",pi=!(typeof global>"u"||typeof process>"u"||!process.versions||!process.versions.node),Zi=Ji.Buffer,es=!!Zi,Zn=i=>i!==void 0;function ts(i){return i===void 0||(i instanceof Map?i.size===0:Object.values(i).filter(Zn).length===0)}function O(i){let e=new Error(i);throw delete e.stack,e}function fi(i){let e=function(t){let s=0;return t.ifd0.enabled&&(s+=1024),t.exif.enabled&&(s+=2048),t.makerNote&&(s+=2048),t.userComment&&(s+=1024),t.gps.enabled&&(s+=512),t.interop.enabled&&(s+=100),t.ifd1.enabled&&(s+=1024),s+2048}(i);return i.jfif.enabled&&(e+=50),i.xmp.enabled&&(e+=2e4),i.iptc.enabled&&(e+=14e3),i.icc.enabled&&(e+=6e3),e}const vt=i=>String.fromCharCode.apply(null,i),mi=typeof TextDecoder<"u"?new TextDecoder("utf-8"):void 0;class j{static from(e,t){return e instanceof this&&e.le===t?e:new j(e,void 0,void 0,t)}constructor(e,t=0,s,n){if(typeof n=="boolean"&&(this.le=n),Array.isArray(e)&&(e=new Uint8Array(e)),e===0)this.byteOffset=0,this.byteLength=0;else if(e instanceof ArrayBuffer){s===void 0&&(s=e.byteLength-t);let a=new DataView(e,t,s);this._swapDataView(a)}else if(e instanceof Uint8Array||e instanceof DataView||e instanceof j){s===void 0&&(s=e.byteLength-t),(t+=e.byteOffset)+s>e.byteOffset+e.byteLength&&O("Creating view outside of available memory in ArrayBuffer");let a=new DataView(e.buffer,t,s);this._swapDataView(a)}else if(typeof e=="number"){let a=new DataView(new ArrayBuffer(e));this._swapDataView(a)}else O("Invalid input argument for BufferView: "+e)}_swapArrayBuffer(e){this._swapDataView(new DataView(e))}_swapBuffer(e){this._swapDataView(new DataView(e.buffer,e.byteOffset,e.byteLength))}_swapDataView(e){this.dataView=e,this.buffer=e.buffer,this.byteOffset=e.byteOffset,this.byteLength=e.byteLength}_lengthToEnd(e){return this.byteLength-e}set(e,t,s=j){return e instanceof DataView||e instanceof j?e=new Uint8Array(e.buffer,e.byteOffset,e.byteLength):e instanceof ArrayBuffer&&(e=new Uint8Array(e)),e instanceof Uint8Array||O("BufferView.set(): Invalid data argument."),this.toUint8().set(e,t),new s(this,t,e.byteLength)}subarray(e,t){return t=t||this._lengthToEnd(e),new j(this,e,t)}toUint8(){return new Uint8Array(this.buffer,this.byteOffset,this.byteLength)}getUint8Array(e,t){return new Uint8Array(this.buffer,this.byteOffset+e,t)}getString(e=0,t=this.byteLength){return n=this.getUint8Array(e,t),mi?mi.decode(n):es?Buffer.from(n).toString("utf8"):decodeURIComponent(escape(vt(n)));var n}getLatin1String(e=0,t=this.byteLength){let s=this.getUint8Array(e,t);return vt(s)}getUnicodeString(e=0,t=this.byteLength){const s=[];for(let n=0;n<t&&e+n<this.byteLength;n+=2)s.push(this.getUint16(e+n));return vt(s)}getInt8(e){return this.dataView.getInt8(e)}getUint8(e){return this.dataView.getUint8(e)}getInt16(e,t=this.le){return this.dataView.getInt16(e,t)}getInt32(e,t=this.le){return this.dataView.getInt32(e,t)}getUint16(e,t=this.le){return this.dataView.getUint16(e,t)}getUint32(e,t=this.le){return this.dataView.getUint32(e,t)}getFloat32(e,t=this.le){return this.dataView.getFloat32(e,t)}getFloat64(e,t=this.le){return this.dataView.getFloat64(e,t)}g
|
||
|
|
this.ifd0Offset: ${this.ifd0Offset}, file.byteLength: ${e.byteLength}`),e.tiff&&await e.ensureChunk(this.ifd0Offset,fi(this.options));let t=this.parseBlock(this.ifd0Offset,"ifd0");return t.size!==0?(this.exifOffset=t.get(34665),this.interopOffset=t.get(40965),this.gpsOffset=t.get(34853),this.xmp=t.get(700),this.iptc=t.get(33723),this.icc=t.get(34675),this.options.sanitize&&(t.delete(34665),t.delete(40965),t.delete(34853),t.delete(700),t.delete(33723),t.delete(34675)),t):void 0}async parseExifBlock(){if(this.exif||(this.ifd0||await this.parseIfd0Block(),this.exifOffset===void 0))return;this.file.tiff&&await this.file.ensureChunk(this.exifOffset,fi(this.options));let e=this.parseBlock(this.exifOffset,"exif");return this.interopOffset||(this.interopOffset=e.get(40965)),this.makerNote=e.get(37500),this.userComment=e.get(37510),this.options.sanitize&&(e.delete(40965),e.delete(37500),e.delete(37510)),this.unpack(e,41728),this.unpack(e,41729),e}unpack(e,t){let s=e.get(t);s&&s.length===1&&e.set(t,s[0])}async parseGpsBlock(){if(this.gps||(this.ifd0||await this.parseIfd0Block(),this.gpsOffset===void 0))return;let e=this.parseBlock(this.gpsOffset,"gps");return e&&e.has(2)&&e.has(4)&&(e.set("latitude",Pi(...e.get(2),e.get(1))),e.set("longitude",Pi(...e.get(4),e.get(3)))),e}async parseInteropBlock(){if(!this.interop&&(this.ifd0||await this.parseIfd0Block(),this.interopOffset!==void 0||this.exif||await this.parseExifBlock(),this.interopOffset!==void 0))return this.parseBlock(this.interopOffset,"interop")}async parseThumbnailBlock(e=!1){if(!this.ifd1&&!this.ifd1Parsed&&(!this.options.mergeOutput||e))return this.findIfd1Offset(),this.ifd1Offset>0&&(this.parseBlock(this.ifd1Offset,"ifd1"),this.ifd1Parsed=!0),this.ifd1}async extractThumbnail(){if(this.headerParsed||this.parseHeader(),this.ifd1Parsed||await this.parseThumbnailBlock(!0),this.ifd1===void 0)return;let e=this.ifd1.get(513),t=this.ifd1.get(514);return this.chunk.getUint8Array(e,t)}get image(){return this.ifd0}get thumbnail(){return this.ifd1}createOutput(){let e,t,s,n={};for(t of B)if(e=this[t],!ts(e))if(s=this.canTranslate?this.translateBlock(e,t):Object.fromEntries(e),this.options.mergeOutput){if(t==="ifd1")continue;Object.assign(n,s)}else n[t]=s;return this.makerNote&&(n.makerNote=this.makerNote),this.userComment&&(n.userComment=this.userComment),n}assignToOutput(e,t){if(this.globalOptions.mergeOutput)Object.assign(e,t);else for(let[s,n]of Object.entries(t))this.assignObjectToOutput(e,s,n)}}function Pi(i,e,t,s){var n=i+e/60+t/3600;return s!=="S"&&s!=="W"||(n*=-1),n}F(Pt,"type","tiff"),F(Pt,"headerLength",10),W.set("tiff",Pt);const Wt={ifd0:!1,ifd1:!1,exif:!1,gps:!1,interop:!1,sanitize:!1,reviveValues:!0,translateKeys:!1,translateValues:!1,mergeOutput:!1};Object.assign({},Wt,{firstChunkSize:4e4,gps:[1,2,3,4]});Object.assign({},Wt,{tiff:!1,ifd1:!0,mergeOutput:!1});const ur=Object.assign({},Wt,{firstChunkSize:4e4,ifd0:[274]});async function dr(i){let e=new sr(ur);await e.read(i);let t=await e.parse();if(t&&t.ifd0)return t.ifd0[274]}const hr=Object.freeze({1:{dimensionSwapped:!1,scaleX:1,scaleY:1,deg:0,rad:0},2:{dimensionSwapped:!1,scaleX:-1,scaleY:1,deg:0,rad:0},3:{dimensionSwapped:!1,scaleX:1,scaleY:1,deg:180,rad:180*Math.PI/180},4:{dimensionSwapped:!1,scaleX:-1,scaleY:1,deg:180,rad:180*Math.PI/180},5:{dimensionSwapped:!0,scaleX:1,scaleY:-1,deg:90,rad:90*Math.PI/180},6:{dimensionSwapped:!0,scaleX:1,scaleY:1,deg:90,rad:90*Math.PI/180},7:{dimensionSwapped:!0,scaleX:1,scaleY:-1,deg:270,rad:270*Math.PI/180},8:{dimensionSwapped:!0,scaleX:1,scaleY:1,deg:270,rad:270*Math.PI/180}});let De=!0,Be=!0;if(typeof navigator=="object"){let i=navigator.userAgent;if(i.includes("iPad")||i.includes("iPhone")){let e=i.match(/OS (\d+)_(\d+)/);if(e){let[,t,s]=e;De=Number(t)+.1*Number(s)<13.4,Be=!1}}else if(i.includes("OS X 10")){let[,e]=i.match(/OS X 10[_.](\d+)/);De=Be=Number(e)<15}if(i.includes("Chrome/")){let[,e]=i.match(/Chrome\/(\d+)/);De=Be=Number(e)<81}else if(i.includes("Firefox/")){let[,e]=i.match(/Firefox\/(\d+)/);De=Be=Number(e)<77}}async function cr(i){let e=await dr(i);return Object.as
|