@stonecrop/desktop 0.4.6 → 0.4.7
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/dist/desktop.js +5089 -1846
- package/dist/desktop.js.map +1 -1
- package/dist/desktop.umd.cjs +13 -14
- package/dist/desktop.umd.cjs.map +1 -1
- package/package.json +12 -12
- /package/dist/{style.css → desktop.css} +0 -0
package/dist/desktop.umd.cjs
CHANGED
|
@@ -1,23 +1,22 @@
|
|
|
1
|
-
(function(D,r){typeof exports=="object"&&typeof module<"u"?r(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],r):(D=typeof globalThis<"u"?globalThis:D||self,r(D["@stonecrop/desktop"]={},D.Vue))})(this,function(D,r){"use strict";const Wn={class:"action-menu-icon"},Hn=["onclick"],Fn={key:1},zn=["onClick"],Jn={class:"dropdown-container"},Gn={class:"dropdown"},Yn=["onclick"],qn=["href"],Qn={class:"dropdown-item"},Xn=r.defineComponent({__name:"ActionSet",props:{elements:{}},setup(t){const e=r.ref(t.elements),n=r.ref(!1),o=r.ref(null),s=r.ref(!1),a=r.ref(!1);r.onMounted(()=>{i()});const i=()=>{for(const d of e.value)d.type==="dropdown"&&(d.show=!1)},l=()=>{s.value=!0,o.value=setTimeout(()=>{s.value&&(n.value=!0)},500)},u=()=>{s.value=!1,a.value=!1,clearTimeout(o.value),n.value=!1},c=d=>{const f=!e.value[d].show;i(),e.value[d].show=f};return(d,f)=>(r.openBlock(),r.createElementBlock("div",{class:r.normalizeClass([{"open-set":n.value,"hovered-and-closed":a.value},"action-set collapse"]),onMouseover:l,onMouseleave:u},[r.createElementVNode("div",Wn,[r.createElementVNode("div",{id:"chevron",onClick:f[0]||(f[0]=p=>a.value=!a.value)},f[1]||(f[1]=[r.createElementVNode("svg",{class:"leftBar",version:"1.1",id:"Layer_1",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",x:"0px",y:"0px",viewBox:"0 0 100 100","xml:space":"preserve",width:"50",height:"50"},[r.createElementVNode("polygon",{points:"54.2,33.4 29.2,58.8 25,54.6 50,29.2 "})],-1),r.createElementVNode("svg",{class:"rightBar",version:"1.1",id:"Layer_1",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",x:"0px",y:"0px",viewBox:"0 0 100 100","xml:space":"preserve",width:"50",height:"50"},[r.createElementVNode("polygon",{points:"70.8,58.8 45.8,33.4 50,29.2 75,54.6 "})],-1)]))]),f[2]||(f[2]=r.createElementVNode("div",{style:{"margin-right":"30px"}},null,-1)),(r.openBlock(!0),r.createElementBlock(r.Fragment,null,r.renderList(e.value,(p,w)=>(r.openBlock(),r.createElementBlock("div",{class:"action-element",key:p.label},[p.type=="button"?(r.openBlock(),r.createElementBlock("button",{key:0,onclick:p.action,class:"button-default"},r.toDisplayString(p.label),9,Hn)):r.createCommentVNode("",!0),p.type=="dropdown"?(r.openBlock(),r.createElementBlock("div",Fn,[r.createElementVNode("button",{class:"button-default",onClick:h=>c(w)},r.toDisplayString(p.label),9,zn),r.withDirectives(r.createElementVNode("div",Jn,[r.createElementVNode("div",Gn,[(r.openBlock(!0),r.createElementBlock(r.Fragment,null,r.renderList(p.actions,h=>(r.openBlock(),r.createElementBlock("div",{key:h.label},[h.action!=null?(r.openBlock(),r.createElementBlock("button",{key:0,onclick:h.action,class:"dropdown-item"},r.toDisplayString(h.label),9,Yn)):h.link!=null?(r.openBlock(),r.createElementBlock("a",{key:1,href:h.link},[r.createElementVNode("button",Qn,r.toDisplayString(h.label),1)],8,qn)):r.createCommentVNode("",!0)]))),128))])],512),[[r.vShow,p.show]])])):r.createCommentVNode("",!0)]))),128))],34))}}),Dt=(t,e)=>{const n=t.__vccOpts||t;for(const[o,s]of e)n[o]=s;return n},ge=Dt(Xn,[["__scopeId","data-v-38e7af34"]]),Kn={};function Zn(t,e){return r.openBlock(),r.createElementBlock("dialog")}const ye=Dt(Kn,[["render",Zn]]),to=(t,e)=>{const n=t.__vccOpts||t;for(const[o,s]of e)n[o]=s;return n};function we(t){return r.getCurrentScope()?(r.onScopeDispose(t),!0):!1}function at(t){return typeof t=="function"?t():r.unref(t)}const be=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const eo=Object.prototype.toString,no=t=>eo.call(t)==="[object Object]",_e=()=>{},Ee=oo();function oo(){var t,e;return be&&((t=window==null?void 0:window.navigator)==null?void 0:t.userAgent)&&(/iP(?:ad|hone|od)/.test(window.navigator.userAgent)||((e=window==null?void 0:window.navigator)==null?void 0:e.maxTouchPoints)>2&&/iPad|Macintosh/.test(window==null?void 0:window.navigator.userAgent))}function ro(...t){if(t.length!==1)return r.toRef(...t);const e=t[0];return typeof e=="function"?r.readonly(r.customRef(()=>({get:e,set:_e}))):r.ref(e)}const so=be?window:void 0;function ao(t){var e;const n=at(t);return(e=n==null?void 0:n.$el)!=null?e:n}function io(...t){let e,n,o,s;if(typeof t[0]=="string"||Array.isArray(t[0])?([n,o,s]=t,e=so):[e,n,o,s]=t,!e)return _e;Array.isArray(n)||(n=[n]),Array.isArray(o)||(o=[o]);const a=[],i=()=>{a.forEach(d=>d()),a.length=0},l=(d,f,p,w)=>(d.addEventListener(f,p,w),()=>d.removeEventListener(f,p,w)),u=r.watch(()=>[ao(e),at(s)],([d,f])=>{if(i(),!d)return;const p=no(f)?{...f}:f;a.push(...n.flatMap(w=>o.map(h=>l(d,w,h,p))))},{immediate:!0,flush:"post"}),c=()=>{u(),i()};return we(c),c}function Tt(t){return typeof Window<"u"&&t instanceof Window?t.document.documentElement:typeof Document<"u"&&t instanceof Document?t.documentElement:t}function ve(t){const e=window.getComputedStyle(t);if(e.overflowX==="scroll"||e.overflowY==="scroll"||e.overflowX==="auto"&&t.clientWidth<t.scrollWidth||e.overflowY==="auto"&&t.clientHeight<t.scrollHeight)return!0;{const n=t.parentNode;return!n||n.tagName==="BODY"?!1:ve(n)}}function lo(t){const e=t||window.event,n=e.target;return ve(n)?!1:e.touches.length>1?!0:(e.preventDefault&&e.preventDefault(),!1)}const At=new WeakMap;function co(t,e=!1){const n=r.ref(e);let o=null,s="";r.watch(ro(t),l=>{const u=Tt(at(l));if(u){const c=u;if(At.get(c)||At.set(c,c.style.overflow),c.style.overflow!=="hidden"&&(s=c.style.overflow),c.style.overflow==="hidden")return n.value=!0;if(n.value)return c.style.overflow="hidden"}},{immediate:!0});const a=()=>{const l=Tt(at(t));!l||n.value||(Ee&&(o=io(l,"touchmove",u=>{lo(u)},{passive:!1})),l.style.overflow="hidden",n.value=!0)},i=()=>{const l=Tt(at(t));!l||!n.value||(Ee&&(o==null||o()),l.style.overflow=s,At.delete(l),n.value=!1)};return we(i),r.computed({get(){return n.value},set(l){l?a():i()}})}function uo(){let t=!1;const e=r.ref(!1);return(n,o)=>{if(e.value=o.value,t)return;t=!0;const s=co(n,o.value);r.watch(e,a=>s.value=a)}}uo(),typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const fo={class:"aform"},po=r.defineComponent({__name:"AForm",props:{modelValue:{},data:{},readonly:{type:Boolean}},emits:["update:modelValue"],setup(t,{emit:e}){const n=e,o=r.ref(t.data||{}),s=i=>{let l={};for(const[u,c]of Object.entries(i))["component","fieldtype"].includes(u)||(l[u]=c),u==="rows"&&c&&c.length===0&&(l.rows=o.value[i.fieldname]);return l},a=r.computed({get:()=>t.modelValue.map((i,l)=>r.computed({get(){return i.value},set:u=>{t.modelValue[l].value=u,n("update:modelValue",t.modelValue)}})),set:()=>{}});return(i,l)=>(r.openBlock(),r.createElementBlock("form",fo,[(r.openBlock(!0),r.createElementBlock(r.Fragment,null,r.renderList(i.modelValue,(u,c)=>(r.openBlock(),r.createBlock(r.resolveDynamicComponent(u.component),r.mergeProps({key:c,schema:u,modelValue:a.value[c].value,"onUpdate:modelValue":d=>a.value[c].value=d,data:o.value[u.fieldname],readonly:i.readonly,ref_for:!0},s(u)),null,16,["schema","modelValue","onUpdate:modelValue","data","readonly"]))),128))]))}}),mo=to(po,[["__scopeId","data-v-68845234"]]);var ho=Object.defineProperty,go=(t,e,n)=>e in t?ho(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,T=(t,e,n)=>go(t,typeof e!="symbol"?e+"":e,n);function Bt(t){this.message=t||""}Bt.prototype=Object.create(Error.prototype,{constructor:{value:Bt},name:{value:"NotImplemented"},stack:{get:function(){return new Error().stack}}});const ke=class It{constructor(e,n,o,s,a){if(T(this,"name","Stonecrop"),T(this,"registry"),T(this,"store"),T(this,"schema"),T(this,"workflow"),T(this,"actions"),It._root)return It._root;It._root=this,this.registry=e,this.store=n,this.schema=o,this.workflow=s,this.actions=a}setup(e){this.getMeta(e),this.getWorkflow(e),this.getActions(e)}getMeta(e){return this.registry.getMeta?this.registry.getMeta(e.doctype):new Bt(e.doctype)}getWorkflow(e){const n=this.registry.registry[e.slug];this.workflow=n.workflow}getActions(e){const n=this.registry.registry[e.slug];this.actions=n.actions}async getRecords(e,n){this.store.$patch({records:[]});const o=await(await fetch(`/${e.slug}`,n)).json();this.store.$patch({records:o})}async getRecord(e,n){this.store.$patch({record:{}});const o=await(await fetch(`/${e.slug}/${n}`)).json();this.store.$patch({record:o})}runAction(e,n,o){var s;const a=(s=this.registry.registry[e.slug].actions)==null?void 0:s.get(n);if(this.workflow){const{initialState:i}=this.workflow;this.workflow.transition(i,{type:n}),a&&a.length>0&&a.forEach(l=>{new Function(l)(o)})}}};T(ke,"_root");let yo=ke;var $e=!1;function bt(t,e,n){return Array.isArray(t)?(t.length=Math.max(t.length,e),t.splice(e,1,n),n):(t[e]=n,n)}function Rt(t,e){if(Array.isArray(t)){t.splice(e,1);return}delete t[e]}function wo(){return Se().__VUE_DEVTOOLS_GLOBAL_HOOK__}function Se(){return typeof navigator<"u"&&typeof window<"u"?window:typeof globalThis<"u"?globalThis:{}}const bo=typeof Proxy=="function",_o="devtools-plugin:setup",Eo="plugin:settings:set";let it,jt;function vo(){var t;return it!==void 0||(typeof window<"u"&&window.performance?(it=!0,jt=window.performance):typeof globalThis<"u"&&!((t=globalThis.perf_hooks)===null||t===void 0)&&t.performance?(it=!0,jt=globalThis.perf_hooks.performance):it=!1),it}function ko(){return vo()?jt.now():Date.now()}class $o{constructor(e,n){this.target=null,this.targetQueue=[],this.onQueue=[],this.plugin=e,this.hook=n;const o={};if(e.settings)for(const i in e.settings){const l=e.settings[i];o[i]=l.defaultValue}const s=`__vue-devtools-plugin-settings__${e.id}`;let a=Object.assign({},o);try{const i=localStorage.getItem(s),l=JSON.parse(i);Object.assign(a,l)}catch{}this.fallbacks={getSettings(){return a},setSettings(i){try{localStorage.setItem(s,JSON.stringify(i))}catch{}a=i},now(){return ko()}},n&&n.on(Eo,(i,l)=>{i===this.plugin.id&&this.fallbacks.setSettings(l)}),this.proxiedOn=new Proxy({},{get:(i,l)=>this.target?this.target.on[l]:(...u)=>{this.onQueue.push({method:l,args:u})}}),this.proxiedTarget=new Proxy({},{get:(i,l)=>this.target?this.target[l]:l==="on"?this.proxiedOn:Object.keys(this.fallbacks).includes(l)?(...u)=>(this.targetQueue.push({method:l,args:u,resolve:()=>{}}),this.fallbacks[l](...u)):(...u)=>new Promise(c=>{this.targetQueue.push({method:l,args:u,resolve:c})})})}async setRealTarget(e){this.target=e;for(const n of this.onQueue)this.target.on[n.method](...n.args);for(const n of this.targetQueue)n.resolve(await this.target[n.method](...n.args))}}function Ne(t,e){const n=t,o=Se(),s=wo(),a=bo&&n.enableEarlyProxy;if(s&&(o.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__||!a))s.emit(_o,t,e);else{const i=a?new $o(n,s):null;(o.__VUE_DEVTOOLS_PLUGINS__=o.__VUE_DEVTOOLS_PLUGINS__||[]).push({pluginDescriptor:n,setupFn:e,proxy:i}),i&&e(i.proxiedTarget)}}/*!
|
|
2
|
-
* pinia
|
|
3
|
-
* (c)
|
|
1
|
+
(function(K,s){typeof exports=="object"&&typeof module<"u"?s(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],s):(K=typeof globalThis<"u"?globalThis:K||self,s(K["@stonecrop/desktop"]={},K.Vue))})(this,function(K,s){"use strict";const zr={class:"action-menu-icon"},Kr=["onclick"],Fr={key:1},Wr=["onClick"],Gr={class:"dropdown-container"},Yr={class:"dropdown"},qr=["onclick"],Jr=["href"],Xr={class:"dropdown-item"},Zr=s.defineComponent({__name:"ActionSet",props:{elements:{}},setup(e){const t=s.ref(e.elements),n=s.ref(!1),o=s.ref(null),r=s.ref(!1),a=s.ref(!1);s.onMounted(()=>{i()});const i=()=>{for(const d of t.value)d.type==="dropdown"&&(d.show=!1)},l=()=>{r.value=!0,o.value=setTimeout(()=>{r.value&&(n.value=!0)},500)},c=()=>{r.value=!1,a.value=!1,clearTimeout(o.value),n.value=!1},u=d=>{const f=!t.value[d].show;i(),t.value[d].show=f};return(d,f)=>(s.openBlock(),s.createElementBlock("div",{class:s.normalizeClass([{"open-set":n.value,"hovered-and-closed":a.value},"action-set collapse"]),onMouseover:l,onMouseleave:c},[s.createElementVNode("div",zr,[s.createElementVNode("div",{id:"chevron",onClick:f[0]||(f[0]=p=>a.value=!a.value)},f[1]||(f[1]=[s.createElementVNode("svg",{class:"leftBar",version:"1.1",id:"Layer_1",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",x:"0px",y:"0px",viewBox:"0 0 100 100","xml:space":"preserve",width:"50",height:"50"},[s.createElementVNode("polygon",{points:"54.2,33.4 29.2,58.8 25,54.6 50,29.2 "})],-1),s.createElementVNode("svg",{class:"rightBar",version:"1.1",id:"Layer_1",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",x:"0px",y:"0px",viewBox:"0 0 100 100","xml:space":"preserve",width:"50",height:"50"},[s.createElementVNode("polygon",{points:"70.8,58.8 45.8,33.4 50,29.2 75,54.6 "})],-1)]))]),f[2]||(f[2]=s.createElementVNode("div",{style:{"margin-right":"30px"}},null,-1)),(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(t.value,(p,m)=>(s.openBlock(),s.createElementBlock("div",{class:"action-element",key:p.label},[p.type=="button"?(s.openBlock(),s.createElementBlock("button",{key:0,onclick:p.action,class:"button-default"},s.toDisplayString(p.label),9,Kr)):s.createCommentVNode("",!0),p.type=="dropdown"?(s.openBlock(),s.createElementBlock("div",Fr,[s.createElementVNode("button",{class:"button-default",onClick:_=>u(m)},s.toDisplayString(p.label),9,Wr),s.withDirectives(s.createElementVNode("div",Gr,[s.createElementVNode("div",Yr,[(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(p.actions,_=>(s.openBlock(),s.createElementBlock("div",{key:_.label},[_.action!=null?(s.openBlock(),s.createElementBlock("button",{key:0,onclick:_.action,class:"dropdown-item"},s.toDisplayString(_.label),9,qr)):_.link!=null?(s.openBlock(),s.createElementBlock("a",{key:1,href:_.link},[s.createElementVNode("button",Xr,s.toDisplayString(_.label),1)],8,Jr)):s.createCommentVNode("",!0)]))),128))])],512),[[s.vShow,p.show]])])):s.createCommentVNode("",!0)]))),128))],34))}}),ct=(e,t)=>{const n=e.__vccOpts||e;for(const[o,r]of t)n[o]=r;return n},un=ct(Zr,[["__scopeId","data-v-38e7af34"]]),Qr={};function es(e,t){return s.openBlock(),s.createElementBlock("dialog")}const dn=ct(Qr,[["render",es]]),ts=(e,t)=>{const n=e.__vccOpts||e;for(const[o,r]of t)n[o]=r;return n};function fn(e){return s.getCurrentScope()?(s.onScopeDispose(e),!0):!1}const pn=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const ns=Object.prototype.toString,os=e=>ns.call(e)==="[object Object]",rs=()=>{},mn=ss();function ss(){var e,t;return pn&&((e=window==null?void 0:window.navigator)==null?void 0:e.userAgent)&&(/iP(?:ad|hone|od)/.test(window.navigator.userAgent)||((t=window==null?void 0:window.navigator)==null?void 0:t.maxTouchPoints)>2&&/iPad|Macintosh/.test(window==null?void 0:window.navigator.userAgent))}function ut(e){return Array.isArray(e)?e:[e]}function as(...e){if(e.length!==1)return s.toRef(...e);const t=e[0];return typeof t=="function"?s.readonly(s.customRef(()=>({get:t,set:rs}))):s.ref(t)}function is(e,t,n){return s.watch(e,t,{...n,immediate:!0})}const ls=pn?window:void 0;function cs(e){var t;const n=s.toValue(e);return(t=n==null?void 0:n.$el)!=null?t:n}function us(...e){const t=[],n=()=>{t.forEach(l=>l()),t.length=0},o=(l,c,u,d)=>(l.addEventListener(c,u,d),()=>l.removeEventListener(c,u,d)),r=s.computed(()=>{const l=ut(s.toValue(e[0])).filter(c=>c!=null);return l.every(c=>typeof c!="string")?l:void 0}),a=is(()=>{var l,c;return[(c=(l=r.value)==null?void 0:l.map(u=>cs(u)))!=null?c:[ls].filter(u=>u!=null),ut(s.toValue(r.value?e[1]:e[0])),ut(s.unref(r.value?e[2]:e[1])),s.toValue(r.value?e[3]:e[2])]},([l,c,u,d])=>{if(n(),!(l!=null&&l.length)||!(c!=null&&c.length)||!(u!=null&&u.length))return;const f=os(d)?{...d}:d;t.push(...l.flatMap(p=>c.flatMap(m=>u.map(_=>o(p,m,_,f)))))},{flush:"post"}),i=()=>{a(),n()};return fn(n),i}function dt(e){return typeof Window<"u"&&e instanceof Window?e.document.documentElement:typeof Document<"u"&&e instanceof Document?e.documentElement:e}function hn(e){const t=window.getComputedStyle(e);if(t.overflowX==="scroll"||t.overflowY==="scroll"||t.overflowX==="auto"&&e.clientWidth<e.scrollWidth||t.overflowY==="auto"&&e.clientHeight<e.scrollHeight)return!0;{const n=e.parentNode;return!n||n.tagName==="BODY"?!1:hn(n)}}function ds(e){const t=e||window.event,n=t.target;return hn(n)?!1:t.touches.length>1?!0:(t.preventDefault&&t.preventDefault(),!1)}const ft=new WeakMap;function fs(e,t=!1){const n=s.ref(t);let o=null,r="";s.watch(as(e),l=>{const c=dt(s.toValue(l));if(c){const u=c;if(ft.get(u)||ft.set(u,u.style.overflow),u.style.overflow!=="hidden"&&(r=u.style.overflow),u.style.overflow==="hidden")return n.value=!0;if(n.value)return u.style.overflow="hidden"}},{immediate:!0});const a=()=>{const l=dt(s.toValue(e));!l||n.value||(mn&&(o=us(l,"touchmove",c=>{ds(c)},{passive:!1})),l.style.overflow="hidden",n.value=!0)},i=()=>{const l=dt(s.toValue(e));!l||!n.value||(mn&&(o==null||o()),l.style.overflow=r,ft.delete(l),n.value=!1)};return fn(i),s.computed({get(){return n.value},set(l){l?a():i()}})}function ps(){let e=!1;const t=s.shallowRef(!1);return(n,o)=>{if(t.value=o.value,e)return;e=!0;const r=fs(n,o.value);s.watch(t,a=>r.value=a)}}ps(),typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const ms={class:"aform"},hs=s.defineComponent({__name:"AForm",props:{modelValue:{},data:{},readonly:{type:Boolean}},emits:["update:modelValue"],setup(e,{emit:t}){const n=t,o=s.ref(e.data||{}),r=i=>{let l={};for(const[c,u]of Object.entries(i))["component","fieldtype"].includes(c)||(l[c]=u),c==="rows"&&u&&u.length===0&&(l.rows=o.value[i.fieldname]);return l},a=s.computed({get:()=>e.modelValue.map((i,l)=>s.computed({get(){return i.value},set:c=>{e.modelValue[l].value=c,n("update:modelValue",e.modelValue)}})),set:()=>{}});return(i,l)=>(s.openBlock(),s.createElementBlock("form",ms,[(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(i.modelValue,(c,u)=>(s.openBlock(),s.createBlock(s.resolveDynamicComponent(c.component),s.mergeProps({key:u,schema:c,modelValue:a.value[u].value,"onUpdate:modelValue":d=>a.value[u].value=d,data:o.value[c.fieldname],readonly:i.readonly,ref_for:!0},r(c)),null,16,["schema","modelValue","onUpdate:modelValue","data","readonly"]))),128))]))}}),_s=ts(hs,[["__scopeId","data-v-68845234"]]);var gs=Object.defineProperty,ys=(e,t,n)=>t in e?gs(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,M=(e,t,n)=>ys(e,typeof t!="symbol"?t+"":t,n);function pt(e){this.message=e||""}pt.prototype=Object.create(Error.prototype,{constructor:{value:pt},name:{value:"NotImplemented"},stack:{get:function(){return new Error().stack}}});const _n=class it{constructor(t,n,o,r,a){if(M(this,"name","Stonecrop"),M(this,"registry"),M(this,"store"),M(this,"schema"),M(this,"workflow"),M(this,"actions"),it._root)return it._root;it._root=this,this.registry=t,this.store=n,this.schema=o,this.workflow=r,this.actions=a}setup(t){this.getMeta(t),this.getWorkflow(t),this.getActions(t)}getMeta(t){return this.registry.getMeta?this.registry.getMeta(t.doctype):new pt(t.doctype)}getWorkflow(t){const n=this.registry.registry[t.slug];this.workflow=n.workflow}getActions(t){const n=this.registry.registry[t.slug];this.actions=n.actions}async getRecords(t,n){this.store.$patch({records:[]});const o=await(await fetch(`/${t.slug}`,n)).json();this.store.$patch({records:o})}async getRecord(t,n){this.store.$patch({record:{}});const o=await(await fetch(`/${t.slug}/${n}`)).json();this.store.$patch({record:o})}runAction(t,n,o){var r;const a=(r=this.registry.registry[t.slug].actions)==null?void 0:r.get(n);if(this.workflow){const{initialState:i}=this.workflow;this.workflow.transition(i,{type:n}),a&&a.length>0&&a.forEach(l=>{new Function(l)(o)})}}};M(_n,"_root");let Es=_n;var ws=Object.create,gn=Object.defineProperty,bs=Object.getOwnPropertyDescriptor,mt=Object.getOwnPropertyNames,vs=Object.getPrototypeOf,ks=Object.prototype.hasOwnProperty,Os=(e,t)=>function(){return e&&(t=(0,e[mt(e)[0]])(e=0)),t},Ss=(e,t)=>function(){return t||(0,e[mt(e)[0]])((t={exports:{}}).exports,t),t.exports},Ts=(e,t,n,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of mt(t))!ks.call(e,r)&&r!==n&&gn(e,r,{get:()=>t[r],enumerable:!(o=bs(t,r))||o.enumerable});return e},Is=(e,t,n)=>(n=e!=null?ws(vs(e)):{},Ts(gn(n,"default",{value:e,enumerable:!0}),e)),Ve=Os({"../../node_modules/.pnpm/tsup@8.3.5_@microsoft+api-extractor@7.48.1_@types+node@22.10.5__jiti@2.4.2_postcss@8.4.49_tsx_s7k37zks4wtn7x2grzma6lrsfa/node_modules/tsup/assets/esm_shims.js"(){}}),Vs=Ss({"../../node_modules/.pnpm/rfdc@1.4.1/node_modules/rfdc/index.js"(e,t){Ve(),t.exports=o;function n(a){return a instanceof Buffer?Buffer.from(a):new a.constructor(a.buffer.slice(),a.byteOffset,a.length)}function o(a){if(a=a||{},a.circles)return r(a);const i=new Map;if(i.set(Date,f=>new Date(f)),i.set(Map,(f,p)=>new Map(c(Array.from(f),p))),i.set(Set,(f,p)=>new Set(c(Array.from(f),p))),a.constructorHandlers)for(const f of a.constructorHandlers)i.set(f[0],f[1]);let l=null;return a.proto?d:u;function c(f,p){const m=Object.keys(f),_=new Array(m.length);for(let b=0;b<m.length;b++){const h=m[b],k=f[h];typeof k!="object"||k===null?_[h]=k:k.constructor!==Object&&(l=i.get(k.constructor))?_[h]=l(k,p):ArrayBuffer.isView(k)?_[h]=n(k):_[h]=p(k)}return _}function u(f){if(typeof f!="object"||f===null)return f;if(Array.isArray(f))return c(f,u);if(f.constructor!==Object&&(l=i.get(f.constructor)))return l(f,u);const p={};for(const m in f){if(Object.hasOwnProperty.call(f,m)===!1)continue;const _=f[m];typeof _!="object"||_===null?p[m]=_:_.constructor!==Object&&(l=i.get(_.constructor))?p[m]=l(_,u):ArrayBuffer.isView(_)?p[m]=n(_):p[m]=u(_)}return p}function d(f){if(typeof f!="object"||f===null)return f;if(Array.isArray(f))return c(f,d);if(f.constructor!==Object&&(l=i.get(f.constructor)))return l(f,d);const p={};for(const m in f){const _=f[m];typeof _!="object"||_===null?p[m]=_:_.constructor!==Object&&(l=i.get(_.constructor))?p[m]=l(_,d):ArrayBuffer.isView(_)?p[m]=n(_):p[m]=d(_)}return p}}function r(a){const i=[],l=[],c=new Map;if(c.set(Date,m=>new Date(m)),c.set(Map,(m,_)=>new Map(d(Array.from(m),_))),c.set(Set,(m,_)=>new Set(d(Array.from(m),_))),a.constructorHandlers)for(const m of a.constructorHandlers)c.set(m[0],m[1]);let u=null;return a.proto?p:f;function d(m,_){const b=Object.keys(m),h=new Array(b.length);for(let k=0;k<b.length;k++){const O=b[k],V=m[O];if(typeof V!="object"||V===null)h[O]=V;else if(V.constructor!==Object&&(u=c.get(V.constructor)))h[O]=u(V,_);else if(ArrayBuffer.isView(V))h[O]=n(V);else{const A=i.indexOf(V);A!==-1?h[O]=l[A]:h[O]=_(V)}}return h}function f(m){if(typeof m!="object"||m===null)return m;if(Array.isArray(m))return d(m,f);if(m.constructor!==Object&&(u=c.get(m.constructor)))return u(m,f);const _={};i.push(m),l.push(_);for(const b in m){if(Object.hasOwnProperty.call(m,b)===!1)continue;const h=m[b];if(typeof h!="object"||h===null)_[b]=h;else if(h.constructor!==Object&&(u=c.get(h.constructor)))_[b]=u(h,f);else if(ArrayBuffer.isView(h))_[b]=n(h);else{const k=i.indexOf(h);k!==-1?_[b]=l[k]:_[b]=f(h)}}return i.pop(),l.pop(),_}function p(m){if(typeof m!="object"||m===null)return m;if(Array.isArray(m))return d(m,p);if(m.constructor!==Object&&(u=c.get(m.constructor)))return u(m,p);const _={};i.push(m),l.push(_);for(const b in m){const h=m[b];if(typeof h!="object"||h===null)_[b]=h;else if(h.constructor!==Object&&(u=c.get(h.constructor)))_[b]=u(h,p);else if(ArrayBuffer.isView(h))_[b]=n(h);else{const k=i.indexOf(h);k!==-1?_[b]=l[k]:_[b]=p(h)}}return i.pop(),l.pop(),_}}}});Ve(),Ve(),Ve();var yn=typeof navigator<"u",S=typeof window<"u"?window:typeof globalThis<"u"?globalThis:typeof global<"u"?global:{};typeof S.chrome<"u"&&S.chrome.devtools,yn&&(S.self,S.top);var En;typeof navigator<"u"&&((En=navigator.userAgent)==null||En.toLowerCase().includes("electron")),Ve();var Cs=Is(Vs()),Ps=/(?:^|[-_/])(\w)/g;function Ns(e,t){return t?t.toUpperCase():""}function Ds(e){return e&&`${e}`.replace(Ps,Ns)}function Rs(e,t){let n=e.replace(/^[a-z]:/i,"").replace(/\\/g,"/");n.endsWith(`index${t}`)&&(n=n.replace(`/index${t}`,t));const o=n.lastIndexOf("/"),r=n.substring(o+1);{const a=r.lastIndexOf(t);return r.substring(0,a)}}var wn=(0,Cs.default)({circles:!0});const xs={trailing:!0};function me(e,t=25,n={}){if(n={...xs,...n},!Number.isFinite(t))throw new TypeError("Expected `wait` to be a finite number");let o,r,a=[],i,l;const c=(u,d)=>(i=As(e,u,d),i.finally(()=>{if(i=null,n.trailing&&l&&!r){const f=c(u,l);return l=null,f}}),i);return function(...u){return i?(n.trailing&&(l=u),i):new Promise(d=>{const f=!r&&n.leading;clearTimeout(r),r=setTimeout(()=>{r=null;const p=n.leading?o:c(this,u);for(const m of a)m(p);a=[]},t),f?(o=c(this,u),d(o)):a.push(d)})}}async function As(e,t,n){return await e.apply(t,n)}function ht(e,t={},n){for(const o in e){const r=e[o],a=n?`${n}:${o}`:o;typeof r=="object"&&r!==null?ht(r,t,a):typeof r=="function"&&(t[a]=r)}return t}const $s={run:e=>e()},Ls=()=>$s,bn=typeof console.createTask<"u"?console.createTask:Ls;function js(e,t){const n=t.shift(),o=bn(n);return e.reduce((r,a)=>r.then(()=>o.run(()=>a(...t))),Promise.resolve())}function Us(e,t){const n=t.shift(),o=bn(n);return Promise.all(e.map(r=>o.run(()=>r(...t))))}function _t(e,t){for(const n of[...e])n(t)}class Ms{constructor(){this._hooks={},this._before=void 0,this._after=void 0,this._deprecatedMessages=void 0,this._deprecatedHooks={},this.hook=this.hook.bind(this),this.callHook=this.callHook.bind(this),this.callHookWith=this.callHookWith.bind(this)}hook(t,n,o={}){if(!t||typeof n!="function")return()=>{};const r=t;let a;for(;this._deprecatedHooks[t];)a=this._deprecatedHooks[t],t=a.to;if(a&&!o.allowDeprecated){let i=a.message;i||(i=`${r} hook has been deprecated`+(a.to?`, please use ${a.to}`:"")),this._deprecatedMessages||(this._deprecatedMessages=new Set),this._deprecatedMessages.has(i)||(console.warn(i),this._deprecatedMessages.add(i))}if(!n.name)try{Object.defineProperty(n,"name",{get:()=>"_"+t.replace(/\W+/g,"_")+"_hook_cb",configurable:!0})}catch{}return this._hooks[t]=this._hooks[t]||[],this._hooks[t].push(n),()=>{n&&(this.removeHook(t,n),n=void 0)}}hookOnce(t,n){let o,r=(...a)=>(typeof o=="function"&&o(),o=void 0,r=void 0,n(...a));return o=this.hook(t,r),o}removeHook(t,n){if(this._hooks[t]){const o=this._hooks[t].indexOf(n);o!==-1&&this._hooks[t].splice(o,1),this._hooks[t].length===0&&delete this._hooks[t]}}deprecateHook(t,n){this._deprecatedHooks[t]=typeof n=="string"?{to:n}:n;const o=this._hooks[t]||[];delete this._hooks[t];for(const r of o)this.hook(t,r)}deprecateHooks(t){Object.assign(this._deprecatedHooks,t);for(const n in t)this.deprecateHook(n,t[n])}addHooks(t){const n=ht(t),o=Object.keys(n).map(r=>this.hook(r,n[r]));return()=>{for(const r of o.splice(0,o.length))r()}}removeHooks(t){const n=ht(t);for(const o in n)this.removeHook(o,n[o])}removeAllHooks(){for(const t in this._hooks)delete this._hooks[t]}callHook(t,...n){return n.unshift(t),this.callHookWith(js,t,...n)}callHookParallel(t,...n){return n.unshift(t),this.callHookWith(Us,t,...n)}callHookWith(t,n,...o){const r=this._before||this._after?{name:n,args:o,context:{}}:void 0;this._before&&_t(this._before,r);const a=t(n in this._hooks?[...this._hooks[n]]:[],o);return a instanceof Promise?a.finally(()=>{this._after&&r&&_t(this._after,r)}):(this._after&&r&&_t(this._after,r),a)}beforeEach(t){return this._before=this._before||[],this._before.push(t),()=>{if(this._before!==void 0){const n=this._before.indexOf(t);n!==-1&&this._before.splice(n,1)}}}afterEach(t){return this._after=this._after||[],this._after.push(t),()=>{if(this._after!==void 0){const n=this._after.indexOf(t);n!==-1&&this._after.splice(n,1)}}}}function vn(){return new Ms}var Bs=Object.create,kn=Object.defineProperty,Hs=Object.getOwnPropertyDescriptor,gt=Object.getOwnPropertyNames,zs=Object.getPrototypeOf,Ks=Object.prototype.hasOwnProperty,Fs=(e,t)=>function(){return e&&(t=(0,e[gt(e)[0]])(e=0)),t},On=(e,t)=>function(){return t||(0,e[gt(e)[0]])((t={exports:{}}).exports,t),t.exports},Ws=(e,t,n,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of gt(t))!Ks.call(e,r)&&r!==n&&kn(e,r,{get:()=>t[r],enumerable:!(o=Hs(t,r))||o.enumerable});return e},Gs=(e,t,n)=>(n=e!=null?Bs(zs(e)):{},Ws(kn(n,"default",{value:e,enumerable:!0}),e)),w=Fs({"../../node_modules/.pnpm/tsup@8.3.5_@microsoft+api-extractor@7.48.1_@types+node@22.10.5__jiti@2.4.2_postcss@8.4.49_tsx_s7k37zks4wtn7x2grzma6lrsfa/node_modules/tsup/assets/esm_shims.js"(){}}),Ys=On({"../../node_modules/.pnpm/speakingurl@14.0.1/node_modules/speakingurl/lib/speakingurl.js"(e,t){w(),function(n){var o={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"Ae",Å:"A",Æ:"AE",Ç:"C",È:"E",É:"E",Ê:"E",Ë:"E",Ì:"I",Í:"I",Î:"I",Ï:"I",Ð:"D",Ñ:"N",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"Oe",Ő:"O",Ø:"O",Ù:"U",Ú:"U",Û:"U",Ü:"Ue",Ű:"U",Ý:"Y",Þ:"TH",ß:"ss",à:"a",á:"a",â:"a",ã:"a",ä:"ae",å:"a",æ:"ae",ç:"c",è:"e",é:"e",ê:"e",ë:"e",ì:"i",í:"i",î:"i",ï:"i",ð:"d",ñ:"n",ò:"o",ó:"o",ô:"o",õ:"o",ö:"oe",ő:"o",ø:"o",ù:"u",ú:"u",û:"u",ü:"ue",ű:"u",ý:"y",þ:"th",ÿ:"y","ẞ":"SS",ا:"a",أ:"a",إ:"i",آ:"aa",ؤ:"u",ئ:"e",ء:"a",ب:"b",ت:"t",ث:"th",ج:"j",ح:"h",خ:"kh",د:"d",ذ:"th",ر:"r",ز:"z",س:"s",ش:"sh",ص:"s",ض:"dh",ط:"t",ظ:"z",ع:"a",غ:"gh",ف:"f",ق:"q",ك:"k",ل:"l",م:"m",ن:"n",ه:"h",و:"w",ي:"y",ى:"a",ة:"h",ﻻ:"la",ﻷ:"laa",ﻹ:"lai",ﻵ:"laa",گ:"g",چ:"ch",پ:"p",ژ:"zh",ک:"k",ی:"y","َ":"a","ً":"an","ِ":"e","ٍ":"en","ُ":"u","ٌ":"on","ْ":"","٠":"0","١":"1","٢":"2","٣":"3","٤":"4","٥":"5","٦":"6","٧":"7","٨":"8","٩":"9","۰":"0","۱":"1","۲":"2","۳":"3","۴":"4","۵":"5","۶":"6","۷":"7","۸":"8","۹":"9",က:"k",ခ:"kh",ဂ:"g",ဃ:"ga",င:"ng",စ:"s",ဆ:"sa",ဇ:"z","စျ":"za",ည:"ny",ဋ:"t",ဌ:"ta",ဍ:"d",ဎ:"da",ဏ:"na",တ:"t",ထ:"ta",ဒ:"d",ဓ:"da",န:"n",ပ:"p",ဖ:"pa",ဗ:"b",ဘ:"ba",မ:"m",ယ:"y",ရ:"ya",လ:"l",ဝ:"w",သ:"th",ဟ:"h",ဠ:"la",အ:"a","ြ":"y","ျ":"ya","ွ":"w","ြွ":"yw","ျွ":"ywa","ှ":"h",ဧ:"e","၏":"-e",ဣ:"i",ဤ:"-i",ဉ:"u",ဦ:"-u",ဩ:"aw","သြော":"aw",ဪ:"aw","၀":"0","၁":"1","၂":"2","၃":"3","၄":"4","၅":"5","၆":"6","၇":"7","၈":"8","၉":"9","္":"","့":"","း":"",č:"c",ď:"d",ě:"e",ň:"n",ř:"r",š:"s",ť:"t",ů:"u",ž:"z",Č:"C",Ď:"D",Ě:"E",Ň:"N",Ř:"R",Š:"S",Ť:"T",Ů:"U",Ž:"Z",ހ:"h",ށ:"sh",ނ:"n",ރ:"r",ބ:"b",ޅ:"lh",ކ:"k",އ:"a",ވ:"v",މ:"m",ފ:"f",ދ:"dh",ތ:"th",ލ:"l",ގ:"g",ޏ:"gn",ސ:"s",ޑ:"d",ޒ:"z",ޓ:"t",ޔ:"y",ޕ:"p",ޖ:"j",ޗ:"ch",ޘ:"tt",ޙ:"hh",ޚ:"kh",ޛ:"th",ޜ:"z",ޝ:"sh",ޞ:"s",ޟ:"d",ޠ:"t",ޡ:"z",ޢ:"a",ޣ:"gh",ޤ:"q",ޥ:"w","ަ":"a","ާ":"aa","ި":"i","ީ":"ee","ު":"u","ޫ":"oo","ެ":"e","ޭ":"ey","ޮ":"o","ޯ":"oa","ް":"",ა:"a",ბ:"b",გ:"g",დ:"d",ე:"e",ვ:"v",ზ:"z",თ:"t",ი:"i",კ:"k",ლ:"l",მ:"m",ნ:"n",ო:"o",პ:"p",ჟ:"zh",რ:"r",ს:"s",ტ:"t",უ:"u",ფ:"p",ქ:"k",ღ:"gh",ყ:"q",შ:"sh",ჩ:"ch",ც:"ts",ძ:"dz",წ:"ts",ჭ:"ch",ხ:"kh",ჯ:"j",ჰ:"h",α:"a",β:"v",γ:"g",δ:"d",ε:"e",ζ:"z",η:"i",θ:"th",ι:"i",κ:"k",λ:"l",μ:"m",ν:"n",ξ:"ks",ο:"o",π:"p",ρ:"r",σ:"s",τ:"t",υ:"y",φ:"f",χ:"x",ψ:"ps",ω:"o",ά:"a",έ:"e",ί:"i",ό:"o",ύ:"y",ή:"i",ώ:"o",ς:"s",ϊ:"i",ΰ:"y",ϋ:"y",ΐ:"i",Α:"A",Β:"B",Γ:"G",Δ:"D",Ε:"E",Ζ:"Z",Η:"I",Θ:"TH",Ι:"I",Κ:"K",Λ:"L",Μ:"M",Ν:"N",Ξ:"KS",Ο:"O",Π:"P",Ρ:"R",Σ:"S",Τ:"T",Υ:"Y",Φ:"F",Χ:"X",Ψ:"PS",Ω:"O",Ά:"A",Έ:"E",Ί:"I",Ό:"O",Ύ:"Y",Ή:"I",Ώ:"O",Ϊ:"I",Ϋ:"Y",ā:"a",ē:"e",ģ:"g",ī:"i",ķ:"k",ļ:"l",ņ:"n",ū:"u",Ā:"A",Ē:"E",Ģ:"G",Ī:"I",Ķ:"k",Ļ:"L",Ņ:"N",Ū:"U",Ќ:"Kj",ќ:"kj",Љ:"Lj",љ:"lj",Њ:"Nj",њ:"nj",Тс:"Ts",тс:"ts",ą:"a",ć:"c",ę:"e",ł:"l",ń:"n",ś:"s",ź:"z",ż:"z",Ą:"A",Ć:"C",Ę:"E",Ł:"L",Ń:"N",Ś:"S",Ź:"Z",Ż:"Z",Є:"Ye",І:"I",Ї:"Yi",Ґ:"G",є:"ye",і:"i",ї:"yi",ґ:"g",ă:"a",Ă:"A",ș:"s",Ș:"S",ț:"t",Ț:"T",ţ:"t",Ţ:"T",а:"a",б:"b",в:"v",г:"g",д:"d",е:"e",ё:"yo",ж:"zh",з:"z",и:"i",й:"i",к:"k",л:"l",м:"m",н:"n",о:"o",п:"p",р:"r",с:"s",т:"t",у:"u",ф:"f",х:"kh",ц:"c",ч:"ch",ш:"sh",щ:"sh",ъ:"",ы:"y",ь:"",э:"e",ю:"yu",я:"ya",А:"A",Б:"B",В:"V",Г:"G",Д:"D",Е:"E",Ё:"Yo",Ж:"Zh",З:"Z",И:"I",Й:"I",К:"K",Л:"L",М:"M",Н:"N",О:"O",П:"P",Р:"R",С:"S",Т:"T",У:"U",Ф:"F",Х:"Kh",Ц:"C",Ч:"Ch",Ш:"Sh",Щ:"Sh",Ъ:"",Ы:"Y",Ь:"",Э:"E",Ю:"Yu",Я:"Ya",ђ:"dj",ј:"j",ћ:"c",џ:"dz",Ђ:"Dj",Ј:"j",Ћ:"C",Џ:"Dz",ľ:"l",ĺ:"l",ŕ:"r",Ľ:"L",Ĺ:"L",Ŕ:"R",ş:"s",Ş:"S",ı:"i",İ:"I",ğ:"g",Ğ:"G",ả:"a",Ả:"A",ẳ:"a",Ẳ:"A",ẩ:"a",Ẩ:"A",đ:"d",Đ:"D",ẹ:"e",Ẹ:"E",ẽ:"e",Ẽ:"E",ẻ:"e",Ẻ:"E",ế:"e",Ế:"E",ề:"e",Ề:"E",ệ:"e",Ệ:"E",ễ:"e",Ễ:"E",ể:"e",Ể:"E",ỏ:"o",ọ:"o",Ọ:"o",ố:"o",Ố:"O",ồ:"o",Ồ:"O",ổ:"o",Ổ:"O",ộ:"o",Ộ:"O",ỗ:"o",Ỗ:"O",ơ:"o",Ơ:"O",ớ:"o",Ớ:"O",ờ:"o",Ờ:"O",ợ:"o",Ợ:"O",ỡ:"o",Ỡ:"O",Ở:"o",ở:"o",ị:"i",Ị:"I",ĩ:"i",Ĩ:"I",ỉ:"i",Ỉ:"i",ủ:"u",Ủ:"U",ụ:"u",Ụ:"U",ũ:"u",Ũ:"U",ư:"u",Ư:"U",ứ:"u",Ứ:"U",ừ:"u",Ừ:"U",ự:"u",Ự:"U",ữ:"u",Ữ:"U",ử:"u",Ử:"ư",ỷ:"y",Ỷ:"y",ỳ:"y",Ỳ:"Y",ỵ:"y",Ỵ:"Y",ỹ:"y",Ỹ:"Y",ạ:"a",Ạ:"A",ấ:"a",Ấ:"A",ầ:"a",Ầ:"A",ậ:"a",Ậ:"A",ẫ:"a",Ẫ:"A",ắ:"a",Ắ:"A",ằ:"a",Ằ:"A",ặ:"a",Ặ:"A",ẵ:"a",Ẵ:"A","⓪":"0","①":"1","②":"2","③":"3","④":"4","⑤":"5","⑥":"6","⑦":"7","⑧":"8","⑨":"9","⑩":"10","⑪":"11","⑫":"12","⑬":"13","⑭":"14","⑮":"15","⑯":"16","⑰":"17","⑱":"18","⑲":"18","⑳":"18","⓵":"1","⓶":"2","⓷":"3","⓸":"4","⓹":"5","⓺":"6","⓻":"7","⓼":"8","⓽":"9","⓾":"10","⓿":"0","⓫":"11","⓬":"12","⓭":"13","⓮":"14","⓯":"15","⓰":"16","⓱":"17","⓲":"18","⓳":"19","⓴":"20","Ⓐ":"A","Ⓑ":"B","Ⓒ":"C","Ⓓ":"D","Ⓔ":"E","Ⓕ":"F","Ⓖ":"G","Ⓗ":"H","Ⓘ":"I","Ⓙ":"J","Ⓚ":"K","Ⓛ":"L","Ⓜ":"M","Ⓝ":"N","Ⓞ":"O","Ⓟ":"P","Ⓠ":"Q","Ⓡ":"R","Ⓢ":"S","Ⓣ":"T","Ⓤ":"U","Ⓥ":"V","Ⓦ":"W","Ⓧ":"X","Ⓨ":"Y","Ⓩ":"Z","ⓐ":"a","ⓑ":"b","ⓒ":"c","ⓓ":"d","ⓔ":"e","ⓕ":"f","ⓖ":"g","ⓗ":"h","ⓘ":"i","ⓙ":"j","ⓚ":"k","ⓛ":"l","ⓜ":"m","ⓝ":"n","ⓞ":"o","ⓟ":"p","ⓠ":"q","ⓡ":"r","ⓢ":"s","ⓣ":"t","ⓤ":"u","ⓦ":"v","ⓥ":"w","ⓧ":"x","ⓨ":"y","ⓩ":"z","“":'"',"”":'"',"‘":"'","’":"'","∂":"d",ƒ:"f","™":"(TM)","©":"(C)",œ:"oe",Œ:"OE","®":"(R)","†":"+","℠":"(SM)","…":"...","˚":"o",º:"o",ª:"a","•":"*","၊":",","။":".",$:"USD","€":"EUR","₢":"BRN","₣":"FRF","£":"GBP","₤":"ITL","₦":"NGN","₧":"ESP","₩":"KRW","₪":"ILS","₫":"VND","₭":"LAK","₮":"MNT","₯":"GRD","₱":"ARS","₲":"PYG","₳":"ARA","₴":"UAH","₵":"GHS","¢":"cent","¥":"CNY",元:"CNY",円:"YEN","﷼":"IRR","₠":"EWE","฿":"THB","₨":"INR","₹":"INR","₰":"PF","₺":"TRY","؋":"AFN","₼":"AZN",лв:"BGN","៛":"KHR","₡":"CRC","₸":"KZT",ден:"MKD",zł:"PLN","₽":"RUB","₾":"GEL"},r=["်","ް"],a={"ာ":"a","ါ":"a","ေ":"e","ဲ":"e","ိ":"i","ီ":"i","ို":"o","ု":"u","ူ":"u","ေါင်":"aung","ော":"aw","ော်":"aw","ေါ":"aw","ေါ်":"aw","်":"်","က်":"et","ိုက်":"aik","ောက်":"auk","င်":"in","ိုင်":"aing","ောင်":"aung","စ်":"it","ည်":"i","တ်":"at","ိတ်":"eik","ုတ်":"ok","ွတ်":"ut","ေတ်":"it","ဒ်":"d","ိုဒ်":"ok","ုဒ်":"ait","န်":"an","ာန်":"an","ိန်":"ein","ုန်":"on","ွန်":"un","ပ်":"at","ိပ်":"eik","ုပ်":"ok","ွပ်":"ut","န်ုပ်":"nub","မ်":"an","ိမ်":"ein","ုမ်":"on","ွမ်":"un","ယ်":"e","ိုလ်":"ol","ဉ်":"in","ံ":"an","ိံ":"ein","ုံ":"on","ައް":"ah","ަށް":"ah"},i={en:{},az:{ç:"c",ə:"e",ğ:"g",ı:"i",ö:"o",ş:"s",ü:"u",Ç:"C",Ə:"E",Ğ:"G",İ:"I",Ö:"O",Ş:"S",Ü:"U"},cs:{č:"c",ď:"d",ě:"e",ň:"n",ř:"r",š:"s",ť:"t",ů:"u",ž:"z",Č:"C",Ď:"D",Ě:"E",Ň:"N",Ř:"R",Š:"S",Ť:"T",Ů:"U",Ž:"Z"},fi:{ä:"a",Ä:"A",ö:"o",Ö:"O"},hu:{ä:"a",Ä:"A",ö:"o",Ö:"O",ü:"u",Ü:"U",ű:"u",Ű:"U"},lt:{ą:"a",č:"c",ę:"e",ė:"e",į:"i",š:"s",ų:"u",ū:"u",ž:"z",Ą:"A",Č:"C",Ę:"E",Ė:"E",Į:"I",Š:"S",Ų:"U",Ū:"U"},lv:{ā:"a",č:"c",ē:"e",ģ:"g",ī:"i",ķ:"k",ļ:"l",ņ:"n",š:"s",ū:"u",ž:"z",Ā:"A",Č:"C",Ē:"E",Ģ:"G",Ī:"i",Ķ:"k",Ļ:"L",Ņ:"N",Š:"S",Ū:"u",Ž:"Z"},pl:{ą:"a",ć:"c",ę:"e",ł:"l",ń:"n",ó:"o",ś:"s",ź:"z",ż:"z",Ą:"A",Ć:"C",Ę:"e",Ł:"L",Ń:"N",Ó:"O",Ś:"S",Ź:"Z",Ż:"Z"},sv:{ä:"a",Ä:"A",ö:"o",Ö:"O"},sk:{ä:"a",Ä:"A"},sr:{љ:"lj",њ:"nj",Љ:"Lj",Њ:"Nj",đ:"dj",Đ:"Dj"},tr:{Ü:"U",Ö:"O",ü:"u",ö:"o"}},l={ar:{"∆":"delta","∞":"la-nihaya","♥":"hob","&":"wa","|":"aw","<":"aqal-men",">":"akbar-men","∑":"majmou","¤":"omla"},az:{},ca:{"∆":"delta","∞":"infinit","♥":"amor","&":"i","|":"o","<":"menys que",">":"mes que","∑":"suma dels","¤":"moneda"},cs:{"∆":"delta","∞":"nekonecno","♥":"laska","&":"a","|":"nebo","<":"mensi nez",">":"vetsi nez","∑":"soucet","¤":"mena"},de:{"∆":"delta","∞":"unendlich","♥":"Liebe","&":"und","|":"oder","<":"kleiner als",">":"groesser als","∑":"Summe von","¤":"Waehrung"},dv:{"∆":"delta","∞":"kolunulaa","♥":"loabi","&":"aai","|":"noonee","<":"ah vure kuda",">":"ah vure bodu","∑":"jumula","¤":"faisaa"},en:{"∆":"delta","∞":"infinity","♥":"love","&":"and","|":"or","<":"less than",">":"greater than","∑":"sum","¤":"currency"},es:{"∆":"delta","∞":"infinito","♥":"amor","&":"y","|":"u","<":"menos que",">":"mas que","∑":"suma de los","¤":"moneda"},fa:{"∆":"delta","∞":"bi-nahayat","♥":"eshgh","&":"va","|":"ya","<":"kamtar-az",">":"bishtar-az","∑":"majmooe","¤":"vahed"},fi:{"∆":"delta","∞":"aarettomyys","♥":"rakkaus","&":"ja","|":"tai","<":"pienempi kuin",">":"suurempi kuin","∑":"summa","¤":"valuutta"},fr:{"∆":"delta","∞":"infiniment","♥":"Amour","&":"et","|":"ou","<":"moins que",">":"superieure a","∑":"somme des","¤":"monnaie"},ge:{"∆":"delta","∞":"usasruloba","♥":"siqvaruli","&":"da","|":"an","<":"naklebi",">":"meti","∑":"jami","¤":"valuta"},gr:{},hu:{"∆":"delta","∞":"vegtelen","♥":"szerelem","&":"es","|":"vagy","<":"kisebb mint",">":"nagyobb mint","∑":"szumma","¤":"penznem"},it:{"∆":"delta","∞":"infinito","♥":"amore","&":"e","|":"o","<":"minore di",">":"maggiore di","∑":"somma","¤":"moneta"},lt:{"∆":"delta","∞":"begalybe","♥":"meile","&":"ir","|":"ar","<":"maziau nei",">":"daugiau nei","∑":"suma","¤":"valiuta"},lv:{"∆":"delta","∞":"bezgaliba","♥":"milestiba","&":"un","|":"vai","<":"mazak neka",">":"lielaks neka","∑":"summa","¤":"valuta"},my:{"∆":"kwahkhyaet","∞":"asaonasme","♥":"akhyait","&":"nhin","|":"tho","<":"ngethaw",">":"kyithaw","∑":"paungld","¤":"ngwekye"},mk:{},nl:{"∆":"delta","∞":"oneindig","♥":"liefde","&":"en","|":"of","<":"kleiner dan",">":"groter dan","∑":"som","¤":"valuta"},pl:{"∆":"delta","∞":"nieskonczonosc","♥":"milosc","&":"i","|":"lub","<":"mniejsze niz",">":"wieksze niz","∑":"suma","¤":"waluta"},pt:{"∆":"delta","∞":"infinito","♥":"amor","&":"e","|":"ou","<":"menor que",">":"maior que","∑":"soma","¤":"moeda"},ro:{"∆":"delta","∞":"infinit","♥":"dragoste","&":"si","|":"sau","<":"mai mic ca",">":"mai mare ca","∑":"suma","¤":"valuta"},ru:{"∆":"delta","∞":"beskonechno","♥":"lubov","&":"i","|":"ili","<":"menshe",">":"bolshe","∑":"summa","¤":"valjuta"},sk:{"∆":"delta","∞":"nekonecno","♥":"laska","&":"a","|":"alebo","<":"menej ako",">":"viac ako","∑":"sucet","¤":"mena"},sr:{},tr:{"∆":"delta","∞":"sonsuzluk","♥":"ask","&":"ve","|":"veya","<":"kucuktur",">":"buyuktur","∑":"toplam","¤":"para birimi"},uk:{"∆":"delta","∞":"bezkinechnist","♥":"lubov","&":"i","|":"abo","<":"menshe",">":"bilshe","∑":"suma","¤":"valjuta"},vn:{"∆":"delta","∞":"vo cuc","♥":"yeu","&":"va","|":"hoac","<":"nho hon",">":"lon hon","∑":"tong","¤":"tien te"}},c=[";","?",":","@","&","=","+","$",",","/"].join(""),u=[";","?",":","@","&","=","+","$",","].join(""),d=[".","!","~","*","'","(",")"].join(""),f=function(b,h){var k="-",O="",V="",A=!0,x={},R,y,T,v,g,E,I,D,G,H,C,Y,P,L,ae="";if(typeof b!="string")return"";if(typeof h=="string"&&(k=h),I=l.en,D=i.en,typeof h=="object"){R=h.maintainCase||!1,x=h.custom&&typeof h.custom=="object"?h.custom:x,T=+h.truncate>1&&h.truncate||!1,v=h.uric||!1,g=h.uricNoSlash||!1,E=h.mark||!1,A=!(h.symbols===!1||h.lang===!1),k=h.separator||k,v&&(ae+=c),g&&(ae+=u),E&&(ae+=d),I=h.lang&&l[h.lang]&&A?l[h.lang]:A?l.en:{},D=h.lang&&i[h.lang]?i[h.lang]:h.lang===!1||h.lang===!0?{}:i.en,h.titleCase&&typeof h.titleCase.length=="number"&&Array.prototype.toString.call(h.titleCase)?(h.titleCase.forEach(function(J){x[J+""]=J+""}),y=!0):y=!!h.titleCase,h.custom&&typeof h.custom.length=="number"&&Array.prototype.toString.call(h.custom)&&h.custom.forEach(function(J){x[J+""]=J+""}),Object.keys(x).forEach(function(J){var Ke;J.length>1?Ke=new RegExp("\\b"+m(J)+"\\b","gi"):Ke=new RegExp(m(J),"gi"),b=b.replace(Ke,x[J])});for(C in x)ae+=C}for(ae+=k,ae=m(ae),b=b.replace(/(^\s+|\s+$)/g,""),P=!1,L=!1,H=0,Y=b.length;H<Y;H++)C=b[H],_(C,x)?P=!1:D[C]?(C=P&&D[C].match(/[A-Za-z0-9]/)?" "+D[C]:D[C],P=!1):C in o?(H+1<Y&&r.indexOf(b[H+1])>=0?(V+=C,C=""):L===!0?(C=a[V]+o[C],V=""):C=P&&o[C].match(/[A-Za-z0-9]/)?" "+o[C]:o[C],P=!1,L=!1):C in a?(V+=C,C="",H===Y-1&&(C=a[V]),L=!0):I[C]&&!(v&&c.indexOf(C)!==-1)&&!(g&&u.indexOf(C)!==-1)?(C=P||O.substr(-1).match(/[A-Za-z0-9]/)?k+I[C]:I[C],C+=b[H+1]!==void 0&&b[H+1].match(/[A-Za-z0-9]/)?k:"",P=!0):(L===!0?(C=a[V]+C,V="",L=!1):P&&(/[A-Za-z0-9]/.test(C)||O.substr(-1).match(/A-Za-z0-9]/))&&(C=" "+C),P=!1),O+=C.replace(new RegExp("[^\\w\\s"+ae+"_-]","g"),k);return y&&(O=O.replace(/(\w)(\S*)/g,function(J,Ke,Hr){var cn=Ke.toUpperCase()+(Hr!==null?Hr:"");return Object.keys(x).indexOf(cn.toLowerCase())<0?cn:cn.toLowerCase()})),O=O.replace(/\s+/g,k).replace(new RegExp("\\"+k+"+","g"),k).replace(new RegExp("(^\\"+k+"+|\\"+k+"+$)","g"),""),T&&O.length>T&&(G=O.charAt(T)===k,O=O.slice(0,T),G||(O=O.slice(0,O.lastIndexOf(k)))),!R&&!y&&(O=O.toLowerCase()),O},p=function(b){return function(h){return f(h,b)}},m=function(b){return b.replace(/[-\\^$*+?.()|[\]{}\/]/g,"\\$&")},_=function(b,h){for(var k in h)if(h[k]===b)return!0};if(typeof t<"u"&&t.exports)t.exports=f,t.exports.createSlug=p;else if(typeof define<"u"&&define.amd)define([],function(){return f});else try{if(n.getSlug||n.createSlug)throw"speakingurl: globals exists /(getSlug|createSlug)/";n.getSlug=f,n.createSlug=p}catch{}}(e)}}),qs=On({"../../node_modules/.pnpm/speakingurl@14.0.1/node_modules/speakingurl/index.js"(e,t){w(),t.exports=Ys()}});w(),w(),w(),w(),w(),w(),w(),w();function Js(e){var t;const n=e.name||e._componentTag||e.__VUE_DEVTOOLS_COMPONENT_GUSSED_NAME__||e.__name;return n==="index"&&(t=e.__file)!=null&&t.endsWith("index.vue")?"":n}function Xs(e){const t=e.__file;if(t)return Ds(Rs(t,".vue"))}function Sn(e,t){return e.type.__VUE_DEVTOOLS_COMPONENT_GUSSED_NAME__=t,t}function yt(e){if(e.__VUE_DEVTOOLS_NEXT_APP_RECORD__)return e.__VUE_DEVTOOLS_NEXT_APP_RECORD__;if(e.root)return e.appContext.app.__VUE_DEVTOOLS_NEXT_APP_RECORD__}function Tn(e){var t,n;const o=(t=e.subTree)==null?void 0:t.type,r=yt(e);return r?((n=r==null?void 0:r.types)==null?void 0:n.Fragment)===o:!1}function Fe(e){var t,n,o;const r=Js((e==null?void 0:e.type)||{});if(r)return r;if((e==null?void 0:e.root)===e)return"Root";for(const i in(n=(t=e.parent)==null?void 0:t.type)==null?void 0:n.components)if(e.parent.type.components[i]===(e==null?void 0:e.type))return Sn(e,i);for(const i in(o=e.appContext)==null?void 0:o.components)if(e.appContext.components[i]===(e==null?void 0:e.type))return Sn(e,i);return Xs((e==null?void 0:e.type)||{})||"Anonymous Component"}function Zs(e){var t,n,o;const r=(o=(n=(t=e==null?void 0:e.appContext)==null?void 0:t.app)==null?void 0:n.__VUE_DEVTOOLS_NEXT_APP_RECORD_ID__)!=null?o:0,a=e===(e==null?void 0:e.root)?"root":e.uid;return`${r}:${a}`}function Et(e,t){return t=t||`${e.id}:root`,e.instanceMap.get(t)||e.instanceMap.get(":root")}function Qs(){const e={top:0,bottom:0,left:0,right:0,get width(){return e.right-e.left},get height(){return e.bottom-e.top}};return e}var We;function ea(e){return We||(We=document.createRange()),We.selectNode(e),We.getBoundingClientRect()}function ta(e){const t=Qs();if(!e.children)return t;for(let n=0,o=e.children.length;n<o;n++){const r=e.children[n];let a;if(r.component)a=ie(r.component);else if(r.el){const i=r.el;i.nodeType===1||i.getBoundingClientRect?a=i.getBoundingClientRect():i.nodeType===3&&i.data.trim()&&(a=ea(i))}a&&na(t,a)}return t}function na(e,t){return(!e.top||t.top<e.top)&&(e.top=t.top),(!e.bottom||t.bottom>e.bottom)&&(e.bottom=t.bottom),(!e.left||t.left<e.left)&&(e.left=t.left),(!e.right||t.right>e.right)&&(e.right=t.right),e}var In={top:0,left:0,right:0,bottom:0,width:0,height:0};function ie(e){const t=e.subTree.el;return typeof window>"u"?In:Tn(e)?ta(e.subTree):(t==null?void 0:t.nodeType)===1?t==null?void 0:t.getBoundingClientRect():e.subTree.component?ie(e.subTree.component):In}w();function wt(e){return Tn(e)?oa(e.subTree):e.subTree?[e.subTree.el]:[]}function oa(e){if(!e.children)return[];const t=[];return e.children.forEach(n=>{n.component?t.push(...wt(n.component)):n!=null&&n.el&&t.push(n.el)}),t}var Vn="__vue-devtools-component-inspector__",Cn="__vue-devtools-component-inspector__card__",Pn="__vue-devtools-component-inspector__name__",Nn="__vue-devtools-component-inspector__indicator__",Dn={display:"block",zIndex:2147483640,position:"fixed",backgroundColor:"#42b88325",border:"1px solid #42b88350",borderRadius:"5px",transition:"all 0.1s ease-in",pointerEvents:"none"},ra={fontFamily:"Arial, Helvetica, sans-serif",padding:"5px 8px",borderRadius:"4px",textAlign:"left",position:"absolute",left:0,color:"#e9e9e9",fontSize:"14px",fontWeight:600,lineHeight:"24px",backgroundColor:"#42b883",boxShadow:"0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1)"},sa={display:"inline-block",fontWeight:400,fontStyle:"normal",fontSize:"12px",opacity:.7};function he(){return document.getElementById(Vn)}function aa(){return document.getElementById(Cn)}function ia(){return document.getElementById(Nn)}function la(){return document.getElementById(Pn)}function bt(e){return{left:`${Math.round(e.left*100)/100}px`,top:`${Math.round(e.top*100)/100}px`,width:`${Math.round(e.width*100)/100}px`,height:`${Math.round(e.height*100)/100}px`}}function vt(e){var t;const n=document.createElement("div");n.id=(t=e.elementId)!=null?t:Vn,Object.assign(n.style,{...Dn,...bt(e.bounds),...e.style});const o=document.createElement("span");o.id=Cn,Object.assign(o.style,{...ra,top:e.bounds.top<35?0:"-35px"});const r=document.createElement("span");r.id=Pn,r.innerHTML=`<${e.name}> `;const a=document.createElement("i");return a.id=Nn,a.innerHTML=`${Math.round(e.bounds.width*100)/100} x ${Math.round(e.bounds.height*100)/100}`,Object.assign(a.style,sa),o.appendChild(r),o.appendChild(a),n.appendChild(o),document.body.appendChild(n),n}function kt(e){const t=he(),n=aa(),o=la(),r=ia();t&&(Object.assign(t.style,{...Dn,...bt(e.bounds)}),Object.assign(n.style,{top:e.bounds.top<35?0:"-35px"}),o.innerHTML=`<${e.name}> `,r.innerHTML=`${Math.round(e.bounds.width*100)/100} x ${Math.round(e.bounds.height*100)/100}`)}function ca(e){const t=ie(e);if(!t.width&&!t.height)return;const n=Fe(e);he()?kt({bounds:t,name:n}):vt({bounds:t,name:n})}function Rn(){const e=he();e&&(e.style.display="none")}var Ot=null;function St(e){const t=e.target;if(t){const n=t.__vueParentComponent;if(n&&(Ot=n,n.vnode.el)){const o=ie(n),r=Fe(n);he()?kt({bounds:o,name:r}):vt({bounds:o,name:r})}}}function ua(e,t){if(e.preventDefault(),e.stopPropagation(),Ot){const n=Zs(Ot);t(n)}}var Ge=null;function da(){Rn(),window.removeEventListener("mouseover",St),window.removeEventListener("click",Ge,!0),Ge=null}function fa(){return window.addEventListener("mouseover",St),new Promise(e=>{function t(n){n.preventDefault(),n.stopPropagation(),ua(n,o=>{window.removeEventListener("click",t,!0),Ge=null,window.removeEventListener("mouseover",St);const r=he();r&&(r.style.display="none"),e(JSON.stringify({id:o}))})}Ge=t,window.addEventListener("click",t,!0)})}function pa(e){const t=Et(B.value,e.id);if(t){const[n]=wt(t);if(typeof n.scrollIntoView=="function")n.scrollIntoView({behavior:"smooth"});else{const o=ie(t),r=document.createElement("div"),a={...bt(o),position:"absolute"};Object.assign(r.style,a),document.body.appendChild(r),r.scrollIntoView({behavior:"smooth"}),setTimeout(()=>{document.body.removeChild(r)},2e3)}setTimeout(()=>{const o=ie(t);if(o.width||o.height){const r=Fe(t),a=he();a?kt({...e,name:r,bounds:o}):vt({...e,name:r,bounds:o}),setTimeout(()=>{a&&(a.style.display="none")},1500)}},1200)}}w();var xn;(xn=S).__VUE_DEVTOOLS_COMPONENT_INSPECTOR_ENABLED__!=null||(xn.__VUE_DEVTOOLS_COMPONENT_INSPECTOR_ENABLED__=!0);function ma(e){let t=0;const n=setInterval(()=>{S.__VUE_INSPECTOR__&&(clearInterval(n),t+=30,e()),t>=5e3&&clearInterval(n)},30)}function ha(){const e=S.__VUE_INSPECTOR__,t=e.openInEditor;e.openInEditor=async(...n)=>{e.disable(),t(...n)}}function _a(){return new Promise(e=>{function t(){ha(),e(S.__VUE_INSPECTOR__)}S.__VUE_INSPECTOR__?t():ma(()=>{t()})})}w(),w();function ga(e){return!!(e&&e.__v_isReadonly)}function An(e){return ga(e)?An(e.__v_raw):!!(e&&e.__v_isReactive)}function Tt(e){return!!(e&&e.__v_isRef===!0)}function Ce(e){const t=e&&e.__v_raw;return t?Ce(t):e}var ya=class{constructor(){this.refEditor=new Ea}set(e,t,n,o){const r=Array.isArray(t)?t:t.split(".");for(;r.length>1;){const l=r.shift();e instanceof Map&&(e=e.get(l)),e instanceof Set?e=Array.from(e.values())[l]:e=e[l],this.refEditor.isRef(e)&&(e=this.refEditor.get(e))}const a=r[0],i=this.refEditor.get(e)[a];o?o(e,a,n):this.refEditor.isRef(i)?this.refEditor.set(i,n):e[a]=n}get(e,t){const n=Array.isArray(t)?t:t.split(".");for(let o=0;o<n.length;o++)if(e instanceof Map?e=e.get(n[o]):e=e[n[o]],this.refEditor.isRef(e)&&(e=this.refEditor.get(e)),!e)return;return e}has(e,t,n=!1){if(typeof e>"u")return!1;const o=Array.isArray(t)?t.slice():t.split("."),r=n?2:1;for(;e&&o.length>r;){const a=o.shift();e=e[a],this.refEditor.isRef(e)&&(e=this.refEditor.get(e))}return e!=null&&Object.prototype.hasOwnProperty.call(e,o[0])}createDefaultSetCallback(e){return(t,n,o)=>{if((e.remove||e.newKey)&&(Array.isArray(t)?t.splice(n,1):Ce(t)instanceof Map?t.delete(n):Ce(t)instanceof Set?t.delete(Array.from(t.values())[n]):Reflect.deleteProperty(t,n)),!e.remove){const r=t[e.newKey||n];this.refEditor.isRef(r)?this.refEditor.set(r,o):Ce(t)instanceof Map?t.set(e.newKey||n,o):Ce(t)instanceof Set?t.add(o):t[e.newKey||n]=o}}}},Ea=class{set(e,t){if(Tt(e))e.value=t;else{if(e instanceof Set&&Array.isArray(t)){e.clear(),t.forEach(r=>e.add(r));return}const n=Object.keys(t);if(e instanceof Map){const r=new Set(e.keys());n.forEach(a=>{e.set(a,Reflect.get(t,a)),r.delete(a)}),r.forEach(a=>e.delete(a));return}const o=new Set(Object.keys(e));n.forEach(r=>{Reflect.set(e,r,Reflect.get(t,r)),o.delete(r)}),o.forEach(r=>Reflect.deleteProperty(e,r))}}get(e){return Tt(e)?e.value:e}isRef(e){return Tt(e)||An(e)}};w(),w(),w();var wa="__VUE_DEVTOOLS_KIT_TIMELINE_LAYERS_STATE__";function ba(){if(!yn||typeof localStorage>"u"||localStorage===null)return{recordingState:!1,mouseEventEnabled:!1,keyboardEventEnabled:!1,componentEventEnabled:!1,performanceEventEnabled:!1,selected:""};const e=localStorage.getItem(wa);return e?JSON.parse(e):{recordingState:!1,mouseEventEnabled:!1,keyboardEventEnabled:!1,componentEventEnabled:!1,performanceEventEnabled:!1,selected:""}}w(),w(),w();var $n;($n=S).__VUE_DEVTOOLS_KIT_TIMELINE_LAYERS!=null||($n.__VUE_DEVTOOLS_KIT_TIMELINE_LAYERS=[]);var va=new Proxy(S.__VUE_DEVTOOLS_KIT_TIMELINE_LAYERS,{get(e,t,n){return Reflect.get(e,t,n)}});function ka(e,t){$.timelineLayersState[t.id]=!1,va.push({...e,descriptorId:t.id,appRecord:yt(t.app)})}var Ln;(Ln=S).__VUE_DEVTOOLS_KIT_INSPECTOR__!=null||(Ln.__VUE_DEVTOOLS_KIT_INSPECTOR__=[]);var It=new Proxy(S.__VUE_DEVTOOLS_KIT_INSPECTOR__,{get(e,t,n){return Reflect.get(e,t,n)}}),jn=me(()=>{ge.hooks.callHook("sendInspectorToClient",Un())});function Oa(e,t){var n,o;It.push({options:e,descriptor:t,treeFilterPlaceholder:(n=e.treeFilterPlaceholder)!=null?n:"Search tree...",stateFilterPlaceholder:(o=e.stateFilterPlaceholder)!=null?o:"Search state...",treeFilter:"",selectedNodeId:"",appRecord:yt(t.app)}),jn()}function Un(){return It.filter(e=>e.descriptor.app===B.value.app).filter(e=>e.descriptor.id!=="components").map(e=>{var t;const n=e.descriptor,o=e.options;return{id:o.id,label:o.label,logo:n.logo,icon:`custom-ic-baseline-${(t=o==null?void 0:o.icon)==null?void 0:t.replace(/_/g,"-")}`,packageName:n.packageName,homepage:n.homepage,pluginId:n.id}})}function Ye(e,t){return It.find(n=>n.options.id===e&&(t?n.descriptor.app===t:!0))}function Sa(){const e=vn();e.hook("addInspector",({inspector:o,plugin:r})=>{Oa(o,r.descriptor)});const t=me(async({inspectorId:o,plugin:r})=>{var a;if(!o||!((a=r==null?void 0:r.descriptor)!=null&&a.app)||$.highPerfModeEnabled)return;const i=Ye(o,r.descriptor.app),l={app:r.descriptor.app,inspectorId:o,filter:(i==null?void 0:i.treeFilter)||"",rootNodes:[]};await new Promise(c=>{e.callHookWith(async u=>{await Promise.all(u.map(d=>d(l))),c()},"getInspectorTree")}),e.callHookWith(async c=>{await Promise.all(c.map(u=>u({inspectorId:o,rootNodes:l.rootNodes})))},"sendInspectorTreeToClient")},120);e.hook("sendInspectorTree",t);const n=me(async({inspectorId:o,plugin:r})=>{var a;if(!o||!((a=r==null?void 0:r.descriptor)!=null&&a.app)||$.highPerfModeEnabled)return;const i=Ye(o,r.descriptor.app),l={app:r.descriptor.app,inspectorId:o,nodeId:(i==null?void 0:i.selectedNodeId)||"",state:null},c={currentTab:`custom-inspector:${o}`};l.nodeId&&await new Promise(u=>{e.callHookWith(async d=>{await Promise.all(d.map(f=>f(l,c))),u()},"getInspectorState")}),e.callHookWith(async u=>{await Promise.all(u.map(d=>d({inspectorId:o,nodeId:l.nodeId,state:l.state})))},"sendInspectorStateToClient")},120);return e.hook("sendInspectorState",n),e.hook("customInspectorSelectNode",({inspectorId:o,nodeId:r,plugin:a})=>{const i=Ye(o,a.descriptor.app);i&&(i.selectedNodeId=r)}),e.hook("timelineLayerAdded",({options:o,plugin:r})=>{ka(o,r.descriptor)}),e.hook("timelineEventAdded",({options:o,plugin:r})=>{var a;const i=["performance","component-event","keyboard","mouse"];$.highPerfModeEnabled||!((a=$.timelineLayersState)!=null&&a[r.descriptor.id])&&!i.includes(o.layerId)||e.callHookWith(async l=>{await Promise.all(l.map(c=>c(o)))},"sendTimelineEventToClient")}),e.hook("getComponentInstances",async({app:o})=>{const r=o.__VUE_DEVTOOLS_NEXT_APP_RECORD__;if(!r)return null;const a=r.id.toString();return[...r.instanceMap].filter(([i])=>i.split(":")[0]===a).map(([,i])=>i)}),e.hook("getComponentBounds",async({instance:o})=>ie(o)),e.hook("getComponentName",({instance:o})=>Fe(o)),e.hook("componentHighlight",({uid:o})=>{const r=B.value.instanceMap.get(o);r&&ca(r)}),e.hook("componentUnhighlight",()=>{Rn()}),e}var Mn;(Mn=S).__VUE_DEVTOOLS_KIT_APP_RECORDS__!=null||(Mn.__VUE_DEVTOOLS_KIT_APP_RECORDS__=[]);var Bn;(Bn=S).__VUE_DEVTOOLS_KIT_ACTIVE_APP_RECORD__!=null||(Bn.__VUE_DEVTOOLS_KIT_ACTIVE_APP_RECORD__={});var Hn;(Hn=S).__VUE_DEVTOOLS_KIT_ACTIVE_APP_RECORD_ID__!=null||(Hn.__VUE_DEVTOOLS_KIT_ACTIVE_APP_RECORD_ID__="");var zn;(zn=S).__VUE_DEVTOOLS_KIT_CUSTOM_TABS__!=null||(zn.__VUE_DEVTOOLS_KIT_CUSTOM_TABS__=[]);var Kn;(Kn=S).__VUE_DEVTOOLS_KIT_CUSTOM_COMMANDS__!=null||(Kn.__VUE_DEVTOOLS_KIT_CUSTOM_COMMANDS__=[]);var le="__VUE_DEVTOOLS_KIT_GLOBAL_STATE__";function Ta(){return{connected:!1,clientConnected:!1,vitePluginDetected:!0,appRecords:[],activeAppRecordId:"",tabs:[],commands:[],highPerfModeEnabled:!0,devtoolsClientDetected:{},perfUniqueGroupId:0,timelineLayersState:ba()}}var Fn;(Fn=S)[le]!=null||(Fn[le]=Ta());var Ia=me(e=>{ge.hooks.callHook("devtoolsStateUpdated",{state:e})});me((e,t)=>{ge.hooks.callHook("devtoolsConnectedUpdated",{state:e,oldState:t})});var qe=new Proxy(S.__VUE_DEVTOOLS_KIT_APP_RECORDS__,{get(e,t,n){return t==="value"?S.__VUE_DEVTOOLS_KIT_APP_RECORDS__:S.__VUE_DEVTOOLS_KIT_APP_RECORDS__[t]}}),B=new Proxy(S.__VUE_DEVTOOLS_KIT_ACTIVE_APP_RECORD__,{get(e,t,n){return t==="value"?S.__VUE_DEVTOOLS_KIT_ACTIVE_APP_RECORD__:t==="id"?S.__VUE_DEVTOOLS_KIT_ACTIVE_APP_RECORD_ID__:S.__VUE_DEVTOOLS_KIT_ACTIVE_APP_RECORD__[t]}});function Wn(){Ia({...S[le],appRecords:qe.value,activeAppRecordId:B.id,tabs:S.__VUE_DEVTOOLS_KIT_CUSTOM_TABS__,commands:S.__VUE_DEVTOOLS_KIT_CUSTOM_COMMANDS__})}function Va(e){S.__VUE_DEVTOOLS_KIT_ACTIVE_APP_RECORD__=e,Wn()}function Ca(e){S.__VUE_DEVTOOLS_KIT_ACTIVE_APP_RECORD_ID__=e,Wn()}var $=new Proxy(S[le],{get(e,t){return t==="appRecords"?qe:t==="activeAppRecordId"?B.id:t==="tabs"?S.__VUE_DEVTOOLS_KIT_CUSTOM_TABS__:t==="commands"?S.__VUE_DEVTOOLS_KIT_CUSTOM_COMMANDS__:S[le][t]},deleteProperty(e,t){return delete e[t],!0},set(e,t,n){return{...S[le]},e[t]=n,S[le][t]=n,!0}});function Pa(e={}){var t,n,o;const{file:r,host:a,baseUrl:i=window.location.origin,line:l=0,column:c=0}=e;if(r){if(a==="chrome-extension"){const u=r.replace(/\\/g,"\\\\"),d=(n=(t=window.VUE_DEVTOOLS_CONFIG)==null?void 0:t.openInEditorHost)!=null?n:"/";fetch(`${d}__open-in-editor?file=${encodeURI(r)}`).then(f=>{if(!f.ok){const p=`Opening component ${u} failed`;console.log(`%c${p}`,"color:red")}})}else if($.vitePluginDetected){const u=(o=S.__VUE_DEVTOOLS_OPEN_IN_EDITOR_BASE_URL__)!=null?o:i;S.__VUE_INSPECTOR__.openInEditor(u,r,l,c)}}}w(),w(),w(),w(),w();var Gn;(Gn=S).__VUE_DEVTOOLS_KIT_PLUGIN_BUFFER__!=null||(Gn.__VUE_DEVTOOLS_KIT_PLUGIN_BUFFER__=[]);var Vt=new Proxy(S.__VUE_DEVTOOLS_KIT_PLUGIN_BUFFER__,{get(e,t,n){return Reflect.get(e,t,n)}});function Ct(e){const t={};return Object.keys(e).forEach(n=>{t[n]=e[n].defaultValue}),t}function Pt(e){return`__VUE_DEVTOOLS_NEXT_PLUGIN_SETTINGS__${e}__`}function Na(e){var t,n,o;const r=(n=(t=Vt.find(a=>{var i;return a[0].id===e&&!!((i=a[0])!=null&&i.settings)}))==null?void 0:t[0])!=null?n:null;return(o=r==null?void 0:r.settings)!=null?o:null}function Yn(e,t){var n,o,r;const a=Pt(e);if(a){const i=localStorage.getItem(a);if(i)return JSON.parse(i)}if(e){const i=(o=(n=Vt.find(l=>l[0].id===e))==null?void 0:n[0])!=null?o:null;return Ct((r=i==null?void 0:i.settings)!=null?r:{})}return Ct(t)}function Da(e,t){const n=Pt(e);localStorage.getItem(n)||localStorage.setItem(n,JSON.stringify(Ct(t)))}function Ra(e,t,n){const o=Pt(e),r=localStorage.getItem(o),a=JSON.parse(r||"{}"),i={...a,[t]:n};localStorage.setItem(o,JSON.stringify(i)),ge.hooks.callHookWith(l=>{l.forEach(c=>c({pluginId:e,key:t,oldValue:a[t],newValue:n,settings:i}))},"setPluginSettings")}w(),w(),w(),w(),w(),w(),w(),w(),w(),w(),w();var qn,Jn,z=(Jn=(qn=S).__VUE_DEVTOOLS_HOOK)!=null?Jn:qn.__VUE_DEVTOOLS_HOOK=vn(),xa={vueAppInit(e){z.hook("app:init",e)},vueAppUnmount(e){z.hook("app:unmount",e)},vueAppConnected(e){z.hook("app:connected",e)},componentAdded(e){return z.hook("component:added",e)},componentEmit(e){return z.hook("component:emit",e)},componentUpdated(e){return z.hook("component:updated",e)},componentRemoved(e){return z.hook("component:removed",e)},setupDevtoolsPlugin(e){z.hook("devtools-plugin:setup",e)},perfStart(e){return z.hook("perf:start",e)},perfEnd(e){return z.hook("perf:end",e)}},Xn={on:xa,setupDevToolsPlugin(e,t){return z.callHook("devtools-plugin:setup",e,t)}},Aa=class{constructor({plugin:e,ctx:t}){this.hooks=t.hooks,this.plugin=e}get on(){return{visitComponentTree:e=>{this.hooks.hook("visitComponentTree",e)},inspectComponent:e=>{this.hooks.hook("inspectComponent",e)},editComponentState:e=>{this.hooks.hook("editComponentState",e)},getInspectorTree:e=>{this.hooks.hook("getInspectorTree",e)},getInspectorState:e=>{this.hooks.hook("getInspectorState",e)},editInspectorState:e=>{this.hooks.hook("editInspectorState",e)},inspectTimelineEvent:e=>{this.hooks.hook("inspectTimelineEvent",e)},timelineCleared:e=>{this.hooks.hook("timelineCleared",e)},setPluginSettings:e=>{this.hooks.hook("setPluginSettings",e)}}}notifyComponentUpdate(e){var t;if($.highPerfModeEnabled)return;const n=Un().find(o=>o.packageName===this.plugin.descriptor.packageName);if(n!=null&&n.id){if(e){const o=[e.appContext.app,e.uid,(t=e.parent)==null?void 0:t.uid,e];z.callHook("component:updated",...o)}else z.callHook("component:updated");this.hooks.callHook("sendInspectorState",{inspectorId:n.id,plugin:this.plugin})}}addInspector(e){this.hooks.callHook("addInspector",{inspector:e,plugin:this.plugin}),this.plugin.descriptor.settings&&Da(e.id,this.plugin.descriptor.settings)}sendInspectorTree(e){$.highPerfModeEnabled||this.hooks.callHook("sendInspectorTree",{inspectorId:e,plugin:this.plugin})}sendInspectorState(e){$.highPerfModeEnabled||this.hooks.callHook("sendInspectorState",{inspectorId:e,plugin:this.plugin})}selectInspectorNode(e,t){this.hooks.callHook("customInspectorSelectNode",{inspectorId:e,nodeId:t,plugin:this.plugin})}visitComponentTree(e){return this.hooks.callHook("visitComponentTree",e)}now(){return $.highPerfModeEnabled?0:Date.now()}addTimelineLayer(e){this.hooks.callHook("timelineLayerAdded",{options:e,plugin:this.plugin})}addTimelineEvent(e){$.highPerfModeEnabled||this.hooks.callHook("timelineEventAdded",{options:e,plugin:this.plugin})}getSettings(e){return Yn(e??this.plugin.descriptor.id,this.plugin.descriptor.settings)}getComponentInstances(e){return this.hooks.callHook("getComponentInstances",{app:e})}getComponentBounds(e){return this.hooks.callHook("getComponentBounds",{instance:e})}getComponentName(e){return this.hooks.callHook("getComponentName",{instance:e})}highlightElement(e){const t=e.__VUE_DEVTOOLS_NEXT_UID__;return this.hooks.callHook("componentHighlight",{uid:t})}unhighlightElement(){return this.hooks.callHook("componentUnhighlight")}},$a=Aa;w(),w(),w(),w();var La="__vue_devtool_undefined__",ja="__vue_devtool_infinity__",Ua="__vue_devtool_negative_infinity__",Ma="__vue_devtool_nan__";w(),w();var Ba={[La]:"undefined",[Ma]:"NaN",[ja]:"Infinity",[Ua]:"-Infinity"};Object.entries(Ba).reduce((e,[t,n])=>(e[n]=t,e),{}),w(),w(),w(),w(),w();var Zn;(Zn=S).__VUE_DEVTOOLS_KIT__REGISTERED_PLUGIN_APPS__!=null||(Zn.__VUE_DEVTOOLS_KIT__REGISTERED_PLUGIN_APPS__=new Set);function Qn(e,t){return Xn.setupDevToolsPlugin(e,t)}function Ha(e,t){const[n,o]=e;if(n.app!==t)return;const r=new $a({plugin:{setupFn:o,descriptor:n},ctx:ge});n.packageName==="vuex"&&r.on.editInspectorState(a=>{r.sendInspectorState(a.inspectorId)}),o(r)}function eo(e,t){S.__VUE_DEVTOOLS_KIT__REGISTERED_PLUGIN_APPS__.has(e)||$.highPerfModeEnabled&&!(t!=null&&t.inspectingComponent)||(S.__VUE_DEVTOOLS_KIT__REGISTERED_PLUGIN_APPS__.add(e),Vt.forEach(n=>{Ha(n,e)}))}w(),w();var Pe="__VUE_DEVTOOLS_ROUTER__",_e="__VUE_DEVTOOLS_ROUTER_INFO__",to;(to=S)[_e]!=null||(to[_e]={currentRoute:null,routes:[]});var no;(no=S)[Pe]!=null||(no[Pe]={}),new Proxy(S[_e],{get(e,t){return S[_e][t]}}),new Proxy(S[Pe],{get(e,t){if(t==="value")return S[Pe]}});function za(e){const t=new Map;return((e==null?void 0:e.getRoutes())||[]).filter(n=>!t.has(n.path)&&t.set(n.path,1))}function Nt(e){return e.map(t=>{let{path:n,name:o,children:r,meta:a}=t;return r!=null&&r.length&&(r=Nt(r)),{path:n,name:o,children:r,meta:a}})}function Ka(e){if(e){const{fullPath:t,hash:n,href:o,path:r,name:a,matched:i,params:l,query:c}=e;return{fullPath:t,hash:n,href:o,path:r,name:a,params:l,query:c,matched:Nt(i)}}return e}function Fa(e,t){function n(){var o;const r=(o=e.app)==null?void 0:o.config.globalProperties.$router,a=Ka(r==null?void 0:r.currentRoute.value),i=Nt(za(r)),l=console.warn;console.warn=()=>{},S[_e]={currentRoute:a?wn(a):{},routes:wn(i)},S[Pe]=r,console.warn=l}n(),Xn.on.componentUpdated(me(()=>{var o;((o=t.value)==null?void 0:o.app)===e.app&&(n(),!$.highPerfModeEnabled&&ge.hooks.callHook("routerInfoUpdated",{state:S[_e]}))},200))}function Wa(e){return{async getInspectorTree(t){const n={...t,app:B.value.app,rootNodes:[]};return await new Promise(o=>{e.callHookWith(async r=>{await Promise.all(r.map(a=>a(n))),o()},"getInspectorTree")}),n.rootNodes},async getInspectorState(t){const n={...t,app:B.value.app,state:null},o={currentTab:`custom-inspector:${t.inspectorId}`};return await new Promise(r=>{e.callHookWith(async a=>{await Promise.all(a.map(i=>i(n,o))),r()},"getInspectorState")}),n.state},editInspectorState(t){const n=new ya,o={...t,app:B.value.app,set:(r,a=t.path,i=t.state.value,l)=>{n.set(r,a,i,l||n.createDefaultSetCallback(t.state))}};e.callHookWith(r=>{r.forEach(a=>a(o))},"editInspectorState")},sendInspectorState(t){const n=Ye(t);e.callHook("sendInspectorState",{inspectorId:t,plugin:{descriptor:n.descriptor,setupFn:()=>({})}})},inspectComponentInspector(){return fa()},cancelInspectComponentInspector(){return da()},getComponentRenderCode(t){const n=Et(B.value,t);if(n)return(n==null?void 0:n.type)instanceof Function?n.type.toString():n.render.toString()},scrollToComponent(t){return pa({id:t})},openInEditor:Pa,getVueInspector:_a,toggleApp(t,n){const o=qe.value.find(r=>r.id===t);o&&(Ca(t),Va(o),Fa(o,B),jn(),eo(o.app,n))},inspectDOM(t){const n=Et(B.value,t);if(n){const[o]=wt(n);o&&(S.__VUE_DEVTOOLS_INSPECT_DOM_TARGET__=o)}},updatePluginSettings(t,n,o){Ra(t,n,o)},getPluginSettings(t){return{options:Na(t),values:Yn(t)}}}}w();var oo;(oo=S).__VUE_DEVTOOLS_ENV__!=null||(oo.__VUE_DEVTOOLS_ENV__={vitePluginDetected:!1});var ro=Sa(),so;(so=S).__VUE_DEVTOOLS_KIT_CONTEXT__!=null||(so.__VUE_DEVTOOLS_KIT_CONTEXT__={hooks:ro,get state(){return{...$,activeAppRecordId:B.id,activeAppRecord:B.value,appRecords:qe.value}},api:Wa(ro)});var ge=S.__VUE_DEVTOOLS_KIT_CONTEXT__;w(),Gs(qs());var ao;(ao=S).__VUE_DEVTOOLS_NEXT_APP_RECORD_INFO__!=null||(ao.__VUE_DEVTOOLS_NEXT_APP_RECORD_INFO__={id:0,appIds:new Set}),w();function Ga(e){$.highPerfModeEnabled=e??!$.highPerfModeEnabled,!e&&B.value&&eo(B.value.app)}w(),w(),w();function Ya(e){$.devtoolsClientDetected={...$.devtoolsClientDetected,...e};const t=Object.values($.devtoolsClientDetected).some(Boolean);Ga(!t)}var io;(io=S).__VUE_DEVTOOLS_UPDATE_CLIENT_DETECTED__!=null||(io.__VUE_DEVTOOLS_UPDATE_CLIENT_DETECTED__=Ya),w(),w(),w(),w(),w(),w(),w();var qa=class{constructor(){this.keyToValue=new Map,this.valueToKey=new Map}set(e,t){this.keyToValue.set(e,t),this.valueToKey.set(t,e)}getByKey(e){return this.keyToValue.get(e)}getByValue(e){return this.valueToKey.get(e)}clear(){this.keyToValue.clear(),this.valueToKey.clear()}},lo=class{constructor(e){this.generateIdentifier=e,this.kv=new qa}register(e,t){this.kv.getByValue(e)||(t||(t=this.generateIdentifier(e)),this.kv.set(t,e))}clear(){this.kv.clear()}getIdentifier(e){return this.kv.getByValue(e)}getValue(e){return this.kv.getByKey(e)}},Ja=class extends lo{constructor(){super(e=>e.name),this.classToAllowedProps=new Map}register(e,t){typeof t=="object"?(t.allowProps&&this.classToAllowedProps.set(e,t.allowProps),super.register(e,t.identifier)):super.register(e,t)}getAllowedProps(e){return this.classToAllowedProps.get(e)}};w(),w();function Xa(e){if("values"in Object)return Object.values(e);const t=[];for(const n in e)e.hasOwnProperty(n)&&t.push(e[n]);return t}function Za(e,t){const n=Xa(e);if("find"in n)return n.find(t);const o=n;for(let r=0;r<o.length;r++){const a=o[r];if(t(a))return a}}function ye(e,t){Object.entries(e).forEach(([n,o])=>t(o,n))}function Je(e,t){return e.indexOf(t)!==-1}function co(e,t){for(let n=0;n<e.length;n++){const o=e[n];if(t(o))return o}}var Qa=class{constructor(){this.transfomers={}}register(e){this.transfomers[e.name]=e}findApplicable(e){return Za(this.transfomers,t=>t.isApplicable(e))}findByName(e){return this.transfomers[e]}};w(),w();var ei=e=>Object.prototype.toString.call(e).slice(8,-1),uo=e=>typeof e>"u",ti=e=>e===null,Ne=e=>typeof e!="object"||e===null||e===Object.prototype?!1:Object.getPrototypeOf(e)===null?!0:Object.getPrototypeOf(e)===Object.prototype,Dt=e=>Ne(e)&&Object.keys(e).length===0,oe=e=>Array.isArray(e),ni=e=>typeof e=="string",oi=e=>typeof e=="number"&&!isNaN(e),ri=e=>typeof e=="boolean",si=e=>e instanceof RegExp,De=e=>e instanceof Map,Re=e=>e instanceof Set,fo=e=>ei(e)==="Symbol",ai=e=>e instanceof Date&&!isNaN(e.valueOf()),ii=e=>e instanceof Error,po=e=>typeof e=="number"&&isNaN(e),li=e=>ri(e)||ti(e)||uo(e)||oi(e)||ni(e)||fo(e),ci=e=>typeof e=="bigint",ui=e=>e===1/0||e===-1/0,di=e=>ArrayBuffer.isView(e)&&!(e instanceof DataView),fi=e=>e instanceof URL;w();var mo=e=>e.replace(/\./g,"\\."),Rt=e=>e.map(String).map(mo).join("."),xe=e=>{const t=[];let n="";for(let r=0;r<e.length;r++){let a=e.charAt(r);if(a==="\\"&&e.charAt(r+1)==="."){n+=".",r++;continue}if(a==="."){t.push(n),n="";continue}n+=a}const o=n;return t.push(o),t};w();function X(e,t,n,o){return{isApplicable:e,annotation:t,transform:n,untransform:o}}var ho=[X(uo,"undefined",()=>null,()=>{}),X(ci,"bigint",e=>e.toString(),e=>typeof BigInt<"u"?BigInt(e):(console.error("Please add a BigInt polyfill."),e)),X(ai,"Date",e=>e.toISOString(),e=>new Date(e)),X(ii,"Error",(e,t)=>{const n={name:e.name,message:e.message};return t.allowedErrorProps.forEach(o=>{n[o]=e[o]}),n},(e,t)=>{const n=new Error(e.message);return n.name=e.name,n.stack=e.stack,t.allowedErrorProps.forEach(o=>{n[o]=e[o]}),n}),X(si,"regexp",e=>""+e,e=>{const t=e.slice(1,e.lastIndexOf("/")),n=e.slice(e.lastIndexOf("/")+1);return new RegExp(t,n)}),X(Re,"set",e=>[...e.values()],e=>new Set(e)),X(De,"map",e=>[...e.entries()],e=>new Map(e)),X(e=>po(e)||ui(e),"number",e=>po(e)?"NaN":e>0?"Infinity":"-Infinity",Number),X(e=>e===0&&1/e===-1/0,"number",()=>"-0",Number),X(fi,"URL",e=>e.toString(),e=>new URL(e))];function Xe(e,t,n,o){return{isApplicable:e,annotation:t,transform:n,untransform:o}}var _o=Xe((e,t)=>fo(e)?!!t.symbolRegistry.getIdentifier(e):!1,(e,t)=>["symbol",t.symbolRegistry.getIdentifier(e)],e=>e.description,(e,t,n)=>{const o=n.symbolRegistry.getValue(t[1]);if(!o)throw new Error("Trying to deserialize unknown symbol");return o}),pi=[Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array,Uint8ClampedArray].reduce((e,t)=>(e[t.name]=t,e),{}),go=Xe(di,e=>["typed-array",e.constructor.name],e=>[...e],(e,t)=>{const n=pi[t[1]];if(!n)throw new Error("Trying to deserialize unknown typed array");return new n(e)});function yo(e,t){return e!=null&&e.constructor?!!t.classRegistry.getIdentifier(e.constructor):!1}var Eo=Xe(yo,(e,t)=>["class",t.classRegistry.getIdentifier(e.constructor)],(e,t)=>{const n=t.classRegistry.getAllowedProps(e.constructor);if(!n)return{...e};const o={};return n.forEach(r=>{o[r]=e[r]}),o},(e,t,n)=>{const o=n.classRegistry.getValue(t[1]);if(!o)throw new Error(`Trying to deserialize unknown class '${t[1]}' - check https://github.com/blitz-js/superjson/issues/116#issuecomment-773996564`);return Object.assign(Object.create(o.prototype),e)}),wo=Xe((e,t)=>!!t.customTransformerRegistry.findApplicable(e),(e,t)=>["custom",t.customTransformerRegistry.findApplicable(e).name],(e,t)=>t.customTransformerRegistry.findApplicable(e).serialize(e),(e,t,n)=>{const o=n.customTransformerRegistry.findByName(t[1]);if(!o)throw new Error("Trying to deserialize unknown custom value");return o.deserialize(e)}),mi=[Eo,_o,wo,go],bo=(e,t)=>{const n=co(mi,r=>r.isApplicable(e,t));if(n)return{value:n.transform(e,t),type:n.annotation(e,t)};const o=co(ho,r=>r.isApplicable(e,t));if(o)return{value:o.transform(e,t),type:o.annotation}},vo={};ho.forEach(e=>{vo[e.annotation]=e});var hi=(e,t,n)=>{if(oe(t))switch(t[0]){case"symbol":return _o.untransform(e,t,n);case"class":return Eo.untransform(e,t,n);case"custom":return wo.untransform(e,t,n);case"typed-array":return go.untransform(e,t,n);default:throw new Error("Unknown transformation: "+t)}else{const o=vo[t];if(!o)throw new Error("Unknown transformation: "+t);return o.untransform(e,n)}};w();var Ee=(e,t)=>{if(t>e.size)throw new Error("index out of bounds");const n=e.keys();for(;t>0;)n.next(),t--;return n.next().value};function ko(e){if(Je(e,"__proto__"))throw new Error("__proto__ is not allowed as a property");if(Je(e,"prototype"))throw new Error("prototype is not allowed as a property");if(Je(e,"constructor"))throw new Error("constructor is not allowed as a property")}var _i=(e,t)=>{ko(t);for(let n=0;n<t.length;n++){const o=t[n];if(Re(e))e=Ee(e,+o);else if(De(e)){const r=+o,a=+t[++n]==0?"key":"value",i=Ee(e,r);switch(a){case"key":e=i;break;case"value":e=e.get(i);break}}else e=e[o]}return e},xt=(e,t,n)=>{if(ko(t),t.length===0)return n(e);let o=e;for(let a=0;a<t.length-1;a++){const i=t[a];if(oe(o)){const l=+i;o=o[l]}else if(Ne(o))o=o[i];else if(Re(o)){const l=+i;o=Ee(o,l)}else if(De(o)){if(a===t.length-2)break;const l=+i,c=+t[++a]==0?"key":"value",u=Ee(o,l);switch(c){case"key":o=u;break;case"value":o=o.get(u);break}}}const r=t[t.length-1];if(oe(o)?o[+r]=n(o[+r]):Ne(o)&&(o[r]=n(o[r])),Re(o)){const a=Ee(o,+r),i=n(a);a!==i&&(o.delete(a),o.add(i))}if(De(o)){const a=+t[t.length-2],i=Ee(o,a);switch(+r==0?"key":"value"){case"key":{const l=n(i);o.set(l,o.get(i)),l!==i&&o.delete(i);break}case"value":{o.set(i,n(o.get(i)));break}}}return e};function At(e,t,n=[]){if(!e)return;if(!oe(e)){ye(e,(a,i)=>At(a,t,[...n,...xe(i)]));return}const[o,r]=e;r&&ye(r,(a,i)=>{At(a,t,[...n,...xe(i)])}),t(o,n)}function gi(e,t,n){return At(t,(o,r)=>{e=xt(e,r,a=>hi(a,o,n))}),e}function yi(e,t){function n(o,r){const a=_i(e,xe(r));o.map(xe).forEach(i=>{e=xt(e,i,()=>a)})}if(oe(t)){const[o,r]=t;o.forEach(a=>{e=xt(e,xe(a),()=>e)}),r&&ye(r,n)}else ye(t,n);return e}var Ei=(e,t)=>Ne(e)||oe(e)||De(e)||Re(e)||yo(e,t);function wi(e,t,n){const o=n.get(e);o?o.push(t):n.set(e,[t])}function bi(e,t){const n={};let o;return e.forEach(r=>{if(r.length<=1)return;t||(r=r.map(l=>l.map(String)).sort((l,c)=>l.length-c.length));const[a,...i]=r;a.length===0?o=i.map(Rt):n[Rt(a)]=i.map(Rt)}),o?Dt(n)?[o]:[o,n]:Dt(n)?void 0:n}var Oo=(e,t,n,o,r=[],a=[],i=new Map)=>{var l;const c=li(e);if(!c){wi(e,r,t);const _=i.get(e);if(_)return o?{transformedValue:null}:_}if(!Ei(e,n)){const _=bo(e,n),b=_?{transformedValue:_.value,annotations:[_.type]}:{transformedValue:e};return c||i.set(e,b),b}if(Je(a,e))return{transformedValue:null};const u=bo(e,n),d=(l=u==null?void 0:u.value)!=null?l:e,f=oe(d)?[]:{},p={};ye(d,(_,b)=>{if(b==="__proto__"||b==="constructor"||b==="prototype")throw new Error(`Detected property ${b}. This is a prototype pollution risk, please remove it from your object.`);const h=Oo(_,t,n,o,[...r,b],[...a,e],i);f[b]=h.transformedValue,oe(h.annotations)?p[b]=h.annotations:Ne(h.annotations)&&ye(h.annotations,(k,O)=>{p[mo(b)+"."+O]=k})});const m=Dt(p)?{transformedValue:f,annotations:u?[u.type]:void 0}:{transformedValue:f,annotations:u?[u.type,p]:p};return c||i.set(e,m),m};w(),w();function So(e){return Object.prototype.toString.call(e).slice(8,-1)}function To(e){return So(e)==="Array"}function vi(e){if(So(e)!=="Object")return!1;const t=Object.getPrototypeOf(e);return!!t&&t.constructor===Object&&t===Object.prototype}function ki(e,t,n,o,r){const a={}.propertyIsEnumerable.call(o,t)?"enumerable":"nonenumerable";a==="enumerable"&&(e[t]=n),r&&a==="nonenumerable"&&Object.defineProperty(e,t,{value:n,enumerable:!1,writable:!0,configurable:!0})}function $t(e,t={}){if(To(e))return e.map(r=>$t(r,t));if(!vi(e))return e;const n=Object.getOwnPropertyNames(e),o=Object.getOwnPropertySymbols(e);return[...n,...o].reduce((r,a)=>{if(To(t.props)&&!t.props.includes(a))return r;const i=e[a],l=$t(i,t);return ki(r,a,l,e,t.nonenumerable),r},{})}var N=class{constructor({dedupe:e=!1}={}){this.classRegistry=new Ja,this.symbolRegistry=new lo(t=>{var n;return(n=t.description)!=null?n:""}),this.customTransformerRegistry=new Qa,this.allowedErrorProps=[],this.dedupe=e}serialize(e){const t=new Map,n=Oo(e,t,this,this.dedupe),o={json:n.transformedValue};n.annotations&&(o.meta={...o.meta,values:n.annotations});const r=bi(t,this.dedupe);return r&&(o.meta={...o.meta,referentialEqualities:r}),o}deserialize(e){const{json:t,meta:n}=e;let o=$t(t);return n!=null&&n.values&&(o=gi(o,n.values,this)),n!=null&&n.referentialEqualities&&(o=yi(o,n.referentialEqualities)),o}stringify(e){return JSON.stringify(this.serialize(e))}parse(e){return this.deserialize(JSON.parse(e))}registerClass(e,t){this.classRegistry.register(e,t)}registerSymbol(e,t){this.symbolRegistry.register(e,t)}registerCustom(e,t){this.customTransformerRegistry.register({name:t,...e})}allowErrorProps(...e){this.allowedErrorProps.push(...e)}};N.defaultInstance=new N,N.serialize=N.defaultInstance.serialize.bind(N.defaultInstance),N.deserialize=N.defaultInstance.deserialize.bind(N.defaultInstance),N.stringify=N.defaultInstance.stringify.bind(N.defaultInstance),N.parse=N.defaultInstance.parse.bind(N.defaultInstance),N.registerClass=N.defaultInstance.registerClass.bind(N.defaultInstance),N.registerSymbol=N.defaultInstance.registerSymbol.bind(N.defaultInstance),N.registerCustom=N.defaultInstance.registerCustom.bind(N.defaultInstance),N.allowErrorProps=N.defaultInstance.allowErrorProps.bind(N.defaultInstance),w(),w(),w(),w(),w(),w(),w(),w(),w(),w(),w(),w(),w(),w(),w(),w(),w(),w(),w(),w(),w(),w(),w();var Io;(Io=S).__VUE_DEVTOOLS_KIT_MESSAGE_CHANNELS__!=null||(Io.__VUE_DEVTOOLS_KIT_MESSAGE_CHANNELS__=[]);var Vo;(Vo=S).__VUE_DEVTOOLS_KIT_RPC_CLIENT__!=null||(Vo.__VUE_DEVTOOLS_KIT_RPC_CLIENT__=null);var Co;(Co=S).__VUE_DEVTOOLS_KIT_RPC_SERVER__!=null||(Co.__VUE_DEVTOOLS_KIT_RPC_SERVER__=null);var Po;(Po=S).__VUE_DEVTOOLS_KIT_VITE_RPC_CLIENT__!=null||(Po.__VUE_DEVTOOLS_KIT_VITE_RPC_CLIENT__=null);var No;(No=S).__VUE_DEVTOOLS_KIT_VITE_RPC_SERVER__!=null||(No.__VUE_DEVTOOLS_KIT_VITE_RPC_SERVER__=null);var Do;(Do=S).__VUE_DEVTOOLS_KIT_BROADCAST_RPC_SERVER__!=null||(Do.__VUE_DEVTOOLS_KIT_BROADCAST_RPC_SERVER__=null),w(),w(),w(),w(),w(),w(),w();/*!
|
|
2
|
+
* pinia v3.0.1
|
|
3
|
+
* (c) 2025 Eduardo San Martin Morote
|
|
4
4
|
* @license MIT
|
|
5
|
-
*/let
|
|
5
|
+
*/let Ae;const $e=e=>Ae=e,Ro=process.env.NODE_ENV!=="production"?Symbol("pinia"):Symbol();function ce(e){return e&&typeof e=="object"&&Object.prototype.toString.call(e)==="[object Object]"&&typeof e.toJSON!="function"}var Z;(function(e){e.direct="direct",e.patchObject="patch object",e.patchFunction="patch function"})(Z||(Z={}));const re=typeof window<"u",xo=typeof window=="object"&&window.window===window?window:typeof self=="object"&&self.self===self?self:typeof global=="object"&&global.global===global?global:typeof globalThis=="object"?globalThis:{HTMLElement:null};function Oi(e,{autoBom:t=!1}={}){return t&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(e.type)?new Blob(["\uFEFF",e],{type:e.type}):e}function Lt(e,t,n){const o=new XMLHttpRequest;o.open("GET",e),o.responseType="blob",o.onload=function(){Lo(o.response,t,n)},o.onerror=function(){console.error("could not download file")},o.send()}function Ao(e){const t=new XMLHttpRequest;t.open("HEAD",e,!1);try{t.send()}catch{}return t.status>=200&&t.status<=299}function Ze(e){try{e.dispatchEvent(new MouseEvent("click"))}catch{const t=document.createEvent("MouseEvents");t.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),e.dispatchEvent(t)}}const Qe=typeof navigator=="object"?navigator:{userAgent:""},$o=/Macintosh/.test(Qe.userAgent)&&/AppleWebKit/.test(Qe.userAgent)&&!/Safari/.test(Qe.userAgent),Lo=re?typeof HTMLAnchorElement<"u"&&"download"in HTMLAnchorElement.prototype&&!$o?Si:"msSaveOrOpenBlob"in Qe?Ti:Ii:()=>{};function Si(e,t="download",n){const o=document.createElement("a");o.download=t,o.rel="noopener",typeof e=="string"?(o.href=e,o.origin!==location.origin?Ao(o.href)?Lt(e,t,n):(o.target="_blank",Ze(o)):Ze(o)):(o.href=URL.createObjectURL(e),setTimeout(function(){URL.revokeObjectURL(o.href)},4e4),setTimeout(function(){Ze(o)},0))}function Ti(e,t="download",n){if(typeof e=="string")if(Ao(e))Lt(e,t,n);else{const o=document.createElement("a");o.href=e,o.target="_blank",setTimeout(function(){Ze(o)})}else navigator.msSaveOrOpenBlob(Oi(e,n),t)}function Ii(e,t,n,o){if(o=o||open("","_blank"),o&&(o.document.title=o.document.body.innerText="downloading..."),typeof e=="string")return Lt(e,t,n);const r=e.type==="application/octet-stream",a=/constructor/i.test(String(xo.HTMLElement))||"safari"in xo,i=/CriOS\/[\d]+/.test(navigator.userAgent);if((i||r&&a||$o)&&typeof FileReader<"u"){const l=new FileReader;l.onloadend=function(){let c=l.result;if(typeof c!="string")throw o=null,new Error("Wrong reader.result type");c=i?c:c.replace(/^data:[^;]*;/,"data:attachment/file;"),o?o.location.href=c:location.assign(c),o=null},l.readAsDataURL(e)}else{const l=URL.createObjectURL(e);o?o.location.assign(l):location.href=l,o=null,setTimeout(function(){URL.revokeObjectURL(l)},4e4)}}function j(e,t){const n="🍍 "+e;typeof __VUE_DEVTOOLS_TOAST__=="function"?__VUE_DEVTOOLS_TOAST__(n,t):t==="error"?console.error(n):t==="warn"?console.warn(n):console.log(n)}function jt(e){return"_a"in e&&"install"in e}function jo(){if(!("clipboard"in navigator))return j("Your browser doesn't support the Clipboard API","error"),!0}function Uo(e){return e instanceof Error&&e.message.toLowerCase().includes("document is not focused")?(j('You need to activate the "Emulate a focused page" setting in the "Rendering" panel of devtools.',"warn"),!0):!1}async function Vi(e){if(!jo())try{await navigator.clipboard.writeText(JSON.stringify(e.state.value)),j("Global state copied to clipboard.")}catch(t){if(Uo(t))return;j("Failed to serialize the state. Check the console for more details.","error"),console.error(t)}}async function Ci(e){if(!jo())try{Mo(e,JSON.parse(await navigator.clipboard.readText())),j("Global state pasted from clipboard.")}catch(t){if(Uo(t))return;j("Failed to deserialize the state from clipboard. Check the console for more details.","error"),console.error(t)}}async function Pi(e){try{Lo(new Blob([JSON.stringify(e.state.value)],{type:"text/plain;charset=utf-8"}),"pinia-state.json")}catch(t){j("Failed to export the state as JSON. Check the console for more details.","error"),console.error(t)}}let Q;function Ni(){Q||(Q=document.createElement("input"),Q.type="file",Q.accept=".json");function e(){return new Promise((t,n)=>{Q.onchange=async()=>{const o=Q.files;if(!o)return t(null);const r=o.item(0);return t(r?{text:await r.text(),file:r}:null)},Q.oncancel=()=>t(null),Q.onerror=n,Q.click()})}return e}async function Di(e){try{const t=await Ni()();if(!t)return;const{text:n,file:o}=t;Mo(e,JSON.parse(n)),j(`Global state imported from "${o.name}".`)}catch(t){j("Failed to import the state from JSON. Check the console for more details.","error"),console.error(t)}}function Mo(e,t){for(const n in t){const o=e.state.value[n];o?Object.assign(o,t[n]):e.state.value[n]=t[n]}}function q(e){return{_custom:{display:e}}}const Bo="🍍 Pinia (root)",et="_root";function Ri(e){return jt(e)?{id:et,label:Bo}:{id:e.$id,label:e.$id}}function xi(e){if(jt(e)){const n=Array.from(e._s.keys()),o=e._s;return{state:n.map(r=>({editable:!0,key:r,value:e.state.value[r]})),getters:n.filter(r=>o.get(r)._getters).map(r=>{const a=o.get(r);return{editable:!1,key:r,value:a._getters.reduce((i,l)=>(i[l]=a[l],i),{})}})}}const t={state:Object.keys(e.$state).map(n=>({editable:!0,key:n,value:e.$state[n]}))};return e._getters&&e._getters.length&&(t.getters=e._getters.map(n=>({editable:!1,key:n,value:e[n]}))),e._customProperties.size&&(t.customProperties=Array.from(e._customProperties).map(n=>({editable:!0,key:n,value:e[n]}))),t}function Ai(e){return e?Array.isArray(e)?e.reduce((t,n)=>(t.keys.push(n.key),t.operations.push(n.type),t.oldValue[n.key]=n.oldValue,t.newValue[n.key]=n.newValue,t),{oldValue:{},keys:[],operations:[],newValue:{}}):{operation:q(e.type),key:q(e.key),oldValue:e.oldValue,newValue:e.newValue}:{}}function $i(e){switch(e){case Z.direct:return"mutation";case Z.patchFunction:return"$patch";case Z.patchObject:return"$patch";default:return"unknown"}}let we=!0;const tt=[],ue="pinia:mutations",U="pinia",{assign:Li}=Object,nt=e=>"🍍 "+e;function ji(e,t){Qn({id:"dev.esm.pinia",label:"Pinia 🍍",logo:"https://pinia.vuejs.org/logo.svg",packageName:"pinia",homepage:"https://pinia.vuejs.org",componentStateTypes:tt,app:e},n=>{typeof n.now!="function"&&j("You seem to be using an outdated version of Vue Devtools. Are you still using the Beta release instead of the stable one? You can find the links at https://devtools.vuejs.org/guide/installation.html."),n.addTimelineLayer({id:ue,label:"Pinia 🍍",color:15064968}),n.addInspector({id:U,label:"Pinia 🍍",icon:"storage",treeFilterPlaceholder:"Search stores",actions:[{icon:"content_copy",action:()=>{Vi(t)},tooltip:"Serialize and copy the state"},{icon:"content_paste",action:async()=>{await Ci(t),n.sendInspectorTree(U),n.sendInspectorState(U)},tooltip:"Replace the state with the content of your clipboard"},{icon:"save",action:()=>{Pi(t)},tooltip:"Save the state as a JSON file"},{icon:"folder_open",action:async()=>{await Di(t),n.sendInspectorTree(U),n.sendInspectorState(U)},tooltip:"Import the state from a JSON file"}],nodeActions:[{icon:"restore",tooltip:'Reset the state (with "$reset")',action:o=>{const r=t._s.get(o);r?typeof r.$reset!="function"?j(`Cannot reset "${o}" store because it doesn't have a "$reset" method implemented.`,"warn"):(r.$reset(),j(`Store "${o}" reset.`)):j(`Cannot reset "${o}" store because it wasn't found.`,"warn")}}]}),n.on.inspectComponent(o=>{const r=o.componentInstance&&o.componentInstance.proxy;if(r&&r._pStores){const a=o.componentInstance.proxy._pStores;Object.values(a).forEach(i=>{o.instanceData.state.push({type:nt(i.$id),key:"state",editable:!0,value:i._isOptionsAPI?{_custom:{value:s.toRaw(i.$state),actions:[{icon:"restore",tooltip:"Reset the state of this store",action:()=>i.$reset()}]}}:Object.keys(i.$state).reduce((l,c)=>(l[c]=i.$state[c],l),{})}),i._getters&&i._getters.length&&o.instanceData.state.push({type:nt(i.$id),key:"getters",editable:!1,value:i._getters.reduce((l,c)=>{try{l[c]=i[c]}catch(u){l[c]=u}return l},{})})})}}),n.on.getInspectorTree(o=>{if(o.app===e&&o.inspectorId===U){let r=[t];r=r.concat(Array.from(t._s.values())),o.rootNodes=(o.filter?r.filter(a=>"$id"in a?a.$id.toLowerCase().includes(o.filter.toLowerCase()):Bo.toLowerCase().includes(o.filter.toLowerCase())):r).map(Ri)}}),globalThis.$pinia=t,n.on.getInspectorState(o=>{if(o.app===e&&o.inspectorId===U){const r=o.nodeId===et?t:t._s.get(o.nodeId);if(!r)return;r&&(o.nodeId!==et&&(globalThis.$store=s.toRaw(r)),o.state=xi(r))}}),n.on.editInspectorState(o=>{if(o.app===e&&o.inspectorId===U){const r=o.nodeId===et?t:t._s.get(o.nodeId);if(!r)return j(`store "${o.nodeId}" not found`,"error");const{path:a}=o;jt(r)?a.unshift("state"):(a.length!==1||!r._customProperties.has(a[0])||a[0]in r.$state)&&a.unshift("$state"),we=!1,o.set(r,a,o.state.value),we=!0}}),n.on.editComponentState(o=>{if(o.type.startsWith("🍍")){const r=o.type.replace(/^🍍\s*/,""),a=t._s.get(r);if(!a)return j(`store "${r}" not found`,"error");const{path:i}=o;if(i[0]!=="state")return j(`Invalid path for store "${r}":
|
|
6
6
|
${i}
|
|
7
|
-
Only state can be modified.`);i[0]="$state",
|
|
7
|
+
Only state can be modified.`);i[0]="$state",we=!1,o.set(a,i,o.state.value),we=!0}})})}function Ui(e,t){tt.includes(nt(t.$id))||tt.push(nt(t.$id)),Qn({id:"dev.esm.pinia",label:"Pinia 🍍",logo:"https://pinia.vuejs.org/logo.svg",packageName:"pinia",homepage:"https://pinia.vuejs.org",componentStateTypes:tt,app:e,settings:{logStoreChanges:{label:"Notify about new/deleted stores",type:"boolean",defaultValue:!0}}},n=>{const o=typeof n.now=="function"?n.now.bind(n):Date.now;t.$onAction(({after:i,onError:l,name:c,args:u})=>{const d=Ho++;n.addTimelineEvent({layerId:ue,event:{time:o(),title:"🛫 "+c,subtitle:"start",data:{store:q(t.$id),action:q(c),args:u},groupId:d}}),i(f=>{se=void 0,n.addTimelineEvent({layerId:ue,event:{time:o(),title:"🛬 "+c,subtitle:"end",data:{store:q(t.$id),action:q(c),args:u,result:f},groupId:d}})}),l(f=>{se=void 0,n.addTimelineEvent({layerId:ue,event:{time:o(),logType:"error",title:"💥 "+c,subtitle:"end",data:{store:q(t.$id),action:q(c),args:u,error:f},groupId:d}})})},!0),t._customProperties.forEach(i=>{s.watch(()=>s.unref(t[i]),(l,c)=>{n.notifyComponentUpdate(),n.sendInspectorState(U),we&&n.addTimelineEvent({layerId:ue,event:{time:o(),title:"Change",subtitle:i,data:{newValue:l,oldValue:c},groupId:se}})},{deep:!0})}),t.$subscribe(({events:i,type:l},c)=>{if(n.notifyComponentUpdate(),n.sendInspectorState(U),!we)return;const u={time:o(),title:$i(l),data:Li({store:q(t.$id)},Ai(i)),groupId:se};l===Z.patchFunction?u.subtitle="⤵️":l===Z.patchObject?u.subtitle="🧩":i&&!Array.isArray(i)&&(u.subtitle=i.type),i&&(u.data["rawEvent(s)"]={_custom:{display:"DebuggerEvent",type:"object",tooltip:"raw DebuggerEvent[]",value:i}}),n.addTimelineEvent({layerId:ue,event:u})},{detached:!0,flush:"sync"});const r=t._hotUpdate;t._hotUpdate=s.markRaw(i=>{r(i),n.addTimelineEvent({layerId:ue,event:{time:o(),title:"🔥 "+t.$id,subtitle:"HMR update",data:{store:q(t.$id),info:q("HMR update")}}}),n.notifyComponentUpdate(),n.sendInspectorTree(U),n.sendInspectorState(U)});const{$dispose:a}=t;t.$dispose=()=>{a(),n.notifyComponentUpdate(),n.sendInspectorTree(U),n.sendInspectorState(U),n.getSettings().logStoreChanges&&j(`Disposed "${t.$id}" store 🗑`)},n.notifyComponentUpdate(),n.sendInspectorTree(U),n.sendInspectorState(U),n.getSettings().logStoreChanges&&j(`"${t.$id}" store installed 🆕`)})}let Ho=0,se;function zo(e,t,n){const o=t.reduce((r,a)=>(r[a]=s.toRaw(e)[a],r),{});for(const r in o)e[r]=function(){const a=Ho,i=n?new Proxy(e,{get(...c){return se=a,Reflect.get(...c)},set(...c){return se=a,Reflect.set(...c)}}):e;se=a;const l=o[r].apply(i,arguments);return se=void 0,l}}function Mi({app:e,store:t,options:n}){if(!t.$id.startsWith("__hot:")){if(t._isOptionsAPI=!!n.state,!t._p._testing){zo(t,Object.keys(n.actions),t._isOptionsAPI);const o=t._hotUpdate;s.toRaw(t)._hotUpdate=function(r){o.apply(this,arguments),zo(t,Object.keys(r._hmrPayload.actions),!!t._isOptionsAPI)}}Ui(e,t)}}function Bi(){const e=s.effectScope(!0),t=e.run(()=>s.ref({}));let n=[],o=[];const r=s.markRaw({install(a){$e(r),r._a=a,a.provide(Ro,r),a.config.globalProperties.$pinia=r,process.env.NODE_ENV!=="production"&&process.env.NODE_ENV!=="test"&&re&&ji(a,r),o.forEach(i=>n.push(i)),o=[]},use(a){return this._a?n.push(a):o.push(a),this},_p:n,_a:null,_e:e,_s:new Map,state:t});return process.env.NODE_ENV!=="production"&&process.env.NODE_ENV!=="test"&&re&&typeof Proxy<"u"&&r.use(Mi),r}function Ko(e,t){for(const n in t){const o=t[n];if(!(n in e))continue;const r=e[n];ce(r)&&ce(o)&&!s.isRef(o)&&!s.isReactive(o)?e[n]=Ko(r,o):e[n]=o}return e}const Fo=()=>{};function Wo(e,t,n,o=Fo){e.push(t);const r=()=>{const a=e.indexOf(t);a>-1&&(e.splice(a,1),o())};return!n&&s.getCurrentScope()&&s.onScopeDispose(r),r}function be(e,...t){e.slice().forEach(n=>{n(...t)})}const Hi=e=>e(),Go=Symbol(),Ut=Symbol();function Mt(e,t){e instanceof Map&&t instanceof Map?t.forEach((n,o)=>e.set(o,n)):e instanceof Set&&t instanceof Set&&t.forEach(e.add,e);for(const n in t){if(!t.hasOwnProperty(n))continue;const o=t[n],r=e[n];ce(r)&&ce(o)&&e.hasOwnProperty(n)&&!s.isRef(o)&&!s.isReactive(o)?e[n]=Mt(r,o):e[n]=o}return e}const zi=process.env.NODE_ENV!=="production"?Symbol("pinia:skipHydration"):Symbol();function Ki(e){return!ce(e)||!e.hasOwnProperty(zi)}const{assign:F}=Object;function Yo(e){return!!(s.isRef(e)&&e.effect)}function qo(e,t,n,o){const{state:r,actions:a,getters:i}=t,l=n.state.value[e];let c;function u(){!l&&(process.env.NODE_ENV==="production"||!o)&&(n.state.value[e]=r?r():{});const d=process.env.NODE_ENV!=="production"&&o?s.toRefs(s.ref(r?r():{}).value):s.toRefs(n.state.value[e]);return F(d,a,Object.keys(i||{}).reduce((f,p)=>(process.env.NODE_ENV!=="production"&&p in d&&console.warn(`[🍍]: A getter cannot have the same name as another state property. Rename one of them. Found with "${p}" in store "${e}".`),f[p]=s.markRaw(s.computed(()=>{$e(n);const m=n._s.get(e);return i[p].call(m,m)})),f),{}))}return c=Bt(e,u,t,n,o,!0),c}function Bt(e,t,n={},o,r,a){let i;const l=F({actions:{}},n);if(process.env.NODE_ENV!=="production"&&!o._e.active)throw new Error("Pinia destroyed");const c={deep:!0};process.env.NODE_ENV!=="production"&&(c.onTrigger=v=>{u?m=v:u==!1&&!y._hotUpdating&&(Array.isArray(m)?m.push(v):console.error("🍍 debuggerEvents should be an array. This is most likely an internal Pinia bug."))});let u,d,f=[],p=[],m;const _=o.state.value[e];!a&&!_&&(process.env.NODE_ENV==="production"||!r)&&(o.state.value[e]={});const b=s.ref({});let h;function k(v){let g;u=d=!1,process.env.NODE_ENV!=="production"&&(m=[]),typeof v=="function"?(v(o.state.value[e]),g={type:Z.patchFunction,storeId:e,events:m}):(Mt(o.state.value[e],v),g={type:Z.patchObject,payload:v,storeId:e,events:m});const E=h=Symbol();s.nextTick().then(()=>{h===E&&(u=!0)}),d=!0,be(f,g,o.state.value[e])}const O=a?function(){const{state:v}=n,g=v?v():{};this.$patch(E=>{F(E,g)})}:process.env.NODE_ENV!=="production"?()=>{throw new Error(`🍍: Store "${e}" is built using the setup syntax and does not implement $reset().`)}:Fo;function V(){i.stop(),f=[],p=[],o._s.delete(e)}const A=(v,g="")=>{if(Go in v)return v[Ut]=g,v;const E=function(){$e(o);const I=Array.from(arguments),D=[],G=[];function H(P){D.push(P)}function C(P){G.push(P)}be(p,{args:I,name:E[Ut],store:y,after:H,onError:C});let Y;try{Y=v.apply(this&&this.$id===e?this:y,I)}catch(P){throw be(G,P),P}return Y instanceof Promise?Y.then(P=>(be(D,P),P)).catch(P=>(be(G,P),Promise.reject(P))):(be(D,Y),Y)};return E[Go]=!0,E[Ut]=g,E},x=s.markRaw({actions:{},getters:{},state:[],hotState:b}),R={_p:o,$id:e,$onAction:Wo.bind(null,p),$patch:k,$reset:O,$subscribe(v,g={}){const E=Wo(f,v,g.detached,()=>I()),I=i.run(()=>s.watch(()=>o.state.value[e],D=>{(g.flush==="sync"?d:u)&&v({storeId:e,type:Z.direct,events:m},D)},F({},c,g)));return E},$dispose:V},y=s.reactive(process.env.NODE_ENV!=="production"||process.env.NODE_ENV!=="production"&&process.env.NODE_ENV!=="test"&&re?F({_hmrPayload:x,_customProperties:s.markRaw(new Set)},R):R);o._s.set(e,y);const T=(o._a&&o._a.runWithContext||Hi)(()=>o._e.run(()=>(i=s.effectScope()).run(()=>t({action:A}))));for(const v in T){const g=T[v];if(s.isRef(g)&&!Yo(g)||s.isReactive(g))process.env.NODE_ENV!=="production"&&r?b.value[v]=s.toRef(T,v):a||(_&&Ki(g)&&(s.isRef(g)?g.value=_[v]:Mt(g,_[v])),o.state.value[e][v]=g),process.env.NODE_ENV!=="production"&&x.state.push(v);else if(typeof g=="function"){const E=process.env.NODE_ENV!=="production"&&r?g:A(g,v);T[v]=E,process.env.NODE_ENV!=="production"&&(x.actions[v]=g),l.actions[v]=g}else process.env.NODE_ENV!=="production"&&Yo(g)&&(x.getters[v]=a?n.getters[v]:g,re&&(T._getters||(T._getters=s.markRaw([]))).push(v))}if(F(y,T),F(s.toRaw(y),T),Object.defineProperty(y,"$state",{get:()=>process.env.NODE_ENV!=="production"&&r?b.value:o.state.value[e],set:v=>{if(process.env.NODE_ENV!=="production"&&r)throw new Error("cannot set hotState");k(g=>{F(g,v)})}}),process.env.NODE_ENV!=="production"&&(y._hotUpdate=s.markRaw(v=>{y._hotUpdating=!0,v._hmrPayload.state.forEach(g=>{if(g in y.$state){const E=v.$state[g],I=y.$state[g];typeof E=="object"&&ce(E)&&ce(I)?Ko(E,I):v.$state[g]=I}y[g]=s.toRef(v.$state,g)}),Object.keys(y.$state).forEach(g=>{g in v.$state||delete y[g]}),u=!1,d=!1,o.state.value[e]=s.toRef(v._hmrPayload,"hotState"),d=!0,s.nextTick().then(()=>{u=!0});for(const g in v._hmrPayload.actions){const E=v[g];y[g]=A(E,g)}for(const g in v._hmrPayload.getters){const E=v._hmrPayload.getters[g],I=a?s.computed(()=>($e(o),E.call(y,y))):E;y[g]=I}Object.keys(y._hmrPayload.getters).forEach(g=>{g in v._hmrPayload.getters||delete y[g]}),Object.keys(y._hmrPayload.actions).forEach(g=>{g in v._hmrPayload.actions||delete y[g]}),y._hmrPayload=v._hmrPayload,y._getters=v._getters,y._hotUpdating=!1})),process.env.NODE_ENV!=="production"&&process.env.NODE_ENV!=="test"&&re){const v={writable:!0,configurable:!0,enumerable:!1};["_p","_hmrPayload","_getters","_customProperties"].forEach(g=>{Object.defineProperty(y,g,F({value:y[g]},v))})}return o._p.forEach(v=>{if(process.env.NODE_ENV!=="production"&&process.env.NODE_ENV!=="test"&&re){const g=i.run(()=>v({store:y,app:o._a,pinia:o,options:l}));Object.keys(g||{}).forEach(E=>y._customProperties.add(E)),F(y,g)}else F(y,i.run(()=>v({store:y,app:o._a,pinia:o,options:l})))}),process.env.NODE_ENV!=="production"&&y.$state&&typeof y.$state=="object"&&typeof y.$state.constructor=="function"&&!y.$state.constructor.toString().includes("[native code]")&&console.warn(`[🍍]: The "state" must be a plain object. It cannot be
|
|
8
8
|
state: () => new MyClass()
|
|
9
|
-
Found in store "${
|
|
9
|
+
Found in store "${y.$id}".`),_&&a&&n.hydrate&&n.hydrate(y.$state,_),u=!0,d=!0,y}/*! #__NO_SIDE_EFFECTS__ */function Fi(e,t,n){let o;const r=typeof t=="function";o=r?n:t;function a(i,l){const c=s.hasInjectionContext();if(i=(process.env.NODE_ENV==="test"&&Ae&&Ae._testing?null:i)||(c?s.inject(Ro,null):null),i&&$e(i),process.env.NODE_ENV!=="production"&&!Ae)throw new Error(`[🍍]: "getActivePinia()" was called but there was no active Pinia. Are you trying to use a store before calling "app.use(pinia)"?
|
|
10
10
|
See https://pinia.vuejs.org/core-concepts/outside-component-usage.html for help.
|
|
11
|
-
This will fail in production.`);l=lt,l._s.has(o)||(a?Ht(o,e,s,l):He(o,s,l),process.env.NODE_ENV!=="production"&&(i._pinia=l));const d=l._s.get(o);if(process.env.NODE_ENV!=="production"&&u){const f="__hot:"+o,p=a?Ht(f,e,s,l,!0):He(f,A({},s),l,!0);u._hotUpdate(p),delete l.state.value[f],l._s.delete(f)}if(process.env.NODE_ENV!=="production"&&G){const f=r.getCurrentInstance();if(f&&f.proxy&&!u){const p=f.proxy,w="_pStores"in p?p._pStores:p._pStores={};w[o]=d}}return d}return i.$id=o,i}const Go=Jo("data",()=>{const t=r.ref([]),e=r.ref({});return{records:t,record:e}});function Fe(t){const e=r.ref();return r.onMounted(async()=>{var n,o,s;t||(t=r.inject("$registry"));let a;try{a=Go()}catch{throw new Error("Please enable the Stonecrop plugin before using the Stonecrop composable")}if(e.value=new yo(t,a),!t||!t.router)return;const i=t.router.currentRoute.value,l=(n=i.params.records)==null?void 0:n.toString().toLowerCase(),u=(o=i.params.record)==null?void 0:o.toString().toLowerCase();if(!l&&!u)return;const c=await((s=t.getMeta)==null?void 0:s.call(t,l));c&&(t.addDoctype(c),e.value.setup(c),l&&(u?await e.value.getRecord(c,u):await e.value.getRecords(c)),e.value.runAction(c,"LOAD",u?[u]:void 0))}),{stonecrop:e}}T(class Vt{constructor(e,n){if(T(this,"name"),T(this,"registry"),T(this,"router"),T(this,"getMeta"),Vt._root)return Vt._root;Vt._root=this,this.name="Registry",this.registry={},this.router=e,this.getMeta=n}addDoctype(e){e.doctype in Object.keys(this.registry)||(this.registry[e.slug]=e),e.component&&this.router&&!this.router.hasRoute(e.doctype)&&this.router.addRoute({path:`/${e.slug}`,name:e.slug,component:e.component})}},"_root");function Yo(t){return t&&typeof t.then=="function"}Promise.resolve(!1),Promise.resolve(!0);var et=Promise.resolve();function ze(t,e){return t||(t=0),new Promise(function(n){return setTimeout(function(){return n(e)},t)})}function qo(t,e){return Math.floor(Math.random()*(e-t+1)+t)}function Ft(){return Math.random().toString(36).substring(2)}var Je=0,zt=0;function St(){var t=new Date().getTime();return t===Je?(zt++,t*1e3+zt):(Je=t,zt=0,t*1e3)}var Qo=St,Xo="native";function Ko(t){var e={messagesCallback:null,bc:new BroadcastChannel(t),subFns:[]};return e.bc.onmessage=function(n){e.messagesCallback&&e.messagesCallback(n.data)},e}function Zo(t){t.bc.close(),t.subFns=[]}function tr(t,e){try{return t.bc.postMessage(e,!1),et}catch(n){return Promise.reject(n)}}function er(t,e){t.messagesCallback=e}function nr(){if(typeof window>"u")return!1;if(typeof BroadcastChannel=="function"){if(BroadcastChannel._pubkey)throw new Error("BroadcastChannel: Do not overwrite window.BroadcastChannel with this module, this is not a polyfill");return!0}else return!1}function or(){return 150}var rr={create:Ko,close:Zo,onMessage:er,postMessage:tr,canBeUsed:nr,type:Xo,averageResponseTime:or,microSeconds:Qo},Ge=function(){function t(e){this.ttl=e,this.map=new Map,this._to=!1}return t.prototype.has=function(e){return this.map.has(e)},t.prototype.add=function(e){var n=this;this.map.set(e,Ye()),this._to||(this._to=!0,setTimeout(function(){n._to=!1,sr(n)},0))},t.prototype.clear=function(){this.map.clear()},t}();function sr(t){for(var e=Ye()-t.ttl,n=t.map[Symbol.iterator]();;){var o=n.next().value;if(!o)return;var s=o[0],a=o[1];if(a<e)t.map.delete(s);else return}}function Ye(){return new Date().getTime()}function Jt(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},e=JSON.parse(JSON.stringify(t));return typeof e.webWorkerSupport>"u"&&(e.webWorkerSupport=!0),e.idb||(e.idb={}),e.idb.ttl||(e.idb.ttl=1e3*45),e.idb.fallbackInterval||(e.idb.fallbackInterval=150),t.idb&&typeof t.idb.onclose=="function"&&(e.idb.onclose=t.idb.onclose),e.localstorage||(e.localstorage={}),e.localstorage.removeTimeout||(e.localstorage.removeTimeout=1e3*60),t.methods&&(e.methods=t.methods),e.node||(e.node={}),e.node.ttl||(e.node.ttl=1e3*60*2),e.node.maxParallelWrites||(e.node.maxParallelWrites=2048),typeof e.node.useFastPath>"u"&&(e.node.useFastPath=!0),e}var ar=St,ir="pubkey.broadcast-channel-0-",H="messages",Nt={durability:"relaxed"},lr="idb";function qe(){if(typeof indexedDB<"u")return indexedDB;if(typeof window<"u"){if(typeof window.mozIndexedDB<"u")return window.mozIndexedDB;if(typeof window.webkitIndexedDB<"u")return window.webkitIndexedDB;if(typeof window.msIndexedDB<"u")return window.msIndexedDB}return!1}function Gt(t){t.commit&&t.commit()}function cr(t){var e=qe(),n=ir+t,o=e.open(n);return o.onupgradeneeded=function(s){var a=s.target.result;a.createObjectStore(H,{keyPath:"id",autoIncrement:!0})},new Promise(function(s,a){o.onerror=function(i){return a(i)},o.onsuccess=function(){s(o.result)}})}function ur(t,e,n){var o=new Date().getTime(),s={uuid:e,time:o,data:n},a=t.transaction([H],"readwrite",Nt);return new Promise(function(i,l){a.oncomplete=function(){return i()},a.onerror=function(c){return l(c)};var u=a.objectStore(H);u.add(s),Gt(a)})}function dr(t,e){var n=t.transaction(H,"readonly",Nt),o=n.objectStore(H),s=[],a=IDBKeyRange.bound(e+1,1/0);if(o.getAll){var i=o.getAll(a);return new Promise(function(u,c){i.onerror=function(d){return c(d)},i.onsuccess=function(d){u(d.target.result)}})}function l(){try{return a=IDBKeyRange.bound(e+1,1/0),o.openCursor(a)}catch{return o.openCursor()}}return new Promise(function(u,c){var d=l();d.onerror=function(f){return c(f)},d.onsuccess=function(f){var p=f.target.result;p?p.value.id<e+1?p.continue(e+1):(s.push(p.value),p.continue()):(Gt(n),u(s))}})}function fr(t,e){if(t.closed)return Promise.resolve([]);var n=t.db.transaction(H,"readwrite",Nt),o=n.objectStore(H);return Promise.all(e.map(function(s){var a=o.delete(s);return new Promise(function(i){a.onsuccess=function(){return i()}})}))}function pr(t,e){var n=new Date().getTime()-e,o=t.transaction(H,"readonly",Nt),s=o.objectStore(H),a=[];return new Promise(function(i){s.openCursor().onsuccess=function(l){var u=l.target.result;if(u){var c=u.value;c.time<n?(a.push(c),u.continue()):(Gt(o),i(a))}else i(a)}})}function mr(t){return pr(t.db,t.options.idb.ttl).then(function(e){return fr(t,e.map(function(n){return n.id}))})}function hr(t,e){return e=Jt(e),cr(t).then(function(n){var o={closed:!1,lastCursorId:0,channelName:t,options:e,uuid:Ft(),eMIs:new Ge(e.idb.ttl*2),writeBlockPromise:et,messagesCallback:null,readQueuePromises:[],db:n};return n.onclose=function(){o.closed=!0,e.idb.onclose&&e.idb.onclose()},Qe(o),o})}function Qe(t){t.closed||Xe(t).then(function(){return ze(t.options.idb.fallbackInterval)}).then(function(){return Qe(t)})}function gr(t,e){return!(t.uuid===e.uuid||e.eMIs.has(t.id)||t.data.time<e.messagesCallbackTime)}function Xe(t){return t.closed||!t.messagesCallback?et:dr(t.db,t.lastCursorId).then(function(e){var n=e.filter(function(o){return!!o}).map(function(o){return o.id>t.lastCursorId&&(t.lastCursorId=o.id),o}).filter(function(o){return gr(o,t)}).sort(function(o,s){return o.time-s.time});return n.forEach(function(o){t.messagesCallback&&(t.eMIs.add(o.id),t.messagesCallback(o.data))}),et})}function yr(t){t.closed=!0,t.db.close()}function wr(t,e){return t.writeBlockPromise=t.writeBlockPromise.then(function(){return ur(t.db,t.uuid,e)}).then(function(){qo(0,10)===0&&mr(t)}),t.writeBlockPromise}function br(t,e,n){t.messagesCallbackTime=n,t.messagesCallback=e,Xe(t)}function _r(){return!!qe()}function Er(t){return t.idb.fallbackInterval*2}var vr={create:hr,close:yr,onMessage:br,postMessage:wr,canBeUsed:_r,type:lr,averageResponseTime:Er,microSeconds:ar},kr=St,$r="pubkey.broadcastChannel-",Sr="localstorage";function Ke(){var t;if(typeof window>"u")return null;try{t=window.localStorage,t=window["ie8-eventlistener/storage"]||window.localStorage}catch{}return t}function Ze(t){return $r+t}function Nr(t,e){return new Promise(function(n){ze().then(function(){var o=Ze(t.channelName),s={token:Ft(),time:new Date().getTime(),data:e,uuid:t.uuid},a=JSON.stringify(s);Ke().setItem(o,a);var i=document.createEvent("Event");i.initEvent("storage",!0,!0),i.key=o,i.newValue=a,window.dispatchEvent(i),n()})})}function xr(t,e){var n=Ze(t),o=function(s){s.key===n&&e(JSON.parse(s.newValue))};return window.addEventListener("storage",o),o}function Or(t){window.removeEventListener("storage",t)}function Cr(t,e){if(e=Jt(e),!tn())throw new Error("BroadcastChannel: localstorage cannot be used");var n=Ft(),o=new Ge(e.localstorage.removeTimeout),s={channelName:t,uuid:n,eMIs:o};return s.listener=xr(t,function(a){s.messagesCallback&&a.uuid!==n&&(!a.token||o.has(a.token)||a.data.time&&a.data.time<s.messagesCallbackTime||(o.add(a.token),s.messagesCallback(a.data)))}),s}function Pr(t){Or(t.listener)}function Ir(t,e,n){t.messagesCallbackTime=n,t.messagesCallback=e}function tn(){var t=Ke();if(!t)return!1;try{var e="__broadcastchannel_check";t.setItem(e,"works"),t.removeItem(e)}catch{return!1}return!0}function Vr(){var t=120,e=navigator.userAgent.toLowerCase();return e.includes("safari")&&!e.includes("chrome")?t*2:t}var Dr={create:Cr,close:Pr,onMessage:Ir,postMessage:Nr,canBeUsed:tn,type:Sr,averageResponseTime:Vr,microSeconds:kr},Tr=St,Ar="simulate",Yt=new Set;function Br(t){var e={name:t,messagesCallback:null};return Yt.add(e),e}function Rr(t){Yt.delete(t)}function jr(t,e){return new Promise(function(n){return setTimeout(function(){var o=Array.from(Yt);o.filter(function(s){return s.name===t.name}).filter(function(s){return s!==t}).filter(function(s){return!!s.messagesCallback}).forEach(function(s){return s.messagesCallback(e)}),n()},5)})}function Lr(t,e){t.messagesCallback=e}function Mr(){return!0}function Ur(){return 5}var Wr={create:Br,close:Rr,onMessage:Lr,postMessage:jr,canBeUsed:Mr,type:Ar,averageResponseTime:Ur,microSeconds:Tr},en=[rr,vr,Dr];function Hr(t){var e=[].concat(t.methods,en).filter(Boolean);if(t.type){if(t.type==="simulate")return Wr;var n=e.find(function(s){return s.type===t.type});if(n)return n;throw new Error("method-type "+t.type+" not found")}t.webWorkerSupport||(e=e.filter(function(s){return s.type!=="idb"}));var o=e.find(function(s){return s.canBeUsed()});if(o)return o;throw new Error("No usable method found in "+JSON.stringify(en.map(function(s){return s.type})))}var nn=new Set,Fr=0,qt=function(t,e){this.id=Fr++,nn.add(this),this.name=t,this.options=Jt(e),this.method=Hr(this.options),this._iL=!1,this._onML=null,this._addEL={message:[],internal:[]},this._uMP=new Set,this._befC=[],this._prepP=null,zr(this)};qt._pubkey=!0,qt.prototype={postMessage:function(t){if(this.closed)throw new Error("BroadcastChannel.postMessage(): Cannot post message after channel has closed "+JSON.stringify(t));return on(this,"message",t)},postInternal:function(t){return on(this,"internal",t)},set onmessage(t){var e=this.method.microSeconds(),n={time:e,fn:t};an(this,"message",this._onML),t&&typeof t=="function"?(this._onML=n,sn(this,"message",n)):this._onML=null},addEventListener:function(t,e){var n=this.method.microSeconds(),o={time:n,fn:e};sn(this,t,o)},removeEventListener:function(t,e){var n=this._addEL[t].find(function(o){return o.fn===e});an(this,t,n)},close:function(){var t=this;if(!this.closed){nn.delete(this),this.closed=!0;var e=this._prepP?this._prepP:et;return this._onML=null,this._addEL.message=[],e.then(function(){return Promise.all(Array.from(t._uMP))}).then(function(){return Promise.all(t._befC.map(function(n){return n()}))}).then(function(){return t.method.close(t._state)})}},get type(){return this.method.type},get isClosed(){return this.closed}};function on(t,e,n){var o=t.method.microSeconds(),s={time:o,type:e,data:n},a=t._prepP?t._prepP:et;return a.then(function(){var i=t.method.postMessage(t._state,s);return t._uMP.add(i),i.catch().then(function(){return t._uMP.delete(i)}),i})}function zr(t){var e=t.method.create(t.name,t.options);Yo(e)?(t._prepP=e,e.then(function(n){t._state=n})):t._state=e}function rn(t){return t._addEL.message.length>0||t._addEL.internal.length>0}function sn(t,e,n){t._addEL[e].push(n),Jr(t)}function an(t,e,n){t._addEL[e]=t._addEL[e].filter(function(o){return o!==n}),Gr(t)}function Jr(t){if(!t._iL&&rn(t)){var e=function(o){t._addEL[o.type].forEach(function(s){var a=1e5,i=s.time-a;o.time>=i&&s.fn(o.data)})},n=t.method.microSeconds();t._prepP?t._prepP.then(function(){t._iL=!0,t.method.onMessage(t._state,e,n)}):(t._iL=!0,t.method.onMessage(t._state,e,n))}}function Gr(t){if(t._iL&&!rn(t)){t._iL=!1;var e=t.method.microSeconds();t.method.onMessage(t._state,null,e)}}let Qt=class extends Error{constructor(e,n){super(e),this.name="DevalueError",this.path=n.join("")}};function ln(t){return Object(t)!==t}const Yr=Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function qr(t){const e=Object.getPrototypeOf(t);return e===Object.prototype||e===null||Object.getOwnPropertyNames(e).sort().join("\0")===Yr}function Qr(t){return Object.prototype.toString.call(t).slice(8,-1)}function Xr(t){switch(t){case'"':return'\\"';case"<":return"\\u003C";case"\\":return"\\\\";case`
|
|
12
|
-
|
|
13
|
-
*
|
|
14
|
-
* (c) 2024 Eduardo San Martin Morote
|
|
11
|
+
This will fail in production.`);i=Ae,i._s.has(e)||(r?Bt(e,t,o,i):qo(e,o,i),process.env.NODE_ENV!=="production"&&(a._pinia=i));const u=i._s.get(e);if(process.env.NODE_ENV!=="production"&&l){const d="__hot:"+e,f=r?Bt(d,t,o,i,!0):qo(d,F({},o),i,!0);l._hotUpdate(f),delete i.state.value[d],i._s.delete(d)}if(process.env.NODE_ENV!=="production"&&re){const d=s.getCurrentInstance();if(d&&d.proxy&&!l){const f=d.proxy,p="_pStores"in f?f._pStores:f._pStores={};p[e]=u}}return u}return a.$id=e,a}const Wi=Fi("data",()=>{const e=s.ref([]),t=s.ref({});return{records:e,record:t}});function Jo(e){const t=s.ref();return s.onMounted(async()=>{var n,o,r;e||(e=s.inject("$registry"));let a;try{a=Wi()}catch{throw new Error("Please enable the Stonecrop plugin before using the Stonecrop composable")}if(t.value=new Es(e,a),!e||!e.router)return;const i=e.router.currentRoute.value,l=(n=i.params.records)==null?void 0:n.toString().toLowerCase(),c=(o=i.params.record)==null?void 0:o.toString().toLowerCase();if(!l&&!c)return;const u=await((r=e.getMeta)==null?void 0:r.call(e,l));u&&(e.addDoctype(u),t.value.setup(u),l&&(c?await t.value.getRecord(u,c):await t.value.getRecords(u)),t.value.runAction(u,"LOAD",c?[c]:void 0))}),{stonecrop:t}}M(class lt{constructor(t,n){if(M(this,"name"),M(this,"registry"),M(this,"router"),M(this,"getMeta"),lt._root)return lt._root;lt._root=this,this.name="Registry",this.registry={},this.router=t,this.getMeta=n}addDoctype(t){t.doctype in Object.keys(this.registry)||(this.registry[t.slug]=t),t.component&&this.router&&!this.router.hasRoute(t.doctype)&&this.router.addRoute({path:`/${t.slug}`,name:t.slug,component:t.component})}},"_root");function Gi(e){return e&&typeof e.then=="function"}Promise.resolve(!1),Promise.resolve(!0);var ve=Promise.resolve();function Xo(e,t){return e||(e=0),new Promise(function(n){return setTimeout(function(){return n(t)},e)})}function Yi(e,t){return Math.floor(Math.random()*(t-e+1)+e)}function Ht(){return Math.random().toString(36).substring(2)}var zt=0;function Le(){var e=Date.now()*1e3;return e<=zt&&(e=zt+1),zt=e,e}var qi=Le,Ji="native";function Xi(e){var t={time:Le(),messagesCallback:null,bc:new BroadcastChannel(e),subFns:[]};return t.bc.onmessage=function(n){t.messagesCallback&&t.messagesCallback(n.data)},t}function Zi(e){e.bc.close(),e.subFns=[]}function Qi(e,t){try{return e.bc.postMessage(t,!1),ve}catch(n){return Promise.reject(n)}}function el(e,t){e.messagesCallback=t}function tl(){if(typeof globalThis<"u"&&globalThis.Deno&&globalThis.Deno.args)return!0;if((typeof window<"u"||typeof self<"u")&&typeof BroadcastChannel=="function"){if(BroadcastChannel._pubkey)throw new Error("BroadcastChannel: Do not overwrite window.BroadcastChannel with this module, this is not a polyfill");return!0}else return!1}function nl(){return 150}var ol={create:Xi,close:Zi,onMessage:el,postMessage:Qi,canBeUsed:tl,type:Ji,averageResponseTime:nl,microSeconds:qi};class Zo{constructor(t){M(this,"ttl"),M(this,"map",new Map),M(this,"_to",!1),this.ttl=t}has(t){return this.map.has(t)}add(t){this.map.set(t,Qo()),this._to||(this._to=!0,setTimeout(()=>{this._to=!1,rl(this)},0))}clear(){this.map.clear()}}function rl(e){const t=Qo()-e.ttl,n=e.map[Symbol.iterator]();for(;;){const o=n.next().value;if(!o)return;const r=o[0];if(o[1]<t)e.map.delete(r);else return}}function Qo(){return Date.now()}function Kt(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=JSON.parse(JSON.stringify(e));return typeof t.webWorkerSupport>"u"&&(t.webWorkerSupport=!0),t.idb||(t.idb={}),t.idb.ttl||(t.idb.ttl=1e3*45),t.idb.fallbackInterval||(t.idb.fallbackInterval=150),e.idb&&typeof e.idb.onclose=="function"&&(t.idb.onclose=e.idb.onclose),t.localstorage||(t.localstorage={}),t.localstorage.removeTimeout||(t.localstorage.removeTimeout=1e3*60),e.methods&&(t.methods=e.methods),t.node||(t.node={}),t.node.ttl||(t.node.ttl=1e3*60*2),t.node.maxParallelWrites||(t.node.maxParallelWrites=2048),typeof t.node.useFastPath>"u"&&(t.node.useFastPath=!0),t}var sl=Le,al="pubkey.broadcast-channel-0-",ee="messages",ot={durability:"relaxed"},il="idb";function er(){if(typeof indexedDB<"u")return indexedDB;if(typeof window<"u"){if(typeof window.mozIndexedDB<"u")return window.mozIndexedDB;if(typeof window.webkitIndexedDB<"u")return window.webkitIndexedDB;if(typeof window.msIndexedDB<"u")return window.msIndexedDB}return!1}function Ft(e){e.commit&&e.commit()}function ll(e){var t=er(),n=al+e,o=t.open(n);return o.onupgradeneeded=function(r){var a=r.target.result;a.createObjectStore(ee,{keyPath:"id",autoIncrement:!0})},new Promise(function(r,a){o.onerror=function(i){return a(i)},o.onsuccess=function(){r(o.result)}})}function cl(e,t,n){var o=Date.now(),r={uuid:t,time:o,data:n},a=e.transaction([ee],"readwrite",ot);return new Promise(function(i,l){a.oncomplete=function(){return i()},a.onerror=function(u){return l(u)};var c=a.objectStore(ee);c.add(r),Ft(a)})}function ul(e,t){var n=e.transaction(ee,"readonly",ot),o=n.objectStore(ee),r=[],a=IDBKeyRange.bound(t+1,1/0);if(o.getAll){var i=o.getAll(a);return new Promise(function(c,u){i.onerror=function(d){return u(d)},i.onsuccess=function(d){c(d.target.result)}})}function l(){try{return a=IDBKeyRange.bound(t+1,1/0),o.openCursor(a)}catch{return o.openCursor()}}return new Promise(function(c,u){var d=l();d.onerror=function(f){return u(f)},d.onsuccess=function(f){var p=f.target.result;p?p.value.id<t+1?p.continue(t+1):(r.push(p.value),p.continue()):(Ft(n),c(r))}})}function dl(e,t){if(e.closed)return Promise.resolve([]);var n=e.db.transaction(ee,"readwrite",ot),o=n.objectStore(ee);return Promise.all(t.map(function(r){var a=o.delete(r);return new Promise(function(i){a.onsuccess=function(){return i()}})}))}function fl(e,t){var n=Date.now()-t,o=e.transaction(ee,"readonly",ot),r=o.objectStore(ee),a=[];return new Promise(function(i){r.openCursor().onsuccess=function(l){var c=l.target.result;if(c){var u=c.value;u.time<n?(a.push(u),c.continue()):(Ft(o),i(a))}else i(a)}})}function pl(e){return fl(e.db,e.options.idb.ttl).then(function(t){return dl(e,t.map(function(n){return n.id}))})}function ml(e,t){return t=Kt(t),ll(e).then(function(n){var o={closed:!1,lastCursorId:0,channelName:e,options:t,uuid:Ht(),eMIs:new Zo(t.idb.ttl*2),writeBlockPromise:ve,messagesCallback:null,readQueuePromises:[],db:n};return n.onclose=function(){o.closed=!0,t.idb.onclose&&t.idb.onclose()},tr(o),o})}function tr(e){e.closed||nr(e).then(function(){return Xo(e.options.idb.fallbackInterval)}).then(function(){return tr(e)})}function hl(e,t){return!(e.uuid===t.uuid||t.eMIs.has(e.id)||e.data.time<t.messagesCallbackTime)}function nr(e){return e.closed||!e.messagesCallback?ve:ul(e.db,e.lastCursorId).then(function(t){var n=t.filter(function(o){return!!o}).map(function(o){return o.id>e.lastCursorId&&(e.lastCursorId=o.id),o}).filter(function(o){return hl(o,e)}).sort(function(o,r){return o.time-r.time});return n.forEach(function(o){e.messagesCallback&&(e.eMIs.add(o.id),e.messagesCallback(o.data))}),ve})}function _l(e){e.closed=!0,e.db.close()}function gl(e,t){return e.writeBlockPromise=e.writeBlockPromise.then(function(){return cl(e.db,e.uuid,t)}).then(function(){Yi(0,10)===0&&pl(e)}),e.writeBlockPromise}function yl(e,t,n){e.messagesCallbackTime=n,e.messagesCallback=t,nr(e)}function El(){return!!er()}function wl(e){return e.idb.fallbackInterval*2}var bl={create:ml,close:_l,onMessage:yl,postMessage:gl,canBeUsed:El,type:il,averageResponseTime:wl,microSeconds:sl},vl=Le,kl="pubkey.broadcastChannel-",Ol="localstorage";function or(){var e;if(typeof window>"u")return null;try{e=window.localStorage,e=window["ie8-eventlistener/storage"]||window.localStorage}catch{}return e}function rr(e){return kl+e}function Sl(e,t){return new Promise(function(n){Xo().then(function(){var o=rr(e.channelName),r={token:Ht(),time:Date.now(),data:t,uuid:e.uuid},a=JSON.stringify(r);or().setItem(o,a);var i=document.createEvent("Event");i.initEvent("storage",!0,!0),i.key=o,i.newValue=a,window.dispatchEvent(i),n()})})}function Tl(e,t){var n=rr(e),o=function(r){r.key===n&&t(JSON.parse(r.newValue))};return window.addEventListener("storage",o),o}function Il(e){window.removeEventListener("storage",e)}function Vl(e,t){if(t=Kt(t),!sr())throw new Error("BroadcastChannel: localstorage cannot be used");var n=Ht(),o=new Zo(t.localstorage.removeTimeout),r={channelName:e,uuid:n,eMIs:o};return r.listener=Tl(e,function(a){r.messagesCallback&&a.uuid!==n&&(!a.token||o.has(a.token)||a.data.time&&a.data.time<r.messagesCallbackTime||(o.add(a.token),r.messagesCallback(a.data)))}),r}function Cl(e){Il(e.listener)}function Pl(e,t,n){e.messagesCallbackTime=n,e.messagesCallback=t}function sr(){var e=or();if(!e)return!1;try{var t="__broadcastchannel_check";e.setItem(t,"works"),e.removeItem(t)}catch{return!1}return!0}function Nl(){var e=120,t=navigator.userAgent.toLowerCase();return t.includes("safari")&&!t.includes("chrome")?e*2:e}var Dl={create:Vl,close:Cl,onMessage:Pl,postMessage:Sl,canBeUsed:sr,type:Ol,averageResponseTime:Nl,microSeconds:vl},ar=Le,Rl="simulate",Wt=new Set;function xl(e){var t={time:ar(),name:e,messagesCallback:null};return Wt.add(t),t}function Al(e){Wt.delete(e)}var ir=5;function $l(e,t){return new Promise(function(n){return setTimeout(function(){var o=Array.from(Wt);o.forEach(function(r){r.name===e.name&&r!==e&&r.messagesCallback&&r.time<t.time&&r.messagesCallback(t)}),n()},ir)})}function Ll(e,t){e.messagesCallback=t}function jl(){return!0}function Ul(){return ir}var Ml={create:xl,close:Al,onMessage:Ll,postMessage:$l,canBeUsed:jl,type:Rl,averageResponseTime:Ul,microSeconds:ar},lr=[ol,bl,Dl];function Bl(e){var t=[].concat(e.methods,lr).filter(Boolean);if(e.type){if(e.type==="simulate")return Ml;var n=t.find(function(r){return r.type===e.type});if(n)return n;throw new Error("method-type "+e.type+" not found")}e.webWorkerSupport||(t=t.filter(function(r){return r.type!=="idb"}));var o=t.find(function(r){return r.canBeUsed()});if(o)return o;throw new Error("No usable method found in "+JSON.stringify(lr.map(function(r){return r.type})))}var cr=new Set,Hl=0,Gt=function(e,t){this.id=Hl++,cr.add(this),this.name=e,this.options=Kt(t),this.method=Bl(this.options),this._iL=!1,this._onML=null,this._addEL={message:[],internal:[]},this._uMP=new Set,this._befC=[],this._prepP=null,zl(this)};Gt._pubkey=!0,Gt.prototype={postMessage:function(e){if(this.closed)throw new Error("BroadcastChannel.postMessage(): Cannot post message after channel has closed "+JSON.stringify(e));return ur(this,"message",e)},postInternal:function(e){return ur(this,"internal",e)},set onmessage(e){var t=this.method.microSeconds(),n={time:t,fn:e};pr(this,"message",this._onML),e&&typeof e=="function"?(this._onML=n,fr(this,"message",n)):this._onML=null},addEventListener:function(e,t){var n=this.method.microSeconds(),o={time:n,fn:t};fr(this,e,o)},removeEventListener:function(e,t){var n=this._addEL[e].find(function(o){return o.fn===t});pr(this,e,n)},close:function(){var e=this;if(!this.closed){cr.delete(this),this.closed=!0;var t=this._prepP?this._prepP:ve;return this._onML=null,this._addEL.message=[],t.then(function(){return Promise.all(Array.from(e._uMP))}).then(function(){return Promise.all(e._befC.map(function(n){return n()}))}).then(function(){return e.method.close(e._state)})}},get type(){return this.method.type},get isClosed(){return this.closed}};function ur(e,t,n){var o=e.method.microSeconds(),r={time:o,type:t,data:n},a=e._prepP?e._prepP:ve;return a.then(function(){var i=e.method.postMessage(e._state,r);return e._uMP.add(i),i.catch().then(function(){return e._uMP.delete(i)}),i})}function zl(e){var t=e.method.create(e.name,e.options);Gi(t)?(e._prepP=t,t.then(function(n){e._state=n})):e._state=t}function dr(e){return e._addEL.message.length>0||e._addEL.internal.length>0}function fr(e,t,n){e._addEL[t].push(n),Kl(e)}function pr(e,t,n){e._addEL[t]=e._addEL[t].filter(function(o){return o!==n}),Fl(e)}function Kl(e){if(!e._iL&&dr(e)){var t=function(o){e._addEL[o.type].forEach(function(r){o.time>=r.time&&r.fn(o.data)})},n=e.method.microSeconds();e._prepP?e._prepP.then(function(){e._iL=!0,e.method.onMessage(e._state,t,n)}):(e._iL=!0,e.method.onMessage(e._state,t,n))}}function Fl(e){if(e._iL&&!dr(e)){e._iL=!1;var t=e.method.microSeconds();e.method.onMessage(e._state,null,t)}}function mr(e,t={serialize:JSON.stringify,deserialize:JSON.parse}){return t.deserialize(t.serialize(e))}function Wl(e,t){return Object.keys(t).includes(e)}function Gl({enable:e=!0,initialize:t=!0,type:n,serializer:o}){return({store:r,options:a})=>{var i,l,c;const u=((i=a==null?void 0:a.share)==null?void 0:i.enable)??e,d=((l=a==null?void 0:a.share)==null?void 0:l.omit)??[];if(!u)return;const f=new Gt(r.$id,{type:n});let p=0,m=!1;const _=Object.keys(r.$state).filter(b=>!d.includes(b)&&Wl(b,r.$state));f.onmessage=b=>{if(b===void 0){f.postMessage({timestamp:p,state:mr(r.$state,o)});return}b.timestamp<=p||(m=!0,p=b.timestamp,r.$patch(h=>{_.forEach(k=>{h[k]=b.state[k]})}))},(((c=a==null?void 0:a.share)==null?void 0:c.initialize)??t)&&f.postMessage(void 0),r.$subscribe((b,h)=>{m||(p=Date.now(),f.postMessage({timestamp:p,state:mr(h,o)})),m=!1})}}Bi().use(Gl({enable:!0,initialize:!0}));const hr=s.defineComponent({__name:"Doctype",setup(e){const{stonecrop:t,isReady:n}=Jo(),o=s.ref([]);return s.watch(n,()=>{if(n.value){let r=t.value.schema.schema.toArray();r.forEach((a,i)=>{const c=t.value.store.record[a.fieldname];r[i].value=c}),o.value=r}}),(r,a)=>s.unref(n)?(s.openBlock(),s.createBlock(s.unref(_s),{key:0,class:"aform-main",modelValue:o.value,"onUpdate:modelValue":a[0]||(a[0]=i=>o.value=i)},null,8,["modelValue"])):s.createCommentVNode("",!0)}});/*!
|
|
12
|
+
* pinia v3.0.1
|
|
13
|
+
* (c) 2025 Eduardo San Martin Morote
|
|
15
14
|
* @license MIT
|
|
16
|
-
*/let
|
|
15
|
+
*/let je;const rt=e=>je=e,Yl=process.env.NODE_ENV!=="production"?Symbol("pinia"):Symbol();function de(e){return e&&typeof e=="object"&&Object.prototype.toString.call(e)==="[object Object]"&&typeof e.toJSON!="function"}var Ue;(function(e){e.direct="direct",e.patchObject="patch object",e.patchFunction="patch function"})(Ue||(Ue={}));const Me=typeof window<"u";function _r(e,t){for(const n in t){const o=t[n];if(!(n in e))continue;const r=e[n];de(r)&&de(o)&&!s.isRef(o)&&!s.isReactive(o)?e[n]=_r(r,o):e[n]=o}return e}const gr=()=>{};function yr(e,t,n,o=gr){e.push(t);const r=()=>{const a=e.indexOf(t);a>-1&&(e.splice(a,1),o())};return!n&&s.getCurrentScope()&&s.onScopeDispose(r),r}function ke(e,...t){e.slice().forEach(n=>{n(...t)})}const ql=e=>e(),Er=Symbol(),Yt=Symbol();function qt(e,t){e instanceof Map&&t instanceof Map?t.forEach((n,o)=>e.set(o,n)):e instanceof Set&&t instanceof Set&&t.forEach(e.add,e);for(const n in t){if(!t.hasOwnProperty(n))continue;const o=t[n],r=e[n];de(r)&&de(o)&&e.hasOwnProperty(n)&&!s.isRef(o)&&!s.isReactive(o)?e[n]=qt(r,o):e[n]=o}return e}const Jl=process.env.NODE_ENV!=="production"?Symbol("pinia:skipHydration"):Symbol();function Xl(e){return!de(e)||!e.hasOwnProperty(Jl)}const{assign:W}=Object;function wr(e){return!!(s.isRef(e)&&e.effect)}function br(e,t,n,o){const{state:r,actions:a,getters:i}=t,l=n.state.value[e];let c;function u(){!l&&(process.env.NODE_ENV==="production"||!o)&&(n.state.value[e]=r?r():{});const d=process.env.NODE_ENV!=="production"&&o?s.toRefs(s.ref(r?r():{}).value):s.toRefs(n.state.value[e]);return W(d,a,Object.keys(i||{}).reduce((f,p)=>(process.env.NODE_ENV!=="production"&&p in d&&console.warn(`[🍍]: A getter cannot have the same name as another state property. Rename one of them. Found with "${p}" in store "${e}".`),f[p]=s.markRaw(s.computed(()=>{rt(n);const m=n._s.get(e);return i[p].call(m,m)})),f),{}))}return c=Jt(e,u,t,n,o,!0),c}function Jt(e,t,n={},o,r,a){let i;const l=W({actions:{}},n);if(process.env.NODE_ENV!=="production"&&!o._e.active)throw new Error("Pinia destroyed");const c={deep:!0};process.env.NODE_ENV!=="production"&&(c.onTrigger=g=>{u?m=g:u==!1&&!y._hotUpdating&&(Array.isArray(m)?m.push(g):console.error("🍍 debuggerEvents should be an array. This is most likely an internal Pinia bug."))});let u,d,f=[],p=[],m;const _=o.state.value[e];!a&&!_&&(process.env.NODE_ENV==="production"||!r)&&(o.state.value[e]={});const b=s.ref({});let h;function k(g){let E;u=d=!1,process.env.NODE_ENV!=="production"&&(m=[]),typeof g=="function"?(g(o.state.value[e]),E={type:Ue.patchFunction,storeId:e,events:m}):(qt(o.state.value[e],g),E={type:Ue.patchObject,payload:g,storeId:e,events:m});const I=h=Symbol();s.nextTick().then(()=>{h===I&&(u=!0)}),d=!0,ke(f,E,o.state.value[e])}const O=a?function(){const{state:E}=n,I=E?E():{};this.$patch(D=>{W(D,I)})}:process.env.NODE_ENV!=="production"?()=>{throw new Error(`🍍: Store "${e}" is built using the setup syntax and does not implement $reset().`)}:gr;function V(){i.stop(),f=[],p=[],o._s.delete(e)}const A=(g,E="")=>{if(Er in g)return g[Yt]=E,g;const I=function(){rt(o);const D=Array.from(arguments),G=[],H=[];function C(L){G.push(L)}function Y(L){H.push(L)}ke(p,{args:D,name:I[Yt],store:y,after:C,onError:Y});let P;try{P=g.apply(this&&this.$id===e?this:y,D)}catch(L){throw ke(H,L),L}return P instanceof Promise?P.then(L=>(ke(G,L),L)).catch(L=>(ke(H,L),Promise.reject(L))):(ke(G,P),P)};return I[Er]=!0,I[Yt]=E,I},x=s.markRaw({actions:{},getters:{},state:[],hotState:b}),R={_p:o,$id:e,$onAction:yr.bind(null,p),$patch:k,$reset:O,$subscribe(g,E={}){const I=yr(f,g,E.detached,()=>D()),D=i.run(()=>s.watch(()=>o.state.value[e],G=>{(E.flush==="sync"?d:u)&&g({storeId:e,type:Ue.direct,events:m},G)},W({},c,E)));return I},$dispose:V},y=s.reactive(process.env.NODE_ENV!=="production"||process.env.NODE_ENV!=="production"&&process.env.NODE_ENV!=="test"&&Me?W({_hmrPayload:x,_customProperties:s.markRaw(new Set)},R):R);o._s.set(e,y);const v=(o._a&&o._a.runWithContext||ql)(()=>o._e.run(()=>(i=s.effectScope()).run(()=>t({action:A}))));for(const g in v){const E=v[g];if(s.isRef(E)&&!wr(E)||s.isReactive(E))process.env.NODE_ENV!=="production"&&r?b.value[g]=s.toRef(v,g):a||(_&&Xl(E)&&(s.isRef(E)?E.value=_[g]:qt(E,_[g])),o.state.value[e][g]=E),process.env.NODE_ENV!=="production"&&x.state.push(g);else if(typeof E=="function"){const I=process.env.NODE_ENV!=="production"&&r?E:A(E,g);v[g]=I,process.env.NODE_ENV!=="production"&&(x.actions[g]=E),l.actions[g]=E}else process.env.NODE_ENV!=="production"&&wr(E)&&(x.getters[g]=a?n.getters[g]:E,Me&&(v._getters||(v._getters=s.markRaw([]))).push(g))}if(W(y,v),W(s.toRaw(y),v),Object.defineProperty(y,"$state",{get:()=>process.env.NODE_ENV!=="production"&&r?b.value:o.state.value[e],set:g=>{if(process.env.NODE_ENV!=="production"&&r)throw new Error("cannot set hotState");k(E=>{W(E,g)})}}),process.env.NODE_ENV!=="production"&&(y._hotUpdate=s.markRaw(g=>{y._hotUpdating=!0,g._hmrPayload.state.forEach(E=>{if(E in y.$state){const I=g.$state[E],D=y.$state[E];typeof I=="object"&&de(I)&&de(D)?_r(I,D):g.$state[E]=D}y[E]=s.toRef(g.$state,E)}),Object.keys(y.$state).forEach(E=>{E in g.$state||delete y[E]}),u=!1,d=!1,o.state.value[e]=s.toRef(g._hmrPayload,"hotState"),d=!0,s.nextTick().then(()=>{u=!0});for(const E in g._hmrPayload.actions){const I=g[E];y[E]=A(I,E)}for(const E in g._hmrPayload.getters){const I=g._hmrPayload.getters[E],D=a?s.computed(()=>(rt(o),I.call(y,y))):I;y[E]=D}Object.keys(y._hmrPayload.getters).forEach(E=>{E in g._hmrPayload.getters||delete y[E]}),Object.keys(y._hmrPayload.actions).forEach(E=>{E in g._hmrPayload.actions||delete y[E]}),y._hmrPayload=g._hmrPayload,y._getters=g._getters,y._hotUpdating=!1})),process.env.NODE_ENV!=="production"&&process.env.NODE_ENV!=="test"&&Me){const g={writable:!0,configurable:!0,enumerable:!1};["_p","_hmrPayload","_getters","_customProperties"].forEach(E=>{Object.defineProperty(y,E,W({value:y[E]},g))})}return o._p.forEach(g=>{if(process.env.NODE_ENV!=="production"&&process.env.NODE_ENV!=="test"&&Me){const E=i.run(()=>g({store:y,app:o._a,pinia:o,options:l}));Object.keys(E||{}).forEach(I=>y._customProperties.add(I)),W(y,E)}else W(y,i.run(()=>g({store:y,app:o._a,pinia:o,options:l})))}),process.env.NODE_ENV!=="production"&&y.$state&&typeof y.$state=="object"&&typeof y.$state.constructor=="function"&&!y.$state.constructor.toString().includes("[native code]")&&console.warn(`[🍍]: The "state" must be a plain object. It cannot be
|
|
17
16
|
state: () => new MyClass()
|
|
18
|
-
Found in store "${
|
|
17
|
+
Found in store "${y.$id}".`),_&&a&&n.hydrate&&n.hydrate(y.$state,_),u=!0,d=!0,y}/*! #__NO_SIDE_EFFECTS__ */function Zl(e,t,n){let o;const r=typeof t=="function";o=r?n:t;function a(i,l){const c=s.hasInjectionContext();if(i=(process.env.NODE_ENV==="test"&&je&&je._testing?null:i)||(c?s.inject(Yl,null):null),i&&rt(i),process.env.NODE_ENV!=="production"&&!je)throw new Error(`[🍍]: "getActivePinia()" was called but there was no active Pinia. Are you trying to use a store before calling "app.use(pinia)"?
|
|
19
18
|
See https://pinia.vuejs.org/core-concepts/outside-component-usage.html for help.
|
|
20
|
-
This will fail in production.`);l=ut,l._s.has(o)||(a?oe(o,e,s,l):En(o,s,l),process.env.NODE_ENV!=="production"&&(i._pinia=l));const d=l._s.get(o);if(process.env.NODE_ENV!=="production"&&u){const f="__hot:"+o,p=a?oe(f,e,s,l,!0):En(f,B({},s),l,!0);u._hotUpdate(p),delete l.state.value[f],l._s.delete(f)}if(process.env.NODE_ENV!=="production"&&ft){const f=r.getCurrentInstance();if(f&&f.proxy&&!u){const p=f.proxy,w="_pStores"in p?p._pStores:p._pStores={};w[o]=d}}return d}return i.$id=o,i}function vn(t){return r.getCurrentScope()?(r.onScopeDispose(t),!0):!1}function re(t){return typeof t=="function"?t():r.unref(t)}const ls=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const cs=t=>t!=null,us=Object.prototype.toString,ds=t=>us.call(t)==="[object Object]",fs=()=>{},pt=ls?window:void 0;function mt(t){var e;const n=re(t);return(e=n==null?void 0:n.$el)!=null?e:n}function ht(...t){let e,n,o,s;if(typeof t[0]=="string"||Array.isArray(t[0])?([n,o,s]=t,e=pt):[e,n,o,s]=t,!e)return fs;Array.isArray(n)||(n=[n]),Array.isArray(o)||(o=[o]);const a=[],i=()=>{a.forEach(d=>d()),a.length=0},l=(d,f,p,w)=>(d.addEventListener(f,p,w),()=>d.removeEventListener(f,p,w)),u=r.watch(()=>[mt(e),re(s)],([d,f])=>{if(i(),!d)return;const p=ds(f)?{...f}:f;a.push(...n.flatMap(w=>o.map(h=>l(d,w,h,p))))},{immediate:!0,flush:"post"}),c=()=>{u(),i()};return vn(c),c}function ps(){const t=r.ref(!1),e=r.getCurrentInstance();return e&&r.onMounted(()=>{t.value=!0},e),t}function ms(t){const e=ps();return r.computed(()=>(e.value,!!t()))}function hs(t,e,n={}){const{window:o=pt,...s}=n;let a;const i=ms(()=>o&&"MutationObserver"in o),l=()=>{a&&(a.disconnect(),a=void 0)},u=r.computed(()=>{const p=re(t),w=(Array.isArray(p)?p:[p]).map(mt).filter(cs);return new Set(w)}),c=r.watch(()=>u.value,p=>{l(),i.value&&p.size&&(a=new MutationObserver(e),p.forEach(w=>a.observe(w,s)))},{immediate:!0,flush:"post"}),d=()=>a==null?void 0:a.takeRecords(),f=()=>{c(),l()};return vn(f),{isSupported:i,stop:f,takeRecords:d}}function gs(t={}){var e;const{window:n=pt,deep:o=!0,triggerOnRemoval:s=!1}=t,a=(e=t.document)!=null?e:n==null?void 0:n.document,i=()=>{var c;let d=a==null?void 0:a.activeElement;if(o)for(;d!=null&&d.shadowRoot;)d=(c=d==null?void 0:d.shadowRoot)==null?void 0:c.activeElement;return d},l=r.ref(),u=()=>{l.value=i()};return n&&(ht(n,"blur",c=>{c.relatedTarget===null&&u()},!0),ht(n,"focus",u,!0)),s&&hs(a,c=>{c.filter(d=>d.removedNodes.length).map(d=>Array.from(d.removedNodes)).flat().forEach(d=>{d===l.value&&u()})},{childList:!0,subtree:!0}),u(),l}const ys="focusin",ws="focusout";function bs(t,e={}){const{window:n=pt}=e,o=r.computed(()=>mt(t)),s=r.ref(!1),a=r.computed(()=>s.value),i=gs(e);return!n||!i.value?{focused:a}:(ht(o,ys,()=>s.value=!0),ht(o,ws,()=>s.value=!1),{focused:a})}function _s(t,{window:e=pt,scrollTarget:n}={}){const o=r.ref(!1),s=()=>{if(!e)return;const a=e.document,i=mt(t);if(!i)o.value=!1;else{const l=i.getBoundingClientRect();o.value=l.top<=(e.innerHeight||a.documentElement.clientHeight)&&l.left<=(e.innerWidth||a.documentElement.clientWidth)&&l.bottom>=0&&l.right>=0}};return r.watch(()=>mt(t),()=>s(),{immediate:!0,flush:"post"}),e&&ht(n||e,"scroll",s,{capture:!1,passive:!0}),o}const F=t=>{let e=_s(t).value;return e=e&&t.offsetHeight>0,e},z=t=>t.tabIndex>=0,kn=t=>{const e=t.target;return se(e)},se=t=>{var e;let n;if(t instanceof HTMLTableCellElement){const o=(e=t.parentElement)==null?void 0:e.previousElementSibling;if(o){const s=Array.from(o.children)[t.cellIndex];s&&(n=s)}}else if(t instanceof HTMLTableRowElement){const o=t.previousElementSibling;o&&(n=o)}return n&&(!z(n)||!F(n))?se(n):n},Es=t=>{var e;const n=t.target;let o;if(n instanceof HTMLTableCellElement){const s=(e=n.parentElement)==null?void 0:e.parentElement;if(s){const a=s.firstElementChild,i=a==null?void 0:a.children[n.cellIndex];i&&(o=i)}}else if(n instanceof HTMLTableRowElement){const s=n.parentElement;if(s){const a=s.firstElementChild;a&&(o=a)}}return o&&(!z(o)||!F(o))?ae(o):o},$n=t=>{const e=t.target;return ae(e)},ae=t=>{var e;let n;if(t instanceof HTMLTableCellElement){const o=(e=t.parentElement)==null?void 0:e.nextElementSibling;if(o){const s=Array.from(o.children)[t.cellIndex];s&&(n=s)}}else if(t instanceof HTMLTableRowElement){const o=t.nextElementSibling;o&&(n=o)}return n&&(!z(n)||!F(n))?ae(n):n},vs=t=>{var e;const n=t.target;let o;if(n instanceof HTMLTableCellElement){const s=(e=n.parentElement)==null?void 0:e.parentElement;if(s){const a=s.lastElementChild,i=a==null?void 0:a.children[n.cellIndex];i&&(o=i)}}else if(n instanceof HTMLTableRowElement){const s=n.parentElement;if(s){const a=s.lastElementChild;a&&(o=a)}}return o&&(!z(o)||!F(o))?se(o):o},Sn=t=>{const e=t.target;return ie(e)},ie=t=>{var e;let n;if(t.previousElementSibling)n=t.previousElementSibling;else{const o=(e=t.parentElement)==null?void 0:e.previousElementSibling;n=o==null?void 0:o.lastElementChild}return n&&(!z(n)||!F(n))?ie(n):n},Nn=t=>{const e=t.target;return le(e)},le=t=>{var e;let n;if(t.nextElementSibling)n=t.nextElementSibling;else{const o=(e=t.parentElement)==null?void 0:e.nextElementSibling;n=o==null?void 0:o.firstElementChild}return n&&(!z(n)||!F(n))?le(n):n},xn=t=>{const e=t.target.parentElement,n=e==null?void 0:e.firstElementChild;return n&&(!z(n)||!F(n))?le(n):n},On=t=>{const e=t.target.parentElement,n=e==null?void 0:e.lastElementChild;return n&&(!z(n)||!F(n))?ie(n):n},Ct=["alt","control","shift","meta"],ks={ArrowUp:"up",ArrowDown:"down",ArrowLeft:"left",ArrowRight:"right"},ce={"keydown.up":t=>{const e=kn(t);e&&(t.preventDefault(),t.stopPropagation(),e.focus())},"keydown.down":t=>{const e=$n(t);e&&(t.preventDefault(),t.stopPropagation(),e.focus())},"keydown.left":t=>{const e=Sn(t);t.preventDefault(),t.stopPropagation(),e&&e.focus()},"keydown.right":t=>{const e=Nn(t);t.preventDefault(),t.stopPropagation(),e&&e.focus()},"keydown.control.up":t=>{const e=Es(t);e&&(t.preventDefault(),t.stopPropagation(),e.focus())},"keydown.control.down":t=>{const e=vs(t);e&&(t.preventDefault(),t.stopPropagation(),e.focus())},"keydown.control.left":t=>{const e=xn(t);e&&(t.preventDefault(),t.stopPropagation(),e.focus())},"keydown.control.right":t=>{const e=On(t);e&&(t.preventDefault(),t.stopPropagation(),e.focus())},"keydown.end":t=>{const e=On(t);e&&(t.preventDefault(),t.stopPropagation(),e.focus())},"keydown.enter":t=>{if(t.target instanceof HTMLTableCellElement){t.preventDefault(),t.stopPropagation();const e=$n(t);e&&e.focus()}},"keydown.shift.enter":t=>{if(t.target instanceof HTMLTableCellElement){t.preventDefault(),t.stopPropagation();const e=kn(t);e&&e.focus()}},"keydown.home":t=>{const e=xn(t);e&&(t.preventDefault(),t.stopPropagation(),e.focus())},"keydown.tab":t=>{const e=Nn(t);e&&(t.preventDefault(),t.stopPropagation(),e.focus())},"keydown.shift.tab":t=>{const e=Sn(t);e&&(t.preventDefault(),t.stopPropagation(),e.focus())}};function Cn(t){const e=i=>{let l=null;return i.parent&&(typeof i.parent=="string"?l=document.querySelector(i.parent):i.parent instanceof HTMLElement?l=i.parent:l=i.parent.value),l},n=i=>{var l;const u=e(i);let c=[];if(typeof i.selectors=="string")c=u?Array.from(u.querySelectorAll(i.selectors)):Array.from(document.querySelectorAll(i.selectors));else if(Array.isArray(i.selectors))for(const d of i.selectors)d instanceof HTMLElement?c.push(d):c.push(d.$el);else if(i.selectors instanceof HTMLElement)c.push(i.selectors);else if((l=i.selectors)!=null&&l.value)if(Array.isArray(i.selectors.value))for(const d of i.selectors.value)d instanceof HTMLElement?c.push(d):c.push(d.$el);else c.push(i.selectors.value);return c},o=i=>{const l=e(i);let u=[];return i.selectors?u=n(i):l&&(u=Array.from(l.children).filter(c=>z(c)&&F(c))),u},s=i=>l=>{const u=ks[l.key]||l.key.toLowerCase();if(Ct.includes(u))return;const c=i.handlers||ce;for(const d of Object.keys(c)){const[f,...p]=d.split(".");if(f==="keydown"&&p.includes(u)){const w=c[d],h=p.filter(E=>Ct.includes(E)),_=Ct.some(E=>{const S=E.charAt(0).toUpperCase()+E.slice(1);return l.getModifierState(S)});if(h.length>0){if(_){for(const E of Ct)if(p.includes(E)){const S=E.charAt(0).toUpperCase()+E.slice(1);l.getModifierState(S)&&w(l)}}}else _||w(l)}}},a=[];r.onMounted(()=>{for(const i of t){const l=e(i),u=o(i),c=s(i),d=l?[l]:u;for(const f of d){const{focused:p}=bs(r.ref(f)),w=r.watch(p,h=>{h?f.addEventListener("keydown",c):f.removeEventListener("keydown",c)});a.push(w)}}}),r.onBeforeUnmount(()=>{for(const i of a)i()})}function gt(t){return r.getCurrentScope()?(r.onScopeDispose(t),!0):!1}function R(t){return typeof t=="function"?t():r.unref(t)}const ue=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const $s=t=>t!=null,Ss=Object.prototype.toString,Pn=t=>Ss.call(t)==="[object Object]",rt=()=>{},de=Ns();function Ns(){var t,e;return ue&&((t=window==null?void 0:window.navigator)==null?void 0:t.userAgent)&&(/iP(?:ad|hone|od)/.test(window.navigator.userAgent)||((e=window==null?void 0:window.navigator)==null?void 0:e.maxTouchPoints)>2&&/iPad|Macintosh/.test(window==null?void 0:window.navigator.userAgent))}function xs(t){return r.getCurrentInstance()}function Os(...t){if(t.length!==1)return r.toRef(...t);const e=t[0];return typeof e=="function"?r.readonly(r.customRef(()=>({get:e,set:rt}))):r.ref(e)}function Cs(t,e=!0,n){xs()?r.onMounted(t,n):e?t():r.nextTick(t)}const fe=ue?window:void 0;function st(t){var e;const n=R(t);return(e=n==null?void 0:n.$el)!=null?e:n}function In(...t){let e,n,o,s;if(typeof t[0]=="string"||Array.isArray(t[0])?([n,o,s]=t,e=fe):[e,n,o,s]=t,!e)return rt;Array.isArray(n)||(n=[n]),Array.isArray(o)||(o=[o]);const a=[],i=()=>{a.forEach(d=>d()),a.length=0},l=(d,f,p,w)=>(d.addEventListener(f,p,w),()=>d.removeEventListener(f,p,w)),u=r.watch(()=>[st(e),R(s)],([d,f])=>{if(i(),!d)return;const p=Pn(f)?{...f}:f;a.push(...n.flatMap(w=>o.map(h=>l(d,w,h,p))))},{immediate:!0,flush:"post"}),c=()=>{u(),i()};return gt(c),c}function Ps(){const t=r.ref(!1),e=r.getCurrentInstance();return e&&r.onMounted(()=>{t.value=!0},e),t}function Vn(t){const e=Ps();return r.computed(()=>(e.value,!!t()))}function Dn(t,e,n={}){const{window:o=fe,...s}=n;let a;const i=Vn(()=>o&&"MutationObserver"in o),l=()=>{a&&(a.disconnect(),a=void 0)},u=r.computed(()=>{const p=R(t),w=(Array.isArray(p)?p:[p]).map(st).filter($s);return new Set(w)}),c=r.watch(()=>u.value,p=>{l(),i.value&&p.size&&(a=new MutationObserver(e),p.forEach(w=>a.observe(w,s)))},{immediate:!0,flush:"post"}),d=()=>a==null?void 0:a.takeRecords(),f=()=>{c(),l()};return gt(f),{isSupported:i,stop:f,takeRecords:d}}function Is(t,e,n={}){const{window:o=fe,...s}=n;let a;const i=Vn(()=>o&&"ResizeObserver"in o),l=()=>{a&&(a.disconnect(),a=void 0)},u=r.computed(()=>{const f=R(t);return Array.isArray(f)?f.map(p=>st(p)):[st(f)]}),c=r.watch(u,f=>{if(l(),i.value&&o){a=new ResizeObserver(e);for(const p of f)p&&a.observe(p,s)}},{immediate:!0,flush:"post"}),d=()=>{l(),c()};return gt(d),{isSupported:i,stop:d}}function Tn(t,e={}){const{reset:n=!0,windowResize:o=!0,windowScroll:s=!0,immediate:a=!0,updateTiming:i="sync"}=e,l=r.ref(0),u=r.ref(0),c=r.ref(0),d=r.ref(0),f=r.ref(0),p=r.ref(0),w=r.ref(0),h=r.ref(0);function _(){const S=st(t);if(!S){n&&(l.value=0,u.value=0,c.value=0,d.value=0,f.value=0,p.value=0,w.value=0,h.value=0);return}const $=S.getBoundingClientRect();l.value=$.height,u.value=$.bottom,c.value=$.left,d.value=$.right,f.value=$.top,p.value=$.width,w.value=$.x,h.value=$.y}function E(){i==="sync"?_():i==="next-frame"&&requestAnimationFrame(()=>_())}return Is(t,E),r.watch(()=>st(t),S=>!S&&E()),Dn(t,E,{attributeFilter:["style","class"]}),s&&In("scroll",E,{capture:!0,passive:!0}),o&&In("resize",E,{passive:!0}),Cs(()=>{a&&E()}),{height:l,bottom:u,left:c,right:d,top:f,width:p,x:w,y:h,update:E}}const Vs=t=>{const e=new DOMParser().parseFromString(t,"text/html");return Array.from(e.body.childNodes).some(n=>n.nodeType===1)},Ds=(t=8)=>Array.from({length:t},()=>Math.floor(Math.random()*16).toString(16)).join(""),Ts=["data-colindex","data-rowindex","data-editable","contenteditable","tabindex"],As=["innerHTML"],Bs={key:2},Rs=r.defineComponent({__name:"ACell",props:{colIndex:{},rowIndex:{},store:{},addNavigation:{type:[Boolean,Object],default:!0},tabIndex:{default:0},pinned:{type:Boolean,default:!1}},emits:["cellInput"],setup(t,{emit:e}){const n=e,o=r.useTemplateRef("cell"),s=t.store.getCellData(t.colIndex,t.rowIndex),a=r.ref(""),i=r.ref(!1),l=t.store.columns[t.colIndex],u=t.store.rows[t.rowIndex],c=l.align||"center",d=l.width||"40ch",f=r.computed(()=>t.store.getCellDisplayValue(t.colIndex,t.rowIndex)),p=r.computed(()=>typeof f.value=="string"?Vs(f.value):!1),w=r.computed(()=>{var $;return{textAlign:c,width:d,fontWeight:i.value?"bold":"inherit",paddingLeft:t.store.getIndent(t.colIndex,($=t.store.display[t.rowIndex])==null?void 0:$.indent)}}),h=r.computed(()=>({"sticky-column":t.pinned,"cell-modified":i.value})),_=()=>{const{left:$,bottom:I,width:j,height:V}=Tn(o);l.mask,l.modalComponent&&t.store.$patch(N=>{N.modal.visible=!0,N.modal.colIndex=t.colIndex,N.modal.rowIndex=t.rowIndex,N.modal.left=$,N.modal.bottom=I,N.modal.width=j,N.modal.height=V,N.modal.cell=o.value,typeof l.modalComponent=="function"?N.modal.component=l.modalComponent({table:N.table,row:u,column:l}):N.modal.component=l.modalComponent,N.modal.componentProps=l.modalComponentExtraProps})};if(t.addNavigation){let $={...ce,"keydown.f2":_,"keydown.alt.up":_,"keydown.alt.down":_,"keydown.alt.left":_,"keydown.alt.right":_};typeof t.addNavigation=="object"&&($={...$,...t.addNavigation}),Cn([{selectors:o,handlers:$}])}const E=()=>{o.value&&(a.value=o.value.textContent)},S=$=>{const I=$.target;I.textContent!==a.value&&(n("cellInput",t.colIndex,t.rowIndex,I.textContent,a.value),a.value=I.textContent,l.format?(i.value=I.textContent!==t.store.getFormattedValue(t.colIndex,t.rowIndex,s),t.store.setCellText(t.colIndex,t.rowIndex,I.textContent)):(i.value=I.textContent!==s,t.store.setCellData(t.colIndex,t.rowIndex,I.textContent)))};return($,I)=>(r.openBlock(),r.createElementBlock("td",{ref:"cell","data-colindex":$.colIndex,"data-rowindex":$.rowIndex,"data-editable":r.unref(l).edit,contenteditable:r.unref(l).edit,tabindex:$.tabIndex,spellcheck:!1,style:r.normalizeStyle(w.value),onFocus:E,onPaste:S,onInput:S,onClick:_,class:r.normalizeClass(["atable-cell",h.value])},[r.unref(l).cellComponent?(r.openBlock(),r.createBlock(r.resolveDynamicComponent(r.unref(l).cellComponent),r.mergeProps({key:0,value:f.value},r.unref(l).cellComponentProps),null,16,["value"])):p.value?(r.openBlock(),r.createElementBlock("span",{key:1,innerHTML:f.value},null,8,As)):(r.openBlock(),r.createElementBlock("span",Bs,r.toDisplayString(f.value),1))],46,Ts))}}),An=(t,e)=>{const n=t.__vccOpts||t;for(const[o,s]of e)n[o]=s;return n},js=["tabindex"],Ls=r.defineComponent({__name:"ARow",props:{rowIndex:{},store:{},tabIndex:{default:()=>-1},addNavigation:{type:[Boolean,Object],default:!1}},setup(t){const e=r.useTemplateRef("rowEl"),n=r.computed(()=>t.store.isRowVisible(t.rowIndex)),o=r.computed(()=>t.store.getRowExpandSymbol(t.rowIndex));if(t.addNavigation){let s=ce;typeof t.addNavigation=="object"&&(s={...s,...t.addNavigation}),Cn([{selectors:e,handlers:s}])}return(s,a)=>r.withDirectives((r.openBlock(),r.createElementBlock("tr",{ref:"rowEl",tabindex:s.tabIndex,class:"atable-row"},[s.store.config.view!=="uncounted"?r.renderSlot(s.$slots,"index",{key:0},()=>[s.store.config.view==="list"?(r.openBlock(),r.createElementBlock("td",{key:0,tabIndex:-1,class:r.normalizeClass(["list-index",s.store.hasPinnedColumns?"sticky-index":""])},r.toDisplayString(s.rowIndex+1),3)):s.store.config.view==="tree"?(r.openBlock(),r.createElementBlock("td",{key:1,tabIndex:-1,class:r.normalizeClass(["tree-index",s.store.hasPinnedColumns?"sticky-index":""]),onClick:a[0]||(a[0]=i=>s.store.toggleRowExpand(s.rowIndex))},r.toDisplayString(o.value),3)):r.createCommentVNode("",!0)],!0):r.createCommentVNode("",!0),r.renderSlot(s.$slots,"default",{},void 0,!0)],8,js)),[[r.vShow,n.value]])}}),Ms=An(Ls,[["__scopeId","data-v-9c529d3d"]]),Bn=ue?window:void 0;function yt(t){var e;const n=R(t);return(e=n==null?void 0:n.$el)!=null?e:n}function Pt(...t){let e,n,o,s;if(typeof t[0]=="string"||Array.isArray(t[0])?([n,o,s]=t,e=Bn):[e,n,o,s]=t,!e)return rt;Array.isArray(n)||(n=[n]),Array.isArray(o)||(o=[o]);const a=[],i=()=>{a.forEach(d=>d()),a.length=0},l=(d,f,p,w)=>(d.addEventListener(f,p,w),()=>d.removeEventListener(f,p,w)),u=r.watch(()=>[yt(e),R(s)],([d,f])=>{if(i(),!d)return;const p=Pn(f)?{...f}:f;a.push(...n.flatMap(w=>o.map(h=>l(d,w,h,p))))},{immediate:!0,flush:"post"}),c=()=>{u(),i()};return gt(c),c}let Rn=!1;function jn(t,e,n={}){const{window:o=Bn,ignore:s=[],capture:a=!0,detectIframe:i=!1}=n;if(!o)return rt;de&&!Rn&&(Rn=!0,Array.from(o.document.body.children).forEach(h=>h.addEventListener("click",rt)),o.document.documentElement.addEventListener("click",rt));let l=!0;const u=h=>R(s).some(_=>{if(typeof _=="string")return Array.from(o.document.querySelectorAll(_)).some(E=>E===h.target||h.composedPath().includes(E));{const E=yt(_);return E&&(h.target===E||h.composedPath().includes(E))}});function c(h){const _=R(h);return _&&_.$.subTree.shapeFlag===16}function d(h,_){const E=R(h),S=E.$.subTree&&E.$.subTree.children;return S==null||!Array.isArray(S)?!1:S.some($=>$.el===_.target||_.composedPath().includes($.el))}const f=h=>{const _=yt(t);if(h.target!=null&&!(!(_ instanceof Element)&&c(t)&&d(t,h))&&!(!_||_===h.target||h.composedPath().includes(_))){if(h.detail===0&&(l=!u(h)),!l){l=!0;return}e(h)}};let p=!1;const w=[Pt(o,"click",h=>{p||(p=!0,setTimeout(()=>{p=!1},0),f(h))},{passive:!0,capture:a}),Pt(o,"pointerdown",h=>{const _=yt(t);l=!u(h)&&!!(_&&!h.composedPath().includes(_))},{passive:!0}),i&&Pt(o,"blur",h=>{setTimeout(()=>{var _;const E=yt(t);((_=o.document.activeElement)==null?void 0:_.tagName)==="IFRAME"&&!(E!=null&&E.contains(o.document.activeElement))&&e(h)},0)})].filter(Boolean);return()=>w.forEach(h=>h())}const Us={mounted(t,e){const n=!e.modifiers.bubble;if(typeof e.value=="function")t.__onClickOutside_stop=jn(t,e.value,{capture:n});else{const[o,s]=e.value;t.__onClickOutside_stop=jn(t,o,Object.assign({capture:n},s))}},unmounted(t){t.__onClickOutside_stop()}};function pe(t){return typeof Window<"u"&&t instanceof Window?t.document.documentElement:typeof Document<"u"&&t instanceof Document?t.documentElement:t}function Ln(t){const e=window.getComputedStyle(t);if(e.overflowX==="scroll"||e.overflowY==="scroll"||e.overflowX==="auto"&&t.clientWidth<t.scrollWidth||e.overflowY==="auto"&&t.clientHeight<t.scrollHeight)return!0;{const n=t.parentNode;return!n||n.tagName==="BODY"?!1:Ln(n)}}function Ws(t){const e=t||window.event,n=e.target;return Ln(n)?!1:e.touches.length>1?!0:(e.preventDefault&&e.preventDefault(),!1)}const me=new WeakMap;function Hs(t,e=!1){const n=r.ref(e);let o=null,s="";r.watch(Os(t),l=>{const u=pe(R(l));if(u){const c=u;if(me.get(c)||me.set(c,c.style.overflow),c.style.overflow!=="hidden"&&(s=c.style.overflow),c.style.overflow==="hidden")return n.value=!0;if(n.value)return c.style.overflow="hidden"}},{immediate:!0});const a=()=>{const l=pe(R(t));!l||n.value||(de&&(o=Pt(l,"touchmove",u=>{Ws(u)},{passive:!1})),l.style.overflow="hidden",n.value=!0)},i=()=>{const l=pe(R(t));!l||!n.value||(de&&(o==null||o()),l.style.overflow=s,me.delete(l),n.value=!1)};return gt(i),r.computed({get(){return n.value},set(l){l?a():i()}})}function Fs(){let t=!1;const e=r.ref(!1);return(n,o)=>{if(e.value=o.value,t)return;t=!0;const s=Hs(n,o.value);r.watch(e,a=>s.value=a)}}Fs();const zs={key:0,id:"resizable"},Js={class:"atable-header-row",tabindex:"-1"},Gs=r.defineComponent({__name:"ATableHeader",props:{columns:{},store:{}},setup(t){return(e,n)=>e.columns.length?(r.openBlock(),r.createElementBlock("thead",zs,[r.createElementVNode("tr",Js,[e.store.zeroColumn?(r.openBlock(),r.createElementBlock("th",{key:0,id:"header-index",class:r.normalizeClass([[e.store.hasPinnedColumns?"sticky-index":"",e.store.config.view==="tree"?"tree-index":"",e.store.config.view==="list-expansion"?"list-expansion-index":""],"list-index"])},null,2)):r.createCommentVNode("",!0),(r.openBlock(!0),r.createElementBlock(r.Fragment,null,r.renderList(e.columns,(o,s)=>(r.openBlock(),r.createElementBlock("th",{key:o.name,tabindex:"-1",style:r.normalizeStyle(e.store.getHeaderCellStyle(o)),class:r.normalizeClass(o.pinned?"sticky-column":"")},[r.renderSlot(e.$slots,"default",{},()=>[r.createTextVNode(r.toDisplayString(o.label||String.fromCharCode(s+97).toUpperCase()),1)])],6))),128))])])):r.createCommentVNode("",!0)}}),Ys=r.defineComponent({__name:"ATableModal",props:{store:{}},setup(t){const e=r.useTemplateRef("amodal"),{width:n,height:o}=Tn(e),s=r.computed(()=>{var a,i,l,u;if(!(t.store.modal.height&&t.store.modal.width&&t.store.modal.left&&t.store.modal.bottom))return;const c=(a=t.store.modal.cell)==null?void 0:a.closest("table"),d=c.offsetHeight||0,f=c.offsetWidth||0;let p=((i=t.store.modal.cell)==null?void 0:i.offsetTop)||0;const w=((l=c.querySelector("thead"))==null?void 0:l.offsetHeight)||0;p+=w,p=p+o.value<d?p:p-(o.value+t.store.modal.height);let h=((u=t.store.modal.cell)==null?void 0:u.offsetLeft)||0;return h=h+n.value<=f?h:h-(n.value-t.store.modal.width),{left:`${h}px`,top:`${p}px`}});return(a,i)=>(r.openBlock(),r.createElementBlock("div",{class:"amodal",ref:"amodal",tabindex:"-1",onClick:i[0]||(i[0]=r.withModifiers(()=>{},["stop"])),onInput:i[1]||(i[1]=r.withModifiers(()=>{},["stop"])),style:r.normalizeStyle(s.value)},[r.renderSlot(a.$slots,"default")],36))}}),qs=t=>{const e=t.id||Ds();return is(`table-${e}`,()=>{const n=()=>{const g={};for(const[v,b]of s.value.entries())for(const[m,y]of a.value.entries())g[`${v}:${m}`]=y[b.name];return g},o=g=>{const v=[Object.assign({},{rowModified:!1})];if(g&&"0:0"in g)return g;const b=new Set;for(let m=a.value.length-1;m>=0;m--){const y=a.value[m];y.parent&&b.add(y.parent),v[m]={childrenOpen:!1,expanded:!1,indent:y.indent||0,isParent:b.has(m),isRoot:y.parent===null||y.parent===void 0,rowModified:!1,open:y.parent===null||y.parent===void 0,parent:y.parent}}return v},s=r.ref(t.columns),a=r.ref(t.rows),i=r.ref(t.config||{}),l=r.ref(t.table||n()),u=r.ref(o(t.display)),c=r.ref(t.modal||{visible:!1}),d=r.ref({}),f=r.computed(()=>s.value.some(g=>g.pinned)),p=r.computed(()=>`${Math.ceil(a.value.length/100+1)}ch`),w=r.computed(()=>i.value.view?["list","tree","list-expansion"].includes(i.value.view):!1),h=(g,v)=>l.value[`${g}:${v}`],_=(g,v,b)=>{const m=`${g}:${v}`,y=s.value[g];l.value[m]!==b&&(u.value[v].rowModified=!0),l.value[m]=b,a.value[v][y.name]=b},E=(g,v,b)=>{const m=`${g}:${v}`;l.value[m]!==b&&(u.value[v].rowModified=!0,d.value[m]=b)},S=g=>({minWidth:g.width||"40ch",textAlign:g.align||"center",width:i.value.fullWidth?"auto":void 0}),$=g=>i.value.view!=="tree"||u.value[g].isRoot||u.value[g].open,I=g=>i.value.view!=="tree"?"":u.value[g].isRoot||u.value[g].isParent?u.value[g].childrenOpen?"-":"+":"",j=g=>{if(i.value.view==="tree"){u.value[g].childrenOpen=!u.value[g].childrenOpen;for(let v=a.value.length-1;v>=0;v--)u.value[v].parent===g&&(u.value[v].open=!u.value[v].open,u.value[v].childrenOpen&&j(v))}else i.value.view==="list-expansion"&&(u.value[g].expanded=!u.value[g].expanded)},V=(g,v)=>{const b=h(g,v);return N(g,v,b)},N=(g,v,b)=>{const m=s.value[g],y=a.value[v],k=m.format;return k?typeof k=="function"?k(b,{table:l.value,row:y,column:m}):typeof k=="string"?Function(`"use strict";return (${k})`)()(b,{table:l.value,row:y,column:m}):b:b};return{columns:s,config:i,display:u,modal:c,rows:a,table:l,updates:d,hasPinnedColumns:f,numberedRowWidth:p,zeroColumn:w,closeModal:g=>{var v;g.target instanceof Node&&(v=c.value.parent)!=null&&v.contains(g.target)||c.value.visible&&(c.value.visible=!1)},getCellData:h,getCellDisplayValue:V,getFormattedValue:N,getHeaderCellStyle:S,getIndent:(g,v)=>v&&g===0&&v>0?`${v}ch`:"inherit",getRowExpandSymbol:I,isRowVisible:$,setCellData:_,setCellText:E,toggleRowExpand:j}})()},Qs=r.defineComponent({__name:"ATable",props:{id:{},modelValue:{},columns:{},rows:{default:()=>[]},config:{default:()=>new Object}},emits:["update:modelValue","cellUpdate"],setup(t,{expose:e,emit:n}){const o=n,s=r.useTemplateRef("table"),a=t.modelValue?t.modelValue:t.rows,i=qs({columns:t.columns,rows:a,id:t.id,config:t.config});i.$onAction(({name:c,store:d,args:f,after:p})=>{if(c==="setCellData"){const[w,h,_]=f,E=d.getCellData(w,h);p(()=>{o("cellUpdate",w,h,_,E)})}}),r.watch(()=>i.rows,c=>{o("update:modelValue",c)},{deep:!0}),r.onMounted(()=>{t.columns.some(c=>c.pinned)&&(u(),i.config.view==="tree"&&Dn(s,u,{childList:!0,subtree:!0}))});const l=(c,d,f,p)=>{o("cellUpdate",c,d,f,p)},u=()=>{const c=s.value,d=c==null?void 0:c.rows[0],f=c==null?void 0:c.rows[1],p=d?Array.from(d.cells):[];for(const[w,h]of p.entries()){const _=f==null?void 0:f.cells[w];_&&(h.style.width=`${_.offsetWidth}px`)}for(const w of(c==null?void 0:c.rows)||[]){let h=0;const _=[];for(const E of w.cells)(E.classList.contains("sticky-column")||E.classList.contains("sticky-index"))&&(E.style.left=`${h}px`,h+=E.offsetWidth,_.push(E));_.length>0&&_[_.length-1].classList.add("sticky-column-edge")}};return window.addEventListener("keydown",c=>{if(c.key==="Escape"&&i.modal.visible){i.modal.visible=!1;const d=i.modal.parent;d&&r.nextTick().then(()=>{d.focus()})}}),e({store:i}),(c,d)=>r.withDirectives((r.openBlock(),r.createElementBlock("table",{ref:"table",class:"atable",style:r.normalizeStyle({width:r.unref(i).config.fullWidth?"100%":"auto"})},[r.renderSlot(c.$slots,"header",{data:r.unref(i)},()=>[r.createVNode(Gs,{columns:r.unref(i).columns,store:r.unref(i)},null,8,["columns","store"])],!0),r.createElementVNode("tbody",null,[r.renderSlot(c.$slots,"body",{data:r.unref(i)},()=>[(r.openBlock(!0),r.createElementBlock(r.Fragment,null,r.renderList(r.unref(i).rows,(f,p)=>(r.openBlock(),r.createBlock(Ms,{key:f.id,row:f,rowIndex:p,store:r.unref(i)},{default:r.withCtx(()=>[(r.openBlock(!0),r.createElementBlock(r.Fragment,null,r.renderList(r.unref(i).columns,(w,h)=>(r.openBlock(),r.createBlock(Rs,{key:w.name,store:r.unref(i),col:w,spellcheck:"false",pinned:w.pinned,rowIndex:p,colIndex:h,component:w.cellComponent,style:r.normalizeStyle({textAlign:(w==null?void 0:w.align)||"center",minWidth:(w==null?void 0:w.width)||"40ch",width:r.unref(i).config.fullWidth?"auto":null}),onCellInput:l},null,8,["store","col","pinned","rowIndex","colIndex","component","style"]))),128))]),_:2},1032,["row","rowIndex","store"]))),128))],!0)]),r.renderSlot(c.$slots,"footer",{data:r.unref(i)},void 0,!0),r.renderSlot(c.$slots,"modal",{data:r.unref(i)},()=>[r.withDirectives(r.createVNode(Ys,{store:r.unref(i)},{default:r.withCtx(()=>[(r.openBlock(),r.createBlock(r.resolveDynamicComponent(r.unref(i).modal.component),r.mergeProps({key:`${r.unref(i).modal.rowIndex}:${r.unref(i).modal.colIndex}`,colIndex:r.unref(i).modal.colIndex,rowIndex:r.unref(i).modal.rowIndex,store:r.unref(i)},r.unref(i).modal.componentProps),null,16,["colIndex","rowIndex","store"]))]),_:1},8,["store"]),[[r.vShow,r.unref(i).modal.visible]])],!0)],4)),[[r.unref(Us),r.unref(i).closeModal]])}}),Xs=An(Qs,[["__scopeId","data-v-37bee2a6"]]),Mn=r.defineComponent({__name:"Records",setup(t){const{stonecrop:e,isReady:n}=Fe(),o={view:"list"};return(s,a)=>r.unref(n)?(r.openBlock(),r.createBlock(r.unref(Xs),{key:0,columns:r.unref(e).schema.schema.toArray(),rows:r.unref(e).store.records,config:o},null,8,["columns","rows"])):r.createCommentVNode("",!0)}}),Ks={class:"tabs"},Zs={tabindex:"0"},ta={version:"1.1",id:"Capa_1",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",x:"0px",y:"0px",viewBox:"0 0 424.098 424.098",style:{"enable-background":"new 0 0 424.098 424.098"},"xml:space":"preserve"},ea={tabindex:"0"},na={style:{width:"11pt"}},Un=Dt(r.defineComponent({__name:"SheetNav",props:{breadcrumbs:{default:()=>[]}},setup(t){const e=r.ref(!0),n=r.ref(!1),o=r.ref(""),s=r.useTemplateRef("searchinput"),a=r.computed(()=>e.value?"unrotated":"rotated"),i=()=>{e.value=!e.value},l=async()=>{n.value=!n.value,await r.nextTick(()=>{s.value.focus()})},u=f=>{f.preventDefault(),f.stopPropagation()},c=async f=>{f.preventDefault(),f.stopPropagation(),await l()},d=()=>{};return(f,p)=>{const w=r.resolveComponent("router-link");return r.openBlock(),r.createElementBlock("footer",null,[r.createElementVNode("ul",Ks,[r.createElementVNode("li",{class:"hidebreadcrumbs",onClick:i,onKeydown:r.withKeys(i,["enter"])},[r.createElementVNode("a",Zs,[r.createElementVNode("div",{class:r.normalizeClass(a.value)},"×",2)])],32),r.createElementVNode("li",{class:"hometab",onClick:d,onKeydown:r.withKeys(d,["enter"]),style:r.normalizeStyle({display:e.value?"block":"none"})},[r.createVNode(w,{to:"/home",tabindex:"0"},{default:r.withCtx(()=>[(r.openBlock(),r.createElementBlock("svg",ta,p[5]||(p[5]=[r.createElementVNode("g",null,[r.createElementVNode("path",{style:{fill:"#010002"},d:`M351.191,401.923H72.901c-4.487,0-8.129-3.633-8.129-8.129V242.262l-56.664-0.114
|
|
19
|
+
This will fail in production.`);i=je,i._s.has(e)||(r?Jt(e,t,o,i):br(e,o,i),process.env.NODE_ENV!=="production"&&(a._pinia=i));const u=i._s.get(e);if(process.env.NODE_ENV!=="production"&&l){const d="__hot:"+e,f=r?Jt(d,t,o,i,!0):br(d,W({},o),i,!0);l._hotUpdate(f),delete i.state.value[d],i._s.delete(d)}if(process.env.NODE_ENV!=="production"&&Me){const d=s.getCurrentInstance();if(d&&d.proxy&&!l){const f=d.proxy,p="_pStores"in f?f._pStores:f._pStores={};p[e]=u}}return u}return a.$id=e,a}function Xt(e){return s.getCurrentScope()?(s.onScopeDispose(e),!0):!1}const Ql=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const ec=e=>e!=null,tc=Object.prototype.toString,nc=e=>tc.call(e)==="[object Object]",oc=()=>{};function st(e){return Array.isArray(e)?e:[e]}function rc(e,t,n){return s.watch(e,t,{...n,immediate:!0})}const Oe=Ql?window:void 0;function Se(e){var t;const n=s.toValue(e);return(t=n==null?void 0:n.$el)!=null?t:n}function Be(...e){const t=[],n=()=>{t.forEach(l=>l()),t.length=0},o=(l,c,u,d)=>(l.addEventListener(c,u,d),()=>l.removeEventListener(c,u,d)),r=s.computed(()=>{const l=st(s.toValue(e[0])).filter(c=>c!=null);return l.every(c=>typeof c!="string")?l:void 0}),a=rc(()=>{var l,c;return[(c=(l=r.value)==null?void 0:l.map(u=>Se(u)))!=null?c:[Oe].filter(u=>u!=null),st(s.toValue(r.value?e[1]:e[0])),st(s.unref(r.value?e[2]:e[1])),s.toValue(r.value?e[3]:e[2])]},([l,c,u,d])=>{if(n(),!(l!=null&&l.length)||!(c!=null&&c.length)||!(u!=null&&u.length))return;const f=nc(d)?{...d}:d;t.push(...l.flatMap(p=>c.flatMap(m=>u.map(_=>o(p,m,_,f)))))},{flush:"post"}),i=()=>{a(),n()};return Xt(n),i}function sc(){const e=s.shallowRef(!1),t=s.getCurrentInstance();return t&&s.onMounted(()=>{e.value=!0},t),e}function ac(e){const t=sc();return s.computed(()=>(t.value,!!e()))}function ic(e,t,n={}){const{window:o=Oe,...r}=n;let a;const i=ac(()=>o&&"MutationObserver"in o),l=()=>{a&&(a.disconnect(),a=void 0)},c=s.computed(()=>{const p=s.toValue(e),m=st(p).map(Se).filter(ec);return new Set(m)}),u=s.watch(()=>c.value,p=>{l(),i.value&&p.size&&(a=new MutationObserver(t),p.forEach(m=>a.observe(m,r)))},{immediate:!0,flush:"post"}),d=()=>a==null?void 0:a.takeRecords(),f=()=>{u(),l()};return Xt(f),{isSupported:i,stop:f,takeRecords:d}}function lc(e,t,n={}){const{window:o=Oe,document:r=o==null?void 0:o.document,flush:a="sync"}=n;if(!o||!r)return oc;let i;const l=d=>{i==null||i(),i=d},c=s.watchEffect(()=>{const d=Se(e);if(d){const{stop:f}=ic(r,p=>{p.map(m=>[...m.removedNodes]).flat().some(m=>m===d||m.contains(d))&&t(p)},{window:o,childList:!0,subtree:!0});l(f)}},{flush:a}),u=()=>{c(),l()};return Xt(u),u}function cc(e={}){var t;const{window:n=Oe,deep:o=!0,triggerOnRemoval:r=!1}=e,a=(t=e.document)!=null?t:n==null?void 0:n.document,i=()=>{var u;let d=a==null?void 0:a.activeElement;if(o)for(;d!=null&&d.shadowRoot;)d=(u=d==null?void 0:d.shadowRoot)==null?void 0:u.activeElement;return d},l=s.ref(),c=()=>{l.value=i()};if(n){const u={capture:!0,passive:!0};Be(n,"blur",d=>{d.relatedTarget===null&&c()},u),Be(n,"focus",c,u)}return r&&lc(l,c,{document:a}),c(),l}const uc="focusin",dc="focusout",fc=":focus-within";function pc(e,t={}){const{window:n=Oe}=t,o=s.computed(()=>Se(e)),r=s.shallowRef(!1),a=s.computed(()=>r.value),i=cc(t);if(!n||!i.value)return{focused:a};const l={passive:!0};return Be(o,uc,()=>r.value=!0,l),Be(o,dc,()=>{var c,u,d;return r.value=(d=(u=(c=o.value)==null?void 0:c.matches)==null?void 0:u.call(c,fc))!=null?d:!1},l),{focused:a}}function mc(e,{window:t=Oe,scrollTarget:n}={}){const o=s.ref(!1),r=()=>{if(!t)return;const a=t.document,i=Se(e);if(!i)o.value=!1;else{const l=i.getBoundingClientRect();o.value=l.top<=(t.innerHeight||a.documentElement.clientHeight)&&l.left<=(t.innerWidth||a.documentElement.clientWidth)&&l.bottom>=0&&l.right>=0}};return s.watch(()=>Se(e),()=>r(),{immediate:!0,flush:"post"}),t&&Be(n||t,"scroll",r,{capture:!1,passive:!0}),o}const te=e=>{let t=mc(e).value;return t=t&&e.offsetHeight>0,t},ne=e=>e.tabIndex>=0,vr=e=>{const t=e.target;return Zt(t)},Zt=e=>{var t;let n;if(e instanceof HTMLTableCellElement){const o=(t=e.parentElement)==null?void 0:t.previousElementSibling;if(o){const r=Array.from(o.children)[e.cellIndex];r&&(n=r)}}else if(e instanceof HTMLTableRowElement){const o=e.previousElementSibling;o&&(n=o)}return n&&(!ne(n)||!te(n))?Zt(n):n},hc=e=>{var t;const n=e.target;let o;if(n instanceof HTMLTableCellElement){const r=(t=n.parentElement)==null?void 0:t.parentElement;if(r){const a=r.firstElementChild,i=a==null?void 0:a.children[n.cellIndex];i&&(o=i)}}else if(n instanceof HTMLTableRowElement){const r=n.parentElement;if(r){const a=r.firstElementChild;a&&(o=a)}}return o&&(!ne(o)||!te(o))?Qt(o):o},kr=e=>{const t=e.target;return Qt(t)},Qt=e=>{var t;let n;if(e instanceof HTMLTableCellElement){const o=(t=e.parentElement)==null?void 0:t.nextElementSibling;if(o){const r=Array.from(o.children)[e.cellIndex];r&&(n=r)}}else if(e instanceof HTMLTableRowElement){const o=e.nextElementSibling;o&&(n=o)}return n&&(!ne(n)||!te(n))?Qt(n):n},_c=e=>{var t;const n=e.target;let o;if(n instanceof HTMLTableCellElement){const r=(t=n.parentElement)==null?void 0:t.parentElement;if(r){const a=r.lastElementChild,i=a==null?void 0:a.children[n.cellIndex];i&&(o=i)}}else if(n instanceof HTMLTableRowElement){const r=n.parentElement;if(r){const a=r.lastElementChild;a&&(o=a)}}return o&&(!ne(o)||!te(o))?Zt(o):o},Or=e=>{const t=e.target;return en(t)},en=e=>{var t;let n;if(e.previousElementSibling)n=e.previousElementSibling;else{const o=(t=e.parentElement)==null?void 0:t.previousElementSibling;n=o==null?void 0:o.lastElementChild}return n&&(!ne(n)||!te(n))?en(n):n},Sr=e=>{const t=e.target;return tn(t)},tn=e=>{var t;let n;if(e.nextElementSibling)n=e.nextElementSibling;else{const o=(t=e.parentElement)==null?void 0:t.nextElementSibling;n=o==null?void 0:o.firstElementChild}return n&&(!ne(n)||!te(n))?tn(n):n},Tr=e=>{const t=e.target.parentElement,n=t==null?void 0:t.firstElementChild;return n&&(!ne(n)||!te(n))?tn(n):n},Ir=e=>{const t=e.target.parentElement,n=t==null?void 0:t.lastElementChild;return n&&(!ne(n)||!te(n))?en(n):n},at=["alt","control","shift","meta"],gc={ArrowUp:"up",ArrowDown:"down",ArrowLeft:"left",ArrowRight:"right"},nn={"keydown.up":e=>{const t=vr(e);t&&(e.preventDefault(),e.stopPropagation(),t.focus())},"keydown.down":e=>{const t=kr(e);t&&(e.preventDefault(),e.stopPropagation(),t.focus())},"keydown.left":e=>{const t=Or(e);e.preventDefault(),e.stopPropagation(),t&&t.focus()},"keydown.right":e=>{const t=Sr(e);e.preventDefault(),e.stopPropagation(),t&&t.focus()},"keydown.control.up":e=>{const t=hc(e);t&&(e.preventDefault(),e.stopPropagation(),t.focus())},"keydown.control.down":e=>{const t=_c(e);t&&(e.preventDefault(),e.stopPropagation(),t.focus())},"keydown.control.left":e=>{const t=Tr(e);t&&(e.preventDefault(),e.stopPropagation(),t.focus())},"keydown.control.right":e=>{const t=Ir(e);t&&(e.preventDefault(),e.stopPropagation(),t.focus())},"keydown.end":e=>{const t=Ir(e);t&&(e.preventDefault(),e.stopPropagation(),t.focus())},"keydown.enter":e=>{if(e.target instanceof HTMLTableCellElement){e.preventDefault(),e.stopPropagation();const t=kr(e);t&&t.focus()}},"keydown.shift.enter":e=>{if(e.target instanceof HTMLTableCellElement){e.preventDefault(),e.stopPropagation();const t=vr(e);t&&t.focus()}},"keydown.home":e=>{const t=Tr(e);t&&(e.preventDefault(),e.stopPropagation(),t.focus())},"keydown.tab":e=>{const t=Sr(e);t&&(e.preventDefault(),e.stopPropagation(),t.focus())},"keydown.shift.tab":e=>{const t=Or(e);t&&(e.preventDefault(),e.stopPropagation(),t.focus())}};function Vr(e){const t=i=>{let l=null;return i.parent&&(typeof i.parent=="string"?l=document.querySelector(i.parent):i.parent instanceof HTMLElement?l=i.parent:l=i.parent.value),l},n=i=>{var l;const c=t(i);let u=[];if(typeof i.selectors=="string")u=c?Array.from(c.querySelectorAll(i.selectors)):Array.from(document.querySelectorAll(i.selectors));else if(Array.isArray(i.selectors))for(const d of i.selectors)d instanceof HTMLElement?u.push(d):u.push(d.$el);else if(i.selectors instanceof HTMLElement)u.push(i.selectors);else if((l=i.selectors)!=null&&l.value)if(Array.isArray(i.selectors.value))for(const d of i.selectors.value)d instanceof HTMLElement?u.push(d):u.push(d.$el);else u.push(i.selectors.value);return u},o=i=>{const l=t(i);let c=[];return i.selectors?c=n(i):l&&(c=Array.from(l.children).filter(u=>ne(u)&&te(u))),c},r=i=>l=>{const c=gc[l.key]||l.key.toLowerCase();if(at.includes(c))return;const u=i.handlers||nn;for(const d of Object.keys(u)){const[f,...p]=d.split(".");if(f==="keydown"&&p.includes(c)){const m=u[d],_=p.filter(h=>at.includes(h)),b=at.some(h=>{const k=h.charAt(0).toUpperCase()+h.slice(1);return l.getModifierState(k)});if(_.length>0){if(b){for(const h of at)if(p.includes(h)){const k=h.charAt(0).toUpperCase()+h.slice(1);l.getModifierState(k)&&m(l)}}}else b||m(l)}}},a=[];s.onMounted(()=>{for(const i of e){const l=t(i),c=o(i),u=r(i),d=l?[l]:c;for(const f of d){const{focused:p}=pc(s.ref(f)),m=s.watch(p,_=>{_?f.addEventListener("keydown",u):f.removeEventListener("keydown",u)});a.push(m)}}}),s.onBeforeUnmount(()=>{for(const i of a)i()})}function He(e){return s.getCurrentScope()?(s.onScopeDispose(e),!0):!1}const on=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const yc=e=>e!=null,Ec=Object.prototype.toString,Cr=e=>Ec.call(e)==="[object Object]",fe=()=>{},rn=wc();function wc(){var e,t;return on&&((e=window==null?void 0:window.navigator)==null?void 0:e.userAgent)&&(/iP(?:ad|hone|od)/.test(window.navigator.userAgent)||((t=window==null?void 0:window.navigator)==null?void 0:t.maxTouchPoints)>2&&/iPad|Macintosh/.test(window==null?void 0:window.navigator.userAgent))}function bc(e){return s.getCurrentInstance()}function pe(e){return Array.isArray(e)?e:[e]}function vc(...e){if(e.length!==1)return s.toRef(...e);const t=e[0];return typeof t=="function"?s.readonly(s.customRef(()=>({get:t,set:fe}))):s.ref(t)}function kc(e,t=!0,n){bc()?s.onMounted(e,n):t?e():s.nextTick(e)}function Pr(e,t,n){return s.watch(e,t,{...n,immediate:!0})}const sn=on?window:void 0;function Te(e){var t;const n=s.toValue(e);return(t=n==null?void 0:n.$el)!=null?t:n}function Nr(...e){const t=[],n=()=>{t.forEach(l=>l()),t.length=0},o=(l,c,u,d)=>(l.addEventListener(c,u,d),()=>l.removeEventListener(c,u,d)),r=s.computed(()=>{const l=pe(s.toValue(e[0])).filter(c=>c!=null);return l.every(c=>typeof c!="string")?l:void 0}),a=Pr(()=>{var l,c;return[(c=(l=r.value)==null?void 0:l.map(u=>Te(u)))!=null?c:[sn].filter(u=>u!=null),pe(s.toValue(r.value?e[1]:e[0])),pe(s.unref(r.value?e[2]:e[1])),s.toValue(r.value?e[3]:e[2])]},([l,c,u,d])=>{if(n(),!(l!=null&&l.length)||!(c!=null&&c.length)||!(u!=null&&u.length))return;const f=Cr(d)?{...d}:d;t.push(...l.flatMap(p=>c.flatMap(m=>u.map(_=>o(p,m,_,f)))))},{flush:"post"}),i=()=>{a(),n()};return He(n),i}function Oc(){const e=s.shallowRef(!1),t=s.getCurrentInstance();return t&&s.onMounted(()=>{e.value=!0},t),e}function Dr(e){const t=Oc();return s.computed(()=>(t.value,!!e()))}function Rr(e,t,n={}){const{window:o=sn,...r}=n;let a;const i=Dr(()=>o&&"MutationObserver"in o),l=()=>{a&&(a.disconnect(),a=void 0)},c=s.computed(()=>{const p=s.toValue(e),m=pe(p).map(Te).filter(yc);return new Set(m)}),u=s.watch(()=>c.value,p=>{l(),i.value&&p.size&&(a=new MutationObserver(t),p.forEach(m=>a.observe(m,r)))},{immediate:!0,flush:"post"}),d=()=>a==null?void 0:a.takeRecords(),f=()=>{u(),l()};return He(f),{isSupported:i,stop:f,takeRecords:d}}function Sc(e,t,n={}){const{window:o=sn,...r}=n;let a;const i=Dr(()=>o&&"ResizeObserver"in o),l=()=>{a&&(a.disconnect(),a=void 0)},c=s.computed(()=>{const f=s.toValue(e);return Array.isArray(f)?f.map(p=>Te(p)):[Te(f)]}),u=s.watch(c,f=>{if(l(),i.value&&o){a=new ResizeObserver(t);for(const p of f)p&&a.observe(p,r)}},{immediate:!0,flush:"post"}),d=()=>{l(),u()};return He(d),{isSupported:i,stop:d}}function xr(e,t={}){const{reset:n=!0,windowResize:o=!0,windowScroll:r=!0,immediate:a=!0,updateTiming:i="sync"}=t,l=s.shallowRef(0),c=s.shallowRef(0),u=s.shallowRef(0),d=s.shallowRef(0),f=s.shallowRef(0),p=s.shallowRef(0),m=s.shallowRef(0),_=s.shallowRef(0);function b(){const k=Te(e);if(!k){n&&(l.value=0,c.value=0,u.value=0,d.value=0,f.value=0,p.value=0,m.value=0,_.value=0);return}const O=k.getBoundingClientRect();l.value=O.height,c.value=O.bottom,u.value=O.left,d.value=O.right,f.value=O.top,p.value=O.width,m.value=O.x,_.value=O.y}function h(){i==="sync"?b():i==="next-frame"&&requestAnimationFrame(()=>b())}return Sc(e,h),s.watch(()=>Te(e),k=>!k&&h()),Rr(e,h,{attributeFilter:["style","class"]}),r&&Nr("scroll",h,{capture:!0,passive:!0}),o&&Nr("resize",h,{passive:!0}),kc(()=>{a&&h()}),{height:l,bottom:c,left:u,right:d,top:f,width:p,x:m,y:_,update:h}}const Tc=e=>{const t=new DOMParser().parseFromString(e,"text/html");return Array.from(t.body.childNodes).some(n=>n.nodeType===1)},Ic=(e=8)=>Array.from({length:e},()=>Math.floor(Math.random()*16).toString(16)).join(""),Vc=["data-colindex","data-rowindex","data-editable","contenteditable","tabindex"],Cc=["innerHTML"],Pc={key:2},Nc=s.defineComponent({__name:"ACell",props:{colIndex:{},rowIndex:{},store:{},addNavigation:{type:[Boolean,Object],default:!0},tabIndex:{default:0},pinned:{type:Boolean,default:!1}},emits:["cellInput"],setup(e,{emit:t}){const n=t,o=s.useTemplateRef("cell"),r=e.store.getCellData(e.colIndex,e.rowIndex),a=s.ref(""),i=s.ref(!1),l=e.store.columns[e.colIndex],c=e.store.rows[e.rowIndex],u=l.align||"center",d=l.width||"40ch",f=s.computed(()=>e.store.getCellDisplayValue(e.colIndex,e.rowIndex)),p=s.computed(()=>typeof f.value=="string"?Tc(f.value):!1),m=s.computed(()=>{var O;return{textAlign:u,width:d,fontWeight:i.value?"bold":"inherit",paddingLeft:e.store.getIndent(e.colIndex,(O=e.store.display[e.rowIndex])==null?void 0:O.indent)}}),_=s.computed(()=>({"sticky-column":e.pinned,"cell-modified":i.value})),b=()=>{const{left:O,bottom:V,width:A,height:x}=xr(o);l.mask,l.modalComponent&&e.store.$patch(R=>{R.modal.visible=!0,R.modal.colIndex=e.colIndex,R.modal.rowIndex=e.rowIndex,R.modal.left=O,R.modal.bottom=V,R.modal.width=A,R.modal.height=x,R.modal.cell=o.value,typeof l.modalComponent=="function"?R.modal.component=l.modalComponent({table:R.table,row:c,column:l}):R.modal.component=l.modalComponent,R.modal.componentProps=l.modalComponentExtraProps})};if(e.addNavigation){let O={...nn,"keydown.f2":b,"keydown.alt.up":b,"keydown.alt.down":b,"keydown.alt.left":b,"keydown.alt.right":b};typeof e.addNavigation=="object"&&(O={...O,...e.addNavigation}),Vr([{selectors:o,handlers:O}])}const h=()=>{o.value&&(a.value=o.value.textContent)},k=O=>{const V=O.target;V.textContent!==a.value&&(n("cellInput",e.colIndex,e.rowIndex,V.textContent,a.value),a.value=V.textContent,l.format?(i.value=V.textContent!==e.store.getFormattedValue(e.colIndex,e.rowIndex,r),e.store.setCellText(e.colIndex,e.rowIndex,V.textContent)):(i.value=V.textContent!==r,e.store.setCellData(e.colIndex,e.rowIndex,V.textContent)))};return(O,V)=>(s.openBlock(),s.createElementBlock("td",{ref:"cell","data-colindex":O.colIndex,"data-rowindex":O.rowIndex,"data-editable":s.unref(l).edit,contenteditable:s.unref(l).edit,tabindex:O.tabIndex,spellcheck:!1,style:s.normalizeStyle(m.value),onFocus:h,onPaste:k,onInput:k,onClick:b,class:s.normalizeClass(["atable-cell",_.value])},[s.unref(l).cellComponent?(s.openBlock(),s.createBlock(s.resolveDynamicComponent(s.unref(l).cellComponent),s.mergeProps({key:0,value:f.value},s.unref(l).cellComponentProps),null,16,["value"])):p.value?(s.openBlock(),s.createElementBlock("span",{key:1,innerHTML:f.value},null,8,Cc)):(s.openBlock(),s.createElementBlock("span",Pc,s.toDisplayString(f.value),1))],46,Vc))}}),Ar=(e,t)=>{const n=e.__vccOpts||e;for(const[o,r]of t)n[o]=r;return n},Dc=["tabindex"],Rc=s.defineComponent({__name:"ARow",props:{rowIndex:{},store:{},tabIndex:{default:()=>-1},addNavigation:{type:[Boolean,Object],default:!1}},setup(e){const t=s.useTemplateRef("rowEl"),n=s.computed(()=>e.store.isRowVisible(e.rowIndex)),o=s.computed(()=>e.store.getRowExpandSymbol(e.rowIndex));if(e.addNavigation){let r=nn;typeof e.addNavigation=="object"&&(r={...r,...e.addNavigation}),Vr([{selectors:t,handlers:r}])}return(r,a)=>s.withDirectives((s.openBlock(),s.createElementBlock("tr",{ref:"rowEl",tabindex:r.tabIndex,class:"atable-row"},[r.store.config.view!=="uncounted"?s.renderSlot(r.$slots,"index",{key:0},()=>[r.store.config.view==="list"?(s.openBlock(),s.createElementBlock("td",{key:0,tabIndex:-1,class:s.normalizeClass(["list-index",r.store.hasPinnedColumns?"sticky-index":""])},s.toDisplayString(r.rowIndex+1),3)):r.store.config.view==="tree"?(s.openBlock(),s.createElementBlock("td",{key:1,tabIndex:-1,class:s.normalizeClass(["tree-index",r.store.hasPinnedColumns?"sticky-index":""]),onClick:a[0]||(a[0]=i=>r.store.toggleRowExpand(r.rowIndex))},s.toDisplayString(o.value),3)):s.createCommentVNode("",!0)],!0):s.createCommentVNode("",!0),s.renderSlot(r.$slots,"default",{},void 0,!0)],8,Dc)),[[s.vShow,n.value]])}}),xc=Ar(Rc,[["__scopeId","data-v-9c529d3d"]]),$r=on?window:void 0;function ze(e){var t;const n=s.toValue(e);return(t=n==null?void 0:n.$el)!=null?t:n}function Ie(...e){const t=[],n=()=>{t.forEach(l=>l()),t.length=0},o=(l,c,u,d)=>(l.addEventListener(c,u,d),()=>l.removeEventListener(c,u,d)),r=s.computed(()=>{const l=pe(s.toValue(e[0])).filter(c=>c!=null);return l.every(c=>typeof c!="string")?l:void 0}),a=Pr(()=>{var l,c;return[(c=(l=r.value)==null?void 0:l.map(u=>ze(u)))!=null?c:[$r].filter(u=>u!=null),pe(s.toValue(r.value?e[1]:e[0])),pe(s.unref(r.value?e[2]:e[1])),s.toValue(r.value?e[3]:e[2])]},([l,c,u,d])=>{if(n(),!(l!=null&&l.length)||!(c!=null&&c.length)||!(u!=null&&u.length))return;const f=Cr(d)?{...d}:d;t.push(...l.flatMap(p=>c.flatMap(m=>u.map(_=>o(p,m,_,f)))))},{flush:"post"}),i=()=>{a(),n()};return He(n),i}let Lr=!1;function jr(e,t,n={}){const{window:o=$r,ignore:r=[],capture:a=!0,detectIframe:i=!1,controls:l=!1}=n;if(!o)return l?{stop:fe,cancel:fe,trigger:fe}:fe;if(rn&&!Lr){Lr=!0;const h={passive:!0};Array.from(o.document.body.children).forEach(k=>Ie(k,"click",fe,h)),Ie(o.document.documentElement,"click",fe,h)}let c=!0;const u=h=>s.toValue(r).some(k=>{if(typeof k=="string")return Array.from(o.document.querySelectorAll(k)).some(O=>O===h.target||h.composedPath().includes(O));{const O=ze(k);return O&&(h.target===O||h.composedPath().includes(O))}});function d(h){const k=s.toValue(h);return k&&k.$.subTree.shapeFlag===16}function f(h,k){const O=s.toValue(h),V=O.$.subTree&&O.$.subTree.children;return V==null||!Array.isArray(V)?!1:V.some(A=>A.el===k.target||k.composedPath().includes(A.el))}const p=h=>{const k=ze(e);if(h.target!=null&&!(!(k instanceof Element)&&d(e)&&f(e,h))&&!(!k||k===h.target||h.composedPath().includes(k))){if("detail"in h&&h.detail===0&&(c=!u(h)),!c){c=!0;return}t(h)}};let m=!1;const _=[Ie(o,"click",h=>{m||(m=!0,setTimeout(()=>{m=!1},0),p(h))},{passive:!0,capture:a}),Ie(o,"pointerdown",h=>{const k=ze(e);c=!u(h)&&!!(k&&!h.composedPath().includes(k))},{passive:!0}),i&&Ie(o,"blur",h=>{setTimeout(()=>{var k;const O=ze(e);((k=o.document.activeElement)==null?void 0:k.tagName)==="IFRAME"&&!(O!=null&&O.contains(o.document.activeElement))&&t(h)},0)},{passive:!0})].filter(Boolean),b=()=>_.forEach(h=>h());return l?{stop:b,cancel:()=>{c=!1},trigger:h=>{c=!0,p(h),c=!1}}:b}const Ac={mounted(e,t){const n=!t.modifiers.bubble;if(typeof t.value=="function")e.__onClickOutside_stop=jr(e,t.value,{capture:n});else{const[o,r]=t.value;e.__onClickOutside_stop=jr(e,o,Object.assign({capture:n},r))}},unmounted(e){e.__onClickOutside_stop()}};function an(e){return typeof Window<"u"&&e instanceof Window?e.document.documentElement:typeof Document<"u"&&e instanceof Document?e.documentElement:e}function Ur(e){const t=window.getComputedStyle(e);if(t.overflowX==="scroll"||t.overflowY==="scroll"||t.overflowX==="auto"&&e.clientWidth<e.scrollWidth||t.overflowY==="auto"&&e.clientHeight<e.scrollHeight)return!0;{const n=e.parentNode;return!n||n.tagName==="BODY"?!1:Ur(n)}}function $c(e){const t=e||window.event,n=t.target;return Ur(n)?!1:t.touches.length>1?!0:(t.preventDefault&&t.preventDefault(),!1)}const ln=new WeakMap;function Lc(e,t=!1){const n=s.ref(t);let o=null,r="";s.watch(vc(e),l=>{const c=an(s.toValue(l));if(c){const u=c;if(ln.get(u)||ln.set(u,u.style.overflow),u.style.overflow!=="hidden"&&(r=u.style.overflow),u.style.overflow==="hidden")return n.value=!0;if(n.value)return u.style.overflow="hidden"}},{immediate:!0});const a=()=>{const l=an(s.toValue(e));!l||n.value||(rn&&(o=Ie(l,"touchmove",c=>{$c(c)},{passive:!1})),l.style.overflow="hidden",n.value=!0)},i=()=>{const l=an(s.toValue(e));!l||!n.value||(rn&&(o==null||o()),l.style.overflow=r,ln.delete(l),n.value=!1)};return He(i),s.computed({get(){return n.value},set(l){l?a():i()}})}function jc(){let e=!1;const t=s.shallowRef(!1);return(n,o)=>{if(t.value=o.value,e)return;e=!0;const r=Lc(n,o.value);s.watch(t,a=>r.value=a)}}jc();const Uc={key:0,id:"resizable"},Mc={class:"atable-header-row",tabindex:"-1"},Bc=s.defineComponent({__name:"ATableHeader",props:{columns:{},store:{}},setup(e){return(t,n)=>t.columns.length?(s.openBlock(),s.createElementBlock("thead",Uc,[s.createElementVNode("tr",Mc,[t.store.zeroColumn?(s.openBlock(),s.createElementBlock("th",{key:0,id:"header-index",class:s.normalizeClass([[t.store.hasPinnedColumns?"sticky-index":"",t.store.config.view==="tree"?"tree-index":"",t.store.config.view==="list-expansion"?"list-expansion-index":""],"list-index"])},null,2)):s.createCommentVNode("",!0),(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(t.columns,(o,r)=>(s.openBlock(),s.createElementBlock("th",{key:o.name,tabindex:"-1",style:s.normalizeStyle(t.store.getHeaderCellStyle(o)),class:s.normalizeClass(o.pinned?"sticky-column":"")},[s.renderSlot(t.$slots,"default",{},()=>[s.createTextVNode(s.toDisplayString(o.label||String.fromCharCode(r+97).toUpperCase()),1)])],6))),128))])])):s.createCommentVNode("",!0)}}),Hc=s.defineComponent({__name:"ATableModal",props:{store:{}},setup(e){const t=s.useTemplateRef("amodal"),{width:n,height:o}=xr(t),r=s.computed(()=>{var a,i,l,c;if(!(e.store.modal.height&&e.store.modal.width&&e.store.modal.left&&e.store.modal.bottom))return;const u=(a=e.store.modal.cell)==null?void 0:a.closest("table"),d=u.offsetHeight||0,f=u.offsetWidth||0;let p=((i=e.store.modal.cell)==null?void 0:i.offsetTop)||0;const m=((l=u.querySelector("thead"))==null?void 0:l.offsetHeight)||0;p+=m,p=p+o.value<d?p:p-(o.value+e.store.modal.height);let _=((c=e.store.modal.cell)==null?void 0:c.offsetLeft)||0;return _=_+n.value<=f?_:_-(n.value-e.store.modal.width),{left:`${_}px`,top:`${p}px`}});return(a,i)=>(s.openBlock(),s.createElementBlock("div",{class:"amodal",ref:"amodal",tabindex:"-1",onClick:i[0]||(i[0]=s.withModifiers(()=>{},["stop"])),onInput:i[1]||(i[1]=s.withModifiers(()=>{},["stop"])),style:s.normalizeStyle(r.value)},[s.renderSlot(a.$slots,"default")],36))}}),zc=e=>{const t=e.id||Ic();return Zl(`table-${t}`,()=>{const n=()=>{const y={};for(const[T,v]of r.value.entries())for(const[g,E]of a.value.entries())y[`${T}:${g}`]=E[v.name];return y},o=y=>{const T=[Object.assign({},{rowModified:!1})];if(y&&"0:0"in y)return y;const v=new Set;for(let g=a.value.length-1;g>=0;g--){const E=a.value[g];E.parent&&v.add(E.parent),T[g]={childrenOpen:!1,expanded:!1,indent:E.indent||0,isParent:v.has(g),isRoot:E.parent===null||E.parent===void 0,rowModified:!1,open:E.parent===null||E.parent===void 0,parent:E.parent}}return T},r=s.ref(e.columns),a=s.ref(e.rows),i=s.ref(e.config||{}),l=s.ref(e.table||n()),c=s.ref(o(e.display)),u=s.ref(e.modal||{visible:!1}),d=s.ref({}),f=s.computed(()=>r.value.some(y=>y.pinned)),p=s.computed(()=>`${Math.ceil(a.value.length/100+1)}ch`),m=s.computed(()=>i.value.view?["list","tree","list-expansion"].includes(i.value.view):!1),_=(y,T)=>l.value[`${y}:${T}`],b=(y,T,v)=>{const g=`${y}:${T}`,E=r.value[y];l.value[g]!==v&&(c.value[T].rowModified=!0),l.value[g]=v,a.value[T][E.name]=v},h=(y,T,v)=>{const g=`${y}:${T}`;l.value[g]!==v&&(c.value[T].rowModified=!0,d.value[g]=v)},k=y=>({minWidth:y.width||"40ch",textAlign:y.align||"center",width:i.value.fullWidth?"auto":void 0}),O=y=>i.value.view!=="tree"||c.value[y].isRoot||c.value[y].open,V=y=>i.value.view!=="tree"?"":c.value[y].isRoot||c.value[y].isParent?c.value[y].childrenOpen?"-":"+":"",A=y=>{if(i.value.view==="tree"){c.value[y].childrenOpen=!c.value[y].childrenOpen;for(let T=a.value.length-1;T>=0;T--)c.value[T].parent===y&&(c.value[T].open=!c.value[T].open,c.value[T].childrenOpen&&A(T))}else i.value.view==="list-expansion"&&(c.value[y].expanded=!c.value[y].expanded)},x=(y,T)=>{const v=_(y,T);return R(y,T,v)},R=(y,T,v)=>{const g=r.value[y],E=a.value[T],I=g.format;return I?typeof I=="function"?I(v,{table:l.value,row:E,column:g}):typeof I=="string"?Function(`"use strict";return (${I})`)()(v,{table:l.value,row:E,column:g}):v:v};return{columns:r,config:i,display:c,modal:u,rows:a,table:l,updates:d,hasPinnedColumns:f,numberedRowWidth:p,zeroColumn:m,closeModal:y=>{var T;y.target instanceof Node&&(T=u.value.parent)!=null&&T.contains(y.target)||u.value.visible&&(u.value.visible=!1)},getCellData:_,getCellDisplayValue:x,getFormattedValue:R,getHeaderCellStyle:k,getIndent:(y,T)=>T&&y===0&&T>0?`${T}ch`:"inherit",getRowExpandSymbol:V,isRowVisible:O,setCellData:b,setCellText:h,toggleRowExpand:A}})()},Kc=s.defineComponent({__name:"ATable",props:{id:{},modelValue:{},columns:{},rows:{default:()=>[]},config:{default:()=>new Object}},emits:["update:modelValue","cellUpdate"],setup(e,{expose:t,emit:n}){const o=n,r=s.useTemplateRef("table"),a=e.modelValue?e.modelValue:e.rows,i=zc({columns:e.columns,rows:a,id:e.id,config:e.config});i.$onAction(({name:u,store:d,args:f,after:p})=>{if(u==="setCellData"){const[m,_,b]=f,h=d.getCellData(m,_);p(()=>{o("cellUpdate",m,_,b,h)})}}),s.watch(()=>i.rows,u=>{o("update:modelValue",u)},{deep:!0}),s.onMounted(()=>{e.columns.some(u=>u.pinned)&&(c(),i.config.view==="tree"&&Rr(r,c,{childList:!0,subtree:!0}))});const l=(u,d,f,p)=>{o("cellUpdate",u,d,f,p)},c=()=>{const u=r.value,d=u==null?void 0:u.rows[0],f=u==null?void 0:u.rows[1],p=d?Array.from(d.cells):[];for(const[m,_]of p.entries()){const b=f==null?void 0:f.cells[m];b&&(_.style.width=`${b.offsetWidth}px`)}for(const m of(u==null?void 0:u.rows)||[]){let _=0;const b=[];for(const h of m.cells)(h.classList.contains("sticky-column")||h.classList.contains("sticky-index"))&&(h.style.left=`${_}px`,_+=h.offsetWidth,b.push(h));b.length>0&&b[b.length-1].classList.add("sticky-column-edge")}};return window.addEventListener("keydown",u=>{if(u.key==="Escape"&&i.modal.visible){i.modal.visible=!1;const d=i.modal.parent;d&&s.nextTick().then(()=>{d.focus()})}}),t({store:i}),(u,d)=>s.withDirectives((s.openBlock(),s.createElementBlock("table",{ref:"table",class:"atable",style:s.normalizeStyle({width:s.unref(i).config.fullWidth?"100%":"auto"})},[s.renderSlot(u.$slots,"header",{data:s.unref(i)},()=>[s.createVNode(Bc,{columns:s.unref(i).columns,store:s.unref(i)},null,8,["columns","store"])],!0),s.createElementVNode("tbody",null,[s.renderSlot(u.$slots,"body",{data:s.unref(i)},()=>[(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(s.unref(i).rows,(f,p)=>(s.openBlock(),s.createBlock(xc,{key:f.id,row:f,rowIndex:p,store:s.unref(i)},{default:s.withCtx(()=>[(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(s.unref(i).columns,(m,_)=>(s.openBlock(),s.createBlock(Nc,{key:m.name,store:s.unref(i),col:m,spellcheck:"false",pinned:m.pinned,rowIndex:p,colIndex:_,component:m.cellComponent,style:s.normalizeStyle({textAlign:(m==null?void 0:m.align)||"center",minWidth:(m==null?void 0:m.width)||"40ch",width:s.unref(i).config.fullWidth?"auto":null}),onCellInput:l},null,8,["store","col","pinned","rowIndex","colIndex","component","style"]))),128))]),_:2},1032,["row","rowIndex","store"]))),128))],!0)]),s.renderSlot(u.$slots,"footer",{data:s.unref(i)},void 0,!0),s.renderSlot(u.$slots,"modal",{data:s.unref(i)},()=>[s.withDirectives(s.createVNode(Hc,{store:s.unref(i)},{default:s.withCtx(()=>[(s.openBlock(),s.createBlock(s.resolveDynamicComponent(s.unref(i).modal.component),s.mergeProps({key:`${s.unref(i).modal.rowIndex}:${s.unref(i).modal.colIndex}`,colIndex:s.unref(i).modal.colIndex,rowIndex:s.unref(i).modal.rowIndex,store:s.unref(i)},s.unref(i).modal.componentProps),null,16,["colIndex","rowIndex","store"]))]),_:1},8,["store"]),[[s.vShow,s.unref(i).modal.visible]])],!0)],4)),[[s.unref(Ac),s.unref(i).closeModal]])}}),Fc=Ar(Kc,[["__scopeId","data-v-37bee2a6"]]),Mr=s.defineComponent({__name:"Records",setup(e){const{stonecrop:t,isReady:n}=Jo(),o={view:"list"};return(r,a)=>s.unref(n)?(s.openBlock(),s.createBlock(s.unref(Fc),{key:0,columns:s.unref(t).schema.schema.toArray(),rows:s.unref(t).store.records,config:o},null,8,["columns","rows"])):s.createCommentVNode("",!0)}}),Wc={class:"tabs"},Gc={tabindex:"0"},Yc={version:"1.1",id:"Capa_1",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",x:"0px",y:"0px",viewBox:"0 0 424.098 424.098",style:{"enable-background":"new 0 0 424.098 424.098"},"xml:space":"preserve"},qc={tabindex:"0"},Jc={style:{width:"11pt"}},Br=ct(s.defineComponent({__name:"SheetNav",props:{breadcrumbs:{default:()=>[]}},setup(e){const t=s.ref(!0),n=s.ref(!1),o=s.ref(""),r=s.useTemplateRef("searchinput"),a=s.computed(()=>t.value?"unrotated":"rotated"),i=()=>{t.value=!t.value},l=async()=>{n.value=!n.value,await s.nextTick(()=>{r.value.focus()})},c=f=>{f.preventDefault(),f.stopPropagation()},u=async f=>{f.preventDefault(),f.stopPropagation(),await l()},d=()=>{};return(f,p)=>{const m=s.resolveComponent("router-link");return s.openBlock(),s.createElementBlock("footer",null,[s.createElementVNode("ul",Wc,[s.createElementVNode("li",{class:"hidebreadcrumbs",onClick:i,onKeydown:s.withKeys(i,["enter"])},[s.createElementVNode("a",Gc,[s.createElementVNode("div",{class:s.normalizeClass(a.value)},"×",2)])],32),s.createElementVNode("li",{class:"hometab",onClick:d,onKeydown:s.withKeys(d,["enter"]),style:s.normalizeStyle({display:t.value?"block":"none"})},[s.createVNode(m,{to:"/home",tabindex:"0"},{default:s.withCtx(()=>[(s.openBlock(),s.createElementBlock("svg",Yc,p[5]||(p[5]=[s.createElementVNode("g",null,[s.createElementVNode("path",{style:{fill:"#010002"},d:`M351.191,401.923H72.901c-4.487,0-8.129-3.633-8.129-8.129V242.262l-56.664-0.114
|
|
21
20
|
c-3.284-0.008-6.243-1.992-7.495-5.023c-1.252-3.04-0.553-6.527,1.764-8.852L206.104,24.546c1.853-1.845,4.503-2.666,7.047-2.276
|
|
22
21
|
c2.414,0.39,4.511,1.845,5.731,3.942l47.43,47.43V58.499c0-4.487,3.633-8.129,8.129-8.129h47.755c4.495,0,8.129,3.642,8.129,8.129
|
|
23
22
|
v79.156l91.39,91.398c2.325,2.325,3.024,5.828,1.764,8.868c-1.26,3.032-4.227,5.007-7.511,5.007c-0.008,0-0.008,0-0.016,0
|
|
@@ -25,5 +24,5 @@ This will fail in production.`);l=ut,l._s.has(o)||(a?oe(o,e,s,l):En(o,s,l),proce
|
|
|
25
24
|
c0-2.162,0.854-4.235,2.39-5.755c1.528-1.52,3.585-2.374,5.739-2.374c0.008,0,0.008,0,0.016,0l45.105,0.089l-79.855-79.863
|
|
26
25
|
c-1.528-1.528-2.382-3.593-2.382-5.747V66.628h-31.498v26.645c0,3.284-1.975,6.251-5.015,7.511
|
|
27
26
|
c-3.032,1.268-6.527,0.569-8.86-1.764l-57.038-57.038l-183.95,183.95l45.203,0.089c4.487,0.008,8.112,3.642,8.112,8.129
|
|
28
|
-
C81.03,234.149,81.03,385.666,81.03,385.666z`})],-1)])))]),_:1})],36),
|
|
27
|
+
C81.03,234.149,81.03,385.666,81.03,385.666z`})],-1)])))]),_:1})],36),s.createElementVNode("li",{class:"searchtab",onClick:l,onKeydown:s.withKeys(l,["enter"]),style:s.normalizeStyle({display:t.value?"block":"none"})},[s.createElementVNode("a",qc,[s.createElementVNode("span",{style:s.normalizeStyle({display:n.value?"none":"block"})},[(s.openBlock(),s.createElementBlock("svg",Jc,p[6]||(p[6]=[s.createElementVNode("g",{transform:"matrix(-0.08088215,0,0,0.08088215,9.8016177,3.1263021e-6)"},[s.createElementVNode("path",{d:"M 93.148438,80.832031 C 109.5,57.742188 104.03125,25.769531 80.941406,9.421875 57.851562,-6.925781 25.878906,-1.460938 9.53125,21.632812 -6.816406,44.722656 -1.351562,76.691406 21.742188,93.039062 38.222656,104.70703 60.011719,105.60547 77.394531,95.339844 l 37.769529,37.542966 c 4.07813,4.29297 10.86328,4.46485 15.15625,0.38672 4.29297,-4.07422 4.46485,-10.85937 0.39063,-15.15234 -0.12891,-0.13672 -0.25391,-0.26172 -0.39063,-0.39063 z m -41.839844,3.5 C 33.0625,84.335938 18.269531,69.554688 18.257812,51.308594 18.253906,33.0625 33.035156,18.269531 51.285156,18.261719 c 18.222656,-0.0078 33.007813,14.75 33.042969,32.972656 0.03125,18.25 -14.742187,33.066406 -32.996094,33.097656 -0.0078,0 -0.01172,0 -0.02344,0 z m 0,0",style:{fill:"#000000","fill-opacity":"1","fill-rule":"nonzero",stroke:"none"},id:"path2"})],-1)])))],4),s.withDirectives(s.createElementVNode("input",{"onUpdate:modelValue":p[0]||(p[0]=_=>o.value=_),ref:"searchinput",style:s.normalizeStyle({display:n.value?"block":"none"}),onClick:p[1]||(p[1]=_=>c(_)),onInput:p[2]||(p[2]=_=>c(_)),onBlur:p[3]||(p[3]=_=>u(_)),onKeydown:p[4]||(p[4]=s.withKeys(_=>u(_),["enter"])),type:"text"},null,36),[[s.vModelText,o.value]])])],36),(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(f.breadcrumbs,_=>(s.openBlock(),s.createElementBlock("li",{key:_.title,style:s.normalizeStyle({display:t.value?"block":"none"})},[s.createVNode(m,{tabindex:"0",to:_.to},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(_.title),1)]),_:2},1032,["to"])],4))),128))])])}}}),[["__scopeId","data-v-a650f215"]]),Xc={install:e=>{e.component("ActionSet",un),e.component("CommandPalette",dn),e.component("Doctype",hr),e.component("Records",Mr),e.component("SheetNav",Br)}};K.ActionSet=un,K.CommandPalette=dn,K.Doctype=hr,K.Records=Mr,K.SheetNav=Br,K.StonecropDesktop=Xc,Object.defineProperty(K,Symbol.toStringTag,{value:"Module"})});
|
|
29
28
|
//# sourceMappingURL=desktop.umd.cjs.map
|