Files
firefly-iii/public/build/assets/dashboard-2100f404.js

47 lines
869 KiB
JavaScript
Raw Normal View History

2023-10-01 07:17:56 +02:00
var ve=Object.defineProperty;var be=(t,e,a)=>e in t?ve(t,e,{enumerable:!0,configurable:!0,writable:!0,value:a}):t[e]=a;var R=(t,e,a)=>(be(t,typeof e!="symbol"?e+"":e,a),a);function bind$4(t,e){return function(){return t.apply(e,arguments)}}const{toString:toString$7}=Object.prototype,{getPrototypeOf}=Object,kindOf=(t=>e=>{const a=toString$7.call(e);return t[a]||(t[a]=a.slice(8,-1).toLowerCase())})(Object.create(null)),kindOfTest=t=>(t=t.toLowerCase(),e=>kindOf(e)===t),typeOfTest=t=>e=>typeof e===t,{isArray:isArray$d}=Array,isUndefined=typeOfTest("undefined");function isBuffer$3(t){return t!==null&&!isUndefined(t)&&t.constructor!==null&&!isUndefined(t.constructor)&&isFunction$6(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const isArrayBuffer=kindOfTest("ArrayBuffer");function isArrayBufferView(t){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&isArrayBuffer(t.buffer),e}const isString$1=typeOfTest("string"),isFunction$6=typeOfTest("function"),isNumber$1=typeOfTest("number"),isObject$c=t=>t!==null&&typeof t=="object",isBoolean=t=>t===!0||t===!1,isPlainObject=t=>{if(kindOf(t)!=="object")return!1;const e=getPrototypeOf(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Symbol.toStringTag in t)&&!(Symbol.iterator in t)},isDate$1=kindOfTest("Date"),isFile=kindOfTest("File"),isBlob=kindOfTest("Blob"),isFileList=kindOfTest("FileList"),isStream=t=>isObject$c(t)&&isFunction$6(t.pipe),isFormData=t=>{let e;return t&&(typeof FormData=="function"&&t instanceof FormData||isFunction$6(t.append)&&((e=kindOf(t))==="formdata"||e==="object"&&isFunction$6(t.toString)&&t.toString()==="[object FormData]"))},isURLSearchParams=kindOfTest("URLSearchParams"),trim$2=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function forEach(t,e,{allOwnKeys:a=!1}={}){if(t===null||typeof t>"u")return;let n,r;if(typeof t!="object"&&(t=[t]),isArray$d(t))for(n=0,r=t.length;n<r;n++)e.call(null,t[n],n,t);else{const i=a?Object.getOwnPropertyNames(t):Object.keys(t),o=i.length;let s;for(n=0;n<o;n++)s=i[n],e.call(null,t[s],s,t)}}function findKey$1(t,e){e=e.toLowerCase();const a=Object.keys(t);let n=a.length,r;for(;n-- >0;)if(r=a[n],e===r.toLowerCase())return r;return null}const _global=(()=>typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global)(),isContextDefined=t=>!isUndefined(t)&&t!==_global;function merge$1(){const{caseless:t}=isContextDefined(this)&&this||{},e={},a=(n,r)=>{const i=t&&findKey$1(e,r)||r;isPlainObject(e[i])&&isPlainObject(n)?e[i]=merge$1(e[i],n):isPlainObject(n)?e[i]=merge$1({},n):isArray$d(n)?e[i]=n.slice():e[i]=n};for(let n=0,r=arguments.length;n<r;n++)arguments[n]&&forEach(arguments[n],a);return e}const extend=(t,e,a,{allOwnKeys:n}={})=>(forEach(e,(r,i)=>{a&&isFunction$6(r)?t[i]=bind$4(r,a):t[i]=r},{allOwnKeys:n}),t),stripBOM=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),inherits=(t,e,a,n)=>{t.prototype=Object.create(e.prototype,n),t.prototype.constructor=t,Object.defineProperty(t,"super",{value:e.prototype}),a&&Object.assign(t.prototype,a)},toFlatObject=(t,e,a,n)=>{let r,i,o;const s={};if(e=e||{},t==null)return e;do{for(r=Object.getOwnPropertyNames(t),i=r.length;i-- >0;)o=r[i],(!n||n(o,t,e))&&!s[o]&&(e[o]=t[o],s[o]=!0);t=a!==!1&&getPrototypeOf(t)}while(t&&(!a||a(t,e))&&t!==Object.prototype);return e},endsWith=(t,e,a)=>{t=String(t),(a===void 0||a>t.length)&&(a=t.length),a-=e.length;const n=t.indexOf(e,a);return n!==-1&&n===a},toArray=t=>{if(!t)return null;if(isArray$d(t))return t;let e=t.length;if(!isNumber$1(e))return null;const a=new Array(e);for(;e-- >0;)a[e]=t[e];return a},isTypedArray$3=(t=>e=>t&&e instanceof t)(typeof Uint8Array<"u"&&getPrototypeOf(Uint8Array)),forEachEntry=(t,e)=>{const n=(t&&t[Symbol.iterator]).call(t);let r;for(;(r=n.next())&&!r.done;){const i=r.value;e.call(t,i[0],i[1])}},matchAll=(t,e)=>{let a;const n=[];for(;(a=t.exec(e))!==null;)n.push(a);return n},isHTMLForm=kindOfTest("HTMLFormElement"),toCamelCase=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(a,n,r){return n.toUpperCase(
2023-08-12 17:44:00 +02:00
`).forEach(function(o){r=o.indexOf(":"),a=o.substring(0,r).trim().toLowerCase(),n=o.substring(r+1).trim(),!(!a||e[a]&&ignoreDuplicateOf[a])&&(a==="set-cookie"?e[a]?e[a].push(n):e[a]=[n]:e[a]=e[a]?e[a]+", "+n:n)}),e},$internals=Symbol("internals");function normalizeHeader(t){return t&&String(t).trim().toLowerCase()}function normalizeValue(t){return t===!1||t==null?t:utils.isArray(t)?t.map(normalizeValue):String(t)}function parseTokens(t){const e=Object.create(null),a=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=a.exec(t);)e[n[1]]=n[2];return e}const isValidHeaderName=t=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());function matchHeaderValue(t,e,a,n,r){if(utils.isFunction(n))return n.call(this,e,a);if(r&&(e=a),!!utils.isString(e)){if(utils.isString(n))return e.indexOf(n)!==-1;if(utils.isRegExp(n))return n.test(e)}}function formatHeader(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,a,n)=>a.toUpperCase()+n)}function buildAccessors(t,e){const a=utils.toCamelCase(" "+e);["get","set","has"].forEach(n=>{Object.defineProperty(t,n+a,{value:function(r,i,o){return this[n].call(this,e,r,i,o)},configurable:!0})})}class AxiosHeaders{constructor(e){e&&this.set(e)}set(e,a,n){const r=this;function i(s,l,u){const c=normalizeHeader(l);if(!c)throw new Error("header name must be a non-empty string");const d=utils.findKey(r,c);(!d||r[d]===void 0||u===!0||u===void 0&&r[d]!==!1)&&(r[d||l]=normalizeValue(s))}const o=(s,l)=>utils.forEach(s,(u,c)=>i(u,c,l));return utils.isPlainObject(e)||e instanceof this.constructor?o(e,a):utils.isString(e)&&(e=e.trim())&&!isValidHeaderName(e)?o(parseHeaders(e),a):e!=null&&i(a,e,n),this}get(e,a){if(e=normalizeHeader(e),e){const n=utils.findKey(this,e);if(n){const r=this[n];if(!a)return r;if(a===!0)return parseTokens(r);if(utils.isFunction(a))return a.call(this,r,n);if(utils.isRegExp(a))return a.exec(r);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,a){if(e=normalizeHeader(e),e){const n=utils.findKey(this,e);return!!(n&&this[n]!==void 0&&(!a||matchHeaderValue(this,this[n],n,a)))}return!1}delete(e,a){const n=this;let r=!1;function i(o){if(o=normalizeHeader(o),o){const s=utils.findKey(n,o);s&&(!a||matchHeaderValue(n,n[s],s,a))&&(delete n[s],r=!0)}}return utils.isArray(e)?e.forEach(i):i(e),r}clear(e){const a=Object.keys(this);let n=a.length,r=!1;for(;n--;){const i=a[n];(!e||matchHeaderValue(this,this[i],i,e,!0))&&(delete this[i],r=!0)}return r}normalize(e){const a=this,n={};return utils.forEach(this,(r,i)=>{const o=utils.findKey(n,i);if(o){a[o]=normalizeValue(r),delete a[i];return}const s=e?formatHeader(i):String(i).trim();s!==i&&delete a[i],a[s]=normalizeValue(r),n[s]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const a=Object.create(null);return utils.forEach(this,(n,r)=>{n!=null&&n!==!1&&(a[r]=e&&utils.isArray(n)?n.join(", "):n)}),a}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,a])=>e+": "+a).join(`
2023-08-29 07:34:41 +02:00
`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...a){const n=new this(e);return a.forEach(r=>n.set(r)),n}static accessor(e){const n=(this[$internals]=this[$internals]={accessors:{}}).accessors,r=this.prototype;function i(o){const s=normalizeHeader(o);n[s]||(buildAccessors(r,o),n[s]=!0)}return utils.isArray(e)?e.forEach(i):i(e),this}}AxiosHeaders.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);utils.reduceDescriptors(AxiosHeaders.prototype,({value:t},e)=>{let a=e[0].toUpperCase()+e.slice(1);return{get:()=>t,set(n){this[a]=n}}});utils.freezeMethods(AxiosHeaders);const AxiosHeaders$1=AxiosHeaders;function transformData(t,e){const a=this||defaults$2,n=e||a,r=AxiosHeaders$1.from(n.headers);let i=n.data;return utils.forEach(t,function(s){i=s.call(a,i,r.normalize(),e?e.status:void 0)}),r.normalize(),i}function isCancel(t){return!!(t&&t.__CANCEL__)}function CanceledError(t,e,a){AxiosError.call(this,t??"canceled",AxiosError.ERR_CANCELED,e,a),this.name="CanceledError"}utils.inherits(CanceledError,AxiosError,{__CANCEL__:!0});function settle(t,e,a){const n=a.config.validateStatus;!a.status||!n||n(a.status)?t(a):e(new AxiosError("Request failed with status code "+a.status,[AxiosError.ERR_BAD_REQUEST,AxiosError.ERR_BAD_RESPONSE][Math.floor(a.status/100)-4],a.config,a.request,a))}const cookies=platform.isStandardBrowserEnv?function(){return{write:function(a,n,r,i,o,s){const l=[];l.push(a+"="+encodeURIComponent(n)),utils.isNumber(r)&&l.push("expires="+new Date(r).toGMTString()),utils.isString(i)&&l.push("path="+i),utils.isString(o)&&l.push("domain="+o),s===!0&&l.push("secure"),document.cookie=l.join("; ")},read:function(a){const n=document.cookie.match(new RegExp("(^|;\\s*)("+a+")=([^;]*)"));return n?decodeURIComponent(n[3]):null},remove:function(a){this.write(a,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}();function isAbsoluteURL(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function combineURLs(t,e){return e?t.replace(/\/+$/,"")+"/"+e.replace(/^\/+/,""):t}function buildFullPath(t,e){return t&&!isAbsoluteURL(e)?combineURLs(t,e):e}const isURLSameOrigin=platform.isStandardBrowserEnv?function(){const e=/(msie|trident)/i.test(navigator.userAgent),a=document.createElement("a");let n;function r(i){let o=i;return e&&(a.setAttribute("href",o),o=a.href),a.setAttribute("href",o),{href:a.href,protocol:a.protocol?a.protocol.replace(/:$/,""):"",host:a.host,search:a.search?a.search.replace(/^\?/,""):"",hash:a.hash?a.hash.replace(/^#/,""):"",hostname:a.hostname,port:a.port,pathname:a.pathname.charAt(0)==="/"?a.pathname:"/"+a.pathname}}return n=r(window.location.href),function(o){const s=utils.isString(o)?r(o):o;return s.protocol===n.protocol&&s.host===n.host}}():function(){return function(){return!0}}();function parseProtocol(t){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}function speedometer(t,e){t=t||10;const a=new Array(t),n=new Array(t);let r=0,i=0,o;return e=e!==void 0?e:1e3,function(l){const u=Date.now(),c=n[i];o||(o=u),a[r]=l,n[r]=u;let d=i,h=0;for(;d!==r;)h+=a[d++],d=d%t;if(r=(r+1)%t,r===i&&(i=(i+1)%t),u-o<e)return;const m=c&&u-c;return m?Math.round(h*1e3/m):void 0}}function progressEventReducer(t,e){let a=0;const n=speedometer(50,250);return r=>{const i=r.loaded,o=r.lengthComputable?r.total:void 0,s=i-a,l=n(s),u=i<=o;a=i;const c={loaded:i,total:o,progress:o?i/o:void 0,bytes:s,rate:l||void 0,estimated:l&&o&&u?(o-i)/l:void 0,event:r};c[e?"download":"upload"]=!0,t(c)}}const isXHRAdapterSupported=typeof XMLHttpRequest<"u",xhrAdapter=isXHRAdapterSupported&&function(t){return new Promise(function(a,n){let r=t.data;const i=AxiosHeaders$1.from(t.headers).normalize(),o=t.responseType;let s;function l(){t.cancelToken&&t.cancelToken.unsubscribe(s),t.signal&&t.signal.removeEventListener("abort",s)}utils.isFormData(r)&&(platform.isStandardBrowserEnv||platform.isStandardBrowserWebWorkerEnv?i.setContentType(!1):i.setContentType("multipart/form-d
2023-08-12 17:44:00 +02:00
`+gap+s.join(`,
`+gap)+`
`+o+"]":"["+s.join(",")+"]",gap=o,r}if(rep&&typeof rep=="object")for(i=rep.length,a=0;a<i;a+=1)typeof rep[a]=="string"&&(n=rep[a],r=str(n,l),r&&s.push(quote(n)+(gap?": ":":")+r));else for(n in l)Object.prototype.hasOwnProperty.call(l,n)&&(r=str(n,l),r&&s.push(quote(n)+(gap?": ":":")+r));return r=s.length===0?"{}":gap?`{
`+gap+s.join(`,
`+gap)+`
2023-08-29 07:34:41 +02:00
`+o+"}":"{"+s.join(",")+"}",gap=o,r}}typeof JSON.stringify!="function"&&(meta={"\b":"\\b"," ":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},JSON.stringify=function(t,e,a){var n;if(gap="",indent="",typeof a=="number")for(n=0;n<a;n+=1)indent+=" ";else typeof a=="string"&&(indent=a);if(rep=e,e&&typeof e!="function"&&(typeof e!="object"||typeof e.length!="number"))throw new Error("JSON.stringify");return str("",{"":t})}),typeof JSON.parse!="function"&&(JSON.parse=function(text,reviver){var j;function walk(t,e){var a,n,r=t[e];if(r&&typeof r=="object")for(a in r)Object.prototype.hasOwnProperty.call(r,a)&&(n=walk(r,a),n!==void 0?r[a]=n:delete r[a]);return reviver.call(t,e,r)}if(text=String(text),rx_dangerous.lastIndex=0,rx_dangerous.test(text)&&(text=text.replace(rx_dangerous,function(t){return"\\u"+("0000"+t.charCodeAt(0).toString(16)).slice(-4)})),rx_one.test(text.replace(rx_two,"@").replace(rx_three,"]").replace(rx_four,"")))return j=eval("("+text+")"),typeof reviver=="function"?walk({"":j},""):j;throw new SyntaxError("JSON.parse")})}()),json2$1}var json2=json2Plugin;function json2Plugin(){return requireJson2(),{}}var engine=storeEngine,storages=all,plugins=[json2],store_legacy=engine.createStore(storages,plugins);const store$1=getDefaultExportFromCjs(store_legacy);var util=util$7,bind$1=util.bind,each$1=util.each,create=util.create,slice=util.slice,events=eventsPlugin$1;function eventsPlugin$1(){var t=_newPubSub();return{watch:e,unwatch:a,once:n,set:r,remove:i,clearAll:o};function e(s,l,u){return t.on(l,bind$1(this,u))}function a(s,l){t.off(l)}function n(s,l,u){t.once(l,bind$1(this,u))}function r(s,l,u){var c=this.get(l);s(),t.fire(l,u,c)}function i(s,l){var u=this.get(l);s(),t.fire(l,void 0,u)}function o(s){var l={};this.each(function(u,c){l[c]=u}),s(),each$1(l,function(u,c){t.fire(c,void 0,u)})}}function _newPubSub(){return create(_pubSubBase,{_id:0,_subSignals:{},_subCallbacks:{}})}var _pubSubBase={_id:null,_subCallbacks:null,_subSignals:null,on:function(t,e){return this._subCallbacks[t]||(this._subCallbacks[t]={}),this._id+=1,this._subCallbacks[t][this._id]=e,this._subSignals[this._id]=t,this._id},off:function(t){var e=this._subSignals[t];delete this._subCallbacks[e][t],delete this._subSignals[t]},once:function(t,e){var a=this.on(t,bind$1(this,function(){e.apply(this,arguments),this.off(a)}))},fire:function(t){var e=slice(arguments,1);each$1(this._subCallbacks[t],function(a){a.apply(this,e)})}},eventsPlugin=events,observe=[eventsPlugin,observePlugin];function observePlugin(){return{observe:t,unobserve:e};function t(a,n,r){var i=this.watch(n,r);return r(this.get(n)),i}function e(a,n){this.unwatch(n)}}const observePlugin$1=getDefaultExportFromCjs(observe);var flushPending=!1,flushing=!1,queue=[],lastFlushedIndex=-1;function scheduler(t){queueJob(t)}function queueJob(t){queue.includes(t)||queue.push(t),queueFlush()}function dequeueJob(t){let e=queue.indexOf(t);e!==-1&&e>lastFlushedIndex&&queue.splice(e,1)}function queueFlush(){!flushing&&!flushPending&&(flushPending=!0,queueMicrotask(flushJobs))}function flushJobs(){flushPending=!1,flushing=!0;for(let t=0;t<queue.length;t++)queue[t](),lastFlushedIndex=t;queue.length=0,lastFlushedIndex=-1,flushing=!1}var reactive,effect$3,release,raw,shouldSchedule=!0;function disableEffectScheduling(t){shouldSchedule=!1,t(),shouldSchedule=!0}function setReactivityEngine(t){reactive=t.reactive,release=t.release,effect$3=e=>t.effect(e,{scheduler:a=>{shouldSchedule?scheduler(a):a()}}),raw=t.raw}function overrideEffect(t){effect$3=t}function elementBoundEffect(t){let e=()=>{};return[n=>{let r=effect$3(n);return t._x_effects||(t._x_effects=new Set,t._x_runEffects=()=>{t._x_effects.forEach(i=>i())}),t._x_effects.add(r),e=()=>{r!==void 0&&(t._x_effects.delete(r),release(r))},r},()=>{e()}]}function dispatch(t,e,a={}){t.dispatchEvent(new CustomEvent(e,{detail:a,bubbles:!0,composed:!0,cancelable:!0}))}function walk(t,e){if(typeof ShadowRoot=="function"&&t instanceof ShadowRoot){Array.from(t.children).forEach(r=>walk(r,e));return}let a=!1;if(e(t,()=>a=!0),a)return;let n=t.firstElemen
2023-08-12 17:44:00 +02:00
${a?'Expression: "'+a+`"
2023-10-07 07:20:01 +02:00
`:""}`,e),setTimeout(()=>{throw t},0)}var shouldAutoEvaluateFunctions=!0;function dontAutoEvaluateFunctions(t){let e=shouldAutoEvaluateFunctions;shouldAutoEvaluateFunctions=!1;let a=t();return shouldAutoEvaluateFunctions=e,a}function evaluate(t,e,a={}){let n;return evaluateLater(t,e)(r=>n=r,a),n}function evaluateLater(...t){return theEvaluatorFunction(...t)}var theEvaluatorFunction=normalEvaluator;function setEvaluator(t){theEvaluatorFunction=t}function normalEvaluator(t,e){let a={};injectMagics(a,t);let n=[a,...closestDataStack(t)],r=typeof e=="function"?generateEvaluatorFromFunction(n,e):generateEvaluatorFromString(n,e,t);return tryCatch.bind(null,t,e,r)}function generateEvaluatorFromFunction(t,e){return(a=()=>{},{scope:n={},params:r=[]}={})=>{let i=e.apply(mergeProxies([n,...t]),r);runIfTypeOfFunction(a,i)}}var evaluatorMemo={};function generateFunctionFromString(t,e){if(evaluatorMemo[t])return evaluatorMemo[t];let a=Object.getPrototypeOf(async function(){}).constructor,n=/^[\n\s]*if.*\(.*\)/.test(t.trim())||/^(let|const)\s/.test(t.trim())?`(async()=>{ ${t} })()`:t,i=(()=>{try{return new a(["__self","scope"],`with (scope) { __self.result = ${n} }; __self.finished = true; return __self.result;`)}catch(o){return handleError(o,e,t),Promise.resolve()}})();return evaluatorMemo[t]=i,i}function generateEvaluatorFromString(t,e,a){let n=generateFunctionFromString(e,a);return(r=()=>{},{scope:i={},params:o=[]}={})=>{n.result=void 0,n.finished=!1;let s=mergeProxies([i,...t]);if(typeof n=="function"){let l=n(n,s).catch(u=>handleError(u,a,e));n.finished?(runIfTypeOfFunction(r,n.result,s,o,a),n.result=void 0):l.then(u=>{runIfTypeOfFunction(r,u,s,o,a)}).catch(u=>handleError(u,a,e)).finally(()=>n.result=void 0)}}}function runIfTypeOfFunction(t,e,a,n,r){if(shouldAutoEvaluateFunctions&&typeof e=="function"){let i=e.apply(a,n);i instanceof Promise?i.then(o=>runIfTypeOfFunction(t,o,a,n)).catch(o=>handleError(o,r,e)):t(i)}else typeof e=="object"&&e instanceof Promise?e.then(i=>t(i)):t(e)}var prefixAsString="x-";function prefix(t=""){return prefixAsString+t}function setPrefix(t){prefixAsString=t}var directiveHandlers={};function directive(t,e){return directiveHandlers[t]=e,{before(a){if(!directiveHandlers[a]){console.warn("Cannot find directive `${directive}`. `${name}` will use the default order of execution");return}const n=directiveOrder.indexOf(a);directiveOrder.splice(n>=0?n:directiveOrder.indexOf("DEFAULT"),0,t)}}}function directives(t,e,a){if(e=Array.from(e),t._x_virtualDirectives){let i=Object.entries(t._x_virtualDirectives).map(([s,l])=>({name:s,value:l})),o=attributesOnly(i);i=i.map(s=>o.find(l=>l.name===s.name)?{name:`x-bind:${s.name}`,value:`"${s.value}"`}:s),e=e.concat(i)}let n={};return e.map(toTransformedAttributes((i,o)=>n[i]=o)).filter(outNonAlpineAttributes).map(toParsedDirectives(n,a)).sort(byPriority).map(i=>getDirectiveHandler(t,i))}function attributesOnly(t){return Array.from(t).map(toTransformedAttributes()).filter(e=>!outNonAlpineAttributes(e))}var isDeferringHandlers=!1,directiveHandlerStacks=new Map,currentHandlerStackKey=Symbol();function deferHandlingDirectives(t){isDeferringHandlers=!0;let e=Symbol();currentHandlerStackKey=e,directiveHandlerStacks.set(e,[]);let a=()=>{for(;directiveHandlerStacks.get(e).length;)directiveHandlerStacks.get(e).shift()();directiveHandlerStacks.delete(e)},n=()=>{isDeferringHandlers=!1,a()};t(a),n()}function getElementBoundUtilities(t){let e=[],a=s=>e.push(s),[n,r]=elementBoundEffect(t);return e.push(r),[{Alpine:alpine_default,effect:n,cleanup:a,evaluateLater:evaluateLater.bind(evaluateLater,t),evaluate:evaluate.bind(evaluate,t)},()=>e.forEach(s=>s())]}function getDirectiveHandler(t,e){let a=()=>{},n=directiveHandlers[e.type]||a,[r,i]=getElementBoundUtilities(t);onAttributeRemoved(t,e.original,i);let o=()=>{t._x_ignore||t._x_ignoreSelf||(n.inline&&n.inline(t,e,r),n=n.bind(n,t,e,r),isDeferringHandlers?directiveHandlerStacks.get(currentHandlerStackKey).push(n):n())};return o.runCleanups=i,o}var startingWith=(t,e)=>({name:a,value:n})=>(a.startsWith(t)&&(a=a.replace(t,e)),{name:a,value:n}
2023-09-15 19:54:56 +02:00
* Bootstrap v5.3.2 (https://getbootstrap.com/)
2023-08-12 17:44:00 +02:00
* Copyright 2011-2023 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors)
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
2023-10-07 07:20:01 +02:00
*/const elementMap=new Map,Data={set(t,e,a){elementMap.has(t)||elementMap.set(t,new Map);const n=elementMap.get(t);if(!n.has(e)&&n.size!==0){console.error(`Bootstrap doesn't allow more than one instance per element. Bound instance: ${Array.from(n.keys())[0]}.`);return}n.set(e,a)},get(t,e){return elementMap.has(t)&&elementMap.get(t).get(e)||null},remove(t,e){if(!elementMap.has(t))return;const a=elementMap.get(t);a.delete(e),a.size===0&&elementMap.delete(t)}},MAX_UID=1e6,MILLISECONDS_MULTIPLIER=1e3,TRANSITION_END="transitionend",parseSelector=t=>(t&&window.CSS&&window.CSS.escape&&(t=t.replace(/#([^\s"#']+)/g,(e,a)=>`#${CSS.escape(a)}`)),t),toType=t=>t==null?`${t}`:Object.prototype.toString.call(t).match(/\s([a-z]+)/i)[1].toLowerCase(),getUID=t=>{do t+=Math.floor(Math.random()*MAX_UID);while(document.getElementById(t));return t},getTransitionDurationFromElement=t=>{if(!t)return 0;let{transitionDuration:e,transitionDelay:a}=window.getComputedStyle(t);const n=Number.parseFloat(e),r=Number.parseFloat(a);return!n&&!r?0:(e=e.split(",")[0],a=a.split(",")[0],(Number.parseFloat(e)+Number.parseFloat(a))*MILLISECONDS_MULTIPLIER)},triggerTransitionEnd=t=>{t.dispatchEvent(new Event(TRANSITION_END))},isElement=t=>!t||typeof t!="object"?!1:(typeof t.jquery<"u"&&(t=t[0]),typeof t.nodeType<"u"),getElement=t=>isElement(t)?t.jquery?t[0]:t:typeof t=="string"&&t.length>0?document.querySelector(parseSelector(t)):null,isVisible=t=>{if(!isElement(t)||t.getClientRects().length===0)return!1;const e=getComputedStyle(t).getPropertyValue("visibility")==="visible",a=t.closest("details:not([open])");if(!a)return e;if(a!==t){const n=t.closest("summary");if(n&&n.parentNode!==a||n===null)return!1}return e},isDisabled=t=>!t||t.nodeType!==Node.ELEMENT_NODE||t.classList.contains("disabled")?!0:typeof t.disabled<"u"?t.disabled:t.hasAttribute("disabled")&&t.getAttribute("disabled")!=="false",findShadowRoot=t=>{if(!document.documentElement.attachShadow)return null;if(typeof t.getRootNode=="function"){const e=t.getRootNode();return e instanceof ShadowRoot?e:null}return t instanceof ShadowRoot?t:t.parentNode?findShadowRoot(t.parentNode):null},noop$3=()=>{},reflow=t=>{t.offsetHeight},getjQuery=()=>window.jQuery&&!document.body.hasAttribute("data-bs-no-jquery")?window.jQuery:null,DOMContentLoadedCallbacks=[],onDOMContentLoaded=t=>{document.readyState==="loading"?(DOMContentLoadedCallbacks.length||document.addEventListener("DOMContentLoaded",()=>{for(const e of DOMContentLoadedCallbacks)e()}),DOMContentLoadedCallbacks.push(t)):t()},isRTL=()=>document.documentElement.dir==="rtl",defineJQueryPlugin=t=>{onDOMContentLoaded(()=>{const e=getjQuery();if(e){const a=t.NAME,n=e.fn[a];e.fn[a]=t.jQueryInterface,e.fn[a].Constructor=t,e.fn[a].noConflict=()=>(e.fn[a]=n,t.jQueryInterface)}})},execute=(t,e=[],a=t)=>typeof t=="function"?t(...e):a,executeAfterTransition=(t,e,a=!0)=>{if(!a){execute(t);return}const n=5,r=getTransitionDurationFromElement(e)+n;let i=!1;const o=({target:s})=>{s===e&&(i=!0,e.removeEventListener(TRANSITION_END,o),execute(t))};e.addEventListener(TRANSITION_END,o),setTimeout(()=>{i||triggerTransitionEnd(e)},r)},getNextActiveElement=(t,e,a,n)=>{const r=t.length;let i=t.indexOf(e);return i===-1?!a&&n?t[r-1]:t[0]:(i+=a?1:-1,n&&(i=(i+r)%r),t[Math.max(0,Math.min(i,r-1))])},namespaceRegex=/[^.]*(?=\..*)\.|.*/,stripNameRegex=/\..*/,stripUidRegex=/::\d+$/,eventRegistry={};let uidEvent=1;const customEvents={mouseenter:"mouseover",mouseleave:"mouseout"},nativeEvents=new Set(["click","dblclick","mouseup","mousedown","contextmenu","mousewheel","DOMMouseScroll","mouseover","mouseout","mousemove","selectstart","selectend","keydown","keypress","keyup","orientationchange","touchstart","touchmove","touchend","touchcancel","pointerdown","pointermove","pointerup","pointerleave","pointercancel","gesturestart","gesturechange","gestureend","focus","blur","change","reset","select","submit","focusin","focusout","load","unload","beforeunload","resize","move","DOMContentLoaded","readystatechange","error","abort","scroll"]);function makeEventUid(t,e){return e&&`${e}::${uidEvent++}`||t
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var i=!0,o=!1,s;return{s:function(){a=a.call(t)},n:function(){var u=a.next();return i=u.done,u},e:function(u){o=!0,s=u},f:function(){try{!i&&a.return!=null&&a.return()}finally{if(o)throw s}}}}function _assertThisInitialized(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function _setPrototypeOf(t,e){return _setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,r){return n.__proto__=r,n},_setPrototypeOf(t,e)}function _inherits(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&_setPrototypeOf(t,e)}function _getPrototypeOf(t){return _getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(a){return a.__proto__||Object.getPrototypeOf(a)},_getPrototypeOf(t)}function _isNativeReflectConstruct(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function _possibleConstructorReturn(t,e){if(e&&(_typeof(e)==="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return _assertThisInitialized(t)}function _createSuper(t){var e=_isNativeReflectConstruct();return function(){var n=_getPrototypeOf(t),r;if(e){var i=_getPrototypeOf(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return _possibleConstructorReturn(this,r)}}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _toPrimitive(t,e){if(_typeof(t)!=="object"||t===null)return t;var a=t[Symbol.toPrimitive];if(a!==void 0){var n=a.call(t,e||"default");if(_typeof(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function _toPropertyKey(t){var e=_toPrimitive(t,"string");return _typeof(e)==="symbol"?e:String(e)}function _defineProperties(t,e){for(var a=0;a<e.length;a++){var n=e[a];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,_toPropertyKey(n.key),n)}}function _createClass(t,e,a){return e&&_defineProperties(t.prototype,e),a&&_defineProperties(t,a),Object.defineProperty(t,"prototype",{writable:!1}),t}function _defineProperty$1(t,e,a){return e=_toPropertyKey(e),e in t?Object.defineProperty(t,e,{value:a,enumerable:!0,configurable:!0,writable:!0}):t[e]=a,t}var TIMEZONE_UNIT_PRIORITY=10,Setter=function(){function t(){_classCallCheck(this,t),_defineProperty$1(this,"priority",void 0),_defineProperty$1(this,"subPriority",0)}return _createClass(t,[{key:"validate",value:function(a,n){return!0}}]),t}(),ValueSetter=function(t){_inherits(a,t);var e=_createSuper(a);function a(n,r,i,o,s){var l;return _classCallCheck(this,a),l=e.call(this),l.value=n,l.validateValue=r,l.setValue=i,l.priority=o,s&&(l.subPriority=s),l}return _createClass(a,[{key:"validate",value:function(r,i){return this.validateValue(r,this.value,i)}},{key:"set",value:function(r,i,o){return this.setValue(r,i,this.value,o)}}]),a}(Setter),DateToSystemTimezoneSetter=function(t){_inherits(a,t);var e=_createSuper(a);function a(){var n;_classCallCheck(this,a);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return n=e.call.apply(e,[this].concat(i)),_defineProperty$1(_assertThisInitialized(n),"priority",TIMEZONE_UNIT_PRIORITY),_defineProperty$1(_assertThisInitialized(n),"subPriority",-1),n}return _createClass(a,[{key:"set",value:function(r,i){if(i.timestampIsSet)return r;var o=new Date(0);return o.setFullYear(r.getUTCFullYear(),r.getUTCMonth(),r.getUTCDate()),o.setHours(r.getUTCHours(),r.getUTCMinutes(),r.getUTCSeconds(),r.getUTCMilliseconds()),o}}]),a}(Set
2023-08-12 17:44:00 +02:00
* @kurkle/color v0.3.2
* https://github.com/kurkle/color#readme
* (c) 2023 Jukka Kurkela
* Released under the MIT License
*/function round(t){return t+.5|0}const lim=(t,e,a)=>Math.max(Math.min(t,a),e);function p2b(t){return lim(round(t*2.55),0,255)}function n2b(t){return lim(round(t*255),0,255)}function b2n(t){return lim(round(t/2.55)/100,0,1)}function n2p(t){return lim(round(t*100),0,100)}const map$1={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,a:10,b:11,c:12,d:13,e:14,f:15},hex=[..."0123456789ABCDEF"],h1=t=>hex[t&15],h2=t=>hex[(t&240)>>4]+hex[t&15],eq$5=t=>(t&240)>>4===(t&15),isShort=t=>eq$5(t.r)&&eq$5(t.g)&&eq$5(t.b)&&eq$5(t.a);function hexParse(t){var e=t.length,a;return t[0]==="#"&&(e===4||e===5?a={r:255&map$1[t[1]]*17,g:255&map$1[t[2]]*17,b:255&map$1[t[3]]*17,a:e===5?map$1[t[4]]*17:255}:(e===7||e===9)&&(a={r:map$1[t[1]]<<4|map$1[t[2]],g:map$1[t[3]]<<4|map$1[t[4]],b:map$1[t[5]]<<4|map$1[t[6]],a:e===9?map$1[t[7]]<<4|map$1[t[8]]:255})),a}const alpha=(t,e)=>t<255?e(t):"";function hexString(t){var e=isShort(t)?h1:h2;return t?"#"+e(t.r)+e(t.g)+e(t.b)+alpha(t.a,e):void 0}const HUE_RE=/^(hsla?|hwb|hsv)\(\s*([-+.e\d]+)(?:deg)?[\s,]+([-+.e\d]+)%[\s,]+([-+.e\d]+)%(?:[\s,]+([-+.e\d]+)(%)?)?\s*\)$/;function hsl2rgbn(t,e,a){const n=e*Math.min(a,1-a),r=(i,o=(i+t/30)%12)=>a-n*Math.max(Math.min(o-3,9-o,1),-1);return[r(0),r(8),r(4)]}function hsv2rgbn(t,e,a){const n=(r,i=(r+t/60)%6)=>a-a*e*Math.max(Math.min(i,4-i,1),0);return[n(5),n(3),n(1)]}function hwb2rgbn(t,e,a){const n=hsl2rgbn(t,1,.5);let r;for(e+a>1&&(r=1/(e+a),e*=r,a*=r),r=0;r<3;r++)n[r]*=1-e-a,n[r]+=e;return n}function hueValue(t,e,a,n,r){return t===r?(e-a)/n+(e<a?6:0):e===r?(a-t)/n+2:(t-e)/n+4}function rgb2hsl(t){const a=t.r/255,n=t.g/255,r=t.b/255,i=Math.max(a,n,r),o=Math.min(a,n,r),s=(i+o)/2;let l,u,c;return i!==o&&(c=i-o,u=s>.5?c/(2-i-o):c/(i+o),l=hueValue(a,n,r,c,i),l=l*60+.5),[l|0,u||0,s]}function calln(t,e,a,n){return(Array.isArray(e)?t(e[0],e[1],e[2]):t(e,a,n)).map(n2b)}function hsl2rgb(t,e,a){return calln(hsl2rgbn,t,e,a)}function hwb2rgb(t,e,a){return calln(hwb2rgbn,t,e,a)}function hsv2rgb(t,e,a){return calln(hsv2rgbn,t,e,a)}function hue(t){return(t%360+360)%360}function hueParse(t){const e=HUE_RE.exec(t);let a=255,n;if(!e)return;e[5]!==n&&(a=e[6]?p2b(+e[5]):n2b(+e[5]));const r=hue(+e[2]),i=+e[3]/100,o=+e[4]/100;return e[1]==="hwb"?n=hwb2rgb(r,i,o):e[1]==="hsv"?n=hsv2rgb(r,i,o):n=hsl2rgb(r,i,o),{r:n[0],g:n[1],b:n[2],a}}function rotate(t,e){var a=rgb2hsl(t);a[0]=hue(a[0]+e),a=hsl2rgb(a),t.r=a[0],t.g=a[1],t.b=a[2]}function hslString(t){if(!t)return;const e=rgb2hsl(t),a=e[0],n=n2p(e[1]),r=n2p(e[2]);return t.a<255?`hsla(${a}, ${n}%, ${r}%, ${b2n(t.a)})`:`hsl(${a}, ${n}%, ${r}%)`}const map={x:"dark",Z:"light",Y:"re",X:"blu",W:"gr",V:"medium",U:"slate",A:"ee",T:"ol",S:"or",B:"ra",C:"lateg",D:"ights",R:"in",Q:"turquois",E:"hi",P:"ro",O:"al",N:"le",M:"de",L:"yello",F:"en",K:"ch",G:"arks",H:"ea",I:"ightg",J:"wh"},names$1={OiceXe:"f0f8ff",antiquewEte:"faebd7",aqua:"ffff",aquamarRe:"7fffd4",azuY:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"0",blanKedOmond:"ffebcd",Xe:"ff",XeviTet:"8a2be2",bPwn:"a52a2a",burlywood:"deb887",caMtXe:"5f9ea0",KartYuse:"7fff00",KocTate:"d2691e",cSO:"ff7f50",cSnflowerXe:"6495ed",cSnsilk:"fff8dc",crimson:"dc143c",cyan:"ffff",xXe:"8b",xcyan:"8b8b",xgTMnPd:"b8860b",xWay:"a9a9a9",xgYF:"6400",xgYy:"a9a9a9",xkhaki:"bdb76b",xmagFta:"8b008b",xTivegYF:"556b2f",xSange:"ff8c00",xScEd:"9932cc",xYd:"8b0000",xsOmon:"e9967a",xsHgYF:"8fbc8f",xUXe:"483d8b",xUWay:"2f4f4f",xUgYy:"2f4f4f",xQe:"ced1",xviTet:"9400d3",dAppRk:"ff1493",dApskyXe:"bfff",dimWay:"696969",dimgYy:"696969",dodgerXe:"1e90ff",fiYbrick:"b22222",flSOwEte:"fffaf0",foYstWAn:"228b22",fuKsia:"ff00ff",gaRsbSo:"dcdcdc",ghostwEte:"f8f8ff",gTd:"ffd700",gTMnPd:"daa520",Way:"808080",gYF:"8000",gYFLw:"adff2f",gYy:"808080",honeyMw:"f0fff0",hotpRk:"ff69b4",RdianYd:"cd5c5c",Rdigo:"4b0082",ivSy:"fffff0",khaki:"f0e68c",lavFMr:"e6e6fa",lavFMrXsh:"fff0f5",lawngYF:"7cfc00",NmoncEffon:"fffacd",ZXe:"add8e6",ZcSO:"f08080",Zcyan:"e0ffff",ZgTMnPdLw:"fafad2",ZWay:"d3d3d3",ZgYF:"90ee90",ZgYy:"d3d3d3",ZpRk:"ffb6c1",ZsOmon:"ffa07a",ZsHgYF:"20b2aa",ZskyXe:"87cefa",ZUWay:"778899",ZUgYy:"778899",ZstAlXe:"b0c4de",ZLw:"ffffe0
2023-08-29 07:34:41 +02:00
* Chart.js v4.4.0
2023-08-12 17:44:00 +02:00
* https://www.chartjs.org
* (c) 2023 Chart.js Contributors
* Released under the MIT License
2023-10-01 07:17:56 +02:00
*/function noop$2(){}const uid=(()=>{let t=0;return()=>t++})();function isNullOrUndef(t){return t===null||typeof t>"u"}function isArray$b(t){if(Array.isArray&&Array.isArray(t))return!0;const e=Object.prototype.toString.call(t);return e.slice(0,7)==="[object"&&e.slice(-6)==="Array]"}function isObject$8(t){return t!==null&&Object.prototype.toString.call(t)==="[object Object]"}function isNumberFinite(t){return(typeof t=="number"||t instanceof Number)&&isFinite(+t)}function finiteOrDefault(t,e){return isNumberFinite(t)?t:e}function valueOrDefault(t,e){return typeof t>"u"?e:t}const toPercentage=(t,e)=>typeof t=="string"&&t.endsWith("%")?parseFloat(t)/100:+t/e,toDimension=(t,e)=>typeof t=="string"&&t.endsWith("%")?parseFloat(t)/100*e:+t;function callback(t,e,a){if(t&&typeof t.call=="function")return t.apply(a,e)}function each(t,e,a,n){let r,i,o;if(isArray$b(t))if(i=t.length,n)for(r=i-1;r>=0;r--)e.call(a,t[r],r);else for(r=0;r<i;r++)e.call(a,t[r],r);else if(isObject$8(t))for(o=Object.keys(t),i=o.length,r=0;r<i;r++)e.call(a,t[o[r]],o[r])}function _elementsEqual(t,e){let a,n,r,i;if(!t||!e||t.length!==e.length)return!1;for(a=0,n=t.length;a<n;++a)if(r=t[a],i=e[a],r.datasetIndex!==i.datasetIndex||r.index!==i.index)return!1;return!0}function clone$1(t){if(isArray$b(t))return t.map(clone$1);if(isObject$8(t)){const e=Object.create(null),a=Object.keys(t),n=a.length;let r=0;for(;r<n;++r)e[a[r]]=clone$1(t[a[r]]);return e}return t}function isValidKey(t){return["__proto__","prototype","constructor"].indexOf(t)===-1}function _merger(t,e,a,n){if(!isValidKey(t))return;const r=e[t],i=a[t];isObject$8(r)&&isObject$8(i)?merge(r,i,n):e[t]=clone$1(i)}function merge(t,e,a){const n=isArray$b(e)?e:[e],r=n.length;if(!isObject$8(t))return t;a=a||{};const i=a.merger||_merger;let o;for(let s=0;s<r;++s){if(o=n[s],!isObject$8(o))continue;const l=Object.keys(o);for(let u=0,c=l.length;u<c;++u)i(l[u],t,o,a)}return t}function mergeIf(t,e){return merge(t,e,{merger:_mergerIf})}function _mergerIf(t,e,a){if(!isValidKey(t))return;const n=e[t],r=a[t];isObject$8(n)&&isObject$8(r)?mergeIf(n,r):Object.prototype.hasOwnProperty.call(e,t)||(e[t]=clone$1(r))}const keyResolvers={"":t=>t,x:t=>t.x,y:t=>t.y};function _splitKey(t){const e=t.split("."),a=[];let n="";for(const r of e)n+=r,n.endsWith("\\")?n=n.slice(0,-1)+".":(a.push(n),n="");return a}function _getKeyResolver(t){const e=_splitKey(t);return a=>{for(const n of e){if(n==="")break;a=a&&a[n]}return a}}function resolveObjectKey(t,e){return(keyResolvers[e]||(keyResolvers[e]=_getKeyResolver(e)))(t)}function _capitalize(t){return t.charAt(0).toUpperCase()+t.slice(1)}const defined$1=t=>typeof t<"u",isFunction$3=t=>typeof t=="function",setsEqual=(t,e)=>{if(t.size!==e.size)return!1;for(const a of t)if(!e.has(a))return!1;return!0};function _isClickEvent(t){return t.type==="mouseup"||t.type==="click"||t.type==="contextmenu"}const PI=Math.PI,TAU=2*PI,PITAU=TAU+PI,INFINITY$5=Number.POSITIVE_INFINITY,RAD_PER_DEG=PI/180,HALF_PI=PI/2,QUARTER_PI=PI/4,TWO_THIRDS_PI=PI*2/3,log10=Math.log10,sign=Math.sign;function almostEquals(t,e,a){return Math.abs(t-e)<a}function niceNum(t){const e=Math.round(t);t=almostEquals(t,e,t/1e3)?e:t;const a=Math.pow(10,Math.floor(log10(t))),n=t/a;return(n<=1?1:n<=2?2:n<=5?5:10)*a}function _factorize(t){const e=[],a=Math.sqrt(t);let n;for(n=1;n<a;n++)t%n===0&&(e.push(n),e.push(t/n));return a===(a|0)&&e.push(a),e.sort((r,i)=>r-i).pop(),e}function isNumber(t){return!isNaN(parseFloat(t))&&isFinite(t)}function almostWhole(t,e){const a=Math.round(t);return a-e<=t&&a+e>=t}function _setMinAndMaxByKey(t,e,a){let n,r,i;for(n=0,r=t.length;n<r;n++)i=t[n][a],isNaN(i)||(e.min=Math.min(e.min,i),e.max=Math.max(e.max,i))}function toRadians(t){return t*(PI/180)}function toDegrees(t){return t*(180/PI)}function _decimalPlaces(t){if(!isNumberFinite(t))return;let e=1,a=0;for(;Math.round(t*e)/e!==t;)e*=10,a++;return a}function getAngleFromPoint(t,e){const a=e.x-t.x,n=e.y-t.y,r=Math.sqrt(a*a+n*n);let i=Math.atan2(n,a);return i<-.5*PI&&(i+=TAU),{angle:i,distance:r}}function distanceBetweenPoints(t,e){return Math.sqrt(Math.pow(e.x-t.x
2023-08-29 07:34:41 +02:00
* Chart.js v4.4.0
2023-08-12 17:44:00 +02:00
* https://www.chartjs.org
* (c) 2023 Chart.js Contributors
* Released under the MIT License
2023-10-07 07:20:01 +02:00
*/class Animator{constructor(){this._request=null,this._charts=new Map,this._running=!1,this._lastDate=void 0}_notify(e,a,n,r){const i=a.listeners[r],o=a.duration;i.forEach(s=>s({chart:e,initial:a.initial,numSteps:o,currentStep:Math.min(n-a.start,o)}))}_refresh(){this._request||(this._running=!0,this._request=requestAnimFrame.call(window,()=>{this._update(),this._request=null,this._running&&this._refresh()}))}_update(e=Date.now()){let a=0;this._charts.forEach((n,r)=>{if(!n.running||!n.items.length)return;const i=n.items;let o=i.length-1,s=!1,l;for(;o>=0;--o)l=i[o],l._active?(l._total>n.duration&&(n.duration=l._total),l.tick(e),s=!0):(i[o]=i[i.length-1],i.pop());s&&(r.draw(),this._notify(r,n,e,"progress")),i.length||(n.running=!1,this._notify(r,n,e,"complete"),n.initial=!1),a+=i.length}),this._lastDate=e,a===0&&(this._running=!1)}_getAnims(e){const a=this._charts;let n=a.get(e);return n||(n={running:!1,initial:!0,items:[],listeners:{complete:[],progress:[]}},a.set(e,n)),n}listen(e,a,n){this._getAnims(e).listeners[a].push(n)}add(e,a){!a||!a.length||this._getAnims(e).items.push(...a)}has(e){return this._getAnims(e).items.length>0}start(e){const a=this._charts.get(e);a&&(a.running=!0,a.start=Date.now(),a.duration=a.items.reduce((n,r)=>Math.max(n,r._duration),0),this._refresh())}running(e){if(!this._running)return!1;const a=this._charts.get(e);return!(!a||!a.running||!a.items.length)}stop(e){const a=this._charts.get(e);if(!a||!a.items.length)return;const n=a.items;let r=n.length-1;for(;r>=0;--r)n[r].cancel();a.items=[],this._notify(e,a,Date.now(),"complete")}remove(e){return this._charts.delete(e)}}var animator=new Animator;const transparent="transparent",interpolators={boolean(t,e,a){return a>.5?e:t},color(t,e,a){const n=color(t||transparent),r=n.valid&&color(e||transparent);return r&&r.valid?r.mix(n,a).hexString():e},number(t,e,a){return t+(e-t)*a}};class Animation{constructor(e,a,n,r){const i=a[n];r=resolve([e.to,r,i,e.from]);const o=resolve([e.from,i,r]);this._active=!0,this._fn=e.fn||interpolators[e.type||typeof o],this._easing=effects[e.easing]||effects.linear,this._start=Math.floor(Date.now()+(e.delay||0)),this._duration=this._total=Math.floor(e.duration),this._loop=!!e.loop,this._target=a,this._prop=n,this._from=o,this._to=r,this._promises=void 0}active(){return this._active}update(e,a,n){if(this._active){this._notify(!1);const r=this._target[this._prop],i=n-this._start,o=this._duration-i;this._start=n,this._duration=Math.floor(Math.max(o,e.duration)),this._total+=i,this._loop=!!e.loop,this._to=resolve([e.to,a,r,e.from]),this._from=resolve([e.from,r,a])}}cancel(){this._active&&(this.tick(Date.now()),this._active=!1,this._notify(!1))}tick(e){const a=e-this._start,n=this._duration,r=this._prop,i=this._from,o=this._loop,s=this._to;let l;if(this._active=i!==s&&(o||a<n),!this._active){this._target[r]=s,this._notify(!0);return}if(a<0){this._target[r]=i;return}l=a/n%2,l=o&&l>1?2-l:l,l=this._easing(Math.min(1,Math.max(0,l))),this._target[r]=this._fn(i,s,l)}wait(){const e=this._promises||(this._promises=[]);return new Promise((a,n)=>{e.push({res:a,rej:n})})}_notify(e){const a=e?"res":"rej",n=this._promises||[];for(let r=0;r<n.length;r++)n[r][a]()}}class Animations{constructor(e,a){this._chart=e,this._properties=new Map,this.configure(a)}configure(e){if(!isObject$8(e))return;const a=Object.keys(defaults.animation),n=this._properties;Object.getOwnPropertyNames(e).forEach(r=>{const i=e[r];if(!isObject$8(i))return;const o={};for(const s of a)o[s]=i[s];(isArray$b(i.properties)&&i.properties||[r]).forEach(s=>{(s===r||!n.has(s))&&n.set(s,o)})})}_animateOptions(e,a){const n=a.options,r=resolveTargetOptions(e,n);if(!r)return[];const i=this._createAnimations(r,n);return n.$shared&&awaitAll(e.options.$animations,n).then(()=>{e.options=n},()=>{}),i}_createAnimations(e,a){const n=this._properties,r=[],i=e.$animations||(e.$animations={}),o=Object.keys(a),s=Date.now();let l;for(l=o.length-1;l>=0;--l){const u=o[l];if(u.charAt(0)==="$")continue;if(u==="options"){r.push(...this._animateOptions(e,a));continue}const c=a[u];let d=i[u];const h=n.
2023-08-12 17:44:00 +02:00
`)>-1?t.split(`
2023-10-07 07:20:01 +02:00
`):t}function createTooltipItem(t,e){const{element:a,datasetIndex:n,index:r}=e,i=t.getDatasetMeta(n).controller,{label:o,value:s}=i.getLabelAndValue(r);return{chart:t,label:o,parsed:i.getParsed(r),raw:t.data.datasets[n].data[r],formattedValue:s,dataset:i.getDataset(),dataIndex:r,datasetIndex:n,element:a}}function getTooltipSize(t,e){const a=t.chart.ctx,{body:n,footer:r,title:i}=t,{boxWidth:o,boxHeight:s}=e,l=toFont(e.bodyFont),u=toFont(e.titleFont),c=toFont(e.footerFont),d=i.length,h=r.length,m=n.length,p=toPadding(e.padding);let v=p.height,y=0,w=n.reduce((O,k)=>O+k.before.length+k.lines.length+k.after.length,0);if(w+=t.beforeBody.length+t.afterBody.length,d&&(v+=d*u.lineHeight+(d-1)*e.titleSpacing+e.titleMarginBottom),w){const O=e.displayColors?Math.max(s,l.lineHeight):l.lineHeight;v+=m*O+(w-m)*l.lineHeight+(w-1)*e.bodySpacing}h&&(v+=e.footerMarginTop+h*c.lineHeight+(h-1)*e.footerSpacing);let _=0;const C=function(O){y=Math.max(y,a.measureText(O).width+_)};return a.save(),a.font=u.string,each(t.title,C),a.font=l.string,each(t.beforeBody.concat(t.afterBody),C),_=e.displayColors?o+2+e.boxPadding:0,each(n,O=>{each(O.before,C),each(O.lines,C),each(O.after,C)}),_=0,a.font=c.string,each(t.footer,C),a.restore(),y+=p.width,{width:y,height:v}}function determineYAlign(t,e){const{y:a,height:n}=e;return a<n/2?"top":a>t.height-n/2?"bottom":"center"}function doesNotFitWithAlign(t,e,a,n){const{x:r,width:i}=n,o=a.caretSize+a.caretPadding;if(t==="left"&&r+i+o>e.width||t==="right"&&r-i-o<0)return!0}function determineXAlign(t,e,a,n){const{x:r,width:i}=a,{width:o,chartArea:{left:s,right:l}}=t;let u="center";return n==="center"?u=r<=(s+l)/2?"left":"right":r<=i/2?u="left":r>=o-i/2&&(u="right"),doesNotFitWithAlign(u,t,e,a)&&(u="center"),u}function determineAlignment(t,e,a){const n=a.yAlign||e.yAlign||determineYAlign(t,a);return{xAlign:a.xAlign||e.xAlign||determineXAlign(t,e,a,n),yAlign:n}}function alignX(t,e){let{x:a,width:n}=t;return e==="right"?a-=n:e==="center"&&(a-=n/2),a}function alignY(t,e,a){let{y:n,height:r}=t;return e==="top"?n+=a:e==="bottom"?n-=r+a:n-=r/2,n}function getBackgroundPoint(t,e,a,n){const{caretSize:r,caretPadding:i,cornerRadius:o}=t,{xAlign:s,yAlign:l}=a,u=r+i,{topLeft:c,topRight:d,bottomLeft:h,bottomRight:m}=toTRBLCorners(o);let p=alignX(e,s);const v=alignY(e,l,u);return l==="center"?s==="left"?p+=u:s==="right"&&(p-=u):s==="left"?p-=Math.max(c,h)+r:s==="right"&&(p+=Math.max(d,m)+r),{x:_limitValue(p,0,n.width-e.width),y:_limitValue(v,0,n.height-e.height)}}function getAlignedX(t,e,a){const n=toPadding(a.padding);return e==="center"?t.x+t.width/2:e==="right"?t.x+t.width-n.right:t.x+n.left}function getBeforeAfterBodyLines(t){return pushOrConcat([],splitNewlines(t))}function createTooltipContext(t,e,a){return createContext(t,{tooltip:e,tooltipItems:a,type:"tooltip"})}function overrideCallbacks(t,e){const a=e&&e.dataset&&e.dataset.tooltip&&e.dataset.tooltip.callbacks;return a?t.override(a):t}const defaultCallbacks={beforeTitle:noop$2,title(t){if(t.length>0){const e=t[0],a=e.chart.data.labels,n=a?a.length:0;if(this&&this.options&&this.options.mode==="dataset")return e.dataset.label||"";if(e.label)return e.label;if(n>0&&e.dataIndex<n)return a[e.dataIndex]}return""},afterTitle:noop$2,beforeBody:noop$2,beforeLabel:noop$2,label(t){if(this&&this.options&&this.options.mode==="dataset")return t.label+": "+t.formattedValue||t.formattedValue;let e=t.dataset.label||"";e&&(e+=": ");const a=t.formattedValue;return isNullOrUndef(a)||(e+=a),e},labelColor(t){const a=t.chart.getDatasetMeta(t.datasetIndex).controller.getStyle(t.dataIndex);return{borderColor:a.borderColor,backgroundColor:a.backgroundColor,borderWidth:a.borderWidth,borderDash:a.borderDash,borderDashOffset:a.borderDashOffset,borderRadius:0}},labelTextColor(){return this.options.bodyColor},labelPointStyle(t){const a=t.chart.getDatasetMeta(t.datasetIndex).controller.getStyle(t.dataIndex);return{pointStyle:a.pointStyle,rotation:a.rotation}},afterLabel:noop$2,afterBody:noop$2,beforeFooter:noop$2,footer:noop$2,afterFooter:noop$2};function invokeCallbackWithFallback(t,e,a,n){const r=t[
2023-08-12 17:44:00 +02:00
* chartjs-chart-sankey v0.12.0
* https://github.com/kurkle/chartjs-chart-sankey#readme
* (c) 2022 Jukka Kurkela
* Released under the MIT license
2023-09-15 19:54:56 +02:00
*/function toTextLines(t){const e=[],a=isArray$b(t)?t:isNullOrUndef(t)?[]:[t];for(;a.length;){const n=a.pop();typeof n=="string"?e.unshift.apply(e,n.split(`
2023-10-07 07:20:01 +02:00
`)):Array.isArray(n)?a.push.apply(a,n):isNullOrUndef(a)||e.unshift(""+n)}return e}function validateSizeValue(t){return!t||["min","max"].indexOf(t)===-1?"max":t}const defined=t=>t!==void 0;function calculateX(t,e){const a=new Set(e.map(o=>o.to)),n=new Set(e.map(o=>o.from)),r=new Set([...t.keys()]);let i=0;for(;r.size;){const o=nextColumn([...r],a);for(const s of o){const l=t.get(s);defined(l.x)||(l.x=i),r.delete(s)}r.size&&(a.clear(),e.filter(s=>r.has(s.from)).forEach(s=>a.add(s.to)),i++)}return[...t.keys()].filter(o=>!n.has(o)).forEach(o=>{const s=t.get(o);s.column||(s.x=i)}),i}function nextColumn(t,e){const a=t.filter(n=>!e.has(n));return a.length?a:t.slice(0,1)}const nodeByXY=(t,e)=>t.x!==e.x?t.x-e.x:t.y-e.y;let prevCountId=-1;function getCountId(){return prevCountId=prevCountId<100?prevCountId+1:0,prevCountId}function nodeCount(t,e,a=getCountId()){let n=0;for(const r of t)r.node._visited!==a&&(r.node._visited=a,n+=r.node[e].length+nodeCount(r.node[e],e,a));return n}const flowByNodeCount=t=>(e,a)=>nodeCount(e.node[t],t)-nodeCount(a.node[t],t)||e.node[t].length-a.node[t].length;function processFrom(t,e){t.from.sort(flowByNodeCount("from"));for(const a of t.from){const n=a.node;defined(n.y)||(n.y=e,processFrom(n,e)),e=Math.max(n.y+n.out,e)}return e}function processTo(t,e){t.to.sort(flowByNodeCount("to"));for(const a of t.to){const n=a.node;defined(n.y)||(n.y=e,processTo(n,e)),e=Math.max(n.y+n.in,e)}return e}function setOrGetY(t,e){return defined(t.y)?t.y:(t.y=e,e)}function processRest(t,e){const a=t.filter(c=>c.x===0),n=t.filter(c=>c.x===e),r=a.filter(c=>!defined(c.y)),i=n.filter(c=>!defined(c.y)),o=t.filter(c=>c.x>0&&c.x<e&&!defined(c.y));let s=a.reduce((c,d)=>Math.max(c,d.y+d.out||0),0),l=n.reduce((c,d)=>Math.max(c,d.y+d.in||0),0),u=0;return s>=l?(r.forEach(c=>{s=setOrGetY(c,s),s=Math.max(s+c.out,processTo(c,s))}),i.forEach(c=>{l=setOrGetY(c,l),l=Math.max(l+c.in,processTo(c,l))})):(i.forEach(c=>{l=setOrGetY(c,l),l=Math.max(l+c.in,processTo(c,l))}),r.forEach(c=>{s=setOrGetY(c,s),s=Math.max(s+c.out,processTo(c,s))})),o.forEach(c=>{let d=t.filter(h=>h.x===c.x&&defined(h.y)).reduce((h,m)=>Math.max(h,m.y+Math.max(m.in,m.out)),0);d=setOrGetY(c,d),d=Math.max(d+c.in,processFrom(c,d)),d=Math.max(d+c.out,processTo(c,d)),u=Math.max(u,d)}),Math.max(s,l,u)}function calculateY(t,e){t.sort((o,s)=>Math.max(s.in,s.out)-Math.max(o.in,o.out));const a=t[0];a.y=0;const n=processFrom(a,0),r=processTo(a,0),i=processRest(t,e);return Math.max(n,r,i)}function calculateYUsingPriority(t,e){let a=0,n=0;for(let r=0;r<=e;r++){let i=n;const o=t.filter(s=>s.x===r).sort((s,l)=>s.priority-l.priority);n=o[0].to.filter(s=>s.node.x>r+1).reduce((s,l)=>s+l.flow,0)||0;for(const s of o)s.y=i,i+=Math.max(s.out,s.in);a=Math.max(i,a)}return a}function addPadding(t,e){let a=1,n=0,r=0,i=0;const o=[];t.sort(nodeByXY);for(const s of t){if(s.y){if(s.x===0)o.push(s.y);else{for(n!==s.x&&(n=s.x,r=0),a=r+1;a<o.length&&!(o[a]>s.y);a++);r=a}s.y+=a*e,a++}i=Math.max(i,s.y+Math.max(s.in,s.out))}return i}function sortFlows(t,e){t.forEach(a=>{const n=Math[e](a.in||a.out,a.out||a.in),r=n<a.in,i=n<a.out;let o=0,s=a.from.length;a.from.sort((l,u)=>l.node.y+l.node.out/2-(u.node.y+u.node.out/2)).forEach((l,u)=>{r?l.addY=u*(n-l.flow)/(s-1):(l.addY=o,o+=l.flow)}),o=0,s=a.to.length,a.to.sort((l,u)=>l.node.y+l.node.in/2-(u.node.y+u.node.in/2)).forEach((l,u)=>{i?l.addY=u*(n-l.flow)/(s-1):(l.addY=o,o+=l.flow)})})}function layout(t,e,a,n){const r=[...t.values()],i=calculateX(t,e),s=(a?calculateYUsingPriority(r,i):calculateY(r,i))*.03,l=addPadding(r,s);return sortFlows(r,n),{maxX:i,maxY:l}}function buildNodesFromRawData(t){const e=new Map;for(let n=0;n<t.length;n++){const{from:r,to:i,flow:o}=t[n];if(!e.has(r))e.set(r,{key:r,in:0,out:o,from:[],to:[{key:i,flow:o,index:n}]});else{const s=e.get(r);s.out+=o,s.to.push({key:i,flow:o,index:n})}if(!e.has(i))e.set(i,{key:i,in:o,out:0,from:[{key:r,flow:o,index:n}],to:[]});else{const s=e.get(i);s.in+=o,s.from.push({key:r,flow:o,index:n})}}const a=(n,r)=>r.flow-n.flow;return[...e.values()].forEach(n=>{n.from=n.from.sort(a),n.from.forEach(r=>{r.node=e.get
2023-08-12 17:44:00 +02:00
* chartjs-adapter-date-fns v3.0.0
* https://www.chartjs.org
* (c) 2022 chartjs-adapter-date-fns Contributors
* Released under the MIT license
2023-10-01 11:32:08 +02:00
*/const FORMATS={datetime:"MMM d, yyyy, h:mm:ss aaaa",millisecond:"h:mm:ss.SSS aaaa",second:"h:mm:ss aaaa",minute:"h:mm aaaa",hour:"ha",day:"MMM d",week:"PP",month:"MMM yyyy",quarter:"qqq - yyyy",year:"yyyy"};adapters._date.override({_id:"date-fns",formats:function(){return FORMATS},parse:function(t,e){if(t===null||typeof t>"u")return null;const a=typeof t;return a==="number"||t instanceof Date?t=toDate(t):a==="string"&&(typeof e=="string"?t=parse$1(t,e,new Date,this.options):t=parseISO(t,this.options)),isValid(t)?t.getTime():null},format:function(t,e){return format$1(t,e,this.options)},add:function(t,e,a){switch(a){case"millisecond":return addMilliseconds(t,e);case"second":return addSeconds(t,e);case"minute":return addMinutes(t,e);case"hour":return addHours(t,e);case"day":return addDays(t,e);case"week":return addWeeks(t,e);case"month":return addMonths(t,e);case"quarter":return addQuarters(t,e);case"year":return addYears(t,e);default:return t}},diff:function(t,e,a){switch(a){case"millisecond":return differenceInMilliseconds(t,e);case"second":return differenceInSeconds(t,e);case"minute":return differenceInMinutes(t,e);case"hour":return differenceInHours(t,e);case"day":return differenceInDays(t,e);case"week":return differenceInWeeks(t,e);case"month":return differenceInMonths(t,e);case"quarter":return differenceInQuarters(t,e);case"year":return differenceInYears(t,e);default:return 0}},startOf:function(t,e,a){switch(e){case"second":return startOfSecond(t);case"minute":return startOfMinute(t);case"hour":return startOfHour(t);case"day":return startOfDay(t);case"week":return startOfWeek(t);case"isoWeek":return startOfWeek(t,{weekStartsOn:+a});case"month":return startOfMonth(t);case"quarter":return startOfQuarter(t);case"year":return startOfYear(t);default:return t}},endOf:function(t,e){switch(e){case"second":return endOfSecond(t);case"minute":return endOfMinute(t);case"hour":return endOfHour(t);case"day":return endOfDay(t);case"week":return endOfWeek(t);case"month":return endOfMonth(t);case"quarter":return endOfQuarter(t);case"year":return endOfYear(t);default:return t}}});Chart.register({LineController,LineElement,ArcElement,BarController,TimeScale,PieController,BarElement,Filler:index$1,Colors:plugin_colors,LinearScale,CategoryScale,PointElement,Tooltip:plugin_tooltip,Legend:plugin_legend});const comps={dates,boxes,accounts,budgets,categories,sankey,subscriptions,piggies};function loadPage(t){Object.keys(t).forEach(e=>{console.log(`Loading page component "${e}"`);let a=t[e]();Alpine.data(e,()=>a)}),Alpine.start()}document.addEventListener("firefly-iii-bootstrapped",()=>{loadPage(comps)});window.bootstrapped&&loadPage(comps);