@oardi/ts-utils 0.0.57 → 0.0.58

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,8 @@
1
1
  export declare class ImageHelper {
2
2
  static load(file: File): Promise<HTMLImageElement>;
3
+ static compress(imageBase64: string, quality?: number, fileType?: string): Promise<string>;
3
4
  static resize(img: HTMLImageElement, targetWidth: number, targetHeight: number): IImageResizeResult;
5
+ private static loadSource;
4
6
  }
5
7
  export interface IImageResizeResult {
6
8
  canvas: HTMLCanvasElement;
package/index.cjs CHANGED
@@ -1,10 +1,10 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const ze={xs:0,sm:576,md:768,lg:992,xl:1200,xxl:1400,xxxl:1600};class be{static getScreenWidth(){return document.documentElement.clientWidth}static getScreenHeight(){return document.documentElement.clientHeight}}class pe{static breakPoints=ze;static getCurrentBreakpoint(){return pe.getBreakpointByScreenWidth(be.getScreenWidth())}static getBreakpointByScreenWidth(e=be.getScreenWidth()){let n="xs";for(const s of Object.keys(pe.breakPoints))pe.breakPoints[s]<=e&&(n=s);return{breakpoint:n,screenWidth:e}}static isScreenGreaterThan(e){return be.getScreenWidth()>pe.breakPoints[e]}static isScreenSmallerThan(e){return be.getScreenWidth()<pe.breakPoints[e]}}var ee=(a=>(a.opera="opera",a.firefox="firefox",a.safari="safari",a.ie="ie",a.edgeLegacy="edgeLegacy",a.edg="edg",a.chrome="chrome",a.iOS="iOS",a.headlessChrome="headlessChrome",a.nodeRuntime="nodeRuntime",a.electron="electron",a))(ee||{});const Be=typeof navigator<"u"?navigator.userAgent:"",de=Be.toLowerCase();class G{static isBrowserEnv(){return typeof window<"u"&&typeof navigator<"u"}static isOpera(e=de){return this.isBrowserEnv()?e.includes("opr/")||e.includes("opera"):!1}static isFirefox(e=de){return this.isBrowserEnv()?e.includes("firefox")||typeof globalThis.InstallTrigger<"u":!1}static isSafari(e=de){if(!this.isBrowserEnv())return!1;const n=navigator.vendor&&navigator.vendor.includes("Apple"),s=e.includes("safari"),y=!(e.includes("crios")||e.includes("chrome")||e.includes("android")||e.includes("opr/")||e.includes("edg"));return n&&s&&y}static isIOS(e=de){if(!this.isBrowserEnv())return!1;const n=/iphone|ipad|ipod/.test(e),s=e.includes("macintosh")&&navigator.maxTouchPoints>1;return n||s}static isEdgeLegacy(){return this.isBrowserEnv()?!!window.StyleMedia&&!de.includes("edg/"):!1}static isEdg(e=de){return this.isBrowserEnv()?e.includes("edg/"):!1}static isIE(){return!this.isBrowserEnv()&&typeof document>"u"?!1:!!document.documentMode}static isChrome(e=de){if(!this.isBrowserEnv())return!1;const n=navigator.vendor&&navigator.vendor.includes("Google"),s=e.includes("chrome")||e.includes("crios"),y=!this.isEdg(e)&&!this.isOpera(e);return n&&s&&y}static isElectron(e=de){return typeof process<"u"&&process.versions?.electron?!0:e.includes("electron")}static isHeadlessChrome(e=de){return e.includes("headlesschrome")}static isNodeRuntime(){return typeof process<"u"&&!!process.versions?.node&&!this.isBrowserEnv()}static getCurrentBrowser(){if(typeof navigator>"u"){if(G.isElectron())return ee.electron;if(G.isNodeRuntime())return ee.nodeRuntime;throw new Error("navigator not set")}const e=navigator.userAgent.toLowerCase();if(G.isOpera())return ee.opera;if(G.isFirefox())return ee.firefox;if(G.isSafari())return ee.safari;if(G.isIE())return ee.ie;if(G.isEdgeLegacy())return ee.edgeLegacy;if(G.isEdg())return ee.edg;if(G.isChrome())return ee.chrome;if(G.isIOS(e))return ee.iOS;if(G.isElectron(e))return ee.electron;if(G.isHeadlessChrome(e))return ee.headlessChrome;if(G.isNodeRuntime())return ee.nodeRuntime;throw new Error("Browser could not be detected: "+e)}}class Ye{static toBlob(e,n,s=!1,y){return new Promise((b,U)=>{e.toBlob(A=>{A?b(A):U(new Error("canvas.toBlob returned null"))},n,s?y:void 0)})}}function Pe(a){return navigator.clipboard.writeText(a)}function $e(a){return a&&a.__esModule&&Object.prototype.hasOwnProperty.call(a,"default")?a.default:a}var Ee={exports:{}};var Ne=Ee.exports,Le;function We(){return Le||(Le=1,(function(a,e){((n,s)=>{a.exports=s()})(Ne,function n(){var s=typeof self<"u"?self:typeof window<"u"?window:s!==void 0?s:{},y,b=!s.document&&!!s.postMessage,U=s.IS_PAPA_WORKER||!1,A={},K=0,h={};function F(t){this._handle=null,this._finished=!1,this._completed=!1,this._halted=!1,this._input=null,this._baseIndex=0,this._partialLine="",this._rowCount=0,this._start=0,this._nextChunk=null,this.isFirstChunk=!0,this._completeResults={data:[],errors:[],meta:{}},(function(r){var i=ce(r);i.chunkSize=parseInt(i.chunkSize),r.step||r.chunk||(i.chunkSize=null),this._handle=new ne(i),(this._handle.streamer=this)._config=i}).call(this,t),this.parseChunk=function(r,i){var u=parseInt(this._config.skipFirstNLines)||0;if(this.isFirstChunk&&0<u){let E=this._config.newline;E||(g=this._config.quoteChar||'"',E=this._handle.guessLineEndings(r,g)),r=[...r.split(E).slice(u)].join(E)}this.isFirstChunk&&R(this._config.beforeFirstChunk)&&(g=this._config.beforeFirstChunk(r))!==void 0&&(r=g),this.isFirstChunk=!1,this._halted=!1;var u=this._partialLine+r,g=(this._partialLine="",this._handle.parse(u,this._baseIndex,!this._finished));if(!this._handle.paused()&&!this._handle.aborted()){if(r=g.meta.cursor,u=(this._finished||(this._partialLine=u.substring(r-this._baseIndex),this._baseIndex=r),g&&g.data&&(this._rowCount+=g.data.length),this._finished||this._config.preview&&this._rowCount>=this._config.preview),U)s.postMessage({results:g,workerId:h.WORKER_ID,finished:u});else if(R(this._config.chunk)&&!i){if(this._config.chunk(g,this._handle),this._handle.paused()||this._handle.aborted())return void(this._halted=!0);this._completeResults=g=void 0}return this._config.step||this._config.chunk||(this._completeResults.data=this._completeResults.data.concat(g.data),this._completeResults.errors=this._completeResults.errors.concat(g.errors),this._completeResults.meta=g.meta),this._completed||!u||!R(this._config.complete)||g&&g.meta.aborted||(this._config.complete(this._completeResults,this._input),this._completed=!0),u||g&&g.meta.paused||this._nextChunk(),g}this._halted=!0},this._sendError=function(r){R(this._config.error)?this._config.error(r):U&&this._config.error&&s.postMessage({workerId:h.WORKER_ID,error:r,finished:!1})}}function j(t){var r;(t=t||{}).chunkSize||(t.chunkSize=h.RemoteChunkSize),F.call(this,t),this._nextChunk=b?function(){this._readChunk(),this._chunkLoaded()}:function(){this._readChunk()},this.stream=function(i){this._input=i,this._nextChunk()},this._readChunk=function(){if(this._finished)this._chunkLoaded();else{if(r=new XMLHttpRequest,this._config.withCredentials&&(r.withCredentials=this._config.withCredentials),b||(r.onload=V(this._chunkLoaded,this),r.onerror=V(this._chunkError,this)),r.open(this._config.downloadRequestBody?"POST":"GET",this._input,!b),this._config.downloadRequestHeaders){var i,u=this._config.downloadRequestHeaders;for(i in u)r.setRequestHeader(i,u[i])}var g;this._config.chunkSize&&(g=this._start+this._config.chunkSize-1,r.setRequestHeader("Range","bytes="+this._start+"-"+g));try{r.send(this._config.downloadRequestBody)}catch(E){this._chunkError(E.message)}b&&r.status===0&&this._chunkError()}},this._chunkLoaded=function(){r.readyState===4&&(r.status<200||400<=r.status?this._chunkError():(this._start+=this._config.chunkSize||r.responseText.length,this._finished=!this._config.chunkSize||this._start>=(i=>(i=i.getResponseHeader("Content-Range"))!==null?parseInt(i.substring(i.lastIndexOf("/")+1)):-1)(r),this.parseChunk(r.responseText)))},this._chunkError=function(i){i=r.statusText||i,this._sendError(new Error(i))}}function Q(t){(t=t||{}).chunkSize||(t.chunkSize=h.LocalChunkSize),F.call(this,t);var r,i,u=typeof FileReader<"u";this.stream=function(g){this._input=g,i=g.slice||g.webkitSlice||g.mozSlice,u?((r=new FileReader).onload=V(this._chunkLoaded,this),r.onerror=V(this._chunkError,this)):r=new FileReaderSync,this._nextChunk()},this._nextChunk=function(){this._finished||this._config.preview&&!(this._rowCount<this._config.preview)||this._readChunk()},this._readChunk=function(){var g=this._input,E=(this._config.chunkSize&&(E=Math.min(this._start+this._config.chunkSize,this._input.size),g=i.call(g,this._start,E)),r.readAsText(g,this._config.encoding));u||this._chunkLoaded({target:{result:E}})},this._chunkLoaded=function(g){this._start+=this._config.chunkSize,this._finished=!this._config.chunkSize||this._start>=this._input.size,this.parseChunk(g.target.result)},this._chunkError=function(){this._sendError(r.error)}}function q(t){var r;F.call(this,t=t||{}),this.stream=function(i){return r=i,this._nextChunk()},this._nextChunk=function(){var i,u;if(!this._finished)return i=this._config.chunkSize,r=i?(u=r.substring(0,i),r.substring(i)):(u=r,""),this._finished=!r,this.parseChunk(u)}}function X(t){F.call(this,t=t||{});var r=[],i=!0,u=!1;this.pause=function(){F.prototype.pause.apply(this,arguments),this._input.pause()},this.resume=function(){F.prototype.resume.apply(this,arguments),this._input.resume()},this.stream=function(g){this._input=g,this._input.on("data",this._streamData),this._input.on("end",this._streamEnd),this._input.on("error",this._streamError)},this._checkIsFinished=function(){u&&r.length===1&&(this._finished=!0)},this._nextChunk=function(){this._checkIsFinished(),r.length?this.parseChunk(r.shift()):i=!0},this._streamData=V(function(g){try{r.push(typeof g=="string"?g:g.toString(this._config.encoding)),i&&(i=!1,this._checkIsFinished(),this.parseChunk(r.shift()))}catch(E){this._streamError(E)}},this),this._streamError=V(function(g){this._streamCleanUp(),this._sendError(g)},this),this._streamEnd=V(function(){this._streamCleanUp(),u=!0,this._streamData("")},this),this._streamCleanUp=V(function(){this._input.removeListener("data",this._streamData),this._input.removeListener("end",this._streamEnd),this._input.removeListener("error",this._streamError)},this)}function ne(t){var r,i,u,g,E=Math.pow(2,53),v=-E,f=/^\s*-?(\d+\.?|\.\d+|\d+\.\d+)([eE][-+]?\d+)?\s*$/,d=/^((\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z)))$/,o=this,c=0,l=0,w=!1,m=!1,k=[],p={data:[],errors:[],meta:{}};function M(S){return t.skipEmptyLines==="greedy"?S.join("").trim()==="":S.length===1&&S[0].length===0}function C(){if(p&&u&&(W("Delimiter","UndetectableDelimiter","Unable to auto-detect delimiting character; defaulted to '"+h.DefaultDelimiter+"'"),u=!1),t.skipEmptyLines&&(p.data=p.data.filter(function(_){return!M(_)})),B()){let _=function(T,Y){R(t.transformHeader)&&(T=t.transformHeader(T,Y)),k.push(T)};if(p)if(Array.isArray(p.data[0])){for(var S=0;B()&&S<p.data.length;S++)p.data[S].forEach(_);p.data.splice(0,1)}else p.data.forEach(_)}function D(_,T){for(var Y=t.header?{}:[],L=0;L<_.length;L++){var z=L,$=_[L],$=((ie,x)=>(P=>(t.dynamicTypingFunction&&t.dynamicTyping[P]===void 0&&(t.dynamicTyping[P]=t.dynamicTypingFunction(P)),(t.dynamicTyping[P]||t.dynamicTyping)===!0))(ie)?x==="true"||x==="TRUE"||x!=="false"&&x!=="FALSE"&&((P=>{if(f.test(P)&&(P=parseFloat(P),v<P&&P<E))return 1})(x)?parseFloat(x):d.test(x)?new Date(x):x===""?null:x):x)(z=t.header?L>=k.length?"__parsed_extra":k[L]:z,$=t.transform?t.transform($,z):$);z==="__parsed_extra"?(Y[z]=Y[z]||[],Y[z].push($)):Y[z]=$}return t.header&&(L>k.length?W("FieldMismatch","TooManyFields","Too many fields: expected "+k.length+" fields but parsed "+L,l+T):L<k.length&&W("FieldMismatch","TooFewFields","Too few fields: expected "+k.length+" fields but parsed "+L,l+T)),Y}var O;p&&(t.header||t.dynamicTyping||t.transform)&&(O=1,!p.data.length||Array.isArray(p.data[0])?(p.data=p.data.map(D),O=p.data.length):p.data=D(p.data,0),t.header&&p.meta&&(p.meta.fields=k),l+=O)}function B(){return t.header&&k.length===0}function W(S,D,O,_){S={type:S,code:D,message:O},_!==void 0&&(S.row=_),p.errors.push(S)}R(t.step)&&(g=t.step,t.step=function(S){p=S,B()?C():(C(),p.data.length!==0&&(c+=S.data.length,t.preview&&c>t.preview?i.abort():(p.data=p.data[0],g(p,o))))}),this.parse=function(S,D,O){var _=t.quoteChar||'"',_=(t.newline||(t.newline=this.guessLineEndings(S,_)),u=!1,t.delimiter?R(t.delimiter)&&(t.delimiter=t.delimiter(S),p.meta.delimiter=t.delimiter):((_=((T,Y,L,z,$)=>{var ie,x,P,he;$=$||[","," ","|",";",h.RECORD_SEP,h.UNIT_SEP];for(var ye=0;ye<$.length;ye++){for(var se,ke=$[ye],Z=0,ae=0,J=0,re=(P=void 0,new ge({comments:z,delimiter:ke,newline:Y,preview:10}).parse(T)),le=0;le<re.data.length;le++)L&&M(re.data[le])?J++:(se=re.data[le].length,ae+=se,P===void 0?P=se:0<se&&(Z+=Math.abs(se-P),P=se));0<re.data.length&&(ae/=re.data.length-J),(x===void 0||Z<=x)&&(he===void 0||he<ae)&&1.99<ae&&(x=Z,ie=ke,he=ae)}return{successful:!!(t.delimiter=ie),bestDelimiter:ie}})(S,t.newline,t.skipEmptyLines,t.comments,t.delimitersToGuess)).successful?t.delimiter=_.bestDelimiter:(u=!0,t.delimiter=h.DefaultDelimiter),p.meta.delimiter=t.delimiter),ce(t));return t.preview&&t.header&&_.preview++,r=S,i=new ge(_),p=i.parse(r,D,O),C(),w?{meta:{paused:!0}}:p||{meta:{paused:!1}}},this.paused=function(){return w},this.pause=function(){w=!0,i.abort(),r=R(t.chunk)?"":r.substring(i.getCharIndex())},this.resume=function(){o.streamer._halted?(w=!1,o.streamer.parseChunk(r,!0)):setTimeout(o.resume,3)},this.aborted=function(){return m},this.abort=function(){m=!0,i.abort(),p.meta.aborted=!0,R(t.complete)&&t.complete(p),r=""},this.guessLineEndings=function(T,_){T=T.substring(0,1048576);var _=new RegExp(ue(_)+"([^]*?)"+ue(_),"gm"),O=(T=T.replace(_,"")).split("\r"),_=T.split(`
2
- `),T=1<_.length&&_[0].length<O[0].length;if(O.length===1||T)return`
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const ze={xs:0,sm:576,md:768,lg:992,xl:1200,xxl:1400,xxxl:1600};class be{static getScreenWidth(){return document.documentElement.clientWidth}static getScreenHeight(){return document.documentElement.clientHeight}}class pe{static breakPoints=ze;static getCurrentBreakpoint(){return pe.getBreakpointByScreenWidth(be.getScreenWidth())}static getBreakpointByScreenWidth(e=be.getScreenWidth()){let n="xs";for(const s of Object.keys(pe.breakPoints))pe.breakPoints[s]<=e&&(n=s);return{breakpoint:n,screenWidth:e}}static isScreenGreaterThan(e){return be.getScreenWidth()>pe.breakPoints[e]}static isScreenSmallerThan(e){return be.getScreenWidth()<pe.breakPoints[e]}}var ee=(a=>(a.opera="opera",a.firefox="firefox",a.safari="safari",a.ie="ie",a.edgeLegacy="edgeLegacy",a.edg="edg",a.chrome="chrome",a.iOS="iOS",a.headlessChrome="headlessChrome",a.nodeRuntime="nodeRuntime",a.electron="electron",a))(ee||{});const Be=typeof navigator<"u"?navigator.userAgent:"",de=Be.toLowerCase();class G{static isBrowserEnv(){return typeof window<"u"&&typeof navigator<"u"}static isOpera(e=de){return this.isBrowserEnv()?e.includes("opr/")||e.includes("opera"):!1}static isFirefox(e=de){return this.isBrowserEnv()?e.includes("firefox")||typeof globalThis.InstallTrigger<"u":!1}static isSafari(e=de){if(!this.isBrowserEnv())return!1;const n=navigator.vendor&&navigator.vendor.includes("Apple"),s=e.includes("safari"),m=!(e.includes("crios")||e.includes("chrome")||e.includes("android")||e.includes("opr/")||e.includes("edg"));return n&&s&&m}static isIOS(e=de){if(!this.isBrowserEnv())return!1;const n=/iphone|ipad|ipod/.test(e),s=e.includes("macintosh")&&navigator.maxTouchPoints>1;return n||s}static isEdgeLegacy(){return this.isBrowserEnv()?!!window.StyleMedia&&!de.includes("edg/"):!1}static isEdg(e=de){return this.isBrowserEnv()?e.includes("edg/"):!1}static isIE(){return!this.isBrowserEnv()&&typeof document>"u"?!1:!!document.documentMode}static isChrome(e=de){if(!this.isBrowserEnv())return!1;const n=navigator.vendor&&navigator.vendor.includes("Google"),s=e.includes("chrome")||e.includes("crios"),m=!this.isEdg(e)&&!this.isOpera(e);return n&&s&&m}static isElectron(e=de){return typeof process<"u"&&process.versions?.electron?!0:e.includes("electron")}static isHeadlessChrome(e=de){return e.includes("headlesschrome")}static isNodeRuntime(){return typeof process<"u"&&!!process.versions?.node&&!this.isBrowserEnv()}static getCurrentBrowser(){if(typeof navigator>"u"){if(G.isElectron())return ee.electron;if(G.isNodeRuntime())return ee.nodeRuntime;throw new Error("navigator not set")}const e=navigator.userAgent.toLowerCase();if(G.isOpera())return ee.opera;if(G.isFirefox())return ee.firefox;if(G.isSafari())return ee.safari;if(G.isIE())return ee.ie;if(G.isEdgeLegacy())return ee.edgeLegacy;if(G.isEdg())return ee.edg;if(G.isChrome())return ee.chrome;if(G.isIOS(e))return ee.iOS;if(G.isElectron(e))return ee.electron;if(G.isHeadlessChrome(e))return ee.headlessChrome;if(G.isNodeRuntime())return ee.nodeRuntime;throw new Error("Browser could not be detected: "+e)}}class Ye{static toBlob(e,n,s=!1,m){return new Promise((_,U)=>{e.toBlob(A=>{A?_(A):U(new Error("canvas.toBlob returned null"))},n,s?m:void 0)})}}function Pe(a){return navigator.clipboard.writeText(a)}function $e(a){return a&&a.__esModule&&Object.prototype.hasOwnProperty.call(a,"default")?a.default:a}var Ee={exports:{}};var Ne=Ee.exports,Le;function We(){return Le||(Le=1,(function(a,e){((n,s)=>{a.exports=s()})(Ne,function n(){var s=typeof self<"u"?self:typeof window<"u"?window:s!==void 0?s:{},m,_=!s.document&&!!s.postMessage,U=s.IS_PAPA_WORKER||!1,A={},K=0,h={};function F(t){this._handle=null,this._finished=!1,this._completed=!1,this._halted=!1,this._input=null,this._baseIndex=0,this._partialLine="",this._rowCount=0,this._start=0,this._nextChunk=null,this.isFirstChunk=!0,this._completeResults={data:[],errors:[],meta:{}},(function(r){var i=ce(r);i.chunkSize=parseInt(i.chunkSize),r.step||r.chunk||(i.chunkSize=null),this._handle=new ne(i),(this._handle.streamer=this)._config=i}).call(this,t),this.parseChunk=function(r,i){var u=parseInt(this._config.skipFirstNLines)||0;if(this.isFirstChunk&&0<u){let E=this._config.newline;E||(y=this._config.quoteChar||'"',E=this._handle.guessLineEndings(r,y)),r=[...r.split(E).slice(u)].join(E)}this.isFirstChunk&&R(this._config.beforeFirstChunk)&&(y=this._config.beforeFirstChunk(r))!==void 0&&(r=y),this.isFirstChunk=!1,this._halted=!1;var u=this._partialLine+r,y=(this._partialLine="",this._handle.parse(u,this._baseIndex,!this._finished));if(!this._handle.paused()&&!this._handle.aborted()){if(r=y.meta.cursor,u=(this._finished||(this._partialLine=u.substring(r-this._baseIndex),this._baseIndex=r),y&&y.data&&(this._rowCount+=y.data.length),this._finished||this._config.preview&&this._rowCount>=this._config.preview),U)s.postMessage({results:y,workerId:h.WORKER_ID,finished:u});else if(R(this._config.chunk)&&!i){if(this._config.chunk(y,this._handle),this._handle.paused()||this._handle.aborted())return void(this._halted=!0);this._completeResults=y=void 0}return this._config.step||this._config.chunk||(this._completeResults.data=this._completeResults.data.concat(y.data),this._completeResults.errors=this._completeResults.errors.concat(y.errors),this._completeResults.meta=y.meta),this._completed||!u||!R(this._config.complete)||y&&y.meta.aborted||(this._config.complete(this._completeResults,this._input),this._completed=!0),u||y&&y.meta.paused||this._nextChunk(),y}this._halted=!0},this._sendError=function(r){R(this._config.error)?this._config.error(r):U&&this._config.error&&s.postMessage({workerId:h.WORKER_ID,error:r,finished:!1})}}function j(t){var r;(t=t||{}).chunkSize||(t.chunkSize=h.RemoteChunkSize),F.call(this,t),this._nextChunk=_?function(){this._readChunk(),this._chunkLoaded()}:function(){this._readChunk()},this.stream=function(i){this._input=i,this._nextChunk()},this._readChunk=function(){if(this._finished)this._chunkLoaded();else{if(r=new XMLHttpRequest,this._config.withCredentials&&(r.withCredentials=this._config.withCredentials),_||(r.onload=V(this._chunkLoaded,this),r.onerror=V(this._chunkError,this)),r.open(this._config.downloadRequestBody?"POST":"GET",this._input,!_),this._config.downloadRequestHeaders){var i,u=this._config.downloadRequestHeaders;for(i in u)r.setRequestHeader(i,u[i])}var y;this._config.chunkSize&&(y=this._start+this._config.chunkSize-1,r.setRequestHeader("Range","bytes="+this._start+"-"+y));try{r.send(this._config.downloadRequestBody)}catch(E){this._chunkError(E.message)}_&&r.status===0&&this._chunkError()}},this._chunkLoaded=function(){r.readyState===4&&(r.status<200||400<=r.status?this._chunkError():(this._start+=this._config.chunkSize||r.responseText.length,this._finished=!this._config.chunkSize||this._start>=(i=>(i=i.getResponseHeader("Content-Range"))!==null?parseInt(i.substring(i.lastIndexOf("/")+1)):-1)(r),this.parseChunk(r.responseText)))},this._chunkError=function(i){i=r.statusText||i,this._sendError(new Error(i))}}function Q(t){(t=t||{}).chunkSize||(t.chunkSize=h.LocalChunkSize),F.call(this,t);var r,i,u=typeof FileReader<"u";this.stream=function(y){this._input=y,i=y.slice||y.webkitSlice||y.mozSlice,u?((r=new FileReader).onload=V(this._chunkLoaded,this),r.onerror=V(this._chunkError,this)):r=new FileReaderSync,this._nextChunk()},this._nextChunk=function(){this._finished||this._config.preview&&!(this._rowCount<this._config.preview)||this._readChunk()},this._readChunk=function(){var y=this._input,E=(this._config.chunkSize&&(E=Math.min(this._start+this._config.chunkSize,this._input.size),y=i.call(y,this._start,E)),r.readAsText(y,this._config.encoding));u||this._chunkLoaded({target:{result:E}})},this._chunkLoaded=function(y){this._start+=this._config.chunkSize,this._finished=!this._config.chunkSize||this._start>=this._input.size,this.parseChunk(y.target.result)},this._chunkError=function(){this._sendError(r.error)}}function q(t){var r;F.call(this,t=t||{}),this.stream=function(i){return r=i,this._nextChunk()},this._nextChunk=function(){var i,u;if(!this._finished)return i=this._config.chunkSize,r=i?(u=r.substring(0,i),r.substring(i)):(u=r,""),this._finished=!r,this.parseChunk(u)}}function X(t){F.call(this,t=t||{});var r=[],i=!0,u=!1;this.pause=function(){F.prototype.pause.apply(this,arguments),this._input.pause()},this.resume=function(){F.prototype.resume.apply(this,arguments),this._input.resume()},this.stream=function(y){this._input=y,this._input.on("data",this._streamData),this._input.on("end",this._streamEnd),this._input.on("error",this._streamError)},this._checkIsFinished=function(){u&&r.length===1&&(this._finished=!0)},this._nextChunk=function(){this._checkIsFinished(),r.length?this.parseChunk(r.shift()):i=!0},this._streamData=V(function(y){try{r.push(typeof y=="string"?y:y.toString(this._config.encoding)),i&&(i=!1,this._checkIsFinished(),this.parseChunk(r.shift()))}catch(E){this._streamError(E)}},this),this._streamError=V(function(y){this._streamCleanUp(),this._sendError(y)},this),this._streamEnd=V(function(){this._streamCleanUp(),u=!0,this._streamData("")},this),this._streamCleanUp=V(function(){this._input.removeListener("data",this._streamData),this._input.removeListener("end",this._streamEnd),this._input.removeListener("error",this._streamError)},this)}function ne(t){var r,i,u,y,E=Math.pow(2,53),v=-E,f=/^\s*-?(\d+\.?|\.\d+|\d+\.\d+)([eE][-+]?\d+)?\s*$/,d=/^((\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z)))$/,o=this,c=0,l=0,w=!1,g=!1,k=[],p={data:[],errors:[],meta:{}};function M(S){return t.skipEmptyLines==="greedy"?S.join("").trim()==="":S.length===1&&S[0].length===0}function C(){if(p&&u&&(W("Delimiter","UndetectableDelimiter","Unable to auto-detect delimiting character; defaulted to '"+h.DefaultDelimiter+"'"),u=!1),t.skipEmptyLines&&(p.data=p.data.filter(function(b){return!M(b)})),B()){let b=function(T,Y){R(t.transformHeader)&&(T=t.transformHeader(T,Y)),k.push(T)};if(p)if(Array.isArray(p.data[0])){for(var S=0;B()&&S<p.data.length;S++)p.data[S].forEach(b);p.data.splice(0,1)}else p.data.forEach(b)}function D(b,T){for(var Y=t.header?{}:[],L=0;L<b.length;L++){var z=L,$=b[L],$=((ie,x)=>(P=>(t.dynamicTypingFunction&&t.dynamicTyping[P]===void 0&&(t.dynamicTyping[P]=t.dynamicTypingFunction(P)),(t.dynamicTyping[P]||t.dynamicTyping)===!0))(ie)?x==="true"||x==="TRUE"||x!=="false"&&x!=="FALSE"&&((P=>{if(f.test(P)&&(P=parseFloat(P),v<P&&P<E))return 1})(x)?parseFloat(x):d.test(x)?new Date(x):x===""?null:x):x)(z=t.header?L>=k.length?"__parsed_extra":k[L]:z,$=t.transform?t.transform($,z):$);z==="__parsed_extra"?(Y[z]=Y[z]||[],Y[z].push($)):Y[z]=$}return t.header&&(L>k.length?W("FieldMismatch","TooManyFields","Too many fields: expected "+k.length+" fields but parsed "+L,l+T):L<k.length&&W("FieldMismatch","TooFewFields","Too few fields: expected "+k.length+" fields but parsed "+L,l+T)),Y}var O;p&&(t.header||t.dynamicTyping||t.transform)&&(O=1,!p.data.length||Array.isArray(p.data[0])?(p.data=p.data.map(D),O=p.data.length):p.data=D(p.data,0),t.header&&p.meta&&(p.meta.fields=k),l+=O)}function B(){return t.header&&k.length===0}function W(S,D,O,b){S={type:S,code:D,message:O},b!==void 0&&(S.row=b),p.errors.push(S)}R(t.step)&&(y=t.step,t.step=function(S){p=S,B()?C():(C(),p.data.length!==0&&(c+=S.data.length,t.preview&&c>t.preview?i.abort():(p.data=p.data[0],y(p,o))))}),this.parse=function(S,D,O){var b=t.quoteChar||'"',b=(t.newline||(t.newline=this.guessLineEndings(S,b)),u=!1,t.delimiter?R(t.delimiter)&&(t.delimiter=t.delimiter(S),p.meta.delimiter=t.delimiter):((b=((T,Y,L,z,$)=>{var ie,x,P,he;$=$||[","," ","|",";",h.RECORD_SEP,h.UNIT_SEP];for(var ye=0;ye<$.length;ye++){for(var se,ke=$[ye],Z=0,ae=0,J=0,re=(P=void 0,new ge({comments:z,delimiter:ke,newline:Y,preview:10}).parse(T)),le=0;le<re.data.length;le++)L&&M(re.data[le])?J++:(se=re.data[le].length,ae+=se,P===void 0?P=se:0<se&&(Z+=Math.abs(se-P),P=se));0<re.data.length&&(ae/=re.data.length-J),(x===void 0||Z<=x)&&(he===void 0||he<ae)&&1.99<ae&&(x=Z,ie=ke,he=ae)}return{successful:!!(t.delimiter=ie),bestDelimiter:ie}})(S,t.newline,t.skipEmptyLines,t.comments,t.delimitersToGuess)).successful?t.delimiter=b.bestDelimiter:(u=!0,t.delimiter=h.DefaultDelimiter),p.meta.delimiter=t.delimiter),ce(t));return t.preview&&t.header&&b.preview++,r=S,i=new ge(b),p=i.parse(r,D,O),C(),w?{meta:{paused:!0}}:p||{meta:{paused:!1}}},this.paused=function(){return w},this.pause=function(){w=!0,i.abort(),r=R(t.chunk)?"":r.substring(i.getCharIndex())},this.resume=function(){o.streamer._halted?(w=!1,o.streamer.parseChunk(r,!0)):setTimeout(o.resume,3)},this.aborted=function(){return g},this.abort=function(){g=!0,i.abort(),p.meta.aborted=!0,R(t.complete)&&t.complete(p),r=""},this.guessLineEndings=function(T,b){T=T.substring(0,1048576);var b=new RegExp(ue(b)+"([^]*?)"+ue(b),"gm"),O=(T=T.replace(b,"")).split("\r"),b=T.split(`
2
+ `),T=1<b.length&&b[0].length<O[0].length;if(O.length===1||T)return`
3
3
  `;for(var Y=0,L=0;L<O.length;L++)O[L][0]===`
4
4
  `&&Y++;return Y>=O.length/2?`\r
5
- `:"\r"}}function ue(t){return t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function ge(t){var r=(t=t||{}).delimiter,i=t.newline,u=t.comments,g=t.step,E=t.preview,v=t.fastMode,f=null,d=!1,o=t.quoteChar==null?'"':t.quoteChar,c=o;if(t.escapeChar!==void 0&&(c=t.escapeChar),(typeof r!="string"||-1<h.BAD_DELIMITERS.indexOf(r))&&(r=","),u===r)throw new Error("Comment character same as delimiter");u===!0?u="#":(typeof u!="string"||-1<h.BAD_DELIMITERS.indexOf(u))&&(u=!1),i!==`
5
+ `:"\r"}}function ue(t){return t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function ge(t){var r=(t=t||{}).delimiter,i=t.newline,u=t.comments,y=t.step,E=t.preview,v=t.fastMode,f=null,d=!1,o=t.quoteChar==null?'"':t.quoteChar,c=o;if(t.escapeChar!==void 0&&(c=t.escapeChar),(typeof r!="string"||-1<h.BAD_DELIMITERS.indexOf(r))&&(r=","),u===r)throw new Error("Comment character same as delimiter");u===!0?u="#":(typeof u!="string"||-1<h.BAD_DELIMITERS.indexOf(u))&&(u=!1),i!==`
6
6
  `&&i!=="\r"&&i!==`\r
7
7
  `&&(i=`
8
- `);var l=0,w=!1;this.parse=function(m,k,p){if(typeof m!="string")throw new Error("Input must be a string");var M=m.length,C=r.length,B=i.length,W=u.length,S=R(g),D=[],O=[],_=[],T=l=0;if(!m)return Z();if(v||v!==!1&&m.indexOf(o)===-1){for(var Y=m.split(i),L=0;L<Y.length;L++){if(_=Y[L],l+=_.length,L!==Y.length-1)l+=i.length;else if(p)return Z();if(!u||_.substring(0,W)!==u){if(S){if(D=[],he(_.split(r)),ae(),w)return Z()}else he(_.split(r));if(E&&E<=L)return D=D.slice(0,E),Z(!0)}}return Z()}for(var z=m.indexOf(r,l),$=m.indexOf(i,l),ie=new RegExp(ue(c)+ue(o),"g"),x=m.indexOf(o,l);;)if(m[l]===o)for(x=l,l++;;){if((x=m.indexOf(o,x+1))===-1)return p||O.push({type:"Quotes",code:"MissingQuotes",message:"Quoted field unterminated",row:D.length,index:l}),se();if(x===M-1)return se(m.substring(l,x).replace(ie,o));if(o===c&&m[x+1]===c)x++;else if(o===c||x===0||m[x-1]!==c){z!==-1&&z<x+1&&(z=m.indexOf(r,x+1));var P=ye(($=$!==-1&&$<x+1?m.indexOf(i,x+1):$)===-1?z:Math.min(z,$));if(m.substr(x+1+P,C)===r){_.push(m.substring(l,x).replace(ie,o)),m[l=x+1+P+C]!==o&&(x=m.indexOf(o,l)),z=m.indexOf(r,l),$=m.indexOf(i,l);break}if(P=ye($),m.substring(x+1+P,x+1+P+B)===i){if(_.push(m.substring(l,x).replace(ie,o)),ke(x+1+P+B),z=m.indexOf(r,l),x=m.indexOf(o,l),S&&(ae(),w))return Z();if(E&&D.length>=E)return Z(!0);break}O.push({type:"Quotes",code:"InvalidQuotes",message:"Trailing quote on quoted field is malformed",row:D.length,index:l}),x++}}else if(u&&_.length===0&&m.substring(l,l+W)===u){if($===-1)return Z();l=$+B,$=m.indexOf(i,l),z=m.indexOf(r,l)}else if(z!==-1&&(z<$||$===-1))_.push(m.substring(l,z)),l=z+C,z=m.indexOf(r,l);else{if($===-1)break;if(_.push(m.substring(l,$)),ke($+B),S&&(ae(),w))return Z();if(E&&D.length>=E)return Z(!0)}return se();function he(J){D.push(J),T=l}function ye(J){var re=0;return re=J!==-1&&(J=m.substring(x+1,J))&&J.trim()===""?J.length:re}function se(J){return p||(J===void 0&&(J=m.substring(l)),_.push(J),l=M,he(_),S&&ae()),Z()}function ke(J){l=J,he(_),_=[],$=m.indexOf(i,l)}function Z(J){if(t.header&&!k&&D.length&&!d){var re=D[0],le=Object.create(null),Ce=new Set(re);let Re=!1;for(let ve=0;ve<re.length;ve++){let oe=re[ve];if(le[oe=R(t.transformHeader)?t.transformHeader(oe,ve):oe]){let _e,Te=le[oe];for(;_e=oe+"_"+Te,Te++,Ce.has(_e););Ce.add(_e),re[ve]=_e,le[oe]++,Re=!0,(f=f===null?{}:f)[_e]=oe}else le[oe]=1,re[ve]=oe;Ce.add(oe)}Re&&console.warn("Duplicate headers found and renamed."),d=!0}return{data:D,errors:O,meta:{delimiter:r,linebreak:i,aborted:w,truncated:!!J,cursor:T+(k||0),renamedHeaders:f}}}function ae(){g(Z()),D=[],O=[]}},this.abort=function(){w=!0},this.getCharIndex=function(){return l}}function we(t){var r=t.data,i=A[r.workerId],u=!1;if(r.error)i.userError(r.error,r.file);else if(r.results&&r.results.data){var g={abort:function(){u=!0,fe(r.workerId,{data:[],errors:[],meta:{aborted:!0}})},pause:Se,resume:Se};if(R(i.userStep)){for(var E=0;E<r.results.data.length&&(i.userStep({data:r.results.data[E],errors:r.results.errors,meta:r.results.meta},g),!u);E++);delete r.results}else R(i.userChunk)&&(i.userChunk(r.results,g,r.file),delete r.results)}r.finished&&!u&&fe(r.workerId,r.results)}function fe(t,r){var i=A[t];R(i.userComplete)&&i.userComplete(r),i.terminate(),delete A[t]}function Se(){throw new Error("Not implemented.")}function ce(t){if(typeof t!="object"||t===null)return t;var r,i=Array.isArray(t)?[]:{};for(r in t)i[r]=ce(t[r]);return i}function V(t,r){return function(){t.apply(r,arguments)}}function R(t){return typeof t=="function"}return h.parse=function(t,r){var i=(r=r||{}).dynamicTyping||!1;if(R(i)&&(r.dynamicTypingFunction=i,i={}),r.dynamicTyping=i,r.transform=!!R(r.transform)&&r.transform,!r.worker||!h.WORKERS_SUPPORTED)return i=null,h.NODE_STREAM_INPUT,typeof t=="string"?(t=(u=>u.charCodeAt(0)!==65279?u:u.slice(1))(t),i=new(r.download?j:q)(r)):t.readable===!0&&R(t.read)&&R(t.on)?i=new X(r):(s.File&&t instanceof File||t instanceof Object)&&(i=new Q(r)),i.stream(t);(i=(()=>{var u;return!!h.WORKERS_SUPPORTED&&(u=(()=>{var g=s.URL||s.webkitURL||null,E=n.toString();return h.BLOB_URL||(h.BLOB_URL=g.createObjectURL(new Blob(["var global = (function() { if (typeof self !== 'undefined') { return self; } if (typeof window !== 'undefined') { return window; } if (typeof global !== 'undefined') { return global; } return {}; })(); global.IS_PAPA_WORKER=true; ","(",E,")();"],{type:"text/javascript"})))})(),(u=new s.Worker(u)).onmessage=we,u.id=K++,A[u.id]=u)})()).userStep=r.step,i.userChunk=r.chunk,i.userComplete=r.complete,i.userError=r.error,r.step=R(r.step),r.chunk=R(r.chunk),r.complete=R(r.complete),r.error=R(r.error),delete r.worker,i.postMessage({input:t,config:r,workerId:i.id})},h.unparse=function(t,r){var i=!1,u=!0,g=",",E=`\r
9
- `,v='"',f=v+v,d=!1,o=null,c=!1,l=((()=>{if(typeof r=="object"){if(typeof r.delimiter!="string"||h.BAD_DELIMITERS.filter(function(k){return r.delimiter.indexOf(k)!==-1}).length||(g=r.delimiter),typeof r.quotes!="boolean"&&typeof r.quotes!="function"&&!Array.isArray(r.quotes)||(i=r.quotes),typeof r.skipEmptyLines!="boolean"&&typeof r.skipEmptyLines!="string"||(d=r.skipEmptyLines),typeof r.newline=="string"&&(E=r.newline),typeof r.quoteChar=="string"&&(v=r.quoteChar),typeof r.header=="boolean"&&(u=r.header),Array.isArray(r.columns)){if(r.columns.length===0)throw new Error("Option columns is empty");o=r.columns}r.escapeChar!==void 0&&(f=r.escapeChar+v),r.escapeFormulae instanceof RegExp?c=r.escapeFormulae:typeof r.escapeFormulae=="boolean"&&r.escapeFormulae&&(c=/^[=+\-@\t\r].*$/)}})(),new RegExp(ue(v),"g"));if(typeof t=="string"&&(t=JSON.parse(t)),Array.isArray(t)){if(!t.length||Array.isArray(t[0]))return w(null,t,d);if(typeof t[0]=="object")return w(o||Object.keys(t[0]),t,d)}else if(typeof t=="object")return typeof t.data=="string"&&(t.data=JSON.parse(t.data)),Array.isArray(t.data)&&(t.fields||(t.fields=t.meta&&t.meta.fields||o),t.fields||(t.fields=Array.isArray(t.data[0])?t.fields:typeof t.data[0]=="object"?Object.keys(t.data[0]):[]),Array.isArray(t.data[0])||typeof t.data[0]=="object"||(t.data=[t.data])),w(t.fields||[],t.data||[],d);throw new Error("Unable to serialize unrecognized input");function w(k,p,M){var C="",B=(typeof k=="string"&&(k=JSON.parse(k)),typeof p=="string"&&(p=JSON.parse(p)),Array.isArray(k)&&0<k.length),W=!Array.isArray(p[0]);if(B&&u){for(var S=0;S<k.length;S++)0<S&&(C+=g),C+=m(k[S],S);0<p.length&&(C+=E)}for(var D=0;D<p.length;D++){var O=(B?k:p[D]).length,_=!1,T=B?Object.keys(p[D]).length===0:p[D].length===0;if(M&&!B&&(_=M==="greedy"?p[D].join("").trim()==="":p[D].length===1&&p[D][0].length===0),M==="greedy"&&B){for(var Y=[],L=0;L<O;L++){var z=W?k[L]:L;Y.push(p[D][z])}_=Y.join("").trim()===""}if(!_){for(var $=0;$<O;$++){0<$&&!T&&(C+=g);var ie=B&&W?k[$]:$;C+=m(p[D][ie],$)}D<p.length-1&&(!M||0<O&&!T)&&(C+=E)}}return C}function m(k,p){var M,C;return k==null?"":k.constructor===Date?JSON.stringify(k).slice(1,25):(C=!1,c&&typeof k=="string"&&c.test(k)&&(k="'"+k,C=!0),M=k.toString().replace(l,f),(C=C||i===!0||typeof i=="function"&&i(k,p)||Array.isArray(i)&&i[p]||((B,W)=>{for(var S=0;S<W.length;S++)if(-1<B.indexOf(W[S]))return!0;return!1})(M,h.BAD_DELIMITERS)||-1<M.indexOf(g)||M.charAt(0)===" "||M.charAt(M.length-1)===" ")?v+M+v:M)}},h.RECORD_SEP="",h.UNIT_SEP="",h.BYTE_ORDER_MARK="\uFEFF",h.BAD_DELIMITERS=["\r",`
10
- `,'"',h.BYTE_ORDER_MARK],h.WORKERS_SUPPORTED=!b&&!!s.Worker,h.NODE_STREAM_INPUT=1,h.LocalChunkSize=10485760,h.RemoteChunkSize=5242880,h.DefaultDelimiter=",",h.Parser=ge,h.ParserHandle=ne,h.NetworkStreamer=j,h.FileStreamer=Q,h.StringStreamer=q,h.ReadableStreamStreamer=X,s.jQuery&&((y=s.jQuery).fn.parse=function(t){var r=t.config||{},i=[];return this.each(function(E){if(!(y(this).prop("tagName").toUpperCase()==="INPUT"&&y(this).attr("type").toLowerCase()==="file"&&s.FileReader)||!this.files||this.files.length===0)return!0;for(var v=0;v<this.files.length;v++)i.push({file:this.files[v],inputElem:this,instanceConfig:y.extend({},r)})}),u(),this;function u(){if(i.length===0)R(t.complete)&&t.complete();else{var E,v,f,d,o=i[0];if(R(t.before)){var c=t.before(o.file,o.inputElem);if(typeof c=="object"){if(c.action==="abort")return E="AbortError",v=o.file,f=o.inputElem,d=c.reason,void(R(t.error)&&t.error({name:E},v,f,d));if(c.action==="skip")return void g();typeof c.config=="object"&&(o.instanceConfig=y.extend(o.instanceConfig,c.config))}else if(c==="skip")return void g()}var l=o.instanceConfig.complete;o.instanceConfig.complete=function(w){R(l)&&l(w,o.file,o.inputElem),g()},h.parse(o.file,o.instanceConfig)}}function g(){i.splice(0,1),u()}}),U&&(s.onmessage=function(t){t=t.data,h.WORKER_ID===void 0&&t&&(h.WORKER_ID=t.workerId),typeof t.input=="string"?s.postMessage({workerId:h.WORKER_ID,results:h.parse(t.input,t.config),finished:!0}):(s.File&&t.input instanceof File||t.input instanceof Object)&&(t=h.parse(t.input,t.config))&&s.postMessage({workerId:h.WORKER_ID,results:t,finished:!0})}),(j.prototype=Object.create(F.prototype)).constructor=j,(Q.prototype=Object.create(F.prototype)).constructor=Q,(q.prototype=Object.create(q.prototype)).constructor=q,(X.prototype=Object.create(F.prototype)).constructor=X,h})})(Ee)),Ee.exports}var qe=We();const Ke=$e(qe),{parse:Je,unparse:Qe}=Ke;class Ve{static unparse(e,n){return Qe(e,n)}static parse(e){return new Promise((n,s)=>{Je(e,{header:!0,complete:y=>n(y),error:y=>s(y)})})}}class Ue{static revokeObjectUrlDelay=4e4;static utf8BomMimeType=/^\s*(?:text\/\S*|application\/xml|\S+\/\S+\+xml)\s*;\s*charset\s*=\s*utf-8/i;static saveAs(e,n,s={}){this.assertBrowserEnvironment();const y=s.autoBom?this.addUtf8Bom(e):e;this.downloadBlob(y,n)}static addUtf8Bom(e){return this.utf8BomMimeType.test(e.type)?new Blob(["\uFEFF",e],{type:e.type}):e}static assertBrowserEnvironment(){if(typeof window>"u"||typeof document>"u"||typeof URL>"u"||typeof URL.createObjectURL!="function"||typeof URL.revokeObjectURL!="function")throw new Error("DownloadHelper is only available in a browser environment with object URL support.")}static downloadBlob(e,n){const s=URL.createObjectURL(e);try{G.isIOS()?this.openBlobInNewTab(s)||this.clickDownloadLink(s,n,!1):this.clickDownloadLink(s,n)}finally{window.setTimeout(()=>URL.revokeObjectURL(s),this.revokeObjectUrlDelay)}}static openBlobInNewTab(e){const n=window.open("about:blank","_blank");if(!n)return!1;try{return n.opener=null,n.location.replace(e),!0}catch{return n.close(),!1}}static clickDownloadLink(e,n,s=!0){const y=document.body??document.documentElement;if(!y)throw new Error("DownloadHelper.saveAs requires an initialized document.");const b=document.createElement("a");try{b.download=n,b.href=e,s&&(b.target="_blank",b.rel="noopener noreferrer"),b.style.display="none",y.appendChild(b),b.click()}finally{b.remove()}}}class Ze{static getEnumValue(e,n){if(n in e)return e[n];throw Error(`${n} not found in ${e}`)}static getKeyValues(e){return Object.keys(e).filter(n=>!isNaN(Number(n))).map(n=>({key:Number(n),value:e[n]}))}}class He{static getFileExtension(e){let n="";const s=e.lastIndexOf(".");return s>0&&s<e.length-1&&(n=`.${e.substring(s+1).toLowerCase()}`),n}static readAsText(e){const n=new FileReader;return new Promise((s,y)=>{n.onload=()=>{n.onload=null,n.onerror=null,typeof n.result=="string"?s(n.result):y(new Error("Unexpected result type"))},n.onerror=()=>{const b=n.error??new Error("FileReader error");n.onload=null,n.onerror=null,y(b)},n.readAsText(e)})}static readAsArrayBuffer(e){const n=new FileReader;return new Promise((s,y)=>{n.onload=()=>{n.onload=null,n.onerror=null,n.result instanceof ArrayBuffer?s(n.result):y(new Error("Unexpected result type"))},n.onerror=()=>{const b=n.error??new Error("FileReader error");n.onload=null,n.onerror=null,y(b)},n.readAsArrayBuffer(e)})}static readAsDataUrl(e){const n=new FileReader;return new Promise((s,y)=>{n.onload=b=>{s(b)},n.onerror=b=>y(b),n.readAsDataURL(e)})}static formatFileSize(e,n=2,s){if(e===0)return"0 Bytes";const y=1024,b=["Bytes","KB","MB","GB","TB"];let U=Math.floor(Math.log(e)/Math.log(y));s&&b.includes(s)&&(U=b.indexOf(s));const A=e/Math.pow(y,U);return`${parseFloat(A.toFixed(n))} ${b[U]}`}static save(e,n,s){const y=new Blob([e],{type:s});Ue.saveAs(y,n)}}class Ge{static load(e){return new Promise((n,s)=>{const y=new Image;y.onload=()=>n(y),y.onerror=s,y.src=URL.createObjectURL(e)})}static resize(e,n,s){let{width:y,height:b}=e;const U=n/y,A=s/b,K=Math.min(U,A,1);y=Math.floor(y*K),b=Math.floor(b*K);const h=document.createElement("canvas");h.width=y,h.height=b;const F=h.getContext("2d");return F.clearRect(0,0,y,b),F.drawImage(e,0,0,y,b),{canvas:h,width:y,height:b}}}class xe{static set(e,n){localStorage.setItem(e,JSON.stringify(n))}static get(e){let n=null;const s=localStorage.getItem(e);return s&&(n=JSON.parse(s)),n}static remove(e){const n=localStorage.getItem(e)!==null;return n&&localStorage.removeItem(e),n}static removeAll(){localStorage.clear()}static getKeysBy(e){return Object.keys(localStorage).filter(n=>n.startsWith(e))}}var me=(a=>(a.log="log",a.info="info",a.warn="warn",a.debug="debug",a.error="error",a))(me||{});class H{static listeners=new Set;static enabled=!0;static log(...e){H.doLog(me.log,e)}static info(...e){H.doLog(me.info,e)}static warn(...e){H.doLog(me.warn,e)}static debug(...e){H.doLog(me.debug,e)}static error(...e){H.doLog(me.error,e)}static clearListeners(){H.listeners.clear()}static setEnabled(e){H.enabled=e}static doLog(e,n){if(!H.enabled)return;const s={type:e,args:n,timestamp:new Date().toISOString()};for(const y of H.listeners)try{if(y(s)===!1)return}catch{}console[e].apply(console,n)}static onLog(e,n=!1){if(n){const s=y=>{try{return e(y)}finally{H.listeners.delete(s)}};return H.listeners.add(s),()=>H.listeners.delete(s)}return H.listeners.add(e),()=>H.listeners.delete(e)}}const Xe=(a,e,n)=>a.localeCompare(e)*(n?1:-1),et=(a,e)=>a<e?-1:a===e?0:1,tt=(a,e,n)=>et(a,e)*(n?1:-1),rt=(a,e,n)=>typeof a=="string"&&typeof e=="string"?Xe(a,e,n):tt(a,e,n),je=(a,e,n,s)=>{const y=n(a),b=n(e);return rt(y,b,s)};class nt{static get(e){return xe.get(e)}static set(e,n){xe.set(e,n)}static remove(e){xe.remove(e)}}class I{static listeners=new Set;static initialized=!1;static resizeTimeout=null;static lastWidth=null;static onResize(e){return I.initialized||I.init(),I.listeners.add(e),()=>I.off(e)}static handleResize=()=>{I.resizeTimeout!==null&&(window.clearTimeout(I.resizeTimeout),I.resizeTimeout=null),I.resizeTimeout=window.setTimeout(()=>{const e=window.innerWidth;if(I.resizeTimeout=null,e!==I.lastWidth){I.lastWidth=e;for(const n of I.listeners)n(e)}},150)};static init(){if(!I.initialized){if(typeof window>"u")throw new Error("WindowResizeHelper is only available in browser environments");I.lastWidth=window.innerWidth,window.addEventListener("resize",I.handleResize,{passive:!0}),I.initialized=!0}}static off(e){I.initialized&&(I.listeners.delete(e),I.listeners.size===0&&(I.resizeTimeout!==null&&(window.clearTimeout(I.resizeTimeout),I.resizeTimeout=null),window.removeEventListener("resize",I.handleResize),I.initialized=!1,I.lastWidth=null))}}function N(a,e,n){Object.defineProperty(a,e,{configurable:!0,enumerable:!1,value:n,writable:!0})}function it(){N(Array.prototype,"distinct",function(a){return a?this.filter((n,s,y)=>y.findIndex(b=>a(b,n))===s):this.filter((n,s,y)=>y.indexOf(n)===s)}),N(Array.prototype,"filterBy",function(a){return this.filter(e=>a(e))}),N(Array.prototype,"first",function(){return this.length>0?this[0]:null}),N(Array.prototype,"groupBy",function(a){return this.reduce((e,n)=>{const s=a(n);return e[s]||(e[s]=[]),e[s].push(n),e},{})}),N(Array.prototype,"orderBy",function(a,e=!0){return this?.sort((n,s)=>je(n,s,a,e)),this}),N(Array.prototype,"removeBy",function(a,e){return this.filter(n=>a(n)!==e)})}var De={exports:{}},st=De.exports,Ie;function at(){return Ie||(Ie=1,(function(a,e){(function(n,s){a.exports=s()})(st,(function(){var n=1e3,s=6e4,y=36e5,b="millisecond",U="second",A="minute",K="hour",h="day",F="week",j="month",Q="quarter",q="year",X="date",ne="Invalid Date",ue=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,ge=/\[([^\]]+)]|YYYY|YY|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,we={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(v){var f=["th","st","nd","rd"],d=v%100;return"["+v+(f[(d-20)%10]||f[d]||f[0])+"]"}},fe=function(v,f,d){var o=String(v);return!o||o.length>=f?v:""+Array(f+1-o.length).join(d)+v},Se={s:fe,z:function(v){var f=-v.utcOffset(),d=Math.abs(f),o=Math.floor(d/60),c=d%60;return(f<=0?"+":"-")+fe(o,2,"0")+":"+fe(c,2,"0")},m:function v(f,d){if(f.date()<d.date())return-v(d,f);var o=12*(d.year()-f.year())+(d.month()-f.month()),c=f.clone().add(o,j),l=d-c<0,w=f.clone().add(o+(l?-1:1),j);return+(-(o+(d-c)/(l?c-w:w-c))||0)},a:function(v){return v<0?Math.ceil(v)||0:Math.floor(v)},p:function(v){return{M:j,y:q,w:F,d:h,D:X,h:K,m:A,s:U,ms:b,Q}[v]||String(v||"").toLowerCase().replace(/s$/,"")},u:function(v){return v===void 0}},ce="en",V={};V[ce]=we;var R="$isDayjsObject",t=function(v){return v instanceof g||!(!v||!v[R])},r=function v(f,d,o){var c;if(!f)return ce;if(typeof f=="string"){var l=f.toLowerCase();V[l]&&(c=l),d&&(V[l]=d,c=l);var w=f.split("-");if(!c&&w.length>1)return v(w[0])}else{var m=f.name;V[m]=f,c=m}return!o&&c&&(ce=c),c||!o&&ce},i=function(v,f){if(t(v))return v.clone();var d=typeof f=="object"?f:{};return d.date=v,d.args=arguments,new g(d)},u=Se;u.l=r,u.i=t,u.w=function(v,f){return i(v,{locale:f.$L,utc:f.$u,x:f.$x,$offset:f.$offset})};var g=(function(){function v(d){this.$L=r(d.locale,null,!0),this.parse(d),this.$x=this.$x||d.x||{},this[R]=!0}var f=v.prototype;return f.parse=function(d){this.$d=(function(o){var c=o.date,l=o.utc;if(c===null)return new Date(NaN);if(u.u(c))return new Date;if(c instanceof Date)return new Date(c);if(typeof c=="string"&&!/Z$/i.test(c)){var w=c.match(ue);if(w){var m=w[2]-1||0,k=(w[7]||"0").substring(0,3);return l?new Date(Date.UTC(w[1],m,w[3]||1,w[4]||0,w[5]||0,w[6]||0,k)):new Date(w[1],m,w[3]||1,w[4]||0,w[5]||0,w[6]||0,k)}}return new Date(c)})(d),this.init()},f.init=function(){var d=this.$d;this.$y=d.getFullYear(),this.$M=d.getMonth(),this.$D=d.getDate(),this.$W=d.getDay(),this.$H=d.getHours(),this.$m=d.getMinutes(),this.$s=d.getSeconds(),this.$ms=d.getMilliseconds()},f.$utils=function(){return u},f.isValid=function(){return this.$d.toString()!==ne},f.isSame=function(d,o){var c=i(d);return this.startOf(o)<=c&&c<=this.endOf(o)},f.isAfter=function(d,o){return i(d)<this.startOf(o)},f.isBefore=function(d,o){return this.endOf(o)<i(d)},f.$g=function(d,o,c){return u.u(d)?this[o]:this.set(c,d)},f.unix=function(){return Math.floor(this.valueOf()/1e3)},f.valueOf=function(){return this.$d.getTime()},f.startOf=function(d,o){var c=this,l=!!u.u(o)||o,w=u.p(d),m=function(D,O){var _=u.w(c.$u?Date.UTC(c.$y,O,D):new Date(c.$y,O,D),c);return l?_:_.endOf(h)},k=function(D,O){return u.w(c.toDate()[D].apply(c.toDate("s"),(l?[0,0,0,0]:[23,59,59,999]).slice(O)),c)},p=this.$W,M=this.$M,C=this.$D,B="set"+(this.$u?"UTC":"");switch(w){case q:return l?m(1,0):m(31,11);case j:return l?m(1,M):m(0,M+1);case F:var W=this.$locale().weekStart||0,S=(p<W?p+7:p)-W;return m(l?C-S:C+(6-S),M);case h:case X:return k(B+"Hours",0);case K:return k(B+"Minutes",1);case A:return k(B+"Seconds",2);case U:return k(B+"Milliseconds",3);default:return this.clone()}},f.endOf=function(d){return this.startOf(d,!1)},f.$set=function(d,o){var c,l=u.p(d),w="set"+(this.$u?"UTC":""),m=(c={},c[h]=w+"Date",c[X]=w+"Date",c[j]=w+"Month",c[q]=w+"FullYear",c[K]=w+"Hours",c[A]=w+"Minutes",c[U]=w+"Seconds",c[b]=w+"Milliseconds",c)[l],k=l===h?this.$D+(o-this.$W):o;if(l===j||l===q){var p=this.clone().set(X,1);p.$d[m](k),p.init(),this.$d=p.set(X,Math.min(this.$D,p.daysInMonth())).$d}else m&&this.$d[m](k);return this.init(),this},f.set=function(d,o){return this.clone().$set(d,o)},f.get=function(d){return this[u.p(d)]()},f.add=function(d,o){var c,l=this;d=Number(d);var w=u.p(o),m=function(M){var C=i(l);return u.w(C.date(C.date()+Math.round(M*d)),l)};if(w===j)return this.set(j,this.$M+d);if(w===q)return this.set(q,this.$y+d);if(w===h)return m(1);if(w===F)return m(7);var k=(c={},c[A]=s,c[K]=y,c[U]=n,c)[w]||1,p=this.$d.getTime()+d*k;return u.w(p,this)},f.subtract=function(d,o){return this.add(-1*d,o)},f.format=function(d){var o=this,c=this.$locale();if(!this.isValid())return c.invalidDate||ne;var l=d||"YYYY-MM-DDTHH:mm:ssZ",w=u.z(this),m=this.$H,k=this.$m,p=this.$M,M=c.weekdays,C=c.months,B=c.meridiem,W=function(O,_,T,Y){return O&&(O[_]||O(o,l))||T[_].slice(0,Y)},S=function(O){return u.s(m%12||12,O,"0")},D=B||function(O,_,T){var Y=O<12?"AM":"PM";return T?Y.toLowerCase():Y};return l.replace(ge,(function(O,_){return _||(function(T){switch(T){case"YY":return String(o.$y).slice(-2);case"YYYY":return u.s(o.$y,4,"0");case"M":return p+1;case"MM":return u.s(p+1,2,"0");case"MMM":return W(c.monthsShort,p,C,3);case"MMMM":return W(C,p);case"D":return o.$D;case"DD":return u.s(o.$D,2,"0");case"d":return String(o.$W);case"dd":return W(c.weekdaysMin,o.$W,M,2);case"ddd":return W(c.weekdaysShort,o.$W,M,3);case"dddd":return M[o.$W];case"H":return String(m);case"HH":return u.s(m,2,"0");case"h":return S(1);case"hh":return S(2);case"a":return D(m,k,!0);case"A":return D(m,k,!1);case"m":return String(k);case"mm":return u.s(k,2,"0");case"s":return String(o.$s);case"ss":return u.s(o.$s,2,"0");case"SSS":return u.s(o.$ms,3,"0");case"Z":return w}return null})(O)||w.replace(":","")}))},f.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},f.diff=function(d,o,c){var l,w=this,m=u.p(o),k=i(d),p=(k.utcOffset()-this.utcOffset())*s,M=this-k,C=function(){return u.m(w,k)};switch(m){case q:l=C()/12;break;case j:l=C();break;case Q:l=C()/3;break;case F:l=(M-p)/6048e5;break;case h:l=(M-p)/864e5;break;case K:l=M/y;break;case A:l=M/s;break;case U:l=M/n;break;default:l=M}return c?l:u.a(l)},f.daysInMonth=function(){return this.endOf(j).$D},f.$locale=function(){return V[this.$L]},f.locale=function(d,o){if(!d)return this.$L;var c=this.clone(),l=r(d,o,!0);return l&&(c.$L=l),c},f.clone=function(){return u.w(this.$d,this)},f.toDate=function(){return new Date(this.valueOf())},f.toJSON=function(){return this.isValid()?this.toISOString():null},f.toISOString=function(){return this.$d.toISOString()},f.toString=function(){return this.$d.toUTCString()},v})(),E=g.prototype;return i.prototype=E,[["$ms",b],["$s",U],["$m",A],["$H",K],["$W",h],["$M",j],["$y",q],["$D",X]].forEach((function(v){E[v[1]]=function(f){return this.$g(f,v[0],v[1])}})),i.extend=function(v,f){return v.$i||(v(f,g,i),v.$i=!0),i},i.locale=r,i.isDayjs=t,i.unix=function(v){return i(1e3*v)},i.en=V[ce],i.Ls=V,i.p={},i}))})(De)),De.exports}var ot=at();const te=$e(ot);var Oe={exports:{}},ut=Oe.exports,Ae;function ct(){return Ae||(Ae=1,(function(a,e){(function(n,s){a.exports=s()})(ut,(function(){var n="day";return function(s,y,b){var U=function(h){return h.add(4-h.isoWeekday(),n)},A=y.prototype;A.isoWeekYear=function(){return U(this).year()},A.isoWeek=function(h){if(!this.$utils().u(h))return this.add(7*(h-this.isoWeek()),n);var F,j,Q,q,X=U(this),ne=(F=this.isoWeekYear(),j=this.$u,Q=(j?b.utc:b)().year(F).startOf("year"),q=4-Q.isoWeekday(),Q.isoWeekday()>4&&(q+=7),Q.add(q,n));return X.diff(ne,"week")+1},A.isoWeekday=function(h){return this.$utils().u(h)?this.day()||7:this.day(this.day()%7?h:h-7)};var K=A.startOf;A.startOf=function(h,F){var j=this.$utils(),Q=!!j.u(F)||F;return j.p(h)==="isoweek"?Q?this.date(this.date()-(this.isoWeekday()-1)).startOf("day"):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf("day"):K.bind(this)(h,F)}}}))})(Oe)),Oe.exports}var lt=ct();const dt=$e(lt);var Me={exports:{}},ft=Me.exports,Fe;function ht(){return Fe||(Fe=1,(function(a,e){(function(n,s){a.exports=s()})(ft,(function(){var n={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};return function(s,y,b){var U=y.prototype,A=U.format;b.en.formats=n,U.format=function(K){K===void 0&&(K="YYYY-MM-DDTHH:mm:ssZ");var h=this.$locale().formats,F=(function(j,Q){return j.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(q,X,ne){var ue=ne&&ne.toUpperCase();return X||Q[ne]||n[ne]||Q[ue].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(ge,we,fe){return we||fe.slice(1)}))}))})(K,h===void 0?{}:h);return A.call(this,F)}}}))})(Me)),Me.exports}var pt=ht();const mt=$e(pt);te.extend(mt);te.extend(dt);function gt(){N(Date.prototype,"add",function(a,e){return te(this).add(a,e).toDate()}),N(Date.prototype,"diff",function(a,e){return te(this).diff(a,e)}),N(Date.prototype,"endOf",function(a){return te(this).endOf(a).toDate()}),N(Date.prototype,"firstDayOfMonth",function(){return te(this).startOf("month").toDate()}),N(Date.prototype,"format",function(a){return te(this).format(a)}),N(Date.prototype,"isAfter",function(a,e){return te(this).isAfter(a,e)}),N(Date.prototype,"isBefore",function(a,e){return te(this).isBefore(a,e)}),N(Date.prototype,"isValid",function(){return te(this).isValid()}),N(Date.prototype,"isoWeek",function(){return te(this).isoWeek()}),N(Date.prototype,"subtract",function(a,e){return te(this).subtract(a,e).toDate()}),N(Date.prototype,"lastDayOfMonth",function(){return te(this).endOf("month").toDate()}),N(Date.prototype,"set",function(a,e){return te(this).set(a,e).toDate()}),N(Date.prototype,"startOf",function(a){return te(this).startOf(a).toDate()})}function yt(){N(String.prototype,"capitalize",function(){return this.charAt(0).toUpperCase()+this.slice(1)}),N(String.prototype,"isNumber",function(){return!isNaN(Number(this))&&this.trim()!==""}),N(String.prototype,"isEmpty",function(){return this===void 0||!this||this.length===0}),N(String.prototype,"stripTags",function(){return new DOMParser().parseFromString(this.toString(),"text/html").body.textContent||""})}class vt{resizeListener=null;onResizeCallbacks=new Set;emitTimeoutId=null;duplicateThresholdMs=60;constructor(){typeof window<"u"&&(this.resizeListener=this.onResize,window.addEventListener("resize",this.resizeListener,{passive:!0}))}destroy(){typeof window<"u"&&this.resizeListener!==null&&(window.removeEventListener("resize",this.resizeListener),this.resizeListener=null),this.emitTimeoutId!==null&&(clearTimeout(this.emitTimeoutId),this.emitTimeoutId=null),this.onResizeCallbacks.clear()}onResizeChange(e){this.onResizeCallbacks.add(e)}offResizeChange(e){this.onResizeCallbacks.delete(e)}onResize=()=>{if(typeof window>"u")return;const e=window.innerWidth;this.emitTimeoutId!==null&&clearTimeout(this.emitTimeoutId),this.emitTimeoutId=window.setTimeout(()=>{this.emitTimeoutId=null;const n=pe.getBreakpointByScreenWidth(e);for(const s of this.onResizeCallbacks)s(e,n)},this.duplicateThresholdMs)}}exports.BreakPointHelper=pe;exports.BreakPoints=ze;exports.BrowserHelper=G;exports.BrowserService=vt;exports.BrowserType=ee;exports.CanvasHelper=Ye;exports.CsvHelper=Ve;exports.DownloadHelper=Ue;exports.EnumHelper=Ze;exports.FileHelper=He;exports.ImageHelper=Ge;exports.LocalStorageHelper=xe;exports.LoggerHelper=H;exports.LoggerType=me;exports.ScreenHelper=be;exports.TokenHelper=nt;exports.WindowResizeHelper=I;exports.copyToClipboard=Pe;exports.initArrayExtensions=it;exports.initDateExtensions=gt;exports.initStringExtensions=yt;exports.sortHelper=je;
8
+ `);var l=0,w=!1;this.parse=function(g,k,p){if(typeof g!="string")throw new Error("Input must be a string");var M=g.length,C=r.length,B=i.length,W=u.length,S=R(y),D=[],O=[],b=[],T=l=0;if(!g)return Z();if(v||v!==!1&&g.indexOf(o)===-1){for(var Y=g.split(i),L=0;L<Y.length;L++){if(b=Y[L],l+=b.length,L!==Y.length-1)l+=i.length;else if(p)return Z();if(!u||b.substring(0,W)!==u){if(S){if(D=[],he(b.split(r)),ae(),w)return Z()}else he(b.split(r));if(E&&E<=L)return D=D.slice(0,E),Z(!0)}}return Z()}for(var z=g.indexOf(r,l),$=g.indexOf(i,l),ie=new RegExp(ue(c)+ue(o),"g"),x=g.indexOf(o,l);;)if(g[l]===o)for(x=l,l++;;){if((x=g.indexOf(o,x+1))===-1)return p||O.push({type:"Quotes",code:"MissingQuotes",message:"Quoted field unterminated",row:D.length,index:l}),se();if(x===M-1)return se(g.substring(l,x).replace(ie,o));if(o===c&&g[x+1]===c)x++;else if(o===c||x===0||g[x-1]!==c){z!==-1&&z<x+1&&(z=g.indexOf(r,x+1));var P=ye(($=$!==-1&&$<x+1?g.indexOf(i,x+1):$)===-1?z:Math.min(z,$));if(g.substr(x+1+P,C)===r){b.push(g.substring(l,x).replace(ie,o)),g[l=x+1+P+C]!==o&&(x=g.indexOf(o,l)),z=g.indexOf(r,l),$=g.indexOf(i,l);break}if(P=ye($),g.substring(x+1+P,x+1+P+B)===i){if(b.push(g.substring(l,x).replace(ie,o)),ke(x+1+P+B),z=g.indexOf(r,l),x=g.indexOf(o,l),S&&(ae(),w))return Z();if(E&&D.length>=E)return Z(!0);break}O.push({type:"Quotes",code:"InvalidQuotes",message:"Trailing quote on quoted field is malformed",row:D.length,index:l}),x++}}else if(u&&b.length===0&&g.substring(l,l+W)===u){if($===-1)return Z();l=$+B,$=g.indexOf(i,l),z=g.indexOf(r,l)}else if(z!==-1&&(z<$||$===-1))b.push(g.substring(l,z)),l=z+C,z=g.indexOf(r,l);else{if($===-1)break;if(b.push(g.substring(l,$)),ke($+B),S&&(ae(),w))return Z();if(E&&D.length>=E)return Z(!0)}return se();function he(J){D.push(J),T=l}function ye(J){var re=0;return re=J!==-1&&(J=g.substring(x+1,J))&&J.trim()===""?J.length:re}function se(J){return p||(J===void 0&&(J=g.substring(l)),b.push(J),l=M,he(b),S&&ae()),Z()}function ke(J){l=J,he(b),b=[],$=g.indexOf(i,l)}function Z(J){if(t.header&&!k&&D.length&&!d){var re=D[0],le=Object.create(null),Ce=new Set(re);let Re=!1;for(let ve=0;ve<re.length;ve++){let oe=re[ve];if(le[oe=R(t.transformHeader)?t.transformHeader(oe,ve):oe]){let _e,Te=le[oe];for(;_e=oe+"_"+Te,Te++,Ce.has(_e););Ce.add(_e),re[ve]=_e,le[oe]++,Re=!0,(f=f===null?{}:f)[_e]=oe}else le[oe]=1,re[ve]=oe;Ce.add(oe)}Re&&console.warn("Duplicate headers found and renamed."),d=!0}return{data:D,errors:O,meta:{delimiter:r,linebreak:i,aborted:w,truncated:!!J,cursor:T+(k||0),renamedHeaders:f}}}function ae(){y(Z()),D=[],O=[]}},this.abort=function(){w=!0},this.getCharIndex=function(){return l}}function we(t){var r=t.data,i=A[r.workerId],u=!1;if(r.error)i.userError(r.error,r.file);else if(r.results&&r.results.data){var y={abort:function(){u=!0,fe(r.workerId,{data:[],errors:[],meta:{aborted:!0}})},pause:Se,resume:Se};if(R(i.userStep)){for(var E=0;E<r.results.data.length&&(i.userStep({data:r.results.data[E],errors:r.results.errors,meta:r.results.meta},y),!u);E++);delete r.results}else R(i.userChunk)&&(i.userChunk(r.results,y,r.file),delete r.results)}r.finished&&!u&&fe(r.workerId,r.results)}function fe(t,r){var i=A[t];R(i.userComplete)&&i.userComplete(r),i.terminate(),delete A[t]}function Se(){throw new Error("Not implemented.")}function ce(t){if(typeof t!="object"||t===null)return t;var r,i=Array.isArray(t)?[]:{};for(r in t)i[r]=ce(t[r]);return i}function V(t,r){return function(){t.apply(r,arguments)}}function R(t){return typeof t=="function"}return h.parse=function(t,r){var i=(r=r||{}).dynamicTyping||!1;if(R(i)&&(r.dynamicTypingFunction=i,i={}),r.dynamicTyping=i,r.transform=!!R(r.transform)&&r.transform,!r.worker||!h.WORKERS_SUPPORTED)return i=null,h.NODE_STREAM_INPUT,typeof t=="string"?(t=(u=>u.charCodeAt(0)!==65279?u:u.slice(1))(t),i=new(r.download?j:q)(r)):t.readable===!0&&R(t.read)&&R(t.on)?i=new X(r):(s.File&&t instanceof File||t instanceof Object)&&(i=new Q(r)),i.stream(t);(i=(()=>{var u;return!!h.WORKERS_SUPPORTED&&(u=(()=>{var y=s.URL||s.webkitURL||null,E=n.toString();return h.BLOB_URL||(h.BLOB_URL=y.createObjectURL(new Blob(["var global = (function() { if (typeof self !== 'undefined') { return self; } if (typeof window !== 'undefined') { return window; } if (typeof global !== 'undefined') { return global; } return {}; })(); global.IS_PAPA_WORKER=true; ","(",E,")();"],{type:"text/javascript"})))})(),(u=new s.Worker(u)).onmessage=we,u.id=K++,A[u.id]=u)})()).userStep=r.step,i.userChunk=r.chunk,i.userComplete=r.complete,i.userError=r.error,r.step=R(r.step),r.chunk=R(r.chunk),r.complete=R(r.complete),r.error=R(r.error),delete r.worker,i.postMessage({input:t,config:r,workerId:i.id})},h.unparse=function(t,r){var i=!1,u=!0,y=",",E=`\r
9
+ `,v='"',f=v+v,d=!1,o=null,c=!1,l=((()=>{if(typeof r=="object"){if(typeof r.delimiter!="string"||h.BAD_DELIMITERS.filter(function(k){return r.delimiter.indexOf(k)!==-1}).length||(y=r.delimiter),typeof r.quotes!="boolean"&&typeof r.quotes!="function"&&!Array.isArray(r.quotes)||(i=r.quotes),typeof r.skipEmptyLines!="boolean"&&typeof r.skipEmptyLines!="string"||(d=r.skipEmptyLines),typeof r.newline=="string"&&(E=r.newline),typeof r.quoteChar=="string"&&(v=r.quoteChar),typeof r.header=="boolean"&&(u=r.header),Array.isArray(r.columns)){if(r.columns.length===0)throw new Error("Option columns is empty");o=r.columns}r.escapeChar!==void 0&&(f=r.escapeChar+v),r.escapeFormulae instanceof RegExp?c=r.escapeFormulae:typeof r.escapeFormulae=="boolean"&&r.escapeFormulae&&(c=/^[=+\-@\t\r].*$/)}})(),new RegExp(ue(v),"g"));if(typeof t=="string"&&(t=JSON.parse(t)),Array.isArray(t)){if(!t.length||Array.isArray(t[0]))return w(null,t,d);if(typeof t[0]=="object")return w(o||Object.keys(t[0]),t,d)}else if(typeof t=="object")return typeof t.data=="string"&&(t.data=JSON.parse(t.data)),Array.isArray(t.data)&&(t.fields||(t.fields=t.meta&&t.meta.fields||o),t.fields||(t.fields=Array.isArray(t.data[0])?t.fields:typeof t.data[0]=="object"?Object.keys(t.data[0]):[]),Array.isArray(t.data[0])||typeof t.data[0]=="object"||(t.data=[t.data])),w(t.fields||[],t.data||[],d);throw new Error("Unable to serialize unrecognized input");function w(k,p,M){var C="",B=(typeof k=="string"&&(k=JSON.parse(k)),typeof p=="string"&&(p=JSON.parse(p)),Array.isArray(k)&&0<k.length),W=!Array.isArray(p[0]);if(B&&u){for(var S=0;S<k.length;S++)0<S&&(C+=y),C+=g(k[S],S);0<p.length&&(C+=E)}for(var D=0;D<p.length;D++){var O=(B?k:p[D]).length,b=!1,T=B?Object.keys(p[D]).length===0:p[D].length===0;if(M&&!B&&(b=M==="greedy"?p[D].join("").trim()==="":p[D].length===1&&p[D][0].length===0),M==="greedy"&&B){for(var Y=[],L=0;L<O;L++){var z=W?k[L]:L;Y.push(p[D][z])}b=Y.join("").trim()===""}if(!b){for(var $=0;$<O;$++){0<$&&!T&&(C+=y);var ie=B&&W?k[$]:$;C+=g(p[D][ie],$)}D<p.length-1&&(!M||0<O&&!T)&&(C+=E)}}return C}function g(k,p){var M,C;return k==null?"":k.constructor===Date?JSON.stringify(k).slice(1,25):(C=!1,c&&typeof k=="string"&&c.test(k)&&(k="'"+k,C=!0),M=k.toString().replace(l,f),(C=C||i===!0||typeof i=="function"&&i(k,p)||Array.isArray(i)&&i[p]||((B,W)=>{for(var S=0;S<W.length;S++)if(-1<B.indexOf(W[S]))return!0;return!1})(M,h.BAD_DELIMITERS)||-1<M.indexOf(y)||M.charAt(0)===" "||M.charAt(M.length-1)===" ")?v+M+v:M)}},h.RECORD_SEP="",h.UNIT_SEP="",h.BYTE_ORDER_MARK="\uFEFF",h.BAD_DELIMITERS=["\r",`
10
+ `,'"',h.BYTE_ORDER_MARK],h.WORKERS_SUPPORTED=!_&&!!s.Worker,h.NODE_STREAM_INPUT=1,h.LocalChunkSize=10485760,h.RemoteChunkSize=5242880,h.DefaultDelimiter=",",h.Parser=ge,h.ParserHandle=ne,h.NetworkStreamer=j,h.FileStreamer=Q,h.StringStreamer=q,h.ReadableStreamStreamer=X,s.jQuery&&((m=s.jQuery).fn.parse=function(t){var r=t.config||{},i=[];return this.each(function(E){if(!(m(this).prop("tagName").toUpperCase()==="INPUT"&&m(this).attr("type").toLowerCase()==="file"&&s.FileReader)||!this.files||this.files.length===0)return!0;for(var v=0;v<this.files.length;v++)i.push({file:this.files[v],inputElem:this,instanceConfig:m.extend({},r)})}),u(),this;function u(){if(i.length===0)R(t.complete)&&t.complete();else{var E,v,f,d,o=i[0];if(R(t.before)){var c=t.before(o.file,o.inputElem);if(typeof c=="object"){if(c.action==="abort")return E="AbortError",v=o.file,f=o.inputElem,d=c.reason,void(R(t.error)&&t.error({name:E},v,f,d));if(c.action==="skip")return void y();typeof c.config=="object"&&(o.instanceConfig=m.extend(o.instanceConfig,c.config))}else if(c==="skip")return void y()}var l=o.instanceConfig.complete;o.instanceConfig.complete=function(w){R(l)&&l(w,o.file,o.inputElem),y()},h.parse(o.file,o.instanceConfig)}}function y(){i.splice(0,1),u()}}),U&&(s.onmessage=function(t){t=t.data,h.WORKER_ID===void 0&&t&&(h.WORKER_ID=t.workerId),typeof t.input=="string"?s.postMessage({workerId:h.WORKER_ID,results:h.parse(t.input,t.config),finished:!0}):(s.File&&t.input instanceof File||t.input instanceof Object)&&(t=h.parse(t.input,t.config))&&s.postMessage({workerId:h.WORKER_ID,results:t,finished:!0})}),(j.prototype=Object.create(F.prototype)).constructor=j,(Q.prototype=Object.create(F.prototype)).constructor=Q,(q.prototype=Object.create(q.prototype)).constructor=q,(X.prototype=Object.create(F.prototype)).constructor=X,h})})(Ee)),Ee.exports}var qe=We();const Ke=$e(qe),{parse:Je,unparse:Qe}=Ke;class Ve{static unparse(e,n){return Qe(e,n)}static parse(e){return new Promise((n,s)=>{Je(e,{header:!0,complete:m=>n(m),error:m=>s(m)})})}}class Ue{static revokeObjectUrlDelay=4e4;static utf8BomMimeType=/^\s*(?:text\/\S*|application\/xml|\S+\/\S+\+xml)\s*;\s*charset\s*=\s*utf-8/i;static saveAs(e,n,s={}){this.assertBrowserEnvironment();const m=s.autoBom?this.addUtf8Bom(e):e;this.downloadBlob(m,n)}static addUtf8Bom(e){return this.utf8BomMimeType.test(e.type)?new Blob(["\uFEFF",e],{type:e.type}):e}static assertBrowserEnvironment(){if(typeof window>"u"||typeof document>"u"||typeof URL>"u"||typeof URL.createObjectURL!="function"||typeof URL.revokeObjectURL!="function")throw new Error("DownloadHelper is only available in a browser environment with object URL support.")}static downloadBlob(e,n){const s=URL.createObjectURL(e);try{G.isIOS()?this.openBlobInNewTab(s)||this.clickDownloadLink(s,n,!1):this.clickDownloadLink(s,n)}finally{window.setTimeout(()=>URL.revokeObjectURL(s),this.revokeObjectUrlDelay)}}static openBlobInNewTab(e){const n=window.open("about:blank","_blank");if(!n)return!1;try{return n.opener=null,n.location.replace(e),!0}catch{return n.close(),!1}}static clickDownloadLink(e,n,s=!0){const m=document.body??document.documentElement;if(!m)throw new Error("DownloadHelper.saveAs requires an initialized document.");const _=document.createElement("a");try{_.download=n,_.href=e,s&&(_.target="_blank",_.rel="noopener noreferrer"),_.style.display="none",m.appendChild(_),_.click()}finally{_.remove()}}}class Ze{static getEnumValue(e,n){if(n in e)return e[n];throw Error(`${n} not found in ${e}`)}static getKeyValues(e){return Object.keys(e).filter(n=>!isNaN(Number(n))).map(n=>({key:Number(n),value:e[n]}))}}class He{static getFileExtension(e){let n="";const s=e.lastIndexOf(".");return s>0&&s<e.length-1&&(n=`.${e.substring(s+1).toLowerCase()}`),n}static readAsText(e){const n=new FileReader;return new Promise((s,m)=>{n.onload=()=>{n.onload=null,n.onerror=null,typeof n.result=="string"?s(n.result):m(new Error("Unexpected result type"))},n.onerror=()=>{const _=n.error??new Error("FileReader error");n.onload=null,n.onerror=null,m(_)},n.readAsText(e)})}static readAsArrayBuffer(e){const n=new FileReader;return new Promise((s,m)=>{n.onload=()=>{n.onload=null,n.onerror=null,n.result instanceof ArrayBuffer?s(n.result):m(new Error("Unexpected result type"))},n.onerror=()=>{const _=n.error??new Error("FileReader error");n.onload=null,n.onerror=null,m(_)},n.readAsArrayBuffer(e)})}static readAsDataUrl(e){const n=new FileReader;return new Promise((s,m)=>{n.onload=_=>{s(_)},n.onerror=_=>m(_),n.readAsDataURL(e)})}static formatFileSize(e,n=2,s){if(e===0)return"0 Bytes";const m=1024,_=["Bytes","KB","MB","GB","TB"];let U=Math.floor(Math.log(e)/Math.log(m));s&&_.includes(s)&&(U=_.indexOf(s));const A=e/Math.pow(m,U);return`${parseFloat(A.toFixed(n))} ${_[U]}`}static save(e,n,s){const m=new Blob([e],{type:s});Ue.saveAs(m,n)}}class Ge{static load(e){const n=URL.createObjectURL(e);return this.loadSource(n).finally(()=>URL.revokeObjectURL(n))}static async compress(e,n=.8,s="image/jpeg"){const m=await this.loadSource(e),{canvas:_}=this.resize(m,m.width,m.height);return _.toDataURL(s,n)}static resize(e,n,s){let{width:m,height:_}=e;const U=n/m,A=s/_,K=Math.min(U,A,1);m=Math.floor(m*K),_=Math.floor(_*K);const h=document.createElement("canvas");h.width=m,h.height=_;const F=h.getContext("2d");return F.clearRect(0,0,m,_),F.drawImage(e,0,0,m,_),{canvas:h,width:m,height:_}}static loadSource(e){return new Promise((n,s)=>{const m=new Image;m.onload=()=>n(m),m.onerror=s,m.src=e})}}class xe{static set(e,n){localStorage.setItem(e,JSON.stringify(n))}static get(e){let n=null;const s=localStorage.getItem(e);return s&&(n=JSON.parse(s)),n}static remove(e){const n=localStorage.getItem(e)!==null;return n&&localStorage.removeItem(e),n}static removeAll(){localStorage.clear()}static getKeysBy(e){return Object.keys(localStorage).filter(n=>n.startsWith(e))}}var me=(a=>(a.log="log",a.info="info",a.warn="warn",a.debug="debug",a.error="error",a))(me||{});class H{static listeners=new Set;static enabled=!0;static log(...e){H.doLog(me.log,e)}static info(...e){H.doLog(me.info,e)}static warn(...e){H.doLog(me.warn,e)}static debug(...e){H.doLog(me.debug,e)}static error(...e){H.doLog(me.error,e)}static clearListeners(){H.listeners.clear()}static setEnabled(e){H.enabled=e}static doLog(e,n){if(!H.enabled)return;const s={type:e,args:n,timestamp:new Date().toISOString()};for(const m of H.listeners)try{if(m(s)===!1)return}catch{}console[e].apply(console,n)}static onLog(e,n=!1){if(n){const s=m=>{try{return e(m)}finally{H.listeners.delete(s)}};return H.listeners.add(s),()=>H.listeners.delete(s)}return H.listeners.add(e),()=>H.listeners.delete(e)}}const Xe=(a,e,n)=>a.localeCompare(e)*(n?1:-1),et=(a,e)=>a<e?-1:a===e?0:1,tt=(a,e,n)=>et(a,e)*(n?1:-1),rt=(a,e,n)=>typeof a=="string"&&typeof e=="string"?Xe(a,e,n):tt(a,e,n),je=(a,e,n,s)=>{const m=n(a),_=n(e);return rt(m,_,s)};class nt{static get(e){return xe.get(e)}static set(e,n){xe.set(e,n)}static remove(e){xe.remove(e)}}class I{static listeners=new Set;static initialized=!1;static resizeTimeout=null;static lastWidth=null;static onResize(e){return I.initialized||I.init(),I.listeners.add(e),()=>I.off(e)}static handleResize=()=>{I.resizeTimeout!==null&&(window.clearTimeout(I.resizeTimeout),I.resizeTimeout=null),I.resizeTimeout=window.setTimeout(()=>{const e=window.innerWidth;if(I.resizeTimeout=null,e!==I.lastWidth){I.lastWidth=e;for(const n of I.listeners)n(e)}},150)};static init(){if(!I.initialized){if(typeof window>"u")throw new Error("WindowResizeHelper is only available in browser environments");I.lastWidth=window.innerWidth,window.addEventListener("resize",I.handleResize,{passive:!0}),I.initialized=!0}}static off(e){I.initialized&&(I.listeners.delete(e),I.listeners.size===0&&(I.resizeTimeout!==null&&(window.clearTimeout(I.resizeTimeout),I.resizeTimeout=null),window.removeEventListener("resize",I.handleResize),I.initialized=!1,I.lastWidth=null))}}function N(a,e,n){Object.defineProperty(a,e,{configurable:!0,enumerable:!1,value:n,writable:!0})}function it(){N(Array.prototype,"distinct",function(a){return a?this.filter((n,s,m)=>m.findIndex(_=>a(_,n))===s):this.filter((n,s,m)=>m.indexOf(n)===s)}),N(Array.prototype,"filterBy",function(a){return this.filter(e=>a(e))}),N(Array.prototype,"first",function(){return this.length>0?this[0]:null}),N(Array.prototype,"groupBy",function(a){return this.reduce((e,n)=>{const s=a(n);return e[s]||(e[s]=[]),e[s].push(n),e},{})}),N(Array.prototype,"orderBy",function(a,e=!0){return this?.sort((n,s)=>je(n,s,a,e)),this}),N(Array.prototype,"removeBy",function(a,e){return this.filter(n=>a(n)!==e)})}var De={exports:{}},st=De.exports,Ie;function at(){return Ie||(Ie=1,(function(a,e){(function(n,s){a.exports=s()})(st,(function(){var n=1e3,s=6e4,m=36e5,_="millisecond",U="second",A="minute",K="hour",h="day",F="week",j="month",Q="quarter",q="year",X="date",ne="Invalid Date",ue=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,ge=/\[([^\]]+)]|YYYY|YY|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,we={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(v){var f=["th","st","nd","rd"],d=v%100;return"["+v+(f[(d-20)%10]||f[d]||f[0])+"]"}},fe=function(v,f,d){var o=String(v);return!o||o.length>=f?v:""+Array(f+1-o.length).join(d)+v},Se={s:fe,z:function(v){var f=-v.utcOffset(),d=Math.abs(f),o=Math.floor(d/60),c=d%60;return(f<=0?"+":"-")+fe(o,2,"0")+":"+fe(c,2,"0")},m:function v(f,d){if(f.date()<d.date())return-v(d,f);var o=12*(d.year()-f.year())+(d.month()-f.month()),c=f.clone().add(o,j),l=d-c<0,w=f.clone().add(o+(l?-1:1),j);return+(-(o+(d-c)/(l?c-w:w-c))||0)},a:function(v){return v<0?Math.ceil(v)||0:Math.floor(v)},p:function(v){return{M:j,y:q,w:F,d:h,D:X,h:K,m:A,s:U,ms:_,Q}[v]||String(v||"").toLowerCase().replace(/s$/,"")},u:function(v){return v===void 0}},ce="en",V={};V[ce]=we;var R="$isDayjsObject",t=function(v){return v instanceof y||!(!v||!v[R])},r=function v(f,d,o){var c;if(!f)return ce;if(typeof f=="string"){var l=f.toLowerCase();V[l]&&(c=l),d&&(V[l]=d,c=l);var w=f.split("-");if(!c&&w.length>1)return v(w[0])}else{var g=f.name;V[g]=f,c=g}return!o&&c&&(ce=c),c||!o&&ce},i=function(v,f){if(t(v))return v.clone();var d=typeof f=="object"?f:{};return d.date=v,d.args=arguments,new y(d)},u=Se;u.l=r,u.i=t,u.w=function(v,f){return i(v,{locale:f.$L,utc:f.$u,x:f.$x,$offset:f.$offset})};var y=(function(){function v(d){this.$L=r(d.locale,null,!0),this.parse(d),this.$x=this.$x||d.x||{},this[R]=!0}var f=v.prototype;return f.parse=function(d){this.$d=(function(o){var c=o.date,l=o.utc;if(c===null)return new Date(NaN);if(u.u(c))return new Date;if(c instanceof Date)return new Date(c);if(typeof c=="string"&&!/Z$/i.test(c)){var w=c.match(ue);if(w){var g=w[2]-1||0,k=(w[7]||"0").substring(0,3);return l?new Date(Date.UTC(w[1],g,w[3]||1,w[4]||0,w[5]||0,w[6]||0,k)):new Date(w[1],g,w[3]||1,w[4]||0,w[5]||0,w[6]||0,k)}}return new Date(c)})(d),this.init()},f.init=function(){var d=this.$d;this.$y=d.getFullYear(),this.$M=d.getMonth(),this.$D=d.getDate(),this.$W=d.getDay(),this.$H=d.getHours(),this.$m=d.getMinutes(),this.$s=d.getSeconds(),this.$ms=d.getMilliseconds()},f.$utils=function(){return u},f.isValid=function(){return this.$d.toString()!==ne},f.isSame=function(d,o){var c=i(d);return this.startOf(o)<=c&&c<=this.endOf(o)},f.isAfter=function(d,o){return i(d)<this.startOf(o)},f.isBefore=function(d,o){return this.endOf(o)<i(d)},f.$g=function(d,o,c){return u.u(d)?this[o]:this.set(c,d)},f.unix=function(){return Math.floor(this.valueOf()/1e3)},f.valueOf=function(){return this.$d.getTime()},f.startOf=function(d,o){var c=this,l=!!u.u(o)||o,w=u.p(d),g=function(D,O){var b=u.w(c.$u?Date.UTC(c.$y,O,D):new Date(c.$y,O,D),c);return l?b:b.endOf(h)},k=function(D,O){return u.w(c.toDate()[D].apply(c.toDate("s"),(l?[0,0,0,0]:[23,59,59,999]).slice(O)),c)},p=this.$W,M=this.$M,C=this.$D,B="set"+(this.$u?"UTC":"");switch(w){case q:return l?g(1,0):g(31,11);case j:return l?g(1,M):g(0,M+1);case F:var W=this.$locale().weekStart||0,S=(p<W?p+7:p)-W;return g(l?C-S:C+(6-S),M);case h:case X:return k(B+"Hours",0);case K:return k(B+"Minutes",1);case A:return k(B+"Seconds",2);case U:return k(B+"Milliseconds",3);default:return this.clone()}},f.endOf=function(d){return this.startOf(d,!1)},f.$set=function(d,o){var c,l=u.p(d),w="set"+(this.$u?"UTC":""),g=(c={},c[h]=w+"Date",c[X]=w+"Date",c[j]=w+"Month",c[q]=w+"FullYear",c[K]=w+"Hours",c[A]=w+"Minutes",c[U]=w+"Seconds",c[_]=w+"Milliseconds",c)[l],k=l===h?this.$D+(o-this.$W):o;if(l===j||l===q){var p=this.clone().set(X,1);p.$d[g](k),p.init(),this.$d=p.set(X,Math.min(this.$D,p.daysInMonth())).$d}else g&&this.$d[g](k);return this.init(),this},f.set=function(d,o){return this.clone().$set(d,o)},f.get=function(d){return this[u.p(d)]()},f.add=function(d,o){var c,l=this;d=Number(d);var w=u.p(o),g=function(M){var C=i(l);return u.w(C.date(C.date()+Math.round(M*d)),l)};if(w===j)return this.set(j,this.$M+d);if(w===q)return this.set(q,this.$y+d);if(w===h)return g(1);if(w===F)return g(7);var k=(c={},c[A]=s,c[K]=m,c[U]=n,c)[w]||1,p=this.$d.getTime()+d*k;return u.w(p,this)},f.subtract=function(d,o){return this.add(-1*d,o)},f.format=function(d){var o=this,c=this.$locale();if(!this.isValid())return c.invalidDate||ne;var l=d||"YYYY-MM-DDTHH:mm:ssZ",w=u.z(this),g=this.$H,k=this.$m,p=this.$M,M=c.weekdays,C=c.months,B=c.meridiem,W=function(O,b,T,Y){return O&&(O[b]||O(o,l))||T[b].slice(0,Y)},S=function(O){return u.s(g%12||12,O,"0")},D=B||function(O,b,T){var Y=O<12?"AM":"PM";return T?Y.toLowerCase():Y};return l.replace(ge,(function(O,b){return b||(function(T){switch(T){case"YY":return String(o.$y).slice(-2);case"YYYY":return u.s(o.$y,4,"0");case"M":return p+1;case"MM":return u.s(p+1,2,"0");case"MMM":return W(c.monthsShort,p,C,3);case"MMMM":return W(C,p);case"D":return o.$D;case"DD":return u.s(o.$D,2,"0");case"d":return String(o.$W);case"dd":return W(c.weekdaysMin,o.$W,M,2);case"ddd":return W(c.weekdaysShort,o.$W,M,3);case"dddd":return M[o.$W];case"H":return String(g);case"HH":return u.s(g,2,"0");case"h":return S(1);case"hh":return S(2);case"a":return D(g,k,!0);case"A":return D(g,k,!1);case"m":return String(k);case"mm":return u.s(k,2,"0");case"s":return String(o.$s);case"ss":return u.s(o.$s,2,"0");case"SSS":return u.s(o.$ms,3,"0");case"Z":return w}return null})(O)||w.replace(":","")}))},f.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},f.diff=function(d,o,c){var l,w=this,g=u.p(o),k=i(d),p=(k.utcOffset()-this.utcOffset())*s,M=this-k,C=function(){return u.m(w,k)};switch(g){case q:l=C()/12;break;case j:l=C();break;case Q:l=C()/3;break;case F:l=(M-p)/6048e5;break;case h:l=(M-p)/864e5;break;case K:l=M/m;break;case A:l=M/s;break;case U:l=M/n;break;default:l=M}return c?l:u.a(l)},f.daysInMonth=function(){return this.endOf(j).$D},f.$locale=function(){return V[this.$L]},f.locale=function(d,o){if(!d)return this.$L;var c=this.clone(),l=r(d,o,!0);return l&&(c.$L=l),c},f.clone=function(){return u.w(this.$d,this)},f.toDate=function(){return new Date(this.valueOf())},f.toJSON=function(){return this.isValid()?this.toISOString():null},f.toISOString=function(){return this.$d.toISOString()},f.toString=function(){return this.$d.toUTCString()},v})(),E=y.prototype;return i.prototype=E,[["$ms",_],["$s",U],["$m",A],["$H",K],["$W",h],["$M",j],["$y",q],["$D",X]].forEach((function(v){E[v[1]]=function(f){return this.$g(f,v[0],v[1])}})),i.extend=function(v,f){return v.$i||(v(f,y,i),v.$i=!0),i},i.locale=r,i.isDayjs=t,i.unix=function(v){return i(1e3*v)},i.en=V[ce],i.Ls=V,i.p={},i}))})(De)),De.exports}var ot=at();const te=$e(ot);var Oe={exports:{}},ut=Oe.exports,Ae;function ct(){return Ae||(Ae=1,(function(a,e){(function(n,s){a.exports=s()})(ut,(function(){var n="day";return function(s,m,_){var U=function(h){return h.add(4-h.isoWeekday(),n)},A=m.prototype;A.isoWeekYear=function(){return U(this).year()},A.isoWeek=function(h){if(!this.$utils().u(h))return this.add(7*(h-this.isoWeek()),n);var F,j,Q,q,X=U(this),ne=(F=this.isoWeekYear(),j=this.$u,Q=(j?_.utc:_)().year(F).startOf("year"),q=4-Q.isoWeekday(),Q.isoWeekday()>4&&(q+=7),Q.add(q,n));return X.diff(ne,"week")+1},A.isoWeekday=function(h){return this.$utils().u(h)?this.day()||7:this.day(this.day()%7?h:h-7)};var K=A.startOf;A.startOf=function(h,F){var j=this.$utils(),Q=!!j.u(F)||F;return j.p(h)==="isoweek"?Q?this.date(this.date()-(this.isoWeekday()-1)).startOf("day"):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf("day"):K.bind(this)(h,F)}}}))})(Oe)),Oe.exports}var lt=ct();const dt=$e(lt);var Me={exports:{}},ft=Me.exports,Fe;function ht(){return Fe||(Fe=1,(function(a,e){(function(n,s){a.exports=s()})(ft,(function(){var n={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};return function(s,m,_){var U=m.prototype,A=U.format;_.en.formats=n,U.format=function(K){K===void 0&&(K="YYYY-MM-DDTHH:mm:ssZ");var h=this.$locale().formats,F=(function(j,Q){return j.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(q,X,ne){var ue=ne&&ne.toUpperCase();return X||Q[ne]||n[ne]||Q[ue].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(ge,we,fe){return we||fe.slice(1)}))}))})(K,h===void 0?{}:h);return A.call(this,F)}}}))})(Me)),Me.exports}var pt=ht();const mt=$e(pt);te.extend(mt);te.extend(dt);function gt(){N(Date.prototype,"add",function(a,e){return te(this).add(a,e).toDate()}),N(Date.prototype,"diff",function(a,e){return te(this).diff(a,e)}),N(Date.prototype,"endOf",function(a){return te(this).endOf(a).toDate()}),N(Date.prototype,"firstDayOfMonth",function(){return te(this).startOf("month").toDate()}),N(Date.prototype,"format",function(a){return te(this).format(a)}),N(Date.prototype,"isAfter",function(a,e){return te(this).isAfter(a,e)}),N(Date.prototype,"isBefore",function(a,e){return te(this).isBefore(a,e)}),N(Date.prototype,"isValid",function(){return te(this).isValid()}),N(Date.prototype,"isoWeek",function(){return te(this).isoWeek()}),N(Date.prototype,"subtract",function(a,e){return te(this).subtract(a,e).toDate()}),N(Date.prototype,"lastDayOfMonth",function(){return te(this).endOf("month").toDate()}),N(Date.prototype,"set",function(a,e){return te(this).set(a,e).toDate()}),N(Date.prototype,"startOf",function(a){return te(this).startOf(a).toDate()})}function yt(){N(String.prototype,"capitalize",function(){return this.charAt(0).toUpperCase()+this.slice(1)}),N(String.prototype,"isNumber",function(){return!isNaN(Number(this))&&this.trim()!==""}),N(String.prototype,"isEmpty",function(){return this===void 0||!this||this.length===0}),N(String.prototype,"stripTags",function(){return new DOMParser().parseFromString(this.toString(),"text/html").body.textContent||""})}class vt{resizeListener=null;onResizeCallbacks=new Set;emitTimeoutId=null;duplicateThresholdMs=60;constructor(){typeof window<"u"&&(this.resizeListener=this.onResize,window.addEventListener("resize",this.resizeListener,{passive:!0}))}destroy(){typeof window<"u"&&this.resizeListener!==null&&(window.removeEventListener("resize",this.resizeListener),this.resizeListener=null),this.emitTimeoutId!==null&&(clearTimeout(this.emitTimeoutId),this.emitTimeoutId=null),this.onResizeCallbacks.clear()}onResizeChange(e){this.onResizeCallbacks.add(e)}offResizeChange(e){this.onResizeCallbacks.delete(e)}onResize=()=>{if(typeof window>"u")return;const e=window.innerWidth;this.emitTimeoutId!==null&&clearTimeout(this.emitTimeoutId),this.emitTimeoutId=window.setTimeout(()=>{this.emitTimeoutId=null;const n=pe.getBreakpointByScreenWidth(e);for(const s of this.onResizeCallbacks)s(e,n)},this.duplicateThresholdMs)}}exports.BreakPointHelper=pe;exports.BreakPoints=ze;exports.BrowserHelper=G;exports.BrowserService=vt;exports.BrowserType=ee;exports.CanvasHelper=Ye;exports.CsvHelper=Ve;exports.DownloadHelper=Ue;exports.EnumHelper=Ze;exports.FileHelper=He;exports.ImageHelper=Ge;exports.LocalStorageHelper=xe;exports.LoggerHelper=H;exports.LoggerType=me;exports.ScreenHelper=be;exports.TokenHelper=nt;exports.WindowResizeHelper=I;exports.copyToClipboard=Pe;exports.initArrayExtensions=it;exports.initDateExtensions=gt;exports.initStringExtensions=yt;exports.sortHelper=je;