@oardi/ts-utils 0.0.54 → 0.0.55
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.
- package/index.cjs +3 -3
- package/index.mjs +223 -223
- package/index.umd.js +4 -4
- package/package.json +1 -1
package/index.umd.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
(function(z,mt){typeof exports=="object"&&typeof module<"u"?mt(exports):typeof define=="function"&&define.amd?define(["exports"],mt):(z=typeof globalThis<"u"?globalThis:z||self,mt(z["ts-utils"]={}))})(this,(function(z){"use strict";const mt={xs:0,sm:576,md:768,lg:992,xl:1200,xxl:1400,xxxl:1600};class _t{static getScreenWidth(){return document.documentElement.clientWidth}static getScreenHeight(){return document.documentElement.clientHeight}}class dt{static breakPoints=mt;static getCurrentBreakpoint(){return dt.getBreakpointByScreenWidth(_t.getScreenWidth())}static getBreakpointByScreenWidth(t=_t.getScreenWidth()){let n="xs";for(const a of Object.keys(dt.breakPoints))dt.breakPoints[a]<=t&&(n=a);return{breakpoint:n,screenWidth:t}}static isScreenGreaterThan(t){return _t.getScreenWidth()>dt.breakPoints[t]}static isScreenSmallerThan(t){return _t.getScreenWidth()<dt.breakPoints[t]}}var X=(s=>(s.opera="opera",s.firefox="firefox",s.safari="safari",s.ie="ie",s.edgeLegacy="edgeLegacy",s.edg="edg",s.chrome="chrome",s.iOS="iOS",s.headlessChrome="headlessChrome",s.nodeRuntime="nodeRuntime",s.electron="electron",s))(X||{});const ut=(typeof navigator<"u"?navigator.userAgent:"").toLowerCase();class H{static isBrowserEnv(){return typeof window<"u"&&typeof navigator<"u"}static isOpera(t=ut){return this.isBrowserEnv()?t.includes("opr/")||t.includes("opera"):!1}static isFirefox(t=ut){return this.isBrowserEnv()?t.includes("firefox")||typeof globalThis.InstallTrigger<"u":!1}static isSafari(t=ut){if(!this.isBrowserEnv())return!1;const n=navigator.vendor&&navigator.vendor.includes("Apple"),a=t.includes("safari"),_=!(t.includes("crios")||t.includes("chrome")||t.includes("android")||t.includes("opr/")||t.includes("edg"));return n&&a&&_}static isIOS(t=ut){if(!this.isBrowserEnv())return!1;const n=/iphone|ipad|ipod/.test(t),a=t.includes("macintosh")&&navigator.maxTouchPoints>1;return n||a}static isEdgeLegacy(){return this.isBrowserEnv()?!!window.StyleMedia&&!ut.includes("edg/"):!1}static isEdg(t=ut){return this.isBrowserEnv()?t.includes("edg/"):!1}static isIE(){return!this.isBrowserEnv()&&typeof document>"u"?!1:!!document.documentMode}static isChrome(t=ut){if(!this.isBrowserEnv())return!1;const n=navigator.vendor&&navigator.vendor.includes("Google"),a=t.includes("chrome")||t.includes("crios"),_=!this.isEdg(t)&&!this.isOpera(t);return n&&a&&_}static isElectron(t=ut){return typeof process<"u"&&process.versions?.electron?!0:t.includes("electron")}static isHeadlessChrome(t=ut){return t.includes("headlesschrome")}static isNodeRuntime(){return typeof process<"u"&&!!process.versions?.node&&!this.isBrowserEnv()}static getCurrentBrowser(){if(typeof navigator>"u"){if(H.isElectron())return X.electron;if(H.isNodeRuntime())return X.nodeRuntime;throw new Error("navigator not set")}const t=navigator.userAgent.toLowerCase();if(H.isOpera())return X.opera;if(H.isFirefox())return X.firefox;if(H.isSafari())return X.safari;if(H.isIE())return X.ie;if(H.isEdgeLegacy())return X.edgeLegacy;if(H.isEdg())return X.edg;if(H.isChrome())return X.chrome;if(H.isIOS(t))return X.iOS;if(H.isElectron(t))return X.electron;if(H.isHeadlessChrome(t))return X.headlessChrome;if(H.isNodeRuntime())return X.nodeRuntime;throw new Error("Browser could not be detected: "+t)}}function Ut(s){return navigator.clipboard.writeText(s)}function Ot(s){return s&&s.__esModule&&Object.prototype.hasOwnProperty.call(s,"default")?s.default:s}var xt={exports:{}};var Wt=xt.exports,Rt;function Bt(){return Rt||(Rt=1,(function(s,t){((n,a)=>{s.exports=a()})(Wt,function n(){var a=typeof self<"u"?self:typeof window<"u"?window:a!==void 0?a:{},_,D=!a.document&&!!a.postMessage,R=a.IS_PAPA_WORKER||!1,U={},K=0,p={};function W(e){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=ft(r);i.chunkSize=parseInt(i.chunkSize),r.step||r.chunk||(i.chunkSize=null),this._handle=new nt(i),(this._handle.streamer=this)._config=i}).call(this,e),this.parseChunk=function(r,i){var u=parseInt(this._config.skipFirstNLines)||0;if(this.isFirstChunk&&0<u){let S=this._config.newline;S||(m=this._config.quoteChar||'"',S=this._handle.guessLineEndings(r,m)),r=[...r.split(S).slice(u)].join(S)}this.isFirstChunk&&T(this._config.beforeFirstChunk)&&(m=this._config.beforeFirstChunk(r))!==void 0&&(r=m),this.isFirstChunk=!1,this._halted=!1;var u=this._partialLine+r,m=(this._partialLine="",this._handle.parse(u,this._baseIndex,!this._finished));if(!this._handle.paused()&&!this._handle.aborted()){if(r=m.meta.cursor,u=(this._finished||(this._partialLine=u.substring(r-this._baseIndex),this._baseIndex=r),m&&m.data&&(this._rowCount+=m.data.length),this._finished||this._config.preview&&this._rowCount>=this._config.preview),R)a.postMessage({results:m,workerId:p.WORKER_ID,finished:u});else if(T(this._config.chunk)&&!i){if(this._config.chunk(m,this._handle),this._handle.paused()||this._handle.aborted())return void(this._halted=!0);this._completeResults=m=void 0}return this._config.step||this._config.chunk||(this._completeResults.data=this._completeResults.data.concat(m.data),this._completeResults.errors=this._completeResults.errors.concat(m.errors),this._completeResults.meta=m.meta),this._completed||!u||!T(this._config.complete)||m&&m.meta.aborted||(this._config.complete(this._completeResults,this._input),this._completed=!0),u||m&&m.meta.paused||this._nextChunk(),m}this._halted=!0},this._sendError=function(r){T(this._config.error)?this._config.error(r):R&&this._config.error&&a.postMessage({workerId:p.WORKER_ID,error:r,finished:!1})}}function j(e){var r;(e=e||{}).chunkSize||(e.chunkSize=p.RemoteChunkSize),W.call(this,e),this._nextChunk=D?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),D||(r.onload=Z(this._chunkLoaded,this),r.onerror=Z(this._chunkError,this)),r.open(this._config.downloadRequestBody?"POST":"GET",this._input,!D),this._config.downloadRequestHeaders){var i,u=this._config.downloadRequestHeaders;for(i in u)r.setRequestHeader(i,u[i])}var m;this._config.chunkSize&&(m=this._start+this._config.chunkSize-1,r.setRequestHeader("Range","bytes="+this._start+"-"+m));try{r.send(this._config.downloadRequestBody)}catch(S){this._chunkError(S.message)}D&&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(e){(e=e||{}).chunkSize||(e.chunkSize=p.LocalChunkSize),W.call(this,e);var r,i,u=typeof FileReader<"u";this.stream=function(m){this._input=m,i=m.slice||m.webkitSlice||m.mozSlice,u?((r=new FileReader).onload=Z(this._chunkLoaded,this),r.onerror=Z(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 m=this._input,S=(this._config.chunkSize&&(S=Math.min(this._start+this._config.chunkSize,this._input.size),m=i.call(m,this._start,S)),r.readAsText(m,this._config.encoding));u||this._chunkLoaded({target:{result:S}})},this._chunkLoaded=function(m){this._start+=this._config.chunkSize,this._finished=!this._config.chunkSize||this._start>=this._input.size,this.parseChunk(m.target.result)},this._chunkError=function(){this._sendError(r.error)}}function q(e){var r;W.call(this,e=e||{}),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 et(e){W.call(this,e=e||{});var r=[],i=!0,u=!1;this.pause=function(){W.prototype.pause.apply(this,arguments),this._input.pause()},this.resume=function(){W.prototype.resume.apply(this,arguments),this._input.resume()},this.stream=function(m){this._input=m,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=Z(function(m){try{r.push(typeof m=="string"?m:m.toString(this._config.encoding)),i&&(i=!1,this._checkIsFinished(),this.parseChunk(r.shift()))}catch(S){this._streamError(S)}},this),this._streamError=Z(function(m){this._streamCleanUp(),this._sendError(m)},this),this._streamEnd=Z(function(){this._streamCleanUp(),u=!0,this._streamData("")},this),this._streamCleanUp=Z(function(){this._input.removeListener("data",this._streamData),this._input.removeListener("end",this._streamEnd),this._input.removeListener("error",this._streamError)},this)}function nt(e){var r,i,u,m,S=Math.pow(2,53),y=-S,d=/^\s*-?(\d+\.?|\.\d+|\d+\.\d+)([eE][-+]?\d+)?\s*$/,l=/^((\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,f=0,v=!1,g=!1,w=[],h={data:[],errors:[],meta:{}};function M(b){return e.skipEmptyLines==="greedy"?b.join("").trim()==="":b.length===1&&b[0].length===0}function C(){if(h&&u&&(N("Delimiter","UndetectableDelimiter","Unable to auto-detect delimiting character; defaulted to '"+p.DefaultDelimiter+"'"),u=!1),e.skipEmptyLines&&(h.data=h.data.filter(function(k){return!M(k)})),P()){let k=function(A,Y){T(e.transformHeader)&&(A=e.transformHeader(A,Y)),w.push(A)};if(h)if(Array.isArray(h.data[0])){for(var b=0;P()&&b<h.data.length;b++)h.data[b].forEach(k);h.data.splice(0,1)}else h.data.forEach(k)}function O(k,A){for(var Y=e.header?{}:[],L=0;L<k.length;L++){var F=L,$=k[L],$=((it,E)=>(B=>(e.dynamicTypingFunction&&e.dynamicTyping[B]===void 0&&(e.dynamicTyping[B]=e.dynamicTypingFunction(B)),(e.dynamicTyping[B]||e.dynamicTyping)===!0))(it)?E==="true"||E==="TRUE"||E!=="false"&&E!=="FALSE"&&((B=>{if(d.test(B)&&(B=parseFloat(B),y<B&&B<S))return 1})(E)?parseFloat(E):l.test(E)?new Date(E):E===""?null:E):E)(F=e.header?L>=w.length?"__parsed_extra":w[L]:F,$=e.transform?e.transform($,F):$);F==="__parsed_extra"?(Y[F]=Y[F]||[],Y[F].push($)):Y[F]=$}return e.header&&(L>w.length?N("FieldMismatch","TooManyFields","Too many fields: expected "+w.length+" fields but parsed "+L,f+A):L<w.length&&N("FieldMismatch","TooFewFields","Too few fields: expected "+w.length+" fields but parsed "+L,f+A)),Y}var x;h&&(e.header||e.dynamicTyping||e.transform)&&(x=1,!h.data.length||Array.isArray(h.data[0])?(h.data=h.data.map(O),x=h.data.length):h.data=O(h.data,0),e.header&&h.meta&&(h.meta.fields=w),f+=x)}function P(){return e.header&&w.length===0}function N(b,O,x,k){b={type:b,code:O,message:x},k!==void 0&&(b.row=k),h.errors.push(b)}T(e.step)&&(m=e.step,e.step=function(b){h=b,P()?C():(C(),h.data.length!==0&&(c+=b.data.length,e.preview&&c>e.preview?i.abort():(h.data=h.data[0],m(h,o))))}),this.parse=function(b,O,x){var k=e.quoteChar||'"',k=(e.newline||(e.newline=this.guessLineEndings(b,k)),u=!1,e.delimiter?T(e.delimiter)&&(e.delimiter=e.delimiter(b),h.meta.delimiter=e.delimiter):((k=((A,Y,L,F,$)=>{var it,E,B,pt;$=$||[","," ","|",";",p.RECORD_SEP,p.UNIT_SEP];for(var wt=0;wt<$.length;wt++){for(var st,St=$[wt],G=0,at=0,J=0,rt=(B=void 0,new vt({comments:F,delimiter:St,newline:Y,preview:10}).parse(A)),lt=0;lt<rt.data.length;lt++)L&&M(rt.data[lt])?J++:(st=rt.data[lt].length,at+=st,B===void 0?B=st:0<st&&(G+=Math.abs(st-B),B=st));0<rt.data.length&&(at/=rt.data.length-J),(E===void 0||G<=E)&&(pt===void 0||pt<at)&&1.99<at&&(E=G,it=St,pt=at)}return{successful:!!(e.delimiter=it),bestDelimiter:it}})(b,e.newline,e.skipEmptyLines,e.comments,e.delimitersToGuess)).successful?e.delimiter=k.bestDelimiter:(u=!0,e.delimiter=p.DefaultDelimiter),h.meta.delimiter=e.delimiter),ft(e));return e.preview&&e.header&&k.preview++,r=b,i=new vt(k),h=i.parse(r,O,x),C(),v?{meta:{paused:!0}}:h||{meta:{paused:!1}}},this.paused=function(){return v},this.pause=function(){v=!0,i.abort(),r=T(e.chunk)?"":r.substring(i.getCharIndex())},this.resume=function(){o.streamer._halted?(v=!1,o.streamer.parseChunk(r,!0)):setTimeout(o.resume,3)},this.aborted=function(){return g},this.abort=function(){g=!0,i.abort(),h.meta.aborted=!0,T(e.complete)&&e.complete(h),r=""},this.guessLineEndings=function(A,k){A=A.substring(0,1048576);var k=new RegExp(ct(k)+"([^]*?)"+ct(k),"gm"),x=(A=A.replace(k,"")).split("\r"),k=A.split(`
|
|
1
|
+
(function(z,mt){typeof exports=="object"&&typeof module<"u"?mt(exports):typeof define=="function"&&define.amd?define(["exports"],mt):(z=typeof globalThis<"u"?globalThis:z||self,mt(z["ts-utils"]={}))})(this,(function(z){"use strict";const mt={xs:0,sm:576,md:768,lg:992,xl:1200,xxl:1400,xxxl:1600};class kt{static getScreenWidth(){return document.documentElement.clientWidth}static getScreenHeight(){return document.documentElement.clientHeight}}class dt{static breakPoints=mt;static getCurrentBreakpoint(){return dt.getBreakpointByScreenWidth(kt.getScreenWidth())}static getBreakpointByScreenWidth(t=kt.getScreenWidth()){let n="xs";for(const a of Object.keys(dt.breakPoints))dt.breakPoints[a]<=t&&(n=a);return{breakpoint:n,screenWidth:t}}static isScreenGreaterThan(t){return kt.getScreenWidth()>dt.breakPoints[t]}static isScreenSmallerThan(t){return kt.getScreenWidth()<dt.breakPoints[t]}}var X=(s=>(s.opera="opera",s.firefox="firefox",s.safari="safari",s.ie="ie",s.edgeLegacy="edgeLegacy",s.edg="edg",s.chrome="chrome",s.iOS="iOS",s.headlessChrome="headlessChrome",s.nodeRuntime="nodeRuntime",s.electron="electron",s))(X||{});const ut=(typeof navigator<"u"?navigator.userAgent:"").toLowerCase();class H{static isBrowserEnv(){return typeof window<"u"&&typeof navigator<"u"}static isOpera(t=ut){return this.isBrowserEnv()?t.includes("opr/")||t.includes("opera"):!1}static isFirefox(t=ut){return this.isBrowserEnv()?t.includes("firefox")||typeof globalThis.InstallTrigger<"u":!1}static isSafari(t=ut){if(!this.isBrowserEnv())return!1;const n=navigator.vendor&&navigator.vendor.includes("Apple"),a=t.includes("safari"),_=!(t.includes("crios")||t.includes("chrome")||t.includes("android")||t.includes("opr/")||t.includes("edg"));return n&&a&&_}static isIOS(t=ut){if(!this.isBrowserEnv())return!1;const n=/iphone|ipad|ipod/.test(t),a=t.includes("macintosh")&&navigator.maxTouchPoints>1;return n||a}static isEdgeLegacy(){return this.isBrowserEnv()?!!window.StyleMedia&&!ut.includes("edg/"):!1}static isEdg(t=ut){return this.isBrowserEnv()?t.includes("edg/"):!1}static isIE(){return!this.isBrowserEnv()&&typeof document>"u"?!1:!!document.documentMode}static isChrome(t=ut){if(!this.isBrowserEnv())return!1;const n=navigator.vendor&&navigator.vendor.includes("Google"),a=t.includes("chrome")||t.includes("crios"),_=!this.isEdg(t)&&!this.isOpera(t);return n&&a&&_}static isElectron(t=ut){return typeof process<"u"&&process.versions?.electron?!0:t.includes("electron")}static isHeadlessChrome(t=ut){return t.includes("headlesschrome")}static isNodeRuntime(){return typeof process<"u"&&!!process.versions?.node&&!this.isBrowserEnv()}static getCurrentBrowser(){if(typeof navigator>"u"){if(H.isElectron())return X.electron;if(H.isNodeRuntime())return X.nodeRuntime;throw new Error("navigator not set")}const t=navigator.userAgent.toLowerCase();if(H.isOpera())return X.opera;if(H.isFirefox())return X.firefox;if(H.isSafari())return X.safari;if(H.isIE())return X.ie;if(H.isEdgeLegacy())return X.edgeLegacy;if(H.isEdg())return X.edg;if(H.isChrome())return X.chrome;if(H.isIOS(t))return X.iOS;if(H.isElectron(t))return X.electron;if(H.isHeadlessChrome(t))return X.headlessChrome;if(H.isNodeRuntime())return X.nodeRuntime;throw new Error("Browser could not be detected: "+t)}}function Ut(s){return navigator.clipboard.writeText(s)}function Et(s){return s&&s.__esModule&&Object.prototype.hasOwnProperty.call(s,"default")?s.default:s}var Ot={exports:{}};var Wt=Ot.exports,Rt;function Bt(){return Rt||(Rt=1,(function(s,t){((n,a)=>{s.exports=a()})(Wt,function n(){var a=typeof self<"u"?self:typeof window<"u"?window:a!==void 0?a:{},_,D=!a.document&&!!a.postMessage,R=a.IS_PAPA_WORKER||!1,U={},K=0,p={};function W(e){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=ft(r);i.chunkSize=parseInt(i.chunkSize),r.step||r.chunk||(i.chunkSize=null),this._handle=new nt(i),(this._handle.streamer=this)._config=i}).call(this,e),this.parseChunk=function(r,i){var u=parseInt(this._config.skipFirstNLines)||0;if(this.isFirstChunk&&0<u){let S=this._config.newline;S||(m=this._config.quoteChar||'"',S=this._handle.guessLineEndings(r,m)),r=[...r.split(S).slice(u)].join(S)}this.isFirstChunk&&T(this._config.beforeFirstChunk)&&(m=this._config.beforeFirstChunk(r))!==void 0&&(r=m),this.isFirstChunk=!1,this._halted=!1;var u=this._partialLine+r,m=(this._partialLine="",this._handle.parse(u,this._baseIndex,!this._finished));if(!this._handle.paused()&&!this._handle.aborted()){if(r=m.meta.cursor,u=(this._finished||(this._partialLine=u.substring(r-this._baseIndex),this._baseIndex=r),m&&m.data&&(this._rowCount+=m.data.length),this._finished||this._config.preview&&this._rowCount>=this._config.preview),R)a.postMessage({results:m,workerId:p.WORKER_ID,finished:u});else if(T(this._config.chunk)&&!i){if(this._config.chunk(m,this._handle),this._handle.paused()||this._handle.aborted())return void(this._halted=!0);this._completeResults=m=void 0}return this._config.step||this._config.chunk||(this._completeResults.data=this._completeResults.data.concat(m.data),this._completeResults.errors=this._completeResults.errors.concat(m.errors),this._completeResults.meta=m.meta),this._completed||!u||!T(this._config.complete)||m&&m.meta.aborted||(this._config.complete(this._completeResults,this._input),this._completed=!0),u||m&&m.meta.paused||this._nextChunk(),m}this._halted=!0},this._sendError=function(r){T(this._config.error)?this._config.error(r):R&&this._config.error&&a.postMessage({workerId:p.WORKER_ID,error:r,finished:!1})}}function j(e){var r;(e=e||{}).chunkSize||(e.chunkSize=p.RemoteChunkSize),W.call(this,e),this._nextChunk=D?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),D||(r.onload=Z(this._chunkLoaded,this),r.onerror=Z(this._chunkError,this)),r.open(this._config.downloadRequestBody?"POST":"GET",this._input,!D),this._config.downloadRequestHeaders){var i,u=this._config.downloadRequestHeaders;for(i in u)r.setRequestHeader(i,u[i])}var m;this._config.chunkSize&&(m=this._start+this._config.chunkSize-1,r.setRequestHeader("Range","bytes="+this._start+"-"+m));try{r.send(this._config.downloadRequestBody)}catch(S){this._chunkError(S.message)}D&&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(e){(e=e||{}).chunkSize||(e.chunkSize=p.LocalChunkSize),W.call(this,e);var r,i,u=typeof FileReader<"u";this.stream=function(m){this._input=m,i=m.slice||m.webkitSlice||m.mozSlice,u?((r=new FileReader).onload=Z(this._chunkLoaded,this),r.onerror=Z(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 m=this._input,S=(this._config.chunkSize&&(S=Math.min(this._start+this._config.chunkSize,this._input.size),m=i.call(m,this._start,S)),r.readAsText(m,this._config.encoding));u||this._chunkLoaded({target:{result:S}})},this._chunkLoaded=function(m){this._start+=this._config.chunkSize,this._finished=!this._config.chunkSize||this._start>=this._input.size,this.parseChunk(m.target.result)},this._chunkError=function(){this._sendError(r.error)}}function q(e){var r;W.call(this,e=e||{}),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 et(e){W.call(this,e=e||{});var r=[],i=!0,u=!1;this.pause=function(){W.prototype.pause.apply(this,arguments),this._input.pause()},this.resume=function(){W.prototype.resume.apply(this,arguments),this._input.resume()},this.stream=function(m){this._input=m,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=Z(function(m){try{r.push(typeof m=="string"?m:m.toString(this._config.encoding)),i&&(i=!1,this._checkIsFinished(),this.parseChunk(r.shift()))}catch(S){this._streamError(S)}},this),this._streamError=Z(function(m){this._streamCleanUp(),this._sendError(m)},this),this._streamEnd=Z(function(){this._streamCleanUp(),u=!0,this._streamData("")},this),this._streamCleanUp=Z(function(){this._input.removeListener("data",this._streamData),this._input.removeListener("end",this._streamEnd),this._input.removeListener("error",this._streamError)},this)}function nt(e){var r,i,u,m,S=Math.pow(2,53),y=-S,d=/^\s*-?(\d+\.?|\.\d+|\d+\.\d+)([eE][-+]?\d+)?\s*$/,l=/^((\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,f=0,v=!1,g=!1,w=[],h={data:[],errors:[],meta:{}};function M(b){return e.skipEmptyLines==="greedy"?b.join("").trim()==="":b.length===1&&b[0].length===0}function C(){if(h&&u&&(N("Delimiter","UndetectableDelimiter","Unable to auto-detect delimiting character; defaulted to '"+p.DefaultDelimiter+"'"),u=!1),e.skipEmptyLines&&(h.data=h.data.filter(function(k){return!M(k)})),P()){let k=function(A,Y){T(e.transformHeader)&&(A=e.transformHeader(A,Y)),w.push(A)};if(h)if(Array.isArray(h.data[0])){for(var b=0;P()&&b<h.data.length;b++)h.data[b].forEach(k);h.data.splice(0,1)}else h.data.forEach(k)}function O(k,A){for(var Y=e.header?{}:[],L=0;L<k.length;L++){var F=L,$=k[L],$=((it,E)=>(B=>(e.dynamicTypingFunction&&e.dynamicTyping[B]===void 0&&(e.dynamicTyping[B]=e.dynamicTypingFunction(B)),(e.dynamicTyping[B]||e.dynamicTyping)===!0))(it)?E==="true"||E==="TRUE"||E!=="false"&&E!=="FALSE"&&((B=>{if(d.test(B)&&(B=parseFloat(B),y<B&&B<S))return 1})(E)?parseFloat(E):l.test(E)?new Date(E):E===""?null:E):E)(F=e.header?L>=w.length?"__parsed_extra":w[L]:F,$=e.transform?e.transform($,F):$);F==="__parsed_extra"?(Y[F]=Y[F]||[],Y[F].push($)):Y[F]=$}return e.header&&(L>w.length?N("FieldMismatch","TooManyFields","Too many fields: expected "+w.length+" fields but parsed "+L,f+A):L<w.length&&N("FieldMismatch","TooFewFields","Too few fields: expected "+w.length+" fields but parsed "+L,f+A)),Y}var x;h&&(e.header||e.dynamicTyping||e.transform)&&(x=1,!h.data.length||Array.isArray(h.data[0])?(h.data=h.data.map(O),x=h.data.length):h.data=O(h.data,0),e.header&&h.meta&&(h.meta.fields=w),f+=x)}function P(){return e.header&&w.length===0}function N(b,O,x,k){b={type:b,code:O,message:x},k!==void 0&&(b.row=k),h.errors.push(b)}T(e.step)&&(m=e.step,e.step=function(b){h=b,P()?C():(C(),h.data.length!==0&&(c+=b.data.length,e.preview&&c>e.preview?i.abort():(h.data=h.data[0],m(h,o))))}),this.parse=function(b,O,x){var k=e.quoteChar||'"',k=(e.newline||(e.newline=this.guessLineEndings(b,k)),u=!1,e.delimiter?T(e.delimiter)&&(e.delimiter=e.delimiter(b),h.meta.delimiter=e.delimiter):((k=((A,Y,L,F,$)=>{var it,E,B,pt;$=$||[","," ","|",";",p.RECORD_SEP,p.UNIT_SEP];for(var vt=0;vt<$.length;vt++){for(var st,bt=$[vt],G=0,at=0,J=0,rt=(B=void 0,new yt({comments:F,delimiter:bt,newline:Y,preview:10}).parse(A)),lt=0;lt<rt.data.length;lt++)L&&M(rt.data[lt])?J++:(st=rt.data[lt].length,at+=st,B===void 0?B=st:0<st&&(G+=Math.abs(st-B),B=st));0<rt.data.length&&(at/=rt.data.length-J),(E===void 0||G<=E)&&(pt===void 0||pt<at)&&1.99<at&&(E=G,it=bt,pt=at)}return{successful:!!(e.delimiter=it),bestDelimiter:it}})(b,e.newline,e.skipEmptyLines,e.comments,e.delimitersToGuess)).successful?e.delimiter=k.bestDelimiter:(u=!0,e.delimiter=p.DefaultDelimiter),h.meta.delimiter=e.delimiter),ft(e));return e.preview&&e.header&&k.preview++,r=b,i=new yt(k),h=i.parse(r,O,x),C(),v?{meta:{paused:!0}}:h||{meta:{paused:!1}}},this.paused=function(){return v},this.pause=function(){v=!0,i.abort(),r=T(e.chunk)?"":r.substring(i.getCharIndex())},this.resume=function(){o.streamer._halted?(v=!1,o.streamer.parseChunk(r,!0)):setTimeout(o.resume,3)},this.aborted=function(){return g},this.abort=function(){g=!0,i.abort(),h.meta.aborted=!0,T(e.complete)&&e.complete(h),r=""},this.guessLineEndings=function(A,k){A=A.substring(0,1048576);var k=new RegExp(ct(k)+"([^]*?)"+ct(k),"gm"),x=(A=A.replace(k,"")).split("\r"),k=A.split(`
|
|
2
2
|
`),A=1<k.length&&k[0].length<x[0].length;if(x.length===1||A)return`
|
|
3
3
|
`;for(var Y=0,L=0;L<x.length;L++)x[L][0]===`
|
|
4
4
|
`&&Y++;return Y>=x.length/2?`\r
|
|
5
|
-
`:"\r"}}function ct(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function
|
|
5
|
+
`:"\r"}}function ct(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function yt(e){var r=(e=e||{}).delimiter,i=e.newline,u=e.comments,m=e.step,S=e.preview,y=e.fastMode,d=null,l=!1,o=e.quoteChar==null?'"':e.quoteChar,c=o;if(e.escapeChar!==void 0&&(c=e.escapeChar),(typeof r!="string"||-1<p.BAD_DELIMITERS.indexOf(r))&&(r=","),u===r)throw new Error("Comment character same as delimiter");u===!0?u="#":(typeof u!="string"||-1<p.BAD_DELIMITERS.indexOf(u))&&(u=!1),i!==`
|
|
6
6
|
`&&i!=="\r"&&i!==`\r
|
|
7
7
|
`&&(i=`
|
|
8
|
-
`);var f=0,v=!1;this.parse=function(g,w,h){if(typeof g!="string")throw new Error("Input must be a string");var M=g.length,C=r.length,P=i.length,N=u.length,b=T(m),O=[],x=[],k=[],A=f=0;if(!g)return G();if(y||y!==!1&&g.indexOf(o)===-1){for(var Y=g.split(i),L=0;L<Y.length;L++){if(k=Y[L],f+=k.length,L!==Y.length-1)f+=i.length;else if(h)return G();if(!u||k.substring(0,N)!==u){if(b){if(O=[],pt(k.split(r)),at(),v)return G()}else pt(k.split(r));if(S&&S<=L)return O=O.slice(0,S),G(!0)}}return G()}for(var F=g.indexOf(r,f),$=g.indexOf(i,f),it=new RegExp(ct(c)+ct(o),"g"),E=g.indexOf(o,f);;)if(g[f]===o)for(E=f,f++;;){if((E=g.indexOf(o,E+1))===-1)return h||x.push({type:"Quotes",code:"MissingQuotes",message:"Quoted field unterminated",row:O.length,index:f}),st();if(E===M-1)return st(g.substring(f,E).replace(it,o));if(o===c&&g[E+1]===c)E++;else if(o===c||E===0||g[E-1]!==c){F!==-1&&F<E+1&&(F=g.indexOf(r,E+1));var B=
|
|
8
|
+
`);var f=0,v=!1;this.parse=function(g,w,h){if(typeof g!="string")throw new Error("Input must be a string");var M=g.length,C=r.length,P=i.length,N=u.length,b=T(m),O=[],x=[],k=[],A=f=0;if(!g)return G();if(y||y!==!1&&g.indexOf(o)===-1){for(var Y=g.split(i),L=0;L<Y.length;L++){if(k=Y[L],f+=k.length,L!==Y.length-1)f+=i.length;else if(h)return G();if(!u||k.substring(0,N)!==u){if(b){if(O=[],pt(k.split(r)),at(),v)return G()}else pt(k.split(r));if(S&&S<=L)return O=O.slice(0,S),G(!0)}}return G()}for(var F=g.indexOf(r,f),$=g.indexOf(i,f),it=new RegExp(ct(c)+ct(o),"g"),E=g.indexOf(o,f);;)if(g[f]===o)for(E=f,f++;;){if((E=g.indexOf(o,E+1))===-1)return h||x.push({type:"Quotes",code:"MissingQuotes",message:"Quoted field unterminated",row:O.length,index:f}),st();if(E===M-1)return st(g.substring(f,E).replace(it,o));if(o===c&&g[E+1]===c)E++;else if(o===c||E===0||g[E-1]!==c){F!==-1&&F<E+1&&(F=g.indexOf(r,E+1));var B=vt(($=$!==-1&&$<E+1?g.indexOf(i,E+1):$)===-1?F:Math.min(F,$));if(g.substr(E+1+B,C)===r){k.push(g.substring(f,E).replace(it,o)),g[f=E+1+B+C]!==o&&(E=g.indexOf(o,f)),F=g.indexOf(r,f),$=g.indexOf(i,f);break}if(B=vt($),g.substring(E+1+B,E+1+B+P)===i){if(k.push(g.substring(f,E).replace(it,o)),bt(E+1+B+P),F=g.indexOf(r,f),E=g.indexOf(o,f),b&&(at(),v))return G();if(S&&O.length>=S)return G(!0);break}x.push({type:"Quotes",code:"InvalidQuotes",message:"Trailing quote on quoted field is malformed",row:O.length,index:f}),E++}}else if(u&&k.length===0&&g.substring(f,f+N)===u){if($===-1)return G();f=$+P,$=g.indexOf(i,f),F=g.indexOf(r,f)}else if(F!==-1&&(F<$||$===-1))k.push(g.substring(f,F)),f=F+C,F=g.indexOf(r,f);else{if($===-1)break;if(k.push(g.substring(f,$)),bt($+P),b&&(at(),v))return G();if(S&&O.length>=S)return G(!0)}return st();function pt(J){O.push(J),A=f}function vt(J){var rt=0;return rt=J!==-1&&(J=g.substring(E+1,J))&&J.trim()===""?J.length:rt}function st(J){return h||(J===void 0&&(J=g.substring(f)),k.push(J),f=M,pt(k),b&&at()),G()}function bt(J){f=J,pt(k),k=[],$=g.indexOf(i,f)}function G(J){if(e.header&&!w&&O.length&&!l){var rt=O[0],lt=Object.create(null),Tt=new Set(rt);let Pt=!1;for(let wt=0;wt<rt.length;wt++){let ot=rt[wt];if(lt[ot=T(e.transformHeader)?e.transformHeader(ot,wt):ot]){let St,Yt=lt[ot];for(;St=ot+"_"+Yt,Yt++,Tt.has(St););Tt.add(St),rt[wt]=St,lt[ot]++,Pt=!0,(d=d===null?{}:d)[St]=ot}else lt[ot]=1,rt[wt]=ot;Tt.add(ot)}Pt&&console.warn("Duplicate headers found and renamed."),l=!0}return{data:O,errors:x,meta:{delimiter:r,linebreak:i,aborted:v,truncated:!!J,cursor:A+(w||0),renamedHeaders:d}}}function at(){m(G()),O=[],x=[]}},this.abort=function(){v=!0},this.getCharIndex=function(){return f}}function _t(e){var r=e.data,i=U[r.workerId],u=!1;if(r.error)i.userError(r.error,r.file);else if(r.results&&r.results.data){var m={abort:function(){u=!0,ht(r.workerId,{data:[],errors:[],meta:{aborted:!0}})},pause:Ct,resume:Ct};if(T(i.userStep)){for(var S=0;S<r.results.data.length&&(i.userStep({data:r.results.data[S],errors:r.results.errors,meta:r.results.meta},m),!u);S++);delete r.results}else T(i.userChunk)&&(i.userChunk(r.results,m,r.file),delete r.results)}r.finished&&!u&&ht(r.workerId,r.results)}function ht(e,r){var i=U[e];T(i.userComplete)&&i.userComplete(r),i.terminate(),delete U[e]}function Ct(){throw new Error("Not implemented.")}function ft(e){if(typeof e!="object"||e===null)return e;var r,i=Array.isArray(e)?[]:{};for(r in e)i[r]=ft(e[r]);return i}function Z(e,r){return function(){e.apply(r,arguments)}}function T(e){return typeof e=="function"}return p.parse=function(e,r){var i=(r=r||{}).dynamicTyping||!1;if(T(i)&&(r.dynamicTypingFunction=i,i={}),r.dynamicTyping=i,r.transform=!!T(r.transform)&&r.transform,!r.worker||!p.WORKERS_SUPPORTED)return i=null,p.NODE_STREAM_INPUT,typeof e=="string"?(e=(u=>u.charCodeAt(0)!==65279?u:u.slice(1))(e),i=new(r.download?j:q)(r)):e.readable===!0&&T(e.read)&&T(e.on)?i=new et(r):(a.File&&e instanceof File||e instanceof Object)&&(i=new Q(r)),i.stream(e);(i=(()=>{var u;return!!p.WORKERS_SUPPORTED&&(u=(()=>{var m=a.URL||a.webkitURL||null,S=n.toString();return p.BLOB_URL||(p.BLOB_URL=m.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; ","(",S,")();"],{type:"text/javascript"})))})(),(u=new a.Worker(u)).onmessage=_t,u.id=K++,U[u.id]=u)})()).userStep=r.step,i.userChunk=r.chunk,i.userComplete=r.complete,i.userError=r.error,r.step=T(r.step),r.chunk=T(r.chunk),r.complete=T(r.complete),r.error=T(r.error),delete r.worker,i.postMessage({input:e,config:r,workerId:i.id})},p.unparse=function(e,r){var i=!1,u=!0,m=",",S=`\r
|
|
9
9
|
`,y='"',d=y+y,l=!1,o=null,c=!1,f=((()=>{if(typeof r=="object"){if(typeof r.delimiter!="string"||p.BAD_DELIMITERS.filter(function(w){return r.delimiter.indexOf(w)!==-1}).length||(m=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"||(l=r.skipEmptyLines),typeof r.newline=="string"&&(S=r.newline),typeof r.quoteChar=="string"&&(y=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&&(d=r.escapeChar+y),r.escapeFormulae instanceof RegExp?c=r.escapeFormulae:typeof r.escapeFormulae=="boolean"&&r.escapeFormulae&&(c=/^[=+\-@\t\r].*$/)}})(),new RegExp(ct(y),"g"));if(typeof e=="string"&&(e=JSON.parse(e)),Array.isArray(e)){if(!e.length||Array.isArray(e[0]))return v(null,e,l);if(typeof e[0]=="object")return v(o||Object.keys(e[0]),e,l)}else if(typeof e=="object")return typeof e.data=="string"&&(e.data=JSON.parse(e.data)),Array.isArray(e.data)&&(e.fields||(e.fields=e.meta&&e.meta.fields||o),e.fields||(e.fields=Array.isArray(e.data[0])?e.fields:typeof e.data[0]=="object"?Object.keys(e.data[0]):[]),Array.isArray(e.data[0])||typeof e.data[0]=="object"||(e.data=[e.data])),v(e.fields||[],e.data||[],l);throw new Error("Unable to serialize unrecognized input");function v(w,h,M){var C="",P=(typeof w=="string"&&(w=JSON.parse(w)),typeof h=="string"&&(h=JSON.parse(h)),Array.isArray(w)&&0<w.length),N=!Array.isArray(h[0]);if(P&&u){for(var b=0;b<w.length;b++)0<b&&(C+=m),C+=g(w[b],b);0<h.length&&(C+=S)}for(var O=0;O<h.length;O++){var x=(P?w:h[O]).length,k=!1,A=P?Object.keys(h[O]).length===0:h[O].length===0;if(M&&!P&&(k=M==="greedy"?h[O].join("").trim()==="":h[O].length===1&&h[O][0].length===0),M==="greedy"&&P){for(var Y=[],L=0;L<x;L++){var F=N?w[L]:L;Y.push(h[O][F])}k=Y.join("").trim()===""}if(!k){for(var $=0;$<x;$++){0<$&&!A&&(C+=m);var it=P&&N?w[$]:$;C+=g(h[O][it],$)}O<h.length-1&&(!M||0<x&&!A)&&(C+=S)}}return C}function g(w,h){var M,C;return w==null?"":w.constructor===Date?JSON.stringify(w).slice(1,25):(C=!1,c&&typeof w=="string"&&c.test(w)&&(w="'"+w,C=!0),M=w.toString().replace(f,d),(C=C||i===!0||typeof i=="function"&&i(w,h)||Array.isArray(i)&&i[h]||((P,N)=>{for(var b=0;b<N.length;b++)if(-1<P.indexOf(N[b]))return!0;return!1})(M,p.BAD_DELIMITERS)||-1<M.indexOf(m)||M.charAt(0)===" "||M.charAt(M.length-1)===" ")?y+M+y:M)}},p.RECORD_SEP="",p.UNIT_SEP="",p.BYTE_ORDER_MARK="\uFEFF",p.BAD_DELIMITERS=["\r",`
|
|
10
|
-
`,'"',p.BYTE_ORDER_MARK],p.WORKERS_SUPPORTED=!D&&!!a.Worker,p.NODE_STREAM_INPUT=1,p.LocalChunkSize=10485760,p.RemoteChunkSize=5242880,p.DefaultDelimiter=",",p.Parser=vt,p.ParserHandle=nt,p.NetworkStreamer=j,p.FileStreamer=Q,p.StringStreamer=q,p.ReadableStreamStreamer=et,a.jQuery&&((_=a.jQuery).fn.parse=function(e){var r=e.config||{},i=[];return this.each(function(S){if(!(_(this).prop("tagName").toUpperCase()==="INPUT"&&_(this).attr("type").toLowerCase()==="file"&&a.FileReader)||!this.files||this.files.length===0)return!0;for(var y=0;y<this.files.length;y++)i.push({file:this.files[y],inputElem:this,instanceConfig:_.extend({},r)})}),u(),this;function u(){if(i.length===0)T(e.complete)&&e.complete();else{var S,y,d,l,o=i[0];if(T(e.before)){var c=e.before(o.file,o.inputElem);if(typeof c=="object"){if(c.action==="abort")return S="AbortError",y=o.file,d=o.inputElem,l=c.reason,void(T(e.error)&&e.error({name:S},y,d,l));if(c.action==="skip")return void m();typeof c.config=="object"&&(o.instanceConfig=_.extend(o.instanceConfig,c.config))}else if(c==="skip")return void m()}var f=o.instanceConfig.complete;o.instanceConfig.complete=function(v){T(f)&&f(v,o.file,o.inputElem),m()},p.parse(o.file,o.instanceConfig)}}function m(){i.splice(0,1),u()}}),R&&(a.onmessage=function(e){e=e.data,p.WORKER_ID===void 0&&e&&(p.WORKER_ID=e.workerId),typeof e.input=="string"?a.postMessage({workerId:p.WORKER_ID,results:p.parse(e.input,e.config),finished:!0}):(a.File&&e.input instanceof File||e.input instanceof Object)&&(e=p.parse(e.input,e.config))&&a.postMessage({workerId:p.WORKER_ID,results:e,finished:!0})}),(j.prototype=Object.create(W.prototype)).constructor=j,(Q.prototype=Object.create(W.prototype)).constructor=Q,(q.prototype=Object.create(q.prototype)).constructor=q,(et.prototype=Object.create(W.prototype)).constructor=et,p})})(xt)),xt.exports}var Nt=Bt();const qt=Ot(Nt),{parse:Kt,unparse:Jt}=qt;class Qt{static unparse(t,n){return Jt(t,n)}static parse(t){return new Promise((n,a)=>{Kt(t,{header:!0,complete:_=>n(_),error:_=>a(_)})})}}async function At(s,t,n){const a=n?.mimeType??Zt(t),_=Vt(s,a);if("showSaveFilePicker"in window&&n?.showSaveFilePicker)try{const K=await(await window.showSaveFilePicker({suggestedName:t,types:[{description:"Datei",accept:{[a]:[`.${It(t)}`]}}]})).createWritable();await K.write(_),await K.close();return}catch{}const D=URL.createObjectURL(_),R=document.createElement("a");R.href=D,R.download=t,R.rel="noopener",R.style.display="none",document.body.appendChild(R),Gt(R),window.setTimeout(()=>{document.body.removeChild(R),URL.revokeObjectURL(D)},0),Xt()&&window.open(D,"_blank","noopener,noreferrer")}function Vt(s,t){if(s instanceof Blob)return s.type?s:new Blob([s],{type:t});if(s instanceof ArrayBuffer||s instanceof Uint8Array){const n=s instanceof Uint8Array?s:new Uint8Array(s);return new Blob([n],{type:t})}return new Blob([s],{type:t||"text/plain;charset=utf-8"})}function Zt(s){switch(It(s).toLowerCase()){case"txt":return"text/plain;charset=utf-8";case"csv":return"text/csv;charset=utf-8";case"json":return"application/json;charset=utf-8";case"pdf":return"application/pdf";case"png":return"image/png";case"jpg":case"jpeg":return"image/jpeg";case"svg":return"image/svg+xml";case"zip":return"application/zip";default:return"application/octet-stream"}}function It(s){const t=s.lastIndexOf(".");return t>=0&&t<s.length-1?s.slice(t+1):""}function Gt(s){const t=document.createEvent("MouseEvents");t.initMouseEvent("click",!0,!0,window,0,0,0,0,0,!1,!1,!1,!1,0,null),s.dispatchEvent(t)}function Xt(){const s=navigator.userAgent,t=/iPad|iPhone|iPod/.test(s),n=/^((?!chrome|android).)*safari/i.test(s);return t||n}class Ht{static getEnumValue(t,n){if(n in t)return t[n];throw Error(`${n} not found in ${t}`)}static getKeyValues(t){return Object.keys(t).filter(n=>!isNaN(Number(n))).map(n=>({key:Number(n),value:t[n]}))}}class te{static getFileExtension(t){let n="";const a=t.lastIndexOf(".");return a>0&&a<t.length-1&&(n=`.${t.substring(a+1).toLowerCase()}`),n}static readAsText(t){const n=new FileReader;return new Promise((a,_)=>{n.onload=()=>{n.onload=null,n.onerror=null,typeof n.result=="string"?a(n.result):_(new Error("Unexpected result type"))},n.onerror=()=>{const D=n.error??new Error("FileReader error");n.onload=null,n.onerror=null,_(D)},n.readAsText(t)})}static readAsArrayBuffer(t){const n=new FileReader;return new Promise((a,_)=>{n.onload=()=>{n.onload=null,n.onerror=null,n.result instanceof ArrayBuffer?a(n.result):_(new Error("Unexpected result type"))},n.onerror=()=>{const D=n.error??new Error("FileReader error");n.onload=null,n.onerror=null,_(D)},n.readAsArrayBuffer(t)})}static readAsDataUrl(t){const n=new FileReader;return new Promise((a,_)=>{n.onload=D=>{a(D)},n.onerror=D=>_(D),n.readAsDataURL(t)})}static formatFileSize(t,n=2,a){if(t===0)return"0 Bytes";const _=1024,D=["Bytes","KB","MB","GB","TB"];let R=Math.floor(Math.log(t)/Math.log(_));a&&D.includes(a)&&(R=D.indexOf(a));const U=t/Math.pow(_,R);return`${parseFloat(U.toFixed(n))} ${D[R]}`}static save(t,n,a){const _=new Blob([t],{type:a});At(_,n)}}class yt{static set(t,n){localStorage.setItem(t,JSON.stringify(n))}static get(t){let n=null;const a=localStorage.getItem(t);return a&&(n=JSON.parse(a)),n}static remove(t){let n=!!yt.get(t);return n&&localStorage.removeItem(t),n}static removeAll(){localStorage.clear()}static getKeysBy(t){return Object.keys(localStorage).filter(n=>n.startsWith(t))}}var gt=(s=>(s.log="log",s.info="info",s.warn="warn",s.debug="debug",s.error="error",s))(gt||{});class V{static listeners=new Set;static enabled=!0;static log(...t){V.doLog(gt.log,t)}static info(...t){V.doLog(gt.info,t)}static warn(...t){V.doLog(gt.warn,t)}static debug(...t){V.doLog(gt.debug,t)}static error(...t){V.doLog(gt.error,t)}static clearListeners(){V.listeners.clear()}static setEnabled(t){V.enabled=t}static doLog(t,n){if(!V.enabled)return;const a={type:t,args:n,timestamp:new Date().toISOString()};for(const _ of V.listeners)try{if(_(a)===!1)return}catch{}console[t].apply(console,n)}static onLog(t,n=!1){if(n){const a=_=>{try{return t(_)}finally{V.listeners.delete(a)}};return V.listeners.add(a),()=>V.listeners.delete(a)}return V.listeners.add(t),()=>V.listeners.delete(t)}}const ee=(s,t,n)=>s.localeCompare(t)*(n?1:-1),re=(s,t)=>s<t?-1:s===t?0:1,ne=(s,t,n)=>re(s,t)*(n?1:-1),ie=(s,t,n)=>{let a=0;return typeof s=="string"&&typeof t=="string"?a=ee(s,t,n):a=ne(s,t,n),a},Lt=(s,t,n,a)=>{const _=n(s),D=n(t);return ie(_,D,a)};class se{static get(t){return yt.get(t)}static set(t,n){yt.set(t,n)}static remove(t){yt.remove(t)}}class I{static listeners=new Set;static initialized=!1;static resizeTimeout=null;static lastWidth=null;static onResize(t){return I.initialized||I.init(),I.listeners.add(t),()=>I.off(t)}static handleResize=()=>{I.resizeTimeout!==null&&(window.clearTimeout(I.resizeTimeout),I.resizeTimeout=null),I.resizeTimeout=window.setTimeout(()=>{const t=window.innerWidth;if(I.resizeTimeout=null,t!==I.lastWidth){I.lastWidth=t;for(const n of I.listeners)n(t)}},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(t){I.initialized&&(I.listeners.delete(t),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 ae(){Array.prototype.distinct=function(s){return s?this.filter((n,a,_)=>_.findIndex(D=>s(D,n))===a):this.filter((n,a,_)=>_.indexOf(n)===a)},Array.prototype.filterBy=function(s){return this.filter(t=>s(t))},Array.prototype.first=function(){return this.length>0?this[0]:null},Array.prototype.groupBy=function(s){return this.reduce((t,n)=>{const a=s(n);return t[a]||(t[a]=[]),t[a].push(n),t},{})},Array.prototype.orderBy=function(s,t=!0){return this?.sort((n,a)=>Lt(n,a,s,t)),this},Array.prototype.removeBy=function(s,t){return this.filter(n=>s(n)!==t)}}var Dt={exports:{}},oe=Dt.exports,Ft;function ue(){return Ft||(Ft=1,(function(s,t){(function(n,a){s.exports=a()})(oe,(function(){var n=1e3,a=6e4,_=36e5,D="millisecond",R="second",U="minute",K="hour",p="day",W="week",j="month",Q="quarter",q="year",et="date",nt="Invalid Date",ct=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,vt=/\[([^\]]+)]|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,bt={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(y){var d=["th","st","nd","rd"],l=y%100;return"["+y+(d[(l-20)%10]||d[l]||d[0])+"]"}},ht=function(y,d,l){var o=String(y);return!o||o.length>=d?y:""+Array(d+1-o.length).join(l)+y},Ct={s:ht,z:function(y){var d=-y.utcOffset(),l=Math.abs(d),o=Math.floor(l/60),c=l%60;return(d<=0?"+":"-")+ht(o,2,"0")+":"+ht(c,2,"0")},m:function y(d,l){if(d.date()<l.date())return-y(l,d);var o=12*(l.year()-d.year())+(l.month()-d.month()),c=d.clone().add(o,j),f=l-c<0,v=d.clone().add(o+(f?-1:1),j);return+(-(o+(l-c)/(f?c-v:v-c))||0)},a:function(y){return y<0?Math.ceil(y)||0:Math.floor(y)},p:function(y){return{M:j,y:q,w:W,d:p,D:et,h:K,m:U,s:R,ms:D,Q}[y]||String(y||"").toLowerCase().replace(/s$/,"")},u:function(y){return y===void 0}},ft="en",Z={};Z[ft]=bt;var T="$isDayjsObject",e=function(y){return y instanceof m||!(!y||!y[T])},r=function y(d,l,o){var c;if(!d)return ft;if(typeof d=="string"){var f=d.toLowerCase();Z[f]&&(c=f),l&&(Z[f]=l,c=f);var v=d.split("-");if(!c&&v.length>1)return y(v[0])}else{var g=d.name;Z[g]=d,c=g}return!o&&c&&(ft=c),c||!o&&ft},i=function(y,d){if(e(y))return y.clone();var l=typeof d=="object"?d:{};return l.date=y,l.args=arguments,new m(l)},u=Ct;u.l=r,u.i=e,u.w=function(y,d){return i(y,{locale:d.$L,utc:d.$u,x:d.$x,$offset:d.$offset})};var m=(function(){function y(l){this.$L=r(l.locale,null,!0),this.parse(l),this.$x=this.$x||l.x||{},this[T]=!0}var d=y.prototype;return d.parse=function(l){this.$d=(function(o){var c=o.date,f=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 v=c.match(ct);if(v){var g=v[2]-1||0,w=(v[7]||"0").substring(0,3);return f?new Date(Date.UTC(v[1],g,v[3]||1,v[4]||0,v[5]||0,v[6]||0,w)):new Date(v[1],g,v[3]||1,v[4]||0,v[5]||0,v[6]||0,w)}}return new Date(c)})(l),this.init()},d.init=function(){var l=this.$d;this.$y=l.getFullYear(),this.$M=l.getMonth(),this.$D=l.getDate(),this.$W=l.getDay(),this.$H=l.getHours(),this.$m=l.getMinutes(),this.$s=l.getSeconds(),this.$ms=l.getMilliseconds()},d.$utils=function(){return u},d.isValid=function(){return this.$d.toString()!==nt},d.isSame=function(l,o){var c=i(l);return this.startOf(o)<=c&&c<=this.endOf(o)},d.isAfter=function(l,o){return i(l)<this.startOf(o)},d.isBefore=function(l,o){return this.endOf(o)<i(l)},d.$g=function(l,o,c){return u.u(l)?this[o]:this.set(c,l)},d.unix=function(){return Math.floor(this.valueOf()/1e3)},d.valueOf=function(){return this.$d.getTime()},d.startOf=function(l,o){var c=this,f=!!u.u(o)||o,v=u.p(l),g=function(O,x){var k=u.w(c.$u?Date.UTC(c.$y,x,O):new Date(c.$y,x,O),c);return f?k:k.endOf(p)},w=function(O,x){return u.w(c.toDate()[O].apply(c.toDate("s"),(f?[0,0,0,0]:[23,59,59,999]).slice(x)),c)},h=this.$W,M=this.$M,C=this.$D,P="set"+(this.$u?"UTC":"");switch(v){case q:return f?g(1,0):g(31,11);case j:return f?g(1,M):g(0,M+1);case W:var N=this.$locale().weekStart||0,b=(h<N?h+7:h)-N;return g(f?C-b:C+(6-b),M);case p:case et:return w(P+"Hours",0);case K:return w(P+"Minutes",1);case U:return w(P+"Seconds",2);case R:return w(P+"Milliseconds",3);default:return this.clone()}},d.endOf=function(l){return this.startOf(l,!1)},d.$set=function(l,o){var c,f=u.p(l),v="set"+(this.$u?"UTC":""),g=(c={},c[p]=v+"Date",c[et]=v+"Date",c[j]=v+"Month",c[q]=v+"FullYear",c[K]=v+"Hours",c[U]=v+"Minutes",c[R]=v+"Seconds",c[D]=v+"Milliseconds",c)[f],w=f===p?this.$D+(o-this.$W):o;if(f===j||f===q){var h=this.clone().set(et,1);h.$d[g](w),h.init(),this.$d=h.set(et,Math.min(this.$D,h.daysInMonth())).$d}else g&&this.$d[g](w);return this.init(),this},d.set=function(l,o){return this.clone().$set(l,o)},d.get=function(l){return this[u.p(l)]()},d.add=function(l,o){var c,f=this;l=Number(l);var v=u.p(o),g=function(M){var C=i(f);return u.w(C.date(C.date()+Math.round(M*l)),f)};if(v===j)return this.set(j,this.$M+l);if(v===q)return this.set(q,this.$y+l);if(v===p)return g(1);if(v===W)return g(7);var w=(c={},c[U]=a,c[K]=_,c[R]=n,c)[v]||1,h=this.$d.getTime()+l*w;return u.w(h,this)},d.subtract=function(l,o){return this.add(-1*l,o)},d.format=function(l){var o=this,c=this.$locale();if(!this.isValid())return c.invalidDate||nt;var f=l||"YYYY-MM-DDTHH:mm:ssZ",v=u.z(this),g=this.$H,w=this.$m,h=this.$M,M=c.weekdays,C=c.months,P=c.meridiem,N=function(x,k,A,Y){return x&&(x[k]||x(o,f))||A[k].slice(0,Y)},b=function(x){return u.s(g%12||12,x,"0")},O=P||function(x,k,A){var Y=x<12?"AM":"PM";return A?Y.toLowerCase():Y};return f.replace(vt,(function(x,k){return k||(function(A){switch(A){case"YY":return String(o.$y).slice(-2);case"YYYY":return u.s(o.$y,4,"0");case"M":return h+1;case"MM":return u.s(h+1,2,"0");case"MMM":return N(c.monthsShort,h,C,3);case"MMMM":return N(C,h);case"D":return o.$D;case"DD":return u.s(o.$D,2,"0");case"d":return String(o.$W);case"dd":return N(c.weekdaysMin,o.$W,M,2);case"ddd":return N(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 b(1);case"hh":return b(2);case"a":return O(g,w,!0);case"A":return O(g,w,!1);case"m":return String(w);case"mm":return u.s(w,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 v}return null})(x)||v.replace(":","")}))},d.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},d.diff=function(l,o,c){var f,v=this,g=u.p(o),w=i(l),h=(w.utcOffset()-this.utcOffset())*a,M=this-w,C=function(){return u.m(v,w)};switch(g){case q:f=C()/12;break;case j:f=C();break;case Q:f=C()/3;break;case W:f=(M-h)/6048e5;break;case p:f=(M-h)/864e5;break;case K:f=M/_;break;case U:f=M/a;break;case R:f=M/n;break;default:f=M}return c?f:u.a(f)},d.daysInMonth=function(){return this.endOf(j).$D},d.$locale=function(){return Z[this.$L]},d.locale=function(l,o){if(!l)return this.$L;var c=this.clone(),f=r(l,o,!0);return f&&(c.$L=f),c},d.clone=function(){return u.w(this.$d,this)},d.toDate=function(){return new Date(this.valueOf())},d.toJSON=function(){return this.isValid()?this.toISOString():null},d.toISOString=function(){return this.$d.toISOString()},d.toString=function(){return this.$d.toUTCString()},y})(),S=m.prototype;return i.prototype=S,[["$ms",D],["$s",R],["$m",U],["$H",K],["$W",p],["$M",j],["$y",q],["$D",et]].forEach((function(y){S[y[1]]=function(d){return this.$g(d,y[0],y[1])}})),i.extend=function(y,d){return y.$i||(y(d,m,i),y.$i=!0),i},i.locale=r,i.isDayjs=e,i.unix=function(y){return i(1e3*y)},i.en=Z[ft],i.Ls=Z,i.p={},i}))})(Dt)),Dt.exports}var ce=ue();const tt=Ot(ce);var Mt={exports:{}},fe=Mt.exports,zt;function le(){return zt||(zt=1,(function(s,t){(function(n,a){s.exports=a()})(fe,(function(){var n="day";return function(a,_,D){var R=function(p){return p.add(4-p.isoWeekday(),n)},U=_.prototype;U.isoWeekYear=function(){return R(this).year()},U.isoWeek=function(p){if(!this.$utils().u(p))return this.add(7*(p-this.isoWeek()),n);var W,j,Q,q,et=R(this),nt=(W=this.isoWeekYear(),j=this.$u,Q=(j?D.utc:D)().year(W).startOf("year"),q=4-Q.isoWeekday(),Q.isoWeekday()>4&&(q+=7),Q.add(q,n));return et.diff(nt,"week")+1},U.isoWeekday=function(p){return this.$utils().u(p)?this.day()||7:this.day(this.day()%7?p:p-7)};var K=U.startOf;U.startOf=function(p,W){var j=this.$utils(),Q=!!j.u(W)||W;return j.p(p)==="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)(p,W)}}}))})(Mt)),Mt.exports}var de=le();const he=Ot(de);var $t={exports:{}},pe=$t.exports,jt;function ge(){return jt||(jt=1,(function(s,t){(function(n,a){s.exports=a()})(pe,(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(a,_,D){var R=_.prototype,U=R.format;D.en.formats=n,R.format=function(K){K===void 0&&(K="YYYY-MM-DDTHH:mm:ssZ");var p=this.$locale().formats,W=(function(j,Q){return j.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(q,et,nt){var ct=nt&&nt.toUpperCase();return et||Q[nt]||n[nt]||Q[ct].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(vt,bt,ht){return bt||ht.slice(1)}))}))})(K,p===void 0?{}:p);return U.call(this,W)}}}))})($t)),$t.exports}var me=ge();const ye=Ot(me);tt.extend(ye),tt.extend(he);function ve(){Date.prototype.add=function(s,t){return tt(this).add(s,t).toDate()},Date.prototype.diff=function(s,t){return tt(this).diff(s,t)},Date.prototype.endOf=function(s){return tt(this).endOf(s).toDate()},Date.prototype.firstDayOfMonth=function(){return tt(this).startOf("month").toDate()},Date.prototype.format=function(s){return tt(this).format(s)},Date.prototype.isAfter=function(s,t){return tt(this).isAfter(s,t)},Date.prototype.isBefore=function(s,t){return tt(this).isBefore(s,t)},Date.prototype.isValid=function(){return tt(this).isValid()},Date.prototype.isoWeek=function(){return tt(this).isoWeek()},Date.prototype.subtract=function(s,t){return tt(this).subtract(s,t).toDate()},Date.prototype.lastDayOfMonth=function(){return tt(this).endOf("month").toDate()},Date.prototype.set=function(s,t){return tt(this).set(s,t).toDate()},Date.prototype.startOf=function(s){return tt(this).startOf(s).toDate()}}function we(){String.prototype.capitalize=function(){return this.charAt(0).toUpperCase()+this.slice(1)},String.prototype.isNumber=function(){return!isNaN(Number(this))&&this.trim()!==""},String.prototype.isEmpty=function(){return this===void 0||!this||this.length===0},String.prototype.stripTags=function(){return new DOMParser().parseFromString(this.toString(),"text/html").body.textContent||""}}class ke{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(t){this.onResizeCallbacks.add(t)}offResizeChange(t){this.onResizeCallbacks.delete(t)}onResize=()=>{if(typeof window>"u")return;const t=window.innerWidth;this.emitTimeoutId!==null&&clearTimeout(this.emitTimeoutId),this.emitTimeoutId=window.setTimeout(()=>{this.emitTimeoutId=null;const n=dt.getBreakpointByScreenWidth(t);for(const a of this.onResizeCallbacks)a(t,n)},this.duplicateThresholdMs)}}z.BreakPointHelper=dt,z.BreakPoints=mt,z.BrowserHelper=H,z.BrowserService=ke,z.BrowserType=X,z.CsvHelper=Qt,z.EnumHelper=Ht,z.FileHelper=te,z.LocalStorageHelper=yt,z.LoggerHelper=V,z.LoggerType=gt,z.ScreenHelper=_t,z.TokenHelper=se,z.WindowResizeHelper=I,z.copyToClipboard=Ut,z.initArrayExtensions=ae,z.initDateExtensions=ve,z.initStringExtensions=we,z.saveAs=At,z.sortHelper=Lt,Object.defineProperty(z,Symbol.toStringTag,{value:"Module"})}));
|
|
10
|
+
`,'"',p.BYTE_ORDER_MARK],p.WORKERS_SUPPORTED=!D&&!!a.Worker,p.NODE_STREAM_INPUT=1,p.LocalChunkSize=10485760,p.RemoteChunkSize=5242880,p.DefaultDelimiter=",",p.Parser=yt,p.ParserHandle=nt,p.NetworkStreamer=j,p.FileStreamer=Q,p.StringStreamer=q,p.ReadableStreamStreamer=et,a.jQuery&&((_=a.jQuery).fn.parse=function(e){var r=e.config||{},i=[];return this.each(function(S){if(!(_(this).prop("tagName").toUpperCase()==="INPUT"&&_(this).attr("type").toLowerCase()==="file"&&a.FileReader)||!this.files||this.files.length===0)return!0;for(var y=0;y<this.files.length;y++)i.push({file:this.files[y],inputElem:this,instanceConfig:_.extend({},r)})}),u(),this;function u(){if(i.length===0)T(e.complete)&&e.complete();else{var S,y,d,l,o=i[0];if(T(e.before)){var c=e.before(o.file,o.inputElem);if(typeof c=="object"){if(c.action==="abort")return S="AbortError",y=o.file,d=o.inputElem,l=c.reason,void(T(e.error)&&e.error({name:S},y,d,l));if(c.action==="skip")return void m();typeof c.config=="object"&&(o.instanceConfig=_.extend(o.instanceConfig,c.config))}else if(c==="skip")return void m()}var f=o.instanceConfig.complete;o.instanceConfig.complete=function(v){T(f)&&f(v,o.file,o.inputElem),m()},p.parse(o.file,o.instanceConfig)}}function m(){i.splice(0,1),u()}}),R&&(a.onmessage=function(e){e=e.data,p.WORKER_ID===void 0&&e&&(p.WORKER_ID=e.workerId),typeof e.input=="string"?a.postMessage({workerId:p.WORKER_ID,results:p.parse(e.input,e.config),finished:!0}):(a.File&&e.input instanceof File||e.input instanceof Object)&&(e=p.parse(e.input,e.config))&&a.postMessage({workerId:p.WORKER_ID,results:e,finished:!0})}),(j.prototype=Object.create(W.prototype)).constructor=j,(Q.prototype=Object.create(W.prototype)).constructor=Q,(q.prototype=Object.create(q.prototype)).constructor=q,(et.prototype=Object.create(W.prototype)).constructor=et,p})})(Ot)),Ot.exports}var Nt=Bt();const qt=Et(Nt),{parse:Kt,unparse:Jt}=qt;class Qt{static unparse(t,n){return Jt(t,n)}static parse(t){return new Promise((n,a)=>{Kt(t,{header:!0,complete:_=>n(_),error:_=>a(_)})})}}async function At(s,t,n){const a=n?.mimeType??Zt(t),_=Vt(s,a);if("showSaveFilePicker"in window&&n?.showSaveFilePicker)try{const K=await(await window.showSaveFilePicker({suggestedName:t,types:[{description:"Datei",accept:{[a]:[`.${It(t)}`]}}]})).createWritable();await K.write(_),await K.close();return}catch{}const D=URL.createObjectURL(_),R=document.createElement("a");R.href=D,R.download=t,R.rel="noopener",R.style.display="none",document.body.appendChild(R),Gt(R),window.setTimeout(()=>{document.body.removeChild(R),URL.revokeObjectURL(D)},0),Xt()&&window.open(D,"_blank","noopener,noreferrer")}function Vt(s,t){if(s instanceof Blob)return s.type?s:new Blob([s],{type:t});if(s instanceof ArrayBuffer||s instanceof Uint8Array){const n=s instanceof Uint8Array?s:new Uint8Array(s);return new Blob([n],{type:t})}return new Blob([s],{type:t||"text/plain;charset=utf-8"})}function Zt(s){switch(It(s).toLowerCase()){case"txt":return"text/plain;charset=utf-8";case"csv":return"text/csv;charset=utf-8";case"json":return"application/json;charset=utf-8";case"pdf":return"application/pdf";case"png":return"image/png";case"jpg":case"jpeg":return"image/jpeg";case"svg":return"image/svg+xml";case"zip":return"application/zip";default:return"application/octet-stream"}}function It(s){const t=s.lastIndexOf(".");return t>=0&&t<s.length-1?s.slice(t+1):""}function Gt(s){const t=document.createEvent("MouseEvents");t.initMouseEvent("click",!0,!0,window,0,0,0,0,0,!1,!1,!1,!1,0,null),s.dispatchEvent(t)}function Xt(){const s=navigator.userAgent,t=/iPad|iPhone|iPod/.test(s),n=/^((?!chrome|android).)*safari/i.test(s);return t||n}class Ht{static getEnumValue(t,n){if(n in t)return t[n];throw Error(`${n} not found in ${t}`)}static getKeyValues(t){return Object.keys(t).filter(n=>!isNaN(Number(n))).map(n=>({key:Number(n),value:t[n]}))}}class te{static getFileExtension(t){let n="";const a=t.lastIndexOf(".");return a>0&&a<t.length-1&&(n=`.${t.substring(a+1).toLowerCase()}`),n}static readAsText(t){const n=new FileReader;return new Promise((a,_)=>{n.onload=()=>{n.onload=null,n.onerror=null,typeof n.result=="string"?a(n.result):_(new Error("Unexpected result type"))},n.onerror=()=>{const D=n.error??new Error("FileReader error");n.onload=null,n.onerror=null,_(D)},n.readAsText(t)})}static readAsArrayBuffer(t){const n=new FileReader;return new Promise((a,_)=>{n.onload=()=>{n.onload=null,n.onerror=null,n.result instanceof ArrayBuffer?a(n.result):_(new Error("Unexpected result type"))},n.onerror=()=>{const D=n.error??new Error("FileReader error");n.onload=null,n.onerror=null,_(D)},n.readAsArrayBuffer(t)})}static readAsDataUrl(t){const n=new FileReader;return new Promise((a,_)=>{n.onload=D=>{a(D)},n.onerror=D=>_(D),n.readAsDataURL(t)})}static formatFileSize(t,n=2,a){if(t===0)return"0 Bytes";const _=1024,D=["Bytes","KB","MB","GB","TB"];let R=Math.floor(Math.log(t)/Math.log(_));a&&D.includes(a)&&(R=D.indexOf(a));const U=t/Math.pow(_,R);return`${parseFloat(U.toFixed(n))} ${D[R]}`}static save(t,n,a){const _=new Blob([t],{type:a});At(_,n)}}class xt{static set(t,n){localStorage.setItem(t,JSON.stringify(n))}static get(t){let n=null;const a=localStorage.getItem(t);return a&&(n=JSON.parse(a)),n}static remove(t){const n=localStorage.getItem(t)!==null;return n&&localStorage.removeItem(t),n}static removeAll(){localStorage.clear()}static getKeysBy(t){return Object.keys(localStorage).filter(n=>n.startsWith(t))}}var gt=(s=>(s.log="log",s.info="info",s.warn="warn",s.debug="debug",s.error="error",s))(gt||{});class V{static listeners=new Set;static enabled=!0;static log(...t){V.doLog(gt.log,t)}static info(...t){V.doLog(gt.info,t)}static warn(...t){V.doLog(gt.warn,t)}static debug(...t){V.doLog(gt.debug,t)}static error(...t){V.doLog(gt.error,t)}static clearListeners(){V.listeners.clear()}static setEnabled(t){V.enabled=t}static doLog(t,n){if(!V.enabled)return;const a={type:t,args:n,timestamp:new Date().toISOString()};for(const _ of V.listeners)try{if(_(a)===!1)return}catch{}console[t].apply(console,n)}static onLog(t,n=!1){if(n){const a=_=>{try{return t(_)}finally{V.listeners.delete(a)}};return V.listeners.add(a),()=>V.listeners.delete(a)}return V.listeners.add(t),()=>V.listeners.delete(t)}}const ee=(s,t,n)=>s.localeCompare(t)*(n?1:-1),re=(s,t)=>s<t?-1:s===t?0:1,ne=(s,t,n)=>re(s,t)*(n?1:-1),ie=(s,t,n)=>{let a=0;return typeof s=="string"&&typeof t=="string"?a=ee(s,t,n):a=ne(s,t,n),a},Lt=(s,t,n,a)=>{const _=n(s),D=n(t);return ie(_,D,a)};class se{static get(t){return xt.get(t)}static set(t,n){xt.set(t,n)}static remove(t){xt.remove(t)}}class I{static listeners=new Set;static initialized=!1;static resizeTimeout=null;static lastWidth=null;static onResize(t){return I.initialized||I.init(),I.listeners.add(t),()=>I.off(t)}static handleResize=()=>{I.resizeTimeout!==null&&(window.clearTimeout(I.resizeTimeout),I.resizeTimeout=null),I.resizeTimeout=window.setTimeout(()=>{const t=window.innerWidth;if(I.resizeTimeout=null,t!==I.lastWidth){I.lastWidth=t;for(const n of I.listeners)n(t)}},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(t){I.initialized&&(I.listeners.delete(t),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 ae(){Array.prototype.distinct=function(s){return s?this.filter((n,a,_)=>_.findIndex(D=>s(D,n))===a):this.filter((n,a,_)=>_.indexOf(n)===a)},Array.prototype.filterBy=function(s){return this.filter(t=>s(t))},Array.prototype.first=function(){return this.length>0?this[0]:null},Array.prototype.groupBy=function(s){return this.reduce((t,n)=>{const a=s(n);return t[a]||(t[a]=[]),t[a].push(n),t},{})},Array.prototype.orderBy=function(s,t=!0){return this?.sort((n,a)=>Lt(n,a,s,t)),this},Array.prototype.removeBy=function(s,t){return this.filter(n=>s(n)!==t)}}var Dt={exports:{}},oe=Dt.exports,Ft;function ue(){return Ft||(Ft=1,(function(s,t){(function(n,a){s.exports=a()})(oe,(function(){var n=1e3,a=6e4,_=36e5,D="millisecond",R="second",U="minute",K="hour",p="day",W="week",j="month",Q="quarter",q="year",et="date",nt="Invalid Date",ct=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,yt=/\[([^\]]+)]|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,_t={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(y){var d=["th","st","nd","rd"],l=y%100;return"["+y+(d[(l-20)%10]||d[l]||d[0])+"]"}},ht=function(y,d,l){var o=String(y);return!o||o.length>=d?y:""+Array(d+1-o.length).join(l)+y},Ct={s:ht,z:function(y){var d=-y.utcOffset(),l=Math.abs(d),o=Math.floor(l/60),c=l%60;return(d<=0?"+":"-")+ht(o,2,"0")+":"+ht(c,2,"0")},m:function y(d,l){if(d.date()<l.date())return-y(l,d);var o=12*(l.year()-d.year())+(l.month()-d.month()),c=d.clone().add(o,j),f=l-c<0,v=d.clone().add(o+(f?-1:1),j);return+(-(o+(l-c)/(f?c-v:v-c))||0)},a:function(y){return y<0?Math.ceil(y)||0:Math.floor(y)},p:function(y){return{M:j,y:q,w:W,d:p,D:et,h:K,m:U,s:R,ms:D,Q}[y]||String(y||"").toLowerCase().replace(/s$/,"")},u:function(y){return y===void 0}},ft="en",Z={};Z[ft]=_t;var T="$isDayjsObject",e=function(y){return y instanceof m||!(!y||!y[T])},r=function y(d,l,o){var c;if(!d)return ft;if(typeof d=="string"){var f=d.toLowerCase();Z[f]&&(c=f),l&&(Z[f]=l,c=f);var v=d.split("-");if(!c&&v.length>1)return y(v[0])}else{var g=d.name;Z[g]=d,c=g}return!o&&c&&(ft=c),c||!o&&ft},i=function(y,d){if(e(y))return y.clone();var l=typeof d=="object"?d:{};return l.date=y,l.args=arguments,new m(l)},u=Ct;u.l=r,u.i=e,u.w=function(y,d){return i(y,{locale:d.$L,utc:d.$u,x:d.$x,$offset:d.$offset})};var m=(function(){function y(l){this.$L=r(l.locale,null,!0),this.parse(l),this.$x=this.$x||l.x||{},this[T]=!0}var d=y.prototype;return d.parse=function(l){this.$d=(function(o){var c=o.date,f=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 v=c.match(ct);if(v){var g=v[2]-1||0,w=(v[7]||"0").substring(0,3);return f?new Date(Date.UTC(v[1],g,v[3]||1,v[4]||0,v[5]||0,v[6]||0,w)):new Date(v[1],g,v[3]||1,v[4]||0,v[5]||0,v[6]||0,w)}}return new Date(c)})(l),this.init()},d.init=function(){var l=this.$d;this.$y=l.getFullYear(),this.$M=l.getMonth(),this.$D=l.getDate(),this.$W=l.getDay(),this.$H=l.getHours(),this.$m=l.getMinutes(),this.$s=l.getSeconds(),this.$ms=l.getMilliseconds()},d.$utils=function(){return u},d.isValid=function(){return this.$d.toString()!==nt},d.isSame=function(l,o){var c=i(l);return this.startOf(o)<=c&&c<=this.endOf(o)},d.isAfter=function(l,o){return i(l)<this.startOf(o)},d.isBefore=function(l,o){return this.endOf(o)<i(l)},d.$g=function(l,o,c){return u.u(l)?this[o]:this.set(c,l)},d.unix=function(){return Math.floor(this.valueOf()/1e3)},d.valueOf=function(){return this.$d.getTime()},d.startOf=function(l,o){var c=this,f=!!u.u(o)||o,v=u.p(l),g=function(O,x){var k=u.w(c.$u?Date.UTC(c.$y,x,O):new Date(c.$y,x,O),c);return f?k:k.endOf(p)},w=function(O,x){return u.w(c.toDate()[O].apply(c.toDate("s"),(f?[0,0,0,0]:[23,59,59,999]).slice(x)),c)},h=this.$W,M=this.$M,C=this.$D,P="set"+(this.$u?"UTC":"");switch(v){case q:return f?g(1,0):g(31,11);case j:return f?g(1,M):g(0,M+1);case W:var N=this.$locale().weekStart||0,b=(h<N?h+7:h)-N;return g(f?C-b:C+(6-b),M);case p:case et:return w(P+"Hours",0);case K:return w(P+"Minutes",1);case U:return w(P+"Seconds",2);case R:return w(P+"Milliseconds",3);default:return this.clone()}},d.endOf=function(l){return this.startOf(l,!1)},d.$set=function(l,o){var c,f=u.p(l),v="set"+(this.$u?"UTC":""),g=(c={},c[p]=v+"Date",c[et]=v+"Date",c[j]=v+"Month",c[q]=v+"FullYear",c[K]=v+"Hours",c[U]=v+"Minutes",c[R]=v+"Seconds",c[D]=v+"Milliseconds",c)[f],w=f===p?this.$D+(o-this.$W):o;if(f===j||f===q){var h=this.clone().set(et,1);h.$d[g](w),h.init(),this.$d=h.set(et,Math.min(this.$D,h.daysInMonth())).$d}else g&&this.$d[g](w);return this.init(),this},d.set=function(l,o){return this.clone().$set(l,o)},d.get=function(l){return this[u.p(l)]()},d.add=function(l,o){var c,f=this;l=Number(l);var v=u.p(o),g=function(M){var C=i(f);return u.w(C.date(C.date()+Math.round(M*l)),f)};if(v===j)return this.set(j,this.$M+l);if(v===q)return this.set(q,this.$y+l);if(v===p)return g(1);if(v===W)return g(7);var w=(c={},c[U]=a,c[K]=_,c[R]=n,c)[v]||1,h=this.$d.getTime()+l*w;return u.w(h,this)},d.subtract=function(l,o){return this.add(-1*l,o)},d.format=function(l){var o=this,c=this.$locale();if(!this.isValid())return c.invalidDate||nt;var f=l||"YYYY-MM-DDTHH:mm:ssZ",v=u.z(this),g=this.$H,w=this.$m,h=this.$M,M=c.weekdays,C=c.months,P=c.meridiem,N=function(x,k,A,Y){return x&&(x[k]||x(o,f))||A[k].slice(0,Y)},b=function(x){return u.s(g%12||12,x,"0")},O=P||function(x,k,A){var Y=x<12?"AM":"PM";return A?Y.toLowerCase():Y};return f.replace(yt,(function(x,k){return k||(function(A){switch(A){case"YY":return String(o.$y).slice(-2);case"YYYY":return u.s(o.$y,4,"0");case"M":return h+1;case"MM":return u.s(h+1,2,"0");case"MMM":return N(c.monthsShort,h,C,3);case"MMMM":return N(C,h);case"D":return o.$D;case"DD":return u.s(o.$D,2,"0");case"d":return String(o.$W);case"dd":return N(c.weekdaysMin,o.$W,M,2);case"ddd":return N(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 b(1);case"hh":return b(2);case"a":return O(g,w,!0);case"A":return O(g,w,!1);case"m":return String(w);case"mm":return u.s(w,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 v}return null})(x)||v.replace(":","")}))},d.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},d.diff=function(l,o,c){var f,v=this,g=u.p(o),w=i(l),h=(w.utcOffset()-this.utcOffset())*a,M=this-w,C=function(){return u.m(v,w)};switch(g){case q:f=C()/12;break;case j:f=C();break;case Q:f=C()/3;break;case W:f=(M-h)/6048e5;break;case p:f=(M-h)/864e5;break;case K:f=M/_;break;case U:f=M/a;break;case R:f=M/n;break;default:f=M}return c?f:u.a(f)},d.daysInMonth=function(){return this.endOf(j).$D},d.$locale=function(){return Z[this.$L]},d.locale=function(l,o){if(!l)return this.$L;var c=this.clone(),f=r(l,o,!0);return f&&(c.$L=f),c},d.clone=function(){return u.w(this.$d,this)},d.toDate=function(){return new Date(this.valueOf())},d.toJSON=function(){return this.isValid()?this.toISOString():null},d.toISOString=function(){return this.$d.toISOString()},d.toString=function(){return this.$d.toUTCString()},y})(),S=m.prototype;return i.prototype=S,[["$ms",D],["$s",R],["$m",U],["$H",K],["$W",p],["$M",j],["$y",q],["$D",et]].forEach((function(y){S[y[1]]=function(d){return this.$g(d,y[0],y[1])}})),i.extend=function(y,d){return y.$i||(y(d,m,i),y.$i=!0),i},i.locale=r,i.isDayjs=e,i.unix=function(y){return i(1e3*y)},i.en=Z[ft],i.Ls=Z,i.p={},i}))})(Dt)),Dt.exports}var ce=ue();const tt=Et(ce);var Mt={exports:{}},fe=Mt.exports,zt;function le(){return zt||(zt=1,(function(s,t){(function(n,a){s.exports=a()})(fe,(function(){var n="day";return function(a,_,D){var R=function(p){return p.add(4-p.isoWeekday(),n)},U=_.prototype;U.isoWeekYear=function(){return R(this).year()},U.isoWeek=function(p){if(!this.$utils().u(p))return this.add(7*(p-this.isoWeek()),n);var W,j,Q,q,et=R(this),nt=(W=this.isoWeekYear(),j=this.$u,Q=(j?D.utc:D)().year(W).startOf("year"),q=4-Q.isoWeekday(),Q.isoWeekday()>4&&(q+=7),Q.add(q,n));return et.diff(nt,"week")+1},U.isoWeekday=function(p){return this.$utils().u(p)?this.day()||7:this.day(this.day()%7?p:p-7)};var K=U.startOf;U.startOf=function(p,W){var j=this.$utils(),Q=!!j.u(W)||W;return j.p(p)==="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)(p,W)}}}))})(Mt)),Mt.exports}var de=le();const he=Et(de);var $t={exports:{}},pe=$t.exports,jt;function ge(){return jt||(jt=1,(function(s,t){(function(n,a){s.exports=a()})(pe,(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(a,_,D){var R=_.prototype,U=R.format;D.en.formats=n,R.format=function(K){K===void 0&&(K="YYYY-MM-DDTHH:mm:ssZ");var p=this.$locale().formats,W=(function(j,Q){return j.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(q,et,nt){var ct=nt&&nt.toUpperCase();return et||Q[nt]||n[nt]||Q[ct].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(yt,_t,ht){return _t||ht.slice(1)}))}))})(K,p===void 0?{}:p);return U.call(this,W)}}}))})($t)),$t.exports}var me=ge();const ye=Et(me);tt.extend(ye),tt.extend(he);function ve(){Date.prototype.add=function(s,t){return tt(this).add(s,t).toDate()},Date.prototype.diff=function(s,t){return tt(this).diff(s,t)},Date.prototype.endOf=function(s){return tt(this).endOf(s).toDate()},Date.prototype.firstDayOfMonth=function(){return tt(this).startOf("month").toDate()},Date.prototype.format=function(s){return tt(this).format(s)},Date.prototype.isAfter=function(s,t){return tt(this).isAfter(s,t)},Date.prototype.isBefore=function(s,t){return tt(this).isBefore(s,t)},Date.prototype.isValid=function(){return tt(this).isValid()},Date.prototype.isoWeek=function(){return tt(this).isoWeek()},Date.prototype.subtract=function(s,t){return tt(this).subtract(s,t).toDate()},Date.prototype.lastDayOfMonth=function(){return tt(this).endOf("month").toDate()},Date.prototype.set=function(s,t){return tt(this).set(s,t).toDate()},Date.prototype.startOf=function(s){return tt(this).startOf(s).toDate()}}function we(){String.prototype.capitalize=function(){return this.charAt(0).toUpperCase()+this.slice(1)},String.prototype.isNumber=function(){return!isNaN(Number(this))&&this.trim()!==""},String.prototype.isEmpty=function(){return this===void 0||!this||this.length===0},String.prototype.stripTags=function(){return new DOMParser().parseFromString(this.toString(),"text/html").body.textContent||""}}class ke{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(t){this.onResizeCallbacks.add(t)}offResizeChange(t){this.onResizeCallbacks.delete(t)}onResize=()=>{if(typeof window>"u")return;const t=window.innerWidth;this.emitTimeoutId!==null&&clearTimeout(this.emitTimeoutId),this.emitTimeoutId=window.setTimeout(()=>{this.emitTimeoutId=null;const n=dt.getBreakpointByScreenWidth(t);for(const a of this.onResizeCallbacks)a(t,n)},this.duplicateThresholdMs)}}z.BreakPointHelper=dt,z.BreakPoints=mt,z.BrowserHelper=H,z.BrowserService=ke,z.BrowserType=X,z.CsvHelper=Qt,z.EnumHelper=Ht,z.FileHelper=te,z.LocalStorageHelper=xt,z.LoggerHelper=V,z.LoggerType=gt,z.ScreenHelper=kt,z.TokenHelper=se,z.WindowResizeHelper=I,z.copyToClipboard=Ut,z.initArrayExtensions=ae,z.initDateExtensions=ve,z.initStringExtensions=we,z.saveAs=At,z.sortHelper=Lt,Object.defineProperty(z,Symbol.toStringTag,{value:"Module"})}));
|