jplan-pack 0.6.783 → 0.6.785
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/{AuthRoute-CkMow6Lc.mjs → AuthRoute-CM4T-4Gf.mjs} +1 -1
- package/dist/{AuthRoute-DqVX_Rtv.js → AuthRoute-Cn52r32r.js} +1 -1
- package/dist/{WidgetLabel-7LzYMAgr.js → WidgetLabel-Bw9j6pzJ.js} +1 -1
- package/dist/{WidgetLabel-COuybmNh.mjs → WidgetLabel-Dpye5mbx.mjs} +1 -1
- package/dist/{WidgetShortcut-B5YowRpU.js → WidgetShortcut-Bs51Jvm4.js} +1 -1
- package/dist/{WidgetShortcut-CS-UGT4z.mjs → WidgetShortcut-DCZEqk78.mjs} +1 -1
- package/dist/{WidgetSpacer-J-D-4ndR.js → WidgetSpacer-C9hW1xHQ.js} +1 -1
- package/dist/{WidgetSpacer-C6aUpOCw.mjs → WidgetSpacer-CbepG2rz.mjs} +1 -1
- package/dist/{WidgetTask-D1ikc5BY.js → WidgetTask-BryId_NG.js} +1 -1
- package/dist/{WidgetTask-CQBJ0VMz.mjs → WidgetTask-Fn74GZ1T.mjs} +1 -1
- package/dist/index-7z8x6nRw.js +113 -0
- package/dist/{index-B8nu_x_B.mjs → index-D9CtH2Bz.mjs} +14900 -14346
- package/dist/index.css +2 -2
- package/dist/jplan-pack.cjs.js +1 -1
- package/dist/jplan-pack.es.js +61 -57
- package/dist/types/components/form/headless/TabFormHeader.d.ts +2 -2
- package/dist/types/components/index.d.ts +4 -1
- package/dist/types/components/table/UiTableFooter.d.ts +20 -0
- package/dist/types/components/table/virtual/ColumnSettingsFlashDialog.d.ts +11 -0
- package/dist/types/components/table/virtual/TableFlash.d.ts +74 -0
- package/dist/types/components/table/virtual/TableHeaderFlash.d.ts +41 -0
- package/dist/types/utils/helpers/Static.d.ts +11 -0
- package/dist/types/utils/helpers/withSpinner.d.ts +1 -0
- package/dist/types/utils/index.d.ts +3 -1
- package/package.json +1 -1
- package/dist/index-XceKD9kD.js +0 -113
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
"use strict";const s=require("vue"),hf=require("@vueuse/core"),Me=require("vuetify/lib/components/VBtn/index.mjs"),ho=require("vuetify/components"),_r=require("vuetify/lib/components/VIcon/index.mjs"),Ut=require("vuetify/lib/components/VCard/index.mjs"),rl=require("vuetify/lib/components/VDialog/index.mjs"),fo=require("vuetify/lib/components/VDivider/index.mjs"),xe=require("vuetify/lib/components/VGrid/index.mjs"),ky=require("vuetify/lib/components/VAvatar/index.mjs"),Bl=require("vuetify/lib/components/VImg/index.mjs"),Tt=require("vuetify/lib/components/VList/index.mjs"),Fl=require("vuetify/lib/components/VMenu/index.mjs"),ff=require("vuetify/lib/components/VDataTable/index.mjs"),PR=require("vuetify/lib/components/VTextField/index.mjs"),Ko=require("vuetify/lib/components/VSelect/index.mjs"),MR=require("vuetify/lib/components/VCheckbox/index.mjs"),DR=require("vuetify/lib/components/VChip/index.mjs"),Ei=require("vuetify/lib/components/VLabel/index.mjs"),LR=require("vuetify/lib/components/VAutocomplete/index.mjs"),xR=require("vuetify/lib/components/VTextarea/index.mjs"),UR=require("vuetify/lib/components/VBtnToggle/index.mjs");function VR(n){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(n){for(const t in n)if(t!=="default"){const r=Object.getOwnPropertyDescriptor(n,t);Object.defineProperty(e,t,r.get?r:{enumerable:!0,get:()=>n[t]})}}return e.default=n,Object.freeze(e)}const BR=VR(hf),FR={key:0},$R={key:1},Us=s.defineComponent({__name:"CopyButton",props:{contentToCopy:{},size:{},color:{}},setup(n){const e=n,{copy:t,copied:r,isSupported:o}=hf.useClipboard();return(a,l)=>{const d=s.resolveComponent("CopyIcon");return s.unref(o)?(s.openBlock(),s.createElementBlock("span",FR,[s.createVNode(Me.VBtn,{icon:"",variant:"text",onClick:l[0]||(l[0]=h=>s.unref(t)(e.contentToCopy)),size:a.size,color:a.color},{default:s.withCtx(()=>[s.createVNode(d,{size:a.size},null,8,["size"])]),_:1},8,["size","color"]),s.unref(r)?(s.openBlock(),s.createElementBlock("span",{key:0,style:s.normalizeStyle({fontSize:typeof e.size=="number"?e.size-4+"px":void 0}),class:"ms-1"}," Copied ",4)):s.createCommentVNode("",!0)])):(s.openBlock(),s.createElementBlock("p",$R,"Your browser does not support Clipboard API"))}}}),iv=s.defineComponent({__name:"IconSet",props:{item:{},level:{default:0},size:{default:25},stroke:{default:1.5},color:{},svg:{default:null}},setup(n){return(e,t)=>(s.openBlock(),s.createElementBlock(s.Fragment,null,[typeof e.item=="object"&&"name"in e.item?(s.openBlock(),s.createBlock(s.resolveDynamicComponent(e.item.name),{key:0,size:e.size,"stroke-width":e.stroke,color:e.color},null,8,["size","stroke-width","color"])):s.createCommentVNode("",!0),typeof e.item=="string"?(s.openBlock(),s.createBlock(_r.VIcon,{key:1,color:e.color,size:e.size},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(e.item),1)]),_:1},8,["color","size"])):s.createCommentVNode("",!0)],64))}}),Ny=s.defineComponent({__name:"JIconBtn",props:{variant:{default:"text"},icon:{},color:{default:"secondary"},tooltip:{},size:{}},emits:["click"],setup(n){const e=n,t=s.useSlots();return(r,o)=>r.tooltip?(s.openBlock(),s.createBlock(s.unref(ho.VTooltip),{key:0,text:r.tooltip,"open-delay":"1000"},{activator:s.withCtx(({props:a})=>[s.createVNode(s.unref(ho.VBtn),s.mergeProps(a,{variant:r.variant,color:r.color,icon:"",size:r.size,onClick:o[0]||(o[0]=l=>r.$emit("click"))}),{default:s.withCtx(()=>[!s.unref(t).default&&a.icon?(s.openBlock(),s.createBlock(iv,{key:0,item:a.icon,size:a.size},null,8,["item","size"])):s.createCommentVNode("",!0),s.renderSlot(r.$slots,"default")]),_:2},1040,["variant","color","size"])]),_:3},8,["text"])):(s.openBlock(),s.createBlock(s.unref(ho.VBtn),{key:1,variant:r.variant,color:r.color,icon:"",size:r.size,onClick:o[1]||(o[1]=a=>r.$emit("click"))},{default:s.withCtx(()=>[!s.unref(t).default&&e.icon?(s.openBlock(),s.createBlock(iv,{key:0,item:e.icon,size:e.size},null,8,["item","size"])):s.createCommentVNode("",!0),s.renderSlot(r.$slots,"default")]),_:3},8,["variant","color","size"]))}}),Oy=s.defineComponent({__name:"JBtn",props:{variant:{default:"flat"},text:{},icon:{},color:{default:"secondary"},tooltip:{}},emits:["click"],setup(n){return(e,t)=>(s.openBlock(),s.createBlock(s.unref(ho.VBtn),{"prepend-icon":e.icon,variant:e.variant,color:e.color,tooltip:e.tooltip,onClick:t[0]||(t[0]=r=>e.$emit("click"))},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(e.text)+" ",1),s.renderSlot(e.$slots,"default")]),_:3},8,["prepend-icon","variant","color","tooltip"]))}});function Uc(n,e,t){return Array.isArray(n)?(n.length=Math.max(n.length,e),n.splice(e,1,t),t):(n[e]=t,t)}function xd(n,e){if(Array.isArray(n)){n.splice(e,1);return}delete n[e]}function HR(){return Ry().__VUE_DEVTOOLS_GLOBAL_HOOK__}function Ry(){return typeof navigator<"u"&&typeof window<"u"?window:typeof globalThis<"u"?globalThis:{}}const KR=typeof Proxy=="function",WR="devtools-plugin:setup",zR="plugin:settings:set";let ji,wh;function GR(){var n;return ji!==void 0||(typeof window<"u"&&window.performance?(ji=!0,wh=window.performance):typeof globalThis<"u"&&(!((n=globalThis.perf_hooks)===null||n===void 0)&&n.performance)?(ji=!0,wh=globalThis.perf_hooks.performance):ji=!1),ji}function qR(){return GR()?wh.now():Date.now()}class jR{constructor(e,t){this.target=null,this.targetQueue=[],this.onQueue=[],this.plugin=e,this.hook=t;const r={};if(e.settings)for(const l in e.settings){const d=e.settings[l];r[l]=d.defaultValue}const o=`__vue-devtools-plugin-settings__${e.id}`;let a=Object.assign({},r);try{const l=localStorage.getItem(o),d=JSON.parse(l);Object.assign(a,d)}catch{}this.fallbacks={getSettings(){return a},setSettings(l){try{localStorage.setItem(o,JSON.stringify(l))}catch{}a=l},now(){return qR()}},t&&t.on(zR,(l,d)=>{l===this.plugin.id&&this.fallbacks.setSettings(d)}),this.proxiedOn=new Proxy({},{get:(l,d)=>this.target?this.target.on[d]:(...h)=>{this.onQueue.push({method:d,args:h})}}),this.proxiedTarget=new Proxy({},{get:(l,d)=>this.target?this.target[d]:d==="on"?this.proxiedOn:Object.keys(this.fallbacks).includes(d)?(...h)=>(this.targetQueue.push({method:d,args:h,resolve:()=>{}}),this.fallbacks[d](...h)):(...h)=>new Promise(f=>{this.targetQueue.push({method:d,args:h,resolve:f})})})}async setRealTarget(e){this.target=e;for(const t of this.onQueue)this.target.on[t.method](...t.args);for(const t of this.targetQueue)t.resolve(await this.target[t.method](...t.args))}}function mf(n,e){const t=n,r=Ry(),o=HR(),a=KR&&t.enableEarlyProxy;if(o&&(r.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__||!a))o.emit(WR,n,e);else{const l=a?new jR(t,o):null;(r.__VUE_DEVTOOLS_PLUGINS__=r.__VUE_DEVTOOLS_PLUGINS__||[]).push({pluginDescriptor:t,setupFn:e,proxy:l}),l&&e(l.proxiedTarget)}}/*!
|
|
2
|
+
* pinia v2.2.6
|
|
3
|
+
* (c) 2024 Eduardo San Martin Morote
|
|
4
|
+
* @license MIT
|
|
5
|
+
*/let us;const Ss=n=>us=n,Py=process.env.NODE_ENV!=="production"?Symbol("pinia"):Symbol();function Ta(n){return n&&typeof n=="object"&&Object.prototype.toString.call(n)==="[object Object]"&&typeof n.toJSON!="function"}var $r;(function(n){n.direct="direct",n.patchObject="patch object",n.patchFunction="patch function"})($r||($r={}));const gi=typeof window<"u",av=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 YR(n,{autoBom:e=!1}={}){return e&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(n.type)?new Blob(["\uFEFF",n],{type:n.type}):n}function gf(n,e,t){const r=new XMLHttpRequest;r.open("GET",n),r.responseType="blob",r.onload=function(){Ly(r.response,e,t)},r.onerror=function(){console.error("could not download file")},r.send()}function My(n){const e=new XMLHttpRequest;e.open("HEAD",n,!1);try{e.send()}catch{}return e.status>=200&&e.status<=299}function ol(n){try{n.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),n.dispatchEvent(t)}}const il=typeof navigator=="object"?navigator:{userAgent:""},Dy=/Macintosh/.test(il.userAgent)&&/AppleWebKit/.test(il.userAgent)&&!/Safari/.test(il.userAgent),Ly=gi?typeof HTMLAnchorElement<"u"&&"download"in HTMLAnchorElement.prototype&&!Dy?JR:"msSaveOrOpenBlob"in il?QR:XR:()=>{};function JR(n,e="download",t){const r=document.createElement("a");r.download=e,r.rel="noopener",typeof n=="string"?(r.href=n,r.origin!==location.origin?My(r.href)?gf(n,e,t):(r.target="_blank",ol(r)):ol(r)):(r.href=URL.createObjectURL(n),setTimeout(function(){URL.revokeObjectURL(r.href)},4e4),setTimeout(function(){ol(r)},0))}function QR(n,e="download",t){if(typeof n=="string")if(My(n))gf(n,e,t);else{const r=document.createElement("a");r.href=n,r.target="_blank",setTimeout(function(){ol(r)})}else navigator.msSaveOrOpenBlob(YR(n,t),e)}function XR(n,e,t,r){if(r=r||open("","_blank"),r&&(r.document.title=r.document.body.innerText="downloading..."),typeof n=="string")return gf(n,e,t);const o=n.type==="application/octet-stream",a=/constructor/i.test(String(av.HTMLElement))||"safari"in av,l=/CriOS\/[\d]+/.test(navigator.userAgent);if((l||o&&a||Dy)&&typeof FileReader<"u"){const d=new FileReader;d.onloadend=function(){let h=d.result;if(typeof h!="string")throw r=null,new Error("Wrong reader.result type");h=l?h:h.replace(/^data:[^;]*;/,"data:attachment/file;"),r?r.location.href=h:location.assign(h),r=null},d.readAsDataURL(n)}else{const d=URL.createObjectURL(n);r?r.location.assign(d):location.href=d,r=null,setTimeout(function(){URL.revokeObjectURL(d)},4e4)}}function Vt(n,e){const t="🍍 "+n;typeof __VUE_DEVTOOLS_TOAST__=="function"?__VUE_DEVTOOLS_TOAST__(t,e):e==="error"?console.error(t):e==="warn"?console.warn(t):console.log(t)}function pf(n){return"_a"in n&&"install"in n}function xy(){if(!("clipboard"in navigator))return Vt("Your browser doesn't support the Clipboard API","error"),!0}function Uy(n){return n instanceof Error&&n.message.toLowerCase().includes("document is not focused")?(Vt('You need to activate the "Emulate a focused page" setting in the "Rendering" panel of devtools.',"warn"),!0):!1}async function ZR(n){if(!xy())try{await navigator.clipboard.writeText(JSON.stringify(n.state.value)),Vt("Global state copied to clipboard.")}catch(e){if(Uy(e))return;Vt("Failed to serialize the state. Check the console for more details.","error"),console.error(e)}}async function e0(n){if(!xy())try{Vy(n,JSON.parse(await navigator.clipboard.readText())),Vt("Global state pasted from clipboard.")}catch(e){if(Uy(e))return;Vt("Failed to deserialize the state from clipboard. Check the console for more details.","error"),console.error(e)}}async function t0(n){try{Ly(new Blob([JSON.stringify(n.state.value)],{type:"text/plain;charset=utf-8"}),"pinia-state.json")}catch(e){Vt("Failed to export the state as JSON. Check the console for more details.","error"),console.error(e)}}let oo;function n0(){oo||(oo=document.createElement("input"),oo.type="file",oo.accept=".json");function n(){return new Promise((e,t)=>{oo.onchange=async()=>{const r=oo.files;if(!r)return e(null);const o=r.item(0);return e(o?{text:await o.text(),file:o}:null)},oo.oncancel=()=>e(null),oo.onerror=t,oo.click()})}return n}async function r0(n){try{const t=await n0()();if(!t)return;const{text:r,file:o}=t;Vy(n,JSON.parse(r)),Vt(`Global state imported from "${o.name}".`)}catch(e){Vt("Failed to import the state from JSON. Check the console for more details.","error"),console.error(e)}}function Vy(n,e){for(const t in e){const r=n.state.value[t];r?Object.assign(r,e[t]):n.state.value[t]=e[t]}}function gr(n){return{_custom:{display:n}}}const By="🍍 Pinia (root)",al="_root";function o0(n){return pf(n)?{id:al,label:By}:{id:n.$id,label:n.$id}}function i0(n){if(pf(n)){const t=Array.from(n._s.keys()),r=n._s;return{state:t.map(a=>({editable:!0,key:a,value:n.state.value[a]})),getters:t.filter(a=>r.get(a)._getters).map(a=>{const l=r.get(a);return{editable:!1,key:a,value:l._getters.reduce((d,h)=>(d[h]=l[h],d),{})}})}}const e={state:Object.keys(n.$state).map(t=>({editable:!0,key:t,value:n.$state[t]}))};return n._getters&&n._getters.length&&(e.getters=n._getters.map(t=>({editable:!1,key:t,value:n[t]}))),n._customProperties.size&&(e.customProperties=Array.from(n._customProperties).map(t=>({editable:!0,key:t,value:n[t]}))),e}function a0(n){return n?Array.isArray(n)?n.reduce((e,t)=>(e.keys.push(t.key),e.operations.push(t.type),e.oldValue[t.key]=t.oldValue,e.newValue[t.key]=t.newValue,e),{oldValue:{},keys:[],operations:[],newValue:{}}):{operation:gr(n.type),key:gr(n.key),oldValue:n.oldValue,newValue:n.newValue}:{}}function s0(n){switch(n){case $r.direct:return"mutation";case $r.patchFunction:return"$patch";case $r.patchObject:return"$patch";default:return"unknown"}}let ga=!0;const sl=[],hi="pinia:mutations",Zt="pinia",{assign:c0}=Object,yl=n=>"🍍 "+n;function l0(n,e){mf({id:"dev.esm.pinia",label:"Pinia 🍍",logo:"https://pinia.vuejs.org/logo.svg",packageName:"pinia",homepage:"https://pinia.vuejs.org",componentStateTypes:sl,app:n},t=>{typeof t.now!="function"&&Vt("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."),t.addTimelineLayer({id:hi,label:"Pinia 🍍",color:15064968}),t.addInspector({id:Zt,label:"Pinia 🍍",icon:"storage",treeFilterPlaceholder:"Search stores",actions:[{icon:"content_copy",action:()=>{ZR(e)},tooltip:"Serialize and copy the state"},{icon:"content_paste",action:async()=>{await e0(e),t.sendInspectorTree(Zt),t.sendInspectorState(Zt)},tooltip:"Replace the state with the content of your clipboard"},{icon:"save",action:()=>{t0(e)},tooltip:"Save the state as a JSON file"},{icon:"folder_open",action:async()=>{await r0(e),t.sendInspectorTree(Zt),t.sendInspectorState(Zt)},tooltip:"Import the state from a JSON file"}],nodeActions:[{icon:"restore",tooltip:'Reset the state (with "$reset")',action:r=>{const o=e._s.get(r);o?typeof o.$reset!="function"?Vt(`Cannot reset "${r}" store because it doesn't have a "$reset" method implemented.`,"warn"):(o.$reset(),Vt(`Store "${r}" reset.`)):Vt(`Cannot reset "${r}" store because it wasn't found.`,"warn")}}]}),t.on.inspectComponent((r,o)=>{const a=r.componentInstance&&r.componentInstance.proxy;if(a&&a._pStores){const l=r.componentInstance.proxy._pStores;Object.values(l).forEach(d=>{r.instanceData.state.push({type:yl(d.$id),key:"state",editable:!0,value:d._isOptionsAPI?{_custom:{value:s.toRaw(d.$state),actions:[{icon:"restore",tooltip:"Reset the state of this store",action:()=>d.$reset()}]}}:Object.keys(d.$state).reduce((h,f)=>(h[f]=d.$state[f],h),{})}),d._getters&&d._getters.length&&r.instanceData.state.push({type:yl(d.$id),key:"getters",editable:!1,value:d._getters.reduce((h,f)=>{try{h[f]=d[f]}catch(g){h[f]=g}return h},{})})})}}),t.on.getInspectorTree(r=>{if(r.app===n&&r.inspectorId===Zt){let o=[e];o=o.concat(Array.from(e._s.values())),r.rootNodes=(r.filter?o.filter(a=>"$id"in a?a.$id.toLowerCase().includes(r.filter.toLowerCase()):By.toLowerCase().includes(r.filter.toLowerCase())):o).map(o0)}}),globalThis.$pinia=e,t.on.getInspectorState(r=>{if(r.app===n&&r.inspectorId===Zt){const o=r.nodeId===al?e:e._s.get(r.nodeId);if(!o)return;o&&(r.nodeId!==al&&(globalThis.$store=s.toRaw(o)),r.state=i0(o))}}),t.on.editInspectorState((r,o)=>{if(r.app===n&&r.inspectorId===Zt){const a=r.nodeId===al?e:e._s.get(r.nodeId);if(!a)return Vt(`store "${r.nodeId}" not found`,"error");const{path:l}=r;pf(a)?l.unshift("state"):(l.length!==1||!a._customProperties.has(l[0])||l[0]in a.$state)&&l.unshift("$state"),ga=!1,r.set(a,l,r.state.value),ga=!0}}),t.on.editComponentState(r=>{if(r.type.startsWith("🍍")){const o=r.type.replace(/^🍍\s*/,""),a=e._s.get(o);if(!a)return Vt(`store "${o}" not found`,"error");const{path:l}=r;if(l[0]!=="state")return Vt(`Invalid path for store "${o}":
|
|
6
|
+
${l}
|
|
7
|
+
Only state can be modified.`);l[0]="$state",ga=!1,r.set(a,l,r.state.value),ga=!0}})})}function u0(n,e){sl.includes(yl(e.$id))||sl.push(yl(e.$id)),mf({id:"dev.esm.pinia",label:"Pinia 🍍",logo:"https://pinia.vuejs.org/logo.svg",packageName:"pinia",homepage:"https://pinia.vuejs.org",componentStateTypes:sl,app:n,settings:{logStoreChanges:{label:"Notify about new/deleted stores",type:"boolean",defaultValue:!0}}},t=>{const r=typeof t.now=="function"?t.now.bind(t):Date.now;e.$onAction(({after:l,onError:d,name:h,args:f})=>{const g=Fy++;t.addTimelineEvent({layerId:hi,event:{time:r(),title:"🛫 "+h,subtitle:"start",data:{store:gr(e.$id),action:gr(h),args:f},groupId:g}}),l(v=>{$o=void 0,t.addTimelineEvent({layerId:hi,event:{time:r(),title:"🛬 "+h,subtitle:"end",data:{store:gr(e.$id),action:gr(h),args:f,result:v},groupId:g}})}),d(v=>{$o=void 0,t.addTimelineEvent({layerId:hi,event:{time:r(),logType:"error",title:"💥 "+h,subtitle:"end",data:{store:gr(e.$id),action:gr(h),args:f,error:v},groupId:g}})})},!0),e._customProperties.forEach(l=>{s.watch(()=>s.unref(e[l]),(d,h)=>{t.notifyComponentUpdate(),t.sendInspectorState(Zt),ga&&t.addTimelineEvent({layerId:hi,event:{time:r(),title:"Change",subtitle:l,data:{newValue:d,oldValue:h},groupId:$o}})},{deep:!0})}),e.$subscribe(({events:l,type:d},h)=>{if(t.notifyComponentUpdate(),t.sendInspectorState(Zt),!ga)return;const f={time:r(),title:s0(d),data:c0({store:gr(e.$id)},a0(l)),groupId:$o};d===$r.patchFunction?f.subtitle="⤵️":d===$r.patchObject?f.subtitle="🧩":l&&!Array.isArray(l)&&(f.subtitle=l.type),l&&(f.data["rawEvent(s)"]={_custom:{display:"DebuggerEvent",type:"object",tooltip:"raw DebuggerEvent[]",value:l}}),t.addTimelineEvent({layerId:hi,event:f})},{detached:!0,flush:"sync"});const o=e._hotUpdate;e._hotUpdate=s.markRaw(l=>{o(l),t.addTimelineEvent({layerId:hi,event:{time:r(),title:"🔥 "+e.$id,subtitle:"HMR update",data:{store:gr(e.$id),info:gr("HMR update")}}}),t.notifyComponentUpdate(),t.sendInspectorTree(Zt),t.sendInspectorState(Zt)});const{$dispose:a}=e;e.$dispose=()=>{a(),t.notifyComponentUpdate(),t.sendInspectorTree(Zt),t.sendInspectorState(Zt),t.getSettings().logStoreChanges&&Vt(`Disposed "${e.$id}" store 🗑`)},t.notifyComponentUpdate(),t.sendInspectorTree(Zt),t.sendInspectorState(Zt),t.getSettings().logStoreChanges&&Vt(`"${e.$id}" store installed 🆕`)})}let Fy=0,$o;function sv(n,e,t){const r=e.reduce((o,a)=>(o[a]=s.toRaw(n)[a],o),{});for(const o in r)n[o]=function(){const a=Fy,l=t?new Proxy(n,{get(...h){return $o=a,Reflect.get(...h)},set(...h){return $o=a,Reflect.set(...h)}}):n;$o=a;const d=r[o].apply(l,arguments);return $o=void 0,d}}function d0({app:n,store:e,options:t}){if(!e.$id.startsWith("__hot:")){if(e._isOptionsAPI=!!t.state,!e._p._testing){sv(e,Object.keys(t.actions),e._isOptionsAPI);const r=e._hotUpdate;s.toRaw(e)._hotUpdate=function(o){r.apply(this,arguments),sv(e,Object.keys(o._hmrPayload.actions),!!e._isOptionsAPI)}}u0(n,e)}}function h0(){const n=s.effectScope(!0),e=n.run(()=>s.ref({}));let t=[],r=[];const o=s.markRaw({install(a){Ss(o),o._a=a,a.provide(Py,o),a.config.globalProperties.$pinia=o,process.env.NODE_ENV!=="production"&&process.env.NODE_ENV!=="test"&&gi&&l0(a,o),r.forEach(l=>t.push(l)),r=[]},use(a){return this._a?t.push(a):r.push(a),this},_p:t,_a:null,_e:n,_s:new Map,state:e});return process.env.NODE_ENV!=="production"&&process.env.NODE_ENV!=="test"&&typeof Proxy<"u"&&o.use(d0),o}function $y(n,e){for(const t in e){const r=e[t];if(!(t in n))continue;const o=n[t];Ta(o)&&Ta(r)&&!s.isRef(r)&&!s.isReactive(r)?n[t]=$y(o,r):n[t]=r}return n}const f0=()=>{};function cv(n,e,t,r=f0){n.push(e);const o=()=>{const a=n.indexOf(e);a>-1&&(n.splice(a,1),r())};return!t&&s.getCurrentScope()&&s.onScopeDispose(o),o}function Yi(n,...e){n.slice().forEach(t=>{t(...e)})}const m0=n=>n(),lv=Symbol(),Ud=Symbol();function Hy(n,e){n instanceof Map&&e instanceof Map?e.forEach((t,r)=>n.set(r,t)):n instanceof Set&&e instanceof Set&&e.forEach(n.add,n);for(const t in e){if(!e.hasOwnProperty(t))continue;const r=e[t],o=n[t];Ta(o)&&Ta(r)&&n.hasOwnProperty(t)&&!s.isRef(r)&&!s.isReactive(r)?n[t]=Hy(o,r):n[t]=r}return n}process.env.NODE_ENV!=="production"?Symbol("pinia:skipHydration"):Symbol();const{assign:tr}=Object;function uv(n){return!!(s.isRef(n)&&n.effect)}function dv(n,e,t,r){const{state:o,actions:a,getters:l}=e,d=t.state.value[n];let h;function f(){!d&&(process.env.NODE_ENV==="production"||!r)&&(t.state.value[n]=o?o():{});const g=process.env.NODE_ENV!=="production"&&r?s.toRefs(s.ref(o?o():{}).value):s.toRefs(t.state.value[n]);return tr(g,a,Object.keys(l||{}).reduce((v,p)=>(process.env.NODE_ENV!=="production"&&p in g&&console.warn(`[🍍]: A getter cannot have the same name as another state property. Rename one of them. Found with "${p}" in store "${n}".`),v[p]=s.markRaw(s.computed(()=>{Ss(t);const w=t._s.get(n);return l[p].call(w,w)})),v),{}))}return h=g0(n,f,e,t,r,!0),h}function g0(n,e,t={},r,o,a){let l;const d=tr({actions:{}},t);if(process.env.NODE_ENV!=="production"&&!r._e.active)throw new Error("Pinia destroyed");const h={deep:!0};process.env.NODE_ENV!=="production"&&(h.onTrigger=X=>{f?w=X:f==!1&&!R._hotUpdating&&(Array.isArray(w)?w.push(X):console.error("🍍 debuggerEvents should be an array. This is most likely an internal Pinia bug."))});let f,g,v=[],p=[],w;const C=r.state.value[n],T=s.ref({});let S;function I(X){let ee;f=g=!1,process.env.NODE_ENV!=="production"&&(w=[]),typeof X=="function"?(X(r.state.value[n]),ee={type:$r.patchFunction,storeId:n,events:w}):(Hy(r.state.value[n],X),ee={type:$r.patchObject,payload:X,storeId:n,events:w});const de=S=Symbol();s.nextTick().then(()=>{S===de&&(f=!0)}),g=!0,Yi(v,ee,r.state.value[n])}const N=function(){const{state:ee}=t,de=ee?ee():{};this.$patch(Fe=>{tr(Fe,de)})};function D(){l.stop(),v=[],p=[],r._s.delete(n)}const L=(X,ee="")=>{if(lv in X)return X[Ud]=ee,X;const de=function(){Ss(r);const Fe=Array.from(arguments),Ct=[],on=[];function jt(Et){Ct.push(Et)}function Dt(Et){on.push(Et)}Yi(p,{args:Fe,name:de[Ud],store:R,after:jt,onError:Dt});let at;try{at=X.apply(this&&this.$id===n?this:R,Fe)}catch(Et){throw Yi(on,Et),Et}return at instanceof Promise?at.then(Et=>(Yi(Ct,Et),Et)).catch(Et=>(Yi(on,Et),Promise.reject(Et))):(Yi(Ct,at),at)};return de[lv]=!0,de[Ud]=ee,de},U=s.markRaw({actions:{},getters:{},state:[],hotState:T}),F={_p:r,$id:n,$onAction:cv.bind(null,p),$patch:I,$reset:N,$subscribe(X,ee={}){const de=cv(v,X,ee.detached,()=>Fe()),Fe=l.run(()=>s.watch(()=>r.state.value[n],Ct=>{(ee.flush==="sync"?g:f)&&X({storeId:n,type:$r.direct,events:w},Ct)},tr({},h,ee)));return de},$dispose:D},R=s.reactive(process.env.NODE_ENV!=="production"||process.env.NODE_ENV!=="production"&&process.env.NODE_ENV!=="test"&&gi?tr({_hmrPayload:U,_customProperties:s.markRaw(new Set)},F):F);r._s.set(n,R);const se=(r._a&&r._a.runWithContext||m0)(()=>r._e.run(()=>(l=s.effectScope()).run(()=>e({action:L}))));for(const X in se){const ee=se[X];if(s.isRef(ee)&&!uv(ee)||s.isReactive(ee))process.env.NODE_ENV!=="production"&&o&&Uc(T.value,X,s.toRef(se,X)),process.env.NODE_ENV!=="production"&&U.state.push(X);else if(typeof ee=="function"){const de=process.env.NODE_ENV!=="production"&&o?ee:L(ee,X);se[X]=de,process.env.NODE_ENV!=="production"&&(U.actions[X]=ee),d.actions[X]=ee}else process.env.NODE_ENV!=="production"&&uv(ee)&&(U.getters[X]=t.getters[X],gi&&(se._getters||(se._getters=s.markRaw([]))).push(X))}if(tr(R,se),tr(s.toRaw(R),se),Object.defineProperty(R,"$state",{get:()=>process.env.NODE_ENV!=="production"&&o?T.value:r.state.value[n],set:X=>{if(process.env.NODE_ENV!=="production"&&o)throw new Error("cannot set hotState");I(ee=>{tr(ee,X)})}}),process.env.NODE_ENV!=="production"&&(R._hotUpdate=s.markRaw(X=>{R._hotUpdating=!0,X._hmrPayload.state.forEach(ee=>{if(ee in R.$state){const de=X.$state[ee],Fe=R.$state[ee];typeof de=="object"&&Ta(de)&&Ta(Fe)?$y(de,Fe):X.$state[ee]=Fe}Uc(R,ee,s.toRef(X.$state,ee))}),Object.keys(R.$state).forEach(ee=>{ee in X.$state||xd(R,ee)}),f=!1,g=!1,r.state.value[n]=s.toRef(X._hmrPayload,"hotState"),g=!0,s.nextTick().then(()=>{f=!0});for(const ee in X._hmrPayload.actions){const de=X[ee];Uc(R,ee,L(de,ee))}for(const ee in X._hmrPayload.getters){const de=X._hmrPayload.getters[ee],Fe=s.computed(()=>(Ss(r),de.call(R,R)));Uc(R,ee,Fe)}Object.keys(R._hmrPayload.getters).forEach(ee=>{ee in X._hmrPayload.getters||xd(R,ee)}),Object.keys(R._hmrPayload.actions).forEach(ee=>{ee in X._hmrPayload.actions||xd(R,ee)}),R._hmrPayload=X._hmrPayload,R._getters=X._getters,R._hotUpdating=!1})),process.env.NODE_ENV!=="production"&&process.env.NODE_ENV!=="test"&&gi){const X={writable:!0,configurable:!0,enumerable:!1};["_p","_hmrPayload","_getters","_customProperties"].forEach(ee=>{Object.defineProperty(R,ee,tr({value:R[ee]},X))})}return r._p.forEach(X=>{if(process.env.NODE_ENV!=="production"&&process.env.NODE_ENV!=="test"&&gi){const ee=l.run(()=>X({store:R,app:r._a,pinia:r,options:d}));Object.keys(ee||{}).forEach(de=>R._customProperties.add(de)),tr(R,ee)}else tr(R,l.run(()=>X({store:R,app:r._a,pinia:r,options:d})))}),process.env.NODE_ENV!=="production"&&R.$state&&typeof R.$state=="object"&&typeof R.$state.constructor=="function"&&!R.$state.constructor.toString().includes("[native code]")&&console.warn(`[🍍]: The "state" must be a plain object. It cannot be
|
|
8
|
+
state: () => new MyClass()
|
|
9
|
+
Found in store "${R.$id}".`),C&&a&&t.hydrate&&t.hydrate(R.$state,C),f=!0,g=!0,R}/*! #__NO_SIDE_EFFECTS__ */function p0(n,e,t){let r,o;if(typeof n=="string")r=n,o=e;else if(o=n,r=n.id,process.env.NODE_ENV!=="production"&&typeof r!="string")throw new Error('[🍍]: "defineStore()" must be passed a store id as its first argument.');function a(l,d){const h=s.hasInjectionContext();if(l=(process.env.NODE_ENV==="test"&&us&&us._testing?null:l)||(h?s.inject(Py,null):null),l&&Ss(l),process.env.NODE_ENV!=="production"&&!us)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
|
+
See https://pinia.vuejs.org/core-concepts/outside-component-usage.html for help.
|
|
11
|
+
This will fail in production.`);l=us,l._s.has(r)||(dv(r,o,l),process.env.NODE_ENV!=="production"&&(a._pinia=l));const f=l._s.get(r);if(process.env.NODE_ENV!=="production"&&d){const g="__hot:"+r,v=dv(g,tr({},o),l,!0);d._hotUpdate(v),delete l.state.value[g],l._s.delete(g)}if(process.env.NODE_ENV!=="production"&&gi){const g=s.getCurrentInstance();if(g&&g.proxy&&!d){const v=g.proxy,p="_pStores"in v?v._pStores:v._pStores={};p[r]=f}}return f}return a.$id=r,a}const v0=p0({id:"customizer",state:()=>({Sidebar_drawer:!0,Customizer_drawer:!1,mini_sidebar:!1,setHorizontalLayout:!1,actTheme:"DarkJPLANTheme",fontTheme:"Roboto",inputBg:!1,boxed:!1}),getters:{},actions:{SET_SIDEBAR_DRAWER(){this.Sidebar_drawer=!this.Sidebar_drawer},SET_MINI_SIDEBAR(n){this.mini_sidebar=n},SET_CUSTOMIZER_DRAWER(n){this.Customizer_drawer=n},SET_LAYOUT(n){this.setHorizontalLayout=n},SET_THEME(n){this.actTheme=n},SET_FONT(n){this.fontTheme=n}}}),Ji=s.ref({}),Ra=n=>{const e=s.computed(()=>n?Ji.value[n]||!1:Ji.value.default||!1),t=()=>{n?Ji.value[n]=!0:Ji.value.default=!0},r=()=>{n?Ji.value[n]=!1:Ji.value.default=!1};return s.onUnmounted(()=>{r()}),s.onMounted(()=>{r()}),{isDialogActive:e,openDialog:t,closeDialog:r}};var _0=Object.defineProperty,hv=Object.getOwnPropertySymbols,y0=Object.prototype.hasOwnProperty,C0=Object.prototype.propertyIsEnumerable,fv=(n,e,t)=>e in n?_0(n,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):n[e]=t,Ky=(n,e)=>{for(var t in e||(e={}))y0.call(e,t)&&fv(n,t,e[t]);if(hv)for(var t of hv(e))C0.call(e,t)&&fv(n,t,e[t]);return n},$l=n=>typeof n=="function",Hl=n=>typeof n=="string",Wy=n=>Hl(n)&&n.trim().length>0,E0=n=>typeof n=="number",pi=n=>typeof n>"u",Is=n=>typeof n=="object"&&n!==null,w0=n=>Hr(n,"tag")&&Wy(n.tag),zy=n=>window.TouchEvent&&n instanceof TouchEvent,Gy=n=>Hr(n,"component")&&qy(n.component),T0=n=>$l(n)||Is(n),qy=n=>!pi(n)&&(Hl(n)||T0(n)||Gy(n)),mv=n=>Is(n)&&["height","width","right","left","top","bottom"].every(e=>E0(n[e])),Hr=(n,e)=>(Is(n)||$l(n))&&e in n,b0=(n=>()=>n++)(0);function Vd(n){return zy(n)?n.targetTouches[0].clientX:n.clientX}function gv(n){return zy(n)?n.targetTouches[0].clientY:n.clientY}var S0=n=>{pi(n.remove)?n.parentNode&&n.parentNode.removeChild(n):n.remove()},Vs=n=>Gy(n)?Vs(n.component):w0(n)?s.defineComponent({render(){return n}}):typeof n=="string"?n:s.toRaw(s.unref(n)),I0=n=>{if(typeof n=="string")return n;const e=Hr(n,"props")&&Is(n.props)?n.props:{},t=Hr(n,"listeners")&&Is(n.listeners)?n.listeners:{};return{component:Vs(n),props:e,listeners:t}},A0=()=>typeof window<"u",Kl=class{constructor(){this.allHandlers={}}getHandlers(n){return this.allHandlers[n]||[]}on(n,e){const t=this.getHandlers(n);t.push(e),this.allHandlers[n]=t}off(n,e){const t=this.getHandlers(n);t.splice(t.indexOf(e)>>>0,1)}emit(n,e){this.getHandlers(n).forEach(r=>r(e))}},k0=n=>["on","off","emit"].every(e=>Hr(n,e)&&$l(n[e]));exports.TYPE=void 0;(function(n){n.SUCCESS="success",n.ERROR="error",n.WARNING="warning",n.INFO="info",n.DEFAULT="default"})(exports.TYPE||(exports.TYPE={}));exports.POSITION=void 0;(function(n){n.TOP_LEFT="top-left",n.TOP_CENTER="top-center",n.TOP_RIGHT="top-right",n.BOTTOM_LEFT="bottom-left",n.BOTTOM_CENTER="bottom-center",n.BOTTOM_RIGHT="bottom-right"})(exports.POSITION||(exports.POSITION={}));var xn;(function(n){n.ADD="add",n.DISMISS="dismiss",n.UPDATE="update",n.CLEAR="clear",n.UPDATE_DEFAULTS="update_defaults"})(xn||(xn={}));var yr="Vue-Toastification",vr={type:{type:String,default:exports.TYPE.DEFAULT},classNames:{type:[String,Array],default:()=>[]},trueBoolean:{type:Boolean,default:!0}},jy={type:vr.type,customIcon:{type:[String,Boolean,Object,Function],default:!0}},cl={component:{type:[String,Object,Function,Boolean],default:"button"},classNames:vr.classNames,showOnHover:{type:Boolean,default:!1},ariaLabel:{type:String,default:"close"}},Th={timeout:{type:[Number,Boolean],default:5e3},hideProgressBar:{type:Boolean,default:!1},isRunning:{type:Boolean,default:!1}},Yy={transition:{type:[Object,String],default:`${yr}__bounce`}},N0={position:{type:String,default:exports.POSITION.TOP_RIGHT},draggable:vr.trueBoolean,draggablePercent:{type:Number,default:.6},pauseOnFocusLoss:vr.trueBoolean,pauseOnHover:vr.trueBoolean,closeOnClick:vr.trueBoolean,timeout:Th.timeout,hideProgressBar:Th.hideProgressBar,toastClassName:vr.classNames,bodyClassName:vr.classNames,icon:jy.customIcon,closeButton:cl.component,closeButtonClassName:cl.classNames,showCloseButtonOnHover:cl.showOnHover,accessibility:{type:Object,default:()=>({toastRole:"alert",closeButtonLabel:"close"})},rtl:{type:Boolean,default:!1},eventBus:{type:Object,required:!1,default:()=>new Kl}},O0={id:{type:[String,Number],required:!0,default:0},type:vr.type,content:{type:[String,Object,Function],required:!0,default:""},onClick:{type:Function,default:void 0},onClose:{type:Function,default:void 0}},R0={container:{type:[Object,Function],default:()=>document.body},newestOnTop:vr.trueBoolean,maxToasts:{type:Number,default:20},transition:Yy.transition,toastDefaults:Object,filterBeforeCreate:{type:Function,default:n=>n},filterToasts:{type:Function,default:n=>n},containerClassName:vr.classNames,onMounted:Function,shareAppContext:[Boolean,Object]},mo={CORE_TOAST:N0,TOAST:O0,CONTAINER:R0,PROGRESS_BAR:Th,ICON:jy,TRANSITION:Yy,CLOSE_BUTTON:cl},Jy=s.defineComponent({name:"VtProgressBar",props:mo.PROGRESS_BAR,data(){return{hasClass:!0}},computed:{style(){return{animationDuration:`${this.timeout}ms`,animationPlayState:this.isRunning?"running":"paused",opacity:this.hideProgressBar?0:1}},cpClass(){return this.hasClass?`${yr}__progress-bar`:""}},watch:{timeout(){this.hasClass=!1,this.$nextTick(()=>this.hasClass=!0)}},mounted(){this.$el.addEventListener("animationend",this.animationEnded)},beforeUnmount(){this.$el.removeEventListener("animationend",this.animationEnded)},methods:{animationEnded(){this.$emit("close-toast")}}});function P0(n,e){return s.openBlock(),s.createElementBlock("div",{style:s.normalizeStyle(n.style),class:s.normalizeClass(n.cpClass)},null,6)}Jy.render=P0;var M0=Jy,Qy=s.defineComponent({name:"VtCloseButton",props:mo.CLOSE_BUTTON,computed:{buttonComponent(){return this.component!==!1?Vs(this.component):"button"},classes(){const n=[`${yr}__close-button`];return this.showOnHover&&n.push("show-on-hover"),n.concat(this.classNames)}}}),D0=s.createTextVNode(" × ");function L0(n,e){return s.openBlock(),s.createBlock(s.resolveDynamicComponent(n.buttonComponent),s.mergeProps({"aria-label":n.ariaLabel,class:n.classes},n.$attrs),{default:s.withCtx(()=>[D0]),_:1},16,["aria-label","class"])}Qy.render=L0;var x0=Qy,Xy={},U0={"aria-hidden":"true",focusable:"false","data-prefix":"fas","data-icon":"check-circle",class:"svg-inline--fa fa-check-circle fa-w-16",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"},V0=s.createElementVNode("path",{fill:"currentColor",d:"M504 256c0 136.967-111.033 248-248 248S8 392.967 8 256 119.033 8 256 8s248 111.033 248 248zM227.314 387.314l184-184c6.248-6.248 6.248-16.379 0-22.627l-22.627-22.627c-6.248-6.249-16.379-6.249-22.628 0L216 308.118l-70.059-70.059c-6.248-6.248-16.379-6.248-22.628 0l-22.627 22.627c-6.248 6.248-6.248 16.379 0 22.627l104 104c6.249 6.249 16.379 6.249 22.628.001z"},null,-1),B0=[V0];function F0(n,e){return s.openBlock(),s.createElementBlock("svg",U0,B0)}Xy.render=F0;var $0=Xy,Zy={},H0={"aria-hidden":"true",focusable:"false","data-prefix":"fas","data-icon":"info-circle",class:"svg-inline--fa fa-info-circle fa-w-16",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"},K0=s.createElementVNode("path",{fill:"currentColor",d:"M256 8C119.043 8 8 119.083 8 256c0 136.997 111.043 248 248 248s248-111.003 248-248C504 119.083 392.957 8 256 8zm0 110c23.196 0 42 18.804 42 42s-18.804 42-42 42-42-18.804-42-42 18.804-42 42-42zm56 254c0 6.627-5.373 12-12 12h-88c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h12v-64h-12c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h64c6.627 0 12 5.373 12 12v100h12c6.627 0 12 5.373 12 12v24z"},null,-1),W0=[K0];function z0(n,e){return s.openBlock(),s.createElementBlock("svg",H0,W0)}Zy.render=z0;var pv=Zy,eC={},G0={"aria-hidden":"true",focusable:"false","data-prefix":"fas","data-icon":"exclamation-circle",class:"svg-inline--fa fa-exclamation-circle fa-w-16",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"},q0=s.createElementVNode("path",{fill:"currentColor",d:"M504 256c0 136.997-111.043 248-248 248S8 392.997 8 256C8 119.083 119.043 8 256 8s248 111.083 248 248zm-248 50c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z"},null,-1),j0=[q0];function Y0(n,e){return s.openBlock(),s.createElementBlock("svg",G0,j0)}eC.render=Y0;var J0=eC,tC={},Q0={"aria-hidden":"true",focusable:"false","data-prefix":"fas","data-icon":"exclamation-triangle",class:"svg-inline--fa fa-exclamation-triangle fa-w-18",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512"},X0=s.createElementVNode("path",{fill:"currentColor",d:"M569.517 440.013C587.975 472.007 564.806 512 527.94 512H48.054c-36.937 0-59.999-40.055-41.577-71.987L246.423 23.985c18.467-32.009 64.72-31.951 83.154 0l239.94 416.028zM288 354c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z"},null,-1),Z0=[X0];function e1(n,e){return s.openBlock(),s.createElementBlock("svg",Q0,Z0)}tC.render=e1;var t1=tC,nC=s.defineComponent({name:"VtIcon",props:mo.ICON,computed:{customIconChildren(){return Hr(this.customIcon,"iconChildren")?this.trimValue(this.customIcon.iconChildren):""},customIconClass(){return Hl(this.customIcon)?this.trimValue(this.customIcon):Hr(this.customIcon,"iconClass")?this.trimValue(this.customIcon.iconClass):""},customIconTag(){return Hr(this.customIcon,"iconTag")?this.trimValue(this.customIcon.iconTag,"i"):"i"},hasCustomIcon(){return this.customIconClass.length>0},component(){return this.hasCustomIcon?this.customIconTag:qy(this.customIcon)?Vs(this.customIcon):this.iconTypeComponent},iconTypeComponent(){return{[exports.TYPE.DEFAULT]:pv,[exports.TYPE.INFO]:pv,[exports.TYPE.SUCCESS]:$0,[exports.TYPE.ERROR]:t1,[exports.TYPE.WARNING]:J0}[this.type]},iconClasses(){const n=[`${yr}__icon`];return this.hasCustomIcon?n.concat(this.customIconClass):n}},methods:{trimValue(n,e=""){return Wy(n)?n.trim():e}}});function n1(n,e){return s.openBlock(),s.createBlock(s.resolveDynamicComponent(n.component),{class:s.normalizeClass(n.iconClasses)},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(n.customIconChildren),1)]),_:1},8,["class"])}nC.render=n1;var r1=nC,rC=s.defineComponent({name:"VtToast",components:{ProgressBar:M0,CloseButton:x0,Icon:r1},inheritAttrs:!1,props:Object.assign({},mo.CORE_TOAST,mo.TOAST),data(){return{isRunning:!0,disableTransitions:!1,beingDragged:!1,dragStart:0,dragPos:{x:0,y:0},dragRect:{}}},computed:{classes(){const n=[`${yr}__toast`,`${yr}__toast--${this.type}`,`${this.position}`].concat(this.toastClassName);return this.disableTransitions&&n.push("disable-transition"),this.rtl&&n.push(`${yr}__toast--rtl`),n},bodyClasses(){return[`${yr}__toast-${Hl(this.content)?"body":"component-body"}`].concat(this.bodyClassName)},draggableStyle(){return this.dragStart===this.dragPos.x?{}:this.beingDragged?{transform:`translateX(${this.dragDelta}px)`,opacity:1-Math.abs(this.dragDelta/this.removalDistance)}:{transition:"transform 0.2s, opacity 0.2s",transform:"translateX(0)",opacity:1}},dragDelta(){return this.beingDragged?this.dragPos.x-this.dragStart:0},removalDistance(){return mv(this.dragRect)?(this.dragRect.right-this.dragRect.left)*this.draggablePercent:0}},mounted(){this.draggable&&this.draggableSetup(),this.pauseOnFocusLoss&&this.focusSetup()},beforeUnmount(){this.draggable&&this.draggableCleanup(),this.pauseOnFocusLoss&&this.focusCleanup()},methods:{hasProp:Hr,getVueComponentFromObj:Vs,closeToast(){this.eventBus.emit(xn.DISMISS,this.id)},clickHandler(){this.onClick&&this.onClick(this.closeToast),this.closeOnClick&&(!this.beingDragged||this.dragStart===this.dragPos.x)&&this.closeToast()},timeoutHandler(){this.closeToast()},hoverPause(){this.pauseOnHover&&(this.isRunning=!1)},hoverPlay(){this.pauseOnHover&&(this.isRunning=!0)},focusPause(){this.isRunning=!1},focusPlay(){this.isRunning=!0},focusSetup(){addEventListener("blur",this.focusPause),addEventListener("focus",this.focusPlay)},focusCleanup(){removeEventListener("blur",this.focusPause),removeEventListener("focus",this.focusPlay)},draggableSetup(){const n=this.$el;n.addEventListener("touchstart",this.onDragStart,{passive:!0}),n.addEventListener("mousedown",this.onDragStart),addEventListener("touchmove",this.onDragMove,{passive:!1}),addEventListener("mousemove",this.onDragMove),addEventListener("touchend",this.onDragEnd),addEventListener("mouseup",this.onDragEnd)},draggableCleanup(){const n=this.$el;n.removeEventListener("touchstart",this.onDragStart),n.removeEventListener("mousedown",this.onDragStart),removeEventListener("touchmove",this.onDragMove),removeEventListener("mousemove",this.onDragMove),removeEventListener("touchend",this.onDragEnd),removeEventListener("mouseup",this.onDragEnd)},onDragStart(n){this.beingDragged=!0,this.dragPos={x:Vd(n),y:gv(n)},this.dragStart=Vd(n),this.dragRect=this.$el.getBoundingClientRect()},onDragMove(n){this.beingDragged&&(n.preventDefault(),this.isRunning&&(this.isRunning=!1),this.dragPos={x:Vd(n),y:gv(n)})},onDragEnd(){this.beingDragged&&(Math.abs(this.dragDelta)>=this.removalDistance?(this.disableTransitions=!0,this.$nextTick(()=>this.closeToast())):setTimeout(()=>{this.beingDragged=!1,mv(this.dragRect)&&this.pauseOnHover&&this.dragRect.bottom>=this.dragPos.y&&this.dragPos.y>=this.dragRect.top&&this.dragRect.left<=this.dragPos.x&&this.dragPos.x<=this.dragRect.right?this.isRunning=!1:this.isRunning=!0}))}}}),o1=["role"];function i1(n,e){const t=s.resolveComponent("Icon"),r=s.resolveComponent("CloseButton"),o=s.resolveComponent("ProgressBar");return s.openBlock(),s.createElementBlock("div",{class:s.normalizeClass(n.classes),style:s.normalizeStyle(n.draggableStyle),onClick:e[0]||(e[0]=(...a)=>n.clickHandler&&n.clickHandler(...a)),onMouseenter:e[1]||(e[1]=(...a)=>n.hoverPause&&n.hoverPause(...a)),onMouseleave:e[2]||(e[2]=(...a)=>n.hoverPlay&&n.hoverPlay(...a))},[n.icon?(s.openBlock(),s.createBlock(t,{key:0,"custom-icon":n.icon,type:n.type},null,8,["custom-icon","type"])):s.createCommentVNode("v-if",!0),s.createElementVNode("div",{role:n.accessibility.toastRole||"alert",class:s.normalizeClass(n.bodyClasses)},[typeof n.content=="string"?(s.openBlock(),s.createElementBlock(s.Fragment,{key:0},[s.createTextVNode(s.toDisplayString(n.content),1)],2112)):(s.openBlock(),s.createBlock(s.resolveDynamicComponent(n.getVueComponentFromObj(n.content)),s.mergeProps({key:1,"toast-id":n.id},n.hasProp(n.content,"props")?n.content.props:{},s.toHandlers(n.hasProp(n.content,"listeners")?n.content.listeners:{}),{onCloseToast:n.closeToast}),null,16,["toast-id","onCloseToast"]))],10,o1),n.closeButton?(s.openBlock(),s.createBlock(r,{key:1,component:n.closeButton,"class-names":n.closeButtonClassName,"show-on-hover":n.showCloseButtonOnHover,"aria-label":n.accessibility.closeButtonLabel,onClick:s.withModifiers(n.closeToast,["stop"])},null,8,["component","class-names","show-on-hover","aria-label","onClick"])):s.createCommentVNode("v-if",!0),n.timeout?(s.openBlock(),s.createBlock(o,{key:2,"is-running":n.isRunning,"hide-progress-bar":n.hideProgressBar,timeout:n.timeout,onCloseToast:n.timeoutHandler},null,8,["is-running","hide-progress-bar","timeout","onCloseToast"])):s.createCommentVNode("v-if",!0)],38)}rC.render=i1;var a1=rC,oC=s.defineComponent({name:"VtTransition",props:mo.TRANSITION,emits:["leave"],methods:{hasProp:Hr,leave(n){n instanceof HTMLElement&&(n.style.left=n.offsetLeft+"px",n.style.top=n.offsetTop+"px",n.style.width=getComputedStyle(n).width,n.style.position="absolute")}}});function s1(n,e){return s.openBlock(),s.createBlock(s.TransitionGroup,{tag:"div","enter-active-class":n.transition.enter?n.transition.enter:`${n.transition}-enter-active`,"move-class":n.transition.move?n.transition.move:`${n.transition}-move`,"leave-active-class":n.transition.leave?n.transition.leave:`${n.transition}-leave-active`,onLeave:n.leave},{default:s.withCtx(()=>[s.renderSlot(n.$slots,"default")]),_:3},8,["enter-active-class","move-class","leave-active-class","onLeave"])}oC.render=s1;var c1=oC,iC=s.defineComponent({name:"VueToastification",devtools:{hide:!0},components:{Toast:a1,VtTransition:c1},props:Object.assign({},mo.CORE_TOAST,mo.CONTAINER,mo.TRANSITION),data(){return{count:0,positions:Object.values(exports.POSITION),toasts:{},defaults:{}}},computed:{toastArray(){return Object.values(this.toasts)},filteredToasts(){return this.defaults.filterToasts(this.toastArray)}},beforeMount(){const n=this.eventBus;n.on(xn.ADD,this.addToast),n.on(xn.CLEAR,this.clearToasts),n.on(xn.DISMISS,this.dismissToast),n.on(xn.UPDATE,this.updateToast),n.on(xn.UPDATE_DEFAULTS,this.updateDefaults),this.defaults=this.$props},mounted(){this.setup(this.container)},methods:{async setup(n){$l(n)&&(n=await n()),S0(this.$el),n.appendChild(this.$el)},setToast(n){pi(n.id)||(this.toasts[n.id]=n)},addToast(n){n.content=I0(n.content);const e=Object.assign({},this.defaults,n.type&&this.defaults.toastDefaults&&this.defaults.toastDefaults[n.type],n),t=this.defaults.filterBeforeCreate(e,this.toastArray);t&&this.setToast(t)},dismissToast(n){const e=this.toasts[n];!pi(e)&&!pi(e.onClose)&&e.onClose(),delete this.toasts[n]},clearToasts(){Object.keys(this.toasts).forEach(n=>{this.dismissToast(n)})},getPositionToasts(n){const e=this.filteredToasts.filter(t=>t.position===n).slice(0,this.defaults.maxToasts);return this.defaults.newestOnTop?e.reverse():e},updateDefaults(n){pi(n.container)||this.setup(n.container),this.defaults=Object.assign({},this.defaults,n)},updateToast({id:n,options:e,create:t}){this.toasts[n]?(e.timeout&&e.timeout===this.toasts[n].timeout&&e.timeout++,this.setToast(Object.assign({},this.toasts[n],e))):t&&this.addToast(Object.assign({},{id:n},e))},getClasses(n){return[`${yr}__container`,n].concat(this.defaults.containerClassName)}}});function l1(n,e){const t=s.resolveComponent("Toast"),r=s.resolveComponent("VtTransition");return s.openBlock(),s.createElementBlock("div",null,[(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(n.positions,o=>(s.openBlock(),s.createElementBlock("div",{key:o},[s.createVNode(r,{transition:n.defaults.transition,class:s.normalizeClass(n.getClasses(o))},{default:s.withCtx(()=>[(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(n.getPositionToasts(o),a=>(s.openBlock(),s.createBlock(t,s.mergeProps({key:a.id},a),null,16))),128))]),_:2},1032,["transition","class"])]))),128))])}iC.render=l1;var u1=iC,vv=(n={},e=!0)=>{const t=n.eventBus=n.eventBus||new Kl;e&&s.nextTick(()=>{const a=s.createApp(u1,Ky({},n)),l=a.mount(document.createElement("div")),d=n.onMounted;if(pi(d)||d(l,a),n.shareAppContext){const h=n.shareAppContext;h===!0?console.warn(`[${yr}] App to share context with was not provided.`):(a._context.components=h._context.components,a._context.directives=h._context.directives,a._context.mixins=h._context.mixins,a._context.provides=h._context.provides,a.config.globalProperties=h.config.globalProperties)}});const r=(a,l)=>{const d=Object.assign({},{id:b0(),type:exports.TYPE.DEFAULT},l,{content:a});return t.emit(xn.ADD,d),d.id};r.clear=()=>t.emit(xn.CLEAR,void 0),r.updateDefaults=a=>{t.emit(xn.UPDATE_DEFAULTS,a)},r.dismiss=a=>{t.emit(xn.DISMISS,a)};function o(a,{content:l,options:d},h=!1){const f=Object.assign({},d,{content:l});t.emit(xn.UPDATE,{id:a,options:f,create:h})}return r.update=o,r.success=(a,l)=>r(a,Object.assign({},l,{type:exports.TYPE.SUCCESS})),r.info=(a,l)=>r(a,Object.assign({},l,{type:exports.TYPE.INFO})),r.error=(a,l)=>r(a,Object.assign({},l,{type:exports.TYPE.ERROR})),r.warning=(a,l)=>r(a,Object.assign({},l,{type:exports.TYPE.WARNING})),r},d1=()=>{const n=()=>console.warn(`[${yr}] This plugin does not support SSR!`);return new Proxy(n,{get(){return n}})};function As(n){return A0()?k0(n)?vv({eventBus:n},!1):vv(n,!0):d1()}var Wl=Symbol("VueToastification"),vf=new Kl,h1=(n,e)=>{(e==null?void 0:e.shareAppContext)===!0&&(e.shareAppContext=n);const t=As(Ky({eventBus:vf},e));n.provide(Wl,t)},f1=n=>{const e=As(n);s.getCurrentInstance()&&s.provide(Wl,e)},sr=n=>{if(n)return As(n);const e=s.getCurrentInstance()?s.inject(Wl,void 0):void 0;return e||As(vf)},m1=h1;const as=s.ref([]),ss=s.ref([]);function aC(){const n=sr();function e(g,v,p={}){n[g](v),ss.value.push({id:crypto.randomUUID(),read:!1,type:g,message:v,timestamp:new Date,meta:{url:p.url||"",method:p.method||"",status:p.status||0}})}function t(g,v){n[g](v),as.value.push({id:crypto.randomUUID(),read:!1,type:g,message:v,timestamp:new Date})}const r={server:{success:(g,v)=>e("success",g,v),error:(g,v)=>e("error",g,v),warning:(g,v)=>e("warning",g,v),info:(g,v)=>e("info",g)},client:{success:g=>t("success",g),error:g=>t("error",g),warning:g=>t("warning",g),info:g=>t("info",g)}};function o(){return as.value.filter(g=>!g.read)}function a(){return ss.value.filter(g=>!g.read)}function l(){return[...o(),...a()].sort((g,v)=>v.timestamp.getTime()-g.timestamp.getTime())}function d(){return o().length+a().length}function h(g){const v=as.value.find(p=>p.id===g)||ss.value.find(p=>p.id===g);v&&(v.read=!0)}function f(){as.value.forEach(g=>g.read=!0),ss.value.forEach(g=>g.read=!0)}return{client:as,server:ss,toast:r,getUnreadClient:o,getUnreadServer:a,getNewNotifications:l,getUnreadCount:d,markAsRead:h,markAllAsRead:f}}const le=s.ref(!1);var sC={name:"CircleOffIcon",props:{size:{type:[Number,String],default:24}},render(){const n=this.$props.size+"px",e=this.$data.attrs||{},t={width:e.width||n,height:e.height||n};return s.createVNode("svg",s.mergeProps({xmlns:"http://www.w3.org/2000/svg",class:"icon-tabler icon-tabler-circle-off",width:"24",height:"24",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},t),[s.createTextVNode(" "),s.createVNode("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M20.042 16.045a9 9 0 0 0 -12.087 -12.087m-2.318 1.677a9 9 0 1 0 12.725 12.73"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M3 3l18 18"},null),s.createTextVNode(" ")])}},g1={name:"DotsVerticalIcon",props:{size:{type:[Number,String],default:24}},render(){const n=this.$props.size+"px",e=this.$data.attrs||{},t={width:e.width||n,height:e.height||n};return s.createVNode("svg",s.mergeProps({xmlns:"http://www.w3.org/2000/svg",class:"icon-tabler icon-tabler-dots-vertical",width:"24",height:"24",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},t),[s.createTextVNode(" "),s.createVNode("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M12 12m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M12 19m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M12 5m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0"},null),s.createTextVNode(" ")])}},p1={name:"DotsIcon",props:{size:{type:[Number,String],default:24}},render(){const n=this.$props.size+"px",e=this.$data.attrs||{},t={width:e.width||n,height:e.height||n};return s.createVNode("svg",s.mergeProps({xmlns:"http://www.w3.org/2000/svg",class:"icon-tabler icon-tabler-dots",width:"24",height:"24",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},t),[s.createTextVNode(" "),s.createVNode("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M5 12m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M12 12m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M19 12m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0"},null),s.createTextVNode(" ")])}},cC={name:"EraserIcon",props:{size:{type:[Number,String],default:24}},render(){const n=this.$props.size+"px",e=this.$data.attrs||{},t={width:e.width||n,height:e.height||n};return s.createVNode("svg",s.mergeProps({xmlns:"http://www.w3.org/2000/svg",class:"icon-tabler icon-tabler-eraser",width:"24",height:"24",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},t),[s.createTextVNode(" "),s.createVNode("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M19 20h-10.5l-4.21 -4.3a1 1 0 0 1 0 -1.41l10 -10a1 1 0 0 1 1.41 0l5 5a1 1 0 0 1 0 1.41l-9.2 9.3"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M18 13.3l-6.3 -6.3"},null),s.createTextVNode(" ")])}},lC={name:"ExclamationCircleIcon",props:{size:{type:[Number,String],default:24}},render(){const n=this.$props.size+"px",e=this.$data.attrs||{},t={width:e.width||n,height:e.height||n};return s.createVNode("svg",s.mergeProps({xmlns:"http://www.w3.org/2000/svg",class:"icon-tabler icon-tabler-exclamation-circle",width:"24",height:"24",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},t),[s.createTextVNode(" "),s.createVNode("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M12 9v4"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M12 16v.01"},null),s.createTextVNode(" ")])}},uC={name:"FilterIcon",props:{size:{type:[Number,String],default:24}},render(){const n=this.$props.size+"px",e=this.$data.attrs||{},t={width:e.width||n,height:e.height||n};return s.createVNode("svg",s.mergeProps({xmlns:"http://www.w3.org/2000/svg",class:"icon-tabler icon-tabler-filter",width:"24",height:"24",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},t),[s.createTextVNode(" "),s.createVNode("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M4 4h16v2.172a2 2 0 0 1 -.586 1.414l-4.414 4.414v7l-6 2v-8.5l-4.48 -4.928a2 2 0 0 1 -.52 -1.345v-2.227z"},null),s.createTextVNode(" ")])}},dC={name:"GripVerticalIcon",props:{size:{type:[Number,String],default:24}},render(){const n=this.$props.size+"px",e=this.$data.attrs||{},t={width:e.width||n,height:e.height||n};return s.createVNode("svg",s.mergeProps({xmlns:"http://www.w3.org/2000/svg",class:"icon-tabler icon-tabler-grip-vertical",width:"24",height:"24",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},t),[s.createTextVNode(" "),s.createVNode("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M9 5m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M9 12m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M9 19m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M15 5m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M15 12m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M15 19m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0"},null),s.createTextVNode(" ")])}},hC={name:"HierarchyIcon",props:{size:{type:[Number,String],default:24}},render(){const n=this.$props.size+"px",e=this.$data.attrs||{},t={width:e.width||n,height:e.height||n};return s.createVNode("svg",s.mergeProps({xmlns:"http://www.w3.org/2000/svg",class:"icon-tabler icon-tabler-hierarchy",width:"24",height:"24",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},t),[s.createTextVNode(" "),s.createVNode("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M12 5m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M5 19m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M19 19m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M6.5 17.5l5.5 -4.5l5.5 4.5"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M12 7l0 6"},null),s.createTextVNode(" ")])}},fC={name:"LayoutSidebarRightCollapseIcon",props:{size:{type:[Number,String],default:24}},render(){const n=this.$props.size+"px",e=this.$data.attrs||{},t={width:e.width||n,height:e.height||n};return s.createVNode("svg",s.mergeProps({xmlns:"http://www.w3.org/2000/svg",class:"icon-tabler icon-tabler-layout-sidebar-right-collapse",width:"24",height:"24",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},t),[s.createTextVNode(" "),s.createVNode("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M4 4m0 2a2 2 0 0 1 2 -2h12a2 2 0 0 1 2 2v12a2 2 0 0 1 -2 2h-12a2 2 0 0 1 -2 -2z"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M15 4v16"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M9 10l2 2l-2 2"},null),s.createTextVNode(" ")])}},v1={name:"RefreshIcon",props:{size:{type:[Number,String],default:24}},render(){const n=this.$props.size+"px",e=this.$data.attrs||{},t={width:e.width||n,height:e.height||n};return s.createVNode("svg",s.mergeProps({xmlns:"http://www.w3.org/2000/svg",class:"icon-tabler icon-tabler-refresh",width:"24",height:"24",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},t),[s.createTextVNode(" "),s.createVNode("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M20 11a8.1 8.1 0 0 0 -15.5 -2m-.5 -4v4h4"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M4 13a8.1 8.1 0 0 0 15.5 2m.5 4v-4h-4"},null),s.createTextVNode(" ")])}},_1={name:"SearchIcon",props:{size:{type:[Number,String],default:24}},render(){const n=this.$props.size+"px",e=this.$data.attrs||{},t={width:e.width||n,height:e.height||n};return s.createVNode("svg",s.mergeProps({xmlns:"http://www.w3.org/2000/svg",class:"icon-tabler icon-tabler-search",width:"24",height:"24",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},t),[s.createTextVNode(" "),s.createVNode("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M10 10m-7 0a7 7 0 1 0 14 0a7 7 0 1 0 -14 0"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M21 21l-6 -6"},null),s.createTextVNode(" ")])}},y1={name:"TableIcon",props:{size:{type:[Number,String],default:24}},render(){const n=this.$props.size+"px",e=this.$data.attrs||{},t={width:e.width||n,height:e.height||n};return s.createVNode("svg",s.mergeProps({xmlns:"http://www.w3.org/2000/svg",class:"icon-tabler icon-tabler-table",width:"24",height:"24",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},t),[s.createTextVNode(" "),s.createVNode("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M3 5a2 2 0 0 1 2 -2h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14z"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M3 10h18"},null),s.createTextVNode(" "),s.createVNode("path",{d:"M10 3v18"},null),s.createTextVNode(" ")])}};const C1={class:"d-flex align-center"},E1={key:1},w1={class:"ms-auto"},Pa=s.defineComponent({__name:"JDialog",props:{ddId:{},variant:{default:"global"},title:{},text:{},width:{default:"500"},reference:{type:Boolean},buttons:{type:Boolean,default:!0},scrim:{default:"background"}},emits:["onSave","onCancel"],setup(n,{emit:e}){const t=n,r=e,o=s.ref(!1),{isDialogActive:a,closeDialog:l}=Ra(t.ddId);async function d(){try{await r("onCancel")}catch(f){console.error(f)}l()}async function h(){o.value=!0;try{await r("onSave")}catch(f){console.error(f)}o.value=!1,l()}return(f,g)=>(s.openBlock(),s.createElementBlock(s.Fragment,null,[f.variant==="global"?(s.openBlock(),s.createBlock(rl.VDialog,{key:0,scrim:t.scrim,width:t.width,modelValue:s.unref(a),"onUpdate:modelValue":g[0]||(g[0]=v=>s.isRef(a)?a.value=v:null),"onClick:outside":d},{default:s.withCtx(()=>[s.createVNode(Ut.VCard,{rounded:"",loading:o.value},{default:s.withCtx(()=>[s.createVNode(Ut.VCardTitle,{class:"mt-2 px-5 d-flex"},{default:s.withCtx(()=>[s.createElementVNode("div",C1,[f.$slots.title?s.renderSlot(f.$slots,"title",{key:0}):(s.openBlock(),s.createElementBlock("div",E1,s.toDisplayString(t.title),1))]),s.createElementVNode("div",w1,[s.renderSlot(f.$slots,"heading-actions"),s.createVNode(Me.VBtn,{class:"ms-auto",icon:"mdi-window-close",onClick:d,variant:"plain"})])]),_:3}),s.createVNode(fo.VDivider,{class:"mx-5"}),s.createVNode(Ut.VCardText,{class:"overflow-y-scroll"},{default:s.withCtx(()=>[s.renderSlot(f.$slots,"default")]),_:3}),f.$slots.footer?(s.openBlock(),s.createElementBlock(s.Fragment,{key:0},[s.createVNode(fo.VDivider,{class:"mx-5 mt-2"}),s.createVNode(Ut.VCardActions,null,{default:s.withCtx(()=>[s.renderSlot(f.$slots,"footer")]),_:3})],64)):s.createCommentVNode("",!0),t.buttons?(s.openBlock(),s.createElementBlock(s.Fragment,{key:1},[s.createVNode(fo.VDivider,{class:"mx-5 mt-2"}),s.createVNode(Ut.VCardActions,null,{default:s.withCtx(()=>[f.$slots.metadata?(s.openBlock(),s.createBlock(xe.VCol,{key:0,cols:"auto",class:"text-sm-subtitle-2 text-medium-emphasis ma-0 pa-0"},{default:s.withCtx(()=>[s.renderSlot(f.$slots,"metadata")]),_:3})):s.createCommentVNode("",!0),s.createVNode(xe.VSpacer),s.createVNode(Me.VBtn,{class:"j-btn-form",variant:"outlined",color:"secondary",onClick:d},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(f.$t("actions.cancel")),1)]),_:1}),s.createVNode(Me.VBtn,{class:"j-btn-form",variant:"flat",color:"secondary",onClick:h,loading:o.value},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(f.$t("actions.save")),1)]),_:1},8,["loading"])]),_:3})],64)):s.createCommentVNode("",!0)]),_:3},8,["loading"])]),_:3},8,["scrim","width","modelValue"])):s.createCommentVNode("",!0),f.variant==="confirm"?(s.openBlock(),s.createBlock(rl.VDialog,{key:1,scrim:"background",width:t.width,modelValue:s.unref(a),"onUpdate:modelValue":g[1]||(g[1]=v=>s.isRef(a)?a.value=v:null),"onClick:outside":d},{default:s.withCtx(()=>[s.createVNode(Ut.VCard,{loading:o.value,title:t.title,rounded:"","min-height":"300"},{prepend:s.withCtx(()=>[s.createVNode(s.unref(lC),{color:"rgb(var(--v-theme-secondary))"})]),append:s.withCtx(()=>[s.createVNode(Me.VBtn,{class:"ms-auto",icon:"mdi-window-close",onClick:d,variant:"plain"})]),default:s.withCtx(()=>[s.createVNode(Ut.VCardText,{class:"text-center mt-7"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(t.text),1)]),_:1}),s.createVNode(Ut.VCardActions,{class:"d-flex"},{default:s.withCtx(()=>[s.createVNode(Me.VBtn,{class:"flex-grow-1",variant:"outlined",color:"secondary",onClick:d},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(f.$t("actions.cancel")),1)]),_:1}),s.createVNode(Me.VBtn,{class:"flex-grow-1",variant:"flat",color:"secondary",onClick:h},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(f.$t("actions.confirm")),1)]),_:1})]),_:1})]),_:1},8,["loading","title"])]),_:1},8,["width","modelValue"])):s.createCommentVNode("",!0),f.variant==="empty"?(s.openBlock(),s.createBlock(rl.VDialog,{key:2,scrim:t.scrim,width:t.width,modelValue:s.unref(a),"onUpdate:modelValue":g[2]||(g[2]=v=>s.isRef(a)?a.value=v:null),"onClick:outside":d},{default:s.withCtx(()=>[s.renderSlot(f.$slots,"default")]),_:3},8,["scrim","width","modelValue"])):s.createCommentVNode("",!0)],64))}});/*!
|
|
12
|
+
* shared v11.1.3
|
|
13
|
+
* (c) 2025 kazuya kawaguchi
|
|
14
|
+
* Released under the MIT License.
|
|
15
|
+
*/const Tr=typeof window<"u";let Vn,wi;if(process.env.NODE_ENV!=="production"){const n=Tr&&window.performance;n&&n.mark&&n.measure&&n.clearMarks&&n.clearMeasures&&(Vn=e=>{n.mark(e)},wi=(e,t,r)=>{n.measure(e,t,r),n.clearMarks(t),n.clearMarks(r)})}const T1=/\{([0-9a-zA-Z]+)\}/g;function zl(n,...e){return e.length===1&&Ue(e[0])&&(e=e[0]),(!e||!e.hasOwnProperty)&&(e={}),n.replace(T1,(t,r)=>e.hasOwnProperty(r)?e[r]:"")}const qr=(n,e=!1)=>e?Symbol.for(n):Symbol(n),b1=(n,e,t)=>S1({l:n,k:e,s:t}),S1=n=>JSON.stringify(n).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029").replace(/\u0027/g,"\\u0027"),bt=n=>typeof n=="number"&&isFinite(n),I1=n=>_f(n)==="[object Date]",ba=n=>_f(n)==="[object RegExp]",Gl=n=>ke(n)&&Object.keys(n).length===0,Pt=Object.assign,A1=Object.create,Ye=(n=null)=>A1(n);let _v;const vi=()=>_v||(_v=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:Ye());function yv(n){return n.replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}const k1=Object.prototype.hasOwnProperty;function Cr(n,e){return k1.call(n,e)}const yt=Array.isArray,Xe=n=>typeof n=="function",ne=n=>typeof n=="string",Be=n=>typeof n=="boolean",Ue=n=>n!==null&&typeof n=="object",N1=n=>Ue(n)&&Xe(n.then)&&Xe(n.catch),mC=Object.prototype.toString,_f=n=>mC.call(n),ke=n=>_f(n)==="[object Object]",O1=n=>n==null?"":yt(n)||ke(n)&&n.toString===mC?JSON.stringify(n,null,2):String(n);function yf(n,e=""){return n.reduce((t,r,o)=>o===0?t+r:t+e+r,"")}const Cv=2;function R1(n,e=0,t=n.length){const r=n.split(/\r?\n/);let o=0;const a=[];for(let l=0;l<r.length;l++)if(o+=r[l].length+1,o>=e){for(let d=l-Cv;d<=l+Cv||t>o;d++){if(d<0||d>=r.length)continue;const h=d+1;a.push(`${h}${" ".repeat(3-String(h).length)}| ${r[d]}`);const f=r[d].length;if(d===l){const g=e-(o-f)+1,v=Math.max(1,t>o?f-g:t-e);a.push(" | "+" ".repeat(g)+"^".repeat(v))}else if(d>l){if(t>o){const g=Math.max(Math.min(t-o,f),1);a.push(" | "+"^".repeat(g))}o+=f+1}}break}return a.join(`
|
|
16
|
+
`)}function jo(n,e){typeof console<"u"&&(console.warn("[intlify] "+n),e&&console.warn(e.stack))}const Ev={};function Cf(n){Ev[n]||(Ev[n]=!0,jo(n))}function Ef(){const n=new Map;return{events:n,on(t,r){const o=n.get(t);o&&o.push(r)||n.set(t,[r])},off(t,r){const o=n.get(t);o&&o.splice(o.indexOf(r)>>>0,1)},emit(t,r){(n.get(t)||[]).slice().map(o=>o(r)),(n.get("*")||[]).slice().map(o=>o(t,r))}}}const Vc=n=>!Ue(n)||yt(n);function ll(n,e){if(Vc(n)||Vc(e))throw new Error("Invalid value");const t=[{src:n,des:e}];for(;t.length;){const{src:r,des:o}=t.pop();Object.keys(r).forEach(a=>{a!=="__proto__"&&(Ue(r[a])&&!Ue(o[a])&&(o[a]=Array.isArray(r[a])?[]:Ye()),Vc(o[a])||Vc(r[a])?o[a]=r[a]:t.push({src:r[a],des:o[a]}))})}}/*!
|
|
17
|
+
* message-compiler v11.1.3
|
|
18
|
+
* (c) 2025 kazuya kawaguchi
|
|
19
|
+
* Released under the MIT License.
|
|
20
|
+
*/function P1(n,e,t){return{line:n,column:e,offset:t}}function bh(n,e,t){return{start:n,end:e}}const ye={EXPECTED_TOKEN:1,INVALID_TOKEN_IN_PLACEHOLDER:2,UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER:3,UNKNOWN_ESCAPE_SEQUENCE:4,INVALID_UNICODE_ESCAPE_SEQUENCE:5,UNBALANCED_CLOSING_BRACE:6,UNTERMINATED_CLOSING_BRACE:7,EMPTY_PLACEHOLDER:8,NOT_ALLOW_NEST_PLACEHOLDER:9,INVALID_LINKED_FORMAT:10,MUST_HAVE_MESSAGES_IN_PLURAL:11,UNEXPECTED_EMPTY_LINKED_MODIFIER:12,UNEXPECTED_EMPTY_LINKED_KEY:13,UNEXPECTED_LEXICAL_ANALYSIS:14,UNHANDLED_CODEGEN_NODE_TYPE:15,UNHANDLED_MINIFIER_NODE_TYPE:16},M1=17,D1={[ye.EXPECTED_TOKEN]:"Expected token: '{0}'",[ye.INVALID_TOKEN_IN_PLACEHOLDER]:"Invalid token in placeholder: '{0}'",[ye.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER]:"Unterminated single quote in placeholder",[ye.UNKNOWN_ESCAPE_SEQUENCE]:"Unknown escape sequence: \\{0}",[ye.INVALID_UNICODE_ESCAPE_SEQUENCE]:"Invalid unicode escape sequence: {0}",[ye.UNBALANCED_CLOSING_BRACE]:"Unbalanced closing brace",[ye.UNTERMINATED_CLOSING_BRACE]:"Unterminated closing brace",[ye.EMPTY_PLACEHOLDER]:"Empty placeholder",[ye.NOT_ALLOW_NEST_PLACEHOLDER]:"Not allowed nest placeholder",[ye.INVALID_LINKED_FORMAT]:"Invalid linked format",[ye.MUST_HAVE_MESSAGES_IN_PLURAL]:"Plural must have messages",[ye.UNEXPECTED_EMPTY_LINKED_MODIFIER]:"Unexpected empty linked modifier",[ye.UNEXPECTED_EMPTY_LINKED_KEY]:"Unexpected empty linked key",[ye.UNEXPECTED_LEXICAL_ANALYSIS]:"Unexpected lexical analysis in token: '{0}'",[ye.UNHANDLED_CODEGEN_NODE_TYPE]:"unhandled codegen node type: '{0}'",[ye.UNHANDLED_MINIFIER_NODE_TYPE]:"unhandled mimifier node type: '{0}'"};function Ma(n,e,t={}){const{domain:r,messages:o,args:a}=t,l=process.env.NODE_ENV!=="production"?zl((o||D1)[n]||"",...a||[]):n,d=new SyntaxError(String(l));return d.code=n,e&&(d.location=e),d.domain=r,d}function L1(n){throw n}const x1=/<\/?[\w\s="/.':;#-\/]+>/,U1=n=>x1.test(n),io=" ",V1="\r",dn=`
|
|
21
|
+
`,B1="\u2028",F1="\u2029";function $1(n){const e=n;let t=0,r=1,o=1,a=0;const l=R=>e[R]===V1&&e[R+1]===dn,d=R=>e[R]===dn,h=R=>e[R]===F1,f=R=>e[R]===B1,g=R=>l(R)||d(R)||h(R)||f(R),v=()=>t,p=()=>r,w=()=>o,C=()=>a,T=R=>l(R)||h(R)||f(R)?dn:e[R],S=()=>T(t),I=()=>T(t+a);function N(){return a=0,g(t)&&(r++,o=0),l(t)&&t++,t++,o++,e[t]}function D(){return l(t+a)&&a++,a++,e[t+a]}function L(){t=0,r=1,o=1,a=0}function U(R=0){a=R}function F(){const R=t+a;for(;R!==t;)N();a=0}return{index:v,line:p,column:w,peekOffset:C,charAt:T,currentChar:S,currentPeek:I,next:N,peek:D,reset:L,resetPeek:U,skipToPeek:F}}const Mo=void 0,H1=".",wv="'",K1="tokenizer";function W1(n,e={}){const t=e.location!==!1,r=$1(n),o=()=>r.index(),a=()=>P1(r.line(),r.column(),r.index()),l=a(),d=o(),h={currentType:13,offset:d,startLoc:l,endLoc:l,lastType:13,lastOffset:d,lastStartLoc:l,lastEndLoc:l,braceNest:0,inLinked:!1,text:""},f=()=>h,{onError:g}=e;function v(k,O,q,...oe){const Je=f();if(O.column+=q,O.offset+=q,g){const et=t?bh(Je.startLoc,O):null,De=Ma(k,et,{domain:K1,args:oe});g(De)}}function p(k,O,q){k.endLoc=a(),k.currentType=O;const oe={type:O};return t&&(oe.loc=bh(k.startLoc,k.endLoc)),q!=null&&(oe.value=q),oe}const w=k=>p(k,13);function C(k,O){return k.currentChar()===O?(k.next(),O):(v(ye.EXPECTED_TOKEN,a(),0,O),"")}function T(k){let O="";for(;k.currentPeek()===io||k.currentPeek()===dn;)O+=k.currentPeek(),k.peek();return O}function S(k){const O=T(k);return k.skipToPeek(),O}function I(k){if(k===Mo)return!1;const O=k.charCodeAt(0);return O>=97&&O<=122||O>=65&&O<=90||O===95}function N(k){if(k===Mo)return!1;const O=k.charCodeAt(0);return O>=48&&O<=57}function D(k,O){const{currentType:q}=O;if(q!==2)return!1;T(k);const oe=I(k.currentPeek());return k.resetPeek(),oe}function L(k,O){const{currentType:q}=O;if(q!==2)return!1;T(k);const oe=k.currentPeek()==="-"?k.peek():k.currentPeek(),Je=N(oe);return k.resetPeek(),Je}function U(k,O){const{currentType:q}=O;if(q!==2)return!1;T(k);const oe=k.currentPeek()===wv;return k.resetPeek(),oe}function F(k,O){const{currentType:q}=O;if(q!==7)return!1;T(k);const oe=k.currentPeek()===".";return k.resetPeek(),oe}function R(k,O){const{currentType:q}=O;if(q!==8)return!1;T(k);const oe=I(k.currentPeek());return k.resetPeek(),oe}function ae(k,O){const{currentType:q}=O;if(!(q===7||q===11))return!1;T(k);const oe=k.currentPeek()===":";return k.resetPeek(),oe}function se(k,O){const{currentType:q}=O;if(q!==9)return!1;const oe=()=>{const et=k.currentPeek();return et==="{"?I(k.peek()):et==="@"||et==="|"||et===":"||et==="."||et===io||!et?!1:et===dn?(k.peek(),oe()):ee(k,!1)},Je=oe();return k.resetPeek(),Je}function X(k){T(k);const O=k.currentPeek()==="|";return k.resetPeek(),O}function ee(k,O=!0){const q=(Je=!1,et="")=>{const De=k.currentPeek();return De==="{"||De==="@"||!De?Je:De==="|"?!(et===io||et===dn):De===io?(k.peek(),q(!0,io)):De===dn?(k.peek(),q(!0,dn)):!0},oe=q();return O&&k.resetPeek(),oe}function de(k,O){const q=k.currentChar();return q===Mo?Mo:O(q)?(k.next(),q):null}function Fe(k){const O=k.charCodeAt(0);return O>=97&&O<=122||O>=65&&O<=90||O>=48&&O<=57||O===95||O===36}function Ct(k){return de(k,Fe)}function on(k){const O=k.charCodeAt(0);return O>=97&&O<=122||O>=65&&O<=90||O>=48&&O<=57||O===95||O===36||O===45}function jt(k){return de(k,on)}function Dt(k){const O=k.charCodeAt(0);return O>=48&&O<=57}function at(k){return de(k,Dt)}function Et(k){const O=k.charCodeAt(0);return O>=48&&O<=57||O>=65&&O<=70||O>=97&&O<=102}function an(k){return de(k,Et)}function At(k){let O="",q="";for(;O=at(k);)q+=O;return q}function Xo(k){let O="";for(;;){const q=k.currentChar();if(q==="{"||q==="}"||q==="@"||q==="|"||!q)break;if(q===io||q===dn)if(ee(k))O+=q,k.next();else{if(X(k))break;O+=q,k.next()}else O+=q,k.next()}return O}function Fa(k){S(k);let O="",q="";for(;O=jt(k);)q+=O;return k.currentChar()===Mo&&v(ye.UNTERMINATED_CLOSING_BRACE,a(),0),q}function $a(k){S(k);let O="";return k.currentChar()==="-"?(k.next(),O+=`-${At(k)}`):O+=At(k),k.currentChar()===Mo&&v(ye.UNTERMINATED_CLOSING_BRACE,a(),0),O}function Ar(k){return k!==wv&&k!==dn}function Zo(k){S(k),C(k,"'");let O="",q="";for(;O=de(k,Ar);)O==="\\"?q+=Ha(k):q+=O;const oe=k.currentChar();return oe===dn||oe===Mo?(v(ye.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER,a(),0),oe===dn&&(k.next(),C(k,"'")),q):(C(k,"'"),q)}function Ha(k){const O=k.currentChar();switch(O){case"\\":case"'":return k.next(),`\\${O}`;case"u":return kr(k,O,4);case"U":return kr(k,O,6);default:return v(ye.UNKNOWN_ESCAPE_SEQUENCE,a(),0,O),""}}function kr(k,O,q){C(k,O);let oe="";for(let Je=0;Je<q;Je++){const et=an(k);if(!et){v(ye.INVALID_UNICODE_ESCAPE_SEQUENCE,a(),0,`\\${O}${oe}${k.currentChar()}`);break}oe+=et}return`\\${O}${oe}`}function jr(k){return k!=="{"&&k!=="}"&&k!==io&&k!==dn}function Ka(k){S(k);let O="",q="";for(;O=de(k,jr);)q+=O;return q}function Co(k){let O="",q="";for(;O=Ct(k);)q+=O;return q}function Eo(k){const O=q=>{const oe=k.currentChar();return oe==="{"||oe==="@"||oe==="|"||oe==="("||oe===")"||!oe||oe===io?q:(q+=oe,k.next(),O(q))};return O("")}function wo(k){S(k);const O=C(k,"|");return S(k),O}function Ft(k,O){let q=null;switch(k.currentChar()){case"{":return O.braceNest>=1&&v(ye.NOT_ALLOW_NEST_PLACEHOLDER,a(),0),k.next(),q=p(O,2,"{"),S(k),O.braceNest++,q;case"}":return O.braceNest>0&&O.currentType===2&&v(ye.EMPTY_PLACEHOLDER,a(),0),k.next(),q=p(O,3,"}"),O.braceNest--,O.braceNest>0&&S(k),O.inLinked&&O.braceNest===0&&(O.inLinked=!1),q;case"@":return O.braceNest>0&&v(ye.UNTERMINATED_CLOSING_BRACE,a(),0),q=wn(k,O)||w(O),O.braceNest=0,q;default:{let Je=!0,et=!0,De=!0;if(X(k))return O.braceNest>0&&v(ye.UNTERMINATED_CLOSING_BRACE,a(),0),q=p(O,1,wo(k)),O.braceNest=0,O.inLinked=!1,q;if(O.braceNest>0&&(O.currentType===4||O.currentType===5||O.currentType===6))return v(ye.UNTERMINATED_CLOSING_BRACE,a(),0),O.braceNest=0,ei(k,O);if(Je=D(k,O))return q=p(O,4,Fa(k)),S(k),q;if(et=L(k,O))return q=p(O,5,$a(k)),S(k),q;if(De=U(k,O))return q=p(O,6,Zo(k)),S(k),q;if(!Je&&!et&&!De)return q=p(O,12,Ka(k)),v(ye.INVALID_TOKEN_IN_PLACEHOLDER,a(),0,q.value),S(k),q;break}}return q}function wn(k,O){const{currentType:q}=O;let oe=null;const Je=k.currentChar();switch((q===7||q===8||q===11||q===9)&&(Je===dn||Je===io)&&v(ye.INVALID_LINKED_FORMAT,a(),0),Je){case"@":return k.next(),oe=p(O,7,"@"),O.inLinked=!0,oe;case".":return S(k),k.next(),p(O,8,".");case":":return S(k),k.next(),p(O,9,":");default:return X(k)?(oe=p(O,1,wo(k)),O.braceNest=0,O.inLinked=!1,oe):F(k,O)||ae(k,O)?(S(k),wn(k,O)):R(k,O)?(S(k),p(O,11,Co(k))):se(k,O)?(S(k),Je==="{"?Ft(k,O)||oe:p(O,10,Eo(k))):(q===7&&v(ye.INVALID_LINKED_FORMAT,a(),0),O.braceNest=0,O.inLinked=!1,ei(k,O))}}function ei(k,O){let q={type:13};if(O.braceNest>0)return Ft(k,O)||w(O);if(O.inLinked)return wn(k,O)||w(O);switch(k.currentChar()){case"{":return Ft(k,O)||w(O);case"}":return v(ye.UNBALANCED_CLOSING_BRACE,a(),0),k.next(),p(O,3,"}");case"@":return wn(k,O)||w(O);default:{if(X(k))return q=p(O,1,wo(k)),O.braceNest=0,O.inLinked=!1,q;if(ee(k))return p(O,0,Xo(k));break}}return q}function Tn(){const{currentType:k,offset:O,startLoc:q,endLoc:oe}=h;return h.lastType=k,h.lastOffset=O,h.lastStartLoc=q,h.lastEndLoc=oe,h.offset=o(),h.startLoc=a(),r.currentChar()===Mo?p(h,13):ei(r,h)}return{nextToken:Tn,currentOffset:o,currentPosition:a,context:f}}const z1="parser",G1=/(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g;function q1(n,e,t){switch(n){case"\\\\":return"\\";case"\\'":return"'";default:{const r=parseInt(e||t,16);return r<=55295||r>=57344?String.fromCodePoint(r):"�"}}}function j1(n={}){const e=n.location!==!1,{onError:t}=n;function r(I,N,D,L,...U){const F=I.currentPosition();if(F.offset+=L,F.column+=L,t){const R=e?bh(D,F):null,ae=Ma(N,R,{domain:z1,args:U});t(ae)}}function o(I,N,D){const L={type:I};return e&&(L.start=N,L.end=N,L.loc={start:D,end:D}),L}function a(I,N,D,L){e&&(I.end=N,I.loc&&(I.loc.end=D))}function l(I,N){const D=I.context(),L=o(3,D.offset,D.startLoc);return L.value=N,a(L,I.currentOffset(),I.currentPosition()),L}function d(I,N){const D=I.context(),{lastOffset:L,lastStartLoc:U}=D,F=o(5,L,U);return F.index=parseInt(N,10),I.nextToken(),a(F,I.currentOffset(),I.currentPosition()),F}function h(I,N){const D=I.context(),{lastOffset:L,lastStartLoc:U}=D,F=o(4,L,U);return F.key=N,I.nextToken(),a(F,I.currentOffset(),I.currentPosition()),F}function f(I,N){const D=I.context(),{lastOffset:L,lastStartLoc:U}=D,F=o(9,L,U);return F.value=N.replace(G1,q1),I.nextToken(),a(F,I.currentOffset(),I.currentPosition()),F}function g(I){const N=I.nextToken(),D=I.context(),{lastOffset:L,lastStartLoc:U}=D,F=o(8,L,U);return N.type!==11?(r(I,ye.UNEXPECTED_EMPTY_LINKED_MODIFIER,D.lastStartLoc,0),F.value="",a(F,L,U),{nextConsumeToken:N,node:F}):(N.value==null&&r(I,ye.UNEXPECTED_LEXICAL_ANALYSIS,D.lastStartLoc,0,Mr(N)),F.value=N.value||"",a(F,I.currentOffset(),I.currentPosition()),{node:F})}function v(I,N){const D=I.context(),L=o(7,D.offset,D.startLoc);return L.value=N,a(L,I.currentOffset(),I.currentPosition()),L}function p(I){const N=I.context(),D=o(6,N.offset,N.startLoc);let L=I.nextToken();if(L.type===8){const U=g(I);D.modifier=U.node,L=U.nextConsumeToken||I.nextToken()}switch(L.type!==9&&r(I,ye.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,Mr(L)),L=I.nextToken(),L.type===2&&(L=I.nextToken()),L.type){case 10:L.value==null&&r(I,ye.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,Mr(L)),D.key=v(I,L.value||"");break;case 4:L.value==null&&r(I,ye.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,Mr(L)),D.key=h(I,L.value||"");break;case 5:L.value==null&&r(I,ye.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,Mr(L)),D.key=d(I,L.value||"");break;case 6:L.value==null&&r(I,ye.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,Mr(L)),D.key=f(I,L.value||"");break;default:{r(I,ye.UNEXPECTED_EMPTY_LINKED_KEY,N.lastStartLoc,0);const U=I.context(),F=o(7,U.offset,U.startLoc);return F.value="",a(F,U.offset,U.startLoc),D.key=F,a(D,U.offset,U.startLoc),{nextConsumeToken:L,node:D}}}return a(D,I.currentOffset(),I.currentPosition()),{node:D}}function w(I){const N=I.context(),D=N.currentType===1?I.currentOffset():N.offset,L=N.currentType===1?N.endLoc:N.startLoc,U=o(2,D,L);U.items=[];let F=null;do{const se=F||I.nextToken();switch(F=null,se.type){case 0:se.value==null&&r(I,ye.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,Mr(se)),U.items.push(l(I,se.value||""));break;case 5:se.value==null&&r(I,ye.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,Mr(se)),U.items.push(d(I,se.value||""));break;case 4:se.value==null&&r(I,ye.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,Mr(se)),U.items.push(h(I,se.value||""));break;case 6:se.value==null&&r(I,ye.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,Mr(se)),U.items.push(f(I,se.value||""));break;case 7:{const X=p(I);U.items.push(X.node),F=X.nextConsumeToken||null;break}}}while(N.currentType!==13&&N.currentType!==1);const R=N.currentType===1?N.lastOffset:I.currentOffset(),ae=N.currentType===1?N.lastEndLoc:I.currentPosition();return a(U,R,ae),U}function C(I,N,D,L){const U=I.context();let F=L.items.length===0;const R=o(1,N,D);R.cases=[],R.cases.push(L);do{const ae=w(I);F||(F=ae.items.length===0),R.cases.push(ae)}while(U.currentType!==13);return F&&r(I,ye.MUST_HAVE_MESSAGES_IN_PLURAL,D,0),a(R,I.currentOffset(),I.currentPosition()),R}function T(I){const N=I.context(),{offset:D,startLoc:L}=N,U=w(I);return N.currentType===13?U:C(I,D,L,U)}function S(I){const N=W1(I,Pt({},n)),D=N.context(),L=o(0,D.offset,D.startLoc);return e&&L.loc&&(L.loc.source=I),L.body=T(N),n.onCacheKey&&(L.cacheKey=n.onCacheKey(I)),D.currentType!==13&&r(N,ye.UNEXPECTED_LEXICAL_ANALYSIS,D.lastStartLoc,0,I[D.offset]||""),a(L,N.currentOffset(),N.currentPosition()),L}return{parse:S}}function Mr(n){if(n.type===13)return"EOF";const e=(n.value||"").replace(/\r?\n/gu,"\\n");return e.length>10?e.slice(0,9)+"…":e}function Y1(n,e={}){const t={ast:n,helpers:new Set};return{context:()=>t,helper:a=>(t.helpers.add(a),a)}}function Tv(n,e){for(let t=0;t<n.length;t++)wf(n[t],e)}function wf(n,e){switch(n.type){case 1:Tv(n.cases,e),e.helper("plural");break;case 2:Tv(n.items,e);break;case 6:{wf(n.key,e),e.helper("linked"),e.helper("type");break}case 5:e.helper("interpolate"),e.helper("list");break;case 4:e.helper("interpolate"),e.helper("named");break}}function J1(n,e={}){const t=Y1(n);t.helper("normalize"),n.body&&wf(n.body,t);const r=t.context();n.helpers=Array.from(r.helpers)}function Q1(n){const e=n.body;return e.type===2?bv(e):e.cases.forEach(t=>bv(t)),n}function bv(n){if(n.items.length===1){const e=n.items[0];(e.type===3||e.type===9)&&(n.static=e.value,delete e.value)}else{const e=[];for(let t=0;t<n.items.length;t++){const r=n.items[t];if(!(r.type===3||r.type===9)||r.value==null)break;e.push(r.value)}if(e.length===n.items.length){n.static=yf(e);for(let t=0;t<n.items.length;t++){const r=n.items[t];(r.type===3||r.type===9)&&delete r.value}}}}const X1="minifier";function ca(n){switch(n.t=n.type,n.type){case 0:{const e=n;ca(e.body),e.b=e.body,delete e.body;break}case 1:{const e=n,t=e.cases;for(let r=0;r<t.length;r++)ca(t[r]);e.c=t,delete e.cases;break}case 2:{const e=n,t=e.items;for(let r=0;r<t.length;r++)ca(t[r]);e.i=t,delete e.items,e.static&&(e.s=e.static,delete e.static);break}case 3:case 9:case 8:case 7:{const e=n;e.value&&(e.v=e.value,delete e.value);break}case 6:{const e=n;ca(e.key),e.k=e.key,delete e.key,e.modifier&&(ca(e.modifier),e.m=e.modifier,delete e.modifier);break}case 5:{const e=n;e.i=e.index,delete e.index;break}case 4:{const e=n;e.k=e.key,delete e.key;break}default:if(process.env.NODE_ENV!=="production")throw Ma(ye.UNHANDLED_MINIFIER_NODE_TYPE,null,{domain:X1,args:[n.type]})}delete n.type}const Z1="parser";function eP(n,e){const{filename:t,breakLineCode:r,needIndent:o}=e,a=e.location!==!1,l={filename:t,code:"",column:1,line:1,offset:0,map:void 0,breakLineCode:r,needIndent:o,indentLevel:0};a&&n.loc&&(l.source=n.loc.source);const d=()=>l;function h(T,S){l.code+=T}function f(T,S=!0){const I=S?r:"";h(o?I+" ".repeat(T):I)}function g(T=!0){const S=++l.indentLevel;T&&f(S)}function v(T=!0){const S=--l.indentLevel;T&&f(S)}function p(){f(l.indentLevel)}return{context:d,push:h,indent:g,deindent:v,newline:p,helper:T=>`_${T}`,needIndent:()=>l.needIndent}}function tP(n,e){const{helper:t}=n;n.push(`${t("linked")}(`),Sa(n,e.key),e.modifier?(n.push(", "),Sa(n,e.modifier),n.push(", _type")):n.push(", undefined, _type"),n.push(")")}function nP(n,e){const{helper:t,needIndent:r}=n;n.push(`${t("normalize")}([`),n.indent(r());const o=e.items.length;for(let a=0;a<o&&(Sa(n,e.items[a]),a!==o-1);a++)n.push(", ");n.deindent(r()),n.push("])")}function rP(n,e){const{helper:t,needIndent:r}=n;if(e.cases.length>1){n.push(`${t("plural")}([`),n.indent(r());const o=e.cases.length;for(let a=0;a<o&&(Sa(n,e.cases[a]),a!==o-1);a++)n.push(", ");n.deindent(r()),n.push("])")}}function oP(n,e){e.body?Sa(n,e.body):n.push("null")}function Sa(n,e){const{helper:t}=n;switch(e.type){case 0:oP(n,e);break;case 1:rP(n,e);break;case 2:nP(n,e);break;case 6:tP(n,e);break;case 8:n.push(JSON.stringify(e.value),e);break;case 7:n.push(JSON.stringify(e.value),e);break;case 5:n.push(`${t("interpolate")}(${t("list")}(${e.index}))`,e);break;case 4:n.push(`${t("interpolate")}(${t("named")}(${JSON.stringify(e.key)}))`,e);break;case 9:n.push(JSON.stringify(e.value),e);break;case 3:n.push(JSON.stringify(e.value),e);break;default:if(process.env.NODE_ENV!=="production")throw Ma(ye.UNHANDLED_CODEGEN_NODE_TYPE,null,{domain:Z1,args:[e.type]})}}const iP=(n,e={})=>{const t=ne(e.mode)?e.mode:"normal",r=ne(e.filename)?e.filename:"message.intl";e.sourceMap;const o=e.breakLineCode!=null?e.breakLineCode:t==="arrow"?";":`
|
|
22
|
+
`,a=e.needIndent?e.needIndent:t!=="arrow",l=n.helpers||[],d=eP(n,{filename:r,breakLineCode:o,needIndent:a});d.push(t==="normal"?"function __msg__ (ctx) {":"(ctx) => {"),d.indent(a),l.length>0&&(d.push(`const { ${yf(l.map(g=>`${g}: _${g}`),", ")} } = ctx`),d.newline()),d.push("return "),Sa(d,n),d.deindent(a),d.push("}"),delete n.helpers;const{code:h,map:f}=d.context();return{ast:n,code:h,map:f?f.toJSON():void 0}};function aP(n,e={}){const t=Pt({},e),r=!!t.jit,o=!!t.minify,a=t.optimize==null?!0:t.optimize,d=j1(t).parse(n);return r?(a&&Q1(d),o&&ca(d),{ast:d,code:""}):(J1(d,t),iP(d,t))}/*!
|
|
23
|
+
* core-base v11.1.3
|
|
24
|
+
* (c) 2025 kazuya kawaguchi
|
|
25
|
+
* Released under the MIT License.
|
|
26
|
+
*/function sP(){typeof __INTLIFY_PROD_DEVTOOLS__!="boolean"&&(vi().__INTLIFY_PROD_DEVTOOLS__=!1),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!="boolean"&&(vi().__INTLIFY_DROP_MESSAGE_COMPILER__=!1)}function ir(n){return Ue(n)&&Tf(n)===0&&(Cr(n,"b")||Cr(n,"body"))}const gC=["b","body"];function cP(n){return Yo(n,gC)}const pC=["c","cases"];function lP(n){return Yo(n,pC,[])}const vC=["s","static"];function uP(n){return Yo(n,vC)}const _C=["i","items"];function dP(n){return Yo(n,_C,[])}const yC=["t","type"];function Tf(n){return Yo(n,yC)}const CC=["v","value"];function Bc(n,e){const t=Yo(n,CC);if(t!=null)return t;throw ks(e)}const EC=["m","modifier"];function hP(n){return Yo(n,EC)}const wC=["k","key"];function fP(n){const e=Yo(n,wC);if(e)return e;throw ks(6)}function Yo(n,e,t){for(let r=0;r<e.length;r++){const o=e[r];if(Cr(n,o)&&n[o]!=null)return n[o]}return t}const TC=[...gC,...pC,...vC,..._C,...wC,...EC,...CC,...yC];function ks(n){return new Error(`unhandled node type: ${n}`)}function Bd(n){return t=>mP(t,n)}function mP(n,e){const t=cP(e);if(t==null)throw ks(0);if(Tf(t)===1){const a=lP(t);return n.plural(a.reduce((l,d)=>[...l,Sv(n,d)],[]))}else return Sv(n,t)}function Sv(n,e){const t=uP(e);if(t!=null)return n.type==="text"?t:n.normalize([t]);{const r=dP(e).reduce((o,a)=>[...o,Sh(n,a)],[]);return n.normalize(r)}}function Sh(n,e){const t=Tf(e);switch(t){case 3:return Bc(e,t);case 9:return Bc(e,t);case 4:{const r=e;if(Cr(r,"k")&&r.k)return n.interpolate(n.named(r.k));if(Cr(r,"key")&&r.key)return n.interpolate(n.named(r.key));throw ks(t)}case 5:{const r=e;if(Cr(r,"i")&&bt(r.i))return n.interpolate(n.list(r.i));if(Cr(r,"index")&&bt(r.index))return n.interpolate(n.list(r.index));throw ks(t)}case 6:{const r=e,o=hP(r),a=fP(r);return n.linked(Sh(n,a),o?Sh(n,o):void 0,n.type)}case 7:return Bc(e,t);case 8:return Bc(e,t);default:throw new Error(`unhandled node on format message part: ${t}`)}}const gP="Detected HTML in '{source}' message. Recommend not using HTML messages to avoid XSS.";function pP(n,e){e&&U1(n)&&jo(zl(gP,{source:n}))}const vP=n=>n;let Fc=Ye();function _P(n,e={}){let t=!1;const r=e.onError||L1;return e.onError=o=>{t=!0,r(o)},{...aP(n,e),detectError:t}}function yP(n,e){if(!__INTLIFY_DROP_MESSAGE_COMPILER__&&ne(n)){const t=Be(e.warnHtmlMessage)?e.warnHtmlMessage:!0;process.env.NODE_ENV!=="production"&&pP(n,t);const o=(e.onCacheKey||vP)(n),a=Fc[o];if(a)return a;const{ast:l,detectError:d}=_P(n,{...e,location:process.env.NODE_ENV!=="production",jit:!0}),h=Bd(l);return d?h:Fc[o]=h}else{if(process.env.NODE_ENV!=="production"&&!ir(n))return jo(`the message that is resolve with key '${e.key}' is not supported for jit compilation`),()=>n;const t=n.cacheKey;if(t){const r=Fc[t];return r||(Fc[t]=Bd(n))}else return Bd(n)}}let Ns=null;function CP(n){Ns=n}function EP(n,e,t){Ns&&Ns.emit("i18n:init",{timestamp:Date.now(),i18n:n,version:e,meta:t})}const wP=TP("function:translate");function TP(n){return e=>Ns&&Ns.emit(n,e)}const en={INVALID_ARGUMENT:M1,INVALID_DATE_ARGUMENT:18,INVALID_ISO_DATE_ARGUMENT:19,NOT_SUPPORT_NON_STRING_MESSAGE:20,NOT_SUPPORT_LOCALE_PROMISE_VALUE:21,NOT_SUPPORT_LOCALE_ASYNC_FUNCTION:22,NOT_SUPPORT_LOCALE_TYPE:23},bP=24;function co(n){return Ma(n,null,process.env.NODE_ENV!=="production"?{messages:SP}:void 0)}const SP={[en.INVALID_ARGUMENT]:"Invalid arguments",[en.INVALID_DATE_ARGUMENT]:"The date provided is an invalid Date object.Make sure your Date represents a valid date.",[en.INVALID_ISO_DATE_ARGUMENT]:"The argument provided is not a valid ISO date string",[en.NOT_SUPPORT_NON_STRING_MESSAGE]:"Not support non-string message",[en.NOT_SUPPORT_LOCALE_PROMISE_VALUE]:"cannot support promise value",[en.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION]:"cannot support async function",[en.NOT_SUPPORT_LOCALE_TYPE]:"cannot support locale type"};function bf(n,e){return e.locale!=null?Iv(e.locale):Iv(n.locale)}let Fd;function Iv(n){if(ne(n))return n;if(Xe(n)){if(n.resolvedOnce&&Fd!=null)return Fd;if(n.constructor.name==="Function"){const e=n();if(N1(e))throw co(en.NOT_SUPPORT_LOCALE_PROMISE_VALUE);return Fd=e}else throw co(en.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION)}else throw co(en.NOT_SUPPORT_LOCALE_TYPE)}function IP(n,e,t){return[...new Set([t,...yt(e)?e:Ue(e)?Object.keys(e):ne(e)?[e]:[t]])]}function bC(n,e,t){const r=ne(t)?t:Os,o=n;o.__localeChainCache||(o.__localeChainCache=new Map);let a=o.__localeChainCache.get(r);if(!a){a=[];let l=[t];for(;yt(l);)l=Av(a,l,e);const d=yt(e)||!ke(e)?e:e.default?e.default:null;l=ne(d)?[d]:d,yt(l)&&Av(a,l,!1),o.__localeChainCache.set(r,a)}return a}function Av(n,e,t){let r=!0;for(let o=0;o<e.length&&Be(r);o++){const a=e[o];ne(a)&&(r=AP(n,e[o],t))}return r}function AP(n,e,t){let r;const o=e.split("-");do{const a=o.join("-");r=kP(n,a,t),o.splice(-1,1)}while(o.length&&r===!0);return r}function kP(n,e,t){let r=!1;if(!n.includes(e)&&(r=!0,e)){r=e[e.length-1]!=="!";const o=e.replace(/!/g,"");n.push(o),(yt(t)||ke(t))&&t[o]&&(r=t[o])}return r}const Jo=[];Jo[0]={w:[0],i:[3,0],"[":[4],o:[7]};Jo[1]={w:[1],".":[2],"[":[4],o:[7]};Jo[2]={w:[2],i:[3,0],0:[3,0]};Jo[3]={i:[3,0],0:[3,0],w:[1,1],".":[2,1],"[":[4,1],o:[7,1]};Jo[4]={"'":[5,0],'"':[6,0],"[":[4,2],"]":[1,3],o:8,l:[4,0]};Jo[5]={"'":[4,0],o:8,l:[5,0]};Jo[6]={'"':[4,0],o:8,l:[6,0]};const NP=/^\s?(?:true|false|-?[\d.]+|'[^']*'|"[^"]*")\s?$/;function OP(n){return NP.test(n)}function RP(n){const e=n.charCodeAt(0),t=n.charCodeAt(n.length-1);return e===t&&(e===34||e===39)?n.slice(1,-1):n}function PP(n){if(n==null)return"o";switch(n.charCodeAt(0)){case 91:case 93:case 46:case 34:case 39:return n;case 95:case 36:case 45:return"i";case 9:case 10:case 13:case 160:case 65279:case 8232:case 8233:return"w"}return"i"}function MP(n){const e=n.trim();return n.charAt(0)==="0"&&isNaN(parseInt(n))?!1:OP(e)?RP(e):"*"+e}function DP(n){const e=[];let t=-1,r=0,o=0,a,l,d,h,f,g,v;const p=[];p[0]=()=>{l===void 0?l=d:l+=d},p[1]=()=>{l!==void 0&&(e.push(l),l=void 0)},p[2]=()=>{p[0](),o++},p[3]=()=>{if(o>0)o--,r=4,p[0]();else{if(o=0,l===void 0||(l=MP(l),l===!1))return!1;p[1]()}};function w(){const C=n[t+1];if(r===5&&C==="'"||r===6&&C==='"')return t++,d="\\"+C,p[0](),!0}for(;r!==null;)if(t++,a=n[t],!(a==="\\"&&w())){if(h=PP(a),v=Jo[r],f=v[h]||v.l||8,f===8||(r=f[0],f[1]!==void 0&&(g=p[f[1]],g&&(d=a,g()===!1))))return;if(r===7)return e}}const kv=new Map;function LP(n,e){return Ue(n)?n[e]:null}function xP(n,e){if(!Ue(n))return null;let t=kv.get(e);if(t||(t=DP(e),t&&kv.set(e,t)),!t)return null;const r=t.length;let o=n,a=0;for(;a<r;){const l=t[a];if(TC.includes(l)&&ir(o))return null;const d=o[l];if(d===void 0||Xe(o))return null;o=d,a++}return o}const _n={NOT_FOUND_KEY:1,FALLBACK_TO_TRANSLATE:2,CANNOT_FORMAT_NUMBER:3,FALLBACK_TO_NUMBER_FORMAT:4,CANNOT_FORMAT_DATE:5,FALLBACK_TO_DATE_FORMAT:6,EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER:7},UP=8,VP={[_n.NOT_FOUND_KEY]:"Not found '{key}' key in '{locale}' locale messages.",[_n.FALLBACK_TO_TRANSLATE]:"Fall back to translate '{key}' key with '{target}' locale.",[_n.CANNOT_FORMAT_NUMBER]:"Cannot format a number value due to not supported Intl.NumberFormat.",[_n.FALLBACK_TO_NUMBER_FORMAT]:"Fall back to number format '{key}' key with '{target}' locale.",[_n.CANNOT_FORMAT_DATE]:"Cannot format a date value due to not supported Intl.DateTimeFormat.",[_n.FALLBACK_TO_DATE_FORMAT]:"Fall back to datetime format '{key}' key with '{target}' locale.",[_n.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER]:"This project is using Custom Message Compiler, which is an experimental feature. It may receive breaking changes or be removed in the future."};function Ti(n,...e){return zl(VP[n],...e)}const BP="11.1.3",ql=-1,Os="en-US",Cl="",Nv=n=>`${n.charAt(0).toLocaleUpperCase()}${n.substr(1)}`;function FP(){return{upper:(n,e)=>e==="text"&&ne(n)?n.toUpperCase():e==="vnode"&&Ue(n)&&"__v_isVNode"in n?n.children.toUpperCase():n,lower:(n,e)=>e==="text"&&ne(n)?n.toLowerCase():e==="vnode"&&Ue(n)&&"__v_isVNode"in n?n.children.toLowerCase():n,capitalize:(n,e)=>e==="text"&&ne(n)?Nv(n):e==="vnode"&&Ue(n)&&"__v_isVNode"in n?Nv(n.children):n}}let SC;function $P(n){SC=n}let IC;function HP(n){IC=n}let AC;function KP(n){AC=n}let kC=null;const WP=n=>{kC=n},zP=()=>kC;let NC=null;const Ov=n=>{NC=n},GP=()=>NC;let Rv=0;function qP(n={}){const e=Xe(n.onWarn)?n.onWarn:jo,t=ne(n.version)?n.version:BP,r=ne(n.locale)||Xe(n.locale)?n.locale:Os,o=Xe(r)?Os:r,a=yt(n.fallbackLocale)||ke(n.fallbackLocale)||ne(n.fallbackLocale)||n.fallbackLocale===!1?n.fallbackLocale:o,l=ke(n.messages)?n.messages:$d(o),d=ke(n.datetimeFormats)?n.datetimeFormats:$d(o),h=ke(n.numberFormats)?n.numberFormats:$d(o),f=Pt(Ye(),n.modifiers,FP()),g=n.pluralRules||Ye(),v=Xe(n.missing)?n.missing:null,p=Be(n.missingWarn)||ba(n.missingWarn)?n.missingWarn:!0,w=Be(n.fallbackWarn)||ba(n.fallbackWarn)?n.fallbackWarn:!0,C=!!n.fallbackFormat,T=!!n.unresolving,S=Xe(n.postTranslation)?n.postTranslation:null,I=ke(n.processor)?n.processor:null,N=Be(n.warnHtmlMessage)?n.warnHtmlMessage:!0,D=!!n.escapeParameter,L=Xe(n.messageCompiler)?n.messageCompiler:SC;process.env.NODE_ENV!=="production"&&Xe(n.messageCompiler)&&Cf(Ti(_n.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER));const U=Xe(n.messageResolver)?n.messageResolver:IC||LP,F=Xe(n.localeFallbacker)?n.localeFallbacker:AC||IP,R=Ue(n.fallbackContext)?n.fallbackContext:void 0,ae=n,se=Ue(ae.__datetimeFormatters)?ae.__datetimeFormatters:new Map,X=Ue(ae.__numberFormatters)?ae.__numberFormatters:new Map,ee=Ue(ae.__meta)?ae.__meta:{};Rv++;const de={version:t,cid:Rv,locale:r,fallbackLocale:a,messages:l,modifiers:f,pluralRules:g,missing:v,missingWarn:p,fallbackWarn:w,fallbackFormat:C,unresolving:T,postTranslation:S,processor:I,warnHtmlMessage:N,escapeParameter:D,messageCompiler:L,messageResolver:U,localeFallbacker:F,fallbackContext:R,onWarn:e,__meta:ee};return de.datetimeFormats=d,de.numberFormats=h,de.__datetimeFormatters=se,de.__numberFormatters=X,process.env.NODE_ENV!=="production"&&(de.__v_emitter=ae.__v_emitter!=null?ae.__v_emitter:void 0),(process.env.NODE_ENV!=="production"||__INTLIFY_PROD_DEVTOOLS__)&&EP(de,t,ee),de}const $d=n=>({[n]:Ye()});function jl(n,e){return n instanceof RegExp?n.test(e):n}function OC(n,e){return n instanceof RegExp?n.test(e):n}function Sf(n,e,t,r,o){const{missing:a,onWarn:l}=n;if(process.env.NODE_ENV!=="production"){const d=n.__v_emitter;d&&d.emit("missing",{locale:t,key:e,type:o,groupId:`${o}:${e}`})}if(a!==null){const d=a(n,t,e,o);return ne(d)?d:e}else return process.env.NODE_ENV!=="production"&&OC(r,e)&&l(Ti(_n.NOT_FOUND_KEY,{key:e,locale:t})),e}function cs(n,e,t){const r=n;r.__localeChainCache=new Map,n.localeFallbacker(n,t,e)}function RC(n,e){return n===e?!1:n.split("-")[0]===e.split("-")[0]}function jP(n,e){const t=e.indexOf(n);if(t===-1)return!1;for(let r=t+1;r<e.length;r++)if(RC(n,e[r]))return!0;return!1}const Pv=typeof Intl<"u",PC={dateTimeFormat:Pv&&typeof Intl.DateTimeFormat<"u",numberFormat:Pv&&typeof Intl.NumberFormat<"u"};function Mv(n,...e){const{datetimeFormats:t,unresolving:r,fallbackLocale:o,onWarn:a,localeFallbacker:l}=n,{__datetimeFormatters:d}=n;if(process.env.NODE_ENV!=="production"&&!PC.dateTimeFormat)return a(Ti(_n.CANNOT_FORMAT_DATE)),Cl;const[h,f,g,v]=Ih(...e),p=Be(g.missingWarn)?g.missingWarn:n.missingWarn,w=Be(g.fallbackWarn)?g.fallbackWarn:n.fallbackWarn,C=!!g.part,T=bf(n,g),S=l(n,o,T);if(!ne(h)||h==="")return new Intl.DateTimeFormat(T,v).format(f);let I={},N,D=null,L=T,U=null;const F="datetime format";for(let se=0;se<S.length;se++){if(N=U=S[se],process.env.NODE_ENV!=="production"&&T!==N&&jl(w,h)&&a(Ti(_n.FALLBACK_TO_DATE_FORMAT,{key:h,target:N})),process.env.NODE_ENV!=="production"&&T!==N){const X=n.__v_emitter;X&&X.emit("fallback",{type:F,key:h,from:L,to:U,groupId:`${F}:${h}`})}if(I=t[N]||{},D=I[h],ke(D))break;Sf(n,h,N,p,F),L=U}if(!ke(D)||!ne(N))return r?ql:h;let R=`${N}__${h}`;Gl(v)||(R=`${R}__${JSON.stringify(v)}`);let ae=d.get(R);return ae||(ae=new Intl.DateTimeFormat(N,Pt({},D,v)),d.set(R,ae)),C?ae.formatToParts(f):ae.format(f)}const MC=["localeMatcher","weekday","era","year","month","day","hour","minute","second","timeZoneName","formatMatcher","hour12","timeZone","dateStyle","timeStyle","calendar","dayPeriod","numberingSystem","hourCycle","fractionalSecondDigits"];function Ih(...n){const[e,t,r,o]=n,a=Ye();let l=Ye(),d;if(ne(e)){const h=e.match(/(\d{4}-\d{2}-\d{2})(T|\s)?(.*)/);if(!h)throw co(en.INVALID_ISO_DATE_ARGUMENT);const f=h[3]?h[3].trim().startsWith("T")?`${h[1].trim()}${h[3].trim()}`:`${h[1].trim()}T${h[3].trim()}`:h[1].trim();d=new Date(f);try{d.toISOString()}catch{throw co(en.INVALID_ISO_DATE_ARGUMENT)}}else if(I1(e)){if(isNaN(e.getTime()))throw co(en.INVALID_DATE_ARGUMENT);d=e}else if(bt(e))d=e;else throw co(en.INVALID_ARGUMENT);return ne(t)?a.key=t:ke(t)&&Object.keys(t).forEach(h=>{MC.includes(h)?l[h]=t[h]:a[h]=t[h]}),ne(r)?a.locale=r:ke(r)&&(l=r),ke(o)&&(l=o),[a.key||"",d,a,l]}function Dv(n,e,t){const r=n;for(const o in t){const a=`${e}__${o}`;r.__datetimeFormatters.has(a)&&r.__datetimeFormatters.delete(a)}}function Lv(n,...e){const{numberFormats:t,unresolving:r,fallbackLocale:o,onWarn:a,localeFallbacker:l}=n,{__numberFormatters:d}=n;if(process.env.NODE_ENV!=="production"&&!PC.numberFormat)return a(Ti(_n.CANNOT_FORMAT_NUMBER)),Cl;const[h,f,g,v]=Ah(...e),p=Be(g.missingWarn)?g.missingWarn:n.missingWarn,w=Be(g.fallbackWarn)?g.fallbackWarn:n.fallbackWarn,C=!!g.part,T=bf(n,g),S=l(n,o,T);if(!ne(h)||h==="")return new Intl.NumberFormat(T,v).format(f);let I={},N,D=null,L=T,U=null;const F="number format";for(let se=0;se<S.length;se++){if(N=U=S[se],process.env.NODE_ENV!=="production"&&T!==N&&jl(w,h)&&a(Ti(_n.FALLBACK_TO_NUMBER_FORMAT,{key:h,target:N})),process.env.NODE_ENV!=="production"&&T!==N){const X=n.__v_emitter;X&&X.emit("fallback",{type:F,key:h,from:L,to:U,groupId:`${F}:${h}`})}if(I=t[N]||{},D=I[h],ke(D))break;Sf(n,h,N,p,F),L=U}if(!ke(D)||!ne(N))return r?ql:h;let R=`${N}__${h}`;Gl(v)||(R=`${R}__${JSON.stringify(v)}`);let ae=d.get(R);return ae||(ae=new Intl.NumberFormat(N,Pt({},D,v)),d.set(R,ae)),C?ae.formatToParts(f):ae.format(f)}const DC=["localeMatcher","style","currency","currencyDisplay","currencySign","useGrouping","minimumIntegerDigits","minimumFractionDigits","maximumFractionDigits","minimumSignificantDigits","maximumSignificantDigits","compactDisplay","notation","signDisplay","unit","unitDisplay","roundingMode","roundingPriority","roundingIncrement","trailingZeroDisplay"];function Ah(...n){const[e,t,r,o]=n,a=Ye();let l=Ye();if(!bt(e))throw co(en.INVALID_ARGUMENT);const d=e;return ne(t)?a.key=t:ke(t)&&Object.keys(t).forEach(h=>{DC.includes(h)?l[h]=t[h]:a[h]=t[h]}),ne(r)?a.locale=r:ke(r)&&(l=r),ke(o)&&(l=o),[a.key||"",d,a,l]}function xv(n,e,t){const r=n;for(const o in t){const a=`${e}__${o}`;r.__numberFormatters.has(a)&&r.__numberFormatters.delete(a)}}const YP=n=>n,JP=n=>"",QP="text",XP=n=>n.length===0?"":yf(n),ZP=O1;function Uv(n,e){return n=Math.abs(n),e===2?n?n>1?1:0:1:n?Math.min(n,2):0}function eM(n){const e=bt(n.pluralIndex)?n.pluralIndex:-1;return n.named&&(bt(n.named.count)||bt(n.named.n))?bt(n.named.count)?n.named.count:bt(n.named.n)?n.named.n:e:e}function tM(n,e){e.count||(e.count=n),e.n||(e.n=n)}function nM(n={}){const e=n.locale,t=eM(n),r=Ue(n.pluralRules)&&ne(e)&&Xe(n.pluralRules[e])?n.pluralRules[e]:Uv,o=Ue(n.pluralRules)&&ne(e)&&Xe(n.pluralRules[e])?Uv:void 0,a=I=>I[r(t,I.length,o)],l=n.list||[],d=I=>l[I],h=n.named||Ye();bt(n.pluralIndex)&&tM(t,h);const f=I=>h[I];function g(I,N){const D=Xe(n.messages)?n.messages(I,!!N):Ue(n.messages)?n.messages[I]:!1;return D||(n.parent?n.parent.message(I):JP)}const v=I=>n.modifiers?n.modifiers[I]:YP,p=ke(n.processor)&&Xe(n.processor.normalize)?n.processor.normalize:XP,w=ke(n.processor)&&Xe(n.processor.interpolate)?n.processor.interpolate:ZP,C=ke(n.processor)&&ne(n.processor.type)?n.processor.type:QP,S={list:d,named:f,plural:a,linked:(I,...N)=>{const[D,L]=N;let U="text",F="";N.length===1?Ue(D)?(F=D.modifier||F,U=D.type||U):ne(D)&&(F=D||F):N.length===2&&(ne(D)&&(F=D||F),ne(L)&&(U=L||U));const R=g(I,!0)(S),ae=U==="vnode"&&yt(R)&&F?R[0]:R;return F?v(F)(ae,U):ae},message:g,type:C,interpolate:w,normalize:p,values:Pt(Ye(),l,h)};return S}const Vv=()=>"",or=n=>Xe(n);function Bv(n,...e){const{fallbackFormat:t,postTranslation:r,unresolving:o,messageCompiler:a,fallbackLocale:l,messages:d}=n,[h,f]=kh(...e),g=Be(f.missingWarn)?f.missingWarn:n.missingWarn,v=Be(f.fallbackWarn)?f.fallbackWarn:n.fallbackWarn,p=Be(f.escapeParameter)?f.escapeParameter:n.escapeParameter,w=!!f.resolvedMessage,C=ne(f.default)||Be(f.default)?Be(f.default)?a?h:()=>h:f.default:t?a?h:()=>h:null,T=t||C!=null&&(ne(C)||Xe(C)),S=bf(n,f);p&&rM(f);let[I,N,D]=w?[h,S,d[S]||Ye()]:LC(n,h,S,l,v,g),L=I,U=h;if(!w&&!(ne(L)||ir(L)||or(L))&&T&&(L=C,U=L),!w&&(!(ne(L)||ir(L)||or(L))||!ne(N)))return o?ql:h;if(process.env.NODE_ENV!=="production"&&ne(L)&&n.messageCompiler==null)return jo(`The message format compilation is not supported in this build. Because message compiler isn't included. You need to pre-compilation all message format. So translate function return '${h}'.`),h;let F=!1;const R=()=>{F=!0},ae=or(L)?L:xC(n,h,N,L,U,R);if(F)return L;const se=sM(n,N,D,f),X=nM(se),ee=oM(n,ae,X),de=r?r(ee,h):ee;if(process.env.NODE_ENV!=="production"||__INTLIFY_PROD_DEVTOOLS__){const Fe={timestamp:Date.now(),key:ne(h)?h:or(L)?L.key:"",locale:N||(or(L)?L.locale:""),format:ne(L)?L:or(L)?L.source:"",message:de};Fe.meta=Pt({},n.__meta,zP()||{}),wP(Fe)}return de}function rM(n){yt(n.list)?n.list=n.list.map(e=>ne(e)?yv(e):e):Ue(n.named)&&Object.keys(n.named).forEach(e=>{ne(n.named[e])&&(n.named[e]=yv(n.named[e]))})}function LC(n,e,t,r,o,a){const{messages:l,onWarn:d,messageResolver:h,localeFallbacker:f}=n,g=f(n,r,t);let v=Ye(),p,w=null,C=t,T=null;const S="translate";for(let I=0;I<g.length;I++){if(p=T=g[I],process.env.NODE_ENV!=="production"&&t!==p&&!RC(t,p)&&jl(o,e)&&d(Ti(_n.FALLBACK_TO_TRANSLATE,{key:e,target:p})),process.env.NODE_ENV!=="production"&&t!==p){const U=n.__v_emitter;U&&U.emit("fallback",{type:S,key:e,from:C,to:T,groupId:`${S}:${e}`})}v=l[p]||Ye();let N=null,D,L;if(process.env.NODE_ENV!=="production"&&Tr&&(N=window.performance.now(),D="intlify-message-resolve-start",L="intlify-message-resolve-end",Vn&&Vn(D)),(w=h(v,e))===null&&(w=v[e]),process.env.NODE_ENV!=="production"&&Tr){const U=window.performance.now(),F=n.__v_emitter;F&&N&&w&&F.emit("message-resolve",{type:"message-resolve",key:e,message:w,time:U-N,groupId:`${S}:${e}`}),D&&L&&Vn&&wi&&(Vn(L),wi("intlify message resolve",D,L))}if(ne(w)||ir(w)||or(w))break;if(!jP(p,g)){const U=Sf(n,e,p,a,S);U!==e&&(w=U)}C=T}return[w,p,v]}function xC(n,e,t,r,o,a){const{messageCompiler:l,warnHtmlMessage:d}=n;if(or(r)){const p=r;return p.locale=p.locale||t,p.key=p.key||e,p}if(l==null){const p=()=>r;return p.locale=t,p.key=e,p}let h=null,f,g;process.env.NODE_ENV!=="production"&&Tr&&(h=window.performance.now(),f="intlify-message-compilation-start",g="intlify-message-compilation-end",Vn&&Vn(f));const v=l(r,iM(n,t,o,r,d,a));if(process.env.NODE_ENV!=="production"&&Tr){const p=window.performance.now(),w=n.__v_emitter;w&&h&&w.emit("message-compilation",{type:"message-compilation",message:r,time:p-h,groupId:`translate:${e}`}),f&&g&&Vn&&wi&&(Vn(g),wi("intlify message compilation",f,g))}return v.locale=t,v.key=e,v.source=r,v}function oM(n,e,t){let r=null,o,a;process.env.NODE_ENV!=="production"&&Tr&&(r=window.performance.now(),o="intlify-message-evaluation-start",a="intlify-message-evaluation-end",Vn&&Vn(o));const l=e(t);if(process.env.NODE_ENV!=="production"&&Tr){const d=window.performance.now(),h=n.__v_emitter;h&&r&&h.emit("message-evaluation",{type:"message-evaluation",value:l,time:d-r,groupId:`translate:${e.key}`}),o&&a&&Vn&&wi&&(Vn(a),wi("intlify message evaluation",o,a))}return l}function kh(...n){const[e,t,r]=n,o=Ye();if(!ne(e)&&!bt(e)&&!or(e)&&!ir(e))throw co(en.INVALID_ARGUMENT);const a=bt(e)?String(e):(or(e),e);return bt(t)?o.plural=t:ne(t)?o.default=t:ke(t)&&!Gl(t)?o.named=t:yt(t)&&(o.list=t),bt(r)?o.plural=r:ne(r)?o.default=r:ke(r)&&Pt(o,r),[a,o]}function iM(n,e,t,r,o,a){return{locale:e,key:t,warnHtmlMessage:o,onError:l=>{if(a&&a(l),process.env.NODE_ENV!=="production"){const d=aM(r),h=`Message compilation error: ${l.message}`,f=l.location&&d&&R1(d,l.location.start.offset,l.location.end.offset),g=n.__v_emitter;g&&d&&g.emit("compile-error",{message:d,error:l.message,start:l.location&&l.location.start.offset,end:l.location&&l.location.end.offset,groupId:`translate:${t}`}),console.error(f?`${h}
|
|
27
|
+
${f}`:h)}else throw l},onCacheKey:l=>b1(e,t,l)}}function aM(n){if(ne(n))return n;if(n.loc&&n.loc.source)return n.loc.source}function sM(n,e,t,r){const{modifiers:o,pluralRules:a,messageResolver:l,fallbackLocale:d,fallbackWarn:h,missingWarn:f,fallbackContext:g}=n,p={locale:e,modifiers:o,pluralRules:a,messages:(w,C)=>{let T=l(t,w);if(T==null&&(g||C)){const[,,S]=LC(g||n,w,e,d,h,f);T=l(S,w)}if(ne(T)||ir(T)){let S=!1;const N=xC(n,w,e,T,w,()=>{S=!0});return S?Vv:N}else return or(T)?T:Vv}};return n.processor&&(p.processor=n.processor),r.list&&(p.list=r.list),r.named&&(p.named=r.named),bt(r.plural)&&(p.pluralIndex=r.plural),p}sP();/*!
|
|
28
|
+
* vue-i18n v11.1.3
|
|
29
|
+
* (c) 2025 kazuya kawaguchi
|
|
30
|
+
* Released under the MIT License.
|
|
31
|
+
*/const cM="11.1.3";function lM(){typeof __VUE_I18N_FULL_INSTALL__!="boolean"&&(vi().__VUE_I18N_FULL_INSTALL__=!0),typeof __VUE_I18N_LEGACY_API__!="boolean"&&(vi().__VUE_I18N_LEGACY_API__=!0),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!="boolean"&&(vi().__INTLIFY_DROP_MESSAGE_COMPILER__=!1),typeof __INTLIFY_PROD_DEVTOOLS__!="boolean"&&(vi().__INTLIFY_PROD_DEVTOOLS__=!1)}const rt={UNEXPECTED_RETURN_TYPE:bP,INVALID_ARGUMENT:25,MUST_BE_CALL_SETUP_TOP:26,NOT_INSTALLED:27,REQUIRED_VALUE:28,INVALID_VALUE:29,CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN:30,NOT_INSTALLED_WITH_PROVIDE:31,UNEXPECTED_ERROR:32,NOT_COMPATIBLE_LEGACY_VUE_I18N:33,NOT_AVAILABLE_COMPOSITION_IN_LEGACY:34};function En(n,...e){return Ma(n,null,process.env.NODE_ENV!=="production"?{messages:uM,args:e}:void 0)}const uM={[rt.UNEXPECTED_RETURN_TYPE]:"Unexpected return type in composer",[rt.INVALID_ARGUMENT]:"Invalid argument",[rt.MUST_BE_CALL_SETUP_TOP]:"Must be called at the top of a `setup` function",[rt.NOT_INSTALLED]:"Need to install with `app.use` function",[rt.UNEXPECTED_ERROR]:"Unexpected error",[rt.REQUIRED_VALUE]:"Required in value: {0}",[rt.INVALID_VALUE]:"Invalid value",[rt.CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN]:"Cannot setup vue-devtools plugin",[rt.NOT_INSTALLED_WITH_PROVIDE]:"Need to install with `provide` function",[rt.NOT_COMPATIBLE_LEGACY_VUE_I18N]:"Not compatible legacy VueI18n.",[rt.NOT_AVAILABLE_COMPOSITION_IN_LEGACY]:"Not available Compostion API in Legacy API mode. Please make sure that the legacy API mode is working properly"},Nh=qr("__translateVNode"),Oh=qr("__datetimeParts"),Rh=qr("__numberParts"),bi=qr("__enableEmitter"),Rs=qr("__disableEmitter"),UC=qr("__setPluralRules"),VC=qr("__injectWithOption"),Ph=qr("__dispose"),Ur={FALLBACK_TO_ROOT:UP,NOT_FOUND_PARENT_SCOPE:9,IGNORE_OBJ_FLATTEN:10,DEPRECATE_LEGACY_MODE:11,DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE:12},dM={[Ur.FALLBACK_TO_ROOT]:"Fall back to {type} '{key}' with root locale.",[Ur.NOT_FOUND_PARENT_SCOPE]:"Not found parent scope. use the global scope.",[Ur.IGNORE_OBJ_FLATTEN]:"Ignore object flatten: '{key}' key has an string value",[Ur.DEPRECATE_LEGACY_MODE]:`Legacy API mode has been deprecated in v11. Use Composition API mode instead.
|
|
32
|
+
About how to use the Composition API mode, see https://vue-i18n.intlify.dev/guide/advanced/composition.html`,[Ur.DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE]:"'v-t' has been deprecated in v11. Use translate APIs ('t' or '$t') instead."};function Bs(n,...e){return zl(dM[n],...e)}function Ps(n){if(!Ue(n)||ir(n))return n;for(const e in n)if(Cr(n,e))if(!e.includes("."))Ue(n[e])&&Ps(n[e]);else{const t=e.split("."),r=t.length-1;let o=n,a=!1;for(let l=0;l<r;l++){if(t[l]==="__proto__")throw new Error(`unsafe key: ${t[l]}`);if(t[l]in o||(o[t[l]]=Ye()),!Ue(o[t[l]])){process.env.NODE_ENV!=="production"&&jo(Bs(Ur.IGNORE_OBJ_FLATTEN,{key:t[l]})),a=!0;break}o=o[t[l]]}if(a||(ir(o)?TC.includes(t[r])||delete n[e]:(o[t[r]]=n[e],delete n[e])),!ir(o)){const l=o[t[r]];Ue(l)&&Ps(l)}}return n}function If(n,e){const{messages:t,__i18n:r,messageResolver:o,flatJson:a}=e,l=ke(t)?t:yt(r)?Ye():{[n]:Ye()};if(yt(r)&&r.forEach(d=>{if("locale"in d&&"resource"in d){const{locale:h,resource:f}=d;h?(l[h]=l[h]||Ye(),ll(f,l[h])):ll(f,l)}else ne(d)&&ll(JSON.parse(d),l)}),o==null&&a)for(const d in l)Cr(l,d)&&Ps(l[d]);return l}function BC(n){return n.type}function FC(n,e,t){let r=Ue(e.messages)?e.messages:Ye();"__i18nGlobal"in t&&(r=If(n.locale.value,{messages:r,__i18n:t.__i18nGlobal}));const o=Object.keys(r);o.length&&o.forEach(a=>{n.mergeLocaleMessage(a,r[a])});{if(Ue(e.datetimeFormats)){const a=Object.keys(e.datetimeFormats);a.length&&a.forEach(l=>{n.mergeDateTimeFormat(l,e.datetimeFormats[l])})}if(Ue(e.numberFormats)){const a=Object.keys(e.numberFormats);a.length&&a.forEach(l=>{n.mergeNumberFormat(l,e.numberFormats[l])})}}}function Fv(n){return s.createVNode(s.Text,null,n,0)}const $v="__INTLIFY_META__",Hv=()=>[],hM=()=>!1;let Kv=0;function Wv(n){return(e,t,r,o)=>n(t,r,s.getCurrentInstance()||void 0,o)}const fM=()=>{const n=s.getCurrentInstance();let e=null;return n&&(e=BC(n)[$v])?{[$v]:e}:null};function Af(n={}){const{__root:e,__injectWithOption:t}=n,r=e===void 0,o=n.flatJson,a=Tr?s.ref:s.shallowRef;let l=Be(n.inheritLocale)?n.inheritLocale:!0;const d=a(e&&l?e.locale.value:ne(n.locale)?n.locale:Os),h=a(e&&l?e.fallbackLocale.value:ne(n.fallbackLocale)||yt(n.fallbackLocale)||ke(n.fallbackLocale)||n.fallbackLocale===!1?n.fallbackLocale:d.value),f=a(If(d.value,n)),g=a(ke(n.datetimeFormats)?n.datetimeFormats:{[d.value]:{}}),v=a(ke(n.numberFormats)?n.numberFormats:{[d.value]:{}});let p=e?e.missingWarn:Be(n.missingWarn)||ba(n.missingWarn)?n.missingWarn:!0,w=e?e.fallbackWarn:Be(n.fallbackWarn)||ba(n.fallbackWarn)?n.fallbackWarn:!0,C=e?e.fallbackRoot:Be(n.fallbackRoot)?n.fallbackRoot:!0,T=!!n.fallbackFormat,S=Xe(n.missing)?n.missing:null,I=Xe(n.missing)?Wv(n.missing):null,N=Xe(n.postTranslation)?n.postTranslation:null,D=e?e.warnHtmlMessage:Be(n.warnHtmlMessage)?n.warnHtmlMessage:!0,L=!!n.escapeParameter;const U=e?e.modifiers:ke(n.modifiers)?n.modifiers:{};let F=n.pluralRules||e&&e.pluralRules,R;R=(()=>{r&&Ov(null);const H={version:cM,locale:d.value,fallbackLocale:h.value,messages:f.value,modifiers:U,pluralRules:F,missing:I===null?void 0:I,missingWarn:p,fallbackWarn:w,fallbackFormat:T,unresolving:!0,postTranslation:N===null?void 0:N,warnHtmlMessage:D,escapeParameter:L,messageResolver:n.messageResolver,messageCompiler:n.messageCompiler,__meta:{framework:"vue"}};H.datetimeFormats=g.value,H.numberFormats=v.value,H.__datetimeFormatters=ke(R)?R.__datetimeFormatters:void 0,H.__numberFormatters=ke(R)?R.__numberFormatters:void 0,process.env.NODE_ENV!=="production"&&(H.__v_emitter=ke(R)?R.__v_emitter:void 0);const J=qP(H);return r&&Ov(J),J})(),cs(R,d.value,h.value);function se(){return[d.value,h.value,f.value,g.value,v.value]}const X=s.computed({get:()=>d.value,set:H=>{R.locale=H,d.value=H}}),ee=s.computed({get:()=>h.value,set:H=>{R.fallbackLocale=H,h.value=H,cs(R,d.value,H)}}),de=s.computed(()=>f.value),Fe=s.computed(()=>g.value),Ct=s.computed(()=>v.value);function on(){return Xe(N)?N:null}function jt(H){N=H,R.postTranslation=H}function Dt(){return S}function at(H){H!==null&&(I=Wv(H)),S=H,R.missing=I}function Et(H,J){return H!=="translate"||!J.resolvedMessage}const an=(H,J,Ne,qe,cr,To)=>{se();let Nr;try{process.env.NODE_ENV!=="production"||__INTLIFY_PROD_DEVTOOLS__,r||(R.fallbackContext=e?GP():void 0),Nr=H(R)}finally{process.env.NODE_ENV!=="production"||__INTLIFY_PROD_DEVTOOLS__,r||(R.fallbackContext=void 0)}if(Ne!=="translate exists"&&bt(Nr)&&Nr===ql||Ne==="translate exists"&&!Nr){const[lr,Wa]=J();if(process.env.NODE_ENV!=="production"&&e&&ne(lr)&&Et(Ne,Wa)&&(C&&(jl(w,lr)||OC(p,lr))&&jo(Bs(Ur.FALLBACK_TO_ROOT,{key:lr,type:Ne})),process.env.NODE_ENV!=="production")){const{__v_emitter:Mi}=R;Mi&&C&&Mi.emit("fallback",{type:Ne,key:lr,to:"global",groupId:`${Ne}:${lr}`})}return e&&C?qe(e):cr(lr)}else{if(To(Nr))return Nr;throw En(rt.UNEXPECTED_RETURN_TYPE)}};function At(...H){return an(J=>Reflect.apply(Bv,null,[J,...H]),()=>kh(...H),"translate",J=>Reflect.apply(J.t,J,[...H]),J=>J,J=>ne(J))}function Xo(...H){const[J,Ne,qe]=H;if(qe&&!Ue(qe))throw En(rt.INVALID_ARGUMENT);return At(J,Ne,Pt({resolvedMessage:!0},qe||{}))}function Fa(...H){return an(J=>Reflect.apply(Mv,null,[J,...H]),()=>Ih(...H),"datetime format",J=>Reflect.apply(J.d,J,[...H]),()=>Cl,J=>ne(J))}function $a(...H){return an(J=>Reflect.apply(Lv,null,[J,...H]),()=>Ah(...H),"number format",J=>Reflect.apply(J.n,J,[...H]),()=>Cl,J=>ne(J))}function Ar(H){return H.map(J=>ne(J)||bt(J)||Be(J)?Fv(String(J)):J)}const Ha={normalize:Ar,interpolate:H=>H,type:"vnode"};function kr(...H){return an(J=>{let Ne;const qe=J;try{qe.processor=Ha,Ne=Reflect.apply(Bv,null,[qe,...H])}finally{qe.processor=null}return Ne},()=>kh(...H),"translate",J=>J[Nh](...H),J=>[Fv(J)],J=>yt(J))}function jr(...H){return an(J=>Reflect.apply(Lv,null,[J,...H]),()=>Ah(...H),"number format",J=>J[Rh](...H),Hv,J=>ne(J)||yt(J))}function Ka(...H){return an(J=>Reflect.apply(Mv,null,[J,...H]),()=>Ih(...H),"datetime format",J=>J[Oh](...H),Hv,J=>ne(J)||yt(J))}function Co(H){F=H,R.pluralRules=F}function Eo(H,J){return an(()=>{if(!H)return!1;const Ne=ne(J)?J:d.value,qe=wn(Ne),cr=R.messageResolver(qe,H);return ir(cr)||or(cr)||ne(cr)},()=>[H],"translate exists",Ne=>Reflect.apply(Ne.te,Ne,[H,J]),hM,Ne=>Be(Ne))}function wo(H){let J=null;const Ne=bC(R,h.value,d.value);for(let qe=0;qe<Ne.length;qe++){const cr=f.value[Ne[qe]]||{},To=R.messageResolver(cr,H);if(To!=null){J=To;break}}return J}function Ft(H){const J=wo(H);return J??(e?e.tm(H)||{}:{})}function wn(H){return f.value[H]||{}}function ei(H,J){if(o){const Ne={[H]:J};for(const qe in Ne)Cr(Ne,qe)&&Ps(Ne[qe]);J=Ne[H]}f.value[H]=J,R.messages=f.value}function Tn(H,J){f.value[H]=f.value[H]||{};const Ne={[H]:J};if(o)for(const qe in Ne)Cr(Ne,qe)&&Ps(Ne[qe]);J=Ne[H],ll(J,f.value[H]),R.messages=f.value}function k(H){return g.value[H]||{}}function O(H,J){g.value[H]=J,R.datetimeFormats=g.value,Dv(R,H,J)}function q(H,J){g.value[H]=Pt(g.value[H]||{},J),R.datetimeFormats=g.value,Dv(R,H,J)}function oe(H){return v.value[H]||{}}function Je(H,J){v.value[H]=J,R.numberFormats=v.value,xv(R,H,J)}function et(H,J){v.value[H]=Pt(v.value[H]||{},J),R.numberFormats=v.value,xv(R,H,J)}Kv++,e&&Tr&&(s.watch(e.locale,H=>{l&&(d.value=H,R.locale=H,cs(R,d.value,h.value))}),s.watch(e.fallbackLocale,H=>{l&&(h.value=H,R.fallbackLocale=H,cs(R,d.value,h.value))}));const De={id:Kv,locale:X,fallbackLocale:ee,get inheritLocale(){return l},set inheritLocale(H){l=H,H&&e&&(d.value=e.locale.value,h.value=e.fallbackLocale.value,cs(R,d.value,h.value))},get availableLocales(){return Object.keys(f.value).sort()},messages:de,get modifiers(){return U},get pluralRules(){return F||{}},get isGlobal(){return r},get missingWarn(){return p},set missingWarn(H){p=H,R.missingWarn=p},get fallbackWarn(){return w},set fallbackWarn(H){w=H,R.fallbackWarn=w},get fallbackRoot(){return C},set fallbackRoot(H){C=H},get fallbackFormat(){return T},set fallbackFormat(H){T=H,R.fallbackFormat=T},get warnHtmlMessage(){return D},set warnHtmlMessage(H){D=H,R.warnHtmlMessage=H},get escapeParameter(){return L},set escapeParameter(H){L=H,R.escapeParameter=H},t:At,getLocaleMessage:wn,setLocaleMessage:ei,mergeLocaleMessage:Tn,getPostTranslationHandler:on,setPostTranslationHandler:jt,getMissingHandler:Dt,setMissingHandler:at,[UC]:Co};return De.datetimeFormats=Fe,De.numberFormats=Ct,De.rt=Xo,De.te=Eo,De.tm=Ft,De.d=Fa,De.n=$a,De.getDateTimeFormat=k,De.setDateTimeFormat=O,De.mergeDateTimeFormat=q,De.getNumberFormat=oe,De.setNumberFormat=Je,De.mergeNumberFormat=et,De[VC]=t,De[Nh]=kr,De[Oh]=Ka,De[Rh]=jr,process.env.NODE_ENV!=="production"&&(De[bi]=H=>{R.__v_emitter=H},De[Rs]=()=>{R.__v_emitter=void 0}),De}const $C="vue-i18n: composer properties",Hd={"vue-devtools-plugin-vue-i18n":"Vue I18n DevTools","vue-i18n-resource-inspector":"Vue I18n DevTools","vue-i18n-timeline":"Vue I18n"},mM={"vue-i18n-resource-inspector":"Search for scopes ..."},gM={"vue-i18n-timeline":16764185};let Mh;async function pM(n,e){return new Promise((t,r)=>{try{mf({id:"vue-devtools-plugin-vue-i18n",label:Hd["vue-devtools-plugin-vue-i18n"],packageName:"vue-i18n",homepage:"https://vue-i18n.intlify.dev",logo:"https://vue-i18n.intlify.dev/vue-i18n-devtools-logo.png",componentStateTypes:[$C],app:n},o=>{Mh=o,o.on.visitComponentTree(({componentInstance:l,treeNode:d})=>{vM(l,d,e)}),o.on.inspectComponent(({componentInstance:l,instanceData:d})=>{l.vnode.el&&l.vnode.el.__VUE_I18N__&&d&&(e.mode==="legacy"?l.vnode.el.__VUE_I18N__!==e.global.__composer&&zv(d,l.vnode.el.__VUE_I18N__):zv(d,l.vnode.el.__VUE_I18N__))}),o.addInspector({id:"vue-i18n-resource-inspector",label:Hd["vue-i18n-resource-inspector"],icon:"language",treeFilterPlaceholder:mM["vue-i18n-resource-inspector"]}),o.on.getInspectorTree(l=>{l.app===n&&l.inspectorId==="vue-i18n-resource-inspector"&&wM(l,e)});const a=new Map;o.on.getInspectorState(async l=>{if(l.app===n&&l.inspectorId==="vue-i18n-resource-inspector")if(o.unhighlightElement(),bM(l,e),l.nodeId==="global"){if(!a.has(l.app)){const[d]=await o.getComponentInstances(l.app);a.set(l.app,d)}o.highlightElement(a.get(l.app))}else{const d=TM(l.nodeId,e);d&&o.highlightElement(d)}}),o.on.editInspectorState(l=>{l.app===n&&l.inspectorId==="vue-i18n-resource-inspector"&&IM(l,e)}),o.addTimelineLayer({id:"vue-i18n-timeline",label:Hd["vue-i18n-timeline"],color:gM["vue-i18n-timeline"]}),t(!0)})}catch(o){console.error(o),r(!1)}})}function HC(n){return n.type.name||n.type.displayName||n.type.__file||"Anonymous"}function vM(n,e,t){const r=t.mode==="composition"?t.global:t.global.__composer;if(n&&n.vnode.el&&n.vnode.el.__VUE_I18N__&&n.vnode.el.__VUE_I18N__!==r){const o={label:`i18n (${HC(n)} Scope)`,textColor:0,backgroundColor:16764185};e.tags.push(o)}}function zv(n,e){const t=$C;n.state.push({type:t,key:"locale",editable:!0,value:e.locale.value}),n.state.push({type:t,key:"availableLocales",editable:!1,value:e.availableLocales}),n.state.push({type:t,key:"fallbackLocale",editable:!0,value:e.fallbackLocale.value}),n.state.push({type:t,key:"inheritLocale",editable:!0,value:e.inheritLocale}),n.state.push({type:t,key:"messages",editable:!1,value:kf(e.messages.value)}),n.state.push({type:t,key:"datetimeFormats",editable:!1,value:e.datetimeFormats.value}),n.state.push({type:t,key:"numberFormats",editable:!1,value:e.numberFormats.value})}function kf(n){const e={};return Object.keys(n).forEach(t=>{const r=n[t];Xe(r)&&"source"in r?e[t]=EM(r):ir(r)&&r.loc&&r.loc.source?e[t]=r.loc.source:Ue(r)?e[t]=kf(r):e[t]=r}),e}const _M={"<":"<",">":">",'"':""","&":"&"};function yM(n){return n.replace(/[<>"&]/g,CM)}function CM(n){return _M[n]||n}function EM(n){return{_custom:{type:"function",display:`<span>ƒ</span> ${n.source?`("${yM(n.source)}")`:"(?)"}`}}}function wM(n,e){n.rootNodes.push({id:"global",label:"Global Scope"});const t=e.mode==="composition"?e.global:e.global.__composer;for(const[r,o]of e.__instances){const a=e.mode==="composition"?o:o.__composer;t!==a&&n.rootNodes.push({id:a.id.toString(),label:`${HC(r)} Scope`})}}function TM(n,e){let t=null;if(n!=="global"){for(const[r,o]of e.__instances.entries())if(o.id.toString()===n){t=r;break}}return t}function KC(n,e){if(n==="global")return e.mode==="composition"?e.global:e.global.__composer;{const t=Array.from(e.__instances.values()).find(r=>r.id.toString()===n);return t?e.mode==="composition"?t:t.__composer:null}}function bM(n,e){const t=KC(n.nodeId,e);return t&&(n.state=SM(t)),null}function SM(n){const e={},t="Locale related info",r=[{type:t,key:"locale",editable:!0,value:n.locale.value},{type:t,key:"fallbackLocale",editable:!0,value:n.fallbackLocale.value},{type:t,key:"availableLocales",editable:!1,value:n.availableLocales},{type:t,key:"inheritLocale",editable:!0,value:n.inheritLocale}];e[t]=r;const o="Locale messages info",a=[{type:o,key:"messages",editable:!1,value:kf(n.messages.value)}];e[o]=a;{const l="Datetime formats info",d=[{type:l,key:"datetimeFormats",editable:!1,value:n.datetimeFormats.value}];e[l]=d;const h="Datetime formats info",f=[{type:h,key:"numberFormats",editable:!1,value:n.numberFormats.value}];e[h]=f}return e}function Ms(n,e){if(Mh){let t;e&&"groupId"in e&&(t=e.groupId,delete e.groupId),Mh.addTimelineEvent({layerId:"vue-i18n-timeline",event:{title:n,groupId:t,time:Date.now(),meta:{},data:e||{},logType:n==="compile-error"?"error":n==="fallback"||n==="missing"?"warning":"default"}})}}function IM(n,e){const t=KC(n.nodeId,e);if(t){const[r]=n.path;r==="locale"&&ne(n.state.value)?t.locale.value=n.state.value:r==="fallbackLocale"&&(ne(n.state.value)||yt(n.state.value)||Ue(n.state.value))?t.fallbackLocale.value=n.state.value:r==="inheritLocale"&&Be(n.state.value)&&(t.inheritLocale=n.state.value)}}function AM(n){const e=ne(n.locale)?n.locale:Os,t=ne(n.fallbackLocale)||yt(n.fallbackLocale)||ke(n.fallbackLocale)||n.fallbackLocale===!1?n.fallbackLocale:e,r=Xe(n.missing)?n.missing:void 0,o=Be(n.silentTranslationWarn)||ba(n.silentTranslationWarn)?!n.silentTranslationWarn:!0,a=Be(n.silentFallbackWarn)||ba(n.silentFallbackWarn)?!n.silentFallbackWarn:!0,l=Be(n.fallbackRoot)?n.fallbackRoot:!0,d=!!n.formatFallbackMessages,h=ke(n.modifiers)?n.modifiers:{},f=n.pluralizationRules,g=Xe(n.postTranslation)?n.postTranslation:void 0,v=ne(n.warnHtmlInMessage)?n.warnHtmlInMessage!=="off":!0,p=!!n.escapeParameterHtml,w=Be(n.sync)?n.sync:!0;let C=n.messages;if(ke(n.sharedMessages)){const U=n.sharedMessages;C=Object.keys(U).reduce((R,ae)=>{const se=R[ae]||(R[ae]={});return Pt(se,U[ae]),R},C||{})}const{__i18n:T,__root:S,__injectWithOption:I}=n,N=n.datetimeFormats,D=n.numberFormats,L=n.flatJson;return{locale:e,fallbackLocale:t,messages:C,flatJson:L,datetimeFormats:N,numberFormats:D,missing:r,missingWarn:o,fallbackWarn:a,fallbackRoot:l,fallbackFormat:d,modifiers:h,pluralRules:f,postTranslation:g,warnHtmlMessage:v,escapeParameter:p,messageResolver:n.messageResolver,inheritLocale:w,__i18n:T,__root:S,__injectWithOption:I}}function Dh(n={}){const e=Af(AM(n)),{__extender:t}=n,r={id:e.id,get locale(){return e.locale.value},set locale(o){e.locale.value=o},get fallbackLocale(){return e.fallbackLocale.value},set fallbackLocale(o){e.fallbackLocale.value=o},get messages(){return e.messages.value},get datetimeFormats(){return e.datetimeFormats.value},get numberFormats(){return e.numberFormats.value},get availableLocales(){return e.availableLocales},get missing(){return e.getMissingHandler()},set missing(o){e.setMissingHandler(o)},get silentTranslationWarn(){return Be(e.missingWarn)?!e.missingWarn:e.missingWarn},set silentTranslationWarn(o){e.missingWarn=Be(o)?!o:o},get silentFallbackWarn(){return Be(e.fallbackWarn)?!e.fallbackWarn:e.fallbackWarn},set silentFallbackWarn(o){e.fallbackWarn=Be(o)?!o:o},get modifiers(){return e.modifiers},get formatFallbackMessages(){return e.fallbackFormat},set formatFallbackMessages(o){e.fallbackFormat=o},get postTranslation(){return e.getPostTranslationHandler()},set postTranslation(o){e.setPostTranslationHandler(o)},get sync(){return e.inheritLocale},set sync(o){e.inheritLocale=o},get warnHtmlInMessage(){return e.warnHtmlMessage?"warn":"off"},set warnHtmlInMessage(o){e.warnHtmlMessage=o!=="off"},get escapeParameterHtml(){return e.escapeParameter},set escapeParameterHtml(o){e.escapeParameter=o},get pluralizationRules(){return e.pluralRules||{}},__composer:e,t(...o){return Reflect.apply(e.t,e,[...o])},rt(...o){return Reflect.apply(e.rt,e,[...o])},te(o,a){return e.te(o,a)},tm(o){return e.tm(o)},getLocaleMessage(o){return e.getLocaleMessage(o)},setLocaleMessage(o,a){e.setLocaleMessage(o,a)},mergeLocaleMessage(o,a){e.mergeLocaleMessage(o,a)},d(...o){return Reflect.apply(e.d,e,[...o])},getDateTimeFormat(o){return e.getDateTimeFormat(o)},setDateTimeFormat(o,a){e.setDateTimeFormat(o,a)},mergeDateTimeFormat(o,a){e.mergeDateTimeFormat(o,a)},n(...o){return Reflect.apply(e.n,e,[...o])},getNumberFormat(o){return e.getNumberFormat(o)},setNumberFormat(o,a){e.setNumberFormat(o,a)},mergeNumberFormat(o,a){e.mergeNumberFormat(o,a)}};return r.__extender=t,process.env.NODE_ENV!=="production"&&(r.__enableEmitter=o=>{const a=e;a[bi]&&a[bi](o)},r.__disableEmitter=()=>{const o=e;o[Rs]&&o[Rs]()}),r}function kM(n,e,t){return{beforeCreate(){const r=s.getCurrentInstance();if(!r)throw En(rt.UNEXPECTED_ERROR);const o=this.$options;if(o.i18n){const a=o.i18n;if(o.__i18n&&(a.__i18n=o.__i18n),a.__root=e,this===this.$root)this.$i18n=Gv(n,a);else{a.__injectWithOption=!0,a.__extender=t.__vueI18nExtend,this.$i18n=Dh(a);const l=this.$i18n;l.__extender&&(l.__disposer=l.__extender(this.$i18n))}}else if(o.__i18n)if(this===this.$root)this.$i18n=Gv(n,o);else{this.$i18n=Dh({__i18n:o.__i18n,__injectWithOption:!0,__extender:t.__vueI18nExtend,__root:e});const a=this.$i18n;a.__extender&&(a.__disposer=a.__extender(this.$i18n))}else this.$i18n=n;o.__i18nGlobal&&FC(e,o,o),this.$t=(...a)=>this.$i18n.t(...a),this.$rt=(...a)=>this.$i18n.rt(...a),this.$te=(a,l)=>this.$i18n.te(a,l),this.$d=(...a)=>this.$i18n.d(...a),this.$n=(...a)=>this.$i18n.n(...a),this.$tm=a=>this.$i18n.tm(a),t.__setInstance(r,this.$i18n)},mounted(){if(process.env.NODE_ENV!=="production"&&this.$el&&this.$i18n){const r=this.$i18n;this.$el.__VUE_I18N__=r.__composer;const o=this.__v_emitter=Ef();r.__enableEmitter&&r.__enableEmitter(o),o.on("*",Ms)}},unmounted(){const r=s.getCurrentInstance();if(!r)throw En(rt.UNEXPECTED_ERROR);const o=this.$i18n;process.env.NODE_ENV!=="production"&&this.$el&&this.$el.__VUE_I18N__&&(this.__v_emitter&&(this.__v_emitter.off("*",Ms),delete this.__v_emitter),this.$i18n&&(o.__disableEmitter&&o.__disableEmitter(),delete this.$el.__VUE_I18N__)),delete this.$t,delete this.$rt,delete this.$te,delete this.$d,delete this.$n,delete this.$tm,o.__disposer&&(o.__disposer(),delete o.__disposer,delete o.__extender),t.__deleteInstance(r),delete this.$i18n}}}function Gv(n,e){n.locale=e.locale||n.locale,n.fallbackLocale=e.fallbackLocale||n.fallbackLocale,n.missing=e.missing||n.missing,n.silentTranslationWarn=e.silentTranslationWarn||n.silentFallbackWarn,n.silentFallbackWarn=e.silentFallbackWarn||n.silentFallbackWarn,n.formatFallbackMessages=e.formatFallbackMessages||n.formatFallbackMessages,n.postTranslation=e.postTranslation||n.postTranslation,n.warnHtmlInMessage=e.warnHtmlInMessage||n.warnHtmlInMessage,n.escapeParameterHtml=e.escapeParameterHtml||n.escapeParameterHtml,n.sync=e.sync||n.sync,n.__composer[UC](e.pluralizationRules||n.pluralizationRules);const t=If(n.locale,{messages:e.messages,__i18n:e.__i18n});return Object.keys(t).forEach(r=>n.mergeLocaleMessage(r,t[r])),e.datetimeFormats&&Object.keys(e.datetimeFormats).forEach(r=>n.mergeDateTimeFormat(r,e.datetimeFormats[r])),e.numberFormats&&Object.keys(e.numberFormats).forEach(r=>n.mergeNumberFormat(r,e.numberFormats[r])),n}const Nf={tag:{type:[String,Object]},locale:{type:String},scope:{type:String,validator:n=>n==="parent"||n==="global",default:"parent"},i18n:{type:Object}};function NM({slots:n},e){return e.length===1&&e[0]==="default"?(n.default?n.default():[]).reduce((r,o)=>[...r,...o.type===s.Fragment?o.children:[o]],[]):e.reduce((t,r)=>{const o=n[r];return o&&(t[r]=o()),t},Ye())}function WC(){return s.Fragment}const OM=s.defineComponent({name:"i18n-t",props:Pt({keypath:{type:String,required:!0},plural:{type:[Number,String],validator:n=>bt(n)||!isNaN(n)}},Nf),setup(n,e){const{slots:t,attrs:r}=e,o=n.i18n||rn({useScope:n.scope,__useComponent:!0});return()=>{const a=Object.keys(t).filter(v=>v!=="_"),l=Ye();n.locale&&(l.locale=n.locale),n.plural!==void 0&&(l.plural=ne(n.plural)?+n.plural:n.plural);const d=NM(e,a),h=o[Nh](n.keypath,d,l),f=Pt(Ye(),r),g=ne(n.tag)||Ue(n.tag)?n.tag:WC();return s.h(g,f,h)}}}),qv=OM;function RM(n){return yt(n)&&!ne(n[0])}function zC(n,e,t,r){const{slots:o,attrs:a}=e;return()=>{const l={part:!0};let d=Ye();n.locale&&(l.locale=n.locale),ne(n.format)?l.key=n.format:Ue(n.format)&&(ne(n.format.key)&&(l.key=n.format.key),d=Object.keys(n.format).reduce((p,w)=>t.includes(w)?Pt(Ye(),p,{[w]:n.format[w]}):p,Ye()));const h=r(n.value,l,d);let f=[l.key];yt(h)?f=h.map((p,w)=>{const C=o[p.type],T=C?C({[p.type]:p.value,index:w,parts:h}):[p.value];return RM(T)&&(T[0].key=`${p.type}-${w}`),T}):ne(h)&&(f=[h]);const g=Pt(Ye(),a),v=ne(n.tag)||Ue(n.tag)?n.tag:WC();return s.h(v,g,f)}}const PM=s.defineComponent({name:"i18n-n",props:Pt({value:{type:Number,required:!0},format:{type:[String,Object]}},Nf),setup(n,e){const t=n.i18n||rn({useScope:n.scope,__useComponent:!0});return zC(n,e,DC,(...r)=>t[Rh](...r))}}),jv=PM;function MM(n,e){const t=n;if(n.mode==="composition")return t.__getInstance(e)||n.global;{const r=t.__getInstance(e);return r!=null?r.__composer:n.global.__composer}}function DM(n){const e=l=>{process.env.NODE_ENV!=="production"&&Cf(Bs(Ur.DEPRECATE_TRANSLATE_CUSTOME_DIRECTIVE));const{instance:d,value:h}=l;if(!d||!d.$)throw En(rt.UNEXPECTED_ERROR);const f=MM(n,d.$),g=Yv(h);return[Reflect.apply(f.t,f,[...Jv(g)]),f]};return{created:(l,d)=>{const[h,f]=e(d);Tr&&n.global===f&&(l.__i18nWatcher=s.watch(f.locale,()=>{d.instance&&d.instance.$forceUpdate()})),l.__composer=f,l.textContent=h},unmounted:l=>{Tr&&l.__i18nWatcher&&(l.__i18nWatcher(),l.__i18nWatcher=void 0,delete l.__i18nWatcher),l.__composer&&(l.__composer=void 0,delete l.__composer)},beforeUpdate:(l,{value:d})=>{if(l.__composer){const h=l.__composer,f=Yv(d);l.textContent=Reflect.apply(h.t,h,[...Jv(f)])}},getSSRProps:l=>{const[d]=e(l);return{textContent:d}}}}function Yv(n){if(ne(n))return{path:n};if(ke(n)){if(!("path"in n))throw En(rt.REQUIRED_VALUE,"path");return n}else throw En(rt.INVALID_VALUE)}function Jv(n){const{path:e,locale:t,args:r,choice:o,plural:a}=n,l={},d=r||{};return ne(t)&&(l.locale=t),bt(o)&&(l.plural=o),bt(a)&&(l.plural=a),[e,d,l]}function LM(n,e,...t){const r=ke(t[0])?t[0]:{};(Be(r.globalInstall)?r.globalInstall:!0)&&([qv.name,"I18nT"].forEach(a=>n.component(a,qv)),[jv.name,"I18nN"].forEach(a=>n.component(a,jv)),[Xv.name,"I18nD"].forEach(a=>n.component(a,Xv))),n.directive("t",DM(e))}const xM=qr("global-vue-i18n");function UM(n={}){const e=__VUE_I18N_LEGACY_API__&&Be(n.legacy)?n.legacy:__VUE_I18N_LEGACY_API__;process.env.NODE_ENV!=="production"&&e&&Cf(Bs(Ur.DEPRECATE_LEGACY_MODE));const t=Be(n.globalInjection)?n.globalInjection:!0,r=new Map,[o,a]=VM(n,e),l=qr(process.env.NODE_ENV!=="production"?"vue-i18n":"");function d(v){return r.get(v)||null}function h(v,p){r.set(v,p)}function f(v){r.delete(v)}const g={get mode(){return __VUE_I18N_LEGACY_API__&&e?"legacy":"composition"},async install(v,...p){if(process.env.NODE_ENV!=="production"&&(v.__VUE_I18N__=g),v.__VUE_I18N_SYMBOL__=l,v.provide(v.__VUE_I18N_SYMBOL__,g),ke(p[0])){const T=p[0];g.__composerExtend=T.__composerExtend,g.__vueI18nExtend=T.__vueI18nExtend}let w=null;!e&&t&&(w=GM(v,g.global)),__VUE_I18N_FULL_INSTALL__&&LM(v,g,...p),__VUE_I18N_LEGACY_API__&&e&&v.mixin(kM(a,a.__composer,g));const C=v.unmount;if(v.unmount=()=>{w&&w(),g.dispose(),C()},process.env.NODE_ENV!=="production"){if(!await pM(v,g))throw En(rt.CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN);const S=Ef();if(e){const I=a;I.__enableEmitter&&I.__enableEmitter(S)}else{const I=a;I[bi]&&I[bi](S)}S.on("*",Ms)}},get global(){return a},dispose(){o.stop()},__instances:r,__getInstance:d,__setInstance:h,__deleteInstance:f};return g}function rn(n={}){const e=s.getCurrentInstance();if(e==null)throw En(rt.MUST_BE_CALL_SETUP_TOP);if(!e.isCE&&e.appContext.app!=null&&!e.appContext.app.__VUE_I18N_SYMBOL__)throw En(rt.NOT_INSTALLED);const t=BM(e),r=$M(t),o=BC(e),a=FM(n,o);if(a==="global")return FC(r,n,o),r;if(a==="parent"){let h=HM(t,e,n.__useComponent);return h==null&&(process.env.NODE_ENV!=="production"&&jo(Bs(Ur.NOT_FOUND_PARENT_SCOPE)),h=r),h}const l=t;let d=l.__getInstance(e);if(d==null){const h=Pt({},n);"__i18n"in o&&(h.__i18n=o.__i18n),r&&(h.__root=r),d=Af(h),l.__composerExtend&&(d[Ph]=l.__composerExtend(d)),WM(l,e,d),l.__setInstance(e,d)}return d}function VM(n,e){const t=s.effectScope(),r=__VUE_I18N_LEGACY_API__&&e?t.run(()=>Dh(n)):t.run(()=>Af(n));if(r==null)throw En(rt.UNEXPECTED_ERROR);return[t,r]}function BM(n){const e=s.inject(n.isCE?xM:n.appContext.app.__VUE_I18N_SYMBOL__);if(!e)throw En(n.isCE?rt.NOT_INSTALLED_WITH_PROVIDE:rt.UNEXPECTED_ERROR);return e}function FM(n,e){return Gl(n)?"__i18n"in e?"local":"global":n.useScope?n.useScope:"local"}function $M(n){return n.mode==="composition"?n.global:n.global.__composer}function HM(n,e,t=!1){let r=null;const o=e.root;let a=KM(e,t);for(;a!=null;){const l=n;if(n.mode==="composition")r=l.__getInstance(a);else if(__VUE_I18N_LEGACY_API__){const d=l.__getInstance(a);d!=null&&(r=d.__composer,t&&r&&!r[VC]&&(r=null))}if(r!=null||o===a)break;a=a.parent}return r}function KM(n,e=!1){return n==null?null:e&&n.vnode.ctx||n.parent}function WM(n,e,t){let r=null;s.onMounted(()=>{if(process.env.NODE_ENV!=="production"&&e.vnode.el){e.vnode.el.__VUE_I18N__=t,r=Ef();const o=t;o[bi]&&o[bi](r),r.on("*",Ms)}},e),s.onUnmounted(()=>{const o=t;process.env.NODE_ENV!=="production"&&e.vnode.el&&e.vnode.el.__VUE_I18N__&&(r&&r.off("*",Ms),o[Rs]&&o[Rs](),delete e.vnode.el.__VUE_I18N__),n.__deleteInstance(e);const a=o[Ph];a&&(a(),delete o[Ph])},e)}const zM=["locale","fallbackLocale","availableLocales"],Qv=["t","rt","d","n","tm","te"];function GM(n,e){const t=Object.create(null);return zM.forEach(o=>{const a=Object.getOwnPropertyDescriptor(e,o);if(!a)throw En(rt.UNEXPECTED_ERROR);const l=s.isRef(a.value)?{get(){return a.value.value},set(d){a.value.value=d}}:{get(){return a.get&&a.get()}};Object.defineProperty(t,o,l)}),n.config.globalProperties.$i18n=t,Qv.forEach(o=>{const a=Object.getOwnPropertyDescriptor(e,o);if(!a||!a.value)throw En(rt.UNEXPECTED_ERROR);Object.defineProperty(n.config.globalProperties,`$${o}`,a)}),()=>{delete n.config.globalProperties.$i18n,Qv.forEach(o=>{delete n.config.globalProperties[`$${o}`]})}}const qM=s.defineComponent({name:"i18n-d",props:Pt({value:{type:[Number,Date],required:!0},format:{type:[String,Object]}},Nf),setup(n,e){const t=n.i18n||rn({useScope:n.scope,__useComponent:!0});return zC(n,e,MC,(...r)=>t[Oh](...r))}}),Xv=qM;lM();$P(yP);HP(xP);KP(bC);if(process.env.NODE_ENV!=="production"||__INTLIFY_PROD_DEVTOOLS__){const n=vi();n.__INTLIFY__=!0,CP(n.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__)}process.env.NODE_ENV;const Yl=s.defineComponent({__name:"DeleteAllBtn",emits:["removeAll"],setup(n,{emit:e}){const{openDialog:t}=Ra("delete-all-__J"),{t:r}=rn(),o=e;return(a,l)=>(s.openBlock(),s.createElementBlock(s.Fragment,null,[s.createVNode(Pa,{"dd-id":"delete-all-__J",variant:"confirm",title:s.unref(r)("dialogs.deleteAll.title"),text:s.unref(r)("dialogs.deleteAll.text"),onOnSave:l[0]||(l[0]=()=>o("removeAll"))},null,8,["title","text"]),s.createVNode(Me.VBtn,{onClick:s.unref(t),variant:"plain",color:"secondary","prepend-icon":"mdi-delete"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(s.unref(r)("actions.deleteAll")),1)]),_:1},8,["onClick"])],64))}}),GC=s.defineComponent({__name:"EditButton",emits:["editAll"],setup(n,{emit:e}){const t=e;return(r,o)=>(s.openBlock(),s.createBlock(Me.VBtn,{onClick:o[0]||(o[0]=a=>t("editAll")),variant:"plain",color:"secondary","prepend-icon":"mdi-pencil"},{default:s.withCtx(()=>o[1]||(o[1]=[s.createTextVNode(" Edit")])),_:1}))}}),qC=s.defineComponent({__name:"DotsMenu",props:{variant:{default:"text"},color:{},orientation:{},size:{}},setup(n){return(e,t)=>(s.openBlock(),s.createBlock(s.unref(ho.VMenu),{"close-on-content-click":!0},{activator:s.withCtx(({props:r})=>[s.createVNode(s.unref(ho.VBtn),s.mergeProps({variant:e.variant},r,{icon:""}),{default:s.withCtx(()=>[e.orientation==="y"?(s.openBlock(),s.createBlock(s.unref(g1),{key:0,size:e.size,color:`rgb(var(--v-theme-${e.color}))`,class:"cursor-pointer"},null,8,["size","color"])):(s.openBlock(),s.createBlock(s.unref(p1),{key:1,size:e.size,color:`rgb(var(--v-theme-${e.color}))`,class:"cursor-pointer"},null,8,["size","color"]))]),_:2},1040,["variant"])]),default:s.withCtx(()=>[s.renderSlot(e.$slots,"default")]),_:3}))}}),Jl=s.defineComponent({__name:"ParentCard",props:{title:{},height:{default:"100%"},loading:{type:Boolean}},setup(n){const e=n;return(t,r)=>(s.openBlock(),s.createBlock(Ut.VCard,{"min-height":t.height,height:t.height,loading:t.loading,class:"bg-surface rounded-sm pa-5"},{default:s.withCtx(()=>[e.title?(s.openBlock(),s.createBlock(Ut.VCardTitle,{key:0,class:"pa-0"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(e.title),1)]),_:1})):s.createCommentVNode("",!0),s.renderSlot(t.$slots,"default")]),_:3},8,["min-height","height","loading"]))}}),jC=s.defineComponent({__name:"ConfirmDialog",props:{title:{},text:{},width:{},loading:{type:Boolean}},emits:["onSave","onCancel"],setup(n,{emit:e}){const t=n,r=s.ref(!1),o=s.ref(!1);s.onUnmounted(()=>{r.value=!1});const a=e;async function l(){try{await a("onCancel")}catch(h){console.error(h)}r.value=!1}async function d(){o.value=!0;try{await a("onSave")}catch(h){console.error(h)}o.value=!1,r.value=!1}return(h,f)=>(s.openBlock(),s.createBlock(rl.VDialog,{scrim:"rgb(0,0,0,100)",width:t.width},{activator:s.withCtx(({isActive:g,props:v})=>[s.renderSlot(h.$slots,"button",s.normalizeProps(s.guardReactiveProps({isActive:g,props:v})))]),default:s.withCtx(({isActive:g})=>[s.createVNode(Ut.VCard,{loading:o.value,title:t.title,rounded:"","min-height":"300"},{prepend:s.withCtx(()=>[s.createVNode(s.unref(lC),{color:"rgb(var(--v-theme-secondary))"})]),append:s.withCtx(()=>[s.createVNode(Me.VBtn,{class:"ms-auto",icon:"mdi-window-close",onClick:l,variant:"plain"})]),default:s.withCtx(()=>[s.createVNode(Ut.VCardText,{class:"text-center mt-7"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(t.text),1)]),_:1}),s.createVNode(Ut.VCardActions,{class:"d-flex"},{default:s.withCtx(()=>[s.createVNode(Me.VBtn,{class:"flex-grow-1",variant:"outlined",color:"secondary",onClick:l},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(h.$t("actions.cancel")),1)]),_:1}),s.createVNode(Me.VBtn,{class:"flex-grow-1",variant:"flat",color:"secondary",onClick:d},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(h.$t("actions.confirm")),1)]),_:1})]),_:1})]),_:1},8,["loading","title"])]),_:3},8,["width"]))}}),Kd="https://app-files.jplan.com.br/pub/resources/profile-placeholder.svg",YC=s.defineComponent({__name:"JAvatar",props:{src:{}},setup(n){const e=n,t=s.ref(e.src),r=s.computed(()=>t.value||Kd);function o(){t.value=Kd}return(a,l)=>(s.openBlock(),s.createBlock(ky.VAvatar,{size:"50"},{default:s.withCtx(()=>[s.createVNode(Bl.VImg,{src:r.value,"lazy-src":Kd,onError:o,width:"50",alt:"profile-placeholder"},null,8,["src"])]),_:1}))}}),Wd="https://app-files.jplan.com.br/pub/resources/profile-placeholder.svg",JC=s.defineComponent({__name:"AvatarPicture",props:{img:{},size:{}},setup(n){const e=n,t=s.ref(e.img),r=s.computed(()=>t.value||Wd);function o(){t.value=Wd}return(a,l)=>(s.openBlock(),s.createBlock(ky.VAvatar,{size:a.size},{default:s.withCtx(()=>[s.createVNode(Bl.VImg,{src:r.value,"lazy-src":Wd,onError:o,width:"40",alt:"Avatar"},null,8,["src"])]),_:1},8,["size"]))}}),jM=s.defineComponent({__name:"ContextMenu",setup(n){const e=s.ref(!1),t=s.ref({x:0,y:0}),r=a=>{a.preventDefault(),t.value={x:a.clientX,y:a.clientY},e.value=!0},o=()=>{e.value=!1};return s.onMounted(()=>{document.addEventListener("click",o)}),s.onUnmounted(()=>{document.removeEventListener("click",o)}),(a,l)=>(s.openBlock(),s.createElementBlock("div",{onContextmenu:s.withModifiers(r,["right"]),class:"relative w-full h-full"},[s.renderSlot(a.$slots,"default",{},void 0,!0),s.createVNode(Fl.VMenu,{modelValue:e.value,"onUpdate:modelValue":l[0]||(l[0]=d=>e.value=d),style:s.normalizeStyle({top:`${t.value.y}px`,left:`${t.value.x}px`,position:"absolute"})},{default:s.withCtx(()=>[s.createVNode(Tt.VList,{onClick:o},{default:s.withCtx(()=>[s.renderSlot(a.$slots,"actions",{},void 0,!0)]),_:3})]),_:3},8,["modelValue","style"])],32))}}),Qo=(n,e)=>{const t=n.__vccOpts||n;for(const[r,o]of e)t[r]=o;return t},QC=Qo(jM,[["__scopeId","data-v-ad4e4a5d"]]),YM={class:"d-inline-flex"},XC=s.defineComponent({__name:"UiTable",props:s.mergeModels({headers:{},items:{default:()=>[]},actions:{},loading:{type:Boolean},columns:{default:()=>[]},sortBy:{}},{selection:{},selectionModifiers:{}}),emits:["update:selection"],setup(n){const e=n,t=s.computed(()=>{var o;if(e.headers)return e.headers;if(e.columns)return(o=e.columns)==null?void 0:o.filter(a=>a.checked)}),r=s.useModel(n,"selection");return(o,a)=>(s.openBlock(),s.createBlock(ff.VDataTable,{modelValue:r.value,"onUpdate:modelValue":a[0]||(a[0]=l=>r.value=l),"fixed-header":"","fixed-footer":"","items-per-page":"10",headers:t.value,items:o.items,"items-length":o.items.length,loading:o.loading||!1,"item-value":"_id","return-object":"","show-select":"","sort-by":o.sortBy,height:"calc(100vh - 320px)",class:"customize-table"},{top:s.withCtx(()=>a[1]||(a[1]=[s.createElementVNode("span",{class:"mt-5"},null,-1)])),"item.avatar":s.withCtx(({item:l})=>[s.renderSlot(o.$slots,"avatar",{item:l})]),"item.active":s.withCtx(({item:l})=>[s.renderSlot(o.$slots,"active",{item:l})]),"item.image":s.withCtx(({item:l})=>[s.renderSlot(o.$slots,"image",{item:l})]),"item.picture":s.withCtx(({item:l})=>[s.renderSlot(o.$slots,"picture",{item:l})]),"item.icon":s.withCtx(({item:l})=>[s.renderSlot(o.$slots,"icon",{item:l})]),"item.actions":s.withCtx(({item:l})=>[s.createElementVNode("div",YM,[s.renderSlot(o.$slots,"actions",{item:l})])]),"no-data":s.withCtx(()=>[!o.loading&&o.items.length===0?(s.openBlock(),s.createElementBlock(s.Fragment,{key:0},[s.createTextVNode(" This table is empty.")],64)):s.createCommentVNode("",!0)]),_:3},8,["modelValue","headers","items","items-length","loading","sort-by"]))}}),Zv={ptBr:{widget:"widget",spacer:"Espaçador"}},Of={"pt-BR":{placeholders:{selectFilter:"Selecionar filtro",visualize:"Visualizar",actions:"Ações",search:"Pesquisar"},dialogs:{columnSettings:{title:"Configurações de coluna"},scope:{title:"Escopo",unknown:"Desconhecido",domain:"Domínio",environment:"Ambiente",organizational:"Organizacional",organization:"Organização",team:"Time",user:"Usuário",none:"Nenhum",selectOrganization:"Selecione uma Organização",selectTeam:"Selecione um Time"},deleteAll:{title:"Confirme a ação",text:"Tem certeza que deseja apagar todos os selecionados?"}},actions:{save:"Salvar",cancel:"Cancelar",edit:"Editar",delete:"Apagar",disable:"Desabilitar",confirm:"Confirmar",back:"Voltar",deleteAll:"Apagar"},forms:{metadata:{created:"Criado",updated:"Atualizado",modified:"Modificado",delegated:"Delegado"}},$vuetify:{dataFooter:{itemsPerPageAll:"Todos",itemsPerPageText:"Itens por página:",ofText:"de"}},toast:{error:{create_failed:"Falha ao criar {entity}",update_failed:"Falha ao atualizar {entity}",delete_failed:"Falha ao apagar {entity}",fetch_failed:"Falha ao buscar {entity}",activate_failed:"Falha ao ativar {entity}",deactivate_failed:"Falha ao desativar {entity}",link_failed:"Falha ao vincular {entity}",unlink_failed:"Falha ao desvincular {entity}"},success:{create_success:"{entity} criado com sucesso",update_success:"{entity} atualizado com sucesso",delete_success:"{entity} apagado com sucesso",activate_success:"{entity} ativado com sucesso",deactivate_success:"{entity} desativado com sucesso",link_success:"{entity} vinculado com sucesso",unlink_success:"{entity} desvinculado com sucesso"},info:{already_linked:"{entity} já está vinculado",select_valid_item:"Selecione um item válido"}},app:{widget:Zv.ptBr}},"en-US":{placeholders:{selectFilter:"Select a filter",visualize:"Visualize",actions:"Actions",search:"Search"},dialogs:{columnSettings:{title:"Column Settings"},scope:{title:"Scope",unknown:"Unknown",domain:"Domain",environment:"Environment",organizational:"Organizational",organization:"Organization",team:"Team",user:"User",none:"None",selectOrganization:"Select a organization",selectTeam:"Select a Team"},deleteAll:{title:"Confirm action",text:"Are you sure you want to delete all selected items?"}},actions:{save:"Save",cancel:"Cancel",edit:"Edit",delete:"Delete",disable:"Disable",back:"Back",confirm:"Confirm",deleteAll:"Delete"},forms:{metadata:{created:"Created",updated:"Updated",modified:"Modified",delegated:"Delegated"}},$vuetify:{dataFooter:{itemsPerPageAll:"All",itemsPerPageText:"Items per page:",ofText:"of"}},toast:{error:{create_failed:"Failed to create {entity}",update_failed:"Failed to update {entity}",delete_failed:"Failed to delete {entity}",fetch_failed:"Failed to fetch {entity}",activate_failed:"Failed to activate {entity}",deactivate_failed:"Failed to deactivate {entity}",link_failed:"Failed to link {entity}",unlink_failed:"Failed to unlink {entity}"},success:{create_success:"{entity} created successfully",update_success:"{entity} updated successfully",delete_success:"{entity} deleted successfully",activate_success:"{entity} activated successfully",deactivate_success:"{entity} deactivated successfully",link_success:"{entity} linked successfully",unlink_success:"{entity} unlinked successfully"},info:{already_linked:"{entity} is already linked",select_valid_item:"Please select a valid item"}},app:{widget:Zv.ptBr}}},JM=Object.keys(Of),e_=navigator.language,QM=JM.includes(e_)?e_:"pt-BR",W=UM({locale:QM,fallbackLocale:"en-US",messages:Of}),XM={key:0,class:"d-flex mt-4 flex-column align-center justify-center w-100"},ZM={class:"ma-2 pt-1"},eD=["checked"],tD={class:"d-inline-flex"},nD={class:"ma-2 pt-1"},rD=["onUpdate:modelValue"],oD={class:"d-inline-flex align-end"},t_="/assets/empty_placeholder.svg",ZC=s.defineComponent({__name:"TableFlash",props:{headers:{default:()=>[]},items:{default:()=>[]},actions:{},loading:{type:Boolean},sortBy:{},customFields:{},search:{},filterKeys:{},selectOnRowClick:{type:Boolean},footer:{default:()=>({itemsPerPageStart:50,itemsPerPageOptions:[{value:50,title:"50"},{value:100,title:"100"},{value:500,title:"500"},{value:1e3,title:"1000"},{value:-1,title:W.global.t("$vuetify.dataFooter.itemsPerPageAll")}]})}},emits:["rowClick","update:selection","getSelection"],setup(n,{expose:e,emit:t}){var L;const r=n,o=t;e({getSelection:S});const a=s.shallowRef(1),l=s.shallowRef(((L=r.footer)==null?void 0:L.itemsPerPageStart)??50),d=s.ref(!1),h=s.ref({x:0,y:0}),f=s.ref(null),g=s.ref(null),v=s.ref(null),p=s.reactive({}),w=s.computed(()=>!r.items.length||l.value===-1?1:Math.ceil(r.items.length/l.value)),C=s.computed(()=>{if(a.value>w.value&&(a.value=1),l.value===-1)return r.items;const U=(a.value-1)*l.value,F=U+l.value;return r.items.slice(U,F)}),T=s.computed(()=>C.value.length===0?!1:C.value.every(U=>p[U.id]));s.watch(C,()=>{le.value&&setTimeout(()=>{le.value=!1},0)});function S(){const U=[];for(const F of r.items)p[F.id]&&U.push(F);return U}const I=(U,{item:F})=>{U.preventDefault(),f.value=F,h.value={x:U.clientX,y:U.clientY},d.value?(d.value=!1,s.nextTick(()=>{d.value=!0})):d.value=!0};function N(U,{item:F}){o("rowClick",F),r.selectOnRowClick&&(p[F.id]=!p[F.id])}function D(){const U=!T.value;for(const F of C.value)p[F.id]=U}return(U,F)=>!U.loading&&U.items.length===0?(s.openBlock(),s.createElementBlock("div",XM,[s.createVNode(Bl.VImg,{"lazy-src":t_,src:t_,height:"600",width:"600"}),F[5]||(F[5]=s.createElementVNode("p",{class:"text-center text-body-1 w-100"},"No records found.",-1))])):(s.openBlock(),s.createElementBlock("div",{key:1,ref_key:"rootRef",ref:v,class:"d-flex flex-column mt-4",style:{height:"calc(100vh - 260px)"}},[s.withDirectives(s.createElementVNode("div",{ref_key:"activatorRef",ref:g,style:s.normalizeStyle({position:"fixed",left:h.value.x+"px",top:h.value.y+"px",zIndex:9999,pointerEvents:"none"})},null,4),[[s.vShow,d.value]]),s.createVNode(Fl.VMenu,{modelValue:d.value,"onUpdate:modelValue":F[0]||(F[0]=R=>d.value=R),attach:v.value||void 0,activator:g.value||void 0,"location-strategy":"connected","scroll-strategy":"block","min-width":"350"},{default:s.withCtx(()=>[s.renderSlot(U.$slots,"contextmenu",{item:f.value})]),_:3},8,["modelValue","attach","activator"]),s.createElementVNode("div",{class:s.normalizeClass(["d-flex flex-column",{"d-none":s.unref(le)}])},[s.withMemo([C.value],()=>s.createVNode(ff.VDataTableVirtual,{"show-select":"","fixed-header":"","return-object":"",headers:U.headers,items:C.value,"items-length":U.items.length,loading:U.loading||!1,"sort-by":U.sortBy,search:U.search,"filter-keys":U.filterKeys,class:"customize-table virtual-table bg-containerBg",height:"calc(100vh - 320px)","onContextmenu:row":I,"onClick:row":N},s.createSlots({"header.data-table-select":s.withCtx(()=>[s.createElementVNode("div",ZM,[s.createElementVNode("input",{type:"checkbox",checked:T.value,onChange:D,class:"j-checkbox"},null,40,eD)])]),"item.data-table-select":s.withCtx(({item:R})=>[s.createElementVNode("div",nD,[s.withDirectives(s.createElementVNode("input",{type:"checkbox","onUpdate:modelValue":ae=>p[R.id]=ae,onClick:F[1]||(F[1]=s.withModifiers(()=>{},["stop"])),class:"j-checkbox"},null,8,rD),[[s.vModelCheckbox,p[R.id]]])])]),"item.actions":s.withCtx(({item:R})=>[s.createElementVNode("div",oD,[s.renderSlot(U.$slots,"actions",{item:R})])]),"no-data":s.withCtx(()=>[F[6]||(F[6]=s.createElementVNode("p",null,"No results found.",-1))]),_:2},[s.renderList(U.customFields,R=>({name:`item.${R}`,fn:s.withCtx(({item:ae})=>[s.createElementVNode("div",tD,[s.renderSlot(U.$slots,R,{item:ae})])])}))]),1032,["headers","items","items-length","loading","sort-by","search","filter-keys"]),F,2)],2),s.createVNode(s.unref(Df),{itemsPerPage:l.value,"onUpdate:itemsPerPage":F[3]||(F[3]=R=>l.value=R),page:a.value,"onUpdate:page":F[4]||(F[4]=R=>a.value=R),"items-per-page-options":U.footer.itemsPerPageOptions??[],"page-count":w.value,"items-length":U.items.length},null,8,["itemsPerPage","page","items-per-page-options","page-count","items-length"])],512))}});var $c=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function iD(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var ds={exports:{}};/**
|
|
33
|
+
* @license
|
|
34
|
+
* Lodash <https://lodash.com/>
|
|
35
|
+
* Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
|
|
36
|
+
* Released under MIT license <https://lodash.com/license>
|
|
37
|
+
* Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
|
|
38
|
+
* Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
|
|
39
|
+
*/var aD=ds.exports,n_;function sD(){return n_||(n_=1,function(n,e){(function(){var t,r="4.17.21",o=200,a="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",l="Expected a function",d="Invalid `variable` option passed into `_.template`",h="__lodash_hash_undefined__",f=500,g="__lodash_placeholder__",v=1,p=2,w=4,C=1,T=2,S=1,I=2,N=4,D=8,L=16,U=32,F=64,R=128,ae=256,se=512,X=30,ee="...",de=800,Fe=16,Ct=1,on=2,jt=3,Dt=1/0,at=9007199254740991,Et=17976931348623157e292,an=NaN,At=4294967295,Xo=At-1,Fa=At>>>1,$a=[["ary",R],["bind",S],["bindKey",I],["curry",D],["curryRight",L],["flip",se],["partial",U],["partialRight",F],["rearg",ae]],Ar="[object Arguments]",Zo="[object Array]",Ha="[object AsyncFunction]",kr="[object Boolean]",jr="[object Date]",Ka="[object DOMException]",Co="[object Error]",Eo="[object Function]",wo="[object GeneratorFunction]",Ft="[object Map]",wn="[object Number]",ei="[object Null]",Tn="[object Object]",k="[object Promise]",O="[object Proxy]",q="[object RegExp]",oe="[object Set]",Je="[object String]",et="[object Symbol]",De="[object Undefined]",H="[object WeakMap]",J="[object WeakSet]",Ne="[object ArrayBuffer]",qe="[object DataView]",cr="[object Float32Array]",To="[object Float64Array]",Nr="[object Int8Array]",lr="[object Int16Array]",Wa="[object Int32Array]",Mi="[object Uint8Array]",Eu="[object Uint8ClampedArray]",wu="[object Uint16Array]",Tu="[object Uint32Array]",ZT=/\b__p \+= '';/g,eb=/\b(__p \+=) '' \+/g,tb=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Om=/&(?:amp|lt|gt|quot|#39);/g,Rm=/[&<>"']/g,nb=RegExp(Om.source),rb=RegExp(Rm.source),ob=/<%-([\s\S]+?)%>/g,ib=/<%([\s\S]+?)%>/g,Pm=/<%=([\s\S]+?)%>/g,ab=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,sb=/^\w*$/,cb=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,bu=/[\\^$.*+?()[\]{}|]/g,lb=RegExp(bu.source),Su=/^\s+/,ub=/\s/,db=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,hb=/\{\n\/\* \[wrapped with (.+)\] \*/,fb=/,? & /,mb=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,gb=/[()=,{}\[\]\/\s]/,pb=/\\(\\)?/g,vb=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Mm=/\w*$/,_b=/^[-+]0x[0-9a-f]+$/i,yb=/^0b[01]+$/i,Cb=/^\[object .+?Constructor\]$/,Eb=/^0o[0-7]+$/i,wb=/^(?:0|[1-9]\d*)$/,Tb=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Ys=/($^)/,bb=/['\n\r\u2028\u2029\\]/g,Js="\\ud800-\\udfff",Sb="\\u0300-\\u036f",Ib="\\ufe20-\\ufe2f",Ab="\\u20d0-\\u20ff",Dm=Sb+Ib+Ab,Lm="\\u2700-\\u27bf",xm="a-z\\xdf-\\xf6\\xf8-\\xff",kb="\\xac\\xb1\\xd7\\xf7",Nb="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",Ob="\\u2000-\\u206f",Rb=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Um="A-Z\\xc0-\\xd6\\xd8-\\xde",Vm="\\ufe0e\\ufe0f",Bm=kb+Nb+Ob+Rb,Iu="['’]",Pb="["+Js+"]",Fm="["+Bm+"]",Qs="["+Dm+"]",$m="\\d+",Mb="["+Lm+"]",Hm="["+xm+"]",Km="[^"+Js+Bm+$m+Lm+xm+Um+"]",Au="\\ud83c[\\udffb-\\udfff]",Db="(?:"+Qs+"|"+Au+")",Wm="[^"+Js+"]",ku="(?:\\ud83c[\\udde6-\\uddff]){2}",Nu="[\\ud800-\\udbff][\\udc00-\\udfff]",Di="["+Um+"]",zm="\\u200d",Gm="(?:"+Hm+"|"+Km+")",Lb="(?:"+Di+"|"+Km+")",qm="(?:"+Iu+"(?:d|ll|m|re|s|t|ve))?",jm="(?:"+Iu+"(?:D|LL|M|RE|S|T|VE))?",Ym=Db+"?",Jm="["+Vm+"]?",xb="(?:"+zm+"(?:"+[Wm,ku,Nu].join("|")+")"+Jm+Ym+")*",Ub="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Vb="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Qm=Jm+Ym+xb,Bb="(?:"+[Mb,ku,Nu].join("|")+")"+Qm,Fb="(?:"+[Wm+Qs+"?",Qs,ku,Nu,Pb].join("|")+")",$b=RegExp(Iu,"g"),Hb=RegExp(Qs,"g"),Ou=RegExp(Au+"(?="+Au+")|"+Fb+Qm,"g"),Kb=RegExp([Di+"?"+Hm+"+"+qm+"(?="+[Fm,Di,"$"].join("|")+")",Lb+"+"+jm+"(?="+[Fm,Di+Gm,"$"].join("|")+")",Di+"?"+Gm+"+"+qm,Di+"+"+jm,Vb,Ub,$m,Bb].join("|"),"g"),Wb=RegExp("["+zm+Js+Dm+Vm+"]"),zb=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Gb=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],qb=-1,ot={};ot[cr]=ot[To]=ot[Nr]=ot[lr]=ot[Wa]=ot[Mi]=ot[Eu]=ot[wu]=ot[Tu]=!0,ot[Ar]=ot[Zo]=ot[Ne]=ot[kr]=ot[qe]=ot[jr]=ot[Co]=ot[Eo]=ot[Ft]=ot[wn]=ot[Tn]=ot[q]=ot[oe]=ot[Je]=ot[H]=!1;var tt={};tt[Ar]=tt[Zo]=tt[Ne]=tt[qe]=tt[kr]=tt[jr]=tt[cr]=tt[To]=tt[Nr]=tt[lr]=tt[Wa]=tt[Ft]=tt[wn]=tt[Tn]=tt[q]=tt[oe]=tt[Je]=tt[et]=tt[Mi]=tt[Eu]=tt[wu]=tt[Tu]=!0,tt[Co]=tt[Eo]=tt[H]=!1;var jb={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},Yb={"&":"&","<":"<",">":">",'"':""","'":"'"},Jb={"&":"&","<":"<",">":">",""":'"',"'":"'"},Qb={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Xb=parseFloat,Zb=parseInt,Xm=typeof $c=="object"&&$c&&$c.Object===Object&&$c,eS=typeof self=="object"&&self&&self.Object===Object&&self,$t=Xm||eS||Function("return this")(),Ru=e&&!e.nodeType&&e,ti=Ru&&!0&&n&&!n.nodeType&&n,Zm=ti&&ti.exports===Ru,Pu=Zm&&Xm.process,$n=function(){try{var P=ti&&ti.require&&ti.require("util").types;return P||Pu&&Pu.binding&&Pu.binding("util")}catch{}}(),eg=$n&&$n.isArrayBuffer,tg=$n&&$n.isDate,ng=$n&&$n.isMap,rg=$n&&$n.isRegExp,og=$n&&$n.isSet,ig=$n&&$n.isTypedArray;function bn(P,K,V){switch(V.length){case 0:return P.call(K);case 1:return P.call(K,V[0]);case 2:return P.call(K,V[0],V[1]);case 3:return P.call(K,V[0],V[1],V[2])}return P.apply(K,V)}function tS(P,K,V,re){for(var Ce=-1,$e=P==null?0:P.length;++Ce<$e;){var kt=P[Ce];K(re,kt,V(kt),P)}return re}function Hn(P,K){for(var V=-1,re=P==null?0:P.length;++V<re&&K(P[V],V,P)!==!1;);return P}function nS(P,K){for(var V=P==null?0:P.length;V--&&K(P[V],V,P)!==!1;);return P}function ag(P,K){for(var V=-1,re=P==null?0:P.length;++V<re;)if(!K(P[V],V,P))return!1;return!0}function bo(P,K){for(var V=-1,re=P==null?0:P.length,Ce=0,$e=[];++V<re;){var kt=P[V];K(kt,V,P)&&($e[Ce++]=kt)}return $e}function Xs(P,K){var V=P==null?0:P.length;return!!V&&Li(P,K,0)>-1}function Mu(P,K,V){for(var re=-1,Ce=P==null?0:P.length;++re<Ce;)if(V(K,P[re]))return!0;return!1}function st(P,K){for(var V=-1,re=P==null?0:P.length,Ce=Array(re);++V<re;)Ce[V]=K(P[V],V,P);return Ce}function So(P,K){for(var V=-1,re=K.length,Ce=P.length;++V<re;)P[Ce+V]=K[V];return P}function Du(P,K,V,re){var Ce=-1,$e=P==null?0:P.length;for(re&&$e&&(V=P[++Ce]);++Ce<$e;)V=K(V,P[Ce],Ce,P);return V}function rS(P,K,V,re){var Ce=P==null?0:P.length;for(re&&Ce&&(V=P[--Ce]);Ce--;)V=K(V,P[Ce],Ce,P);return V}function Lu(P,K){for(var V=-1,re=P==null?0:P.length;++V<re;)if(K(P[V],V,P))return!0;return!1}var oS=xu("length");function iS(P){return P.split("")}function aS(P){return P.match(mb)||[]}function sg(P,K,V){var re;return V(P,function(Ce,$e,kt){if(K(Ce,$e,kt))return re=$e,!1}),re}function Zs(P,K,V,re){for(var Ce=P.length,$e=V+(re?1:-1);re?$e--:++$e<Ce;)if(K(P[$e],$e,P))return $e;return-1}function Li(P,K,V){return K===K?_S(P,K,V):Zs(P,cg,V)}function sS(P,K,V,re){for(var Ce=V-1,$e=P.length;++Ce<$e;)if(re(P[Ce],K))return Ce;return-1}function cg(P){return P!==P}function lg(P,K){var V=P==null?0:P.length;return V?Vu(P,K)/V:an}function xu(P){return function(K){return K==null?t:K[P]}}function Uu(P){return function(K){return P==null?t:P[K]}}function ug(P,K,V,re,Ce){return Ce(P,function($e,kt,Qe){V=re?(re=!1,$e):K(V,$e,kt,Qe)}),V}function cS(P,K){var V=P.length;for(P.sort(K);V--;)P[V]=P[V].value;return P}function Vu(P,K){for(var V,re=-1,Ce=P.length;++re<Ce;){var $e=K(P[re]);$e!==t&&(V=V===t?$e:V+$e)}return V}function Bu(P,K){for(var V=-1,re=Array(P);++V<P;)re[V]=K(V);return re}function lS(P,K){return st(K,function(V){return[V,P[V]]})}function dg(P){return P&&P.slice(0,gg(P)+1).replace(Su,"")}function Sn(P){return function(K){return P(K)}}function Fu(P,K){return st(K,function(V){return P[V]})}function za(P,K){return P.has(K)}function hg(P,K){for(var V=-1,re=P.length;++V<re&&Li(K,P[V],0)>-1;);return V}function fg(P,K){for(var V=P.length;V--&&Li(K,P[V],0)>-1;);return V}function uS(P,K){for(var V=P.length,re=0;V--;)P[V]===K&&++re;return re}var dS=Uu(jb),hS=Uu(Yb);function fS(P){return"\\"+Qb[P]}function mS(P,K){return P==null?t:P[K]}function xi(P){return Wb.test(P)}function gS(P){return zb.test(P)}function pS(P){for(var K,V=[];!(K=P.next()).done;)V.push(K.value);return V}function $u(P){var K=-1,V=Array(P.size);return P.forEach(function(re,Ce){V[++K]=[Ce,re]}),V}function mg(P,K){return function(V){return P(K(V))}}function Io(P,K){for(var V=-1,re=P.length,Ce=0,$e=[];++V<re;){var kt=P[V];(kt===K||kt===g)&&(P[V]=g,$e[Ce++]=V)}return $e}function ec(P){var K=-1,V=Array(P.size);return P.forEach(function(re){V[++K]=re}),V}function vS(P){var K=-1,V=Array(P.size);return P.forEach(function(re){V[++K]=[re,re]}),V}function _S(P,K,V){for(var re=V-1,Ce=P.length;++re<Ce;)if(P[re]===K)return re;return-1}function yS(P,K,V){for(var re=V+1;re--;)if(P[re]===K)return re;return re}function Ui(P){return xi(P)?ES(P):oS(P)}function ur(P){return xi(P)?wS(P):iS(P)}function gg(P){for(var K=P.length;K--&&ub.test(P.charAt(K)););return K}var CS=Uu(Jb);function ES(P){for(var K=Ou.lastIndex=0;Ou.test(P);)++K;return K}function wS(P){return P.match(Ou)||[]}function TS(P){return P.match(Kb)||[]}var bS=function P(K){K=K==null?$t:Vi.defaults($t.Object(),K,Vi.pick($t,Gb));var V=K.Array,re=K.Date,Ce=K.Error,$e=K.Function,kt=K.Math,Qe=K.Object,Hu=K.RegExp,SS=K.String,Kn=K.TypeError,tc=V.prototype,IS=$e.prototype,Bi=Qe.prototype,nc=K["__core-js_shared__"],rc=IS.toString,We=Bi.hasOwnProperty,AS=0,pg=function(){var i=/[^.]+$/.exec(nc&&nc.keys&&nc.keys.IE_PROTO||"");return i?"Symbol(src)_1."+i:""}(),oc=Bi.toString,kS=rc.call(Qe),NS=$t._,OS=Hu("^"+rc.call(We).replace(bu,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),ic=Zm?K.Buffer:t,Ao=K.Symbol,ac=K.Uint8Array,vg=ic?ic.allocUnsafe:t,sc=mg(Qe.getPrototypeOf,Qe),_g=Qe.create,yg=Bi.propertyIsEnumerable,cc=tc.splice,Cg=Ao?Ao.isConcatSpreadable:t,Ga=Ao?Ao.iterator:t,ni=Ao?Ao.toStringTag:t,lc=function(){try{var i=si(Qe,"defineProperty");return i({},"",{}),i}catch{}}(),RS=K.clearTimeout!==$t.clearTimeout&&K.clearTimeout,PS=re&&re.now!==$t.Date.now&&re.now,MS=K.setTimeout!==$t.setTimeout&&K.setTimeout,uc=kt.ceil,dc=kt.floor,Ku=Qe.getOwnPropertySymbols,DS=ic?ic.isBuffer:t,Eg=K.isFinite,LS=tc.join,xS=mg(Qe.keys,Qe),Nt=kt.max,Yt=kt.min,US=re.now,VS=K.parseInt,wg=kt.random,BS=tc.reverse,Wu=si(K,"DataView"),qa=si(K,"Map"),zu=si(K,"Promise"),Fi=si(K,"Set"),ja=si(K,"WeakMap"),Ya=si(Qe,"create"),hc=ja&&new ja,$i={},FS=ci(Wu),$S=ci(qa),HS=ci(zu),KS=ci(Fi),WS=ci(ja),fc=Ao?Ao.prototype:t,Ja=fc?fc.valueOf:t,Tg=fc?fc.toString:t;function y(i){if(dt(i)&&!Ee(i)&&!(i instanceof Re)){if(i instanceof Wn)return i;if(We.call(i,"__wrapped__"))return bp(i)}return new Wn(i)}var Hi=function(){function i(){}return function(c){if(!ut(c))return{};if(_g)return _g(c);i.prototype=c;var u=new i;return i.prototype=t,u}}();function mc(){}function Wn(i,c){this.__wrapped__=i,this.__actions__=[],this.__chain__=!!c,this.__index__=0,this.__values__=t}y.templateSettings={escape:ob,evaluate:ib,interpolate:Pm,variable:"",imports:{_:y}},y.prototype=mc.prototype,y.prototype.constructor=y,Wn.prototype=Hi(mc.prototype),Wn.prototype.constructor=Wn;function Re(i){this.__wrapped__=i,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=At,this.__views__=[]}function zS(){var i=new Re(this.__wrapped__);return i.__actions__=fn(this.__actions__),i.__dir__=this.__dir__,i.__filtered__=this.__filtered__,i.__iteratees__=fn(this.__iteratees__),i.__takeCount__=this.__takeCount__,i.__views__=fn(this.__views__),i}function GS(){if(this.__filtered__){var i=new Re(this);i.__dir__=-1,i.__filtered__=!0}else i=this.clone(),i.__dir__*=-1;return i}function qS(){var i=this.__wrapped__.value(),c=this.__dir__,u=Ee(i),m=c<0,_=u?i.length:0,E=iA(0,_,this.__views__),b=E.start,A=E.end,M=A-b,z=m?A:b-1,G=this.__iteratees__,j=G.length,te=0,ce=Yt(M,this.__takeCount__);if(!u||!m&&_==M&&ce==M)return qg(i,this.__actions__);var fe=[];e:for(;M--&&te<ce;){z+=c;for(var Se=-1,me=i[z];++Se<j;){var Oe=G[Se],Pe=Oe.iteratee,kn=Oe.type,ln=Pe(me);if(kn==on)me=ln;else if(!ln){if(kn==Ct)continue e;break e}}fe[te++]=me}return fe}Re.prototype=Hi(mc.prototype),Re.prototype.constructor=Re;function ri(i){var c=-1,u=i==null?0:i.length;for(this.clear();++c<u;){var m=i[c];this.set(m[0],m[1])}}function jS(){this.__data__=Ya?Ya(null):{},this.size=0}function YS(i){var c=this.has(i)&&delete this.__data__[i];return this.size-=c?1:0,c}function JS(i){var c=this.__data__;if(Ya){var u=c[i];return u===h?t:u}return We.call(c,i)?c[i]:t}function QS(i){var c=this.__data__;return Ya?c[i]!==t:We.call(c,i)}function XS(i,c){var u=this.__data__;return this.size+=this.has(i)?0:1,u[i]=Ya&&c===t?h:c,this}ri.prototype.clear=jS,ri.prototype.delete=YS,ri.prototype.get=JS,ri.prototype.has=QS,ri.prototype.set=XS;function Yr(i){var c=-1,u=i==null?0:i.length;for(this.clear();++c<u;){var m=i[c];this.set(m[0],m[1])}}function ZS(){this.__data__=[],this.size=0}function eI(i){var c=this.__data__,u=gc(c,i);if(u<0)return!1;var m=c.length-1;return u==m?c.pop():cc.call(c,u,1),--this.size,!0}function tI(i){var c=this.__data__,u=gc(c,i);return u<0?t:c[u][1]}function nI(i){return gc(this.__data__,i)>-1}function rI(i,c){var u=this.__data__,m=gc(u,i);return m<0?(++this.size,u.push([i,c])):u[m][1]=c,this}Yr.prototype.clear=ZS,Yr.prototype.delete=eI,Yr.prototype.get=tI,Yr.prototype.has=nI,Yr.prototype.set=rI;function Jr(i){var c=-1,u=i==null?0:i.length;for(this.clear();++c<u;){var m=i[c];this.set(m[0],m[1])}}function oI(){this.size=0,this.__data__={hash:new ri,map:new(qa||Yr),string:new ri}}function iI(i){var c=Ac(this,i).delete(i);return this.size-=c?1:0,c}function aI(i){return Ac(this,i).get(i)}function sI(i){return Ac(this,i).has(i)}function cI(i,c){var u=Ac(this,i),m=u.size;return u.set(i,c),this.size+=u.size==m?0:1,this}Jr.prototype.clear=oI,Jr.prototype.delete=iI,Jr.prototype.get=aI,Jr.prototype.has=sI,Jr.prototype.set=cI;function oi(i){var c=-1,u=i==null?0:i.length;for(this.__data__=new Jr;++c<u;)this.add(i[c])}function lI(i){return this.__data__.set(i,h),this}function uI(i){return this.__data__.has(i)}oi.prototype.add=oi.prototype.push=lI,oi.prototype.has=uI;function dr(i){var c=this.__data__=new Yr(i);this.size=c.size}function dI(){this.__data__=new Yr,this.size=0}function hI(i){var c=this.__data__,u=c.delete(i);return this.size=c.size,u}function fI(i){return this.__data__.get(i)}function mI(i){return this.__data__.has(i)}function gI(i,c){var u=this.__data__;if(u instanceof Yr){var m=u.__data__;if(!qa||m.length<o-1)return m.push([i,c]),this.size=++u.size,this;u=this.__data__=new Jr(m)}return u.set(i,c),this.size=u.size,this}dr.prototype.clear=dI,dr.prototype.delete=hI,dr.prototype.get=fI,dr.prototype.has=mI,dr.prototype.set=gI;function bg(i,c){var u=Ee(i),m=!u&&li(i),_=!u&&!m&&Po(i),E=!u&&!m&&!_&&Gi(i),b=u||m||_||E,A=b?Bu(i.length,SS):[],M=A.length;for(var z in i)(c||We.call(i,z))&&!(b&&(z=="length"||_&&(z=="offset"||z=="parent")||E&&(z=="buffer"||z=="byteLength"||z=="byteOffset")||eo(z,M)))&&A.push(z);return A}function Sg(i){var c=i.length;return c?i[nd(0,c-1)]:t}function pI(i,c){return kc(fn(i),ii(c,0,i.length))}function vI(i){return kc(fn(i))}function Gu(i,c,u){(u!==t&&!hr(i[c],u)||u===t&&!(c in i))&&Qr(i,c,u)}function Qa(i,c,u){var m=i[c];(!(We.call(i,c)&&hr(m,u))||u===t&&!(c in i))&&Qr(i,c,u)}function gc(i,c){for(var u=i.length;u--;)if(hr(i[u][0],c))return u;return-1}function _I(i,c,u,m){return ko(i,function(_,E,b){c(m,_,u(_),b)}),m}function Ig(i,c){return i&&Rr(c,Lt(c),i)}function yI(i,c){return i&&Rr(c,gn(c),i)}function Qr(i,c,u){c=="__proto__"&&lc?lc(i,c,{configurable:!0,enumerable:!0,value:u,writable:!0}):i[c]=u}function qu(i,c){for(var u=-1,m=c.length,_=V(m),E=i==null;++u<m;)_[u]=E?t:Ad(i,c[u]);return _}function ii(i,c,u){return i===i&&(u!==t&&(i=i<=u?i:u),c!==t&&(i=i>=c?i:c)),i}function zn(i,c,u,m,_,E){var b,A=c&v,M=c&p,z=c&w;if(u&&(b=_?u(i,m,_,E):u(i)),b!==t)return b;if(!ut(i))return i;var G=Ee(i);if(G){if(b=sA(i),!A)return fn(i,b)}else{var j=Jt(i),te=j==Eo||j==wo;if(Po(i))return Jg(i,A);if(j==Tn||j==Ar||te&&!_){if(b=M||te?{}:gp(i),!A)return M?JI(i,yI(b,i)):YI(i,Ig(b,i))}else{if(!tt[j])return _?i:{};b=cA(i,j,A)}}E||(E=new dr);var ce=E.get(i);if(ce)return ce;E.set(i,b),Wp(i)?i.forEach(function(me){b.add(zn(me,c,u,me,i,E))}):Hp(i)&&i.forEach(function(me,Oe){b.set(Oe,zn(me,c,u,Oe,i,E))});var fe=z?M?fd:hd:M?gn:Lt,Se=G?t:fe(i);return Hn(Se||i,function(me,Oe){Se&&(Oe=me,me=i[Oe]),Qa(b,Oe,zn(me,c,u,Oe,i,E))}),b}function CI(i){var c=Lt(i);return function(u){return Ag(u,i,c)}}function Ag(i,c,u){var m=u.length;if(i==null)return!m;for(i=Qe(i);m--;){var _=u[m],E=c[_],b=i[_];if(b===t&&!(_ in i)||!E(b))return!1}return!0}function kg(i,c,u){if(typeof i!="function")throw new Kn(l);return os(function(){i.apply(t,u)},c)}function Xa(i,c,u,m){var _=-1,E=Xs,b=!0,A=i.length,M=[],z=c.length;if(!A)return M;u&&(c=st(c,Sn(u))),m?(E=Mu,b=!1):c.length>=o&&(E=za,b=!1,c=new oi(c));e:for(;++_<A;){var G=i[_],j=u==null?G:u(G);if(G=m||G!==0?G:0,b&&j===j){for(var te=z;te--;)if(c[te]===j)continue e;M.push(G)}else E(c,j,m)||M.push(G)}return M}var ko=tp(Or),Ng=tp(Yu,!0);function EI(i,c){var u=!0;return ko(i,function(m,_,E){return u=!!c(m,_,E),u}),u}function pc(i,c,u){for(var m=-1,_=i.length;++m<_;){var E=i[m],b=c(E);if(b!=null&&(A===t?b===b&&!An(b):u(b,A)))var A=b,M=E}return M}function wI(i,c,u,m){var _=i.length;for(u=be(u),u<0&&(u=-u>_?0:_+u),m=m===t||m>_?_:be(m),m<0&&(m+=_),m=u>m?0:Gp(m);u<m;)i[u++]=c;return i}function Og(i,c){var u=[];return ko(i,function(m,_,E){c(m,_,E)&&u.push(m)}),u}function Ht(i,c,u,m,_){var E=-1,b=i.length;for(u||(u=uA),_||(_=[]);++E<b;){var A=i[E];c>0&&u(A)?c>1?Ht(A,c-1,u,m,_):So(_,A):m||(_[_.length]=A)}return _}var ju=np(),Rg=np(!0);function Or(i,c){return i&&ju(i,c,Lt)}function Yu(i,c){return i&&Rg(i,c,Lt)}function vc(i,c){return bo(c,function(u){return to(i[u])})}function ai(i,c){c=Oo(c,i);for(var u=0,m=c.length;i!=null&&u<m;)i=i[Pr(c[u++])];return u&&u==m?i:t}function Pg(i,c,u){var m=c(i);return Ee(i)?m:So(m,u(i))}function sn(i){return i==null?i===t?De:ei:ni&&ni in Qe(i)?oA(i):vA(i)}function Ju(i,c){return i>c}function TI(i,c){return i!=null&&We.call(i,c)}function bI(i,c){return i!=null&&c in Qe(i)}function SI(i,c,u){return i>=Yt(c,u)&&i<Nt(c,u)}function Qu(i,c,u){for(var m=u?Mu:Xs,_=i[0].length,E=i.length,b=E,A=V(E),M=1/0,z=[];b--;){var G=i[b];b&&c&&(G=st(G,Sn(c))),M=Yt(G.length,M),A[b]=!u&&(c||_>=120&&G.length>=120)?new oi(b&&G):t}G=i[0];var j=-1,te=A[0];e:for(;++j<_&&z.length<M;){var ce=G[j],fe=c?c(ce):ce;if(ce=u||ce!==0?ce:0,!(te?za(te,fe):m(z,fe,u))){for(b=E;--b;){var Se=A[b];if(!(Se?za(Se,fe):m(i[b],fe,u)))continue e}te&&te.push(fe),z.push(ce)}}return z}function II(i,c,u,m){return Or(i,function(_,E,b){c(m,u(_),E,b)}),m}function Za(i,c,u){c=Oo(c,i),i=yp(i,c);var m=i==null?i:i[Pr(qn(c))];return m==null?t:bn(m,i,u)}function Mg(i){return dt(i)&&sn(i)==Ar}function AI(i){return dt(i)&&sn(i)==Ne}function kI(i){return dt(i)&&sn(i)==jr}function es(i,c,u,m,_){return i===c?!0:i==null||c==null||!dt(i)&&!dt(c)?i!==i&&c!==c:NI(i,c,u,m,es,_)}function NI(i,c,u,m,_,E){var b=Ee(i),A=Ee(c),M=b?Zo:Jt(i),z=A?Zo:Jt(c);M=M==Ar?Tn:M,z=z==Ar?Tn:z;var G=M==Tn,j=z==Tn,te=M==z;if(te&&Po(i)){if(!Po(c))return!1;b=!0,G=!1}if(te&&!G)return E||(E=new dr),b||Gi(i)?hp(i,c,u,m,_,E):nA(i,c,M,u,m,_,E);if(!(u&C)){var ce=G&&We.call(i,"__wrapped__"),fe=j&&We.call(c,"__wrapped__");if(ce||fe){var Se=ce?i.value():i,me=fe?c.value():c;return E||(E=new dr),_(Se,me,u,m,E)}}return te?(E||(E=new dr),rA(i,c,u,m,_,E)):!1}function OI(i){return dt(i)&&Jt(i)==Ft}function Xu(i,c,u,m){var _=u.length,E=_,b=!m;if(i==null)return!E;for(i=Qe(i);_--;){var A=u[_];if(b&&A[2]?A[1]!==i[A[0]]:!(A[0]in i))return!1}for(;++_<E;){A=u[_];var M=A[0],z=i[M],G=A[1];if(b&&A[2]){if(z===t&&!(M in i))return!1}else{var j=new dr;if(m)var te=m(z,G,M,i,c,j);if(!(te===t?es(G,z,C|T,m,j):te))return!1}}return!0}function Dg(i){if(!ut(i)||hA(i))return!1;var c=to(i)?OS:Cb;return c.test(ci(i))}function RI(i){return dt(i)&&sn(i)==q}function PI(i){return dt(i)&&Jt(i)==oe}function MI(i){return dt(i)&&Dc(i.length)&&!!ot[sn(i)]}function Lg(i){return typeof i=="function"?i:i==null?pn:typeof i=="object"?Ee(i)?Vg(i[0],i[1]):Ug(i):rv(i)}function Zu(i){if(!rs(i))return xS(i);var c=[];for(var u in Qe(i))We.call(i,u)&&u!="constructor"&&c.push(u);return c}function DI(i){if(!ut(i))return pA(i);var c=rs(i),u=[];for(var m in i)m=="constructor"&&(c||!We.call(i,m))||u.push(m);return u}function ed(i,c){return i<c}function xg(i,c){var u=-1,m=mn(i)?V(i.length):[];return ko(i,function(_,E,b){m[++u]=c(_,E,b)}),m}function Ug(i){var c=gd(i);return c.length==1&&c[0][2]?vp(c[0][0],c[0][1]):function(u){return u===i||Xu(u,i,c)}}function Vg(i,c){return vd(i)&&pp(c)?vp(Pr(i),c):function(u){var m=Ad(u,i);return m===t&&m===c?kd(u,i):es(c,m,C|T)}}function _c(i,c,u,m,_){i!==c&&ju(c,function(E,b){if(_||(_=new dr),ut(E))LI(i,c,b,u,_c,m,_);else{var A=m?m(yd(i,b),E,b+"",i,c,_):t;A===t&&(A=E),Gu(i,b,A)}},gn)}function LI(i,c,u,m,_,E,b){var A=yd(i,u),M=yd(c,u),z=b.get(M);if(z){Gu(i,u,z);return}var G=E?E(A,M,u+"",i,c,b):t,j=G===t;if(j){var te=Ee(M),ce=!te&&Po(M),fe=!te&&!ce&&Gi(M);G=M,te||ce||fe?Ee(A)?G=A:pt(A)?G=fn(A):ce?(j=!1,G=Jg(M,!0)):fe?(j=!1,G=Qg(M,!0)):G=[]:is(M)||li(M)?(G=A,li(A)?G=qp(A):(!ut(A)||to(A))&&(G=gp(M))):j=!1}j&&(b.set(M,G),_(G,M,m,E,b),b.delete(M)),Gu(i,u,G)}function Bg(i,c){var u=i.length;if(u)return c+=c<0?u:0,eo(c,u)?i[c]:t}function Fg(i,c,u){c.length?c=st(c,function(E){return Ee(E)?function(b){return ai(b,E.length===1?E[0]:E)}:E}):c=[pn];var m=-1;c=st(c,Sn(he()));var _=xg(i,function(E,b,A){var M=st(c,function(z){return z(E)});return{criteria:M,index:++m,value:E}});return cS(_,function(E,b){return jI(E,b,u)})}function xI(i,c){return $g(i,c,function(u,m){return kd(i,m)})}function $g(i,c,u){for(var m=-1,_=c.length,E={};++m<_;){var b=c[m],A=ai(i,b);u(A,b)&&ts(E,Oo(b,i),A)}return E}function UI(i){return function(c){return ai(c,i)}}function td(i,c,u,m){var _=m?sS:Li,E=-1,b=c.length,A=i;for(i===c&&(c=fn(c)),u&&(A=st(i,Sn(u)));++E<b;)for(var M=0,z=c[E],G=u?u(z):z;(M=_(A,G,M,m))>-1;)A!==i&&cc.call(A,M,1),cc.call(i,M,1);return i}function Hg(i,c){for(var u=i?c.length:0,m=u-1;u--;){var _=c[u];if(u==m||_!==E){var E=_;eo(_)?cc.call(i,_,1):id(i,_)}}return i}function nd(i,c){return i+dc(wg()*(c-i+1))}function VI(i,c,u,m){for(var _=-1,E=Nt(uc((c-i)/(u||1)),0),b=V(E);E--;)b[m?E:++_]=i,i+=u;return b}function rd(i,c){var u="";if(!i||c<1||c>at)return u;do c%2&&(u+=i),c=dc(c/2),c&&(i+=i);while(c);return u}function Ie(i,c){return Cd(_p(i,c,pn),i+"")}function BI(i){return Sg(qi(i))}function FI(i,c){var u=qi(i);return kc(u,ii(c,0,u.length))}function ts(i,c,u,m){if(!ut(i))return i;c=Oo(c,i);for(var _=-1,E=c.length,b=E-1,A=i;A!=null&&++_<E;){var M=Pr(c[_]),z=u;if(M==="__proto__"||M==="constructor"||M==="prototype")return i;if(_!=b){var G=A[M];z=m?m(G,M,A):t,z===t&&(z=ut(G)?G:eo(c[_+1])?[]:{})}Qa(A,M,z),A=A[M]}return i}var Kg=hc?function(i,c){return hc.set(i,c),i}:pn,$I=lc?function(i,c){return lc(i,"toString",{configurable:!0,enumerable:!1,value:Od(c),writable:!0})}:pn;function HI(i){return kc(qi(i))}function Gn(i,c,u){var m=-1,_=i.length;c<0&&(c=-c>_?0:_+c),u=u>_?_:u,u<0&&(u+=_),_=c>u?0:u-c>>>0,c>>>=0;for(var E=V(_);++m<_;)E[m]=i[m+c];return E}function KI(i,c){var u;return ko(i,function(m,_,E){return u=c(m,_,E),!u}),!!u}function yc(i,c,u){var m=0,_=i==null?m:i.length;if(typeof c=="number"&&c===c&&_<=Fa){for(;m<_;){var E=m+_>>>1,b=i[E];b!==null&&!An(b)&&(u?b<=c:b<c)?m=E+1:_=E}return _}return od(i,c,pn,u)}function od(i,c,u,m){var _=0,E=i==null?0:i.length;if(E===0)return 0;c=u(c);for(var b=c!==c,A=c===null,M=An(c),z=c===t;_<E;){var G=dc((_+E)/2),j=u(i[G]),te=j!==t,ce=j===null,fe=j===j,Se=An(j);if(b)var me=m||fe;else z?me=fe&&(m||te):A?me=fe&&te&&(m||!ce):M?me=fe&&te&&!ce&&(m||!Se):ce||Se?me=!1:me=m?j<=c:j<c;me?_=G+1:E=G}return Yt(E,Xo)}function Wg(i,c){for(var u=-1,m=i.length,_=0,E=[];++u<m;){var b=i[u],A=c?c(b):b;if(!u||!hr(A,M)){var M=A;E[_++]=b===0?0:b}}return E}function zg(i){return typeof i=="number"?i:An(i)?an:+i}function In(i){if(typeof i=="string")return i;if(Ee(i))return st(i,In)+"";if(An(i))return Tg?Tg.call(i):"";var c=i+"";return c=="0"&&1/i==-Dt?"-0":c}function No(i,c,u){var m=-1,_=Xs,E=i.length,b=!0,A=[],M=A;if(u)b=!1,_=Mu;else if(E>=o){var z=c?null:eA(i);if(z)return ec(z);b=!1,_=za,M=new oi}else M=c?[]:A;e:for(;++m<E;){var G=i[m],j=c?c(G):G;if(G=u||G!==0?G:0,b&&j===j){for(var te=M.length;te--;)if(M[te]===j)continue e;c&&M.push(j),A.push(G)}else _(M,j,u)||(M!==A&&M.push(j),A.push(G))}return A}function id(i,c){return c=Oo(c,i),i=yp(i,c),i==null||delete i[Pr(qn(c))]}function Gg(i,c,u,m){return ts(i,c,u(ai(i,c)),m)}function Cc(i,c,u,m){for(var _=i.length,E=m?_:-1;(m?E--:++E<_)&&c(i[E],E,i););return u?Gn(i,m?0:E,m?E+1:_):Gn(i,m?E+1:0,m?_:E)}function qg(i,c){var u=i;return u instanceof Re&&(u=u.value()),Du(c,function(m,_){return _.func.apply(_.thisArg,So([m],_.args))},u)}function ad(i,c,u){var m=i.length;if(m<2)return m?No(i[0]):[];for(var _=-1,E=V(m);++_<m;)for(var b=i[_],A=-1;++A<m;)A!=_&&(E[_]=Xa(E[_]||b,i[A],c,u));return No(Ht(E,1),c,u)}function jg(i,c,u){for(var m=-1,_=i.length,E=c.length,b={};++m<_;){var A=m<E?c[m]:t;u(b,i[m],A)}return b}function sd(i){return pt(i)?i:[]}function cd(i){return typeof i=="function"?i:pn}function Oo(i,c){return Ee(i)?i:vd(i,c)?[i]:Tp(Ke(i))}var WI=Ie;function Ro(i,c,u){var m=i.length;return u=u===t?m:u,!c&&u>=m?i:Gn(i,c,u)}var Yg=RS||function(i){return $t.clearTimeout(i)};function Jg(i,c){if(c)return i.slice();var u=i.length,m=vg?vg(u):new i.constructor(u);return i.copy(m),m}function ld(i){var c=new i.constructor(i.byteLength);return new ac(c).set(new ac(i)),c}function zI(i,c){var u=c?ld(i.buffer):i.buffer;return new i.constructor(u,i.byteOffset,i.byteLength)}function GI(i){var c=new i.constructor(i.source,Mm.exec(i));return c.lastIndex=i.lastIndex,c}function qI(i){return Ja?Qe(Ja.call(i)):{}}function Qg(i,c){var u=c?ld(i.buffer):i.buffer;return new i.constructor(u,i.byteOffset,i.length)}function Xg(i,c){if(i!==c){var u=i!==t,m=i===null,_=i===i,E=An(i),b=c!==t,A=c===null,M=c===c,z=An(c);if(!A&&!z&&!E&&i>c||E&&b&&M&&!A&&!z||m&&b&&M||!u&&M||!_)return 1;if(!m&&!E&&!z&&i<c||z&&u&&_&&!m&&!E||A&&u&&_||!b&&_||!M)return-1}return 0}function jI(i,c,u){for(var m=-1,_=i.criteria,E=c.criteria,b=_.length,A=u.length;++m<b;){var M=Xg(_[m],E[m]);if(M){if(m>=A)return M;var z=u[m];return M*(z=="desc"?-1:1)}}return i.index-c.index}function Zg(i,c,u,m){for(var _=-1,E=i.length,b=u.length,A=-1,M=c.length,z=Nt(E-b,0),G=V(M+z),j=!m;++A<M;)G[A]=c[A];for(;++_<b;)(j||_<E)&&(G[u[_]]=i[_]);for(;z--;)G[A++]=i[_++];return G}function ep(i,c,u,m){for(var _=-1,E=i.length,b=-1,A=u.length,M=-1,z=c.length,G=Nt(E-A,0),j=V(G+z),te=!m;++_<G;)j[_]=i[_];for(var ce=_;++M<z;)j[ce+M]=c[M];for(;++b<A;)(te||_<E)&&(j[ce+u[b]]=i[_++]);return j}function fn(i,c){var u=-1,m=i.length;for(c||(c=V(m));++u<m;)c[u]=i[u];return c}function Rr(i,c,u,m){var _=!u;u||(u={});for(var E=-1,b=c.length;++E<b;){var A=c[E],M=m?m(u[A],i[A],A,u,i):t;M===t&&(M=i[A]),_?Qr(u,A,M):Qa(u,A,M)}return u}function YI(i,c){return Rr(i,pd(i),c)}function JI(i,c){return Rr(i,fp(i),c)}function Ec(i,c){return function(u,m){var _=Ee(u)?tS:_I,E=c?c():{};return _(u,i,he(m,2),E)}}function Ki(i){return Ie(function(c,u){var m=-1,_=u.length,E=_>1?u[_-1]:t,b=_>2?u[2]:t;for(E=i.length>3&&typeof E=="function"?(_--,E):t,b&&cn(u[0],u[1],b)&&(E=_<3?t:E,_=1),c=Qe(c);++m<_;){var A=u[m];A&&i(c,A,m,E)}return c})}function tp(i,c){return function(u,m){if(u==null)return u;if(!mn(u))return i(u,m);for(var _=u.length,E=c?_:-1,b=Qe(u);(c?E--:++E<_)&&m(b[E],E,b)!==!1;);return u}}function np(i){return function(c,u,m){for(var _=-1,E=Qe(c),b=m(c),A=b.length;A--;){var M=b[i?A:++_];if(u(E[M],M,E)===!1)break}return c}}function QI(i,c,u){var m=c&S,_=ns(i);function E(){var b=this&&this!==$t&&this instanceof E?_:i;return b.apply(m?u:this,arguments)}return E}function rp(i){return function(c){c=Ke(c);var u=xi(c)?ur(c):t,m=u?u[0]:c.charAt(0),_=u?Ro(u,1).join(""):c.slice(1);return m[i]()+_}}function Wi(i){return function(c){return Du(tv(ev(c).replace($b,"")),i,"")}}function ns(i){return function(){var c=arguments;switch(c.length){case 0:return new i;case 1:return new i(c[0]);case 2:return new i(c[0],c[1]);case 3:return new i(c[0],c[1],c[2]);case 4:return new i(c[0],c[1],c[2],c[3]);case 5:return new i(c[0],c[1],c[2],c[3],c[4]);case 6:return new i(c[0],c[1],c[2],c[3],c[4],c[5]);case 7:return new i(c[0],c[1],c[2],c[3],c[4],c[5],c[6])}var u=Hi(i.prototype),m=i.apply(u,c);return ut(m)?m:u}}function XI(i,c,u){var m=ns(i);function _(){for(var E=arguments.length,b=V(E),A=E,M=zi(_);A--;)b[A]=arguments[A];var z=E<3&&b[0]!==M&&b[E-1]!==M?[]:Io(b,M);if(E-=z.length,E<u)return cp(i,c,wc,_.placeholder,t,b,z,t,t,u-E);var G=this&&this!==$t&&this instanceof _?m:i;return bn(G,this,b)}return _}function op(i){return function(c,u,m){var _=Qe(c);if(!mn(c)){var E=he(u,3);c=Lt(c),u=function(A){return E(_[A],A,_)}}var b=i(c,u,m);return b>-1?_[E?c[b]:b]:t}}function ip(i){return Zr(function(c){var u=c.length,m=u,_=Wn.prototype.thru;for(i&&c.reverse();m--;){var E=c[m];if(typeof E!="function")throw new Kn(l);if(_&&!b&&Ic(E)=="wrapper")var b=new Wn([],!0)}for(m=b?m:u;++m<u;){E=c[m];var A=Ic(E),M=A=="wrapper"?md(E):t;M&&_d(M[0])&&M[1]==(R|D|U|ae)&&!M[4].length&&M[9]==1?b=b[Ic(M[0])].apply(b,M[3]):b=E.length==1&&_d(E)?b[A]():b.thru(E)}return function(){var z=arguments,G=z[0];if(b&&z.length==1&&Ee(G))return b.plant(G).value();for(var j=0,te=u?c[j].apply(this,z):G;++j<u;)te=c[j].call(this,te);return te}})}function wc(i,c,u,m,_,E,b,A,M,z){var G=c&R,j=c&S,te=c&I,ce=c&(D|L),fe=c&se,Se=te?t:ns(i);function me(){for(var Oe=arguments.length,Pe=V(Oe),kn=Oe;kn--;)Pe[kn]=arguments[kn];if(ce)var ln=zi(me),Nn=uS(Pe,ln);if(m&&(Pe=Zg(Pe,m,_,ce)),E&&(Pe=ep(Pe,E,b,ce)),Oe-=Nn,ce&&Oe<z){var vt=Io(Pe,ln);return cp(i,c,wc,me.placeholder,u,Pe,vt,A,M,z-Oe)}var fr=j?u:this,ro=te?fr[i]:i;return Oe=Pe.length,A?Pe=_A(Pe,A):fe&&Oe>1&&Pe.reverse(),G&&M<Oe&&(Pe.length=M),this&&this!==$t&&this instanceof me&&(ro=Se||ns(ro)),ro.apply(fr,Pe)}return me}function ap(i,c){return function(u,m){return II(u,i,c(m),{})}}function Tc(i,c){return function(u,m){var _;if(u===t&&m===t)return c;if(u!==t&&(_=u),m!==t){if(_===t)return m;typeof u=="string"||typeof m=="string"?(u=In(u),m=In(m)):(u=zg(u),m=zg(m)),_=i(u,m)}return _}}function ud(i){return Zr(function(c){return c=st(c,Sn(he())),Ie(function(u){var m=this;return i(c,function(_){return bn(_,m,u)})})})}function bc(i,c){c=c===t?" ":In(c);var u=c.length;if(u<2)return u?rd(c,i):c;var m=rd(c,uc(i/Ui(c)));return xi(c)?Ro(ur(m),0,i).join(""):m.slice(0,i)}function ZI(i,c,u,m){var _=c&S,E=ns(i);function b(){for(var A=-1,M=arguments.length,z=-1,G=m.length,j=V(G+M),te=this&&this!==$t&&this instanceof b?E:i;++z<G;)j[z]=m[z];for(;M--;)j[z++]=arguments[++A];return bn(te,_?u:this,j)}return b}function sp(i){return function(c,u,m){return m&&typeof m!="number"&&cn(c,u,m)&&(u=m=t),c=no(c),u===t?(u=c,c=0):u=no(u),m=m===t?c<u?1:-1:no(m),VI(c,u,m,i)}}function Sc(i){return function(c,u){return typeof c=="string"&&typeof u=="string"||(c=jn(c),u=jn(u)),i(c,u)}}function cp(i,c,u,m,_,E,b,A,M,z){var G=c&D,j=G?b:t,te=G?t:b,ce=G?E:t,fe=G?t:E;c|=G?U:F,c&=~(G?F:U),c&N||(c&=-4);var Se=[i,c,_,ce,j,fe,te,A,M,z],me=u.apply(t,Se);return _d(i)&&Cp(me,Se),me.placeholder=m,Ep(me,i,c)}function dd(i){var c=kt[i];return function(u,m){if(u=jn(u),m=m==null?0:Yt(be(m),292),m&&Eg(u)){var _=(Ke(u)+"e").split("e"),E=c(_[0]+"e"+(+_[1]+m));return _=(Ke(E)+"e").split("e"),+(_[0]+"e"+(+_[1]-m))}return c(u)}}var eA=Fi&&1/ec(new Fi([,-0]))[1]==Dt?function(i){return new Fi(i)}:Md;function lp(i){return function(c){var u=Jt(c);return u==Ft?$u(c):u==oe?vS(c):lS(c,i(c))}}function Xr(i,c,u,m,_,E,b,A){var M=c&I;if(!M&&typeof i!="function")throw new Kn(l);var z=m?m.length:0;if(z||(c&=-97,m=_=t),b=b===t?b:Nt(be(b),0),A=A===t?A:be(A),z-=_?_.length:0,c&F){var G=m,j=_;m=_=t}var te=M?t:md(i),ce=[i,c,u,m,_,G,j,E,b,A];if(te&&gA(ce,te),i=ce[0],c=ce[1],u=ce[2],m=ce[3],_=ce[4],A=ce[9]=ce[9]===t?M?0:i.length:Nt(ce[9]-z,0),!A&&c&(D|L)&&(c&=-25),!c||c==S)var fe=QI(i,c,u);else c==D||c==L?fe=XI(i,c,A):(c==U||c==(S|U))&&!_.length?fe=ZI(i,c,u,m):fe=wc.apply(t,ce);var Se=te?Kg:Cp;return Ep(Se(fe,ce),i,c)}function up(i,c,u,m){return i===t||hr(i,Bi[u])&&!We.call(m,u)?c:i}function dp(i,c,u,m,_,E){return ut(i)&&ut(c)&&(E.set(c,i),_c(i,c,t,dp,E),E.delete(c)),i}function tA(i){return is(i)?t:i}function hp(i,c,u,m,_,E){var b=u&C,A=i.length,M=c.length;if(A!=M&&!(b&&M>A))return!1;var z=E.get(i),G=E.get(c);if(z&&G)return z==c&&G==i;var j=-1,te=!0,ce=u&T?new oi:t;for(E.set(i,c),E.set(c,i);++j<A;){var fe=i[j],Se=c[j];if(m)var me=b?m(Se,fe,j,c,i,E):m(fe,Se,j,i,c,E);if(me!==t){if(me)continue;te=!1;break}if(ce){if(!Lu(c,function(Oe,Pe){if(!za(ce,Pe)&&(fe===Oe||_(fe,Oe,u,m,E)))return ce.push(Pe)})){te=!1;break}}else if(!(fe===Se||_(fe,Se,u,m,E))){te=!1;break}}return E.delete(i),E.delete(c),te}function nA(i,c,u,m,_,E,b){switch(u){case qe:if(i.byteLength!=c.byteLength||i.byteOffset!=c.byteOffset)return!1;i=i.buffer,c=c.buffer;case Ne:return!(i.byteLength!=c.byteLength||!E(new ac(i),new ac(c)));case kr:case jr:case wn:return hr(+i,+c);case Co:return i.name==c.name&&i.message==c.message;case q:case Je:return i==c+"";case Ft:var A=$u;case oe:var M=m&C;if(A||(A=ec),i.size!=c.size&&!M)return!1;var z=b.get(i);if(z)return z==c;m|=T,b.set(i,c);var G=hp(A(i),A(c),m,_,E,b);return b.delete(i),G;case et:if(Ja)return Ja.call(i)==Ja.call(c)}return!1}function rA(i,c,u,m,_,E){var b=u&C,A=hd(i),M=A.length,z=hd(c),G=z.length;if(M!=G&&!b)return!1;for(var j=M;j--;){var te=A[j];if(!(b?te in c:We.call(c,te)))return!1}var ce=E.get(i),fe=E.get(c);if(ce&&fe)return ce==c&&fe==i;var Se=!0;E.set(i,c),E.set(c,i);for(var me=b;++j<M;){te=A[j];var Oe=i[te],Pe=c[te];if(m)var kn=b?m(Pe,Oe,te,c,i,E):m(Oe,Pe,te,i,c,E);if(!(kn===t?Oe===Pe||_(Oe,Pe,u,m,E):kn)){Se=!1;break}me||(me=te=="constructor")}if(Se&&!me){var ln=i.constructor,Nn=c.constructor;ln!=Nn&&"constructor"in i&&"constructor"in c&&!(typeof ln=="function"&&ln instanceof ln&&typeof Nn=="function"&&Nn instanceof Nn)&&(Se=!1)}return E.delete(i),E.delete(c),Se}function Zr(i){return Cd(_p(i,t,Ap),i+"")}function hd(i){return Pg(i,Lt,pd)}function fd(i){return Pg(i,gn,fp)}var md=hc?function(i){return hc.get(i)}:Md;function Ic(i){for(var c=i.name+"",u=$i[c],m=We.call($i,c)?u.length:0;m--;){var _=u[m],E=_.func;if(E==null||E==i)return _.name}return c}function zi(i){var c=We.call(y,"placeholder")?y:i;return c.placeholder}function he(){var i=y.iteratee||Rd;return i=i===Rd?Lg:i,arguments.length?i(arguments[0],arguments[1]):i}function Ac(i,c){var u=i.__data__;return dA(c)?u[typeof c=="string"?"string":"hash"]:u.map}function gd(i){for(var c=Lt(i),u=c.length;u--;){var m=c[u],_=i[m];c[u]=[m,_,pp(_)]}return c}function si(i,c){var u=mS(i,c);return Dg(u)?u:t}function oA(i){var c=We.call(i,ni),u=i[ni];try{i[ni]=t;var m=!0}catch{}var _=oc.call(i);return m&&(c?i[ni]=u:delete i[ni]),_}var pd=Ku?function(i){return i==null?[]:(i=Qe(i),bo(Ku(i),function(c){return yg.call(i,c)}))}:Dd,fp=Ku?function(i){for(var c=[];i;)So(c,pd(i)),i=sc(i);return c}:Dd,Jt=sn;(Wu&&Jt(new Wu(new ArrayBuffer(1)))!=qe||qa&&Jt(new qa)!=Ft||zu&&Jt(zu.resolve())!=k||Fi&&Jt(new Fi)!=oe||ja&&Jt(new ja)!=H)&&(Jt=function(i){var c=sn(i),u=c==Tn?i.constructor:t,m=u?ci(u):"";if(m)switch(m){case FS:return qe;case $S:return Ft;case HS:return k;case KS:return oe;case WS:return H}return c});function iA(i,c,u){for(var m=-1,_=u.length;++m<_;){var E=u[m],b=E.size;switch(E.type){case"drop":i+=b;break;case"dropRight":c-=b;break;case"take":c=Yt(c,i+b);break;case"takeRight":i=Nt(i,c-b);break}}return{start:i,end:c}}function aA(i){var c=i.match(hb);return c?c[1].split(fb):[]}function mp(i,c,u){c=Oo(c,i);for(var m=-1,_=c.length,E=!1;++m<_;){var b=Pr(c[m]);if(!(E=i!=null&&u(i,b)))break;i=i[b]}return E||++m!=_?E:(_=i==null?0:i.length,!!_&&Dc(_)&&eo(b,_)&&(Ee(i)||li(i)))}function sA(i){var c=i.length,u=new i.constructor(c);return c&&typeof i[0]=="string"&&We.call(i,"index")&&(u.index=i.index,u.input=i.input),u}function gp(i){return typeof i.constructor=="function"&&!rs(i)?Hi(sc(i)):{}}function cA(i,c,u){var m=i.constructor;switch(c){case Ne:return ld(i);case kr:case jr:return new m(+i);case qe:return zI(i,u);case cr:case To:case Nr:case lr:case Wa:case Mi:case Eu:case wu:case Tu:return Qg(i,u);case Ft:return new m;case wn:case Je:return new m(i);case q:return GI(i);case oe:return new m;case et:return qI(i)}}function lA(i,c){var u=c.length;if(!u)return i;var m=u-1;return c[m]=(u>1?"& ":"")+c[m],c=c.join(u>2?", ":" "),i.replace(db,`{
|
|
40
|
+
/* [wrapped with `+c+`] */
|
|
41
|
+
`)}function uA(i){return Ee(i)||li(i)||!!(Cg&&i&&i[Cg])}function eo(i,c){var u=typeof i;return c=c??at,!!c&&(u=="number"||u!="symbol"&&wb.test(i))&&i>-1&&i%1==0&&i<c}function cn(i,c,u){if(!ut(u))return!1;var m=typeof c;return(m=="number"?mn(u)&&eo(c,u.length):m=="string"&&c in u)?hr(u[c],i):!1}function vd(i,c){if(Ee(i))return!1;var u=typeof i;return u=="number"||u=="symbol"||u=="boolean"||i==null||An(i)?!0:sb.test(i)||!ab.test(i)||c!=null&&i in Qe(c)}function dA(i){var c=typeof i;return c=="string"||c=="number"||c=="symbol"||c=="boolean"?i!=="__proto__":i===null}function _d(i){var c=Ic(i),u=y[c];if(typeof u!="function"||!(c in Re.prototype))return!1;if(i===u)return!0;var m=md(u);return!!m&&i===m[0]}function hA(i){return!!pg&&pg in i}var fA=nc?to:Ld;function rs(i){var c=i&&i.constructor,u=typeof c=="function"&&c.prototype||Bi;return i===u}function pp(i){return i===i&&!ut(i)}function vp(i,c){return function(u){return u==null?!1:u[i]===c&&(c!==t||i in Qe(u))}}function mA(i){var c=Pc(i,function(m){return u.size===f&&u.clear(),m}),u=c.cache;return c}function gA(i,c){var u=i[1],m=c[1],_=u|m,E=_<(S|I|R),b=m==R&&u==D||m==R&&u==ae&&i[7].length<=c[8]||m==(R|ae)&&c[7].length<=c[8]&&u==D;if(!(E||b))return i;m&S&&(i[2]=c[2],_|=u&S?0:N);var A=c[3];if(A){var M=i[3];i[3]=M?Zg(M,A,c[4]):A,i[4]=M?Io(i[3],g):c[4]}return A=c[5],A&&(M=i[5],i[5]=M?ep(M,A,c[6]):A,i[6]=M?Io(i[5],g):c[6]),A=c[7],A&&(i[7]=A),m&R&&(i[8]=i[8]==null?c[8]:Yt(i[8],c[8])),i[9]==null&&(i[9]=c[9]),i[0]=c[0],i[1]=_,i}function pA(i){var c=[];if(i!=null)for(var u in Qe(i))c.push(u);return c}function vA(i){return oc.call(i)}function _p(i,c,u){return c=Nt(c===t?i.length-1:c,0),function(){for(var m=arguments,_=-1,E=Nt(m.length-c,0),b=V(E);++_<E;)b[_]=m[c+_];_=-1;for(var A=V(c+1);++_<c;)A[_]=m[_];return A[c]=u(b),bn(i,this,A)}}function yp(i,c){return c.length<2?i:ai(i,Gn(c,0,-1))}function _A(i,c){for(var u=i.length,m=Yt(c.length,u),_=fn(i);m--;){var E=c[m];i[m]=eo(E,u)?_[E]:t}return i}function yd(i,c){if(!(c==="constructor"&&typeof i[c]=="function")&&c!="__proto__")return i[c]}var Cp=wp(Kg),os=MS||function(i,c){return $t.setTimeout(i,c)},Cd=wp($I);function Ep(i,c,u){var m=c+"";return Cd(i,lA(m,yA(aA(m),u)))}function wp(i){var c=0,u=0;return function(){var m=US(),_=Fe-(m-u);if(u=m,_>0){if(++c>=de)return arguments[0]}else c=0;return i.apply(t,arguments)}}function kc(i,c){var u=-1,m=i.length,_=m-1;for(c=c===t?m:c;++u<c;){var E=nd(u,_),b=i[E];i[E]=i[u],i[u]=b}return i.length=c,i}var Tp=mA(function(i){var c=[];return i.charCodeAt(0)===46&&c.push(""),i.replace(cb,function(u,m,_,E){c.push(_?E.replace(pb,"$1"):m||u)}),c});function Pr(i){if(typeof i=="string"||An(i))return i;var c=i+"";return c=="0"&&1/i==-Dt?"-0":c}function ci(i){if(i!=null){try{return rc.call(i)}catch{}try{return i+""}catch{}}return""}function yA(i,c){return Hn($a,function(u){var m="_."+u[0];c&u[1]&&!Xs(i,m)&&i.push(m)}),i.sort()}function bp(i){if(i instanceof Re)return i.clone();var c=new Wn(i.__wrapped__,i.__chain__);return c.__actions__=fn(i.__actions__),c.__index__=i.__index__,c.__values__=i.__values__,c}function CA(i,c,u){(u?cn(i,c,u):c===t)?c=1:c=Nt(be(c),0);var m=i==null?0:i.length;if(!m||c<1)return[];for(var _=0,E=0,b=V(uc(m/c));_<m;)b[E++]=Gn(i,_,_+=c);return b}function EA(i){for(var c=-1,u=i==null?0:i.length,m=0,_=[];++c<u;){var E=i[c];E&&(_[m++]=E)}return _}function wA(){var i=arguments.length;if(!i)return[];for(var c=V(i-1),u=arguments[0],m=i;m--;)c[m-1]=arguments[m];return So(Ee(u)?fn(u):[u],Ht(c,1))}var TA=Ie(function(i,c){return pt(i)?Xa(i,Ht(c,1,pt,!0)):[]}),bA=Ie(function(i,c){var u=qn(c);return pt(u)&&(u=t),pt(i)?Xa(i,Ht(c,1,pt,!0),he(u,2)):[]}),SA=Ie(function(i,c){var u=qn(c);return pt(u)&&(u=t),pt(i)?Xa(i,Ht(c,1,pt,!0),t,u):[]});function IA(i,c,u){var m=i==null?0:i.length;return m?(c=u||c===t?1:be(c),Gn(i,c<0?0:c,m)):[]}function AA(i,c,u){var m=i==null?0:i.length;return m?(c=u||c===t?1:be(c),c=m-c,Gn(i,0,c<0?0:c)):[]}function kA(i,c){return i&&i.length?Cc(i,he(c,3),!0,!0):[]}function NA(i,c){return i&&i.length?Cc(i,he(c,3),!0):[]}function OA(i,c,u,m){var _=i==null?0:i.length;return _?(u&&typeof u!="number"&&cn(i,c,u)&&(u=0,m=_),wI(i,c,u,m)):[]}function Sp(i,c,u){var m=i==null?0:i.length;if(!m)return-1;var _=u==null?0:be(u);return _<0&&(_=Nt(m+_,0)),Zs(i,he(c,3),_)}function Ip(i,c,u){var m=i==null?0:i.length;if(!m)return-1;var _=m-1;return u!==t&&(_=be(u),_=u<0?Nt(m+_,0):Yt(_,m-1)),Zs(i,he(c,3),_,!0)}function Ap(i){var c=i==null?0:i.length;return c?Ht(i,1):[]}function RA(i){var c=i==null?0:i.length;return c?Ht(i,Dt):[]}function PA(i,c){var u=i==null?0:i.length;return u?(c=c===t?1:be(c),Ht(i,c)):[]}function MA(i){for(var c=-1,u=i==null?0:i.length,m={};++c<u;){var _=i[c];m[_[0]]=_[1]}return m}function kp(i){return i&&i.length?i[0]:t}function DA(i,c,u){var m=i==null?0:i.length;if(!m)return-1;var _=u==null?0:be(u);return _<0&&(_=Nt(m+_,0)),Li(i,c,_)}function LA(i){var c=i==null?0:i.length;return c?Gn(i,0,-1):[]}var xA=Ie(function(i){var c=st(i,sd);return c.length&&c[0]===i[0]?Qu(c):[]}),UA=Ie(function(i){var c=qn(i),u=st(i,sd);return c===qn(u)?c=t:u.pop(),u.length&&u[0]===i[0]?Qu(u,he(c,2)):[]}),VA=Ie(function(i){var c=qn(i),u=st(i,sd);return c=typeof c=="function"?c:t,c&&u.pop(),u.length&&u[0]===i[0]?Qu(u,t,c):[]});function BA(i,c){return i==null?"":LS.call(i,c)}function qn(i){var c=i==null?0:i.length;return c?i[c-1]:t}function FA(i,c,u){var m=i==null?0:i.length;if(!m)return-1;var _=m;return u!==t&&(_=be(u),_=_<0?Nt(m+_,0):Yt(_,m-1)),c===c?yS(i,c,_):Zs(i,cg,_,!0)}function $A(i,c){return i&&i.length?Bg(i,be(c)):t}var HA=Ie(Np);function Np(i,c){return i&&i.length&&c&&c.length?td(i,c):i}function KA(i,c,u){return i&&i.length&&c&&c.length?td(i,c,he(u,2)):i}function WA(i,c,u){return i&&i.length&&c&&c.length?td(i,c,t,u):i}var zA=Zr(function(i,c){var u=i==null?0:i.length,m=qu(i,c);return Hg(i,st(c,function(_){return eo(_,u)?+_:_}).sort(Xg)),m});function GA(i,c){var u=[];if(!(i&&i.length))return u;var m=-1,_=[],E=i.length;for(c=he(c,3);++m<E;){var b=i[m];c(b,m,i)&&(u.push(b),_.push(m))}return Hg(i,_),u}function Ed(i){return i==null?i:BS.call(i)}function qA(i,c,u){var m=i==null?0:i.length;return m?(u&&typeof u!="number"&&cn(i,c,u)?(c=0,u=m):(c=c==null?0:be(c),u=u===t?m:be(u)),Gn(i,c,u)):[]}function jA(i,c){return yc(i,c)}function YA(i,c,u){return od(i,c,he(u,2))}function JA(i,c){var u=i==null?0:i.length;if(u){var m=yc(i,c);if(m<u&&hr(i[m],c))return m}return-1}function QA(i,c){return yc(i,c,!0)}function XA(i,c,u){return od(i,c,he(u,2),!0)}function ZA(i,c){var u=i==null?0:i.length;if(u){var m=yc(i,c,!0)-1;if(hr(i[m],c))return m}return-1}function ek(i){return i&&i.length?Wg(i):[]}function tk(i,c){return i&&i.length?Wg(i,he(c,2)):[]}function nk(i){var c=i==null?0:i.length;return c?Gn(i,1,c):[]}function rk(i,c,u){return i&&i.length?(c=u||c===t?1:be(c),Gn(i,0,c<0?0:c)):[]}function ok(i,c,u){var m=i==null?0:i.length;return m?(c=u||c===t?1:be(c),c=m-c,Gn(i,c<0?0:c,m)):[]}function ik(i,c){return i&&i.length?Cc(i,he(c,3),!1,!0):[]}function ak(i,c){return i&&i.length?Cc(i,he(c,3)):[]}var sk=Ie(function(i){return No(Ht(i,1,pt,!0))}),ck=Ie(function(i){var c=qn(i);return pt(c)&&(c=t),No(Ht(i,1,pt,!0),he(c,2))}),lk=Ie(function(i){var c=qn(i);return c=typeof c=="function"?c:t,No(Ht(i,1,pt,!0),t,c)});function uk(i){return i&&i.length?No(i):[]}function dk(i,c){return i&&i.length?No(i,he(c,2)):[]}function hk(i,c){return c=typeof c=="function"?c:t,i&&i.length?No(i,t,c):[]}function wd(i){if(!(i&&i.length))return[];var c=0;return i=bo(i,function(u){if(pt(u))return c=Nt(u.length,c),!0}),Bu(c,function(u){return st(i,xu(u))})}function Op(i,c){if(!(i&&i.length))return[];var u=wd(i);return c==null?u:st(u,function(m){return bn(c,t,m)})}var fk=Ie(function(i,c){return pt(i)?Xa(i,c):[]}),mk=Ie(function(i){return ad(bo(i,pt))}),gk=Ie(function(i){var c=qn(i);return pt(c)&&(c=t),ad(bo(i,pt),he(c,2))}),pk=Ie(function(i){var c=qn(i);return c=typeof c=="function"?c:t,ad(bo(i,pt),t,c)}),vk=Ie(wd);function _k(i,c){return jg(i||[],c||[],Qa)}function yk(i,c){return jg(i||[],c||[],ts)}var Ck=Ie(function(i){var c=i.length,u=c>1?i[c-1]:t;return u=typeof u=="function"?(i.pop(),u):t,Op(i,u)});function Rp(i){var c=y(i);return c.__chain__=!0,c}function Ek(i,c){return c(i),i}function Nc(i,c){return c(i)}var wk=Zr(function(i){var c=i.length,u=c?i[0]:0,m=this.__wrapped__,_=function(E){return qu(E,i)};return c>1||this.__actions__.length||!(m instanceof Re)||!eo(u)?this.thru(_):(m=m.slice(u,+u+(c?1:0)),m.__actions__.push({func:Nc,args:[_],thisArg:t}),new Wn(m,this.__chain__).thru(function(E){return c&&!E.length&&E.push(t),E}))});function Tk(){return Rp(this)}function bk(){return new Wn(this.value(),this.__chain__)}function Sk(){this.__values__===t&&(this.__values__=zp(this.value()));var i=this.__index__>=this.__values__.length,c=i?t:this.__values__[this.__index__++];return{done:i,value:c}}function Ik(){return this}function Ak(i){for(var c,u=this;u instanceof mc;){var m=bp(u);m.__index__=0,m.__values__=t,c?_.__wrapped__=m:c=m;var _=m;u=u.__wrapped__}return _.__wrapped__=i,c}function kk(){var i=this.__wrapped__;if(i instanceof Re){var c=i;return this.__actions__.length&&(c=new Re(this)),c=c.reverse(),c.__actions__.push({func:Nc,args:[Ed],thisArg:t}),new Wn(c,this.__chain__)}return this.thru(Ed)}function Nk(){return qg(this.__wrapped__,this.__actions__)}var Ok=Ec(function(i,c,u){We.call(i,u)?++i[u]:Qr(i,u,1)});function Rk(i,c,u){var m=Ee(i)?ag:EI;return u&&cn(i,c,u)&&(c=t),m(i,he(c,3))}function Pk(i,c){var u=Ee(i)?bo:Og;return u(i,he(c,3))}var Mk=op(Sp),Dk=op(Ip);function Lk(i,c){return Ht(Oc(i,c),1)}function xk(i,c){return Ht(Oc(i,c),Dt)}function Uk(i,c,u){return u=u===t?1:be(u),Ht(Oc(i,c),u)}function Pp(i,c){var u=Ee(i)?Hn:ko;return u(i,he(c,3))}function Mp(i,c){var u=Ee(i)?nS:Ng;return u(i,he(c,3))}var Vk=Ec(function(i,c,u){We.call(i,u)?i[u].push(c):Qr(i,u,[c])});function Bk(i,c,u,m){i=mn(i)?i:qi(i),u=u&&!m?be(u):0;var _=i.length;return u<0&&(u=Nt(_+u,0)),Lc(i)?u<=_&&i.indexOf(c,u)>-1:!!_&&Li(i,c,u)>-1}var Fk=Ie(function(i,c,u){var m=-1,_=typeof c=="function",E=mn(i)?V(i.length):[];return ko(i,function(b){E[++m]=_?bn(c,b,u):Za(b,c,u)}),E}),$k=Ec(function(i,c,u){Qr(i,u,c)});function Oc(i,c){var u=Ee(i)?st:xg;return u(i,he(c,3))}function Hk(i,c,u,m){return i==null?[]:(Ee(c)||(c=c==null?[]:[c]),u=m?t:u,Ee(u)||(u=u==null?[]:[u]),Fg(i,c,u))}var Kk=Ec(function(i,c,u){i[u?0:1].push(c)},function(){return[[],[]]});function Wk(i,c,u){var m=Ee(i)?Du:ug,_=arguments.length<3;return m(i,he(c,4),u,_,ko)}function zk(i,c,u){var m=Ee(i)?rS:ug,_=arguments.length<3;return m(i,he(c,4),u,_,Ng)}function Gk(i,c){var u=Ee(i)?bo:Og;return u(i,Mc(he(c,3)))}function qk(i){var c=Ee(i)?Sg:BI;return c(i)}function jk(i,c,u){(u?cn(i,c,u):c===t)?c=1:c=be(c);var m=Ee(i)?pI:FI;return m(i,c)}function Yk(i){var c=Ee(i)?vI:HI;return c(i)}function Jk(i){if(i==null)return 0;if(mn(i))return Lc(i)?Ui(i):i.length;var c=Jt(i);return c==Ft||c==oe?i.size:Zu(i).length}function Qk(i,c,u){var m=Ee(i)?Lu:KI;return u&&cn(i,c,u)&&(c=t),m(i,he(c,3))}var Xk=Ie(function(i,c){if(i==null)return[];var u=c.length;return u>1&&cn(i,c[0],c[1])?c=[]:u>2&&cn(c[0],c[1],c[2])&&(c=[c[0]]),Fg(i,Ht(c,1),[])}),Rc=PS||function(){return $t.Date.now()};function Zk(i,c){if(typeof c!="function")throw new Kn(l);return i=be(i),function(){if(--i<1)return c.apply(this,arguments)}}function Dp(i,c,u){return c=u?t:c,c=i&&c==null?i.length:c,Xr(i,R,t,t,t,t,c)}function Lp(i,c){var u;if(typeof c!="function")throw new Kn(l);return i=be(i),function(){return--i>0&&(u=c.apply(this,arguments)),i<=1&&(c=t),u}}var Td=Ie(function(i,c,u){var m=S;if(u.length){var _=Io(u,zi(Td));m|=U}return Xr(i,m,c,u,_)}),xp=Ie(function(i,c,u){var m=S|I;if(u.length){var _=Io(u,zi(xp));m|=U}return Xr(c,m,i,u,_)});function Up(i,c,u){c=u?t:c;var m=Xr(i,D,t,t,t,t,t,c);return m.placeholder=Up.placeholder,m}function Vp(i,c,u){c=u?t:c;var m=Xr(i,L,t,t,t,t,t,c);return m.placeholder=Vp.placeholder,m}function Bp(i,c,u){var m,_,E,b,A,M,z=0,G=!1,j=!1,te=!0;if(typeof i!="function")throw new Kn(l);c=jn(c)||0,ut(u)&&(G=!!u.leading,j="maxWait"in u,E=j?Nt(jn(u.maxWait)||0,c):E,te="trailing"in u?!!u.trailing:te);function ce(vt){var fr=m,ro=_;return m=_=t,z=vt,b=i.apply(ro,fr),b}function fe(vt){return z=vt,A=os(Oe,c),G?ce(vt):b}function Se(vt){var fr=vt-M,ro=vt-z,ov=c-fr;return j?Yt(ov,E-ro):ov}function me(vt){var fr=vt-M,ro=vt-z;return M===t||fr>=c||fr<0||j&&ro>=E}function Oe(){var vt=Rc();if(me(vt))return Pe(vt);A=os(Oe,Se(vt))}function Pe(vt){return A=t,te&&m?ce(vt):(m=_=t,b)}function kn(){A!==t&&Yg(A),z=0,m=M=_=A=t}function ln(){return A===t?b:Pe(Rc())}function Nn(){var vt=Rc(),fr=me(vt);if(m=arguments,_=this,M=vt,fr){if(A===t)return fe(M);if(j)return Yg(A),A=os(Oe,c),ce(M)}return A===t&&(A=os(Oe,c)),b}return Nn.cancel=kn,Nn.flush=ln,Nn}var eN=Ie(function(i,c){return kg(i,1,c)}),tN=Ie(function(i,c,u){return kg(i,jn(c)||0,u)});function nN(i){return Xr(i,se)}function Pc(i,c){if(typeof i!="function"||c!=null&&typeof c!="function")throw new Kn(l);var u=function(){var m=arguments,_=c?c.apply(this,m):m[0],E=u.cache;if(E.has(_))return E.get(_);var b=i.apply(this,m);return u.cache=E.set(_,b)||E,b};return u.cache=new(Pc.Cache||Jr),u}Pc.Cache=Jr;function Mc(i){if(typeof i!="function")throw new Kn(l);return function(){var c=arguments;switch(c.length){case 0:return!i.call(this);case 1:return!i.call(this,c[0]);case 2:return!i.call(this,c[0],c[1]);case 3:return!i.call(this,c[0],c[1],c[2])}return!i.apply(this,c)}}function rN(i){return Lp(2,i)}var oN=WI(function(i,c){c=c.length==1&&Ee(c[0])?st(c[0],Sn(he())):st(Ht(c,1),Sn(he()));var u=c.length;return Ie(function(m){for(var _=-1,E=Yt(m.length,u);++_<E;)m[_]=c[_].call(this,m[_]);return bn(i,this,m)})}),bd=Ie(function(i,c){var u=Io(c,zi(bd));return Xr(i,U,t,c,u)}),Fp=Ie(function(i,c){var u=Io(c,zi(Fp));return Xr(i,F,t,c,u)}),iN=Zr(function(i,c){return Xr(i,ae,t,t,t,c)});function aN(i,c){if(typeof i!="function")throw new Kn(l);return c=c===t?c:be(c),Ie(i,c)}function sN(i,c){if(typeof i!="function")throw new Kn(l);return c=c==null?0:Nt(be(c),0),Ie(function(u){var m=u[c],_=Ro(u,0,c);return m&&So(_,m),bn(i,this,_)})}function cN(i,c,u){var m=!0,_=!0;if(typeof i!="function")throw new Kn(l);return ut(u)&&(m="leading"in u?!!u.leading:m,_="trailing"in u?!!u.trailing:_),Bp(i,c,{leading:m,maxWait:c,trailing:_})}function lN(i){return Dp(i,1)}function uN(i,c){return bd(cd(c),i)}function dN(){if(!arguments.length)return[];var i=arguments[0];return Ee(i)?i:[i]}function hN(i){return zn(i,w)}function fN(i,c){return c=typeof c=="function"?c:t,zn(i,w,c)}function mN(i){return zn(i,v|w)}function gN(i,c){return c=typeof c=="function"?c:t,zn(i,v|w,c)}function pN(i,c){return c==null||Ag(i,c,Lt(c))}function hr(i,c){return i===c||i!==i&&c!==c}var vN=Sc(Ju),_N=Sc(function(i,c){return i>=c}),li=Mg(function(){return arguments}())?Mg:function(i){return dt(i)&&We.call(i,"callee")&&!yg.call(i,"callee")},Ee=V.isArray,yN=eg?Sn(eg):AI;function mn(i){return i!=null&&Dc(i.length)&&!to(i)}function pt(i){return dt(i)&&mn(i)}function CN(i){return i===!0||i===!1||dt(i)&&sn(i)==kr}var Po=DS||Ld,EN=tg?Sn(tg):kI;function wN(i){return dt(i)&&i.nodeType===1&&!is(i)}function TN(i){if(i==null)return!0;if(mn(i)&&(Ee(i)||typeof i=="string"||typeof i.splice=="function"||Po(i)||Gi(i)||li(i)))return!i.length;var c=Jt(i);if(c==Ft||c==oe)return!i.size;if(rs(i))return!Zu(i).length;for(var u in i)if(We.call(i,u))return!1;return!0}function bN(i,c){return es(i,c)}function SN(i,c,u){u=typeof u=="function"?u:t;var m=u?u(i,c):t;return m===t?es(i,c,t,u):!!m}function Sd(i){if(!dt(i))return!1;var c=sn(i);return c==Co||c==Ka||typeof i.message=="string"&&typeof i.name=="string"&&!is(i)}function IN(i){return typeof i=="number"&&Eg(i)}function to(i){if(!ut(i))return!1;var c=sn(i);return c==Eo||c==wo||c==Ha||c==O}function $p(i){return typeof i=="number"&&i==be(i)}function Dc(i){return typeof i=="number"&&i>-1&&i%1==0&&i<=at}function ut(i){var c=typeof i;return i!=null&&(c=="object"||c=="function")}function dt(i){return i!=null&&typeof i=="object"}var Hp=ng?Sn(ng):OI;function AN(i,c){return i===c||Xu(i,c,gd(c))}function kN(i,c,u){return u=typeof u=="function"?u:t,Xu(i,c,gd(c),u)}function NN(i){return Kp(i)&&i!=+i}function ON(i){if(fA(i))throw new Ce(a);return Dg(i)}function RN(i){return i===null}function PN(i){return i==null}function Kp(i){return typeof i=="number"||dt(i)&&sn(i)==wn}function is(i){if(!dt(i)||sn(i)!=Tn)return!1;var c=sc(i);if(c===null)return!0;var u=We.call(c,"constructor")&&c.constructor;return typeof u=="function"&&u instanceof u&&rc.call(u)==kS}var Id=rg?Sn(rg):RI;function MN(i){return $p(i)&&i>=-at&&i<=at}var Wp=og?Sn(og):PI;function Lc(i){return typeof i=="string"||!Ee(i)&&dt(i)&&sn(i)==Je}function An(i){return typeof i=="symbol"||dt(i)&&sn(i)==et}var Gi=ig?Sn(ig):MI;function DN(i){return i===t}function LN(i){return dt(i)&&Jt(i)==H}function xN(i){return dt(i)&&sn(i)==J}var UN=Sc(ed),VN=Sc(function(i,c){return i<=c});function zp(i){if(!i)return[];if(mn(i))return Lc(i)?ur(i):fn(i);if(Ga&&i[Ga])return pS(i[Ga]());var c=Jt(i),u=c==Ft?$u:c==oe?ec:qi;return u(i)}function no(i){if(!i)return i===0?i:0;if(i=jn(i),i===Dt||i===-Dt){var c=i<0?-1:1;return c*Et}return i===i?i:0}function be(i){var c=no(i),u=c%1;return c===c?u?c-u:c:0}function Gp(i){return i?ii(be(i),0,At):0}function jn(i){if(typeof i=="number")return i;if(An(i))return an;if(ut(i)){var c=typeof i.valueOf=="function"?i.valueOf():i;i=ut(c)?c+"":c}if(typeof i!="string")return i===0?i:+i;i=dg(i);var u=yb.test(i);return u||Eb.test(i)?Zb(i.slice(2),u?2:8):_b.test(i)?an:+i}function qp(i){return Rr(i,gn(i))}function BN(i){return i?ii(be(i),-at,at):i===0?i:0}function Ke(i){return i==null?"":In(i)}var FN=Ki(function(i,c){if(rs(c)||mn(c)){Rr(c,Lt(c),i);return}for(var u in c)We.call(c,u)&&Qa(i,u,c[u])}),jp=Ki(function(i,c){Rr(c,gn(c),i)}),xc=Ki(function(i,c,u,m){Rr(c,gn(c),i,m)}),$N=Ki(function(i,c,u,m){Rr(c,Lt(c),i,m)}),HN=Zr(qu);function KN(i,c){var u=Hi(i);return c==null?u:Ig(u,c)}var WN=Ie(function(i,c){i=Qe(i);var u=-1,m=c.length,_=m>2?c[2]:t;for(_&&cn(c[0],c[1],_)&&(m=1);++u<m;)for(var E=c[u],b=gn(E),A=-1,M=b.length;++A<M;){var z=b[A],G=i[z];(G===t||hr(G,Bi[z])&&!We.call(i,z))&&(i[z]=E[z])}return i}),zN=Ie(function(i){return i.push(t,dp),bn(Yp,t,i)});function GN(i,c){return sg(i,he(c,3),Or)}function qN(i,c){return sg(i,he(c,3),Yu)}function jN(i,c){return i==null?i:ju(i,he(c,3),gn)}function YN(i,c){return i==null?i:Rg(i,he(c,3),gn)}function JN(i,c){return i&&Or(i,he(c,3))}function QN(i,c){return i&&Yu(i,he(c,3))}function XN(i){return i==null?[]:vc(i,Lt(i))}function ZN(i){return i==null?[]:vc(i,gn(i))}function Ad(i,c,u){var m=i==null?t:ai(i,c);return m===t?u:m}function eO(i,c){return i!=null&&mp(i,c,TI)}function kd(i,c){return i!=null&&mp(i,c,bI)}var tO=ap(function(i,c,u){c!=null&&typeof c.toString!="function"&&(c=oc.call(c)),i[c]=u},Od(pn)),nO=ap(function(i,c,u){c!=null&&typeof c.toString!="function"&&(c=oc.call(c)),We.call(i,c)?i[c].push(u):i[c]=[u]},he),rO=Ie(Za);function Lt(i){return mn(i)?bg(i):Zu(i)}function gn(i){return mn(i)?bg(i,!0):DI(i)}function oO(i,c){var u={};return c=he(c,3),Or(i,function(m,_,E){Qr(u,c(m,_,E),m)}),u}function iO(i,c){var u={};return c=he(c,3),Or(i,function(m,_,E){Qr(u,_,c(m,_,E))}),u}var aO=Ki(function(i,c,u){_c(i,c,u)}),Yp=Ki(function(i,c,u,m){_c(i,c,u,m)}),sO=Zr(function(i,c){var u={};if(i==null)return u;var m=!1;c=st(c,function(E){return E=Oo(E,i),m||(m=E.length>1),E}),Rr(i,fd(i),u),m&&(u=zn(u,v|p|w,tA));for(var _=c.length;_--;)id(u,c[_]);return u});function cO(i,c){return Jp(i,Mc(he(c)))}var lO=Zr(function(i,c){return i==null?{}:xI(i,c)});function Jp(i,c){if(i==null)return{};var u=st(fd(i),function(m){return[m]});return c=he(c),$g(i,u,function(m,_){return c(m,_[0])})}function uO(i,c,u){c=Oo(c,i);var m=-1,_=c.length;for(_||(_=1,i=t);++m<_;){var E=i==null?t:i[Pr(c[m])];E===t&&(m=_,E=u),i=to(E)?E.call(i):E}return i}function dO(i,c,u){return i==null?i:ts(i,c,u)}function hO(i,c,u,m){return m=typeof m=="function"?m:t,i==null?i:ts(i,c,u,m)}var Qp=lp(Lt),Xp=lp(gn);function fO(i,c,u){var m=Ee(i),_=m||Po(i)||Gi(i);if(c=he(c,4),u==null){var E=i&&i.constructor;_?u=m?new E:[]:ut(i)?u=to(E)?Hi(sc(i)):{}:u={}}return(_?Hn:Or)(i,function(b,A,M){return c(u,b,A,M)}),u}function mO(i,c){return i==null?!0:id(i,c)}function gO(i,c,u){return i==null?i:Gg(i,c,cd(u))}function pO(i,c,u,m){return m=typeof m=="function"?m:t,i==null?i:Gg(i,c,cd(u),m)}function qi(i){return i==null?[]:Fu(i,Lt(i))}function vO(i){return i==null?[]:Fu(i,gn(i))}function _O(i,c,u){return u===t&&(u=c,c=t),u!==t&&(u=jn(u),u=u===u?u:0),c!==t&&(c=jn(c),c=c===c?c:0),ii(jn(i),c,u)}function yO(i,c,u){return c=no(c),u===t?(u=c,c=0):u=no(u),i=jn(i),SI(i,c,u)}function CO(i,c,u){if(u&&typeof u!="boolean"&&cn(i,c,u)&&(c=u=t),u===t&&(typeof c=="boolean"?(u=c,c=t):typeof i=="boolean"&&(u=i,i=t)),i===t&&c===t?(i=0,c=1):(i=no(i),c===t?(c=i,i=0):c=no(c)),i>c){var m=i;i=c,c=m}if(u||i%1||c%1){var _=wg();return Yt(i+_*(c-i+Xb("1e-"+((_+"").length-1))),c)}return nd(i,c)}var EO=Wi(function(i,c,u){return c=c.toLowerCase(),i+(u?Zp(c):c)});function Zp(i){return Nd(Ke(i).toLowerCase())}function ev(i){return i=Ke(i),i&&i.replace(Tb,dS).replace(Hb,"")}function wO(i,c,u){i=Ke(i),c=In(c);var m=i.length;u=u===t?m:ii(be(u),0,m);var _=u;return u-=c.length,u>=0&&i.slice(u,_)==c}function TO(i){return i=Ke(i),i&&rb.test(i)?i.replace(Rm,hS):i}function bO(i){return i=Ke(i),i&&lb.test(i)?i.replace(bu,"\\$&"):i}var SO=Wi(function(i,c,u){return i+(u?"-":"")+c.toLowerCase()}),IO=Wi(function(i,c,u){return i+(u?" ":"")+c.toLowerCase()}),AO=rp("toLowerCase");function kO(i,c,u){i=Ke(i),c=be(c);var m=c?Ui(i):0;if(!c||m>=c)return i;var _=(c-m)/2;return bc(dc(_),u)+i+bc(uc(_),u)}function NO(i,c,u){i=Ke(i),c=be(c);var m=c?Ui(i):0;return c&&m<c?i+bc(c-m,u):i}function OO(i,c,u){i=Ke(i),c=be(c);var m=c?Ui(i):0;return c&&m<c?bc(c-m,u)+i:i}function RO(i,c,u){return u||c==null?c=0:c&&(c=+c),VS(Ke(i).replace(Su,""),c||0)}function PO(i,c,u){return(u?cn(i,c,u):c===t)?c=1:c=be(c),rd(Ke(i),c)}function MO(){var i=arguments,c=Ke(i[0]);return i.length<3?c:c.replace(i[1],i[2])}var DO=Wi(function(i,c,u){return i+(u?"_":"")+c.toLowerCase()});function LO(i,c,u){return u&&typeof u!="number"&&cn(i,c,u)&&(c=u=t),u=u===t?At:u>>>0,u?(i=Ke(i),i&&(typeof c=="string"||c!=null&&!Id(c))&&(c=In(c),!c&&xi(i))?Ro(ur(i),0,u):i.split(c,u)):[]}var xO=Wi(function(i,c,u){return i+(u?" ":"")+Nd(c)});function UO(i,c,u){return i=Ke(i),u=u==null?0:ii(be(u),0,i.length),c=In(c),i.slice(u,u+c.length)==c}function VO(i,c,u){var m=y.templateSettings;u&&cn(i,c,u)&&(c=t),i=Ke(i),c=xc({},c,m,up);var _=xc({},c.imports,m.imports,up),E=Lt(_),b=Fu(_,E),A,M,z=0,G=c.interpolate||Ys,j="__p += '",te=Hu((c.escape||Ys).source+"|"+G.source+"|"+(G===Pm?vb:Ys).source+"|"+(c.evaluate||Ys).source+"|$","g"),ce="//# sourceURL="+(We.call(c,"sourceURL")?(c.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++qb+"]")+`
|
|
42
|
+
`;i.replace(te,function(me,Oe,Pe,kn,ln,Nn){return Pe||(Pe=kn),j+=i.slice(z,Nn).replace(bb,fS),Oe&&(A=!0,j+=`' +
|
|
43
|
+
__e(`+Oe+`) +
|
|
44
|
+
'`),ln&&(M=!0,j+=`';
|
|
45
|
+
`+ln+`;
|
|
46
|
+
__p += '`),Pe&&(j+=`' +
|
|
47
|
+
((__t = (`+Pe+`)) == null ? '' : __t) +
|
|
48
|
+
'`),z=Nn+me.length,me}),j+=`';
|
|
49
|
+
`;var fe=We.call(c,"variable")&&c.variable;if(!fe)j=`with (obj) {
|
|
50
|
+
`+j+`
|
|
51
|
+
}
|
|
52
|
+
`;else if(gb.test(fe))throw new Ce(d);j=(M?j.replace(ZT,""):j).replace(eb,"$1").replace(tb,"$1;"),j="function("+(fe||"obj")+`) {
|
|
53
|
+
`+(fe?"":`obj || (obj = {});
|
|
54
|
+
`)+"var __t, __p = ''"+(A?", __e = _.escape":"")+(M?`, __j = Array.prototype.join;
|
|
55
|
+
function print() { __p += __j.call(arguments, '') }
|
|
56
|
+
`:`;
|
|
57
|
+
`)+j+`return __p
|
|
58
|
+
}`;var Se=nv(function(){return $e(E,ce+"return "+j).apply(t,b)});if(Se.source=j,Sd(Se))throw Se;return Se}function BO(i){return Ke(i).toLowerCase()}function FO(i){return Ke(i).toUpperCase()}function $O(i,c,u){if(i=Ke(i),i&&(u||c===t))return dg(i);if(!i||!(c=In(c)))return i;var m=ur(i),_=ur(c),E=hg(m,_),b=fg(m,_)+1;return Ro(m,E,b).join("")}function HO(i,c,u){if(i=Ke(i),i&&(u||c===t))return i.slice(0,gg(i)+1);if(!i||!(c=In(c)))return i;var m=ur(i),_=fg(m,ur(c))+1;return Ro(m,0,_).join("")}function KO(i,c,u){if(i=Ke(i),i&&(u||c===t))return i.replace(Su,"");if(!i||!(c=In(c)))return i;var m=ur(i),_=hg(m,ur(c));return Ro(m,_).join("")}function WO(i,c){var u=X,m=ee;if(ut(c)){var _="separator"in c?c.separator:_;u="length"in c?be(c.length):u,m="omission"in c?In(c.omission):m}i=Ke(i);var E=i.length;if(xi(i)){var b=ur(i);E=b.length}if(u>=E)return i;var A=u-Ui(m);if(A<1)return m;var M=b?Ro(b,0,A).join(""):i.slice(0,A);if(_===t)return M+m;if(b&&(A+=M.length-A),Id(_)){if(i.slice(A).search(_)){var z,G=M;for(_.global||(_=Hu(_.source,Ke(Mm.exec(_))+"g")),_.lastIndex=0;z=_.exec(G);)var j=z.index;M=M.slice(0,j===t?A:j)}}else if(i.indexOf(In(_),A)!=A){var te=M.lastIndexOf(_);te>-1&&(M=M.slice(0,te))}return M+m}function zO(i){return i=Ke(i),i&&nb.test(i)?i.replace(Om,CS):i}var GO=Wi(function(i,c,u){return i+(u?" ":"")+c.toUpperCase()}),Nd=rp("toUpperCase");function tv(i,c,u){return i=Ke(i),c=u?t:c,c===t?gS(i)?TS(i):aS(i):i.match(c)||[]}var nv=Ie(function(i,c){try{return bn(i,t,c)}catch(u){return Sd(u)?u:new Ce(u)}}),qO=Zr(function(i,c){return Hn(c,function(u){u=Pr(u),Qr(i,u,Td(i[u],i))}),i});function jO(i){var c=i==null?0:i.length,u=he();return i=c?st(i,function(m){if(typeof m[1]!="function")throw new Kn(l);return[u(m[0]),m[1]]}):[],Ie(function(m){for(var _=-1;++_<c;){var E=i[_];if(bn(E[0],this,m))return bn(E[1],this,m)}})}function YO(i){return CI(zn(i,v))}function Od(i){return function(){return i}}function JO(i,c){return i==null||i!==i?c:i}var QO=ip(),XO=ip(!0);function pn(i){return i}function Rd(i){return Lg(typeof i=="function"?i:zn(i,v))}function ZO(i){return Ug(zn(i,v))}function eR(i,c){return Vg(i,zn(c,v))}var tR=Ie(function(i,c){return function(u){return Za(u,i,c)}}),nR=Ie(function(i,c){return function(u){return Za(i,u,c)}});function Pd(i,c,u){var m=Lt(c),_=vc(c,m);u==null&&!(ut(c)&&(_.length||!m.length))&&(u=c,c=i,i=this,_=vc(c,Lt(c)));var E=!(ut(u)&&"chain"in u)||!!u.chain,b=to(i);return Hn(_,function(A){var M=c[A];i[A]=M,b&&(i.prototype[A]=function(){var z=this.__chain__;if(E||z){var G=i(this.__wrapped__),j=G.__actions__=fn(this.__actions__);return j.push({func:M,args:arguments,thisArg:i}),G.__chain__=z,G}return M.apply(i,So([this.value()],arguments))})}),i}function rR(){return $t._===this&&($t._=NS),this}function Md(){}function oR(i){return i=be(i),Ie(function(c){return Bg(c,i)})}var iR=ud(st),aR=ud(ag),sR=ud(Lu);function rv(i){return vd(i)?xu(Pr(i)):UI(i)}function cR(i){return function(c){return i==null?t:ai(i,c)}}var lR=sp(),uR=sp(!0);function Dd(){return[]}function Ld(){return!1}function dR(){return{}}function hR(){return""}function fR(){return!0}function mR(i,c){if(i=be(i),i<1||i>at)return[];var u=At,m=Yt(i,At);c=he(c),i-=At;for(var _=Bu(m,c);++u<i;)c(u);return _}function gR(i){return Ee(i)?st(i,Pr):An(i)?[i]:fn(Tp(Ke(i)))}function pR(i){var c=++AS;return Ke(i)+c}var vR=Tc(function(i,c){return i+c},0),_R=dd("ceil"),yR=Tc(function(i,c){return i/c},1),CR=dd("floor");function ER(i){return i&&i.length?pc(i,pn,Ju):t}function wR(i,c){return i&&i.length?pc(i,he(c,2),Ju):t}function TR(i){return lg(i,pn)}function bR(i,c){return lg(i,he(c,2))}function SR(i){return i&&i.length?pc(i,pn,ed):t}function IR(i,c){return i&&i.length?pc(i,he(c,2),ed):t}var AR=Tc(function(i,c){return i*c},1),kR=dd("round"),NR=Tc(function(i,c){return i-c},0);function OR(i){return i&&i.length?Vu(i,pn):0}function RR(i,c){return i&&i.length?Vu(i,he(c,2)):0}return y.after=Zk,y.ary=Dp,y.assign=FN,y.assignIn=jp,y.assignInWith=xc,y.assignWith=$N,y.at=HN,y.before=Lp,y.bind=Td,y.bindAll=qO,y.bindKey=xp,y.castArray=dN,y.chain=Rp,y.chunk=CA,y.compact=EA,y.concat=wA,y.cond=jO,y.conforms=YO,y.constant=Od,y.countBy=Ok,y.create=KN,y.curry=Up,y.curryRight=Vp,y.debounce=Bp,y.defaults=WN,y.defaultsDeep=zN,y.defer=eN,y.delay=tN,y.difference=TA,y.differenceBy=bA,y.differenceWith=SA,y.drop=IA,y.dropRight=AA,y.dropRightWhile=kA,y.dropWhile=NA,y.fill=OA,y.filter=Pk,y.flatMap=Lk,y.flatMapDeep=xk,y.flatMapDepth=Uk,y.flatten=Ap,y.flattenDeep=RA,y.flattenDepth=PA,y.flip=nN,y.flow=QO,y.flowRight=XO,y.fromPairs=MA,y.functions=XN,y.functionsIn=ZN,y.groupBy=Vk,y.initial=LA,y.intersection=xA,y.intersectionBy=UA,y.intersectionWith=VA,y.invert=tO,y.invertBy=nO,y.invokeMap=Fk,y.iteratee=Rd,y.keyBy=$k,y.keys=Lt,y.keysIn=gn,y.map=Oc,y.mapKeys=oO,y.mapValues=iO,y.matches=ZO,y.matchesProperty=eR,y.memoize=Pc,y.merge=aO,y.mergeWith=Yp,y.method=tR,y.methodOf=nR,y.mixin=Pd,y.negate=Mc,y.nthArg=oR,y.omit=sO,y.omitBy=cO,y.once=rN,y.orderBy=Hk,y.over=iR,y.overArgs=oN,y.overEvery=aR,y.overSome=sR,y.partial=bd,y.partialRight=Fp,y.partition=Kk,y.pick=lO,y.pickBy=Jp,y.property=rv,y.propertyOf=cR,y.pull=HA,y.pullAll=Np,y.pullAllBy=KA,y.pullAllWith=WA,y.pullAt=zA,y.range=lR,y.rangeRight=uR,y.rearg=iN,y.reject=Gk,y.remove=GA,y.rest=aN,y.reverse=Ed,y.sampleSize=jk,y.set=dO,y.setWith=hO,y.shuffle=Yk,y.slice=qA,y.sortBy=Xk,y.sortedUniq=ek,y.sortedUniqBy=tk,y.split=LO,y.spread=sN,y.tail=nk,y.take=rk,y.takeRight=ok,y.takeRightWhile=ik,y.takeWhile=ak,y.tap=Ek,y.throttle=cN,y.thru=Nc,y.toArray=zp,y.toPairs=Qp,y.toPairsIn=Xp,y.toPath=gR,y.toPlainObject=qp,y.transform=fO,y.unary=lN,y.union=sk,y.unionBy=ck,y.unionWith=lk,y.uniq=uk,y.uniqBy=dk,y.uniqWith=hk,y.unset=mO,y.unzip=wd,y.unzipWith=Op,y.update=gO,y.updateWith=pO,y.values=qi,y.valuesIn=vO,y.without=fk,y.words=tv,y.wrap=uN,y.xor=mk,y.xorBy=gk,y.xorWith=pk,y.zip=vk,y.zipObject=_k,y.zipObjectDeep=yk,y.zipWith=Ck,y.entries=Qp,y.entriesIn=Xp,y.extend=jp,y.extendWith=xc,Pd(y,y),y.add=vR,y.attempt=nv,y.camelCase=EO,y.capitalize=Zp,y.ceil=_R,y.clamp=_O,y.clone=hN,y.cloneDeep=mN,y.cloneDeepWith=gN,y.cloneWith=fN,y.conformsTo=pN,y.deburr=ev,y.defaultTo=JO,y.divide=yR,y.endsWith=wO,y.eq=hr,y.escape=TO,y.escapeRegExp=bO,y.every=Rk,y.find=Mk,y.findIndex=Sp,y.findKey=GN,y.findLast=Dk,y.findLastIndex=Ip,y.findLastKey=qN,y.floor=CR,y.forEach=Pp,y.forEachRight=Mp,y.forIn=jN,y.forInRight=YN,y.forOwn=JN,y.forOwnRight=QN,y.get=Ad,y.gt=vN,y.gte=_N,y.has=eO,y.hasIn=kd,y.head=kp,y.identity=pn,y.includes=Bk,y.indexOf=DA,y.inRange=yO,y.invoke=rO,y.isArguments=li,y.isArray=Ee,y.isArrayBuffer=yN,y.isArrayLike=mn,y.isArrayLikeObject=pt,y.isBoolean=CN,y.isBuffer=Po,y.isDate=EN,y.isElement=wN,y.isEmpty=TN,y.isEqual=bN,y.isEqualWith=SN,y.isError=Sd,y.isFinite=IN,y.isFunction=to,y.isInteger=$p,y.isLength=Dc,y.isMap=Hp,y.isMatch=AN,y.isMatchWith=kN,y.isNaN=NN,y.isNative=ON,y.isNil=PN,y.isNull=RN,y.isNumber=Kp,y.isObject=ut,y.isObjectLike=dt,y.isPlainObject=is,y.isRegExp=Id,y.isSafeInteger=MN,y.isSet=Wp,y.isString=Lc,y.isSymbol=An,y.isTypedArray=Gi,y.isUndefined=DN,y.isWeakMap=LN,y.isWeakSet=xN,y.join=BA,y.kebabCase=SO,y.last=qn,y.lastIndexOf=FA,y.lowerCase=IO,y.lowerFirst=AO,y.lt=UN,y.lte=VN,y.max=ER,y.maxBy=wR,y.mean=TR,y.meanBy=bR,y.min=SR,y.minBy=IR,y.stubArray=Dd,y.stubFalse=Ld,y.stubObject=dR,y.stubString=hR,y.stubTrue=fR,y.multiply=AR,y.nth=$A,y.noConflict=rR,y.noop=Md,y.now=Rc,y.pad=kO,y.padEnd=NO,y.padStart=OO,y.parseInt=RO,y.random=CO,y.reduce=Wk,y.reduceRight=zk,y.repeat=PO,y.replace=MO,y.result=uO,y.round=kR,y.runInContext=P,y.sample=qk,y.size=Jk,y.snakeCase=DO,y.some=Qk,y.sortedIndex=jA,y.sortedIndexBy=YA,y.sortedIndexOf=JA,y.sortedLastIndex=QA,y.sortedLastIndexBy=XA,y.sortedLastIndexOf=ZA,y.startCase=xO,y.startsWith=UO,y.subtract=NR,y.sum=OR,y.sumBy=RR,y.template=VO,y.times=mR,y.toFinite=no,y.toInteger=be,y.toLength=Gp,y.toLower=BO,y.toNumber=jn,y.toSafeInteger=BN,y.toString=Ke,y.toUpper=FO,y.trim=$O,y.trimEnd=HO,y.trimStart=KO,y.truncate=WO,y.unescape=zO,y.uniqueId=pR,y.upperCase=GO,y.upperFirst=Nd,y.each=Pp,y.eachRight=Mp,y.first=kp,Pd(y,function(){var i={};return Or(y,function(c,u){We.call(y.prototype,u)||(i[u]=c)}),i}(),{chain:!1}),y.VERSION=r,Hn(["bind","bindKey","curry","curryRight","partial","partialRight"],function(i){y[i].placeholder=y}),Hn(["drop","take"],function(i,c){Re.prototype[i]=function(u){u=u===t?1:Nt(be(u),0);var m=this.__filtered__&&!c?new Re(this):this.clone();return m.__filtered__?m.__takeCount__=Yt(u,m.__takeCount__):m.__views__.push({size:Yt(u,At),type:i+(m.__dir__<0?"Right":"")}),m},Re.prototype[i+"Right"]=function(u){return this.reverse()[i](u).reverse()}}),Hn(["filter","map","takeWhile"],function(i,c){var u=c+1,m=u==Ct||u==jt;Re.prototype[i]=function(_){var E=this.clone();return E.__iteratees__.push({iteratee:he(_,3),type:u}),E.__filtered__=E.__filtered__||m,E}}),Hn(["head","last"],function(i,c){var u="take"+(c?"Right":"");Re.prototype[i]=function(){return this[u](1).value()[0]}}),Hn(["initial","tail"],function(i,c){var u="drop"+(c?"":"Right");Re.prototype[i]=function(){return this.__filtered__?new Re(this):this[u](1)}}),Re.prototype.compact=function(){return this.filter(pn)},Re.prototype.find=function(i){return this.filter(i).head()},Re.prototype.findLast=function(i){return this.reverse().find(i)},Re.prototype.invokeMap=Ie(function(i,c){return typeof i=="function"?new Re(this):this.map(function(u){return Za(u,i,c)})}),Re.prototype.reject=function(i){return this.filter(Mc(he(i)))},Re.prototype.slice=function(i,c){i=be(i);var u=this;return u.__filtered__&&(i>0||c<0)?new Re(u):(i<0?u=u.takeRight(-i):i&&(u=u.drop(i)),c!==t&&(c=be(c),u=c<0?u.dropRight(-c):u.take(c-i)),u)},Re.prototype.takeRightWhile=function(i){return this.reverse().takeWhile(i).reverse()},Re.prototype.toArray=function(){return this.take(At)},Or(Re.prototype,function(i,c){var u=/^(?:filter|find|map|reject)|While$/.test(c),m=/^(?:head|last)$/.test(c),_=y[m?"take"+(c=="last"?"Right":""):c],E=m||/^find/.test(c);_&&(y.prototype[c]=function(){var b=this.__wrapped__,A=m?[1]:arguments,M=b instanceof Re,z=A[0],G=M||Ee(b),j=function(Oe){var Pe=_.apply(y,So([Oe],A));return m&&te?Pe[0]:Pe};G&&u&&typeof z=="function"&&z.length!=1&&(M=G=!1);var te=this.__chain__,ce=!!this.__actions__.length,fe=E&&!te,Se=M&&!ce;if(!E&&G){b=Se?b:new Re(this);var me=i.apply(b,A);return me.__actions__.push({func:Nc,args:[j],thisArg:t}),new Wn(me,te)}return fe&&Se?i.apply(this,A):(me=this.thru(j),fe?m?me.value()[0]:me.value():me)})}),Hn(["pop","push","shift","sort","splice","unshift"],function(i){var c=tc[i],u=/^(?:push|sort|unshift)$/.test(i)?"tap":"thru",m=/^(?:pop|shift)$/.test(i);y.prototype[i]=function(){var _=arguments;if(m&&!this.__chain__){var E=this.value();return c.apply(Ee(E)?E:[],_)}return this[u](function(b){return c.apply(Ee(b)?b:[],_)})}}),Or(Re.prototype,function(i,c){var u=y[c];if(u){var m=u.name+"";We.call($i,m)||($i[m]=[]),$i[m].push({name:c,func:u})}}),$i[wc(t,I).name]=[{name:"wrapper",func:t}],Re.prototype.clone=zS,Re.prototype.reverse=GS,Re.prototype.value=qS,y.prototype.at=wk,y.prototype.chain=Tk,y.prototype.commit=bk,y.prototype.next=Sk,y.prototype.plant=Ak,y.prototype.reverse=kk,y.prototype.toJSON=y.prototype.valueOf=y.prototype.value=Nk,y.prototype.first=y.prototype.head,Ga&&(y.prototype[Ga]=Ik),y},Vi=bS();ti?((ti.exports=Vi)._=Vi,Ru._=Vi):$t._=Vi}).call(aD)}(ds,ds.exports)),ds.exports}var Oi=sD();const ul=iD(Oi);/*!
|
|
59
|
+
* vue-draggable-next v2.2.0
|
|
60
|
+
* (c) 2023 Anish George
|
|
61
|
+
* @license MIT
|
|
62
|
+
*//**!
|
|
63
|
+
* Sortable 1.14.0
|
|
64
|
+
* @author RubaXa <trash@rubaxa.org>
|
|
65
|
+
* @author owenm <owen23355@gmail.com>
|
|
66
|
+
* @license MIT
|
|
67
|
+
*/function r_(n,e){var t=Object.keys(n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(n);e&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable})),t.push.apply(t,r)}return t}function zr(n){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?r_(Object(t),!0).forEach(function(r){cD(n,r,t[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(t)):r_(Object(t)).forEach(function(r){Object.defineProperty(n,r,Object.getOwnPropertyDescriptor(t,r))})}return n}function dl(n){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?dl=function(e){return typeof e}:dl=function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},dl(n)}function cD(n,e,t){return e in n?Object.defineProperty(n,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):n[e]=t,n}function vo(){return vo=Object.assign||function(n){for(var e=1;e<arguments.length;e++){var t=arguments[e];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(n[r]=t[r])}return n},vo.apply(this,arguments)}function lD(n,e){if(n==null)return{};var t={},r=Object.keys(n),o,a;for(a=0;a<r.length;a++)o=r[a],!(e.indexOf(o)>=0)&&(t[o]=n[o]);return t}function uD(n,e){if(n==null)return{};var t=lD(n,e),r,o;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(n);for(o=0;o<a.length;o++)r=a[o],!(e.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(n,r)&&(t[r]=n[r])}return t}var dD="1.14.0";function go(n){if(typeof window<"u"&&window.navigator)return!!navigator.userAgent.match(n)}var yo=go(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),Fs=go(/Edge/i),o_=go(/firefox/i),ps=go(/safari/i)&&!go(/chrome/i)&&!go(/android/i),eE=go(/iP(ad|od|hone)/i),hD=go(/chrome/i)&&go(/android/i),tE={capture:!1,passive:!1};function He(n,e,t){n.addEventListener(e,t,!yo&&tE)}function Ve(n,e,t){n.removeEventListener(e,t,!yo&&tE)}function El(n,e){if(e){if(e[0]===">"&&(e=e.substring(1)),n)try{if(n.matches)return n.matches(e);if(n.msMatchesSelector)return n.msMatchesSelector(e);if(n.webkitMatchesSelector)return n.webkitMatchesSelector(e)}catch{return!1}return!1}}function fD(n){return n.host&&n!==document&&n.host.nodeType?n.host:n.parentNode}function xr(n,e,t,r){if(n){t=t||document;do{if(e!=null&&(e[0]===">"?n.parentNode===t&&El(n,e):El(n,e))||r&&n===t)return n;if(n===t)break}while(n=fD(n))}return null}var i_=/\s+/g;function On(n,e,t){if(n&&e)if(n.classList)n.classList[t?"add":"remove"](e);else{var r=(" "+n.className+" ").replace(i_," ").replace(" "+e+" "," ");n.className=(r+(t?" "+e:"")).replace(i_," ")}}function ve(n,e,t){var r=n&&n.style;if(r){if(t===void 0)return document.defaultView&&document.defaultView.getComputedStyle?t=document.defaultView.getComputedStyle(n,""):n.currentStyle&&(t=n.currentStyle),e===void 0?t:t[e];!(e in r)&&e.indexOf("webkit")===-1&&(e="-webkit-"+e),r[e]=t+(typeof t=="string"?"":"px")}}function Ca(n,e){var t="";if(typeof n=="string")t=n;else do{var r=ve(n,"transform");r&&r!=="none"&&(t=r+" "+t)}while(!e&&(n=n.parentNode));var o=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return o&&new o(t)}function nE(n,e,t){if(n){var r=n.getElementsByTagName(e),o=0,a=r.length;if(t)for(;o<a;o++)t(r[o],o);return r}return[]}function Kr(){var n=document.scrollingElement;return n||document.documentElement}function Rt(n,e,t,r,o){if(!(!n.getBoundingClientRect&&n!==window)){var a,l,d,h,f,g,v;if(n!==window&&n.parentNode&&n!==Kr()?(a=n.getBoundingClientRect(),l=a.top,d=a.left,h=a.bottom,f=a.right,g=a.height,v=a.width):(l=0,d=0,h=window.innerHeight,f=window.innerWidth,g=window.innerHeight,v=window.innerWidth),(e||t)&&n!==window&&(o=o||n.parentNode,!yo))do if(o&&o.getBoundingClientRect&&(ve(o,"transform")!=="none"||t&&ve(o,"position")!=="static")){var p=o.getBoundingClientRect();l-=p.top+parseInt(ve(o,"border-top-width")),d-=p.left+parseInt(ve(o,"border-left-width")),h=l+a.height,f=d+a.width;break}while(o=o.parentNode);if(r&&n!==window){var w=Ca(o||n),C=w&&w.a,T=w&&w.d;w&&(l/=T,d/=C,v/=C,g/=T,h=l+g,f=d+v)}return{top:l,left:d,bottom:h,right:f,width:v,height:g}}}function a_(n,e,t){for(var r=Ho(n,!0),o=Rt(n)[e];r;){var a=Rt(r)[t],l=void 0;if(l=o>=a,!l)return r;if(r===Kr())break;r=Ho(r,!1)}return!1}function Ia(n,e,t,r){for(var o=0,a=0,l=n.children;a<l.length;){if(l[a].style.display!=="none"&&l[a]!==_e.ghost&&(r||l[a]!==_e.dragged)&&xr(l[a],t.draggable,n,!1)){if(o===e)return l[a];o++}a++}return null}function Rf(n,e){for(var t=n.lastElementChild;t&&(t===_e.ghost||ve(t,"display")==="none"||e&&!El(t,e));)t=t.previousElementSibling;return t||null}function rr(n,e){var t=0;if(!n||!n.parentNode)return-1;for(;n=n.previousElementSibling;)n.nodeName.toUpperCase()!=="TEMPLATE"&&n!==_e.clone&&(!e||El(n,e))&&t++;return t}function s_(n){var e=0,t=0,r=Kr();if(n)do{var o=Ca(n),a=o.a,l=o.d;e+=n.scrollLeft*a,t+=n.scrollTop*l}while(n!==r&&(n=n.parentNode));return[e,t]}function mD(n,e){for(var t in n)if(n.hasOwnProperty(t)){for(var r in e)if(e.hasOwnProperty(r)&&e[r]===n[t][r])return Number(t)}return-1}function Ho(n,e){if(!n||!n.getBoundingClientRect)return Kr();var t=n,r=!1;do if(t.clientWidth<t.scrollWidth||t.clientHeight<t.scrollHeight){var o=ve(t);if(t.clientWidth<t.scrollWidth&&(o.overflowX=="auto"||o.overflowX=="scroll")||t.clientHeight<t.scrollHeight&&(o.overflowY=="auto"||o.overflowY=="scroll")){if(!t.getBoundingClientRect||t===document.body)return Kr();if(r||e)return t;r=!0}}while(t=t.parentNode);return Kr()}function gD(n,e){if(n&&e)for(var t in e)e.hasOwnProperty(t)&&(n[t]=e[t]);return n}function zd(n,e){return Math.round(n.top)===Math.round(e.top)&&Math.round(n.left)===Math.round(e.left)&&Math.round(n.height)===Math.round(e.height)&&Math.round(n.width)===Math.round(e.width)}var vs;function rE(n,e){return function(){if(!vs){var t=arguments,r=this;t.length===1?n.call(r,t[0]):n.apply(r,t),vs=setTimeout(function(){vs=void 0},e)}}}function pD(){clearTimeout(vs),vs=void 0}function oE(n,e,t){n.scrollLeft+=e,n.scrollTop+=t}function iE(n){var e=window.Polymer,t=window.jQuery||window.Zepto;return e&&e.dom?e.dom(n).cloneNode(!0):t?t(n).clone(!0)[0]:n.cloneNode(!0)}var Un="Sortable"+new Date().getTime();function vD(){var n=[],e;return{captureAnimationState:function(){if(n=[],!!this.options.animation){var r=[].slice.call(this.el.children);r.forEach(function(o){if(!(ve(o,"display")==="none"||o===_e.ghost)){n.push({target:o,rect:Rt(o)});var a=zr({},n[n.length-1].rect);if(o.thisAnimationDuration){var l=Ca(o,!0);l&&(a.top-=l.f,a.left-=l.e)}o.fromRect=a}})}},addAnimationState:function(r){n.push(r)},removeAnimationState:function(r){n.splice(mD(n,{target:r}),1)},animateAll:function(r){var o=this;if(!this.options.animation){clearTimeout(e),typeof r=="function"&&r();return}var a=!1,l=0;n.forEach(function(d){var h=0,f=d.target,g=f.fromRect,v=Rt(f),p=f.prevFromRect,w=f.prevToRect,C=d.rect,T=Ca(f,!0);T&&(v.top-=T.f,v.left-=T.e),f.toRect=v,f.thisAnimationDuration&&zd(p,v)&&!zd(g,v)&&(C.top-v.top)/(C.left-v.left)===(g.top-v.top)/(g.left-v.left)&&(h=yD(C,p,w,o.options)),zd(v,g)||(f.prevFromRect=g,f.prevToRect=v,h||(h=o.options.animation),o.animate(f,C,v,h)),h&&(a=!0,l=Math.max(l,h),clearTimeout(f.animationResetTimer),f.animationResetTimer=setTimeout(function(){f.animationTime=0,f.prevFromRect=null,f.fromRect=null,f.prevToRect=null,f.thisAnimationDuration=null},h),f.thisAnimationDuration=h)}),clearTimeout(e),a?e=setTimeout(function(){typeof r=="function"&&r()},l):typeof r=="function"&&r(),n=[]},animate:function(r,o,a,l){if(l){ve(r,"transition",""),ve(r,"transform","");var d=Ca(this.el),h=d&&d.a,f=d&&d.d,g=(o.left-a.left)/(h||1),v=(o.top-a.top)/(f||1);r.animatingX=!!g,r.animatingY=!!v,ve(r,"transform","translate3d("+g+"px,"+v+"px,0)"),this.forRepaintDummy=_D(r),ve(r,"transition","transform "+l+"ms"+(this.options.easing?" "+this.options.easing:"")),ve(r,"transform","translate3d(0,0,0)"),typeof r.animated=="number"&&clearTimeout(r.animated),r.animated=setTimeout(function(){ve(r,"transition",""),ve(r,"transform",""),r.animated=!1,r.animatingX=!1,r.animatingY=!1},l)}}}}function _D(n){return n.offsetWidth}function yD(n,e,t,r){return Math.sqrt(Math.pow(e.top-n.top,2)+Math.pow(e.left-n.left,2))/Math.sqrt(Math.pow(e.top-t.top,2)+Math.pow(e.left-t.left,2))*r.animation}var Qi=[],Gd={initializeByDefault:!0},$s={mount:function(e){for(var t in Gd)Gd.hasOwnProperty(t)&&!(t in e)&&(e[t]=Gd[t]);Qi.forEach(function(r){if(r.pluginName===e.pluginName)throw"Sortable: Cannot mount plugin ".concat(e.pluginName," more than once")}),Qi.push(e)},pluginEvent:function(e,t,r){var o=this;this.eventCanceled=!1,r.cancel=function(){o.eventCanceled=!0};var a=e+"Global";Qi.forEach(function(l){t[l.pluginName]&&(t[l.pluginName][a]&&t[l.pluginName][a](zr({sortable:t},r)),t.options[l.pluginName]&&t[l.pluginName][e]&&t[l.pluginName][e](zr({sortable:t},r)))})},initializePlugins:function(e,t,r,o){Qi.forEach(function(d){var h=d.pluginName;if(!(!e.options[h]&&!d.initializeByDefault)){var f=new d(e,t,e.options);f.sortable=e,f.options=e.options,e[h]=f,vo(r,f.defaults)}});for(var a in e.options)if(e.options.hasOwnProperty(a)){var l=this.modifyOption(e,a,e.options[a]);typeof l<"u"&&(e.options[a]=l)}},getEventProperties:function(e,t){var r={};return Qi.forEach(function(o){typeof o.eventProperties=="function"&&vo(r,o.eventProperties.call(t[o.pluginName],e))}),r},modifyOption:function(e,t,r){var o;return Qi.forEach(function(a){e[a.pluginName]&&a.optionListeners&&typeof a.optionListeners[t]=="function"&&(o=a.optionListeners[t].call(e[a.pluginName],r))}),o}};function CD(n){var e=n.sortable,t=n.rootEl,r=n.name,o=n.targetEl,a=n.cloneEl,l=n.toEl,d=n.fromEl,h=n.oldIndex,f=n.newIndex,g=n.oldDraggableIndex,v=n.newDraggableIndex,p=n.originalEvent,w=n.putSortable,C=n.extraEventProperties;if(e=e||t&&t[Un],!!e){var T,S=e.options,I="on"+r.charAt(0).toUpperCase()+r.substr(1);window.CustomEvent&&!yo&&!Fs?T=new CustomEvent(r,{bubbles:!0,cancelable:!0}):(T=document.createEvent("Event"),T.initEvent(r,!0,!0)),T.to=l||t,T.from=d||t,T.item=o||t,T.clone=a,T.oldIndex=h,T.newIndex=f,T.oldDraggableIndex=g,T.newDraggableIndex=v,T.originalEvent=p,T.pullMode=w?w.lastPutMode:void 0;var N=zr(zr({},C),$s.getEventProperties(r,e));for(var D in N)T[D]=N[D];t&&t.dispatchEvent(T),S[I]&&S[I].call(e,T)}}var ED=["evt"],vn=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=r.evt,a=uD(r,ED);$s.pluginEvent.bind(_e)(e,t,zr({dragEl:Z,parentEl:ft,ghostEl:we,rootEl:ct,nextEl:fi,lastDownEl:hl,cloneEl:mt,cloneHidden:Vo,dragStarted:hs,putSortable:Gt,activeSortable:_e.active,originalEvent:o,oldIndex:pa,oldDraggableIndex:_s,newIndex:Rn,newDraggableIndex:Uo,hideGhostForTarget:lE,unhideGhostForTarget:uE,cloneNowHidden:function(){Vo=!0},cloneNowShown:function(){Vo=!1},dispatchSortableEvent:function(d){un({sortable:t,name:d,originalEvent:o})}},a))};function un(n){CD(zr({putSortable:Gt,cloneEl:mt,targetEl:Z,rootEl:ct,oldIndex:pa,oldDraggableIndex:_s,newIndex:Rn,newDraggableIndex:Uo},n))}var Z,ft,we,ct,fi,hl,mt,Vo,pa,Rn,_s,Uo,Hc,Gt,la=!1,wl=!1,Tl=[],ui,mr,qd,jd,c_,l_,hs,Xi,ys,Cs=!1,Kc=!1,fl,Qt,Yd=[],Lh=!1,bl=[],Ql=typeof document<"u",Wc=eE,u_=Fs||yo?"cssFloat":"float",wD=Ql&&!hD&&!eE&&"draggable"in document.createElement("div"),aE=function(){if(Ql){if(yo)return!1;var n=document.createElement("x");return n.style.cssText="pointer-events:auto",n.style.pointerEvents==="auto"}}(),sE=function(e,t){var r=ve(e),o=parseInt(r.width)-parseInt(r.paddingLeft)-parseInt(r.paddingRight)-parseInt(r.borderLeftWidth)-parseInt(r.borderRightWidth),a=Ia(e,0,t),l=Ia(e,1,t),d=a&&ve(a),h=l&&ve(l),f=d&&parseInt(d.marginLeft)+parseInt(d.marginRight)+Rt(a).width,g=h&&parseInt(h.marginLeft)+parseInt(h.marginRight)+Rt(l).width;if(r.display==="flex")return r.flexDirection==="column"||r.flexDirection==="column-reverse"?"vertical":"horizontal";if(r.display==="grid")return r.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal";if(a&&d.float&&d.float!=="none"){var v=d.float==="left"?"left":"right";return l&&(h.clear==="both"||h.clear===v)?"vertical":"horizontal"}return a&&(d.display==="block"||d.display==="flex"||d.display==="table"||d.display==="grid"||f>=o&&r[u_]==="none"||l&&r[u_]==="none"&&f+g>o)?"vertical":"horizontal"},TD=function(e,t,r){var o=r?e.left:e.top,a=r?e.right:e.bottom,l=r?e.width:e.height,d=r?t.left:t.top,h=r?t.right:t.bottom,f=r?t.width:t.height;return o===d||a===h||o+l/2===d+f/2},bD=function(e,t){var r;return Tl.some(function(o){var a=o[Un].options.emptyInsertThreshold;if(!(!a||Rf(o))){var l=Rt(o),d=e>=l.left-a&&e<=l.right+a,h=t>=l.top-a&&t<=l.bottom+a;if(d&&h)return r=o}}),r},cE=function(e){function t(a,l){return function(d,h,f,g){var v=d.options.group.name&&h.options.group.name&&d.options.group.name===h.options.group.name;if(a==null&&(l||v))return!0;if(a==null||a===!1)return!1;if(l&&a==="clone")return a;if(typeof a=="function")return t(a(d,h,f,g),l)(d,h,f,g);var p=(l?d:h).options.group.name;return a===!0||typeof a=="string"&&a===p||a.join&&a.indexOf(p)>-1}}var r={},o=e.group;(!o||dl(o)!="object")&&(o={name:o}),r.name=o.name,r.checkPull=t(o.pull,!0),r.checkPut=t(o.put),r.revertClone=o.revertClone,e.group=r},lE=function(){!aE&&we&&ve(we,"display","none")},uE=function(){!aE&&we&&ve(we,"display","")};Ql&&document.addEventListener("click",function(n){if(wl)return n.preventDefault(),n.stopPropagation&&n.stopPropagation(),n.stopImmediatePropagation&&n.stopImmediatePropagation(),wl=!1,!1},!0);var di=function(e){if(Z){e=e.touches?e.touches[0]:e;var t=bD(e.clientX,e.clientY);if(t){var r={};for(var o in e)e.hasOwnProperty(o)&&(r[o]=e[o]);r.target=r.rootEl=t,r.preventDefault=void 0,r.stopPropagation=void 0,t[Un]._onDragOver(r)}}},SD=function(e){Z&&Z.parentNode[Un]._isOutsideThisEl(e.target)};function _e(n,e){if(!(n&&n.nodeType&&n.nodeType===1))throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(n));this.el=n,this.options=e=vo({},e),n[Un]=this;var t={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(n.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return sE(n,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(l,d){l.setData("Text",d.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,delayOnTouchOnly:!1,touchStartThreshold:(Number.parseInt?Number:window).parseInt(window.devicePixelRatio,10)||1,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:_e.supportPointer!==!1&&"PointerEvent"in window&&!ps,emptyInsertThreshold:5};$s.initializePlugins(this,n,t);for(var r in t)!(r in e)&&(e[r]=t[r]);cE(e);for(var o in this)o.charAt(0)==="_"&&typeof this[o]=="function"&&(this[o]=this[o].bind(this));this.nativeDraggable=e.forceFallback?!1:wD,this.nativeDraggable&&(this.options.touchStartThreshold=1),e.supportPointer?He(n,"pointerdown",this._onTapStart):(He(n,"mousedown",this._onTapStart),He(n,"touchstart",this._onTapStart)),this.nativeDraggable&&(He(n,"dragover",this),He(n,"dragenter",this)),Tl.push(this.el),e.store&&e.store.get&&this.sort(e.store.get(this)||[]),vo(this,vD())}_e.prototype={constructor:_e,_isOutsideThisEl:function(e){!this.el.contains(e)&&e!==this.el&&(Xi=null)},_getDirection:function(e,t){return typeof this.options.direction=="function"?this.options.direction.call(this,e,t,Z):this.options.direction},_onTapStart:function(e){if(e.cancelable){var t=this,r=this.el,o=this.options,a=o.preventOnFilter,l=e.type,d=e.touches&&e.touches[0]||e.pointerType&&e.pointerType==="touch"&&e,h=(d||e).target,f=e.target.shadowRoot&&(e.path&&e.path[0]||e.composedPath&&e.composedPath()[0])||h,g=o.filter;if(MD(r),!Z&&!(/mousedown|pointerdown/.test(l)&&e.button!==0||o.disabled)&&!f.isContentEditable&&!(!this.nativeDraggable&&ps&&h&&h.tagName.toUpperCase()==="SELECT")&&(h=xr(h,o.draggable,r,!1),!(h&&h.animated)&&hl!==h)){if(pa=rr(h),_s=rr(h,o.draggable),typeof g=="function"){if(g.call(this,e,h,this)){un({sortable:t,rootEl:f,name:"filter",targetEl:h,toEl:r,fromEl:r}),vn("filter",t,{evt:e}),a&&e.cancelable&&e.preventDefault();return}}else if(g&&(g=g.split(",").some(function(v){if(v=xr(f,v.trim(),r,!1),v)return un({sortable:t,rootEl:v,name:"filter",targetEl:h,fromEl:r,toEl:r}),vn("filter",t,{evt:e}),!0}),g)){a&&e.cancelable&&e.preventDefault();return}o.handle&&!xr(f,o.handle,r,!1)||this._prepareDragStart(e,d,h)}}},_prepareDragStart:function(e,t,r){var o=this,a=o.el,l=o.options,d=a.ownerDocument,h;if(r&&!Z&&r.parentNode===a){var f=Rt(r);if(ct=a,Z=r,ft=Z.parentNode,fi=Z.nextSibling,hl=r,Hc=l.group,_e.dragged=Z,ui={target:Z,clientX:(t||e).clientX,clientY:(t||e).clientY},c_=ui.clientX-f.left,l_=ui.clientY-f.top,this._lastX=(t||e).clientX,this._lastY=(t||e).clientY,Z.style["will-change"]="all",h=function(){if(vn("delayEnded",o,{evt:e}),_e.eventCanceled){o._onDrop();return}o._disableDelayedDragEvents(),!o_&&o.nativeDraggable&&(Z.draggable=!0),o._triggerDragStart(e,t),un({sortable:o,name:"choose",originalEvent:e}),On(Z,l.chosenClass,!0)},l.ignore.split(",").forEach(function(g){nE(Z,g.trim(),Jd)}),He(d,"dragover",di),He(d,"mousemove",di),He(d,"touchmove",di),He(d,"mouseup",o._onDrop),He(d,"touchend",o._onDrop),He(d,"touchcancel",o._onDrop),o_&&this.nativeDraggable&&(this.options.touchStartThreshold=4,Z.draggable=!0),vn("delayStart",this,{evt:e}),l.delay&&(!l.delayOnTouchOnly||t)&&(!this.nativeDraggable||!(Fs||yo))){if(_e.eventCanceled){this._onDrop();return}He(d,"mouseup",o._disableDelayedDrag),He(d,"touchend",o._disableDelayedDrag),He(d,"touchcancel",o._disableDelayedDrag),He(d,"mousemove",o._delayedDragTouchMoveHandler),He(d,"touchmove",o._delayedDragTouchMoveHandler),l.supportPointer&&He(d,"pointermove",o._delayedDragTouchMoveHandler),o._dragStartTimer=setTimeout(h,l.delay)}else h()}},_delayedDragTouchMoveHandler:function(e){var t=e.touches?e.touches[0]:e;Math.max(Math.abs(t.clientX-this._lastX),Math.abs(t.clientY-this._lastY))>=Math.floor(this.options.touchStartThreshold/(this.nativeDraggable&&window.devicePixelRatio||1))&&this._disableDelayedDrag()},_disableDelayedDrag:function(){Z&&Jd(Z),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var e=this.el.ownerDocument;Ve(e,"mouseup",this._disableDelayedDrag),Ve(e,"touchend",this._disableDelayedDrag),Ve(e,"touchcancel",this._disableDelayedDrag),Ve(e,"mousemove",this._delayedDragTouchMoveHandler),Ve(e,"touchmove",this._delayedDragTouchMoveHandler),Ve(e,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(e,t){t=t||e.pointerType=="touch"&&e,!this.nativeDraggable||t?this.options.supportPointer?He(document,"pointermove",this._onTouchMove):t?He(document,"touchmove",this._onTouchMove):He(document,"mousemove",this._onTouchMove):(He(Z,"dragend",this),He(ct,"dragstart",this._onDragStart));try{document.selection?ml(function(){document.selection.empty()}):window.getSelection().removeAllRanges()}catch{}},_dragStarted:function(e,t){if(la=!1,ct&&Z){vn("dragStarted",this,{evt:t}),this.nativeDraggable&&He(document,"dragover",SD);var r=this.options;!e&&On(Z,r.dragClass,!1),On(Z,r.ghostClass,!0),_e.active=this,e&&this._appendGhost(),un({sortable:this,name:"start",originalEvent:t})}else this._nulling()},_emulateDragOver:function(){if(mr){this._lastX=mr.clientX,this._lastY=mr.clientY,lE();for(var e=document.elementFromPoint(mr.clientX,mr.clientY),t=e;e&&e.shadowRoot&&(e=e.shadowRoot.elementFromPoint(mr.clientX,mr.clientY),e!==t);)t=e;if(Z.parentNode[Un]._isOutsideThisEl(e),t)do{if(t[Un]){var r=void 0;if(r=t[Un]._onDragOver({clientX:mr.clientX,clientY:mr.clientY,target:e,rootEl:t}),r&&!this.options.dragoverBubble)break}e=t}while(t=t.parentNode);uE()}},_onTouchMove:function(e){if(ui){var t=this.options,r=t.fallbackTolerance,o=t.fallbackOffset,a=e.touches?e.touches[0]:e,l=we&&Ca(we,!0),d=we&&l&&l.a,h=we&&l&&l.d,f=Wc&&Qt&&s_(Qt),g=(a.clientX-ui.clientX+o.x)/(d||1)+(f?f[0]-Yd[0]:0)/(d||1),v=(a.clientY-ui.clientY+o.y)/(h||1)+(f?f[1]-Yd[1]:0)/(h||1);if(!_e.active&&!la){if(r&&Math.max(Math.abs(a.clientX-this._lastX),Math.abs(a.clientY-this._lastY))<r)return;this._onDragStart(e,!0)}if(we){l?(l.e+=g-(qd||0),l.f+=v-(jd||0)):l={a:1,b:0,c:0,d:1,e:g,f:v};var p="matrix(".concat(l.a,",").concat(l.b,",").concat(l.c,",").concat(l.d,",").concat(l.e,",").concat(l.f,")");ve(we,"webkitTransform",p),ve(we,"mozTransform",p),ve(we,"msTransform",p),ve(we,"transform",p),qd=g,jd=v,mr=a}e.cancelable&&e.preventDefault()}},_appendGhost:function(){if(!we){var e=this.options.fallbackOnBody?document.body:ct,t=Rt(Z,!0,Wc,!0,e),r=this.options;if(Wc){for(Qt=e;ve(Qt,"position")==="static"&&ve(Qt,"transform")==="none"&&Qt!==document;)Qt=Qt.parentNode;Qt!==document.body&&Qt!==document.documentElement?(Qt===document&&(Qt=Kr()),t.top+=Qt.scrollTop,t.left+=Qt.scrollLeft):Qt=Kr(),Yd=s_(Qt)}we=Z.cloneNode(!0),On(we,r.ghostClass,!1),On(we,r.fallbackClass,!0),On(we,r.dragClass,!0),ve(we,"transition",""),ve(we,"transform",""),ve(we,"box-sizing","border-box"),ve(we,"margin",0),ve(we,"top",t.top),ve(we,"left",t.left),ve(we,"width",t.width),ve(we,"height",t.height),ve(we,"opacity","0.8"),ve(we,"position",Wc?"absolute":"fixed"),ve(we,"zIndex","100000"),ve(we,"pointerEvents","none"),_e.ghost=we,e.appendChild(we),ve(we,"transform-origin",c_/parseInt(we.style.width)*100+"% "+l_/parseInt(we.style.height)*100+"%")}},_onDragStart:function(e,t){var r=this,o=e.dataTransfer,a=r.options;if(vn("dragStart",this,{evt:e}),_e.eventCanceled){this._onDrop();return}vn("setupClone",this),_e.eventCanceled||(mt=iE(Z),mt.draggable=!1,mt.style["will-change"]="",this._hideClone(),On(mt,this.options.chosenClass,!1),_e.clone=mt),r.cloneId=ml(function(){vn("clone",r),!_e.eventCanceled&&(r.options.removeCloneOnHide||ct.insertBefore(mt,Z),r._hideClone(),un({sortable:r,name:"clone"}))}),!t&&On(Z,a.dragClass,!0),t?(wl=!0,r._loopId=setInterval(r._emulateDragOver,50)):(Ve(document,"mouseup",r._onDrop),Ve(document,"touchend",r._onDrop),Ve(document,"touchcancel",r._onDrop),o&&(o.effectAllowed="move",a.setData&&a.setData.call(r,o,Z)),He(document,"drop",r),ve(Z,"transform","translateZ(0)")),la=!0,r._dragStartId=ml(r._dragStarted.bind(r,t,e)),He(document,"selectstart",r),hs=!0,ps&&ve(document.body,"user-select","none")},_onDragOver:function(e){var t=this.el,r=e.target,o,a,l,d=this.options,h=d.group,f=_e.active,g=Hc===h,v=d.sort,p=Gt||f,w,C=this,T=!1;if(Lh)return;function S(at,Et){vn(at,C,zr({evt:e,isOwner:g,axis:w?"vertical":"horizontal",revert:l,dragRect:o,targetRect:a,canSort:v,fromSortable:p,target:r,completed:N,onMove:function(At,Xo){return zc(ct,t,Z,o,At,Rt(At),e,Xo)},changed:D},Et))}function I(){S("dragOverAnimationCapture"),C.captureAnimationState(),C!==p&&p.captureAnimationState()}function N(at){return S("dragOverCompleted",{insertion:at}),at&&(g?f._hideClone():f._showClone(C),C!==p&&(On(Z,Gt?Gt.options.ghostClass:f.options.ghostClass,!1),On(Z,d.ghostClass,!0)),Gt!==C&&C!==_e.active?Gt=C:C===_e.active&&Gt&&(Gt=null),p===C&&(C._ignoreWhileAnimating=r),C.animateAll(function(){S("dragOverAnimationComplete"),C._ignoreWhileAnimating=null}),C!==p&&(p.animateAll(),p._ignoreWhileAnimating=null)),(r===Z&&!Z.animated||r===t&&!r.animated)&&(Xi=null),!d.dragoverBubble&&!e.rootEl&&r!==document&&(Z.parentNode[Un]._isOutsideThisEl(e.target),!at&&di(e)),!d.dragoverBubble&&e.stopPropagation&&e.stopPropagation(),T=!0}function D(){Rn=rr(Z),Uo=rr(Z,d.draggable),un({sortable:C,name:"change",toEl:t,newIndex:Rn,newDraggableIndex:Uo,originalEvent:e})}if(e.preventDefault!==void 0&&e.cancelable&&e.preventDefault(),r=xr(r,d.draggable,t,!0),S("dragOver"),_e.eventCanceled)return T;if(Z.contains(e.target)||r.animated&&r.animatingX&&r.animatingY||C._ignoreWhileAnimating===r)return N(!1);if(wl=!1,f&&!d.disabled&&(g?v||(l=ft!==ct):Gt===this||(this.lastPutMode=Hc.checkPull(this,f,Z,e))&&h.checkPut(this,f,Z,e))){if(w=this._getDirection(e,r)==="vertical",o=Rt(Z),S("dragOverValid"),_e.eventCanceled)return T;if(l)return ft=ct,I(),this._hideClone(),S("revert"),_e.eventCanceled||(fi?ct.insertBefore(Z,fi):ct.appendChild(Z)),N(!0);var L=Rf(t,d.draggable);if(!L||ND(e,w,this)&&!L.animated){if(L===Z)return N(!1);if(L&&t===e.target&&(r=L),r&&(a=Rt(r)),zc(ct,t,Z,o,r,a,e,!!r)!==!1)return I(),t.appendChild(Z),ft=t,D(),N(!0)}else if(L&&kD(e,w,this)){var U=Ia(t,0,d,!0);if(U===Z)return N(!1);if(r=U,a=Rt(r),zc(ct,t,Z,o,r,a,e,!1)!==!1)return I(),t.insertBefore(Z,U),ft=t,D(),N(!0)}else if(r.parentNode===t){a=Rt(r);var F=0,R,ae=Z.parentNode!==t,se=!TD(Z.animated&&Z.toRect||o,r.animated&&r.toRect||a,w),X=w?"top":"left",ee=a_(r,"top","top")||a_(Z,"top","top"),de=ee?ee.scrollTop:void 0;Xi!==r&&(R=a[X],Cs=!1,Kc=!se&&d.invertSwap||ae),F=OD(e,r,a,w,se?1:d.swapThreshold,d.invertedSwapThreshold==null?d.swapThreshold:d.invertedSwapThreshold,Kc,Xi===r);var Fe;if(F!==0){var Ct=rr(Z);do Ct-=F,Fe=ft.children[Ct];while(Fe&&(ve(Fe,"display")==="none"||Fe===we))}if(F===0||Fe===r)return N(!1);Xi=r,ys=F;var on=r.nextElementSibling,jt=!1;jt=F===1;var Dt=zc(ct,t,Z,o,r,a,e,jt);if(Dt!==!1)return(Dt===1||Dt===-1)&&(jt=Dt===1),Lh=!0,setTimeout(AD,30),I(),jt&&!on?t.appendChild(Z):r.parentNode.insertBefore(Z,jt?on:r),ee&&oE(ee,0,de-ee.scrollTop),ft=Z.parentNode,R!==void 0&&!Kc&&(fl=Math.abs(R-Rt(r)[X])),D(),N(!0)}if(t.contains(Z))return N(!1)}return!1},_ignoreWhileAnimating:null,_offMoveEvents:function(){Ve(document,"mousemove",this._onTouchMove),Ve(document,"touchmove",this._onTouchMove),Ve(document,"pointermove",this._onTouchMove),Ve(document,"dragover",di),Ve(document,"mousemove",di),Ve(document,"touchmove",di)},_offUpEvents:function(){var e=this.el.ownerDocument;Ve(e,"mouseup",this._onDrop),Ve(e,"touchend",this._onDrop),Ve(e,"pointerup",this._onDrop),Ve(e,"touchcancel",this._onDrop),Ve(document,"selectstart",this)},_onDrop:function(e){var t=this.el,r=this.options;if(Rn=rr(Z),Uo=rr(Z,r.draggable),vn("drop",this,{evt:e}),ft=Z&&Z.parentNode,Rn=rr(Z),Uo=rr(Z,r.draggable),_e.eventCanceled){this._nulling();return}la=!1,Kc=!1,Cs=!1,clearInterval(this._loopId),clearTimeout(this._dragStartTimer),xh(this.cloneId),xh(this._dragStartId),this.nativeDraggable&&(Ve(document,"drop",this),Ve(t,"dragstart",this._onDragStart)),this._offMoveEvents(),this._offUpEvents(),ps&&ve(document.body,"user-select",""),ve(Z,"transform",""),e&&(hs&&(e.cancelable&&e.preventDefault(),!r.dropBubble&&e.stopPropagation()),we&&we.parentNode&&we.parentNode.removeChild(we),(ct===ft||Gt&&Gt.lastPutMode!=="clone")&&mt&&mt.parentNode&&mt.parentNode.removeChild(mt),Z&&(this.nativeDraggable&&Ve(Z,"dragend",this),Jd(Z),Z.style["will-change"]="",hs&&!la&&On(Z,Gt?Gt.options.ghostClass:this.options.ghostClass,!1),On(Z,this.options.chosenClass,!1),un({sortable:this,name:"unchoose",toEl:ft,newIndex:null,newDraggableIndex:null,originalEvent:e}),ct!==ft?(Rn>=0&&(un({rootEl:ft,name:"add",toEl:ft,fromEl:ct,originalEvent:e}),un({sortable:this,name:"remove",toEl:ft,originalEvent:e}),un({rootEl:ft,name:"sort",toEl:ft,fromEl:ct,originalEvent:e}),un({sortable:this,name:"sort",toEl:ft,originalEvent:e})),Gt&&Gt.save()):Rn!==pa&&Rn>=0&&(un({sortable:this,name:"update",toEl:ft,originalEvent:e}),un({sortable:this,name:"sort",toEl:ft,originalEvent:e})),_e.active&&((Rn==null||Rn===-1)&&(Rn=pa,Uo=_s),un({sortable:this,name:"end",toEl:ft,originalEvent:e}),this.save()))),this._nulling()},_nulling:function(){vn("nulling",this),ct=Z=ft=we=fi=mt=hl=Vo=ui=mr=hs=Rn=Uo=pa=_s=Xi=ys=Gt=Hc=_e.dragged=_e.ghost=_e.clone=_e.active=null,bl.forEach(function(e){e.checked=!0}),bl.length=qd=jd=0},handleEvent:function(e){switch(e.type){case"drop":case"dragend":this._onDrop(e);break;case"dragenter":case"dragover":Z&&(this._onDragOver(e),ID(e));break;case"selectstart":e.preventDefault();break}},toArray:function(){for(var e=[],t,r=this.el.children,o=0,a=r.length,l=this.options;o<a;o++)t=r[o],xr(t,l.draggable,this.el,!1)&&e.push(t.getAttribute(l.dataIdAttr)||PD(t));return e},sort:function(e,t){var r={},o=this.el;this.toArray().forEach(function(a,l){var d=o.children[l];xr(d,this.options.draggable,o,!1)&&(r[a]=d)},this),t&&this.captureAnimationState(),e.forEach(function(a){r[a]&&(o.removeChild(r[a]),o.appendChild(r[a]))}),t&&this.animateAll()},save:function(){var e=this.options.store;e&&e.set&&e.set(this)},closest:function(e,t){return xr(e,t||this.options.draggable,this.el,!1)},option:function(e,t){var r=this.options;if(t===void 0)return r[e];var o=$s.modifyOption(this,e,t);typeof o<"u"?r[e]=o:r[e]=t,e==="group"&&cE(r)},destroy:function(){vn("destroy",this);var e=this.el;e[Un]=null,Ve(e,"mousedown",this._onTapStart),Ve(e,"touchstart",this._onTapStart),Ve(e,"pointerdown",this._onTapStart),this.nativeDraggable&&(Ve(e,"dragover",this),Ve(e,"dragenter",this)),Array.prototype.forEach.call(e.querySelectorAll("[draggable]"),function(t){t.removeAttribute("draggable")}),this._onDrop(),this._disableDelayedDragEvents(),Tl.splice(Tl.indexOf(this.el),1),this.el=e=null},_hideClone:function(){if(!Vo){if(vn("hideClone",this),_e.eventCanceled)return;ve(mt,"display","none"),this.options.removeCloneOnHide&&mt.parentNode&&mt.parentNode.removeChild(mt),Vo=!0}},_showClone:function(e){if(e.lastPutMode!=="clone"){this._hideClone();return}if(Vo){if(vn("showClone",this),_e.eventCanceled)return;Z.parentNode==ct&&!this.options.group.revertClone?ct.insertBefore(mt,Z):fi?ct.insertBefore(mt,fi):ct.appendChild(mt),this.options.group.revertClone&&this.animate(Z,mt),ve(mt,"display",""),Vo=!1}}};function ID(n){n.dataTransfer&&(n.dataTransfer.dropEffect="move"),n.cancelable&&n.preventDefault()}function zc(n,e,t,r,o,a,l,d){var h,f=n[Un],g=f.options.onMove,v;return window.CustomEvent&&!yo&&!Fs?h=new CustomEvent("move",{bubbles:!0,cancelable:!0}):(h=document.createEvent("Event"),h.initEvent("move",!0,!0)),h.to=e,h.from=n,h.dragged=t,h.draggedRect=r,h.related=o||e,h.relatedRect=a||Rt(e),h.willInsertAfter=d,h.originalEvent=l,n.dispatchEvent(h),g&&(v=g.call(f,h,l)),v}function Jd(n){n.draggable=!1}function AD(){Lh=!1}function kD(n,e,t){var r=Rt(Ia(t.el,0,t.options,!0)),o=10;return e?n.clientX<r.left-o||n.clientY<r.top&&n.clientX<r.right:n.clientY<r.top-o||n.clientY<r.bottom&&n.clientX<r.left}function ND(n,e,t){var r=Rt(Rf(t.el,t.options.draggable)),o=10;return e?n.clientX>r.right+o||n.clientX<=r.right&&n.clientY>r.bottom&&n.clientX>=r.left:n.clientX>r.right&&n.clientY>r.top||n.clientX<=r.right&&n.clientY>r.bottom+o}function OD(n,e,t,r,o,a,l,d){var h=r?n.clientY:n.clientX,f=r?t.height:t.width,g=r?t.top:t.left,v=r?t.bottom:t.right,p=!1;if(!l){if(d&&fl<f*o){if(!Cs&&(ys===1?h>g+f*a/2:h<v-f*a/2)&&(Cs=!0),Cs)p=!0;else if(ys===1?h<g+fl:h>v-fl)return-ys}else if(h>g+f*(1-o)/2&&h<v-f*(1-o)/2)return RD(e)}return p=p||l,p&&(h<g+f*a/2||h>v-f*a/2)?h>g+f/2?1:-1:0}function RD(n){return rr(Z)<rr(n)?1:-1}function PD(n){for(var e=n.tagName+n.className+n.src+n.href+n.textContent,t=e.length,r=0;t--;)r+=e.charCodeAt(t);return r.toString(36)}function MD(n){bl.length=0;for(var e=n.getElementsByTagName("input"),t=e.length;t--;){var r=e[t];r.checked&&bl.push(r)}}function ml(n){return setTimeout(n,0)}function xh(n){return clearTimeout(n)}Ql&&He(document,"touchmove",function(n){(_e.active||la)&&n.cancelable&&n.preventDefault()});_e.utils={on:He,off:Ve,css:ve,find:nE,is:function(e,t){return!!xr(e,t,e,!1)},extend:gD,throttle:rE,closest:xr,toggleClass:On,clone:iE,index:rr,nextTick:ml,cancelNextTick:xh,detectDirection:sE,getChild:Ia};_e.get=function(n){return n[Un]};_e.mount=function(){for(var n=arguments.length,e=new Array(n),t=0;t<n;t++)e[t]=arguments[t];e[0].constructor===Array&&(e=e[0]),e.forEach(function(r){if(!r.prototype||!r.prototype.constructor)throw"Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(r));r.utils&&(_e.utils=zr(zr({},_e.utils),r.utils)),$s.mount(r)})};_e.create=function(n,e){return new _e(n,e)};_e.version=dD;var wt=[],fs,Uh,Vh=!1,Qd,Xd,Sl,ms;function DD(){function n(){this.defaults={scroll:!0,forceAutoScrollFallback:!1,scrollSensitivity:30,scrollSpeed:10,bubbleScroll:!0};for(var e in this)e.charAt(0)==="_"&&typeof this[e]=="function"&&(this[e]=this[e].bind(this))}return n.prototype={dragStarted:function(t){var r=t.originalEvent;this.sortable.nativeDraggable?He(document,"dragover",this._handleAutoScroll):this.options.supportPointer?He(document,"pointermove",this._handleFallbackAutoScroll):r.touches?He(document,"touchmove",this._handleFallbackAutoScroll):He(document,"mousemove",this._handleFallbackAutoScroll)},dragOverCompleted:function(t){var r=t.originalEvent;!this.options.dragOverBubble&&!r.rootEl&&this._handleAutoScroll(r)},drop:function(){this.sortable.nativeDraggable?Ve(document,"dragover",this._handleAutoScroll):(Ve(document,"pointermove",this._handleFallbackAutoScroll),Ve(document,"touchmove",this._handleFallbackAutoScroll),Ve(document,"mousemove",this._handleFallbackAutoScroll)),d_(),gl(),pD()},nulling:function(){Sl=Uh=fs=Vh=ms=Qd=Xd=null,wt.length=0},_handleFallbackAutoScroll:function(t){this._handleAutoScroll(t,!0)},_handleAutoScroll:function(t,r){var o=this,a=(t.touches?t.touches[0]:t).clientX,l=(t.touches?t.touches[0]:t).clientY,d=document.elementFromPoint(a,l);if(Sl=t,r||this.options.forceAutoScrollFallback||Fs||yo||ps){Zd(t,this.options,d,r);var h=Ho(d,!0);Vh&&(!ms||a!==Qd||l!==Xd)&&(ms&&d_(),ms=setInterval(function(){var f=Ho(document.elementFromPoint(a,l),!0);f!==h&&(h=f,gl()),Zd(t,o.options,f,r)},10),Qd=a,Xd=l)}else{if(!this.options.bubbleScroll||Ho(d,!0)===Kr()){gl();return}Zd(t,this.options,Ho(d,!1),!1)}}},vo(n,{pluginName:"scroll",initializeByDefault:!0})}function gl(){wt.forEach(function(n){clearInterval(n.pid)}),wt=[]}function d_(){clearInterval(ms)}var Zd=rE(function(n,e,t,r){if(e.scroll){var o=(n.touches?n.touches[0]:n).clientX,a=(n.touches?n.touches[0]:n).clientY,l=e.scrollSensitivity,d=e.scrollSpeed,h=Kr(),f=!1,g;Uh!==t&&(Uh=t,gl(),fs=e.scroll,g=e.scrollFn,fs===!0&&(fs=Ho(t,!0)));var v=0,p=fs;do{var w=p,C=Rt(w),T=C.top,S=C.bottom,I=C.left,N=C.right,D=C.width,L=C.height,U=void 0,F=void 0,R=w.scrollWidth,ae=w.scrollHeight,se=ve(w),X=w.scrollLeft,ee=w.scrollTop;w===h?(U=D<R&&(se.overflowX==="auto"||se.overflowX==="scroll"||se.overflowX==="visible"),F=L<ae&&(se.overflowY==="auto"||se.overflowY==="scroll"||se.overflowY==="visible")):(U=D<R&&(se.overflowX==="auto"||se.overflowX==="scroll"),F=L<ae&&(se.overflowY==="auto"||se.overflowY==="scroll"));var de=U&&(Math.abs(N-o)<=l&&X+D<R)-(Math.abs(I-o)<=l&&!!X),Fe=F&&(Math.abs(S-a)<=l&&ee+L<ae)-(Math.abs(T-a)<=l&&!!ee);if(!wt[v])for(var Ct=0;Ct<=v;Ct++)wt[Ct]||(wt[Ct]={});(wt[v].vx!=de||wt[v].vy!=Fe||wt[v].el!==w)&&(wt[v].el=w,wt[v].vx=de,wt[v].vy=Fe,clearInterval(wt[v].pid),(de!=0||Fe!=0)&&(f=!0,wt[v].pid=setInterval((function(){r&&this.layer===0&&_e.active._onTouchMove(Sl);var on=wt[this.layer].vy?wt[this.layer].vy*d:0,jt=wt[this.layer].vx?wt[this.layer].vx*d:0;typeof g=="function"&&g.call(_e.dragged.parentNode[Un],jt,on,n,Sl,wt[this.layer].el)!=="continue"||oE(wt[this.layer].el,jt,on)}).bind({layer:v}),24))),v++}while(e.bubbleScroll&&p!==h&&(p=Ho(p,!1)));Vh=f}},30),dE=function(e){var t=e.originalEvent,r=e.putSortable,o=e.dragEl,a=e.activeSortable,l=e.dispatchSortableEvent,d=e.hideGhostForTarget,h=e.unhideGhostForTarget;if(t){var f=r||a;d();var g=t.changedTouches&&t.changedTouches.length?t.changedTouches[0]:t,v=document.elementFromPoint(g.clientX,g.clientY);h(),f&&!f.el.contains(v)&&(l("spill"),this.onSpill({dragEl:o,putSortable:r}))}};function Pf(){}Pf.prototype={startIndex:null,dragStart:function(e){var t=e.oldDraggableIndex;this.startIndex=t},onSpill:function(e){var t=e.dragEl,r=e.putSortable;this.sortable.captureAnimationState(),r&&r.captureAnimationState();var o=Ia(this.sortable.el,this.startIndex,this.options);o?this.sortable.el.insertBefore(t,o):this.sortable.el.appendChild(t),this.sortable.animateAll(),r&&r.animateAll()},drop:dE};vo(Pf,{pluginName:"revertOnSpill"});function Mf(){}Mf.prototype={onSpill:function(e){var t=e.dragEl,r=e.putSortable,o=r||this.sortable;o.captureAnimationState(),t.parentNode&&t.parentNode.removeChild(t),o.animateAll()},drop:dE};vo(Mf,{pluginName:"removeOnSpill"});_e.mount(new DD);_e.mount(Mf,Pf);function LD(){return typeof window<"u"?window.console:global.console}const xD=LD();function UD(n){const e=Object.create(null);return function(r){return e[r]||(e[r]=n(r))}}const VD=/-(\w)/g,h_=UD(n=>n.replace(VD,(e,t)=>t?t.toUpperCase():""));function eh(n){n.parentElement!==null&&n.parentElement.removeChild(n)}function f_(n,e,t){const r=t===0?n.children[0]:n.children[t-1].nextSibling;n.insertBefore(e,r)}function BD(n,e){return Object.values(n).indexOf(e)}function FD(n,e,t,r){if(!n)return[];const o=Object.values(n),a=e.length-r;return[...e].map((d,h)=>h>=a?o.length:o.indexOf(d))}function hE(n,e){this.$nextTick(()=>this.$emit(n.toLowerCase(),e))}function $D(n){return e=>{this.realList!==null&&this["onDrag"+n](e),hE.call(this,n,e)}}function HD(n){return["transition-group","TransitionGroup"].includes(n)}function KD(n){if(!n||n.length!==1)return!1;const[{type:e}]=n;return e?HD(e.name):!1}function WD(n,e){return e?{...e.props,...e.attrs}:n}const Bh=["Start","Add","Remove","Update","End"],Fh=["Choose","Unchoose","Sort","Filter","Clone"],zD=["Move",...Bh,...Fh].map(n=>"on"+n);let th=null;const GD={options:Object,list:{type:Array,required:!1,default:null},noTransitionOnDrag:{type:Boolean,default:!1},clone:{type:Function,default:n=>n},tag:{type:String,default:"div"},move:{type:Function,default:null},componentData:{type:Object,required:!1,default:null},component:{type:String,default:null},modelValue:{type:Array,required:!1,default:null}},fE=s.defineComponent({name:"VueDraggableNext",inheritAttrs:!1,emits:["update:modelValue","move","change",...Bh.map(n=>n.toLowerCase()),...Fh.map(n=>n.toLowerCase())],props:GD,data(){return{transitionMode:!1,noneFunctionalComponentMode:!1,headerOffset:0,footerOffset:0,_sortable:{},visibleIndexes:[],context:{}}},render(){const n=this.$slots.default?this.$slots.default():null,e=WD(this.$attrs,this.componentData);return n?(this.transitionMode=KD(n),s.h(this.getTag(),e,n)):s.h(this.getTag(),e,[])},created(){this.list!==null&&this.modelValue!==null&&xD.error("list props are mutually exclusive! Please set one.")},mounted(){const n={};Bh.forEach(o=>{n["on"+o]=$D.call(this,o)}),Fh.forEach(o=>{n["on"+o]=hE.bind(this,o)});const e=Object.keys(this.$attrs).reduce((o,a)=>(o[h_(a)]=this.$attrs[a],o),{}),t=Object.assign({},e,n,{onMove:(o,a)=>this.onDragMove(o,a)});!("draggable"in t)&&(t.draggable=">*");const r=this.$el.nodeType===1?this.$el:this.$el.parentElement;this._sortable=new _e(r,t),r.__draggable_component__=this,this.computeIndexes()},beforeUnmount(){try{this._sortable!==void 0&&this._sortable.destroy()}catch{}},computed:{realList(){return this.list?this.list:this.modelValue}},watch:{$attrs:{handler(n){this.updateOptions(n)},deep:!0},realList(){this.computeIndexes()}},methods:{getTag(){return this.component?s.resolveComponent(this.component):this.tag},updateOptions(n){for(var e in n){const t=h_(e);zD.indexOf(t)===-1&&this._sortable.option(t,n[e])}},getChildrenNodes(){return this.$el.children},computeIndexes(){this.$nextTick(()=>{this.visibleIndexes=FD(this.getChildrenNodes(),this.$el.children,this.transitionMode,this.footerOffset)})},getUnderlyingVm(n){const e=BD(this.getChildrenNodes()||[],n);if(e===-1)return null;const t=this.realList[e];return{index:e,element:t}},emitChanges(n){this.$nextTick(()=>{this.$emit("change",n)})},alterList(n){if(this.list){n(this.list);return}const e=[...this.modelValue];n(e),this.$emit("update:modelValue",e)},spliceList(){const n=e=>e.splice(...arguments);this.alterList(n)},updatePosition(n,e){const t=r=>r.splice(e,0,r.splice(n,1)[0]);this.alterList(t)},getVmIndex(n){const e=this.visibleIndexes,t=e.length;return n>t-1?t:e[n]},getComponent(){return this.$slots.default?this.$slots.default()[0].componentInstance:null},resetTransitionData(n){if(!this.noTransitionOnDrag||!this.transitionMode)return;var e=this.getChildrenNodes();e[n].data=null;const t=this.getComponent();t.children=[],t.kept=void 0},onDragStart(n){this.computeIndexes(),this.context=this.getUnderlyingVm(n.item),this.context&&(n.item._underlying_vm_=this.clone(this.context.element),th=n.item)},onDragAdd(n){const e=n.item._underlying_vm_;if(e===void 0)return;eh(n.item);const t=this.getVmIndex(n.newIndex);this.spliceList(t,0,e),this.computeIndexes();const r={element:e,newIndex:t};this.emitChanges({added:r})},onDragRemove(n){if(f_(this.$el,n.item,n.oldIndex),n.pullMode==="clone"){eh(n.clone);return}if(!this.context)return;const e=this.context.index;this.spliceList(e,1);const t={element:this.context.element,oldIndex:e};this.resetTransitionData(e),this.emitChanges({removed:t})},onDragUpdate(n){eh(n.item),f_(n.from,n.item,n.oldIndex);const e=this.context.index,t=this.getVmIndex(n.newIndex);this.updatePosition(e,t);const r={element:this.context.element,oldIndex:e,newIndex:t};this.emitChanges({moved:r})},updateProperty(n,e){n.hasOwnProperty(e)&&(n[e]+=this.headerOffset)},onDragMove(n,e){const t=this.move;if(!t||!this.realList)return!0;const r=this.getRelatedContextFromMoveEvent(n),o=this.context,a=this.computeFutureIndex(r,n);Object.assign(o,{futureIndex:a});const l=Object.assign({},n,{relatedContext:r,draggedContext:o});return t(l,e)},onDragEnd(){this.computeIndexes(),th=null},getTrargetedComponent(n){return n.__draggable_component__},getRelatedContextFromMoveEvent({to:n,related:e}){const t=this.getTrargetedComponent(n);if(!t)return{component:t};const r=t.realList,o={list:r,component:t};if(n!==e&&r&&t.getUnderlyingVm){const a=t.getUnderlyingVm(e);if(a)return Object.assign(a,o)}return o},computeFutureIndex(n,e){const t=[...e.to.children].filter(l=>l.style.display!=="none");if(t.length===0)return 0;const r=t.indexOf(e.related),o=n.component.getVmIndex(r);return t.indexOf(th)!==-1||!e.willInsertAfter?o:o+1}}}),Hs=s.defineComponent({__name:"SearchFilter",props:s.mergeModels({placeholder:{}},{search:{},searchModifiers:{}}),emits:["update:search"],setup(n){const e=s.useModel(n,"search"),{t}=rn();return(r,o)=>(s.openBlock(),s.createBlock(PR.VTextField,{class:"bg-containerBg pa-1 rounded-sm elevation-1","persistent-placeholder":"",placeholder:r.placeholder??s.unref(t)("placeholders.search"),variant:"plain","hide-details":"",density:"compact",modelValue:e.value,"onUpdate:modelValue":o[0]||(o[0]=a=>e.value=a)},{"prepend-inner":s.withCtx(()=>[s.createVNode(s.unref(_1),{size:"15",class:"ma-1 me-1"})]),_:1},8,["placeholder","modelValue"]))}}),qD={class:"overflow-y-auto h-600px"},jD={class:"d-flex flex-row align-center"},YD={class:"ma-2 pb-1"},JD=["checked","onClick"],QD=s.defineComponent({__name:"ColumnSettingsFlashDialog",props:{columns:{}},emits:["confirm"],setup(n,{emit:e}){const{t}=rn(),r=s.ref(""),o=n,a=e,l=s.ref([]);s.watch(()=>o.columns,v=>{l.value=v.map(p=>({...p}))},{immediate:!0});const d=s.computed(()=>{const v=r.value.toLowerCase();return l.value.filter(p=>p.title.toLowerCase().includes(v))});function h(v){const p=d.value[v],w=l.value.findIndex(C=>C.key===p.key);w!==-1&&(l.value[w].checked=!l.value[w].checked)}function f(){a("confirm",l.value)}function g(){l.value=o.columns.map(v=>({...v})),a("confirm",l.value)}return(v,p)=>(s.openBlock(),s.createBlock(s.unref(Pa),{"dd-id":"col-settings",title:s.unref(t)("dialogs.columnSettings.title"),onOnSave:f,onOnClose:g},{default:s.withCtx(()=>[s.createElementVNode("div",qD,[s.createVNode(Hs,{modelValue:r.value,"onUpdate:modelValue":p[0]||(p[0]=w=>r.value=w)},null,8,["modelValue"]),s.createVNode(Tt.VList,null,{default:s.withCtx(()=>[s.createVNode(s.unref(fE),{list:l.value,animation:200,"ghost-class":"ghost-card"},{default:s.withCtx(()=>[(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(l.value,(w,C)=>(s.openBlock(),s.createBlock(Tt.VListItem,{key:w.key,class:"pa-0"},{default:s.withCtx(()=>[s.createElementVNode("div",jD,[s.createVNode(s.unref(dC),{class:"cursor-grab mb-2"}),s.createVNode(Tt.VListItemAction,null,{default:s.withCtx(()=>[s.createElementVNode("div",YD,[s.createElementVNode("input",{type:"checkbox",checked:w.checked,onClick:s.withModifiers(T=>h(C),["stop"]),class:"j-checkbox"},null,8,JD)])]),_:2},1024),s.createVNode(Tt.VListItemTitle,{class:"mb-1"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(w.title)+" ",1)]),_:2},1024),w.icon?(s.openBlock(),s.createBlock(_r.VIcon,{key:0},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(w.icon),1)]),_:2},1024)):s.createCommentVNode("",!0)])]),_:2},1024))),128))]),_:1},8,["list"])]),_:1})])]),_:1},8,["title"]))}}),XD=Qo(QD,[["__scopeId","data-v-ee968766"]]),ZD=s.defineComponent({__name:"TableHeaderFlash",props:s.mergeModels({confirmColumnsSettings:{type:Boolean}},{columns:{},columnsModifiers:{}}),emits:s.mergeModels(["refresh","remove"],["update:columns"]),setup(n,{emit:e}){var g,v;const t=n,r=e,o=s.useModel(n,"columns"),{openDialog:a}=Ra("col-settings");function l(p){o.value=Oi.cloneDeep(p)}const d=s.getCurrentInstance(),h=((g=d==null?void 0:d.vnode.props)==null?void 0:g.onRemove)!==void 0||((v=d==null?void 0:d.vnode.props)==null?void 0:v["onUpdate:remove"])!==void 0,{t:f}=rn();return(p,w)=>(s.openBlock(),s.createElementBlock("div",null,[t.confirmColumnsSettings&&o.value?(s.openBlock(),s.createBlock(XD,{key:0,columns:o.value,onConfirm:l},null,8,["columns"])):s.createCommentVNode("",!0),s.createVNode(xe.VRow,{"no-gutters":"",align:"center"},{default:s.withCtx(()=>[s.createVNode(xe.VCol,{cols:"12",md:"7",class:"d-flex align-center flex-wrap gap-2"},{default:s.withCtx(()=>[s.createElementVNode("div",null,[s.createVNode(s.unref(uC),{class:"mt-1 me-2",color:"rgb(var(--v-theme-lightprimary))"})]),s.renderSlot(p.$slots,"filter",{},void 0,!0),p.$slots.filter?s.createCommentVNode("",!0):(s.openBlock(),s.createBlock(Ko.VSelect,{key:0,items:["Move data","Copy","Duplicate","Loop"],variant:"solo","bg-color":"containerBg",rounded:"false",placeholder:s.unref(f)("placeholders.selectFilter"),density:"compact",class:"filter-field","hide-details":"",multiple:"",clearable:""},null,8,["placeholder"])),s.createVNode(Me.VBtn,{icon:"",variant:"text"},{default:s.withCtx(()=>[s.createVNode(s.unref(cC),{color:"rgb(var(--v-theme-secondary))"})]),_:1}),s.createVNode(Me.VBtn,{color:"secondary",class:"ms-2",height:"35",elevation:"5",onClick:w[0]||(w[0]=C=>r("refresh"))},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(s.unref(f)("ui.load")),1)]),_:1})]),_:3}),s.createVNode(xe.VCol,{cols:"12",md:"5",class:"d-flex align-center justify-end flex-wrap gap-2"},{default:s.withCtx(()=>[s.renderSlot(p.$slots,"top-right",{},void 0,!0),s.createVNode(Me.VBtn,{class:"me-2",icon:"",variant:"text",onClick:s.unref(a)},{default:s.withCtx(()=>[s.createVNode(s.unref(fC),{color:"rgb(var(--v-theme-secondary))"})]),_:1},8,["onClick"])]),_:3})]),_:3}),s.createVNode(fo.VDivider,{class:"my-4"}),s.createVNode(xe.VRow,{align:"center"},{default:s.withCtx(()=>[s.createVNode(xe.VCol,{md:"3",cols:"6",class:"d-flex flex-wrap gap-2"},{default:s.withCtx(()=>[s.renderSlot(p.$slots,"left-prepend",{},void 0,!0),s.unref(h)?(s.openBlock(),s.createBlock(s.unref(Yl),{key:0,onRemoveAll:w[1]||(w[1]=C=>r("remove"))})):s.createCommentVNode("",!0),s.renderSlot(p.$slots,"left-append",{},void 0,!0)]),_:3}),s.createVNode(xe.VCol,{md:"9",cols:"12",class:"d-flex justify-end align-center flex-wrap gap-2"},{default:s.withCtx(()=>[s.renderSlot(p.$slots,"right-prepend",{},void 0,!0),s.createVNode(s.unref(hC),{class:"me-2",color:"rgb(var(--v-theme-secondary))"}),s.createVNode(Ko.VSelect,{items:["Move data","Copy","Duplicate","Loop"],variant:"solo","bg-color":"containerBg",rounded:"false",placeholder:s.unref(f)("placeholders.actions"),density:"compact",class:"bottom-field","hide-details":"",clearable:""},null,8,["placeholder"])]),_:3})]),_:3})]))}}),mE=Qo(ZD,[["__scopeId","data-v-6adb6fc9"]]),eL={class:"v-data-table-footer border-t text-body-1"},tL={class:"v-data-table-footer__info"},nL={key:0},rL={key:1},oL={class:"v-data-table-footer__pagination"},iL=["aria-label"],aL={class:"v-pagination__list"},sL={class:"v-pagination__first"},cL={class:"v-pagination__prev"},lL={class:"v-pagination__next"},uL={class:"v-pagination__last"},m_=50,Df=s.defineComponent({__name:"UiTableFooter",props:s.mergeModels({itemsPerPageOptions:{},pageCount:{},itemsLength:{}},{itemsPerPage:{},itemsPerPageModifiers:{},page:{},pageModifiers:{}}),emits:["update:itemsPerPage","update:page"],setup(n){const{t:e}=rn(),t=s.useModel(n,"itemsPerPage"),r=s.useModel(n,"page"),o=n,a=s.computed(()=>o.itemsLength?((r.value??1)-1)*(t.value??m_)+1:0),l=s.computed(()=>Math.min((r.value??1)*(t.value??m_),o.itemsLength)),d=s.computed(()=>(r.value??1)<=1),h=s.computed(()=>(r.value??1)>=o.pageCount),f=async g=>{g===-1?(le.value=!0,await s.nextTick(),setTimeout(()=>{t.value=g},0)):(t.value=g,le.value=!1),r.value=1};return(g,v)=>(s.openBlock(),s.createElementBlock("div",eL,[s.createElementVNode("span",null,s.toDisplayString(s.unref(e)("$vuetify.dataFooter.itemsPerPageText")),1),s.createVNode(Ko.VSelect,{"model-value":t.value,items:o.itemsPerPageOptions,variant:"outlined",density:"compact","hide-details":"",class:"ml-4",style:{"max-width":"100px"},"onUpdate:modelValue":f},null,8,["model-value","items"]),v[8]||(v[8]=s.createElementVNode("div",{class:"v-data-table-footer__items-per-page"},null,-1)),s.createElementVNode("div",tL,[t.value!==-1?(s.openBlock(),s.createElementBlock("div",nL,s.toDisplayString(a.value)+"-"+s.toDisplayString(l.value)+" "+s.toDisplayString(s.unref(e)("$vuetify.dataFooter.ofText"))+" "+s.toDisplayString(o.itemsLength),1)):(s.openBlock(),s.createElementBlock("div",rL,s.toDisplayString(o.itemsLength)+" "+s.toDisplayString(s.unref(e)("$vuetify.dataFooter.ofText"))+" "+s.toDisplayString(o.itemsLength),1))]),s.createElementVNode("div",oL,[s.createElementVNode("nav",{class:"v-pagination",role:"navigation","aria-label":s.unref(e)("pagination.ariaLabel.root")},[s.createElementVNode("ul",aL,[s.createElementVNode("li",sL,[s.createVNode(Me.VBtn,{icon:"",variant:"plain",disabled:d.value,onClick:v[0]||(v[0]=p=>r.value=1),"aria-label":s.unref(e)("pagination.first")},{default:s.withCtx(()=>[s.createVNode(_r.VIcon,null,{default:s.withCtx(()=>v[4]||(v[4]=[s.createTextVNode("mdi-page-first")])),_:1})]),_:1},8,["disabled","aria-label"])]),s.createElementVNode("li",cL,[s.createVNode(Me.VBtn,{icon:"",variant:"plain",disabled:d.value,onClick:v[1]||(v[1]=p=>r.value=(r.value??1)-1),"aria-label":s.unref(e)("$vuetify.pagination.prev")},{default:s.withCtx(()=>[s.createVNode(_r.VIcon,null,{default:s.withCtx(()=>v[5]||(v[5]=[s.createTextVNode("mdi-chevron-left")])),_:1})]),_:1},8,["disabled","aria-label"])]),s.createElementVNode("li",lL,[s.createVNode(Me.VBtn,{icon:"",variant:"plain",disabled:h.value,onClick:v[2]||(v[2]=p=>r.value=(r.value??1)+1),"aria-label":s.unref(e)("$vuetify.pagination.next")},{default:s.withCtx(()=>[s.createVNode(_r.VIcon,null,{default:s.withCtx(()=>v[6]||(v[6]=[s.createTextVNode("mdi-chevron-right")])),_:1})]),_:1},8,["disabled","aria-label"])]),s.createElementVNode("li",uL,[s.createVNode(Me.VBtn,{icon:"",variant:"plain",disabled:h.value,onClick:v[3]||(v[3]=p=>r.value=o.pageCount),"aria-label":s.unref(e)("$vuetify.pagination.last")},{default:s.withCtx(()=>[s.createVNode(_r.VIcon,null,{default:s.withCtx(()=>v[7]||(v[7]=[s.createTextVNode("mdi-page-last")])),_:1})]),_:1},8,["disabled","aria-label"])])])],8,iL)])]))}}),gE=6048e5,dL=864e5,g_=Symbol.for("constructDateFrom");function zo(n,e){return typeof n=="function"?n(e):n&&typeof n=="object"&&g_ in n?n[g_](e):n instanceof Date?new n.constructor(e):new Date(e)}function Sr(n,e){return zo(e||n,n)}let hL={};function Xl(){return hL}function Ds(n,e){var d,h,f,g;const t=Xl(),r=(e==null?void 0:e.weekStartsOn)??((h=(d=e==null?void 0:e.locale)==null?void 0:d.options)==null?void 0:h.weekStartsOn)??t.weekStartsOn??((g=(f=t.locale)==null?void 0:f.options)==null?void 0:g.weekStartsOn)??0,o=Sr(n,e==null?void 0:e.in),a=o.getDay(),l=(a<r?7:0)+a-r;return o.setDate(o.getDate()-l),o.setHours(0,0,0,0),o}function Il(n,e){return Ds(n,{...e,weekStartsOn:1})}function pE(n,e){const t=Sr(n,e==null?void 0:e.in),r=t.getFullYear(),o=zo(t,0);o.setFullYear(r+1,0,4),o.setHours(0,0,0,0);const a=Il(o),l=zo(t,0);l.setFullYear(r,0,4),l.setHours(0,0,0,0);const d=Il(l);return t.getTime()>=a.getTime()?r+1:t.getTime()>=d.getTime()?r:r-1}function p_(n){const e=Sr(n),t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return t.setUTCFullYear(e.getFullYear()),+n-+t}function fL(n,...e){const t=zo.bind(null,e.find(r=>typeof r=="object"));return e.map(t)}function v_(n,e){const t=Sr(n,e==null?void 0:e.in);return t.setHours(0,0,0,0),t}function mL(n,e,t){const[r,o]=fL(t==null?void 0:t.in,n,e),a=v_(r),l=v_(o),d=+a-p_(a),h=+l-p_(l);return Math.round((d-h)/dL)}function gL(n,e){const t=pE(n,e),r=zo(n,0);return r.setFullYear(t,0,4),r.setHours(0,0,0,0),Il(r)}function pL(n){return n instanceof Date||typeof n=="object"&&Object.prototype.toString.call(n)==="[object Date]"}function vL(n){return!(!pL(n)&&typeof n!="number"||isNaN(+Sr(n)))}function _L(n,e){const t=Sr(n,e==null?void 0:e.in);return t.setFullYear(t.getFullYear(),0,1),t.setHours(0,0,0,0),t}const yL={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},CL=(n,e,t)=>{let r;const o=yL[n];return typeof o=="string"?r=o:e===1?r=o.one:r=o.other.replace("{{count}}",e.toString()),t!=null&&t.addSuffix?t.comparison&&t.comparison>0?"in "+r:r+" ago":r};function ar(n){return(e={})=>{const t=e.width?String(e.width):n.defaultWidth;return n.formats[t]||n.formats[n.defaultWidth]}}const EL={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},wL={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},TL={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},bL={date:ar({formats:EL,defaultWidth:"full"}),time:ar({formats:wL,defaultWidth:"full"}),dateTime:ar({formats:TL,defaultWidth:"full"})},SL={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},IL=(n,e,t,r)=>SL[n];function St(n){return(e,t)=>{const r=t!=null&&t.context?String(t.context):"standalone";let o;if(r==="formatting"&&n.formattingValues){const l=n.defaultFormattingWidth||n.defaultWidth,d=t!=null&&t.width?String(t.width):l;o=n.formattingValues[d]||n.formattingValues[l]}else{const l=n.defaultWidth,d=t!=null&&t.width?String(t.width):n.defaultWidth;o=n.values[d]||n.values[l]}const a=n.argumentCallback?n.argumentCallback(e):e;return o[a]}}const AL={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},kL={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},NL={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},OL={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},RL={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},PL={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},ML=(n,e)=>{const t=Number(n),r=t%100;if(r>20||r<10)switch(r%10){case 1:return t+"st";case 2:return t+"nd";case 3:return t+"rd"}return t+"th"},DL={ordinalNumber:ML,era:St({values:AL,defaultWidth:"wide"}),quarter:St({values:kL,defaultWidth:"wide",argumentCallback:n=>n-1}),month:St({values:NL,defaultWidth:"wide"}),day:St({values:OL,defaultWidth:"wide"}),dayPeriod:St({values:RL,defaultWidth:"wide",formattingValues:PL,defaultFormattingWidth:"wide"})};function It(n){return(e,t={})=>{const r=t.width,o=r&&n.matchPatterns[r]||n.matchPatterns[n.defaultMatchWidth],a=e.match(o);if(!a)return null;const l=a[0],d=r&&n.parsePatterns[r]||n.parsePatterns[n.defaultParseWidth],h=Array.isArray(d)?xL(d,v=>v.test(l)):LL(d,v=>v.test(l));let f;f=n.valueCallback?n.valueCallback(h):h,f=t.valueCallback?t.valueCallback(f):f;const g=e.slice(l.length);return{value:f,rest:g}}}function LL(n,e){for(const t in n)if(Object.prototype.hasOwnProperty.call(n,t)&&e(n[t]))return t}function xL(n,e){for(let t=0;t<n.length;t++)if(e(n[t]))return t}function Zl(n){return(e,t={})=>{const r=e.match(n.matchPattern);if(!r)return null;const o=r[0],a=e.match(n.parsePattern);if(!a)return null;let l=n.valueCallback?n.valueCallback(a[0]):a[0];l=t.valueCallback?t.valueCallback(l):l;const d=e.slice(o.length);return{value:l,rest:d}}}const UL=/^(\d+)(th|st|nd|rd)?/i,VL=/\d+/i,BL={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},FL={any:[/^b/i,/^(a|c)/i]},$L={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},HL={any:[/1/i,/2/i,/3/i,/4/i]},KL={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},WL={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},zL={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},GL={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},qL={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},jL={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},YL={ordinalNumber:Zl({matchPattern:UL,parsePattern:VL,valueCallback:n=>parseInt(n,10)}),era:It({matchPatterns:BL,defaultMatchWidth:"wide",parsePatterns:FL,defaultParseWidth:"any"}),quarter:It({matchPatterns:$L,defaultMatchWidth:"wide",parsePatterns:HL,defaultParseWidth:"any",valueCallback:n=>n+1}),month:It({matchPatterns:KL,defaultMatchWidth:"wide",parsePatterns:WL,defaultParseWidth:"any"}),day:It({matchPatterns:zL,defaultMatchWidth:"wide",parsePatterns:GL,defaultParseWidth:"any"}),dayPeriod:It({matchPatterns:qL,defaultMatchWidth:"any",parsePatterns:jL,defaultParseWidth:"any"})},Lf={code:"en-US",formatDistance:CL,formatLong:bL,formatRelative:IL,localize:DL,match:YL,options:{weekStartsOn:0,firstWeekContainsDate:1}};function JL(n,e){const t=Sr(n,e==null?void 0:e.in);return mL(t,_L(t))+1}function QL(n,e){const t=Sr(n,e==null?void 0:e.in),r=+Il(t)-+gL(t);return Math.round(r/gE)+1}function vE(n,e){var g,v,p,w;const t=Sr(n,e==null?void 0:e.in),r=t.getFullYear(),o=Xl(),a=(e==null?void 0:e.firstWeekContainsDate)??((v=(g=e==null?void 0:e.locale)==null?void 0:g.options)==null?void 0:v.firstWeekContainsDate)??o.firstWeekContainsDate??((w=(p=o.locale)==null?void 0:p.options)==null?void 0:w.firstWeekContainsDate)??1,l=zo((e==null?void 0:e.in)||n,0);l.setFullYear(r+1,0,a),l.setHours(0,0,0,0);const d=Ds(l,e),h=zo((e==null?void 0:e.in)||n,0);h.setFullYear(r,0,a),h.setHours(0,0,0,0);const f=Ds(h,e);return+t>=+d?r+1:+t>=+f?r:r-1}function XL(n,e){var d,h,f,g;const t=Xl(),r=(e==null?void 0:e.firstWeekContainsDate)??((h=(d=e==null?void 0:e.locale)==null?void 0:d.options)==null?void 0:h.firstWeekContainsDate)??t.firstWeekContainsDate??((g=(f=t.locale)==null?void 0:f.options)==null?void 0:g.firstWeekContainsDate)??1,o=vE(n,e),a=zo((e==null?void 0:e.in)||n,0);return a.setFullYear(o,0,r),a.setHours(0,0,0,0),Ds(a,e)}function ZL(n,e){const t=Sr(n,e==null?void 0:e.in),r=+Ds(t,e)-+XL(t,e);return Math.round(r/gE)+1}function Ge(n,e){const t=n<0?"-":"",r=Math.abs(n).toString().padStart(e,"0");return t+r}const Do={y(n,e){const t=n.getFullYear(),r=t>0?t:1-t;return Ge(e==="yy"?r%100:r,e.length)},M(n,e){const t=n.getMonth();return e==="M"?String(t+1):Ge(t+1,2)},d(n,e){return Ge(n.getDate(),e.length)},a(n,e){const t=n.getHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return t.toUpperCase();case"aaa":return t;case"aaaaa":return t[0];case"aaaa":default:return t==="am"?"a.m.":"p.m."}},h(n,e){return Ge(n.getHours()%12||12,e.length)},H(n,e){return Ge(n.getHours(),e.length)},m(n,e){return Ge(n.getMinutes(),e.length)},s(n,e){return Ge(n.getSeconds(),e.length)},S(n,e){const t=e.length,r=n.getMilliseconds(),o=Math.trunc(r*Math.pow(10,t-3));return Ge(o,e.length)}},Zi={midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},__={G:function(n,e,t){const r=n.getFullYear()>0?1:0;switch(e){case"G":case"GG":case"GGG":return t.era(r,{width:"abbreviated"});case"GGGGG":return t.era(r,{width:"narrow"});case"GGGG":default:return t.era(r,{width:"wide"})}},y:function(n,e,t){if(e==="yo"){const r=n.getFullYear(),o=r>0?r:1-r;return t.ordinalNumber(o,{unit:"year"})}return Do.y(n,e)},Y:function(n,e,t,r){const o=vE(n,r),a=o>0?o:1-o;if(e==="YY"){const l=a%100;return Ge(l,2)}return e==="Yo"?t.ordinalNumber(a,{unit:"year"}):Ge(a,e.length)},R:function(n,e){const t=pE(n);return Ge(t,e.length)},u:function(n,e){const t=n.getFullYear();return Ge(t,e.length)},Q:function(n,e,t){const r=Math.ceil((n.getMonth()+1)/3);switch(e){case"Q":return String(r);case"QQ":return Ge(r,2);case"Qo":return t.ordinalNumber(r,{unit:"quarter"});case"QQQ":return t.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return t.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return t.quarter(r,{width:"wide",context:"formatting"})}},q:function(n,e,t){const r=Math.ceil((n.getMonth()+1)/3);switch(e){case"q":return String(r);case"qq":return Ge(r,2);case"qo":return t.ordinalNumber(r,{unit:"quarter"});case"qqq":return t.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return t.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return t.quarter(r,{width:"wide",context:"standalone"})}},M:function(n,e,t){const r=n.getMonth();switch(e){case"M":case"MM":return Do.M(n,e);case"Mo":return t.ordinalNumber(r+1,{unit:"month"});case"MMM":return t.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return t.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return t.month(r,{width:"wide",context:"formatting"})}},L:function(n,e,t){const r=n.getMonth();switch(e){case"L":return String(r+1);case"LL":return Ge(r+1,2);case"Lo":return t.ordinalNumber(r+1,{unit:"month"});case"LLL":return t.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return t.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return t.month(r,{width:"wide",context:"standalone"})}},w:function(n,e,t,r){const o=ZL(n,r);return e==="wo"?t.ordinalNumber(o,{unit:"week"}):Ge(o,e.length)},I:function(n,e,t){const r=QL(n);return e==="Io"?t.ordinalNumber(r,{unit:"week"}):Ge(r,e.length)},d:function(n,e,t){return e==="do"?t.ordinalNumber(n.getDate(),{unit:"date"}):Do.d(n,e)},D:function(n,e,t){const r=JL(n);return e==="Do"?t.ordinalNumber(r,{unit:"dayOfYear"}):Ge(r,e.length)},E:function(n,e,t){const r=n.getDay();switch(e){case"E":case"EE":case"EEE":return t.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return t.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return t.day(r,{width:"short",context:"formatting"});case"EEEE":default:return t.day(r,{width:"wide",context:"formatting"})}},e:function(n,e,t,r){const o=n.getDay(),a=(o-r.weekStartsOn+8)%7||7;switch(e){case"e":return String(a);case"ee":return Ge(a,2);case"eo":return t.ordinalNumber(a,{unit:"day"});case"eee":return t.day(o,{width:"abbreviated",context:"formatting"});case"eeeee":return t.day(o,{width:"narrow",context:"formatting"});case"eeeeee":return t.day(o,{width:"short",context:"formatting"});case"eeee":default:return t.day(o,{width:"wide",context:"formatting"})}},c:function(n,e,t,r){const o=n.getDay(),a=(o-r.weekStartsOn+8)%7||7;switch(e){case"c":return String(a);case"cc":return Ge(a,e.length);case"co":return t.ordinalNumber(a,{unit:"day"});case"ccc":return t.day(o,{width:"abbreviated",context:"standalone"});case"ccccc":return t.day(o,{width:"narrow",context:"standalone"});case"cccccc":return t.day(o,{width:"short",context:"standalone"});case"cccc":default:return t.day(o,{width:"wide",context:"standalone"})}},i:function(n,e,t){const r=n.getDay(),o=r===0?7:r;switch(e){case"i":return String(o);case"ii":return Ge(o,e.length);case"io":return t.ordinalNumber(o,{unit:"day"});case"iii":return t.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return t.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return t.day(r,{width:"short",context:"formatting"});case"iiii":default:return t.day(r,{width:"wide",context:"formatting"})}},a:function(n,e,t){const o=n.getHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return t.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"aaa":return t.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return t.dayPeriod(o,{width:"narrow",context:"formatting"});case"aaaa":default:return t.dayPeriod(o,{width:"wide",context:"formatting"})}},b:function(n,e,t){const r=n.getHours();let o;switch(r===12?o=Zi.noon:r===0?o=Zi.midnight:o=r/12>=1?"pm":"am",e){case"b":case"bb":return t.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"bbb":return t.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return t.dayPeriod(o,{width:"narrow",context:"formatting"});case"bbbb":default:return t.dayPeriod(o,{width:"wide",context:"formatting"})}},B:function(n,e,t){const r=n.getHours();let o;switch(r>=17?o=Zi.evening:r>=12?o=Zi.afternoon:r>=4?o=Zi.morning:o=Zi.night,e){case"B":case"BB":case"BBB":return t.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"BBBBB":return t.dayPeriod(o,{width:"narrow",context:"formatting"});case"BBBB":default:return t.dayPeriod(o,{width:"wide",context:"formatting"})}},h:function(n,e,t){if(e==="ho"){let r=n.getHours()%12;return r===0&&(r=12),t.ordinalNumber(r,{unit:"hour"})}return Do.h(n,e)},H:function(n,e,t){return e==="Ho"?t.ordinalNumber(n.getHours(),{unit:"hour"}):Do.H(n,e)},K:function(n,e,t){const r=n.getHours()%12;return e==="Ko"?t.ordinalNumber(r,{unit:"hour"}):Ge(r,e.length)},k:function(n,e,t){let r=n.getHours();return r===0&&(r=24),e==="ko"?t.ordinalNumber(r,{unit:"hour"}):Ge(r,e.length)},m:function(n,e,t){return e==="mo"?t.ordinalNumber(n.getMinutes(),{unit:"minute"}):Do.m(n,e)},s:function(n,e,t){return e==="so"?t.ordinalNumber(n.getSeconds(),{unit:"second"}):Do.s(n,e)},S:function(n,e){return Do.S(n,e)},X:function(n,e,t){const r=n.getTimezoneOffset();if(r===0)return"Z";switch(e){case"X":return C_(r);case"XXXX":case"XX":return mi(r);case"XXXXX":case"XXX":default:return mi(r,":")}},x:function(n,e,t){const r=n.getTimezoneOffset();switch(e){case"x":return C_(r);case"xxxx":case"xx":return mi(r);case"xxxxx":case"xxx":default:return mi(r,":")}},O:function(n,e,t){const r=n.getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+y_(r,":");case"OOOO":default:return"GMT"+mi(r,":")}},z:function(n,e,t){const r=n.getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+y_(r,":");case"zzzz":default:return"GMT"+mi(r,":")}},t:function(n,e,t){const r=Math.trunc(+n/1e3);return Ge(r,e.length)},T:function(n,e,t){return Ge(+n,e.length)}};function y_(n,e=""){const t=n>0?"-":"+",r=Math.abs(n),o=Math.trunc(r/60),a=r%60;return a===0?t+String(o):t+String(o)+e+Ge(a,2)}function C_(n,e){return n%60===0?(n>0?"-":"+")+Ge(Math.abs(n)/60,2):mi(n,e)}function mi(n,e=""){const t=n>0?"-":"+",r=Math.abs(n),o=Ge(Math.trunc(r/60),2),a=Ge(r%60,2);return t+o+e+a}const E_=(n,e)=>{switch(n){case"P":return e.date({width:"short"});case"PP":return e.date({width:"medium"});case"PPP":return e.date({width:"long"});case"PPPP":default:return e.date({width:"full"})}},_E=(n,e)=>{switch(n){case"p":return e.time({width:"short"});case"pp":return e.time({width:"medium"});case"ppp":return e.time({width:"long"});case"pppp":default:return e.time({width:"full"})}},ex=(n,e)=>{const t=n.match(/(P+)(p+)?/)||[],r=t[1],o=t[2];if(!o)return E_(n,e);let a;switch(r){case"P":a=e.dateTime({width:"short"});break;case"PP":a=e.dateTime({width:"medium"});break;case"PPP":a=e.dateTime({width:"long"});break;case"PPPP":default:a=e.dateTime({width:"full"});break}return a.replace("{{date}}",E_(r,e)).replace("{{time}}",_E(o,e))},tx={p:_E,P:ex},nx=/^D+$/,rx=/^Y+$/,ox=["D","DD","YY","YYYY"];function ix(n){return nx.test(n)}function ax(n){return rx.test(n)}function sx(n,e,t){const r=cx(n,e,t);if(console.warn(r),ox.includes(n))throw new RangeError(r)}function cx(n,e,t){const r=n[0]==="Y"?"years":"days of the month";return`Use \`${n.toLowerCase()}\` instead of \`${n}\` (in \`${e}\`) for formatting ${r} to the input \`${t}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}const lx=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,ux=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,dx=/^'([^]*?)'?$/,hx=/''/g,fx=/[a-zA-Z]/;function mx(n,e,t){var g,v,p,w,C,T,S,I;const r=Xl(),o=(t==null?void 0:t.locale)??r.locale??Lf,a=(t==null?void 0:t.firstWeekContainsDate)??((v=(g=t==null?void 0:t.locale)==null?void 0:g.options)==null?void 0:v.firstWeekContainsDate)??r.firstWeekContainsDate??((w=(p=r.locale)==null?void 0:p.options)==null?void 0:w.firstWeekContainsDate)??1,l=(t==null?void 0:t.weekStartsOn)??((T=(C=t==null?void 0:t.locale)==null?void 0:C.options)==null?void 0:T.weekStartsOn)??r.weekStartsOn??((I=(S=r.locale)==null?void 0:S.options)==null?void 0:I.weekStartsOn)??0,d=Sr(n,t==null?void 0:t.in);if(!vL(d))throw new RangeError("Invalid time value");let h=e.match(ux).map(N=>{const D=N[0];if(D==="p"||D==="P"){const L=tx[D];return L(N,o.formatLong)}return N}).join("").match(lx).map(N=>{if(N==="''")return{isToken:!1,value:"'"};const D=N[0];if(D==="'")return{isToken:!1,value:gx(N)};if(__[D])return{isToken:!0,value:N};if(D.match(fx))throw new RangeError("Format string contains an unescaped latin alphabet character `"+D+"`");return{isToken:!1,value:N}});o.localize.preprocessor&&(h=o.localize.preprocessor(d,h));const f={firstWeekContainsDate:a,weekStartsOn:l,locale:o};return h.map(N=>{if(!N.isToken)return N.value;const D=N.value;(!(t!=null&&t.useAdditionalWeekYearTokens)&&ax(D)||!(t!=null&&t.useAdditionalDayOfYearTokens)&&ix(D))&&sx(D,e,String(n));const L=__[D[0]];return L(d,D,o.localize,f)}).join("")}function gx(n){const e=n.match(dx);return e?e[1].replace(hx,"'"):n}const w_={lessThanXSeconds:{standalone:{one:"weniger als 1 Sekunde",other:"weniger als {{count}} Sekunden"},withPreposition:{one:"weniger als 1 Sekunde",other:"weniger als {{count}} Sekunden"}},xSeconds:{standalone:{one:"1 Sekunde",other:"{{count}} Sekunden"},withPreposition:{one:"1 Sekunde",other:"{{count}} Sekunden"}},halfAMinute:{standalone:"eine halbe Minute",withPreposition:"einer halben Minute"},lessThanXMinutes:{standalone:{one:"weniger als 1 Minute",other:"weniger als {{count}} Minuten"},withPreposition:{one:"weniger als 1 Minute",other:"weniger als {{count}} Minuten"}},xMinutes:{standalone:{one:"1 Minute",other:"{{count}} Minuten"},withPreposition:{one:"1 Minute",other:"{{count}} Minuten"}},aboutXHours:{standalone:{one:"etwa 1 Stunde",other:"etwa {{count}} Stunden"},withPreposition:{one:"etwa 1 Stunde",other:"etwa {{count}} Stunden"}},xHours:{standalone:{one:"1 Stunde",other:"{{count}} Stunden"},withPreposition:{one:"1 Stunde",other:"{{count}} Stunden"}},xDays:{standalone:{one:"1 Tag",other:"{{count}} Tage"},withPreposition:{one:"1 Tag",other:"{{count}} Tagen"}},aboutXWeeks:{standalone:{one:"etwa 1 Woche",other:"etwa {{count}} Wochen"},withPreposition:{one:"etwa 1 Woche",other:"etwa {{count}} Wochen"}},xWeeks:{standalone:{one:"1 Woche",other:"{{count}} Wochen"},withPreposition:{one:"1 Woche",other:"{{count}} Wochen"}},aboutXMonths:{standalone:{one:"etwa 1 Monat",other:"etwa {{count}} Monate"},withPreposition:{one:"etwa 1 Monat",other:"etwa {{count}} Monaten"}},xMonths:{standalone:{one:"1 Monat",other:"{{count}} Monate"},withPreposition:{one:"1 Monat",other:"{{count}} Monaten"}},aboutXYears:{standalone:{one:"etwa 1 Jahr",other:"etwa {{count}} Jahre"},withPreposition:{one:"etwa 1 Jahr",other:"etwa {{count}} Jahren"}},xYears:{standalone:{one:"1 Jahr",other:"{{count}} Jahre"},withPreposition:{one:"1 Jahr",other:"{{count}} Jahren"}},overXYears:{standalone:{one:"mehr als 1 Jahr",other:"mehr als {{count}} Jahre"},withPreposition:{one:"mehr als 1 Jahr",other:"mehr als {{count}} Jahren"}},almostXYears:{standalone:{one:"fast 1 Jahr",other:"fast {{count}} Jahre"},withPreposition:{one:"fast 1 Jahr",other:"fast {{count}} Jahren"}}},px=(n,e,t)=>{let r;const o=t!=null&&t.addSuffix?w_[n].withPreposition:w_[n].standalone;return typeof o=="string"?r=o:e===1?r=o.one:r=o.other.replace("{{count}}",String(e)),t!=null&&t.addSuffix?t.comparison&&t.comparison>0?"in "+r:"vor "+r:r},vx={full:"EEEE, do MMMM y",long:"do MMMM y",medium:"do MMM y",short:"dd.MM.y"},_x={full:"HH:mm:ss zzzz",long:"HH:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},yx={full:"{{date}} 'um' {{time}}",long:"{{date}} 'um' {{time}}",medium:"{{date}} {{time}}",short:"{{date}} {{time}}"},Cx={date:ar({formats:vx,defaultWidth:"full"}),time:ar({formats:_x,defaultWidth:"full"}),dateTime:ar({formats:yx,defaultWidth:"full"})},Ex={lastWeek:"'letzten' eeee 'um' p",yesterday:"'gestern um' p",today:"'heute um' p",tomorrow:"'morgen um' p",nextWeek:"eeee 'um' p",other:"P"},wx=(n,e,t,r)=>Ex[n],Tx={narrow:["v.Chr.","n.Chr."],abbreviated:["v.Chr.","n.Chr."],wide:["vor Christus","nach Christus"]},bx={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1. Quartal","2. Quartal","3. Quartal","4. Quartal"]},$h={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mär","Apr","Mai","Jun","Jul","Aug","Sep","Okt","Nov","Dez"],wide:["Januar","Februar","März","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"]},Sx={narrow:$h.narrow,abbreviated:["Jan.","Feb.","März","Apr.","Mai","Juni","Juli","Aug.","Sep.","Okt.","Nov.","Dez."],wide:$h.wide},Ix={narrow:["S","M","D","M","D","F","S"],short:["So","Mo","Di","Mi","Do","Fr","Sa"],abbreviated:["So.","Mo.","Di.","Mi.","Do.","Fr.","Sa."],wide:["Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"]},Ax={narrow:{am:"vm.",pm:"nm.",midnight:"Mitternacht",noon:"Mittag",morning:"Morgen",afternoon:"Nachm.",evening:"Abend",night:"Nacht"},abbreviated:{am:"vorm.",pm:"nachm.",midnight:"Mitternacht",noon:"Mittag",morning:"Morgen",afternoon:"Nachmittag",evening:"Abend",night:"Nacht"},wide:{am:"vormittags",pm:"nachmittags",midnight:"Mitternacht",noon:"Mittag",morning:"Morgen",afternoon:"Nachmittag",evening:"Abend",night:"Nacht"}},kx={narrow:{am:"vm.",pm:"nm.",midnight:"Mitternacht",noon:"Mittag",morning:"morgens",afternoon:"nachm.",evening:"abends",night:"nachts"},abbreviated:{am:"vorm.",pm:"nachm.",midnight:"Mitternacht",noon:"Mittag",morning:"morgens",afternoon:"nachmittags",evening:"abends",night:"nachts"},wide:{am:"vormittags",pm:"nachmittags",midnight:"Mitternacht",noon:"Mittag",morning:"morgens",afternoon:"nachmittags",evening:"abends",night:"nachts"}},Nx=n=>Number(n)+".",Ox={ordinalNumber:Nx,era:St({values:Tx,defaultWidth:"wide"}),quarter:St({values:bx,defaultWidth:"wide",argumentCallback:n=>n-1}),month:St({values:$h,formattingValues:Sx,defaultWidth:"wide"}),day:St({values:Ix,defaultWidth:"wide"}),dayPeriod:St({values:Ax,defaultWidth:"wide",formattingValues:kx,defaultFormattingWidth:"wide"})},Rx=/^(\d+)(\.)?/i,Px=/\d+/i,Mx={narrow:/^(v\.? ?Chr\.?|n\.? ?Chr\.?)/i,abbreviated:/^(v\.? ?Chr\.?|n\.? ?Chr\.?)/i,wide:/^(vor Christus|vor unserer Zeitrechnung|nach Christus|unserer Zeitrechnung)/i},Dx={any:[/^v/i,/^n/i]},Lx={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](\.)? Quartal/i},xx={any:[/1/i,/2/i,/3/i,/4/i]},Ux={narrow:/^[jfmasond]/i,abbreviated:/^(j[aä]n|feb|mär[z]?|apr|mai|jun[i]?|jul[i]?|aug|sep|okt|nov|dez)\.?/i,wide:/^(januar|februar|märz|april|mai|juni|juli|august|september|oktober|november|dezember)/i},Vx={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^j[aä]/i,/^f/i,/^mär/i,/^ap/i,/^mai/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},Bx={narrow:/^[smdmf]/i,short:/^(so|mo|di|mi|do|fr|sa)/i,abbreviated:/^(son?|mon?|die?|mit?|don?|fre?|sam?)\.?/i,wide:/^(sonntag|montag|dienstag|mittwoch|donnerstag|freitag|samstag)/i},Fx={any:[/^so/i,/^mo/i,/^di/i,/^mi/i,/^do/i,/^f/i,/^sa/i]},$x={narrow:/^(vm\.?|nm\.?|Mitternacht|Mittag|morgens|nachm\.?|abends|nachts)/i,abbreviated:/^(vorm\.?|nachm\.?|Mitternacht|Mittag|morgens|nachm\.?|abends|nachts)/i,wide:/^(vormittags|nachmittags|Mitternacht|Mittag|morgens|nachmittags|abends|nachts)/i},Hx={any:{am:/^v/i,pm:/^n/i,midnight:/^Mitte/i,noon:/^Mitta/i,morning:/morgens/i,afternoon:/nachmittags/i,evening:/abends/i,night:/nachts/i}},Kx={ordinalNumber:Zl({matchPattern:Rx,parsePattern:Px,valueCallback:n=>parseInt(n)}),era:It({matchPatterns:Mx,defaultMatchWidth:"wide",parsePatterns:Dx,defaultParseWidth:"any"}),quarter:It({matchPatterns:Lx,defaultMatchWidth:"wide",parsePatterns:xx,defaultParseWidth:"any",valueCallback:n=>n+1}),month:It({matchPatterns:Ux,defaultMatchWidth:"wide",parsePatterns:Vx,defaultParseWidth:"any"}),day:It({matchPatterns:Bx,defaultMatchWidth:"wide",parsePatterns:Fx,defaultParseWidth:"any"}),dayPeriod:It({matchPatterns:$x,defaultMatchWidth:"wide",parsePatterns:Hx,defaultParseWidth:"any"})},Wx={code:"de",formatDistance:px,formatLong:Cx,formatRelative:wx,localize:Ox,match:Kx,options:{weekStartsOn:1,firstWeekContainsDate:4}},zx={lessThanXSeconds:{one:"moins d’une seconde",other:"moins de {{count}} secondes"},xSeconds:{one:"1 seconde",other:"{{count}} secondes"},halfAMinute:"30 secondes",lessThanXMinutes:{one:"moins d’une minute",other:"moins de {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"environ 1 heure",other:"environ {{count}} heures"},xHours:{one:"1 heure",other:"{{count}} heures"},xDays:{one:"1 jour",other:"{{count}} jours"},aboutXWeeks:{one:"environ 1 semaine",other:"environ {{count}} semaines"},xWeeks:{one:"1 semaine",other:"{{count}} semaines"},aboutXMonths:{one:"environ 1 mois",other:"environ {{count}} mois"},xMonths:{one:"1 mois",other:"{{count}} mois"},aboutXYears:{one:"environ 1 an",other:"environ {{count}} ans"},xYears:{one:"1 an",other:"{{count}} ans"},overXYears:{one:"plus d’un an",other:"plus de {{count}} ans"},almostXYears:{one:"presqu’un an",other:"presque {{count}} ans"}},Gx=(n,e,t)=>{let r;const o=zx[n];return typeof o=="string"?r=o:e===1?r=o.one:r=o.other.replace("{{count}}",String(e)),t!=null&&t.addSuffix?t.comparison&&t.comparison>0?"dans "+r:"il y a "+r:r},qx={full:"EEEE d MMMM y",long:"d MMMM y",medium:"d MMM y",short:"dd/MM/y"},jx={full:"HH:mm:ss zzzz",long:"HH:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},Yx={full:"{{date}} 'à' {{time}}",long:"{{date}} 'à' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},Jx={date:ar({formats:qx,defaultWidth:"full"}),time:ar({formats:jx,defaultWidth:"full"}),dateTime:ar({formats:Yx,defaultWidth:"full"})},Qx={lastWeek:"eeee 'dernier à' p",yesterday:"'hier à' p",today:"'aujourd’hui à' p",tomorrow:"'demain à' p'",nextWeek:"eeee 'prochain à' p",other:"P"},Xx=(n,e,t,r)=>Qx[n],Zx={narrow:["av. J.-C","ap. J.-C"],abbreviated:["av. J.-C","ap. J.-C"],wide:["avant Jésus-Christ","après Jésus-Christ"]},eU={narrow:["T1","T2","T3","T4"],abbreviated:["1er trim.","2ème trim.","3ème trim.","4ème trim."],wide:["1er trimestre","2ème trimestre","3ème trimestre","4ème trimestre"]},tU={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["janv.","févr.","mars","avr.","mai","juin","juil.","août","sept.","oct.","nov.","déc."],wide:["janvier","février","mars","avril","mai","juin","juillet","août","septembre","octobre","novembre","décembre"]},nU={narrow:["D","L","M","M","J","V","S"],short:["di","lu","ma","me","je","ve","sa"],abbreviated:["dim.","lun.","mar.","mer.","jeu.","ven.","sam."],wide:["dimanche","lundi","mardi","mercredi","jeudi","vendredi","samedi"]},rU={narrow:{am:"AM",pm:"PM",midnight:"minuit",noon:"midi",morning:"mat.",afternoon:"ap.m.",evening:"soir",night:"mat."},abbreviated:{am:"AM",pm:"PM",midnight:"minuit",noon:"midi",morning:"matin",afternoon:"après-midi",evening:"soir",night:"matin"},wide:{am:"AM",pm:"PM",midnight:"minuit",noon:"midi",morning:"du matin",afternoon:"de l’après-midi",evening:"du soir",night:"du matin"}},oU=(n,e)=>{const t=Number(n),r=e==null?void 0:e.unit;if(t===0)return"0";const o=["year","week","hour","minute","second"];let a;return t===1?a=r&&o.includes(r)?"ère":"er":a="ème",t+a},iU=["MMM","MMMM"],aU={preprocessor:(n,e)=>n.getDate()===1||!e.some(r=>r.isToken&&iU.includes(r.value))?e:e.map(r=>r.isToken&&r.value==="do"?{isToken:!0,value:"d"}:r),ordinalNumber:oU,era:St({values:Zx,defaultWidth:"wide"}),quarter:St({values:eU,defaultWidth:"wide",argumentCallback:n=>n-1}),month:St({values:tU,defaultWidth:"wide"}),day:St({values:nU,defaultWidth:"wide"}),dayPeriod:St({values:rU,defaultWidth:"wide"})},sU=/^(\d+)(ième|ère|ème|er|e)?/i,cU=/\d+/i,lU={narrow:/^(av\.J\.C|ap\.J\.C|ap\.J\.-C)/i,abbreviated:/^(av\.J\.-C|av\.J-C|apr\.J\.-C|apr\.J-C|ap\.J-C)/i,wide:/^(avant Jésus-Christ|après Jésus-Christ)/i},uU={any:[/^av/i,/^ap/i]},dU={narrow:/^T?[1234]/i,abbreviated:/^[1234](er|ème|e)? trim\.?/i,wide:/^[1234](er|ème|e)? trimestre/i},hU={any:[/1/i,/2/i,/3/i,/4/i]},fU={narrow:/^[jfmasond]/i,abbreviated:/^(janv|févr|mars|avr|mai|juin|juill|juil|août|sept|oct|nov|déc)\.?/i,wide:/^(janvier|février|mars|avril|mai|juin|juillet|août|septembre|octobre|novembre|décembre)/i},mU={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^av/i,/^ma/i,/^juin/i,/^juil/i,/^ao/i,/^s/i,/^o/i,/^n/i,/^d/i]},gU={narrow:/^[lmjvsd]/i,short:/^(di|lu|ma|me|je|ve|sa)/i,abbreviated:/^(dim|lun|mar|mer|jeu|ven|sam)\.?/i,wide:/^(dimanche|lundi|mardi|mercredi|jeudi|vendredi|samedi)/i},pU={narrow:[/^d/i,/^l/i,/^m/i,/^m/i,/^j/i,/^v/i,/^s/i],any:[/^di/i,/^lu/i,/^ma/i,/^me/i,/^je/i,/^ve/i,/^sa/i]},vU={narrow:/^(a|p|minuit|midi|mat\.?|ap\.?m\.?|soir|nuit)/i,any:/^([ap]\.?\s?m\.?|du matin|de l'après[-\s]midi|du soir|de la nuit)/i},_U={any:{am:/^a/i,pm:/^p/i,midnight:/^min/i,noon:/^mid/i,morning:/mat/i,afternoon:/ap/i,evening:/soir/i,night:/nuit/i}},yU={ordinalNumber:Zl({matchPattern:sU,parsePattern:cU,valueCallback:n=>parseInt(n)}),era:It({matchPatterns:lU,defaultMatchWidth:"wide",parsePatterns:uU,defaultParseWidth:"any"}),quarter:It({matchPatterns:dU,defaultMatchWidth:"wide",parsePatterns:hU,defaultParseWidth:"any",valueCallback:n=>n+1}),month:It({matchPatterns:fU,defaultMatchWidth:"wide",parsePatterns:mU,defaultParseWidth:"any"}),day:It({matchPatterns:gU,defaultMatchWidth:"wide",parsePatterns:pU,defaultParseWidth:"any"}),dayPeriod:It({matchPatterns:vU,defaultMatchWidth:"any",parsePatterns:_U,defaultParseWidth:"any"})},CU={code:"fr",formatDistance:Gx,formatLong:Jx,formatRelative:Xx,localize:aU,match:yU,options:{weekStartsOn:1,firstWeekContainsDate:4}},EU={lessThanXSeconds:{one:"menos de um segundo",other:"menos de {{count}} segundos"},xSeconds:{one:"1 segundo",other:"{{count}} segundos"},halfAMinute:"meio minuto",lessThanXMinutes:{one:"menos de um minuto",other:"menos de {{count}} minutos"},xMinutes:{one:"1 minuto",other:"{{count}} minutos"},aboutXHours:{one:"cerca de 1 hora",other:"cerca de {{count}} horas"},xHours:{one:"1 hora",other:"{{count}} horas"},xDays:{one:"1 dia",other:"{{count}} dias"},aboutXWeeks:{one:"cerca de 1 semana",other:"cerca de {{count}} semanas"},xWeeks:{one:"1 semana",other:"{{count}} semanas"},aboutXMonths:{one:"cerca de 1 mês",other:"cerca de {{count}} meses"},xMonths:{one:"1 mês",other:"{{count}} meses"},aboutXYears:{one:"cerca de 1 ano",other:"cerca de {{count}} anos"},xYears:{one:"1 ano",other:"{{count}} anos"},overXYears:{one:"mais de 1 ano",other:"mais de {{count}} anos"},almostXYears:{one:"quase 1 ano",other:"quase {{count}} anos"}},wU=(n,e,t)=>{let r;const o=EU[n];return typeof o=="string"?r=o:e===1?r=o.one:r=o.other.replace("{{count}}",String(e)),t!=null&&t.addSuffix?t.comparison&&t.comparison>0?"em "+r:"há "+r:r},TU={full:"EEEE, d 'de' MMMM 'de' y",long:"d 'de' MMMM 'de' y",medium:"d MMM y",short:"dd/MM/yyyy"},bU={full:"HH:mm:ss zzzz",long:"HH:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},SU={full:"{{date}} 'às' {{time}}",long:"{{date}} 'às' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},IU={date:ar({formats:TU,defaultWidth:"full"}),time:ar({formats:bU,defaultWidth:"full"}),dateTime:ar({formats:SU,defaultWidth:"full"})},AU={lastWeek:n=>{const e=n.getDay();return"'"+(e===0||e===6?"último":"última")+"' eeee 'às' p"},yesterday:"'ontem às' p",today:"'hoje às' p",tomorrow:"'amanhã às' p",nextWeek:"eeee 'às' p",other:"P"},kU=(n,e,t,r)=>{const o=AU[n];return typeof o=="function"?o(e):o},NU={narrow:["AC","DC"],abbreviated:["AC","DC"],wide:["antes de cristo","depois de cristo"]},OU={narrow:["1","2","3","4"],abbreviated:["T1","T2","T3","T4"],wide:["1º trimestre","2º trimestre","3º trimestre","4º trimestre"]},RU={narrow:["j","f","m","a","m","j","j","a","s","o","n","d"],abbreviated:["jan","fev","mar","abr","mai","jun","jul","ago","set","out","nov","dez"],wide:["janeiro","fevereiro","março","abril","maio","junho","julho","agosto","setembro","outubro","novembro","dezembro"]},PU={narrow:["D","S","T","Q","Q","S","S"],short:["dom","seg","ter","qua","qui","sex","sab"],abbreviated:["domingo","segunda","terça","quarta","quinta","sexta","sábado"],wide:["domingo","segunda-feira","terça-feira","quarta-feira","quinta-feira","sexta-feira","sábado"]},MU={narrow:{am:"a",pm:"p",midnight:"mn",noon:"md",morning:"manhã",afternoon:"tarde",evening:"tarde",night:"noite"},abbreviated:{am:"AM",pm:"PM",midnight:"meia-noite",noon:"meio-dia",morning:"manhã",afternoon:"tarde",evening:"tarde",night:"noite"},wide:{am:"a.m.",pm:"p.m.",midnight:"meia-noite",noon:"meio-dia",morning:"manhã",afternoon:"tarde",evening:"tarde",night:"noite"}},DU={narrow:{am:"a",pm:"p",midnight:"mn",noon:"md",morning:"da manhã",afternoon:"da tarde",evening:"da tarde",night:"da noite"},abbreviated:{am:"AM",pm:"PM",midnight:"meia-noite",noon:"meio-dia",morning:"da manhã",afternoon:"da tarde",evening:"da tarde",night:"da noite"},wide:{am:"a.m.",pm:"p.m.",midnight:"meia-noite",noon:"meio-dia",morning:"da manhã",afternoon:"da tarde",evening:"da tarde",night:"da noite"}},LU=(n,e)=>{const t=Number(n);return(e==null?void 0:e.unit)==="week"?t+"ª":t+"º"},xU={ordinalNumber:LU,era:St({values:NU,defaultWidth:"wide"}),quarter:St({values:OU,defaultWidth:"wide",argumentCallback:n=>n-1}),month:St({values:RU,defaultWidth:"wide"}),day:St({values:PU,defaultWidth:"wide"}),dayPeriod:St({values:MU,defaultWidth:"wide",formattingValues:DU,defaultFormattingWidth:"wide"})},UU=/^(\d+)[ºªo]?/i,VU=/\d+/i,BU={narrow:/^(ac|dc|a|d)/i,abbreviated:/^(a\.?\s?c\.?|d\.?\s?c\.?)/i,wide:/^(antes de cristo|depois de cristo)/i},FU={any:[/^ac/i,/^dc/i],wide:[/^antes de cristo/i,/^depois de cristo/i]},$U={narrow:/^[1234]/i,abbreviated:/^T[1234]/i,wide:/^[1234](º)? trimestre/i},HU={any:[/1/i,/2/i,/3/i,/4/i]},KU={narrow:/^[jfmajsond]/i,abbreviated:/^(jan|fev|mar|abr|mai|jun|jul|ago|set|out|nov|dez)/i,wide:/^(janeiro|fevereiro|março|abril|maio|junho|julho|agosto|setembro|outubro|novembro|dezembro)/i},WU={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^fev/i,/^mar/i,/^abr/i,/^mai/i,/^jun/i,/^jul/i,/^ago/i,/^set/i,/^out/i,/^nov/i,/^dez/i]},zU={narrow:/^(dom|[23456]ª?|s[aá]b)/i,short:/^(dom|[23456]ª?|s[aá]b)/i,abbreviated:/^(dom|seg|ter|qua|qui|sex|s[aá]b)/i,wide:/^(domingo|(segunda|ter[cç]a|quarta|quinta|sexta)([- ]feira)?|s[aá]bado)/i},GU={short:[/^d/i,/^2/i,/^3/i,/^4/i,/^5/i,/^6/i,/^s[aá]/i],narrow:[/^d/i,/^2/i,/^3/i,/^4/i,/^5/i,/^6/i,/^s[aá]/i],any:[/^d/i,/^seg/i,/^t/i,/^qua/i,/^qui/i,/^sex/i,/^s[aá]b/i]},qU={narrow:/^(a|p|mn|md|(da) (manhã|tarde|noite))/i,any:/^([ap]\.?\s?m\.?|meia[-\s]noite|meio[-\s]dia|(da) (manhã|tarde|noite))/i},jU={any:{am:/^a/i,pm:/^p/i,midnight:/^mn|^meia[-\s]noite/i,noon:/^md|^meio[-\s]dia/i,morning:/manhã/i,afternoon:/tarde/i,evening:/tarde/i,night:/noite/i}},YU={ordinalNumber:Zl({matchPattern:UU,parsePattern:VU,valueCallback:n=>parseInt(n,10)}),era:It({matchPatterns:BU,defaultMatchWidth:"wide",parsePatterns:FU,defaultParseWidth:"any"}),quarter:It({matchPatterns:$U,defaultMatchWidth:"wide",parsePatterns:HU,defaultParseWidth:"any",valueCallback:n=>n+1}),month:It({matchPatterns:KU,defaultMatchWidth:"wide",parsePatterns:WU,defaultParseWidth:"any"}),day:It({matchPatterns:zU,defaultMatchWidth:"wide",parsePatterns:GU,defaultParseWidth:"any"}),dayPeriod:It({matchPatterns:qU,defaultMatchWidth:"any",parsePatterns:jU,defaultParseWidth:"any"})},JU={code:"pt-BR",formatDistance:wU,formatLong:IU,formatRelative:kU,localize:xU,match:YU,options:{weekStartsOn:0,firstWeekContainsDate:1}},QU={"en-US":Lf,"pt-BR":JU,"fr-FR":CU,"de-DE":Wx};function Es(n){if(!n)return"";const{locale:e}=rn(),t=e.value,r=QU[t]||Lf;try{const o=typeof n=="string"||n===null?new Date(n||""):n;return isNaN(o.getTime())?"":mx(o,"PPpp",{locale:r})}catch(o){return console.error("Error formatting date:",o),""}}const XU={key:0,class:"d-flex mt-4 flex-column align-center justify-center w-100"},ZU={class:"d-inline-flex"},eV={class:"d-inline-flex"},tV={class:"d-inline-flex"},T_="/assets/empty_placeholder.svg",yE=s.defineComponent({__name:"TableAdvanced",props:s.mergeModels({headers:{},items:{default:()=>[]},actions:{},loading:{type:Boolean},columns:{default:()=>[]},sortBy:{},dateFields:{},customFields:{},search:{},filterKeys:{},selectOnRowClick:{type:Boolean}},{selection:{},selectionModifiers:{}}),emits:s.mergeModels(["rowClick"],["update:selection"]),setup(n,{emit:e}){const t=[{value:50,title:"50"},{value:100,title:"100"},{value:500,title:"500"},{value:1e3,title:"1000"},{value:-1,title:"$vuetify.dataFooter.itemsPerPageAll"}],r=n,o=e,a=s.computed(()=>r.headers?r.headers:r.columns?r.columns.filter(C=>C.checked):[]),l=s.useModel(n,"selection"),d=s.ref(!1),h=s.ref({x:0,y:0}),f=s.ref(null),g=s.ref(null),v=s.ref(null),p=(C,{item:T})=>{C.preventDefault(),f.value=T,h.value={x:C.clientX,y:C.clientY},d.value?(d.value=!1,s.nextTick(()=>{d.value=!0})):d.value=!0};function w(C,{item:T}){o("rowClick",T),(!r.selectOnRowClick||!l.value)&&(l.value=[]);const S=l.value.findIndex(I=>I===T);return S!==-1?l.value.splice(S,1):l.value.push(T),T}return(C,T)=>!C.loading&&C.items.length===0?(s.openBlock(),s.createElementBlock("div",XU,[s.createVNode(Bl.VImg,{"lazy-src":T_,src:T_,height:"600",width:"600"}),T[2]||(T[2]=s.createElementVNode("p",{class:"text-center text-body-1 w-100"},"No records found.",-1))])):(s.openBlock(),s.createElementBlock("div",{key:1,ref_key:"rootRef",ref:g,class:"mt-4 h-100 rounded-sm",style:{position:"relative"}},[s.withDirectives(s.createElementVNode("div",{ref_key:"activatorRef",ref:v,style:s.normalizeStyle({position:"fixed",left:h.value.x+"px",top:h.value.y+"px",width:"1px",height:"1px",zIndex:9999,pointerEvents:"none"})},null,4),[[s.vShow,d.value]]),s.createVNode(Fl.VMenu,{modelValue:d.value,"onUpdate:modelValue":T[0]||(T[0]=S=>d.value=S),attach:g.value||void 0,activator:v.value||void 0,"location-strategy":"connected","scroll-strategy":"block","min-width":"350"},{default:s.withCtx(()=>[s.renderSlot(C.$slots,"contextmenu",{item:f.value})]),_:3},8,["modelValue","attach","activator"]),s.createVNode(ff.VDataTable,{modelValue:l.value,"onUpdate:modelValue":T[1]||(T[1]=S=>l.value=S),"fixed-header":"","fixed-footer":"","items-per-page":"50",headers:a.value,items:C.items,"items-length":C.items.length,loading:C.loading||!1,"return-object":"","show-select":"","sort-by":C.sortBy,search:C.search,"filter-keys":C.filterKeys,height:"calc(100vh - 320px)",class:"customize-table bg-containerBg","onContextmenu:row":p,"onClick:row":w,"items-per-page-options":t},s.createSlots({"item.avatar":s.withCtx(({item:S})=>[s.renderSlot(C.$slots,"avatar",{item:S})]),"item.active":s.withCtx(({item:S})=>[s.renderSlot(C.$slots,"active",{item:S})]),"item.image":s.withCtx(({item:S})=>[s.renderSlot(C.$slots,"image",{item:S})]),"item.picture":s.withCtx(({item:S})=>[s.renderSlot(C.$slots,"picture",{item:S})]),"item.icon":s.withCtx(({item:S})=>[s.renderSlot(C.$slots,"icon",{item:S})]),"item.actions":s.withCtx(({item:S})=>[s.createElementVNode("div",eV,[s.renderSlot(C.$slots,"actions",{item:S})])]),"no-data":s.withCtx(()=>[T[3]||(T[3]=s.createElementVNode("p",null,"No results found.",-1))]),_:2},[s.renderList(C.customFields,S=>({name:`item.${S}`,fn:s.withCtx(({item:I})=>[s.createElementVNode("div",ZU,[s.renderSlot(C.$slots,S,{item:I})])])})),s.renderList(C.dateFields,S=>({name:`item.${S}`,fn:s.withCtx(({item:I})=>[s.createElementVNode("div",tV,s.toDisplayString(s.unref(Es)(I[S])),1)])}))]),1032,["modelValue","headers","items","items-length","loading","sort-by","search","filter-keys"])],512))}}),nV=s.defineComponent({__name:"TableHeader",props:s.mergeModels({columns:{},filter_visualize:{type:Boolean,default:!0}},{search:{},searchModifiers:{}}),emits:s.mergeModels(["refresh","remove"],["update:search"]),setup(n,{emit:e}){var g,v;const t=n,r=s.computed(()=>t.columns),o=e,a=s.useModel(n,"search"),{openDialog:l}=Ra("col-settings"),d=s.getCurrentInstance(),h=((g=d==null?void 0:d.vnode.props)==null?void 0:g.onRemove)!==void 0||((v=d==null?void 0:d.vnode.props)==null?void 0:v["onUpdate:remove"])!==void 0,{t:f}=rn();return(p,w)=>(s.openBlock(),s.createElementBlock("div",null,[s.createVNode(s.unref(xf),{modelValue:r.value,"onUpdate:modelValue":w[0]||(w[0]=C=>r.value=C)},null,8,["modelValue"]),s.createVNode(xe.VRow,{"no-gutters":"",align:"center"},{default:s.withCtx(()=>[s.createVNode(xe.VCol,{cols:"12",md:"6",class:"d-flex align-center flex-wrap gap-2"},{default:s.withCtx(()=>[s.createElementVNode("div",null,[s.createVNode(s.unref(uC),{class:"mt-1 me-2",color:"rgb(var(--v-theme-lightprimary))"})]),s.renderSlot(p.$slots,"filter",{},void 0,!0),p.$slots.filter?s.createCommentVNode("",!0):(s.openBlock(),s.createBlock(Ko.VSelect,{key:0,items:["Move data","Copy","Duplicate","Loop"],variant:"solo","bg-color":"containerBg",rounded:"false",placeholder:s.unref(f)("placeholders.selectFilter"),density:"compact",class:"filter-field","hide-details":"",multiple:"",clearable:""},null,8,["placeholder"])),s.createVNode(Me.VBtn,{icon:"",variant:"text",onClick:w[1]||(w[1]=C=>o("refresh"))},{default:s.withCtx(()=>[s.createVNode(s.unref(v1),{color:"rgb(var(--v-theme-secondary))"})]),_:1}),s.createVNode(Me.VBtn,{icon:"",variant:"text"},{default:s.withCtx(()=>[s.createVNode(s.unref(cC),{color:"rgb(var(--v-theme-secondary))"})]),_:1})]),_:3}),s.createVNode(xe.VCol,{cols:"12",md:"6",class:"d-flex align-center justify-end flex-wrap gap-2"},{default:s.withCtx(()=>[s.renderSlot(p.$slots,"top-right",{},void 0,!0),s.createVNode(Me.VBtn,{class:"me-2",icon:"",variant:"text",onClick:s.unref(l)},{default:s.withCtx(()=>[s.createVNode(s.unref(fC),{color:"rgb(var(--v-theme-secondary))"})]),_:1},8,["onClick"]),s.createVNode(Hs,{class:"search-field",modelValue:a.value,"onUpdate:modelValue":w[2]||(w[2]=C=>a.value=C)},null,8,["modelValue"])]),_:3})]),_:3}),s.createVNode(fo.VDivider,{class:"my-4"}),s.createVNode(xe.VRow,{align:"center"},{default:s.withCtx(()=>[s.createVNode(xe.VCol,{md:"3",cols:"6",class:"d-flex flex-wrap gap-2"},{default:s.withCtx(()=>[s.renderSlot(p.$slots,"left-prepend",{},void 0,!0),s.unref(h)?(s.openBlock(),s.createBlock(s.unref(Yl),{key:0,onRemoveAll:w[3]||(w[3]=C=>o("remove"))})):s.createCommentVNode("",!0),s.renderSlot(p.$slots,"left-append",{},void 0,!0)]),_:3}),s.createVNode(xe.VCol,{md:"9",cols:"12",class:"d-flex justify-end align-center flex-wrap gap-2"},{default:s.withCtx(()=>[s.renderSlot(p.$slots,"right-prepend",{},void 0,!0),p.filter_visualize?(s.openBlock(),s.createElementBlock(s.Fragment,{key:0},[s.createVNode(s.unref(y1),{class:"me-2",color:"rgb(var(--v-theme-secondary))"}),s.createVNode(Ko.VSelect,{items:[],variant:"solo","bg-color":"containerBg",rounded:"false",placeholder:s.unref(f)("placeholders.visualize"),density:"compact",class:"bottom-field me-2","hide-details":"",multiple:"",clearable:""},null,8,["placeholder"])],64)):s.createCommentVNode("",!0),s.createVNode(s.unref(hC),{class:"me-2",color:"rgb(var(--v-theme-secondary))"}),s.createVNode(Ko.VSelect,{items:["Move data","Copy","Duplicate","Loop"],variant:"solo","bg-color":"containerBg",rounded:"false",placeholder:s.unref(f)("placeholders.actions"),density:"compact",class:"bottom-field","hide-details":"",clearable:""},null,8,["placeholder"])]),_:3})]),_:3})]))}}),CE=Qo(nV,[["__scopeId","data-v-58865e47"]]),rV={class:"d-flex flex-row align-center"},xf=s.defineComponent({__name:"ColumnSettingsDialog",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(n){const e=s.useModel(n,"modelValue"),t=s.ref(""),r=s.computed(()=>{var a;return(a=e.value)==null?void 0:a.filter(l=>l.title.toLowerCase().includes(t.value.toLowerCase()))}),{t:o}=rn();return(a,l)=>{const d=s.resolveComponent("v-list-item-content");return s.openBlock(),s.createBlock(Pa,{"dd-id":"col-settings",buttons:!1,title:s.unref(o)("dialogs.columnSettings.title")},{default:s.withCtx(()=>[s.createVNode(Hs,{modelValue:t.value,"onUpdate:modelValue":l[0]||(l[0]=h=>t.value=h)},null,8,["modelValue"]),s.createVNode(Tt.VList,null,{default:s.withCtx(()=>[s.createVNode(s.unref(fE),{list:r.value,animation:200,"ghost-class":"ghost-card"},{default:s.withCtx(()=>[(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(r.value,h=>(s.openBlock(),s.createBlock(Tt.VListItem,{key:h.key,class:"pa-0"},{default:s.withCtx(()=>[s.createElementVNode("div",rV,[s.createVNode(s.unref(dC),{class:"cursor-grab mb-2"}),s.createVNode(Tt.VListItemAction,null,{default:s.withCtx(()=>[s.createVNode(MR.VCheckbox,{modelValue:h.checked,"onUpdate:modelValue":f=>h.checked=f},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024),s.createVNode(d,null,{default:s.withCtx(()=>[s.createVNode(Tt.VListItemTitle,{class:"mb-1"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(h.title)+" ",1)]),_:2},1024)]),_:2},1024),h.icon?(s.openBlock(),s.createBlock(_r.VIcon,{key:0},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(h.icon),1)]),_:2},1024)):s.createCommentVNode("",!0)])]),_:2},1024))),128))]),_:1},8,["list"])]),_:1})]),_:1},8,["title"])}}}),oV=["src","height","width"],iV={key:0,class:"text-center text-h6"},aV={key:1,class:"text-center text-h5"},sV={key:0,class:"text-center"},cV={class:"d-flex justify-center align-center mt-4 ga-3"},Uf=s.defineComponent({__name:"TableCard",props:{item:{},columns:{},size:{},image:{},tags:{},route:{},callback:{type:Function}},setup(n){const e=n,t=()=>{var o;return((o=e.columns.find(a=>a.isHeader))==null?void 0:o.key)||""},r=()=>{var o;return((o=e.columns.find(a=>a.isSubtitle))==null?void 0:o.key)||""};return(o,a)=>(s.openBlock(),s.createBlock(Ut.VCard,{onClick:o.callback,ripple:"",class:"d-flex flex-column pa-4pa-4 bg-containerBg"},{default:s.withCtx(()=>[s.createVNode(Ut.VCardActions,null,{default:s.withCtx(()=>[s.createVNode(xe.VRow,{"no-gutters":"",align:"center",justify:"end"},{default:s.withCtx(()=>[s.renderSlot(o.$slots,"actions",{item:o.item})]),_:3})]),_:3}),s.createVNode(Ut.VCardTitle,null,{default:s.withCtx(()=>[s.createVNode(xe.VRow,{"no-gutters":"",align:"center",justify:"center"},{default:s.withCtx(()=>[o.image?(s.openBlock(),s.createElementBlock("img",{key:0,src:o.image,height:o.size,width:o.size,alt:""},null,8,oV)):s.createCommentVNode("",!0)]),_:1})]),_:1}),t()?(s.openBlock(),s.createElementBlock("div",iV,s.toDisplayString(o.item[t()]),1)):s.createCommentVNode("",!0),r()?(s.openBlock(),s.createElementBlock("div",aV,s.toDisplayString(o.item[r()]),1)):s.createCommentVNode("",!0),s.createVNode(fo.VDivider,{class:"ma-3"}),s.createVNode(Ut.VCardText,{class:"d-flex flex-column align-center pa-4 pt-1"},{default:s.withCtx(()=>[(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(o.columns,l=>(s.openBlock(),s.createElementBlock(s.Fragment,{key:l.key},[o.item[l.key]&&!l.isHeader&&!l.isSubtitle?(s.openBlock(),s.createElementBlock("div",sV,s.toDisplayString(l.title)+": "+s.toDisplayString(o.item[l.key]),1)):s.createCommentVNode("",!0)],64))),128)),s.createElementVNode("div",cV,[o.tags?(s.openBlock(!0),s.createElementBlock(s.Fragment,{key:0},s.renderList(o.tags,l=>(s.openBlock(),s.createBlock(DR.VChip,{class:"pa-3",key:l},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(l),1)]),_:2},1024))),128)):s.createCommentVNode("",!0)])]),_:1})]),_:3},8,["onClick"]))}}),lV=s.defineComponent({__name:"TableCardsView",props:{data:{},columns:{},size:{},itemKey:{}},setup(n){return(e,t)=>(s.openBlock(),s.createBlock(xe.VRow,{class:"mt-5 border tb-cards-h",wrap:""},{default:s.withCtx(()=>[(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(e.data,r=>(s.openBlock(),s.createBlock(xe.VCol,{cols:"12",sm:"6",md:"4",lg:"3",class:"pa-2",key:r[e.itemKey]},{default:s.withCtx(()=>[s.createVNode(Uf,{item:r,columns:e.columns,size:e.size},{actions:s.withCtx(({item:o})=>[s.renderSlot(e.$slots,"actions",{item:o},void 0,!0)]),_:2},1032,["item","columns","size"])]),_:2},1024))),128))]),_:3}))}}),EE=Qo(lV,[["__scopeId","data-v-e1a4ccbc"]]),uV={key:0,class:"mb-2 ms-1"},wE=s.defineComponent({__name:"JTextField",props:s.mergeModels({name:{},label:{},type:{default:"text"},readonly:{type:Boolean},density:{},rules:{},hideDetails:{type:Boolean},min:{}},{modelValue:{},modelModifiers:{}}),emits:["update:modelValue"],setup(n){const e=s.useModel(n,"modelValue");return(t,r)=>(s.openBlock(),s.createElementBlock("div",null,[t.name?(s.openBlock(),s.createElementBlock("p",uV,s.toDisplayString(t.name),1)):s.createCommentVNode("",!0),t.label?(s.openBlock(),s.createBlock(Ei.VLabel,{key:1,class:"text-subtitle-1 text-high-emphasis mb-2"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(t.label),1)]),_:1})):s.createCommentVNode("",!0),s.createVNode(s.unref(ho.VTextField),{variant:"solo-filled","bg-color":t.readonly?"containerBg30":"containerBg",color:"secondary",rounded:"sm",type:t.type,density:t.density,rules:t.rules,modelValue:e.value,"onUpdate:modelValue":r[0]||(r[0]=o=>e.value=o),class:s.normalizeClass(["j-field",{readonly:t.readonly}]),readonly:t.readonly,"hide-details":t.hideDetails,min:t.min},null,8,["bg-color","type","density","rules","modelValue","class","readonly","hide-details","min"])]))}});function TE(n,e){return function(){return n.apply(e,arguments)}}const{toString:dV}=Object.prototype,{getPrototypeOf:Vf}=Object,eu=(n=>e=>{const t=dV.call(e);return n[t]||(n[t]=t.slice(8,-1).toLowerCase())})(Object.create(null)),Ir=n=>(n=n.toLowerCase(),e=>eu(e)===n),tu=n=>e=>typeof e===n,{isArray:Da}=Array,Ls=tu("undefined");function hV(n){return n!==null&&!Ls(n)&&n.constructor!==null&&!Ls(n.constructor)&&Fn(n.constructor.isBuffer)&&n.constructor.isBuffer(n)}const bE=Ir("ArrayBuffer");function fV(n){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(n):e=n&&n.buffer&&bE(n.buffer),e}const mV=tu("string"),Fn=tu("function"),SE=tu("number"),nu=n=>n!==null&&typeof n=="object",gV=n=>n===!0||n===!1,pl=n=>{if(eu(n)!=="object")return!1;const e=Vf(n);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Symbol.toStringTag in n)&&!(Symbol.iterator in n)},pV=Ir("Date"),vV=Ir("File"),_V=Ir("Blob"),yV=Ir("FileList"),CV=n=>nu(n)&&Fn(n.pipe),EV=n=>{let e;return n&&(typeof FormData=="function"&&n instanceof FormData||Fn(n.append)&&((e=eu(n))==="formdata"||e==="object"&&Fn(n.toString)&&n.toString()==="[object FormData]"))},wV=Ir("URLSearchParams"),[TV,bV,SV,IV]=["ReadableStream","Request","Response","Headers"].map(Ir),AV=n=>n.trim?n.trim():n.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Ks(n,e,{allOwnKeys:t=!1}={}){if(n===null||typeof n>"u")return;let r,o;if(typeof n!="object"&&(n=[n]),Da(n))for(r=0,o=n.length;r<o;r++)e.call(null,n[r],r,n);else{const a=t?Object.getOwnPropertyNames(n):Object.keys(n),l=a.length;let d;for(r=0;r<l;r++)d=a[r],e.call(null,n[d],d,n)}}function IE(n,e){e=e.toLowerCase();const t=Object.keys(n);let r=t.length,o;for(;r-- >0;)if(o=t[r],e===o.toLowerCase())return o;return null}const _i=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,AE=n=>!Ls(n)&&n!==_i;function Hh(){const{caseless:n}=AE(this)&&this||{},e={},t=(r,o)=>{const a=n&&IE(e,o)||o;pl(e[a])&&pl(r)?e[a]=Hh(e[a],r):pl(r)?e[a]=Hh({},r):Da(r)?e[a]=r.slice():e[a]=r};for(let r=0,o=arguments.length;r<o;r++)arguments[r]&&Ks(arguments[r],t);return e}const kV=(n,e,t,{allOwnKeys:r}={})=>(Ks(e,(o,a)=>{t&&Fn(o)?n[a]=TE(o,t):n[a]=o},{allOwnKeys:r}),n),NV=n=>(n.charCodeAt(0)===65279&&(n=n.slice(1)),n),OV=(n,e,t,r)=>{n.prototype=Object.create(e.prototype,r),n.prototype.constructor=n,Object.defineProperty(n,"super",{value:e.prototype}),t&&Object.assign(n.prototype,t)},RV=(n,e,t,r)=>{let o,a,l;const d={};if(e=e||{},n==null)return e;do{for(o=Object.getOwnPropertyNames(n),a=o.length;a-- >0;)l=o[a],(!r||r(l,n,e))&&!d[l]&&(e[l]=n[l],d[l]=!0);n=t!==!1&&Vf(n)}while(n&&(!t||t(n,e))&&n!==Object.prototype);return e},PV=(n,e,t)=>{n=String(n),(t===void 0||t>n.length)&&(t=n.length),t-=e.length;const r=n.indexOf(e,t);return r!==-1&&r===t},MV=n=>{if(!n)return null;if(Da(n))return n;let e=n.length;if(!SE(e))return null;const t=new Array(e);for(;e-- >0;)t[e]=n[e];return t},DV=(n=>e=>n&&e instanceof n)(typeof Uint8Array<"u"&&Vf(Uint8Array)),LV=(n,e)=>{const r=(n&&n[Symbol.iterator]).call(n);let o;for(;(o=r.next())&&!o.done;){const a=o.value;e.call(n,a[0],a[1])}},xV=(n,e)=>{let t;const r=[];for(;(t=n.exec(e))!==null;)r.push(t);return r},UV=Ir("HTMLFormElement"),VV=n=>n.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(t,r,o){return r.toUpperCase()+o}),b_=(({hasOwnProperty:n})=>(e,t)=>n.call(e,t))(Object.prototype),BV=Ir("RegExp"),kE=(n,e)=>{const t=Object.getOwnPropertyDescriptors(n),r={};Ks(t,(o,a)=>{let l;(l=e(o,a,n))!==!1&&(r[a]=l||o)}),Object.defineProperties(n,r)},FV=n=>{kE(n,(e,t)=>{if(Fn(n)&&["arguments","caller","callee"].indexOf(t)!==-1)return!1;const r=n[t];if(Fn(r)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+t+"'")})}})},$V=(n,e)=>{const t={},r=o=>{o.forEach(a=>{t[a]=!0})};return Da(n)?r(n):r(String(n).split(e)),t},HV=()=>{},KV=(n,e)=>n!=null&&Number.isFinite(n=+n)?n:e;function WV(n){return!!(n&&Fn(n.append)&&n[Symbol.toStringTag]==="FormData"&&n[Symbol.iterator])}const zV=n=>{const e=new Array(10),t=(r,o)=>{if(nu(r)){if(e.indexOf(r)>=0)return;if(!("toJSON"in r)){e[o]=r;const a=Da(r)?[]:{};return Ks(r,(l,d)=>{const h=t(l,o+1);!Ls(h)&&(a[d]=h)}),e[o]=void 0,a}}return r};return t(n,0)},GV=Ir("AsyncFunction"),qV=n=>n&&(nu(n)||Fn(n))&&Fn(n.then)&&Fn(n.catch),NE=((n,e)=>n?setImmediate:e?((t,r)=>(_i.addEventListener("message",({source:o,data:a})=>{o===_i&&a===t&&r.length&&r.shift()()},!1),o=>{r.push(o),_i.postMessage(t,"*")}))(`axios@${Math.random()}`,[]):t=>setTimeout(t))(typeof setImmediate=="function",Fn(_i.postMessage)),jV=typeof queueMicrotask<"u"?queueMicrotask.bind(_i):typeof process<"u"&&process.nextTick||NE,B={isArray:Da,isArrayBuffer:bE,isBuffer:hV,isFormData:EV,isArrayBufferView:fV,isString:mV,isNumber:SE,isBoolean:gV,isObject:nu,isPlainObject:pl,isReadableStream:TV,isRequest:bV,isResponse:SV,isHeaders:IV,isUndefined:Ls,isDate:pV,isFile:vV,isBlob:_V,isRegExp:BV,isFunction:Fn,isStream:CV,isURLSearchParams:wV,isTypedArray:DV,isFileList:yV,forEach:Ks,merge:Hh,extend:kV,trim:AV,stripBOM:NV,inherits:OV,toFlatObject:RV,kindOf:eu,kindOfTest:Ir,endsWith:PV,toArray:MV,forEachEntry:LV,matchAll:xV,isHTMLForm:UV,hasOwnProperty:b_,hasOwnProp:b_,reduceDescriptors:kE,freezeMethods:FV,toObjectSet:$V,toCamelCase:VV,noop:HV,toFiniteNumber:KV,findKey:IE,global:_i,isContextDefined:AE,isSpecCompliantForm:WV,toJSONObject:zV,isAsyncFn:GV,isThenable:qV,setImmediate:NE,asap:jV};function Te(n,e,t,r,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=n,this.name="AxiosError",e&&(this.code=e),t&&(this.config=t),r&&(this.request=r),o&&(this.response=o,this.status=o.status?o.status:null)}B.inherits(Te,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:B.toJSONObject(this.config),code:this.code,status:this.status}}});const OE=Te.prototype,RE={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(n=>{RE[n]={value:n}});Object.defineProperties(Te,RE);Object.defineProperty(OE,"isAxiosError",{value:!0});Te.from=(n,e,t,r,o,a)=>{const l=Object.create(OE);return B.toFlatObject(n,l,function(h){return h!==Error.prototype},d=>d!=="isAxiosError"),Te.call(l,n.message,e,t,r,o),l.cause=n,l.name=n.name,a&&Object.assign(l,a),l};const YV=null;function Kh(n){return B.isPlainObject(n)||B.isArray(n)}function PE(n){return B.endsWith(n,"[]")?n.slice(0,-2):n}function S_(n,e,t){return n?n.concat(e).map(function(o,a){return o=PE(o),!t&&a?"["+o+"]":o}).join(t?".":""):e}function JV(n){return B.isArray(n)&&!n.some(Kh)}const QV=B.toFlatObject(B,{},null,function(e){return/^is[A-Z]/.test(e)});function ru(n,e,t){if(!B.isObject(n))throw new TypeError("target must be an object");e=e||new FormData,t=B.toFlatObject(t,{metaTokens:!0,dots:!1,indexes:!1},!1,function(T,S){return!B.isUndefined(S[T])});const r=t.metaTokens,o=t.visitor||g,a=t.dots,l=t.indexes,h=(t.Blob||typeof Blob<"u"&&Blob)&&B.isSpecCompliantForm(e);if(!B.isFunction(o))throw new TypeError("visitor must be a function");function f(C){if(C===null)return"";if(B.isDate(C))return C.toISOString();if(!h&&B.isBlob(C))throw new Te("Blob is not supported. Use a Buffer instead.");return B.isArrayBuffer(C)||B.isTypedArray(C)?h&&typeof Blob=="function"?new Blob([C]):Buffer.from(C):C}function g(C,T,S){let I=C;if(C&&!S&&typeof C=="object"){if(B.endsWith(T,"{}"))T=r?T:T.slice(0,-2),C=JSON.stringify(C);else if(B.isArray(C)&&JV(C)||(B.isFileList(C)||B.endsWith(T,"[]"))&&(I=B.toArray(C)))return T=PE(T),I.forEach(function(D,L){!(B.isUndefined(D)||D===null)&&e.append(l===!0?S_([T],L,a):l===null?T:T+"[]",f(D))}),!1}return Kh(C)?!0:(e.append(S_(S,T,a),f(C)),!1)}const v=[],p=Object.assign(QV,{defaultVisitor:g,convertValue:f,isVisitable:Kh});function w(C,T){if(!B.isUndefined(C)){if(v.indexOf(C)!==-1)throw Error("Circular reference detected in "+T.join("."));v.push(C),B.forEach(C,function(I,N){(!(B.isUndefined(I)||I===null)&&o.call(e,I,B.isString(N)?N.trim():N,T,p))===!0&&w(I,T?T.concat(N):[N])}),v.pop()}}if(!B.isObject(n))throw new TypeError("data must be an object");return w(n),e}function I_(n){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(n).replace(/[!'()~]|%20|%00/g,function(r){return e[r]})}function Bf(n,e){this._pairs=[],n&&ru(n,this,e)}const ME=Bf.prototype;ME.append=function(e,t){this._pairs.push([e,t])};ME.toString=function(e){const t=e?function(r){return e.call(this,r,I_)}:I_;return this._pairs.map(function(o){return t(o[0])+"="+t(o[1])},"").join("&")};function XV(n){return encodeURIComponent(n).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function DE(n,e,t){if(!e)return n;const r=t&&t.encode||XV;B.isFunction(t)&&(t={serialize:t});const o=t&&t.serialize;let a;if(o?a=o(e,t):a=B.isURLSearchParams(e)?e.toString():new Bf(e,t).toString(r),a){const l=n.indexOf("#");l!==-1&&(n=n.slice(0,l)),n+=(n.indexOf("?")===-1?"?":"&")+a}return n}class A_{constructor(){this.handlers=[]}use(e,t,r){return this.handlers.push({fulfilled:e,rejected:t,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){B.forEach(this.handlers,function(r){r!==null&&e(r)})}}const LE={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},ZV=typeof URLSearchParams<"u"?URLSearchParams:Bf,eB=typeof FormData<"u"?FormData:null,tB=typeof Blob<"u"?Blob:null,nB={isBrowser:!0,classes:{URLSearchParams:ZV,FormData:eB,Blob:tB},protocols:["http","https","file","blob","url","data"]},Ff=typeof window<"u"&&typeof document<"u",Wh=typeof navigator=="object"&&navigator||void 0,rB=Ff&&(!Wh||["ReactNative","NativeScript","NS"].indexOf(Wh.product)<0),oB=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",iB=Ff&&window.location.href||"http://localhost",aB=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Ff,hasStandardBrowserEnv:rB,hasStandardBrowserWebWorkerEnv:oB,navigator:Wh,origin:iB},Symbol.toStringTag,{value:"Module"})),nn={...aB,...nB};function sB(n,e){return ru(n,new nn.classes.URLSearchParams,Object.assign({visitor:function(t,r,o,a){return nn.isNode&&B.isBuffer(t)?(this.append(r,t.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},e))}function cB(n){return B.matchAll(/\w+|\[(\w*)]/g,n).map(e=>e[0]==="[]"?"":e[1]||e[0])}function lB(n){const e={},t=Object.keys(n);let r;const o=t.length;let a;for(r=0;r<o;r++)a=t[r],e[a]=n[a];return e}function xE(n){function e(t,r,o,a){let l=t[a++];if(l==="__proto__")return!0;const d=Number.isFinite(+l),h=a>=t.length;return l=!l&&B.isArray(o)?o.length:l,h?(B.hasOwnProp(o,l)?o[l]=[o[l],r]:o[l]=r,!d):((!o[l]||!B.isObject(o[l]))&&(o[l]=[]),e(t,r,o[l],a)&&B.isArray(o[l])&&(o[l]=lB(o[l])),!d)}if(B.isFormData(n)&&B.isFunction(n.entries)){const t={};return B.forEachEntry(n,(r,o)=>{e(cB(r),o,t,0)}),t}return null}function uB(n,e,t){if(B.isString(n))try{return(e||JSON.parse)(n),B.trim(n)}catch(r){if(r.name!=="SyntaxError")throw r}return(t||JSON.stringify)(n)}const Ws={transitional:LE,adapter:["xhr","http","fetch"],transformRequest:[function(e,t){const r=t.getContentType()||"",o=r.indexOf("application/json")>-1,a=B.isObject(e);if(a&&B.isHTMLForm(e)&&(e=new FormData(e)),B.isFormData(e))return o?JSON.stringify(xE(e)):e;if(B.isArrayBuffer(e)||B.isBuffer(e)||B.isStream(e)||B.isFile(e)||B.isBlob(e)||B.isReadableStream(e))return e;if(B.isArrayBufferView(e))return e.buffer;if(B.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let d;if(a){if(r.indexOf("application/x-www-form-urlencoded")>-1)return sB(e,this.formSerializer).toString();if((d=B.isFileList(e))||r.indexOf("multipart/form-data")>-1){const h=this.env&&this.env.FormData;return ru(d?{"files[]":e}:e,h&&new h,this.formSerializer)}}return a||o?(t.setContentType("application/json",!1),uB(e)):e}],transformResponse:[function(e){const t=this.transitional||Ws.transitional,r=t&&t.forcedJSONParsing,o=this.responseType==="json";if(B.isResponse(e)||B.isReadableStream(e))return e;if(e&&B.isString(e)&&(r&&!this.responseType||o)){const l=!(t&&t.silentJSONParsing)&&o;try{return JSON.parse(e)}catch(d){if(l)throw d.name==="SyntaxError"?Te.from(d,Te.ERR_BAD_RESPONSE,this,null,this.response):d}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:nn.classes.FormData,Blob:nn.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};B.forEach(["delete","get","head","post","put","patch"],n=>{Ws.headers[n]={}});const dB=B.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),hB=n=>{const e={};let t,r,o;return n&&n.split(`
|
|
68
|
+
`).forEach(function(l){o=l.indexOf(":"),t=l.substring(0,o).trim().toLowerCase(),r=l.substring(o+1).trim(),!(!t||e[t]&&dB[t])&&(t==="set-cookie"?e[t]?e[t].push(r):e[t]=[r]:e[t]=e[t]?e[t]+", "+r:r)}),e},k_=Symbol("internals");function ls(n){return n&&String(n).trim().toLowerCase()}function vl(n){return n===!1||n==null?n:B.isArray(n)?n.map(vl):String(n)}function fB(n){const e=Object.create(null),t=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=t.exec(n);)e[r[1]]=r[2];return e}const mB=n=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(n.trim());function nh(n,e,t,r,o){if(B.isFunction(r))return r.call(this,e,t);if(o&&(e=t),!!B.isString(e)){if(B.isString(r))return e.indexOf(r)!==-1;if(B.isRegExp(r))return r.test(e)}}function gB(n){return n.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,t,r)=>t.toUpperCase()+r)}function pB(n,e){const t=B.toCamelCase(" "+e);["get","set","has"].forEach(r=>{Object.defineProperty(n,r+t,{value:function(o,a,l){return this[r].call(this,e,o,a,l)},configurable:!0})})}let Cn=class{constructor(e){e&&this.set(e)}set(e,t,r){const o=this;function a(d,h,f){const g=ls(h);if(!g)throw new Error("header name must be a non-empty string");const v=B.findKey(o,g);(!v||o[v]===void 0||f===!0||f===void 0&&o[v]!==!1)&&(o[v||h]=vl(d))}const l=(d,h)=>B.forEach(d,(f,g)=>a(f,g,h));if(B.isPlainObject(e)||e instanceof this.constructor)l(e,t);else if(B.isString(e)&&(e=e.trim())&&!mB(e))l(hB(e),t);else if(B.isHeaders(e))for(const[d,h]of e.entries())a(h,d,r);else e!=null&&a(t,e,r);return this}get(e,t){if(e=ls(e),e){const r=B.findKey(this,e);if(r){const o=this[r];if(!t)return o;if(t===!0)return fB(o);if(B.isFunction(t))return t.call(this,o,r);if(B.isRegExp(t))return t.exec(o);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=ls(e),e){const r=B.findKey(this,e);return!!(r&&this[r]!==void 0&&(!t||nh(this,this[r],r,t)))}return!1}delete(e,t){const r=this;let o=!1;function a(l){if(l=ls(l),l){const d=B.findKey(r,l);d&&(!t||nh(r,r[d],d,t))&&(delete r[d],o=!0)}}return B.isArray(e)?e.forEach(a):a(e),o}clear(e){const t=Object.keys(this);let r=t.length,o=!1;for(;r--;){const a=t[r];(!e||nh(this,this[a],a,e,!0))&&(delete this[a],o=!0)}return o}normalize(e){const t=this,r={};return B.forEach(this,(o,a)=>{const l=B.findKey(r,a);if(l){t[l]=vl(o),delete t[a];return}const d=e?gB(a):String(a).trim();d!==a&&delete t[a],t[d]=vl(o),r[d]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const t=Object.create(null);return B.forEach(this,(r,o)=>{r!=null&&r!==!1&&(t[o]=e&&B.isArray(r)?r.join(", "):r)}),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,t])=>e+": "+t).join(`
|
|
69
|
+
`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){const r=new this(e);return t.forEach(o=>r.set(o)),r}static accessor(e){const r=(this[k_]=this[k_]={accessors:{}}).accessors,o=this.prototype;function a(l){const d=ls(l);r[d]||(pB(o,l),r[d]=!0)}return B.isArray(e)?e.forEach(a):a(e),this}};Cn.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);B.reduceDescriptors(Cn.prototype,({value:n},e)=>{let t=e[0].toUpperCase()+e.slice(1);return{get:()=>n,set(r){this[t]=r}}});B.freezeMethods(Cn);function rh(n,e){const t=this||Ws,r=e||t,o=Cn.from(r.headers);let a=r.data;return B.forEach(n,function(d){a=d.call(t,a,o.normalize(),e?e.status:void 0)}),o.normalize(),a}function UE(n){return!!(n&&n.__CANCEL__)}function La(n,e,t){Te.call(this,n??"canceled",Te.ERR_CANCELED,e,t),this.name="CanceledError"}B.inherits(La,Te,{__CANCEL__:!0});function VE(n,e,t){const r=t.config.validateStatus;!t.status||!r||r(t.status)?n(t):e(new Te("Request failed with status code "+t.status,[Te.ERR_BAD_REQUEST,Te.ERR_BAD_RESPONSE][Math.floor(t.status/100)-4],t.config,t.request,t))}function vB(n){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(n);return e&&e[1]||""}function _B(n,e){n=n||10;const t=new Array(n),r=new Array(n);let o=0,a=0,l;return e=e!==void 0?e:1e3,function(h){const f=Date.now(),g=r[a];l||(l=f),t[o]=h,r[o]=f;let v=a,p=0;for(;v!==o;)p+=t[v++],v=v%n;if(o=(o+1)%n,o===a&&(a=(a+1)%n),f-l<e)return;const w=g&&f-g;return w?Math.round(p*1e3/w):void 0}}function yB(n,e){let t=0,r=1e3/e,o,a;const l=(f,g=Date.now())=>{t=g,o=null,a&&(clearTimeout(a),a=null),n.apply(null,f)};return[(...f)=>{const g=Date.now(),v=g-t;v>=r?l(f,g):(o=f,a||(a=setTimeout(()=>{a=null,l(o)},r-v)))},()=>o&&l(o)]}const Al=(n,e,t=3)=>{let r=0;const o=_B(50,250);return yB(a=>{const l=a.loaded,d=a.lengthComputable?a.total:void 0,h=l-r,f=o(h),g=l<=d;r=l;const v={loaded:l,total:d,progress:d?l/d:void 0,bytes:h,rate:f||void 0,estimated:f&&d&&g?(d-l)/f:void 0,event:a,lengthComputable:d!=null,[e?"download":"upload"]:!0};n(v)},t)},N_=(n,e)=>{const t=n!=null;return[r=>e[0]({lengthComputable:t,total:n,loaded:r}),e[1]]},O_=n=>(...e)=>B.asap(()=>n(...e)),CB=nn.hasStandardBrowserEnv?((n,e)=>t=>(t=new URL(t,nn.origin),n.protocol===t.protocol&&n.host===t.host&&(e||n.port===t.port)))(new URL(nn.origin),nn.navigator&&/(msie|trident)/i.test(nn.navigator.userAgent)):()=>!0,EB=nn.hasStandardBrowserEnv?{write(n,e,t,r,o,a){const l=[n+"="+encodeURIComponent(e)];B.isNumber(t)&&l.push("expires="+new Date(t).toGMTString()),B.isString(r)&&l.push("path="+r),B.isString(o)&&l.push("domain="+o),a===!0&&l.push("secure"),document.cookie=l.join("; ")},read(n){const e=document.cookie.match(new RegExp("(^|;\\s*)("+n+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove(n){this.write(n,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function wB(n){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(n)}function TB(n,e){return e?n.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):n}function BE(n,e,t){let r=!wB(e);return n&&r||t==!1?TB(n,e):e}const R_=n=>n instanceof Cn?{...n}:n;function Si(n,e){e=e||{};const t={};function r(f,g,v,p){return B.isPlainObject(f)&&B.isPlainObject(g)?B.merge.call({caseless:p},f,g):B.isPlainObject(g)?B.merge({},g):B.isArray(g)?g.slice():g}function o(f,g,v,p){if(B.isUndefined(g)){if(!B.isUndefined(f))return r(void 0,f,v,p)}else return r(f,g,v,p)}function a(f,g){if(!B.isUndefined(g))return r(void 0,g)}function l(f,g){if(B.isUndefined(g)){if(!B.isUndefined(f))return r(void 0,f)}else return r(void 0,g)}function d(f,g,v){if(v in e)return r(f,g);if(v in n)return r(void 0,f)}const h={url:a,method:a,data:a,baseURL:l,transformRequest:l,transformResponse:l,paramsSerializer:l,timeout:l,timeoutMessage:l,withCredentials:l,withXSRFToken:l,adapter:l,responseType:l,xsrfCookieName:l,xsrfHeaderName:l,onUploadProgress:l,onDownloadProgress:l,decompress:l,maxContentLength:l,maxBodyLength:l,beforeRedirect:l,transport:l,httpAgent:l,httpsAgent:l,cancelToken:l,socketPath:l,responseEncoding:l,validateStatus:d,headers:(f,g,v)=>o(R_(f),R_(g),v,!0)};return B.forEach(Object.keys(Object.assign({},n,e)),function(g){const v=h[g]||o,p=v(n[g],e[g],g);B.isUndefined(p)&&v!==d||(t[g]=p)}),t}const FE=n=>{const e=Si({},n);let{data:t,withXSRFToken:r,xsrfHeaderName:o,xsrfCookieName:a,headers:l,auth:d}=e;e.headers=l=Cn.from(l),e.url=DE(BE(e.baseURL,e.url),n.params,n.paramsSerializer),d&&l.set("Authorization","Basic "+btoa((d.username||"")+":"+(d.password?unescape(encodeURIComponent(d.password)):"")));let h;if(B.isFormData(t)){if(nn.hasStandardBrowserEnv||nn.hasStandardBrowserWebWorkerEnv)l.setContentType(void 0);else if((h=l.getContentType())!==!1){const[f,...g]=h?h.split(";").map(v=>v.trim()).filter(Boolean):[];l.setContentType([f||"multipart/form-data",...g].join("; "))}}if(nn.hasStandardBrowserEnv&&(r&&B.isFunction(r)&&(r=r(e)),r||r!==!1&&CB(e.url))){const f=o&&a&&EB.read(a);f&&l.set(o,f)}return e},bB=typeof XMLHttpRequest<"u",SB=bB&&function(n){return new Promise(function(t,r){const o=FE(n);let a=o.data;const l=Cn.from(o.headers).normalize();let{responseType:d,onUploadProgress:h,onDownloadProgress:f}=o,g,v,p,w,C;function T(){w&&w(),C&&C(),o.cancelToken&&o.cancelToken.unsubscribe(g),o.signal&&o.signal.removeEventListener("abort",g)}let S=new XMLHttpRequest;S.open(o.method.toUpperCase(),o.url,!0),S.timeout=o.timeout;function I(){if(!S)return;const D=Cn.from("getAllResponseHeaders"in S&&S.getAllResponseHeaders()),U={data:!d||d==="text"||d==="json"?S.responseText:S.response,status:S.status,statusText:S.statusText,headers:D,config:n,request:S};VE(function(R){t(R),T()},function(R){r(R),T()},U),S=null}"onloadend"in S?S.onloadend=I:S.onreadystatechange=function(){!S||S.readyState!==4||S.status===0&&!(S.responseURL&&S.responseURL.indexOf("file:")===0)||setTimeout(I)},S.onabort=function(){S&&(r(new Te("Request aborted",Te.ECONNABORTED,n,S)),S=null)},S.onerror=function(){r(new Te("Network Error",Te.ERR_NETWORK,n,S)),S=null},S.ontimeout=function(){let L=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded";const U=o.transitional||LE;o.timeoutErrorMessage&&(L=o.timeoutErrorMessage),r(new Te(L,U.clarifyTimeoutError?Te.ETIMEDOUT:Te.ECONNABORTED,n,S)),S=null},a===void 0&&l.setContentType(null),"setRequestHeader"in S&&B.forEach(l.toJSON(),function(L,U){S.setRequestHeader(U,L)}),B.isUndefined(o.withCredentials)||(S.withCredentials=!!o.withCredentials),d&&d!=="json"&&(S.responseType=o.responseType),f&&([p,C]=Al(f,!0),S.addEventListener("progress",p)),h&&S.upload&&([v,w]=Al(h),S.upload.addEventListener("progress",v),S.upload.addEventListener("loadend",w)),(o.cancelToken||o.signal)&&(g=D=>{S&&(r(!D||D.type?new La(null,n,S):D),S.abort(),S=null)},o.cancelToken&&o.cancelToken.subscribe(g),o.signal&&(o.signal.aborted?g():o.signal.addEventListener("abort",g)));const N=vB(o.url);if(N&&nn.protocols.indexOf(N)===-1){r(new Te("Unsupported protocol "+N+":",Te.ERR_BAD_REQUEST,n));return}S.send(a||null)})},IB=(n,e)=>{const{length:t}=n=n?n.filter(Boolean):[];if(e||t){let r=new AbortController,o;const a=function(f){if(!o){o=!0,d();const g=f instanceof Error?f:this.reason;r.abort(g instanceof Te?g:new La(g instanceof Error?g.message:g))}};let l=e&&setTimeout(()=>{l=null,a(new Te(`timeout ${e} of ms exceeded`,Te.ETIMEDOUT))},e);const d=()=>{n&&(l&&clearTimeout(l),l=null,n.forEach(f=>{f.unsubscribe?f.unsubscribe(a):f.removeEventListener("abort",a)}),n=null)};n.forEach(f=>f.addEventListener("abort",a));const{signal:h}=r;return h.unsubscribe=()=>B.asap(d),h}},AB=function*(n,e){let t=n.byteLength;if(t<e){yield n;return}let r=0,o;for(;r<t;)o=r+e,yield n.slice(r,o),r=o},kB=async function*(n,e){for await(const t of NB(n))yield*AB(t,e)},NB=async function*(n){if(n[Symbol.asyncIterator]){yield*n;return}const e=n.getReader();try{for(;;){const{done:t,value:r}=await e.read();if(t)break;yield r}}finally{await e.cancel()}},P_=(n,e,t,r)=>{const o=kB(n,e);let a=0,l,d=h=>{l||(l=!0,r&&r(h))};return new ReadableStream({async pull(h){try{const{done:f,value:g}=await o.next();if(f){d(),h.close();return}let v=g.byteLength;if(t){let p=a+=v;t(p)}h.enqueue(new Uint8Array(g))}catch(f){throw d(f),f}},cancel(h){return d(h),o.return()}},{highWaterMark:2})},ou=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",$E=ou&&typeof ReadableStream=="function",OB=ou&&(typeof TextEncoder=="function"?(n=>e=>n.encode(e))(new TextEncoder):async n=>new Uint8Array(await new Response(n).arrayBuffer())),HE=(n,...e)=>{try{return!!n(...e)}catch{return!1}},RB=$E&&HE(()=>{let n=!1;const e=new Request(nn.origin,{body:new ReadableStream,method:"POST",get duplex(){return n=!0,"half"}}).headers.has("Content-Type");return n&&!e}),M_=64*1024,zh=$E&&HE(()=>B.isReadableStream(new Response("").body)),kl={stream:zh&&(n=>n.body)};ou&&(n=>{["text","arrayBuffer","blob","formData","stream"].forEach(e=>{!kl[e]&&(kl[e]=B.isFunction(n[e])?t=>t[e]():(t,r)=>{throw new Te(`Response type '${e}' is not supported`,Te.ERR_NOT_SUPPORT,r)})})})(new Response);const PB=async n=>{if(n==null)return 0;if(B.isBlob(n))return n.size;if(B.isSpecCompliantForm(n))return(await new Request(nn.origin,{method:"POST",body:n}).arrayBuffer()).byteLength;if(B.isArrayBufferView(n)||B.isArrayBuffer(n))return n.byteLength;if(B.isURLSearchParams(n)&&(n=n+""),B.isString(n))return(await OB(n)).byteLength},MB=async(n,e)=>{const t=B.toFiniteNumber(n.getContentLength());return t??PB(e)},DB=ou&&(async n=>{let{url:e,method:t,data:r,signal:o,cancelToken:a,timeout:l,onDownloadProgress:d,onUploadProgress:h,responseType:f,headers:g,withCredentials:v="same-origin",fetchOptions:p}=FE(n);f=f?(f+"").toLowerCase():"text";let w=IB([o,a&&a.toAbortSignal()],l),C;const T=w&&w.unsubscribe&&(()=>{w.unsubscribe()});let S;try{if(h&&RB&&t!=="get"&&t!=="head"&&(S=await MB(g,r))!==0){let U=new Request(e,{method:"POST",body:r,duplex:"half"}),F;if(B.isFormData(r)&&(F=U.headers.get("content-type"))&&g.setContentType(F),U.body){const[R,ae]=N_(S,Al(O_(h)));r=P_(U.body,M_,R,ae)}}B.isString(v)||(v=v?"include":"omit");const I="credentials"in Request.prototype;C=new Request(e,{...p,signal:w,method:t.toUpperCase(),headers:g.normalize().toJSON(),body:r,duplex:"half",credentials:I?v:void 0});let N=await fetch(C);const D=zh&&(f==="stream"||f==="response");if(zh&&(d||D&&T)){const U={};["status","statusText","headers"].forEach(se=>{U[se]=N[se]});const F=B.toFiniteNumber(N.headers.get("content-length")),[R,ae]=d&&N_(F,Al(O_(d),!0))||[];N=new Response(P_(N.body,M_,R,()=>{ae&&ae(),T&&T()}),U)}f=f||"text";let L=await kl[B.findKey(kl,f)||"text"](N,n);return!D&&T&&T(),await new Promise((U,F)=>{VE(U,F,{data:L,headers:Cn.from(N.headers),status:N.status,statusText:N.statusText,config:n,request:C})})}catch(I){throw T&&T(),I&&I.name==="TypeError"&&/fetch/i.test(I.message)?Object.assign(new Te("Network Error",Te.ERR_NETWORK,n,C),{cause:I.cause||I}):Te.from(I,I&&I.code,n,C)}}),Gh={http:YV,xhr:SB,fetch:DB};B.forEach(Gh,(n,e)=>{if(n){try{Object.defineProperty(n,"name",{value:e})}catch{}Object.defineProperty(n,"adapterName",{value:e})}});const D_=n=>`- ${n}`,LB=n=>B.isFunction(n)||n===null||n===!1,KE={getAdapter:n=>{n=B.isArray(n)?n:[n];const{length:e}=n;let t,r;const o={};for(let a=0;a<e;a++){t=n[a];let l;if(r=t,!LB(t)&&(r=Gh[(l=String(t)).toLowerCase()],r===void 0))throw new Te(`Unknown adapter '${l}'`);if(r)break;o[l||"#"+a]=r}if(!r){const a=Object.entries(o).map(([d,h])=>`adapter ${d} `+(h===!1?"is not supported by the environment":"is not available in the build"));let l=e?a.length>1?`since :
|
|
70
|
+
`+a.map(D_).join(`
|
|
71
|
+
`):" "+D_(a[0]):"as no adapter specified";throw new Te("There is no suitable adapter to dispatch the request "+l,"ERR_NOT_SUPPORT")}return r},adapters:Gh};function oh(n){if(n.cancelToken&&n.cancelToken.throwIfRequested(),n.signal&&n.signal.aborted)throw new La(null,n)}function L_(n){return oh(n),n.headers=Cn.from(n.headers),n.data=rh.call(n,n.transformRequest),["post","put","patch"].indexOf(n.method)!==-1&&n.headers.setContentType("application/x-www-form-urlencoded",!1),KE.getAdapter(n.adapter||Ws.adapter)(n).then(function(r){return oh(n),r.data=rh.call(n,n.transformResponse,r),r.headers=Cn.from(r.headers),r},function(r){return UE(r)||(oh(n),r&&r.response&&(r.response.data=rh.call(n,n.transformResponse,r.response),r.response.headers=Cn.from(r.response.headers))),Promise.reject(r)})}const WE="1.8.2",iu={};["object","boolean","number","function","string","symbol"].forEach((n,e)=>{iu[n]=function(r){return typeof r===n||"a"+(e<1?"n ":" ")+n}});const x_={};iu.transitional=function(e,t,r){function o(a,l){return"[Axios v"+WE+"] Transitional option '"+a+"'"+l+(r?". "+r:"")}return(a,l,d)=>{if(e===!1)throw new Te(o(l," has been removed"+(t?" in "+t:"")),Te.ERR_DEPRECATED);return t&&!x_[l]&&(x_[l]=!0,console.warn(o(l," has been deprecated since v"+t+" and will be removed in the near future"))),e?e(a,l,d):!0}};iu.spelling=function(e){return(t,r)=>(console.warn(`${r} is likely a misspelling of ${e}`),!0)};function xB(n,e,t){if(typeof n!="object")throw new Te("options must be an object",Te.ERR_BAD_OPTION_VALUE);const r=Object.keys(n);let o=r.length;for(;o-- >0;){const a=r[o],l=e[a];if(l){const d=n[a],h=d===void 0||l(d,a,n);if(h!==!0)throw new Te("option "+a+" must be "+h,Te.ERR_BAD_OPTION_VALUE);continue}if(t!==!0)throw new Te("Unknown option "+a,Te.ERR_BAD_OPTION)}}const _l={assertOptions:xB,validators:iu},Dr=_l.validators;let Ci=class{constructor(e){this.defaults=e,this.interceptors={request:new A_,response:new A_}}async request(e,t){try{return await this._request(e,t)}catch(r){if(r instanceof Error){let o={};Error.captureStackTrace?Error.captureStackTrace(o):o=new Error;const a=o.stack?o.stack.replace(/^.+\n/,""):"";try{r.stack?a&&!String(r.stack).endsWith(a.replace(/^.+\n.+\n/,""))&&(r.stack+=`
|
|
72
|
+
`+a):r.stack=a}catch{}}throw r}}_request(e,t){typeof e=="string"?(t=t||{},t.url=e):t=e||{},t=Si(this.defaults,t);const{transitional:r,paramsSerializer:o,headers:a}=t;r!==void 0&&_l.assertOptions(r,{silentJSONParsing:Dr.transitional(Dr.boolean),forcedJSONParsing:Dr.transitional(Dr.boolean),clarifyTimeoutError:Dr.transitional(Dr.boolean)},!1),o!=null&&(B.isFunction(o)?t.paramsSerializer={serialize:o}:_l.assertOptions(o,{encode:Dr.function,serialize:Dr.function},!0)),t.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:t.allowAbsoluteUrls=!0),_l.assertOptions(t,{baseUrl:Dr.spelling("baseURL"),withXsrfToken:Dr.spelling("withXSRFToken")},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();let l=a&&B.merge(a.common,a[t.method]);a&&B.forEach(["delete","get","head","post","put","patch","common"],C=>{delete a[C]}),t.headers=Cn.concat(l,a);const d=[];let h=!0;this.interceptors.request.forEach(function(T){typeof T.runWhen=="function"&&T.runWhen(t)===!1||(h=h&&T.synchronous,d.unshift(T.fulfilled,T.rejected))});const f=[];this.interceptors.response.forEach(function(T){f.push(T.fulfilled,T.rejected)});let g,v=0,p;if(!h){const C=[L_.bind(this),void 0];for(C.unshift.apply(C,d),C.push.apply(C,f),p=C.length,g=Promise.resolve(t);v<p;)g=g.then(C[v++],C[v++]);return g}p=d.length;let w=t;for(v=0;v<p;){const C=d[v++],T=d[v++];try{w=C(w)}catch(S){T.call(this,S);break}}try{g=L_.call(this,w)}catch(C){return Promise.reject(C)}for(v=0,p=f.length;v<p;)g=g.then(f[v++],f[v++]);return g}getUri(e){e=Si(this.defaults,e);const t=BE(e.baseURL,e.url,e.allowAbsoluteUrls);return DE(t,e.params,e.paramsSerializer)}};B.forEach(["delete","get","head","options"],function(e){Ci.prototype[e]=function(t,r){return this.request(Si(r||{},{method:e,url:t,data:(r||{}).data}))}});B.forEach(["post","put","patch"],function(e){function t(r){return function(a,l,d){return this.request(Si(d||{},{method:e,headers:r?{"Content-Type":"multipart/form-data"}:{},url:a,data:l}))}}Ci.prototype[e]=t(),Ci.prototype[e+"Form"]=t(!0)});let UB=class zE{constructor(e){if(typeof e!="function")throw new TypeError("executor must be a function.");let t;this.promise=new Promise(function(a){t=a});const r=this;this.promise.then(o=>{if(!r._listeners)return;let a=r._listeners.length;for(;a-- >0;)r._listeners[a](o);r._listeners=null}),this.promise.then=o=>{let a;const l=new Promise(d=>{r.subscribe(d),a=d}).then(o);return l.cancel=function(){r.unsubscribe(a)},l},e(function(a,l,d){r.reason||(r.reason=new La(a,l,d),t(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const t=this._listeners.indexOf(e);t!==-1&&this._listeners.splice(t,1)}toAbortSignal(){const e=new AbortController,t=r=>{e.abort(r)};return this.subscribe(t),e.signal.unsubscribe=()=>this.unsubscribe(t),e.signal}static source(){let e;return{token:new zE(function(o){e=o}),cancel:e}}};function VB(n){return function(t){return n.apply(null,t)}}function BB(n){return B.isObject(n)&&n.isAxiosError===!0}const qh={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(qh).forEach(([n,e])=>{qh[e]=n});function GE(n){const e=new Ci(n),t=TE(Ci.prototype.request,e);return B.extend(t,Ci.prototype,e,{allOwnKeys:!0}),B.extend(t,e,null,{allOwnKeys:!0}),t.create=function(o){return GE(Si(n,o))},t}const gt=GE(Ws);gt.Axios=Ci;gt.CanceledError=La;gt.CancelToken=UB;gt.isCancel=UE;gt.VERSION=WE;gt.toFormData=ru;gt.AxiosError=Te;gt.Cancel=gt.CanceledError;gt.all=function(e){return Promise.all(e)};gt.spread=VB;gt.isAxiosError=BB;gt.mergeConfig=Si;gt.AxiosHeaders=Cn;gt.formToJSON=n=>xE(B.isHTMLForm(n)?new FormData(n):n);gt.getAdapter=KE.getAdapter;gt.HttpStatusCode=qh;gt.default=gt;const{Axios:U4,AxiosError:V4,CanceledError:B4,isCancel:F4,CancelToken:$4,VERSION:H4,all:K4,Cancel:W4,isAxiosError:z4,spread:G4,toFormData:q4,AxiosHeaders:j4,HttpStatusCode:Y4,formToJSON:J4,getAdapter:Q4,mergeConfig:X4}=gt;async function FB({url:n,method:e,header:t={},body:r,bearerToken:o}){const a=o?{Authorization:`Bearer ${o}`}:{};try{return(await gt({url:n,method:e,headers:{...t,...a},data:r??{}})).data}catch(l){throw console.error(`Request failed for ${e} ${n}:`,l),l}}function xa(n,e,t=[]){const r=HB(e);if(!r)return n;const o=r.split(" ");return n.filter(a=>$B(a,o,t))}function $B(n,e,t){return t.some(r=>{const o=ul.get(n,r);if(ul.isNil(o))return!1;const a=ul.toString(o).toLowerCase();return e.every(l=>a.includes(l))})}function HB(n){return ul.trim(n).toLowerCase().replace(/\s+/g," ")}async function KB(n,...e){le.value=!0;try{return await Promise.resolve(n(...e))}finally{le.value=!1}}const WB={class:"text-faded mt-7"},zB={key:0,class:"d-flex align-baseline mb-1"},GB={class:"me-1"},qB={class:"max-w-_form-metadataJ"},jB={key:0,class:"mb-1"},YB={key:1,class:"mb-1"},JB={class:"mb-1"},au=s.defineComponent({__name:"FormMetadata",props:{meta:{},id:{}},setup(n){const{t:e}=rn();return(t,r)=>(s.openBlock(),s.createElementBlock("div",WB,[s.createVNode(xe.VRow,{"no-gutters":"",class:"align-end ga-3",align:"center"},{default:s.withCtx(()=>[s.renderSlot(t.$slots,"default"),s.createVNode(xe.VCol,{cols:"auto",class:"pa-2"},{default:s.withCtx(()=>[t.id?(s.openBlock(),s.createElementBlock("p",zB,[s.createElementVNode("b",GB,s.toDisplayString(t.id.title)+": ",1),s.createElementVNode("span",qB,s.toDisplayString(t.id.key||"-"),1),s.createElementVNode("span",null,[s.createVNode(Us,{"content-to-copy":t.id.key,size:15},null,8,["content-to-copy"])])])):s.createCommentVNode("",!0),s.createElementVNode("p",null,[s.createElementVNode("b",null,s.toDisplayString(s.unref(e)("forms.metadata.created"))+": ",1),s.createTextVNode(s.toDisplayString(s.unref(Es)(t.meta.created_at))+" - "+s.toDisplayString(t.meta.created_by),1)])]),_:1}),s.createVNode(xe.VCol,{cols:"auto",class:"d-flex flex-column align-baseline px-2 mt-1"},{default:s.withCtx(()=>[t.meta.updated_at&&t.meta.updated_by?(s.openBlock(),s.createElementBlock("p",jB,[s.createElementVNode("b",null,s.toDisplayString(s.unref(e)("forms.metadata.updated"))+": ",1),s.createTextVNode(s.toDisplayString(s.unref(Es)(t.meta.updated_at))+" - "+s.toDisplayString(t.meta.updated_by),1)])):(s.openBlock(),s.createElementBlock("p",YB,[s.createElementVNode("b",null,s.toDisplayString(s.unref(e)("forms.metadata.modified"))+": ",1),s.createTextVNode(s.toDisplayString(s.unref(Es)(t.meta.modified_at))+" - "+s.toDisplayString(t.meta.modified_by),1)])),s.createElementVNode("p",JB,[s.createElementVNode("b",null,s.toDisplayString(s.unref(e)("forms.metadata.delegated"))+": ",1),s.createTextVNode(s.toDisplayString(t.meta.delegated_at)+" - "+s.toDisplayString(t.meta.delegated_by),1)])]),_:1})]),_:3})]))}}),QB={key:0,class:"mb-2 ms-1"},qE=s.defineComponent({__name:"JSelect",props:s.mergeModels({name:{},label:{},placeholder:{},readonly:{type:Boolean},items:{},itemTitle:{},itemValue:{},density:{},loading:{type:Boolean},clearable:{type:Boolean,default:!0},rules:{},hideDetails:{type:Boolean}},{modelValue:{},modelModifiers:{}}),emits:["update:modelValue"],setup(n){const e=s.useModel(n,"modelValue");return(t,r)=>(s.openBlock(),s.createElementBlock(s.Fragment,null,[t.name?(s.openBlock(),s.createElementBlock("p",QB,s.toDisplayString(t.name),1)):s.createCommentVNode("",!0),t.label?(s.openBlock(),s.createBlock(Ei.VLabel,{key:1,class:"text-subtitle-1 text-high-emphasis mb-2"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(t.label),1)]),_:1})):s.createCommentVNode("",!0),s.createVNode(s.unref(ho.VSelect),{modelValue:e.value,"onUpdate:modelValue":r[0]||(r[0]=o=>e.value=o),variant:"solo-filled",items:t.items,"item-title":t.itemTitle,"item-value":t.itemValue,loading:t.loading,placeholder:t.placeholder,density:t.density,"bg-color":t.readonly?"containerBg30":"containerBg",rounded:"false",class:s.normalizeClass(["j-field",{readonly:t.readonly}]),style:{"min-height":"44.5px"},clearable:!t.readonly&&t.clearable,readonly:t.readonly,rules:t.rules,"hide-details":t.hideDetails},null,8,["modelValue","items","item-title","item-value","loading","placeholder","density","bg-color","class","clearable","readonly","rules","hide-details"])],64))}}),XB={key:0,class:"mb-2 ms-1"},jE=s.defineComponent({__name:"JNumberField",props:s.mergeModels({name:{},label:{},readonly:{type:Boolean},density:{},rules:{},hideDetails:{type:Boolean},min:{},max:{}},{modelValue:{},modelModifiers:{}}),emits:["update:modelValue"],setup(n){const e=s.useModel(n,"modelValue"),t=n,r=o=>{t.min===0&&(o.key==="-"||o.key==="Subtract")&&o.preventDefault()};return(o,a)=>(s.openBlock(),s.createElementBlock("div",null,[o.name?(s.openBlock(),s.createElementBlock("p",XB,s.toDisplayString(o.name),1)):s.createCommentVNode("",!0),o.label?(s.openBlock(),s.createBlock(Ei.VLabel,{key:1,class:"text-subtitle-1 text-high-emphasis mb-2"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(o.label),1)]),_:1})):s.createCommentVNode("",!0),s.createVNode(s.unref(ho.VTextField),{variant:"solo-filled","bg-color":o.readonly?"containerBg30":"containerBg",color:"secondary",rounded:"sm",type:"number",density:o.density,rules:o.rules,modelValue:e.value,"onUpdate:modelValue":a[0]||(a[0]=l=>e.value=l),class:s.normalizeClass(["j-field",{readonly:o.readonly}]),readonly:o.readonly,"hide-details":o.hideDetails,min:o.min,max:o.max,onKeydown:r},null,8,["bg-color","density","rules","modelValue","class","readonly","hide-details","min","max"])]))}}),ZB={key:0,class:"mb-2 ms-1"},eF={key:3,class:"j-field px-4 py-3 rounded-sm bg-containerBg elevation-10"},YE=s.defineComponent({__name:"JAutocomplete",props:s.mergeModels({name:{},label:{},placeholder:{},readonly:{type:Boolean},items:{},itemTitle:{},itemValue:{},density:{},loading:{type:Boolean},clearable:{type:Boolean,default:!0}},{modelValue:{},modelModifiers:{}}),emits:["update:modelValue"],setup(n){const e=s.useModel(n,"modelValue"),t=n,r=s.computed(()=>t.readonly?"solo":"solo-filled"),o=s.computed(()=>{if(Array.isArray(t.items)&&t.items.length>0&&e!=null)if(typeof t.items[0]=="object"&&t.itemValue&&t.itemTitle){const a=t.items.find(l=>l[t.itemValue]===e);return a?a[t.itemTitle]:e}else{const a=t.items.indexOf(e);return a!==-1?t.items[a]:e}return e});return(a,l)=>(s.openBlock(),s.createElementBlock(s.Fragment,null,[t.name?(s.openBlock(),s.createElementBlock("p",ZB,s.toDisplayString(t.name),1)):s.createCommentVNode("",!0),t.label?(s.openBlock(),s.createBlock(Ei.VLabel,{key:1,class:"text-subtitle-1 text-high-emphasis mb-2"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(t.label),1)]),_:1})):s.createCommentVNode("",!0),t.readonly?(s.openBlock(),s.createElementBlock("div",eF,s.toDisplayString(o.value),1)):(s.openBlock(),s.createBlock(LR.VAutocomplete,{key:2,modelValue:e.value,"onUpdate:modelValue":l[0]||(l[0]=d=>e.value=d),variant:r.value,items:t.items,"item-title":t.itemTitle,"item-value":t.itemValue,loading:t.loading,placeholder:t.placeholder,density:t.density,"bg-color":"containerBg",rounded:"false","hide-details":"",class:"j-field",clearable:t.clearable,readonly:t.readonly},null,8,["modelValue","variant","items","item-title","item-value","loading","placeholder","density","clearable","readonly"]))],64))}}),tF={key:0,class:"mb-2 ms-1"},JE=s.defineComponent({__name:"JTextArea",props:s.mergeModels({name:{},label:{},readonly:{type:Boolean},rows:{},hideDetails:{type:Boolean}},{modelValue:{},modelModifiers:{}}),emits:["update:modelValue"],setup(n){const e=s.useModel(n,"modelValue");return(t,r)=>(s.openBlock(),s.createElementBlock(s.Fragment,null,[t.name?(s.openBlock(),s.createElementBlock("p",tF,s.toDisplayString(t.name),1)):s.createCommentVNode("",!0),t.label?(s.openBlock(),s.createBlock(Ei.VLabel,{key:1,class:"text-subtitle-1 text-high-emphasis mb-2"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(t.label),1)]),_:1})):s.createCommentVNode("",!0),s.createVNode(xR.VTextarea,{variant:"solo-filled","bg-color":t.readonly?"containerBg30":"containerBg",rounded:"false",rows:t.rows,hideDetails:t.hideDetails,modelValue:e.value,"onUpdate:modelValue":r[0]||(r[0]=o=>e.value=o),"no-resize":"",readonly:t.readonly,class:s.normalizeClass(["j-textarea",{readonly:t.readonly}])},null,8,["bg-color","rows","hideDetails","modelValue","readonly","class"])],64))}}),QE=s.defineComponent({__name:"CancelButton",props:{title:{}},emits:["cancel"],setup(n,{emit:e}){const t=e,{t:r}=rn();return(o,a)=>(s.openBlock(),s.createBlock(Me.VBtn,{color:"secondary",variant:"outlined",onClick:a[0]||(a[0]=l=>t("cancel")),class:"me-2 j-btn-form",height:"36"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(o.title?s.unref(r)("actions.cancel"):s.unref(r)("actions.back")),1)]),_:1}))}}),XE=s.defineComponent({__name:"SaveButton",props:{disabled:{type:Boolean}},emits:["onSave"],setup(n,{emit:e}){const t=e,r=s.ref(!1);async function o(){r.value=!0,await t("onSave"),r.value=!1}const{t:a}=rn();return(l,d)=>(s.openBlock(),s.createBlock(Me.VBtn,{disabled:l.disabled,loading:r.value,color:"secondary",onClick:o,onKeydown:s.withKeys(o,["enter"]),class:"j-btn-form",height:"36"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(s.unref(a)("actions.save")),1)]),_:1},8,["disabled","loading"]))}}),nF={class:"mt-4"},ZE=s.defineComponent({__name:"JForm",props:{title:{},metadata:{},id:{},cancelReturn:{type:Boolean}},emits:["onSave","onCancel"],setup(n,{emit:e}){const t=e;return(r,o)=>(s.openBlock(),s.createBlock(Jl,{title:r.title,class:"d-flex flex-column ma-0"},{default:s.withCtx(()=>[r.title?(s.openBlock(),s.createBlock(fo.VDivider,{key:0})):s.createCommentVNode("",!0),s.createElementVNode("div",nF,[s.renderSlot(r.$slots,"default")]),s.createVNode(Ut.VCardText,{class:"pa-0 mx-0 align-content-end"},{default:s.withCtx(()=>[s.createVNode(xe.VRow,{justify:"space-between",class:"mt-4"},{default:s.withCtx(()=>[s.createVNode(xe.VCol,{cols:"auto",class:"text-sm-subtitle-2 text-medium-emphasis"},{default:s.withCtx(()=>[s.createVNode(au,{id:r.id,meta:r.metadata},null,8,["id","meta"])]),_:1}),s.createVNode(xe.VSpacer),s.createVNode(xe.VCol,{cols:"auto",class:"align-content-end"},{default:s.withCtx(()=>[s.createVNode(QE,{"cancel-return":r.cancelReturn,onCancel:o[0]||(o[0]=a=>t("onCancel"))},null,8,["cancel-return"]),s.createVNode(XE,{onOnSave:o[1]||(o[1]=a=>t("onSave"))})]),_:1})]),_:1})]),_:1})]),_:3},8,["title"]))}}),rF={class:"d-flex align-items-center"},oF={key:0,class:"d-flex align-center"},iF={class:"ms-1"},aF={class:"d-flex"},sF={class:"d-flex mb-1 align-center"},cF={class:"min-w-100 relative"},ew=s.defineComponent({__name:"TabFormHeader",props:{id:{},readonly:{type:Boolean,default:!1}},emits:["update:isEdition","save","cancel","delete","disable"],setup(n,{emit:e}){var v;const t=n,r=e,o=s.getCurrentInstance(),a=((v=o==null?void 0:o.vnode.props)==null?void 0:v.onDisable)!==void 0,l=s.ref(t.readonly);function d(){r("cancel"),l.value=!1,r("update:isEdition",l.value)}function h(){l.value=!l.value,r("update:isEdition",l.value)}async function f(){r("delete"),r("disable")}const{t:g}=rn();return(p,w)=>(s.openBlock(),s.createElementBlock("div",rF,[p.id?(s.openBlock(),s.createElementBlock("div",oF,[w[0]||(w[0]=s.createElementVNode("b",null,"ID:",-1)),s.createElementVNode("span",iF,s.toDisplayString(p.id),1),s.createVNode(Us,{"content-to-copy":p.id,size:20},null,8,["content-to-copy"])])):s.createCommentVNode("",!0),s.createVNode(xe.VSpacer),s.createElementVNode("div",aF,[s.createVNode(Me.VBtn,{onClick:f,variant:"text"},{default:s.withCtx(()=>[a?(s.openBlock(),s.createBlock(s.unref(sC),{key:0,size:"11",class:"me-2"})):(s.openBlock(),s.createBlock(_r.VIcon,{key:1,class:"me-2"},{default:s.withCtx(()=>w[1]||(w[1]=[s.createTextVNode("mdi-delete-outline")])),_:1})),s.createTextVNode(" "+s.toDisplayString(a?s.unref(g)("actions.disable"):s.unref(g)("actions.delete")),1)]),_:1}),s.createElementVNode("div",sF,[s.createVNode(fo.VDivider,{class:"mx-2 my-1",vertical:""}),s.createElementVNode("div",cF,[s.withDirectives(s.createVNode(Me.VBtn,{onClick:h,variant:"text",color:"secondary","prepend-icon":"mdi-pencil",width:"95"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(s.unref(g)("actions.edit")),1)]),_:1},512),[[s.vShow,!l.value]]),s.withDirectives(s.createVNode(Me.VBtn,{onClick:d,variant:"text",color:"secondary",width:"95"},{default:s.withCtx(()=>[s.createVNode(_r.VIcon,{class:"pt-1 pe-2"},{default:s.withCtx(()=>w[2]||(w[2]=[s.createTextVNode("mdi-close")])),_:1}),s.createTextVNode(" "+s.toDisplayString(s.unref(g)("actions.cancel")),1)]),_:1},512),[[s.vShow,l.value]])])])])]))}}),lF={class:"d-flex align-items-center"},uF={key:0,class:"d-flex align-center"},dF={class:"ms-1"},hF={class:"d-flex"},fF={class:"d-flex mb-1 align-center"},mF={class:"min-w-100 relative"},tw=s.defineComponent({__name:"TabFormHeaderV2",props:s.mergeModels({id:{}},{modelValue:{type:Boolean},modelModifiers:{}}),emits:s.mergeModels(["save","cancel","delete","disable"],["update:modelValue"]),setup(n,{emit:e}){var g;const t=s.useModel(n,"modelValue"),r=e,o=s.getCurrentInstance(),a=((g=o==null?void 0:o.vnode.props)==null?void 0:g.onDisable)!==void 0;function l(){r("cancel"),t.value=!0}function d(){t.value=!t.value}async function h(){r("delete"),r("disable")}const{t:f}=rn();return(v,p)=>(s.openBlock(),s.createElementBlock("div",lF,[v.id?(s.openBlock(),s.createElementBlock("div",uF,[p[0]||(p[0]=s.createElementVNode("b",null,"ID:",-1)),s.createElementVNode("span",dF,s.toDisplayString(v.id),1),s.createVNode(Us,{"content-to-copy":v.id,size:20},null,8,["content-to-copy"])])):s.createCommentVNode("",!0),s.createVNode(xe.VSpacer),s.createElementVNode("div",hF,[s.createVNode(Me.VBtn,{onClick:h,variant:"text"},{default:s.withCtx(()=>[a?(s.openBlock(),s.createBlock(s.unref(sC),{key:0,size:"11",class:"me-2"})):(s.openBlock(),s.createBlock(_r.VIcon,{key:1,class:"me-2"},{default:s.withCtx(()=>p[1]||(p[1]=[s.createTextVNode("mdi-delete-outline")])),_:1})),s.createTextVNode(" "+s.toDisplayString(a?s.unref(f)("actions.disable"):s.unref(f)("actions.delete")),1)]),_:1}),s.createElementVNode("div",fF,[s.createVNode(fo.VDivider,{class:"mx-2 my-1",vertical:""}),s.createElementVNode("div",mF,[s.withDirectives(s.createVNode(Me.VBtn,{onClick:d,variant:"text",color:"secondary","prepend-icon":"mdi-pencil",width:"95"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(s.unref(f)("actions.edit")),1)]),_:1},512),[[s.vShow,t.value]]),s.withDirectives(s.createVNode(Me.VBtn,{onClick:l,variant:"text",color:"secondary",width:"95"},{default:s.withCtx(()=>[s.createVNode(_r.VIcon,{class:"pt-1 pe-2"},{default:s.withCtx(()=>p[2]||(p[2]=[s.createTextVNode("mdi-close")])),_:1}),s.createTextVNode(" "+s.toDisplayString(s.unref(f)("actions.cancel")),1)]),_:1},512),[[s.vShow,!t.value]])])])])]))}}),gF={class:"d-flex flex-column"},pF={class:"height d-flex flex-column"},vF={class:"d-flex justify-between align-end"},_F=s.defineComponent({__name:"FormHeadless",props:{id:{},metadata:{},readonly:{type:Boolean,default:!1}},emits:["save","cancel"],setup(n,{emit:e}){const t=e,r=s.getCurrentInstance(),o=s.computed(()=>{var l;return!!((l=r==null?void 0:r.vnode.props)!=null&&l.onSave)}),a=s.computed(()=>{var l;return!!((l=r==null?void 0:r.vnode.props)!=null&&l.onCancel)});return(l,d)=>(s.openBlock(),s.createBlock(Jl,null,{default:s.withCtx(()=>[s.createElementVNode("div",gF,[s.createElementVNode("div",pF,[s.renderSlot(l.$slots,"default",{},void 0,!0)])]),s.createElementVNode("div",vF,[s.createVNode(xe.VRow,{"no-gutters":"",justify:"space-between",class:"w-100"},{default:s.withCtx(()=>[s.createVNode(xe.VCol,{cols:"auto",class:"text-sm-subtitle-2 text-medium-emphasis"},{default:s.withCtx(()=>[s.createVNode(au,{id:l.id,meta:l.metadata},null,8,["id","meta"])]),_:1}),l.readonly?s.createCommentVNode("",!0):(s.openBlock(),s.createBlock(xe.VCol,{key:0,class:"d-flex align-end",cols:"auto"},{default:s.withCtx(()=>[a.value?(s.openBlock(),s.createBlock(QE,{key:0,title:"Back",onCancel:d[0]||(d[0]=h=>t("cancel"))})):s.createCommentVNode("",!0),o.value?(s.openBlock(),s.createBlock(XE,{key:1,onOnSave:d[1]||(d[1]=h=>t("save"))})):s.createCommentVNode("",!0)]),_:1}))]),_:1})])]),_:3}))}}),nw=Qo(_F,[["__scopeId","data-v-e7e4d99c"]]);/**
|
|
73
|
+
* @license @tabler/icons-vue v3.22.0 - MIT
|
|
74
|
+
*
|
|
75
|
+
* This source code is licensed under the MIT license.
|
|
76
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
77
|
+
*/var U_={outline:{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":2,"stroke-linecap":"round","stroke-linejoin":"round"},filled:{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"currentColor",stroke:"none"}};/**
|
|
78
|
+
* @license @tabler/icons-vue v3.22.0 - MIT
|
|
79
|
+
*
|
|
80
|
+
* This source code is licensed under the MIT license.
|
|
81
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
82
|
+
*/const zs=(n,e,t,r)=>({color:o="currentColor",size:a=24,stroke:l=2,title:d,class:h,...f},{attrs:g,slots:v})=>{let p=[...r.map(w=>s.h(...w)),...v.default?[v.default()]:[]];return d&&(p=[s.h("title",d),...p]),s.h("svg",{...U_[n],width:a,height:a,...g,class:["tabler-icon",`tabler-icon-${e}`],...n==="filled"?{fill:o}:{"stroke-width":l??U_[n]["stroke-width"],stroke:o},...f},p)};/**
|
|
83
|
+
* @license @tabler/icons-vue v3.22.0 - MIT
|
|
84
|
+
*
|
|
85
|
+
* This source code is licensed under the MIT license.
|
|
86
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
87
|
+
*/var yF=zs("outline","buildings","IconBuildings",[["path",{d:"M4 21v-15c0 -1 1 -2 2 -2h5c1 0 2 1 2 2v15",key:"svg-0"}],["path",{d:"M16 8h2c1 0 2 1 2 2v11",key:"svg-1"}],["path",{d:"M3 21h18",key:"svg-2"}],["path",{d:"M10 12v0",key:"svg-3"}],["path",{d:"M10 16v0",key:"svg-4"}],["path",{d:"M10 8v0",key:"svg-5"}],["path",{d:"M7 12v0",key:"svg-6"}],["path",{d:"M7 16v0",key:"svg-7"}],["path",{d:"M7 8v0",key:"svg-8"}],["path",{d:"M17 12v0",key:"svg-9"}],["path",{d:"M17 16v0",key:"svg-10"}]]);/**
|
|
88
|
+
* @license @tabler/icons-vue v3.22.0 - MIT
|
|
89
|
+
*
|
|
90
|
+
* This source code is licensed under the MIT license.
|
|
91
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
92
|
+
*/var CF=zs("outline","universe","IconUniverse",[["path",{d:"M7.027 11.477a5 5 0 1 0 5.496 -4.45a4.951 4.951 0 0 0 -3.088 .681",key:"svg-0"}],["path",{d:"M5.636 5.636a9 9 0 1 0 3.555 -2.188",key:"svg-1"}],["path",{d:"M18 5m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0",key:"svg-2"}],["path",{d:"M12 12m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0",key:"svg-3"}],["path",{d:"M9 16m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0",key:"svg-4"}]]);/**
|
|
93
|
+
* @license @tabler/icons-vue v3.22.0 - MIT
|
|
94
|
+
*
|
|
95
|
+
* This source code is licensed under the MIT license.
|
|
96
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
97
|
+
*/var EF=zs("outline","user","IconUser",[["path",{d:"M8 7a4 4 0 1 0 8 0a4 4 0 0 0 -8 0",key:"svg-0"}],["path",{d:"M6 21v-2a4 4 0 0 1 4 -4h4a4 4 0 0 1 4 4v2",key:"svg-1"}]]);/**
|
|
98
|
+
* @license @tabler/icons-vue v3.22.0 - MIT
|
|
99
|
+
*
|
|
100
|
+
* This source code is licensed under the MIT license.
|
|
101
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
102
|
+
*/var wF=zs("outline","users","IconUsers",[["path",{d:"M9 7m-4 0a4 4 0 1 0 8 0a4 4 0 1 0 -8 0",key:"svg-0"}],["path",{d:"M3 21v-2a4 4 0 0 1 4 -4h4a4 4 0 0 1 4 4v2",key:"svg-1"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"svg-2"}],["path",{d:"M21 21v-2a4 4 0 0 0 -3 -3.85",key:"svg-3"}]]);/**
|
|
103
|
+
* @license @tabler/icons-vue v3.22.0 - MIT
|
|
104
|
+
*
|
|
105
|
+
* This source code is licensed under the MIT license.
|
|
106
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
107
|
+
*/var TF=zs("filled","caret-right-filled","IconCaretRightFilled",[["path",{d:"M9 6c0 -.852 .986 -1.297 1.623 -.783l.084 .076l6 6a1 1 0 0 1 .083 1.32l-.083 .094l-6 6l-.094 .083l-.077 .054l-.096 .054l-.036 .017l-.067 .027l-.108 .032l-.053 .01l-.06 .01l-.057 .004l-.059 .002l-.059 -.002l-.058 -.005l-.06 -.009l-.052 -.01l-.108 -.032l-.067 -.027l-.132 -.07l-.09 -.065l-.081 -.073l-.083 -.094l-.054 -.077l-.054 -.096l-.017 -.036l-.027 -.067l-.032 -.108l-.01 -.053l-.01 -.06l-.004 -.057l-.002 -12.059z",key:"svg-0"}]]);/*! @azure/msal-common v14.16.0 2024-11-05 */const $={LIBRARY_NAME:"MSAL.JS",SKU:"msal.js.common",CACHE_PREFIX:"msal",DEFAULT_AUTHORITY:"https://login.microsoftonline.com/common/",DEFAULT_AUTHORITY_HOST:"login.microsoftonline.com",DEFAULT_COMMON_TENANT:"common",ADFS:"adfs",DSTS:"dstsv2",AAD_INSTANCE_DISCOVERY_ENDPT:"https://login.microsoftonline.com/common/discovery/instance?api-version=1.1&authorization_endpoint=",CIAM_AUTH_URL:".ciamlogin.com",AAD_TENANT_DOMAIN_SUFFIX:".onmicrosoft.com",RESOURCE_DELIM:"|",NO_ACCOUNT:"NO_ACCOUNT",CLAIMS:"claims",CONSUMER_UTID:"9188040d-6c67-4c5b-b112-36a304b66dad",OPENID_SCOPE:"openid",PROFILE_SCOPE:"profile",OFFLINE_ACCESS_SCOPE:"offline_access",EMAIL_SCOPE:"email",CODE_RESPONSE_TYPE:"code",CODE_GRANT_TYPE:"authorization_code",RT_GRANT_TYPE:"refresh_token",FRAGMENT_RESPONSE_MODE:"fragment",S256_CODE_CHALLENGE_METHOD:"S256",URL_FORM_CONTENT_TYPE:"application/x-www-form-urlencoded;charset=utf-8",AUTHORIZATION_PENDING:"authorization_pending",NOT_DEFINED:"not_defined",EMPTY_STRING:"",NOT_APPLICABLE:"N/A",NOT_AVAILABLE:"Not Available",FORWARD_SLASH:"/",IMDS_ENDPOINT:"http://169.254.169.254/metadata/instance/compute/location",IMDS_VERSION:"2020-06-01",IMDS_TIMEOUT:2e3,AZURE_REGION_AUTO_DISCOVER_FLAG:"TryAutoDetect",REGIONAL_AUTH_PUBLIC_CLOUD_SUFFIX:"login.microsoft.com",KNOWN_PUBLIC_CLOUDS:["login.microsoftonline.com","login.windows.net","login.microsoft.com","sts.windows.net"],TOKEN_RESPONSE_TYPE:"token",ID_TOKEN_RESPONSE_TYPE:"id_token",SHR_NONCE_VALIDITY:240,INVALID_INSTANCE:"invalid_instance"},Gc={CLIENT_ERROR_RANGE_START:400,CLIENT_ERROR_RANGE_END:499,SERVER_ERROR_RANGE_START:500,SERVER_ERROR_RANGE_END:599},Ua=[$.OPENID_SCOPE,$.PROFILE_SCOPE,$.OFFLINE_ACCESS_SCOPE],V_=[...Ua,$.EMAIL_SCOPE],hn={CONTENT_TYPE:"Content-Type",CONTENT_LENGTH:"Content-Length",RETRY_AFTER:"Retry-After",CCS_HEADER:"X-AnchorMailbox",WWWAuthenticate:"WWW-Authenticate",AuthenticationInfo:"Authentication-Info",X_MS_REQUEST_ID:"x-ms-request-id",X_MS_HTTP_VERSION:"x-ms-httpver"},xt={ID_TOKEN:"idtoken",CLIENT_INFO:"client.info",ADAL_ID_TOKEN:"adal.idtoken",ERROR:"error",ERROR_DESC:"error.description",ACTIVE_ACCOUNT:"active-account",ACTIVE_ACCOUNT_FILTERS:"active-account-filters"},Wo={COMMON:"common",ORGANIZATIONS:"organizations",CONSUMERS:"consumers"},qc={ACCESS_TOKEN:"access_token",XMS_CC:"xms_cc"},Bt={LOGIN:"login",SELECT_ACCOUNT:"select_account",CONSENT:"consent",NONE:"none",CREATE:"create",NO_SESSION:"no_session"},B_={PLAIN:"plain",S256:"S256"},Gs={QUERY:"query",FRAGMENT:"fragment"},bF={...Gs},rw={AUTHORIZATION_CODE_GRANT:"authorization_code",REFRESH_TOKEN_GRANT:"refresh_token"},jc={MSSTS_ACCOUNT_TYPE:"MSSTS",ADFS_ACCOUNT_TYPE:"ADFS",GENERIC_ACCOUNT_TYPE:"Generic"},tn={CACHE_KEY_SEPARATOR:"-",CLIENT_INFO_SEPARATOR:"."},pe={ID_TOKEN:"IdToken",ACCESS_TOKEN:"AccessToken",ACCESS_TOKEN_WITH_AUTH_SCHEME:"AccessToken_With_AuthScheme",REFRESH_TOKEN:"RefreshToken"},$f="appmetadata",SF="client_info",ws="1",Nl={CACHE_KEY:"authority-metadata",REFRESH_TIME_SECONDS:3600*24},Pn={CONFIG:"config",CACHE:"cache",NETWORK:"network",HARDCODED_VALUES:"hardcoded_values"},zt={SCHEMA_VERSION:5,MAX_LAST_HEADER_BYTES:330,MAX_CACHED_ERRORS:50,CACHE_KEY:"server-telemetry",CATEGORY_SEPARATOR:"|",VALUE_SEPARATOR:",",OVERFLOW_TRUE:"1",OVERFLOW_FALSE:"0",UNKNOWN_ERROR:"unknown_error"},je={BEARER:"Bearer",POP:"pop",SSH:"ssh-cert"},Ts={DEFAULT_THROTTLE_TIME_SECONDS:60,DEFAULT_MAX_THROTTLE_TIME_SECONDS:3600,THROTTLING_PREFIX:"throttling",X_MS_LIB_CAPABILITY_VALUE:"retry-after, h429"},F_={INVALID_GRANT_ERROR:"invalid_grant",CLIENT_MISMATCH_ERROR:"client_mismatch"},$_={username:"username",password:"password"},Yc={httpSuccess:200,httpBadRequest:400},ea={FAILED_AUTO_DETECTION:"1",INTERNAL_CACHE:"2",ENVIRONMENT_VARIABLE:"3",IMDS:"4"},ih={CONFIGURED_NO_AUTO_DETECTION:"2",AUTO_DETECTION_REQUESTED_SUCCESSFUL:"4",AUTO_DETECTION_REQUESTED_FAILED:"5"},xo={NOT_APPLICABLE:"0",FORCE_REFRESH_OR_CLAIMS:"1",NO_CACHED_ACCESS_TOKEN:"2",CACHED_ACCESS_TOKEN_EXPIRED:"3",PROACTIVELY_REFRESHED:"4"},IF={Pop:"pop"},AF=300;/*! @azure/msal-common v14.16.0 2024-11-05 */const Hf="unexpected_error",kF="post_request_failed";/*! @azure/msal-common v14.16.0 2024-11-05 */const H_={[Hf]:"Unexpected error in authentication.",[kF]:"Post request failed from the network, could be a 4xx/5xx or a network unavailability. Please check the exact error code for details."};class lt extends Error{constructor(e,t,r){const o=t?`${e}: ${t}`:e;super(o),Object.setPrototypeOf(this,lt.prototype),this.errorCode=e||$.EMPTY_STRING,this.errorMessage=t||$.EMPTY_STRING,this.subError=r||$.EMPTY_STRING,this.name="AuthError"}setCorrelationId(e){this.correlationId=e}}function ow(n,e){return new lt(n,e?`${H_[n]} ${e}`:H_[n])}/*! @azure/msal-common v14.16.0 2024-11-05 */const Kf="client_info_decoding_error",iw="client_info_empty_error",Wf="token_parsing_error",aw="null_or_empty_token",so="endpoints_resolution_error",sw="network_error",cw="openid_config_error",lw="hash_not_deserialized",Aa="invalid_state",uw="state_mismatch",Ol="state_not_found",dw="nonce_mismatch",zf="auth_time_not_found",hw="max_age_transpired",NF="multiple_matching_tokens",OF="multiple_matching_accounts",fw="multiple_matching_appMetadata",mw="request_cannot_be_made",gw="cannot_remove_empty_scope",pw="cannot_append_scopeset",jh="empty_input_scopeset",RF="device_code_polling_cancelled",PF="device_code_expired",MF="device_code_unknown_error",Gf="no_account_in_silent_request",vw="invalid_cache_record",qf="invalid_cache_environment",Yh="no_account_found",Jh="no_crypto_object",Qh="unexpected_credential_type",DF="invalid_assertion",LF="invalid_client_credential",lo="token_refresh_required",xF="user_timeout_reached",_w="token_claims_cnf_required_for_signedjwt",yw="authorization_code_missing_from_server_response",Cw="binding_key_not_removed",Ew="end_session_endpoint_not_supported",jf="key_id_missing",UF="no_network_connectivity",VF="user_canceled",BF="missing_tenant_id_error",Ae="method_not_implemented",FF="nested_app_auth_bridge_disabled";/*! @azure/msal-common v14.16.0 2024-11-05 */const K_={[Kf]:"The client info could not be parsed/decoded correctly",[iw]:"The client info was empty",[Wf]:"Token cannot be parsed",[aw]:"The token is null or empty",[so]:"Endpoints cannot be resolved",[sw]:"Network request failed",[cw]:"Could not retrieve endpoints. Check your authority and verify the .well-known/openid-configuration endpoint returns the required endpoints.",[lw]:"The hash parameters could not be deserialized",[Aa]:"State was not the expected format",[uw]:"State mismatch error",[Ol]:"State not found",[dw]:"Nonce mismatch error",[zf]:"Max Age was requested and the ID token is missing the auth_time variable. auth_time is an optional claim and is not enabled by default - it must be enabled. See https://aka.ms/msaljs/optional-claims for more information.",[hw]:"Max Age is set to 0, or too much time has elapsed since the last end-user authentication.",[NF]:"The cache contains multiple tokens satisfying the requirements. Call AcquireToken again providing more requirements such as authority or account.",[OF]:"The cache contains multiple accounts satisfying the given parameters. Please pass more info to obtain the correct account",[fw]:"The cache contains multiple appMetadata satisfying the given parameters. Please pass more info to obtain the correct appMetadata",[mw]:"Token request cannot be made without authorization code or refresh token.",[gw]:"Cannot remove null or empty scope from ScopeSet",[pw]:"Cannot append ScopeSet",[jh]:"Empty input ScopeSet cannot be processed",[RF]:"Caller has cancelled token endpoint polling during device code flow by setting DeviceCodeRequest.cancel = true.",[PF]:"Device code is expired.",[MF]:"Device code stopped polling for unknown reasons.",[Gf]:"Please pass an account object, silent flow is not supported without account information",[vw]:"Cache record object was null or undefined.",[qf]:"Invalid environment when attempting to create cache entry",[Yh]:"No account found in cache for given key.",[Jh]:"No crypto object detected.",[Qh]:"Unexpected credential type.",[DF]:"Client assertion must meet requirements described in https://tools.ietf.org/html/rfc7515",[LF]:"Client credential (secret, certificate, or assertion) must not be empty when creating a confidential client. An application should at most have one credential",[lo]:"Cannot return token from cache because it must be refreshed. This may be due to one of the following reasons: forceRefresh parameter is set to true, claims have been requested, there is no cached access token or it is expired.",[xF]:"User defined timeout for device code polling reached",[_w]:"Cannot generate a POP jwt if the token_claims are not populated",[yw]:"Server response does not contain an authorization code to proceed",[Cw]:"Could not remove the credential's binding key from storage.",[Ew]:"The provided authority does not support logout",[jf]:"A keyId value is missing from the requested bound token's cache record and is required to match the token to it's stored binding key.",[UF]:"No network connectivity. Check your internet connection.",[VF]:"User cancelled the flow.",[BF]:"A tenant id - not common, organizations, or consumers - must be specified when using the client_credentials flow.",[Ae]:"This method has not been implemented",[FF]:"The nested app auth bridge is disabled"};class su extends lt{constructor(e,t){super(e,t?`${K_[e]}: ${t}`:K_[e]),this.name="ClientAuthError",Object.setPrototypeOf(this,su.prototype)}}function Y(n,e){return new su(n,e)}/*! @azure/msal-common v14.16.0 2024-11-05 */const Rl={createNewGuid:()=>{throw Y(Ae)},base64Decode:()=>{throw Y(Ae)},base64Encode:()=>{throw Y(Ae)},base64UrlEncode:()=>{throw Y(Ae)},encodeKid:()=>{throw Y(Ae)},async getPublicKeyThumbprint(){throw Y(Ae)},async removeTokenBindingKey(){throw Y(Ae)},async clearKeystore(){throw Y(Ae)},async signJwt(){throw Y(Ae)},async hashString(){throw Y(Ae)}};/*! @azure/msal-common v14.16.0 2024-11-05 */var nt;(function(n){n[n.Error=0]="Error",n[n.Warning=1]="Warning",n[n.Info=2]="Info",n[n.Verbose=3]="Verbose",n[n.Trace=4]="Trace"})(nt||(nt={}));class Go{constructor(e,t,r){this.level=nt.Info;const o=()=>{},a=e||Go.createDefaultLoggerOptions();this.localCallback=a.loggerCallback||o,this.piiLoggingEnabled=a.piiLoggingEnabled||!1,this.level=typeof a.logLevel=="number"?a.logLevel:nt.Info,this.correlationId=a.correlationId||$.EMPTY_STRING,this.packageName=t||$.EMPTY_STRING,this.packageVersion=r||$.EMPTY_STRING}static createDefaultLoggerOptions(){return{loggerCallback:()=>{},piiLoggingEnabled:!1,logLevel:nt.Info}}clone(e,t,r){return new Go({loggerCallback:this.localCallback,piiLoggingEnabled:this.piiLoggingEnabled,logLevel:this.level,correlationId:r||this.correlationId},e,t)}logMessage(e,t){if(t.logLevel>this.level||!this.piiLoggingEnabled&&t.containsPii)return;const a=`${`[${new Date().toUTCString()}] : [${t.correlationId||this.correlationId||""}]`} : ${this.packageName}@${this.packageVersion} : ${nt[t.logLevel]} - ${e}`;this.executeCallback(t.logLevel,a,t.containsPii||!1)}executeCallback(e,t,r){this.localCallback&&this.localCallback(e,t,r)}error(e,t){this.logMessage(e,{logLevel:nt.Error,containsPii:!1,correlationId:t||$.EMPTY_STRING})}errorPii(e,t){this.logMessage(e,{logLevel:nt.Error,containsPii:!0,correlationId:t||$.EMPTY_STRING})}warning(e,t){this.logMessage(e,{logLevel:nt.Warning,containsPii:!1,correlationId:t||$.EMPTY_STRING})}warningPii(e,t){this.logMessage(e,{logLevel:nt.Warning,containsPii:!0,correlationId:t||$.EMPTY_STRING})}info(e,t){this.logMessage(e,{logLevel:nt.Info,containsPii:!1,correlationId:t||$.EMPTY_STRING})}infoPii(e,t){this.logMessage(e,{logLevel:nt.Info,containsPii:!0,correlationId:t||$.EMPTY_STRING})}verbose(e,t){this.logMessage(e,{logLevel:nt.Verbose,containsPii:!1,correlationId:t||$.EMPTY_STRING})}verbosePii(e,t){this.logMessage(e,{logLevel:nt.Verbose,containsPii:!0,correlationId:t||$.EMPTY_STRING})}trace(e,t){this.logMessage(e,{logLevel:nt.Trace,containsPii:!1,correlationId:t||$.EMPTY_STRING})}tracePii(e,t){this.logMessage(e,{logLevel:nt.Trace,containsPii:!0,correlationId:t||$.EMPTY_STRING})}isPiiLoggingEnabled(){return this.piiLoggingEnabled||!1}}/*! @azure/msal-common v14.16.0 2024-11-05 */const ww="@azure/msal-common",Yf="14.16.0";/*! @azure/msal-common v14.16.0 2024-11-05 */const Jf={None:"none"};/*! @azure/msal-common v14.16.0 2024-11-05 */function Ri(n,e){const t=$F(n);try{const r=e(t);return JSON.parse(r)}catch{throw Y(Wf)}}function $F(n){if(!n)throw Y(aw);const t=/^([^\.\s]*)\.([^\.\s]+)\.([^\.\s]*)$/.exec(n);if(!t||t.length<4)throw Y(Wf);return t[2]}function Tw(n,e){if(e===0||Date.now()-3e5>n+e)throw Y(hw)}/*! @azure/msal-common v14.16.0 2024-11-05 */function Gr(){return Math.round(new Date().getTime()/1e3)}function Xh(n,e){const t=Number(n)||0;return Gr()+e>t}function HF(n){return Number(n)>Gr()}/*! @azure/msal-common v14.16.0 2024-11-05 */function va(n){return[KF(n),WF(n),zF(n),GF(n),qF(n)].join(tn.CACHE_KEY_SEPARATOR).toLowerCase()}function cu(n,e,t,r,o){return{credentialType:pe.ID_TOKEN,homeAccountId:n,environment:e,clientId:r,secret:t,realm:o}}function lu(n,e,t,r,o,a,l,d,h,f,g,v,p,w,C){var S,I;const T={homeAccountId:n,credentialType:pe.ACCESS_TOKEN,secret:t,cachedAt:Gr().toString(),expiresOn:l.toString(),extendedExpiresOn:d.toString(),environment:e,clientId:r,realm:o,target:a,tokenType:g||je.BEARER};if(v&&(T.userAssertionHash=v),f&&(T.refreshOn=f.toString()),w&&(T.requestedClaims=w,T.requestedClaimsHash=C),((S=T.tokenType)==null?void 0:S.toLowerCase())!==je.BEARER.toLowerCase())switch(T.credentialType=pe.ACCESS_TOKEN_WITH_AUTH_SCHEME,T.tokenType){case je.POP:const N=Ri(t,h);if(!((I=N==null?void 0:N.cnf)!=null&&I.kid))throw Y(_w);T.keyId=N.cnf.kid;break;case je.SSH:T.keyId=p}return T}function bw(n,e,t,r,o,a,l){const d={credentialType:pe.REFRESH_TOKEN,homeAccountId:n,environment:e,clientId:r,secret:t};return a&&(d.userAssertionHash=a),o&&(d.familyId=o),l&&(d.expiresOn=l.toString()),d}function Qf(n){return n.hasOwnProperty("homeAccountId")&&n.hasOwnProperty("environment")&&n.hasOwnProperty("credentialType")&&n.hasOwnProperty("clientId")&&n.hasOwnProperty("secret")}function W_(n){return n?Qf(n)&&n.hasOwnProperty("realm")&&n.hasOwnProperty("target")&&(n.credentialType===pe.ACCESS_TOKEN||n.credentialType===pe.ACCESS_TOKEN_WITH_AUTH_SCHEME):!1}function z_(n){return n?Qf(n)&&n.hasOwnProperty("realm")&&n.credentialType===pe.ID_TOKEN:!1}function G_(n){return n?Qf(n)&&n.credentialType===pe.REFRESH_TOKEN:!1}function KF(n){return[n.homeAccountId,n.environment].join(tn.CACHE_KEY_SEPARATOR).toLowerCase()}function WF(n){const e=n.credentialType===pe.REFRESH_TOKEN&&n.familyId||n.clientId;return[n.credentialType,e,n.realm||""].join(tn.CACHE_KEY_SEPARATOR).toLowerCase()}function zF(n){return(n.target||"").toLowerCase()}function GF(n){return(n.requestedClaimsHash||"").toLowerCase()}function qF(n){return n.tokenType&&n.tokenType.toLowerCase()!==je.BEARER.toLowerCase()?n.tokenType.toLowerCase():""}function jF(n,e){const t=n.indexOf(zt.CACHE_KEY)===0;let r=!0;return e&&(r=e.hasOwnProperty("failedRequests")&&e.hasOwnProperty("errors")&&e.hasOwnProperty("cacheHits")),t&&r}function YF(n,e){let t=!1;n&&(t=n.indexOf(Ts.THROTTLING_PREFIX)===0);let r=!0;return e&&(r=e.hasOwnProperty("throttleTime")),t&&r}function JF({environment:n,clientId:e}){return[$f,n,e].join(tn.CACHE_KEY_SEPARATOR).toLowerCase()}function QF(n,e){return e?n.indexOf($f)===0&&e.hasOwnProperty("clientId")&&e.hasOwnProperty("environment"):!1}function XF(n,e){return e?n.indexOf(Nl.CACHE_KEY)===0&&e.hasOwnProperty("aliases")&&e.hasOwnProperty("preferred_cache")&&e.hasOwnProperty("preferred_network")&&e.hasOwnProperty("canonical_authority")&&e.hasOwnProperty("authorization_endpoint")&&e.hasOwnProperty("token_endpoint")&&e.hasOwnProperty("issuer")&&e.hasOwnProperty("aliasesFromNetwork")&&e.hasOwnProperty("endpointsFromNetwork")&&e.hasOwnProperty("expiresAt")&&e.hasOwnProperty("jwks_uri"):!1}function q_(){return Gr()+Nl.REFRESH_TIME_SECONDS}function Jc(n,e,t){n.authorization_endpoint=e.authorization_endpoint,n.token_endpoint=e.token_endpoint,n.end_session_endpoint=e.end_session_endpoint,n.issuer=e.issuer,n.endpointsFromNetwork=t,n.jwks_uri=e.jwks_uri}function ah(n,e,t){n.aliases=e.aliases,n.preferred_cache=e.preferred_cache,n.preferred_network=e.preferred_network,n.aliasesFromNetwork=t}function j_(n){return n.expiresAt<=Gr()}/*! @azure/msal-common v14.16.0 2024-11-05 */const Sw="redirect_uri_empty",ZF="claims_request_parsing_error",Iw="authority_uri_insecure",gs="url_parse_error",Aw="empty_url_error",kw="empty_input_scopes_error",Nw="invalid_prompt_value",Xf="invalid_claims",Ow="token_request_empty",Rw="logout_request_empty",Pw="invalid_code_challenge_method",Zf="pkce_params_missing",em="invalid_cloud_discovery_metadata",Mw="invalid_authority_metadata",Dw="untrusted_authority",uu="missing_ssh_jwk",Lw="missing_ssh_kid",e2="missing_nonce_authentication_header",t2="invalid_authentication_header",xw="cannot_set_OIDCOptions",Uw="cannot_allow_native_broker",Vw="authority_mismatch";/*! @azure/msal-common v14.16.0 2024-11-05 */const n2={[Sw]:"A redirect URI is required for all calls, and none has been set.",[ZF]:"Could not parse the given claims request object.",[Iw]:"Authority URIs must use https. Please see here for valid authority configuration options: https://docs.microsoft.com/en-us/azure/active-directory/develop/msal-js-initializing-client-applications#configuration-options",[gs]:"URL could not be parsed into appropriate segments.",[Aw]:"URL was empty or null.",[kw]:"Scopes cannot be passed as null, undefined or empty array because they are required to obtain an access token.",[Nw]:"Please see here for valid configuration options: https://azuread.github.io/microsoft-authentication-library-for-js/ref/modules/_azure_msal_common.html#commonauthorizationurlrequest",[Xf]:"Given claims parameter must be a stringified JSON object.",[Ow]:"Token request was empty and not found in cache.",[Rw]:"The logout request was null or undefined.",[Pw]:'code_challenge_method passed is invalid. Valid values are "plain" and "S256".',[Zf]:"Both params: code_challenge and code_challenge_method are to be passed if to be sent in the request",[em]:"Invalid cloudDiscoveryMetadata provided. Must be a stringified JSON object containing tenant_discovery_endpoint and metadata fields",[Mw]:"Invalid authorityMetadata provided. Must by a stringified JSON object containing authorization_endpoint, token_endpoint, issuer fields.",[Dw]:"The provided authority is not a trusted authority. Please include this authority in the knownAuthorities config parameter.",[uu]:"Missing sshJwk in SSH certificate request. A stringified JSON Web Key is required when using the SSH authentication scheme.",[Lw]:"Missing sshKid in SSH certificate request. A string that uniquely identifies the public SSH key is required when using the SSH authentication scheme.",[e2]:"Unable to find an authentication header containing server nonce. Either the Authentication-Info or WWW-Authenticate headers must be present in order to obtain a server nonce.",[t2]:"Invalid authentication header provided",[xw]:"Cannot set OIDCOptions parameter. Please change the protocol mode to OIDC or use a non-Microsoft authority.",[Uw]:"Cannot set allowNativeBroker parameter to true when not in AAD protocol mode.",[Vw]:"Authority mismatch error. Authority provided in login request or PublicClientApplication config does not match the environment of the provided account. Please use a matching account or make an interactive request to login to this authority."};class tm extends lt{constructor(e){super(e,n2[e]),this.name="ClientConfigurationError",Object.setPrototypeOf(this,tm.prototype)}}function Ze(n){return new tm(n)}/*! @azure/msal-common v14.16.0 2024-11-05 */class Er{static isEmptyObj(e){if(e)try{const t=JSON.parse(e);return Object.keys(t).length===0}catch{}return!0}static startsWith(e,t){return e.indexOf(t)===0}static endsWith(e,t){return e.length>=t.length&&e.lastIndexOf(t)===e.length-t.length}static queryStringToObject(e){const t={},r=e.split("&"),o=a=>decodeURIComponent(a.replace(/\+/g," "));return r.forEach(a=>{if(a.trim()){const[l,d]=a.split(/=(.+)/g,2);l&&d&&(t[o(l)]=o(d))}}),t}static trimArrayEntries(e){return e.map(t=>t.trim())}static removeEmptyStringsFromArray(e){return e.filter(t=>!!t)}static jsonParseHelper(e){try{return JSON.parse(e)}catch{return null}}static matchPattern(e,t){return new RegExp(e.replace(/\\/g,"\\\\").replace(/\*/g,"[^ ]*").replace(/\?/g,"\\?")).test(t)}}/*! @azure/msal-common v14.16.0 2024-11-05 */class _t{constructor(e){const t=e?Er.trimArrayEntries([...e]):[],r=t?Er.removeEmptyStringsFromArray(t):[];this.validateInputScopes(r),this.scopes=new Set,r.forEach(o=>this.scopes.add(o))}static fromString(e){const r=(e||$.EMPTY_STRING).split(" ");return new _t(r)}static createSearchScopes(e){const t=new _t(e);return t.containsOnlyOIDCScopes()?t.removeScope($.OFFLINE_ACCESS_SCOPE):t.removeOIDCScopes(),t}validateInputScopes(e){if(!e||e.length<1)throw Ze(kw)}containsScope(e){const t=this.printScopesLowerCase().split(" "),r=new _t(t);return e?r.scopes.has(e.toLowerCase()):!1}containsScopeSet(e){return!e||e.scopes.size<=0?!1:this.scopes.size>=e.scopes.size&&e.asArray().every(t=>this.containsScope(t))}containsOnlyOIDCScopes(){let e=0;return V_.forEach(t=>{this.containsScope(t)&&(e+=1)}),this.scopes.size===e}appendScope(e){e&&this.scopes.add(e.trim())}appendScopes(e){try{e.forEach(t=>this.appendScope(t))}catch{throw Y(pw)}}removeScope(e){if(!e)throw Y(gw);this.scopes.delete(e.trim())}removeOIDCScopes(){V_.forEach(e=>{this.scopes.delete(e)})}unionScopeSets(e){if(!e)throw Y(jh);const t=new Set;return e.scopes.forEach(r=>t.add(r.toLowerCase())),this.scopes.forEach(r=>t.add(r.toLowerCase())),t}intersectingScopeSets(e){if(!e)throw Y(jh);e.containsOnlyOIDCScopes()||e.removeOIDCScopes();const t=this.unionScopeSets(e),r=e.getScopeCount(),o=this.getScopeCount();return t.size<o+r}getScopeCount(){return this.scopes.size}asArray(){const e=[];return this.scopes.forEach(t=>e.push(t)),e}printScopes(){return this.scopes?this.asArray().join(" "):$.EMPTY_STRING}printScopesLowerCase(){return this.printScopes().toLowerCase()}}/*! @azure/msal-common v14.16.0 2024-11-05 */function Pl(n,e){if(!n)throw Y(iw);try{const t=e(n);return JSON.parse(t)}catch{throw Y(Kf)}}function _a(n){if(!n)throw Y(Kf);const e=n.split(tn.CLIENT_INFO_SEPARATOR,2);return{uid:e[0],utid:e.length<2?$.EMPTY_STRING:e[1]}}/*! @azure/msal-common v14.16.0 2024-11-05 */function Ml(n,e){return!!n&&!!e&&n===e.split(".")[1]}function nm(n,e,t,r){if(r){const{oid:o,sub:a,tid:l,name:d,tfp:h,acr:f}=r,g=l||h||f||"";return{tenantId:g,localAccountId:o||a||"",name:d,isHomeTenant:Ml(g,n)}}else return{tenantId:t,localAccountId:e,isHomeTenant:Ml(t,n)}}function rm(n,e,t,r){let o=n;if(e){const{isHomeTenant:a,...l}=e;o={...n,...l}}if(t){const{isHomeTenant:a,...l}=nm(n.homeAccountId,n.localAccountId,n.tenantId,t);return o={...o,...l,idTokenClaims:t,idToken:r},o}return o}/*! @azure/msal-common v14.16.0 2024-11-05 */const pr={Default:0,Adfs:1,Dsts:2,Ciam:3};/*! @azure/msal-common v14.16.0 2024-11-05 */function Bw(n){return n&&(n.tid||n.tfp||n.acr)||null}/*! @azure/msal-common v14.16.0 2024-11-05 */const po={AAD:"AAD",OIDC:"OIDC"};/*! @azure/msal-common v14.16.0 2024-11-05 */class Mt{generateAccountId(){return[this.homeAccountId,this.environment].join(tn.CACHE_KEY_SEPARATOR).toLowerCase()}generateAccountKey(){return Mt.generateAccountCacheKey({homeAccountId:this.homeAccountId,environment:this.environment,tenantId:this.realm,username:this.username,localAccountId:this.localAccountId})}getAccountInfo(){return{homeAccountId:this.homeAccountId,environment:this.environment,tenantId:this.realm,username:this.username,localAccountId:this.localAccountId,name:this.name,nativeAccountId:this.nativeAccountId,authorityType:this.authorityType,tenantProfiles:new Map((this.tenantProfiles||[]).map(e=>[e.tenantId,e]))}}isSingleTenant(){return!this.tenantProfiles}static generateAccountCacheKey(e){const t=e.homeAccountId.split(".")[1];return[e.homeAccountId,e.environment||"",t||e.tenantId||""].join(tn.CACHE_KEY_SEPARATOR).toLowerCase()}static createAccount(e,t,r){var f,g,v,p,w,C;const o=new Mt;t.authorityType===pr.Adfs?o.authorityType=jc.ADFS_ACCOUNT_TYPE:t.protocolMode===po.AAD?o.authorityType=jc.MSSTS_ACCOUNT_TYPE:o.authorityType=jc.GENERIC_ACCOUNT_TYPE;let a;e.clientInfo&&r&&(a=Pl(e.clientInfo,r)),o.clientInfo=e.clientInfo,o.homeAccountId=e.homeAccountId,o.nativeAccountId=e.nativeAccountId;const l=e.environment||t&&t.getPreferredCache();if(!l)throw Y(qf);o.environment=l,o.realm=(a==null?void 0:a.utid)||Bw(e.idTokenClaims)||"",o.localAccountId=(a==null?void 0:a.uid)||((f=e.idTokenClaims)==null?void 0:f.oid)||((g=e.idTokenClaims)==null?void 0:g.sub)||"";const d=((v=e.idTokenClaims)==null?void 0:v.preferred_username)||((p=e.idTokenClaims)==null?void 0:p.upn),h=(w=e.idTokenClaims)!=null&&w.emails?e.idTokenClaims.emails[0]:null;if(o.username=d||h||"",o.name=((C=e.idTokenClaims)==null?void 0:C.name)||"",o.cloudGraphHostName=e.cloudGraphHostName,o.msGraphHost=e.msGraphHost,e.tenantProfiles)o.tenantProfiles=e.tenantProfiles;else{const T=nm(e.homeAccountId,o.localAccountId,o.realm,e.idTokenClaims);o.tenantProfiles=[T]}return o}static createFromAccountInfo(e,t,r){var a;const o=new Mt;return o.authorityType=e.authorityType||jc.GENERIC_ACCOUNT_TYPE,o.homeAccountId=e.homeAccountId,o.localAccountId=e.localAccountId,o.nativeAccountId=e.nativeAccountId,o.realm=e.tenantId,o.environment=e.environment,o.username=e.username,o.name=e.name,o.cloudGraphHostName=t,o.msGraphHost=r,o.tenantProfiles=Array.from(((a=e.tenantProfiles)==null?void 0:a.values())||[]),o}static generateHomeAccountId(e,t,r,o,a){if(!(t===pr.Adfs||t===pr.Dsts)){if(e)try{const l=Pl(e,o.base64Decode);if(l.uid&&l.utid)return`${l.uid}.${l.utid}`}catch{}r.warning("No client info in response")}return(a==null?void 0:a.sub)||""}static isAccountEntity(e){return e?e.hasOwnProperty("homeAccountId")&&e.hasOwnProperty("environment")&&e.hasOwnProperty("realm")&&e.hasOwnProperty("localAccountId")&&e.hasOwnProperty("username")&&e.hasOwnProperty("authorityType"):!1}static accountInfoIsEqual(e,t,r){if(!e||!t)return!1;let o=!0;if(r){const a=e.idTokenClaims||{},l=t.idTokenClaims||{};o=a.iat===l.iat&&a.nonce===l.nonce}return e.homeAccountId===t.homeAccountId&&e.localAccountId===t.localAccountId&&e.username===t.username&&e.tenantId===t.tenantId&&e.environment===t.environment&&e.nativeAccountId===t.nativeAccountId&&o}}/*! @azure/msal-common v14.16.0 2024-11-05 */function Fw(n){return n.startsWith("#/")?n.substring(2):n.startsWith("#")||n.startsWith("?")?n.substring(1):n}function Dl(n){if(!n||n.indexOf("=")<0)return null;try{const e=Fw(n),t=Object.fromEntries(new URLSearchParams(e));if(t.code||t.error||t.error_description||t.state)return t}catch{throw Y(lw)}return null}/*! @azure/msal-common v14.16.0 2024-11-05 */class Le{get urlString(){return this._urlString}constructor(e){if(this._urlString=e,!this._urlString)throw Ze(Aw);e.includes("#")||(this._urlString=Le.canonicalizeUri(e))}static canonicalizeUri(e){if(e){let t=e.toLowerCase();return Er.endsWith(t,"?")?t=t.slice(0,-1):Er.endsWith(t,"?/")&&(t=t.slice(0,-2)),Er.endsWith(t,"/")||(t+="/"),t}return e}validateAsUri(){let e;try{e=this.getUrlComponents()}catch{throw Ze(gs)}if(!e.HostNameAndPort||!e.PathSegments)throw Ze(gs);if(!e.Protocol||e.Protocol.toLowerCase()!=="https:")throw Ze(Iw)}static appendQueryString(e,t){return t?e.indexOf("?")<0?`${e}?${t}`:`${e}&${t}`:e}static removeHashFromUrl(e){return Le.canonicalizeUri(e.split("#")[0])}replaceTenantPath(e){const t=this.getUrlComponents(),r=t.PathSegments;return e&&r.length!==0&&(r[0]===Wo.COMMON||r[0]===Wo.ORGANIZATIONS)&&(r[0]=e),Le.constructAuthorityUriFromObject(t)}getUrlComponents(){const e=RegExp("^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\\?([^#]*))?(#(.*))?"),t=this.urlString.match(e);if(!t)throw Ze(gs);const r={Protocol:t[1],HostNameAndPort:t[4],AbsolutePath:t[5],QueryString:t[7]};let o=r.AbsolutePath.split("/");return o=o.filter(a=>a&&a.length>0),r.PathSegments=o,r.QueryString&&r.QueryString.endsWith("/")&&(r.QueryString=r.QueryString.substring(0,r.QueryString.length-1)),r}static getDomainFromUrl(e){const t=RegExp("^([^:/?#]+://)?([^/?#]*)"),r=e.match(t);if(!r)throw Ze(gs);return r[2]}static getAbsoluteUrl(e,t){if(e[0]===$.FORWARD_SLASH){const o=new Le(t).getUrlComponents();return o.Protocol+"//"+o.HostNameAndPort+e}return e}static constructAuthorityUriFromObject(e){return new Le(e.Protocol+"//"+e.HostNameAndPort+"/"+e.PathSegments.join("/"))}static hashContainsKnownProperties(e){return!!Dl(e)}}/*! @azure/msal-common v14.16.0 2024-11-05 */const $w={endpointMetadata:{"login.microsoftonline.com":{token_endpoint:"https://login.microsoftonline.com/{tenantid}/oauth2/v2.0/token",jwks_uri:"https://login.microsoftonline.com/{tenantid}/discovery/v2.0/keys",issuer:"https://login.microsoftonline.com/{tenantid}/v2.0",authorization_endpoint:"https://login.microsoftonline.com/{tenantid}/oauth2/v2.0/authorize",end_session_endpoint:"https://login.microsoftonline.com/{tenantid}/oauth2/v2.0/logout"},"login.chinacloudapi.cn":{token_endpoint:"https://login.chinacloudapi.cn/{tenantid}/oauth2/v2.0/token",jwks_uri:"https://login.chinacloudapi.cn/{tenantid}/discovery/v2.0/keys",issuer:"https://login.partner.microsoftonline.cn/{tenantid}/v2.0",authorization_endpoint:"https://login.chinacloudapi.cn/{tenantid}/oauth2/v2.0/authorize",end_session_endpoint:"https://login.chinacloudapi.cn/{tenantid}/oauth2/v2.0/logout"},"login.microsoftonline.us":{token_endpoint:"https://login.microsoftonline.us/{tenantid}/oauth2/v2.0/token",jwks_uri:"https://login.microsoftonline.us/{tenantid}/discovery/v2.0/keys",issuer:"https://login.microsoftonline.us/{tenantid}/v2.0",authorization_endpoint:"https://login.microsoftonline.us/{tenantid}/oauth2/v2.0/authorize",end_session_endpoint:"https://login.microsoftonline.us/{tenantid}/oauth2/v2.0/logout"}},instanceDiscoveryMetadata:{metadata:[{preferred_network:"login.microsoftonline.com",preferred_cache:"login.windows.net",aliases:["login.microsoftonline.com","login.windows.net","login.microsoft.com","sts.windows.net"]},{preferred_network:"login.partner.microsoftonline.cn",preferred_cache:"login.partner.microsoftonline.cn",aliases:["login.partner.microsoftonline.cn","login.chinacloudapi.cn"]},{preferred_network:"login.microsoftonline.de",preferred_cache:"login.microsoftonline.de",aliases:["login.microsoftonline.de"]},{preferred_network:"login.microsoftonline.us",preferred_cache:"login.microsoftonline.us",aliases:["login.microsoftonline.us","login.usgovcloudapi.net"]},{preferred_network:"login-us.microsoftonline.com",preferred_cache:"login-us.microsoftonline.com",aliases:["login-us.microsoftonline.com"]}]}},Y_=$w.endpointMetadata,om=$w.instanceDiscoveryMetadata,Hw=new Set;om.metadata.forEach(n=>{n.aliases.forEach(e=>{Hw.add(e)})});function r2(n,e){var o;let t;const r=n.canonicalAuthority;if(r){const a=new Le(r).getUrlComponents().HostNameAndPort;t=J_(a,(o=n.cloudDiscoveryMetadata)==null?void 0:o.metadata,Pn.CONFIG,e)||J_(a,om.metadata,Pn.HARDCODED_VALUES,e)||n.knownAuthorities}return t||[]}function J_(n,e,t,r){if(r==null||r.trace(`getAliasesFromMetadata called with source: ${t}`),n&&e){const o=Ll(e,n);if(o)return r==null||r.trace(`getAliasesFromMetadata: found cloud discovery metadata in ${t}, returning aliases`),o.aliases;r==null||r.trace(`getAliasesFromMetadata: did not find cloud discovery metadata in ${t}`)}return null}function o2(n){return Ll(om.metadata,n)}function Ll(n,e){for(let t=0;t<n.length;t++){const r=n[t];if(r.aliases.includes(e))return r}return null}/*! @azure/msal-common v14.16.0 2024-11-05 */const Kw="cache_quota_exceeded",im="cache_error_unknown";/*! @azure/msal-common v14.16.0 2024-11-05 */const sh={[Kw]:"Exceeded cache storage capacity.",[im]:"Unexpected error occurred when using cache storage."};class Ea extends Error{constructor(e,t){const r=t||(sh[e]?sh[e]:sh[im]);super(`${e}: ${r}`),Object.setPrototypeOf(this,Ea.prototype),this.name="CacheError",this.errorCode=e,this.errorMessage=r}}/*! @azure/msal-common v14.16.0 2024-11-05 */class ka{constructor(e,t,r,o){this.clientId=e,this.cryptoImpl=t,this.commonLogger=r.clone(ww,Yf),this.staticAuthorityOptions=o}getAllAccounts(e){return this.buildTenantProfiles(this.getAccountsFilteredBy(e||{}),e)}getAccountInfoFilteredBy(e){const t=this.getAllAccounts(e);return t.length>1?t.sort(o=>o.idTokenClaims?-1:1)[0]:t.length===1?t[0]:null}getBaseAccountInfo(e){const t=this.getAccountsFilteredBy(e);return t.length>0?t[0].getAccountInfo():null}buildTenantProfiles(e,t){return e.flatMap(r=>this.getTenantProfilesFromAccountEntity(r,t==null?void 0:t.tenantId,t))}getTenantedAccountInfoByFilter(e,t,r,o){let a=null,l;if(o&&!this.tenantProfileMatchesFilter(r,o))return null;const d=this.getIdToken(e,t,r.tenantId);return d&&(l=Ri(d.secret,this.cryptoImpl.base64Decode),!this.idTokenClaimsMatchTenantProfileFilter(l,o))?null:(a=rm(e,r,l,d==null?void 0:d.secret),a)}getTenantProfilesFromAccountEntity(e,t,r){const o=e.getAccountInfo();let a=o.tenantProfiles||new Map;const l=this.getTokenKeys();if(t){const h=a.get(t);if(h)a=new Map([[t,h]]);else return[]}const d=[];return a.forEach(h=>{const f=this.getTenantedAccountInfoByFilter(o,l,h,r);f&&d.push(f)}),d}tenantProfileMatchesFilter(e,t){return!(t.localAccountId&&!this.matchLocalAccountIdFromTenantProfile(e,t.localAccountId)||t.name&&e.name!==t.name||t.isHomeTenant!==void 0&&e.isHomeTenant!==t.isHomeTenant)}idTokenClaimsMatchTenantProfileFilter(e,t){return!(t&&(t.localAccountId&&!this.matchLocalAccountIdFromTokenClaims(e,t.localAccountId)||t.loginHint&&!this.matchLoginHintFromTokenClaims(e,t.loginHint)||t.username&&!this.matchUsername(e.preferred_username,t.username)||t.name&&!this.matchName(e,t.name)||t.sid&&!this.matchSid(e,t.sid)))}async saveCacheRecord(e,t,r){var o,a,l,d;if(!e)throw Y(vw);try{e.account&&this.setAccount(e.account),e.idToken&&(t==null?void 0:t.idToken)!==!1&&this.setIdTokenCredential(e.idToken),e.accessToken&&(t==null?void 0:t.accessToken)!==!1&&await this.saveAccessToken(e.accessToken),e.refreshToken&&(t==null?void 0:t.refreshToken)!==!1&&this.setRefreshTokenCredential(e.refreshToken),e.appMetadata&&this.setAppMetadata(e.appMetadata)}catch(h){throw(o=this.commonLogger)==null||o.error("CacheManager.saveCacheRecord: failed"),h instanceof Error?((a=this.commonLogger)==null||a.errorPii(`CacheManager.saveCacheRecord: ${h.message}`,r),h.name==="QuotaExceededError"||h.name==="NS_ERROR_DOM_QUOTA_REACHED"||h.message.includes("exceeded the quota")?((l=this.commonLogger)==null||l.error("CacheManager.saveCacheRecord: exceeded storage quota",r),new Ea(Kw)):new Ea(h.name,h.message)):((d=this.commonLogger)==null||d.errorPii(`CacheManager.saveCacheRecord: ${h}`,r),new Ea(im))}}async saveAccessToken(e){const t={clientId:e.clientId,credentialType:e.credentialType,environment:e.environment,homeAccountId:e.homeAccountId,realm:e.realm,tokenType:e.tokenType,requestedClaimsHash:e.requestedClaimsHash},r=this.getTokenKeys(),o=_t.fromString(e.target),a=[];r.accessToken.forEach(l=>{if(!this.accessTokenKeyMatchesFilter(l,t,!1))return;const d=this.getAccessTokenCredential(l);d&&this.credentialMatchesFilter(d,t)&&_t.fromString(d.target).intersectingScopeSets(o)&&a.push(this.removeAccessToken(l))}),await Promise.all(a),this.setAccessTokenCredential(e)}getAccountsFilteredBy(e){const t=this.getAccountKeys(),r=[];return t.forEach(o=>{var h;if(!this.isAccountKey(o,e.homeAccountId))return;const a=this.getAccount(o,this.commonLogger);if(!a||e.homeAccountId&&!this.matchHomeAccountId(a,e.homeAccountId)||e.username&&!this.matchUsername(a.username,e.username)||e.environment&&!this.matchEnvironment(a,e.environment)||e.realm&&!this.matchRealm(a,e.realm)||e.nativeAccountId&&!this.matchNativeAccountId(a,e.nativeAccountId)||e.authorityType&&!this.matchAuthorityType(a,e.authorityType))return;const l={localAccountId:e==null?void 0:e.localAccountId,name:e==null?void 0:e.name},d=(h=a.tenantProfiles)==null?void 0:h.filter(f=>this.tenantProfileMatchesFilter(f,l));d&&d.length===0||r.push(a)}),r}isAccountKey(e,t,r){return!(e.split(tn.CACHE_KEY_SEPARATOR).length<3||t&&!e.toLowerCase().includes(t.toLowerCase())||r&&!e.toLowerCase().includes(r.toLowerCase()))}isCredentialKey(e){if(e.split(tn.CACHE_KEY_SEPARATOR).length<6)return!1;const t=e.toLowerCase();if(t.indexOf(pe.ID_TOKEN.toLowerCase())===-1&&t.indexOf(pe.ACCESS_TOKEN.toLowerCase())===-1&&t.indexOf(pe.ACCESS_TOKEN_WITH_AUTH_SCHEME.toLowerCase())===-1&&t.indexOf(pe.REFRESH_TOKEN.toLowerCase())===-1)return!1;if(t.indexOf(pe.REFRESH_TOKEN.toLowerCase())>-1){const r=`${pe.REFRESH_TOKEN}${tn.CACHE_KEY_SEPARATOR}${this.clientId}${tn.CACHE_KEY_SEPARATOR}`,o=`${pe.REFRESH_TOKEN}${tn.CACHE_KEY_SEPARATOR}${ws}${tn.CACHE_KEY_SEPARATOR}`;if(t.indexOf(r.toLowerCase())===-1&&t.indexOf(o.toLowerCase())===-1)return!1}else if(t.indexOf(this.clientId.toLowerCase())===-1)return!1;return!0}credentialMatchesFilter(e,t){return!(t.clientId&&!this.matchClientId(e,t.clientId)||t.userAssertionHash&&!this.matchUserAssertionHash(e,t.userAssertionHash)||typeof t.homeAccountId=="string"&&!this.matchHomeAccountId(e,t.homeAccountId)||t.environment&&!this.matchEnvironment(e,t.environment)||t.realm&&!this.matchRealm(e,t.realm)||t.credentialType&&!this.matchCredentialType(e,t.credentialType)||t.familyId&&!this.matchFamilyId(e,t.familyId)||t.target&&!this.matchTarget(e,t.target)||(t.requestedClaimsHash||e.requestedClaimsHash)&&e.requestedClaimsHash!==t.requestedClaimsHash||e.credentialType===pe.ACCESS_TOKEN_WITH_AUTH_SCHEME&&(t.tokenType&&!this.matchTokenType(e,t.tokenType)||t.tokenType===je.SSH&&t.keyId&&!this.matchKeyId(e,t.keyId)))}getAppMetadataFilteredBy(e){const t=this.getKeys(),r={};return t.forEach(o=>{if(!this.isAppMetadata(o))return;const a=this.getAppMetadata(o);a&&(e.environment&&!this.matchEnvironment(a,e.environment)||e.clientId&&!this.matchClientId(a,e.clientId)||(r[o]=a))}),r}getAuthorityMetadataByAlias(e){const t=this.getAuthorityMetadataKeys();let r=null;return t.forEach(o=>{if(!this.isAuthorityMetadata(o)||o.indexOf(this.clientId)===-1)return;const a=this.getAuthorityMetadata(o);a&&a.aliases.indexOf(e)!==-1&&(r=a)}),r}async removeAllAccounts(){const e=this.getAccountKeys(),t=[];e.forEach(r=>{t.push(this.removeAccount(r))}),await Promise.all(t)}async removeAccount(e){const t=this.getAccount(e,this.commonLogger);t&&(await this.removeAccountContext(t),this.removeItem(e))}async removeAccountContext(e){const t=this.getTokenKeys(),r=e.generateAccountId(),o=[];t.idToken.forEach(a=>{a.indexOf(r)===0&&this.removeIdToken(a)}),t.accessToken.forEach(a=>{a.indexOf(r)===0&&o.push(this.removeAccessToken(a))}),t.refreshToken.forEach(a=>{a.indexOf(r)===0&&this.removeRefreshToken(a)}),await Promise.all(o)}updateOutdatedCachedAccount(e,t,r){var o;if(t&&t.isSingleTenant()){(o=this.commonLogger)==null||o.verbose("updateOutdatedCachedAccount: Found a single-tenant (outdated) account entity in the cache, migrating to multi-tenant account entity");const a=this.getAccountKeys().filter(g=>g.startsWith(t.homeAccountId)),l=[];a.forEach(g=>{const v=this.getCachedAccountEntity(g);v&&l.push(v)});const d=l.find(g=>Ml(g.realm,g.homeAccountId))||l[0];d.tenantProfiles=l.map(g=>({tenantId:g.realm,localAccountId:g.localAccountId,name:g.name,isHomeTenant:Ml(g.realm,g.homeAccountId)}));const h=ka.toObject(new Mt,{...d}),f=h.generateAccountKey();return a.forEach(g=>{g!==f&&this.removeOutdatedAccount(e)}),this.setAccount(h),r==null||r.verbose("Updated an outdated account entity in the cache"),h}return t}async removeAccessToken(e){const t=this.getAccessTokenCredential(e);if(t){if(t.credentialType.toLowerCase()===pe.ACCESS_TOKEN_WITH_AUTH_SCHEME.toLowerCase()&&t.tokenType===je.POP){const o=t.keyId;if(o)try{await this.cryptoImpl.removeTokenBindingKey(o)}catch{throw Y(Cw)}}return this.removeItem(e)}}removeAppMetadata(){return this.getKeys().forEach(t=>{this.isAppMetadata(t)&&this.removeItem(t)}),!0}readAccountFromCache(e){const t=Mt.generateAccountCacheKey(e);return this.getAccount(t,this.commonLogger)}getIdToken(e,t,r,o,a){this.commonLogger.trace("CacheManager - getIdToken called");const l={homeAccountId:e.homeAccountId,environment:e.environment,credentialType:pe.ID_TOKEN,clientId:this.clientId,realm:r},d=this.getIdTokensByFilter(l,t),h=d.size;if(h<1)return this.commonLogger.info("CacheManager:getIdToken - No token found"),null;if(h>1){let f=d;if(!r){const g=new Map;d.forEach((p,w)=>{p.realm===e.tenantId&&g.set(w,p)});const v=g.size;if(v<1)return this.commonLogger.info("CacheManager:getIdToken - Multiple ID tokens found for account but none match account entity tenant id, returning first result"),d.values().next().value;if(v===1)return this.commonLogger.info("CacheManager:getIdToken - Multiple ID tokens found for account, defaulting to home tenant profile"),g.values().next().value;f=g}return this.commonLogger.info("CacheManager:getIdToken - Multiple matching ID tokens found, clearing them"),f.forEach((g,v)=>{this.removeIdToken(v)}),o&&a&&o.addFields({multiMatchedID:d.size},a),null}return this.commonLogger.info("CacheManager:getIdToken - Returning ID token"),d.values().next().value}getIdTokensByFilter(e,t){const r=t&&t.idToken||this.getTokenKeys().idToken,o=new Map;return r.forEach(a=>{if(!this.idTokenKeyMatchesFilter(a,{clientId:this.clientId,...e}))return;const l=this.getIdTokenCredential(a);l&&this.credentialMatchesFilter(l,e)&&o.set(a,l)}),o}idTokenKeyMatchesFilter(e,t){const r=e.toLowerCase();return!(t.clientId&&r.indexOf(t.clientId.toLowerCase())===-1||t.homeAccountId&&r.indexOf(t.homeAccountId.toLowerCase())===-1)}removeIdToken(e){this.removeItem(e)}removeRefreshToken(e){this.removeItem(e)}getAccessToken(e,t,r,o,a,l){this.commonLogger.trace("CacheManager - getAccessToken called");const d=_t.createSearchScopes(t.scopes),h=t.authenticationScheme||je.BEARER,f=h.toLowerCase()!==je.BEARER.toLowerCase()?pe.ACCESS_TOKEN_WITH_AUTH_SCHEME:pe.ACCESS_TOKEN,g={homeAccountId:e.homeAccountId,environment:e.environment,credentialType:f,clientId:this.clientId,realm:o||e.tenantId,target:d,tokenType:h,keyId:t.sshKid,requestedClaimsHash:t.requestedClaimsHash},v=r&&r.accessToken||this.getTokenKeys().accessToken,p=[];v.forEach(C=>{if(this.accessTokenKeyMatchesFilter(C,g,!0)){const T=this.getAccessTokenCredential(C);T&&this.credentialMatchesFilter(T,g)&&p.push(T)}});const w=p.length;return w<1?(this.commonLogger.info("CacheManager:getAccessToken - No token found"),null):w>1?(this.commonLogger.info("CacheManager:getAccessToken - Multiple access tokens found, clearing them"),p.forEach(C=>{this.removeAccessToken(va(C))}),a&&l&&a.addFields({multiMatchedAT:p.length},l),null):(this.commonLogger.info("CacheManager:getAccessToken - Returning access token"),p[0])}accessTokenKeyMatchesFilter(e,t,r){const o=e.toLowerCase();if(t.clientId&&o.indexOf(t.clientId.toLowerCase())===-1||t.homeAccountId&&o.indexOf(t.homeAccountId.toLowerCase())===-1||t.realm&&o.indexOf(t.realm.toLowerCase())===-1||t.requestedClaimsHash&&o.indexOf(t.requestedClaimsHash.toLowerCase())===-1)return!1;if(t.target){const a=t.target.asArray();for(let l=0;l<a.length;l++){if(r&&!o.includes(a[l].toLowerCase()))return!1;if(!r&&o.includes(a[l].toLowerCase()))return!0}}return!0}getAccessTokensByFilter(e){const t=this.getTokenKeys(),r=[];return t.accessToken.forEach(o=>{if(!this.accessTokenKeyMatchesFilter(o,e,!0))return;const a=this.getAccessTokenCredential(o);a&&this.credentialMatchesFilter(a,e)&&r.push(a)}),r}getRefreshToken(e,t,r,o,a){this.commonLogger.trace("CacheManager - getRefreshToken called");const l=t?ws:void 0,d={homeAccountId:e.homeAccountId,environment:e.environment,credentialType:pe.REFRESH_TOKEN,clientId:this.clientId,familyId:l},h=r&&r.refreshToken||this.getTokenKeys().refreshToken,f=[];h.forEach(v=>{if(this.refreshTokenKeyMatchesFilter(v,d)){const p=this.getRefreshTokenCredential(v);p&&this.credentialMatchesFilter(p,d)&&f.push(p)}});const g=f.length;return g<1?(this.commonLogger.info("CacheManager:getRefreshToken - No refresh token found."),null):(g>1&&o&&a&&o.addFields({multiMatchedRT:g},a),this.commonLogger.info("CacheManager:getRefreshToken - returning refresh token"),f[0])}refreshTokenKeyMatchesFilter(e,t){const r=e.toLowerCase();return!(t.familyId&&r.indexOf(t.familyId.toLowerCase())===-1||!t.familyId&&t.clientId&&r.indexOf(t.clientId.toLowerCase())===-1||t.homeAccountId&&r.indexOf(t.homeAccountId.toLowerCase())===-1)}readAppMetadataFromCache(e){const t={environment:e,clientId:this.clientId},r=this.getAppMetadataFilteredBy(t),o=Object.keys(r).map(l=>r[l]),a=o.length;if(a<1)return null;if(a>1)throw Y(fw);return o[0]}isAppMetadataFOCI(e){const t=this.readAppMetadataFromCache(e);return!!(t&&t.familyId===ws)}matchHomeAccountId(e,t){return typeof e.homeAccountId=="string"&&t===e.homeAccountId}matchLocalAccountIdFromTokenClaims(e,t){const r=e.oid||e.sub;return t===r}matchLocalAccountIdFromTenantProfile(e,t){return e.localAccountId===t}matchName(e,t){var r;return t.toLowerCase()===((r=e.name)==null?void 0:r.toLowerCase())}matchUsername(e,t){return!!(e&&typeof e=="string"&&(t==null?void 0:t.toLowerCase())===e.toLowerCase())}matchUserAssertionHash(e,t){return!!(e.userAssertionHash&&t===e.userAssertionHash)}matchEnvironment(e,t){if(this.staticAuthorityOptions){const o=r2(this.staticAuthorityOptions,this.commonLogger);if(o.includes(t)&&o.includes(e.environment))return!0}const r=this.getAuthorityMetadataByAlias(t);return!!(r&&r.aliases.indexOf(e.environment)>-1)}matchCredentialType(e,t){return e.credentialType&&t.toLowerCase()===e.credentialType.toLowerCase()}matchClientId(e,t){return!!(e.clientId&&t===e.clientId)}matchFamilyId(e,t){return!!(e.familyId&&t===e.familyId)}matchRealm(e,t){var r;return((r=e.realm)==null?void 0:r.toLowerCase())===t.toLowerCase()}matchNativeAccountId(e,t){return!!(e.nativeAccountId&&t===e.nativeAccountId)}matchLoginHintFromTokenClaims(e,t){return e.login_hint===t||e.preferred_username===t||e.upn===t}matchSid(e,t){return e.sid===t}matchAuthorityType(e,t){return!!(e.authorityType&&t.toLowerCase()===e.authorityType.toLowerCase())}matchTarget(e,t){return e.credentialType!==pe.ACCESS_TOKEN&&e.credentialType!==pe.ACCESS_TOKEN_WITH_AUTH_SCHEME||!e.target?!1:_t.fromString(e.target).containsScopeSet(t)}matchTokenType(e,t){return!!(e.tokenType&&e.tokenType===t)}matchKeyId(e,t){return!!(e.keyId&&e.keyId===t)}isAppMetadata(e){return e.indexOf($f)!==-1}isAuthorityMetadata(e){return e.indexOf(Nl.CACHE_KEY)!==-1}generateAuthorityMetadataCacheKey(e){return`${Nl.CACHE_KEY}-${this.clientId}-${e}`}static toObject(e,t){for(const r in t)e[r]=t[r];return e}}class i2 extends ka{setAccount(){throw Y(Ae)}getAccount(){throw Y(Ae)}getCachedAccountEntity(){throw Y(Ae)}setIdTokenCredential(){throw Y(Ae)}getIdTokenCredential(){throw Y(Ae)}setAccessTokenCredential(){throw Y(Ae)}getAccessTokenCredential(){throw Y(Ae)}setRefreshTokenCredential(){throw Y(Ae)}getRefreshTokenCredential(){throw Y(Ae)}setAppMetadata(){throw Y(Ae)}getAppMetadata(){throw Y(Ae)}setServerTelemetry(){throw Y(Ae)}getServerTelemetry(){throw Y(Ae)}setAuthorityMetadata(){throw Y(Ae)}getAuthorityMetadata(){throw Y(Ae)}getAuthorityMetadataKeys(){throw Y(Ae)}setThrottlingCache(){throw Y(Ae)}getThrottlingCache(){throw Y(Ae)}removeItem(){throw Y(Ae)}getKeys(){throw Y(Ae)}getAccountKeys(){throw Y(Ae)}getTokenKeys(){throw Y(Ae)}updateCredentialCacheKey(){throw Y(Ae)}removeOutdatedAccount(){throw Y(Ae)}}/*! @azure/msal-common v14.16.0 2024-11-05 */const Ww={tokenRenewalOffsetSeconds:AF,preventCorsPreflight:!1},a2={loggerCallback:()=>{},piiLoggingEnabled:!1,logLevel:nt.Info,correlationId:$.EMPTY_STRING},s2={claimsBasedCachingEnabled:!1},c2={async sendGetRequestAsync(){throw Y(Ae)},async sendPostRequestAsync(){throw Y(Ae)}},l2={sku:$.SKU,version:Yf,cpu:$.EMPTY_STRING,os:$.EMPTY_STRING},u2={clientSecret:$.EMPTY_STRING,clientAssertion:void 0},d2={azureCloudInstance:Jf.None,tenant:`${$.DEFAULT_COMMON_TENANT}`},h2={application:{appName:"",appVersion:""}};function f2({authOptions:n,systemOptions:e,loggerOptions:t,cacheOptions:r,storageInterface:o,networkInterface:a,cryptoInterface:l,clientCredentials:d,libraryInfo:h,telemetry:f,serverTelemetryManager:g,persistencePlugin:v,serializableCache:p}){const w={...a2,...t};return{authOptions:m2(n),systemOptions:{...Ww,...e},loggerOptions:w,cacheOptions:{...s2,...r},storageInterface:o||new i2(n.clientId,Rl,new Go(w)),networkInterface:a||c2,cryptoInterface:l||Rl,clientCredentials:d||u2,libraryInfo:{...l2,...h},telemetry:{...h2,...f},serverTelemetryManager:g||null,persistencePlugin:v||null,serializableCache:p||null}}function m2(n){return{clientCapabilities:[],azureCloudOptions:d2,skipAuthorityMetadataCache:!1,instanceAware:!1,...n}}function Zh(n){return n.authOptions.authority.options.protocolMode===po.OIDC}/*! @azure/msal-common v14.16.0 2024-11-05 */const Bn={HOME_ACCOUNT_ID:"home_account_id",UPN:"UPN"};/*! @azure/msal-common v14.16.0 2024-11-05 */const Ii="client_id",zw="redirect_uri",Q_="response_type",g2="response_mode",p2="grant_type",v2="claims",_2="scope",y2="refresh_token",C2="state",E2="nonce",w2="prompt",T2="code",b2="code_challenge",S2="code_challenge_method",I2="code_verifier",A2="client-request-id",k2="x-client-SKU",N2="x-client-VER",O2="x-client-OS",R2="x-client-CPU",P2="x-client-current-telemetry",M2="x-client-last-telemetry",D2="x-ms-lib-capability",L2="x-app-name",x2="x-app-ver",U2="post_logout_redirect_uri",V2="id_token_hint",B2="device_code",F2="client_secret",$2="client_assertion",H2="client_assertion_type",X_="token_type",Z_="req_cnf",K2="assertion",W2="requested_token_use",ey="return_spa_code",z2="nativebroker",G2="logout_hint",q2="sid",j2="login_hint",Y2="domain_hint",J2="x-client-xtra-sku",am="brk_client_id",ef="brk_redirect_uri";/*! @azure/msal-common v14.16.0 2024-11-05 */class ua{static validateRedirectUri(e){if(!e)throw Ze(Sw)}static validatePrompt(e){const t=[];for(const r in Bt)t.push(Bt[r]);if(t.indexOf(e)<0)throw Ze(Nw)}static validateClaims(e){try{JSON.parse(e)}catch{throw Ze(Xf)}}static validateCodeChallengeParams(e,t){if(!e||!t)throw Ze(Zf);this.validateCodeChallengeMethod(t)}static validateCodeChallengeMethod(e){if([B_.PLAIN,B_.S256].indexOf(e)<0)throw Ze(Pw)}}/*! @azure/msal-common v14.16.0 2024-11-05 */function Q2(n,e,t){if(!e)return;const r=n.get(Ii);r&&n.has(am)&&(t==null||t.addFields({embeddedClientId:r,embeddedRedirectUri:n.get(zw)},e))}class bs{constructor(e,t){this.parameters=new Map,this.performanceClient=t,this.correlationId=e}addResponseTypeCode(){this.parameters.set(Q_,encodeURIComponent($.CODE_RESPONSE_TYPE))}addResponseTypeForTokenAndIdToken(){this.parameters.set(Q_,encodeURIComponent(`${$.TOKEN_RESPONSE_TYPE} ${$.ID_TOKEN_RESPONSE_TYPE}`))}addResponseMode(e){this.parameters.set(g2,encodeURIComponent(e||bF.QUERY))}addNativeBroker(){this.parameters.set(z2,encodeURIComponent("1"))}addScopes(e,t=!0,r=Ua){t&&!r.includes("openid")&&!e.includes("openid")&&r.push("openid");const o=t?[...e||[],...r]:e||[],a=new _t(o);this.parameters.set(_2,encodeURIComponent(a.printScopes()))}addClientId(e){this.parameters.set(Ii,encodeURIComponent(e))}addRedirectUri(e){ua.validateRedirectUri(e),this.parameters.set(zw,encodeURIComponent(e))}addPostLogoutRedirectUri(e){ua.validateRedirectUri(e),this.parameters.set(U2,encodeURIComponent(e))}addIdTokenHint(e){this.parameters.set(V2,encodeURIComponent(e))}addDomainHint(e){this.parameters.set(Y2,encodeURIComponent(e))}addLoginHint(e){this.parameters.set(j2,encodeURIComponent(e))}addCcsUpn(e){this.parameters.set(hn.CCS_HEADER,encodeURIComponent(`UPN:${e}`))}addCcsOid(e){this.parameters.set(hn.CCS_HEADER,encodeURIComponent(`Oid:${e.uid}@${e.utid}`))}addSid(e){this.parameters.set(q2,encodeURIComponent(e))}addClaims(e,t){const r=this.addClientCapabilitiesToClaims(e,t);ua.validateClaims(r),this.parameters.set(v2,encodeURIComponent(r))}addCorrelationId(e){this.parameters.set(A2,encodeURIComponent(e))}addLibraryInfo(e){this.parameters.set(k2,e.sku),this.parameters.set(N2,e.version),e.os&&this.parameters.set(O2,e.os),e.cpu&&this.parameters.set(R2,e.cpu)}addApplicationTelemetry(e){e!=null&&e.appName&&this.parameters.set(L2,e.appName),e!=null&&e.appVersion&&this.parameters.set(x2,e.appVersion)}addPrompt(e){ua.validatePrompt(e),this.parameters.set(`${w2}`,encodeURIComponent(e))}addState(e){e&&this.parameters.set(C2,encodeURIComponent(e))}addNonce(e){this.parameters.set(E2,encodeURIComponent(e))}addCodeChallengeParams(e,t){if(ua.validateCodeChallengeParams(e,t),e&&t)this.parameters.set(b2,encodeURIComponent(e)),this.parameters.set(S2,encodeURIComponent(t));else throw Ze(Zf)}addAuthorizationCode(e){this.parameters.set(T2,encodeURIComponent(e))}addDeviceCode(e){this.parameters.set(B2,encodeURIComponent(e))}addRefreshToken(e){this.parameters.set(y2,encodeURIComponent(e))}addCodeVerifier(e){this.parameters.set(I2,encodeURIComponent(e))}addClientSecret(e){this.parameters.set(F2,encodeURIComponent(e))}addClientAssertion(e){e&&this.parameters.set($2,encodeURIComponent(e))}addClientAssertionType(e){e&&this.parameters.set(H2,encodeURIComponent(e))}addOboAssertion(e){this.parameters.set(K2,encodeURIComponent(e))}addRequestTokenUse(e){this.parameters.set(W2,encodeURIComponent(e))}addGrantType(e){this.parameters.set(p2,encodeURIComponent(e))}addClientInfo(){this.parameters.set(SF,"1")}addExtraQueryParameters(e){Object.entries(e).forEach(([t,r])=>{!this.parameters.has(t)&&r&&this.parameters.set(t,r)})}addClientCapabilitiesToClaims(e,t){let r;if(!e)r={};else try{r=JSON.parse(e)}catch{throw Ze(Xf)}return t&&t.length>0&&(r.hasOwnProperty(qc.ACCESS_TOKEN)||(r[qc.ACCESS_TOKEN]={}),r[qc.ACCESS_TOKEN][qc.XMS_CC]={values:t}),JSON.stringify(r)}addUsername(e){this.parameters.set($_.username,encodeURIComponent(e))}addPassword(e){this.parameters.set($_.password,encodeURIComponent(e))}addPopToken(e){e&&(this.parameters.set(X_,je.POP),this.parameters.set(Z_,encodeURIComponent(e)))}addSshJwk(e){e&&(this.parameters.set(X_,je.SSH),this.parameters.set(Z_,encodeURIComponent(e)))}addServerTelemetry(e){this.parameters.set(P2,e.generateCurrentRequestHeaderValue()),this.parameters.set(M2,e.generateLastRequestHeaderValue())}addThrottling(){this.parameters.set(D2,Ts.X_MS_LIB_CAPABILITY_VALUE)}addLogoutHint(e){this.parameters.set(G2,encodeURIComponent(e))}addBrokerParameters(e){const t={};t[am]=e.brokerClientId,t[ef]=e.brokerRedirectUri,this.addExtraQueryParameters(t)}createQueryString(){const e=new Array;return this.parameters.forEach((t,r)=>{e.push(`${r}=${t}`)}),Q2(this.parameters,this.correlationId,this.performanceClient),e.join("&")}}/*! @azure/msal-common v14.16.0 2024-11-05 */function X2(n){return n.hasOwnProperty("authorization_endpoint")&&n.hasOwnProperty("token_endpoint")&&n.hasOwnProperty("issuer")&&n.hasOwnProperty("jwks_uri")}/*! @azure/msal-common v14.16.0 2024-11-05 */function Z2(n){return n.hasOwnProperty("tenant_discovery_endpoint")&&n.hasOwnProperty("metadata")}/*! @azure/msal-common v14.16.0 2024-11-05 */function e$(n){return n.hasOwnProperty("error")&&n.hasOwnProperty("error_description")}/*! @azure/msal-common v14.16.0 2024-11-05 */const x={AcquireTokenByCode:"acquireTokenByCode",AcquireTokenByRefreshToken:"acquireTokenByRefreshToken",AcquireTokenSilent:"acquireTokenSilent",AcquireTokenSilentAsync:"acquireTokenSilentAsync",AcquireTokenPopup:"acquireTokenPopup",AcquireTokenPreRedirect:"acquireTokenPreRedirect",AcquireTokenRedirect:"acquireTokenRedirect",CryptoOptsGetPublicKeyThumbprint:"cryptoOptsGetPublicKeyThumbprint",CryptoOptsSignJwt:"cryptoOptsSignJwt",SilentCacheClientAcquireToken:"silentCacheClientAcquireToken",SilentIframeClientAcquireToken:"silentIframeClientAcquireToken",AwaitConcurrentIframe:"awaitConcurrentIframe",SilentRefreshClientAcquireToken:"silentRefreshClientAcquireToken",SsoSilent:"ssoSilent",StandardInteractionClientGetDiscoveredAuthority:"standardInteractionClientGetDiscoveredAuthority",FetchAccountIdWithNativeBroker:"fetchAccountIdWithNativeBroker",NativeInteractionClientAcquireToken:"nativeInteractionClientAcquireToken",BaseClientCreateTokenRequestHeaders:"baseClientCreateTokenRequestHeaders",NetworkClientSendPostRequestAsync:"networkClientSendPostRequestAsync",RefreshTokenClientExecutePostToTokenEndpoint:"refreshTokenClientExecutePostToTokenEndpoint",AuthorizationCodeClientExecutePostToTokenEndpoint:"authorizationCodeClientExecutePostToTokenEndpoint",BrokerHandhshake:"brokerHandshake",AcquireTokenByRefreshTokenInBroker:"acquireTokenByRefreshTokenInBroker",AcquireTokenByBroker:"acquireTokenByBroker",RefreshTokenClientExecuteTokenRequest:"refreshTokenClientExecuteTokenRequest",RefreshTokenClientAcquireToken:"refreshTokenClientAcquireToken",RefreshTokenClientAcquireTokenWithCachedRefreshToken:"refreshTokenClientAcquireTokenWithCachedRefreshToken",RefreshTokenClientAcquireTokenByRefreshToken:"refreshTokenClientAcquireTokenByRefreshToken",RefreshTokenClientCreateTokenRequestBody:"refreshTokenClientCreateTokenRequestBody",AcquireTokenFromCache:"acquireTokenFromCache",SilentFlowClientAcquireCachedToken:"silentFlowClientAcquireCachedToken",SilentFlowClientGenerateResultFromCacheRecord:"silentFlowClientGenerateResultFromCacheRecord",AcquireTokenBySilentIframe:"acquireTokenBySilentIframe",InitializeBaseRequest:"initializeBaseRequest",InitializeSilentRequest:"initializeSilentRequest",InitializeClientApplication:"initializeClientApplication",SilentIframeClientTokenHelper:"silentIframeClientTokenHelper",SilentHandlerInitiateAuthRequest:"silentHandlerInitiateAuthRequest",SilentHandlerMonitorIframeForHash:"silentHandlerMonitorIframeForHash",SilentHandlerLoadFrame:"silentHandlerLoadFrame",SilentHandlerLoadFrameSync:"silentHandlerLoadFrameSync",StandardInteractionClientCreateAuthCodeClient:"standardInteractionClientCreateAuthCodeClient",StandardInteractionClientGetClientConfiguration:"standardInteractionClientGetClientConfiguration",StandardInteractionClientInitializeAuthorizationRequest:"standardInteractionClientInitializeAuthorizationRequest",StandardInteractionClientInitializeAuthorizationCodeRequest:"standardInteractionClientInitializeAuthorizationCodeRequest",GetAuthCodeUrl:"getAuthCodeUrl",HandleCodeResponseFromServer:"handleCodeResponseFromServer",HandleCodeResponse:"handleCodeResponse",UpdateTokenEndpointAuthority:"updateTokenEndpointAuthority",AuthClientAcquireToken:"authClientAcquireToken",AuthClientExecuteTokenRequest:"authClientExecuteTokenRequest",AuthClientCreateTokenRequestBody:"authClientCreateTokenRequestBody",AuthClientCreateQueryString:"authClientCreateQueryString",PopTokenGenerateCnf:"popTokenGenerateCnf",PopTokenGenerateKid:"popTokenGenerateKid",HandleServerTokenResponse:"handleServerTokenResponse",DeserializeResponse:"deserializeResponse",AuthorityFactoryCreateDiscoveredInstance:"authorityFactoryCreateDiscoveredInstance",AuthorityResolveEndpointsAsync:"authorityResolveEndpointsAsync",AuthorityResolveEndpointsFromLocalSources:"authorityResolveEndpointsFromLocalSources",AuthorityGetCloudDiscoveryMetadataFromNetwork:"authorityGetCloudDiscoveryMetadataFromNetwork",AuthorityUpdateCloudDiscoveryMetadata:"authorityUpdateCloudDiscoveryMetadata",AuthorityGetEndpointMetadataFromNetwork:"authorityGetEndpointMetadataFromNetwork",AuthorityUpdateEndpointMetadata:"authorityUpdateEndpointMetadata",AuthorityUpdateMetadataWithRegionalInformation:"authorityUpdateMetadataWithRegionalInformation",RegionDiscoveryDetectRegion:"regionDiscoveryDetectRegion",RegionDiscoveryGetRegionFromIMDS:"regionDiscoveryGetRegionFromIMDS",RegionDiscoveryGetCurrentVersion:"regionDiscoveryGetCurrentVersion",AcquireTokenByCodeAsync:"acquireTokenByCodeAsync",GetEndpointMetadataFromNetwork:"getEndpointMetadataFromNetwork",GetCloudDiscoveryMetadataFromNetworkMeasurement:"getCloudDiscoveryMetadataFromNetworkMeasurement",HandleRedirectPromiseMeasurement:"handleRedirectPromise",HandleNativeRedirectPromiseMeasurement:"handleNativeRedirectPromise",UpdateCloudDiscoveryMetadataMeasurement:"updateCloudDiscoveryMetadataMeasurement",UsernamePasswordClientAcquireToken:"usernamePasswordClientAcquireToken",NativeMessageHandlerHandshake:"nativeMessageHandlerHandshake",NativeGenerateAuthResult:"nativeGenerateAuthResult",RemoveHiddenIframe:"removeHiddenIframe",ClearTokensAndKeysWithClaims:"clearTokensAndKeysWithClaims",CacheManagerGetRefreshToken:"cacheManagerGetRefreshToken",GeneratePkceCodes:"generatePkceCodes",GenerateCodeVerifier:"generateCodeVerifier",GenerateCodeChallengeFromVerifier:"generateCodeChallengeFromVerifier",Sha256Digest:"sha256Digest",GetRandomValues:"getRandomValues"},t$={InProgress:1};/*! @azure/msal-common v14.16.0 2024-11-05 */const Pi=(n,e,t,r,o)=>(...a)=>{t.trace(`Executing function ${e}`);const l=r==null?void 0:r.startMeasurement(e,o);if(o){const d=e+"CallCount";r==null||r.incrementFields({[d]:1},o)}try{const d=n(...a);return l==null||l.end({success:!0}),t.trace(`Returning result from ${e}`),d}catch(d){t.trace(`Error occurred in ${e}`);try{t.trace(JSON.stringify(d))}catch{t.trace("Unable to print error message.")}throw l==null||l.end({success:!1},d),d}},Q=(n,e,t,r,o)=>(...a)=>{t.trace(`Executing function ${e}`);const l=r==null?void 0:r.startMeasurement(e,o);if(o){const d=e+"CallCount";r==null||r.incrementFields({[d]:1},o)}return r==null||r.setPreQueueTime(e,o),n(...a).then(d=>(t.trace(`Returning result from ${e}`),l==null||l.end({success:!0}),d)).catch(d=>{t.trace(`Error occurred in ${e}`);try{t.trace(JSON.stringify(d))}catch{t.trace("Unable to print error message.")}throw l==null||l.end({success:!1},d),d})};/*! @azure/msal-common v14.16.0 2024-11-05 */class du{constructor(e,t,r,o){this.networkInterface=e,this.logger=t,this.performanceClient=r,this.correlationId=o}async detectRegion(e,t){var o;(o=this.performanceClient)==null||o.addQueueMeasurement(x.RegionDiscoveryDetectRegion,this.correlationId);let r=e;if(r)t.region_source=ea.ENVIRONMENT_VARIABLE;else{const a=du.IMDS_OPTIONS;try{const l=await Q(this.getRegionFromIMDS.bind(this),x.RegionDiscoveryGetRegionFromIMDS,this.logger,this.performanceClient,this.correlationId)($.IMDS_VERSION,a);if(l.status===Yc.httpSuccess&&(r=l.body,t.region_source=ea.IMDS),l.status===Yc.httpBadRequest){const d=await Q(this.getCurrentVersion.bind(this),x.RegionDiscoveryGetCurrentVersion,this.logger,this.performanceClient,this.correlationId)(a);if(!d)return t.region_source=ea.FAILED_AUTO_DETECTION,null;const h=await Q(this.getRegionFromIMDS.bind(this),x.RegionDiscoveryGetRegionFromIMDS,this.logger,this.performanceClient,this.correlationId)(d,a);h.status===Yc.httpSuccess&&(r=h.body,t.region_source=ea.IMDS)}}catch{return t.region_source=ea.FAILED_AUTO_DETECTION,null}}return r||(t.region_source=ea.FAILED_AUTO_DETECTION),r||null}async getRegionFromIMDS(e,t){var r;return(r=this.performanceClient)==null||r.addQueueMeasurement(x.RegionDiscoveryGetRegionFromIMDS,this.correlationId),this.networkInterface.sendGetRequestAsync(`${$.IMDS_ENDPOINT}?api-version=${e}&format=text`,t,$.IMDS_TIMEOUT)}async getCurrentVersion(e){var t;(t=this.performanceClient)==null||t.addQueueMeasurement(x.RegionDiscoveryGetCurrentVersion,this.correlationId);try{const r=await this.networkInterface.sendGetRequestAsync(`${$.IMDS_ENDPOINT}?format=json`,e);return r.status===Yc.httpBadRequest&&r.body&&r.body["newest-versions"]&&r.body["newest-versions"].length>0?r.body["newest-versions"][0]:null}catch{return null}}}du.IMDS_OPTIONS={headers:{Metadata:"true"}};/*! @azure/msal-common v14.16.0 2024-11-05 */class Xt{constructor(e,t,r,o,a,l,d,h){this.canonicalAuthority=e,this._canonicalAuthority.validateAsUri(),this.networkInterface=t,this.cacheManager=r,this.authorityOptions=o,this.regionDiscoveryMetadata={region_used:void 0,region_source:void 0,region_outcome:void 0},this.logger=a,this.performanceClient=d,this.correlationId=l,this.managedIdentity=h||!1,this.regionDiscovery=new du(t,this.logger,this.performanceClient,this.correlationId)}getAuthorityType(e){if(e.HostNameAndPort.endsWith($.CIAM_AUTH_URL))return pr.Ciam;const t=e.PathSegments;if(t.length)switch(t[0].toLowerCase()){case $.ADFS:return pr.Adfs;case $.DSTS:return pr.Dsts}return pr.Default}get authorityType(){return this.getAuthorityType(this.canonicalAuthorityUrlComponents)}get protocolMode(){return this.authorityOptions.protocolMode}get options(){return this.authorityOptions}get canonicalAuthority(){return this._canonicalAuthority.urlString}set canonicalAuthority(e){this._canonicalAuthority=new Le(e),this._canonicalAuthority.validateAsUri(),this._canonicalAuthorityUrlComponents=null}get canonicalAuthorityUrlComponents(){return this._canonicalAuthorityUrlComponents||(this._canonicalAuthorityUrlComponents=this._canonicalAuthority.getUrlComponents()),this._canonicalAuthorityUrlComponents}get hostnameAndPort(){return this.canonicalAuthorityUrlComponents.HostNameAndPort.toLowerCase()}get tenant(){return this.canonicalAuthorityUrlComponents.PathSegments[0]}get authorizationEndpoint(){if(this.discoveryComplete())return this.replacePath(this.metadata.authorization_endpoint);throw Y(so)}get tokenEndpoint(){if(this.discoveryComplete())return this.replacePath(this.metadata.token_endpoint);throw Y(so)}get deviceCodeEndpoint(){if(this.discoveryComplete())return this.replacePath(this.metadata.token_endpoint.replace("/token","/devicecode"));throw Y(so)}get endSessionEndpoint(){if(this.discoveryComplete()){if(!this.metadata.end_session_endpoint)throw Y(Ew);return this.replacePath(this.metadata.end_session_endpoint)}else throw Y(so)}get selfSignedJwtAudience(){if(this.discoveryComplete())return this.replacePath(this.metadata.issuer);throw Y(so)}get jwksUri(){if(this.discoveryComplete())return this.replacePath(this.metadata.jwks_uri);throw Y(so)}canReplaceTenant(e){return e.PathSegments.length===1&&!Xt.reservedTenantDomains.has(e.PathSegments[0])&&this.getAuthorityType(e)===pr.Default&&this.protocolMode===po.AAD}replaceTenant(e){return e.replace(/{tenant}|{tenantid}/g,this.tenant)}replacePath(e){let t=e;const o=new Le(this.metadata.canonical_authority).getUrlComponents(),a=o.PathSegments;return this.canonicalAuthorityUrlComponents.PathSegments.forEach((d,h)=>{let f=a[h];if(h===0&&this.canReplaceTenant(o)){const g=new Le(this.metadata.authorization_endpoint).getUrlComponents().PathSegments[0];f!==g&&(this.logger.verbose(`Replacing tenant domain name ${f} with id ${g}`),f=g)}d!==f&&(t=t.replace(`/${f}/`,`/${d}/`))}),this.replaceTenant(t)}get defaultOpenIdConfigurationEndpoint(){const e=this.hostnameAndPort;return this.canonicalAuthority.endsWith("v2.0/")||this.authorityType===pr.Adfs||this.protocolMode!==po.AAD&&!this.isAliasOfKnownMicrosoftAuthority(e)?`${this.canonicalAuthority}.well-known/openid-configuration`:`${this.canonicalAuthority}v2.0/.well-known/openid-configuration`}discoveryComplete(){return!!this.metadata}async resolveEndpointsAsync(){var o,a;(o=this.performanceClient)==null||o.addQueueMeasurement(x.AuthorityResolveEndpointsAsync,this.correlationId);const e=this.getCurrentMetadataEntity(),t=await Q(this.updateCloudDiscoveryMetadata.bind(this),x.AuthorityUpdateCloudDiscoveryMetadata,this.logger,this.performanceClient,this.correlationId)(e);this.canonicalAuthority=this.canonicalAuthority.replace(this.hostnameAndPort,e.preferred_network);const r=await Q(this.updateEndpointMetadata.bind(this),x.AuthorityUpdateEndpointMetadata,this.logger,this.performanceClient,this.correlationId)(e);this.updateCachedMetadata(e,t,{source:r}),(a=this.performanceClient)==null||a.addFields({cloudDiscoverySource:t,authorityEndpointSource:r},this.correlationId)}getCurrentMetadataEntity(){let e=this.cacheManager.getAuthorityMetadataByAlias(this.hostnameAndPort);return e||(e={aliases:[],preferred_cache:this.hostnameAndPort,preferred_network:this.hostnameAndPort,canonical_authority:this.canonicalAuthority,authorization_endpoint:"",token_endpoint:"",end_session_endpoint:"",issuer:"",aliasesFromNetwork:!1,endpointsFromNetwork:!1,expiresAt:q_(),jwks_uri:""}),e}updateCachedMetadata(e,t,r){t!==Pn.CACHE&&(r==null?void 0:r.source)!==Pn.CACHE&&(e.expiresAt=q_(),e.canonical_authority=this.canonicalAuthority);const o=this.cacheManager.generateAuthorityMetadataCacheKey(e.preferred_cache);this.cacheManager.setAuthorityMetadata(o,e),this.metadata=e}async updateEndpointMetadata(e){var o,a,l;(o=this.performanceClient)==null||o.addQueueMeasurement(x.AuthorityUpdateEndpointMetadata,this.correlationId);const t=this.updateEndpointMetadataFromLocalSources(e);if(t){if(t.source===Pn.HARDCODED_VALUES&&(a=this.authorityOptions.azureRegionConfiguration)!=null&&a.azureRegion&&t.metadata){const d=await Q(this.updateMetadataWithRegionalInformation.bind(this),x.AuthorityUpdateMetadataWithRegionalInformation,this.logger,this.performanceClient,this.correlationId)(t.metadata);Jc(e,d,!1),e.canonical_authority=this.canonicalAuthority}return t.source}let r=await Q(this.getEndpointMetadataFromNetwork.bind(this),x.AuthorityGetEndpointMetadataFromNetwork,this.logger,this.performanceClient,this.correlationId)();if(r)return(l=this.authorityOptions.azureRegionConfiguration)!=null&&l.azureRegion&&(r=await Q(this.updateMetadataWithRegionalInformation.bind(this),x.AuthorityUpdateMetadataWithRegionalInformation,this.logger,this.performanceClient,this.correlationId)(r)),Jc(e,r,!0),Pn.NETWORK;throw Y(cw,this.defaultOpenIdConfigurationEndpoint)}updateEndpointMetadataFromLocalSources(e){this.logger.verbose("Attempting to get endpoint metadata from authority configuration");const t=this.getEndpointMetadataFromConfig();if(t)return this.logger.verbose("Found endpoint metadata in authority configuration"),Jc(e,t,!1),{source:Pn.CONFIG};if(this.logger.verbose("Did not find endpoint metadata in the config... Attempting to get endpoint metadata from the hardcoded values."),this.authorityOptions.skipAuthorityMetadataCache)this.logger.verbose("Skipping hardcoded metadata cache since skipAuthorityMetadataCache is set to true. Attempting to get endpoint metadata from the network metadata cache.");else{const o=this.getEndpointMetadataFromHardcodedValues();if(o)return Jc(e,o,!1),{source:Pn.HARDCODED_VALUES,metadata:o};this.logger.verbose("Did not find endpoint metadata in hardcoded values... Attempting to get endpoint metadata from the network metadata cache.")}const r=j_(e);return this.isAuthoritySameType(e)&&e.endpointsFromNetwork&&!r?(this.logger.verbose("Found endpoint metadata in the cache."),{source:Pn.CACHE}):(r&&this.logger.verbose("The metadata entity is expired."),null)}isAuthoritySameType(e){return new Le(e.canonical_authority).getUrlComponents().PathSegments.length===this.canonicalAuthorityUrlComponents.PathSegments.length}getEndpointMetadataFromConfig(){if(this.authorityOptions.authorityMetadata)try{return JSON.parse(this.authorityOptions.authorityMetadata)}catch{throw Ze(Mw)}return null}async getEndpointMetadataFromNetwork(){var r;(r=this.performanceClient)==null||r.addQueueMeasurement(x.AuthorityGetEndpointMetadataFromNetwork,this.correlationId);const e={},t=this.defaultOpenIdConfigurationEndpoint;this.logger.verbose(`Authority.getEndpointMetadataFromNetwork: attempting to retrieve OAuth endpoints from ${t}`);try{const o=await this.networkInterface.sendGetRequestAsync(t,e);return X2(o.body)?o.body:(this.logger.verbose("Authority.getEndpointMetadataFromNetwork: could not parse response as OpenID configuration"),null)}catch(o){return this.logger.verbose(`Authority.getEndpointMetadataFromNetwork: ${o}`),null}}getEndpointMetadataFromHardcodedValues(){return this.hostnameAndPort in Y_?Y_[this.hostnameAndPort]:null}async updateMetadataWithRegionalInformation(e){var r,o,a;(r=this.performanceClient)==null||r.addQueueMeasurement(x.AuthorityUpdateMetadataWithRegionalInformation,this.correlationId);const t=(o=this.authorityOptions.azureRegionConfiguration)==null?void 0:o.azureRegion;if(t){if(t!==$.AZURE_REGION_AUTO_DISCOVER_FLAG)return this.regionDiscoveryMetadata.region_outcome=ih.CONFIGURED_NO_AUTO_DETECTION,this.regionDiscoveryMetadata.region_used=t,Xt.replaceWithRegionalInformation(e,t);const l=await Q(this.regionDiscovery.detectRegion.bind(this.regionDiscovery),x.RegionDiscoveryDetectRegion,this.logger,this.performanceClient,this.correlationId)((a=this.authorityOptions.azureRegionConfiguration)==null?void 0:a.environmentRegion,this.regionDiscoveryMetadata);if(l)return this.regionDiscoveryMetadata.region_outcome=ih.AUTO_DETECTION_REQUESTED_SUCCESSFUL,this.regionDiscoveryMetadata.region_used=l,Xt.replaceWithRegionalInformation(e,l);this.regionDiscoveryMetadata.region_outcome=ih.AUTO_DETECTION_REQUESTED_FAILED}return e}async updateCloudDiscoveryMetadata(e){var o;(o=this.performanceClient)==null||o.addQueueMeasurement(x.AuthorityUpdateCloudDiscoveryMetadata,this.correlationId);const t=this.updateCloudDiscoveryMetadataFromLocalSources(e);if(t)return t;const r=await Q(this.getCloudDiscoveryMetadataFromNetwork.bind(this),x.AuthorityGetCloudDiscoveryMetadataFromNetwork,this.logger,this.performanceClient,this.correlationId)();if(r)return ah(e,r,!0),Pn.NETWORK;throw Ze(Dw)}updateCloudDiscoveryMetadataFromLocalSources(e){this.logger.verbose("Attempting to get cloud discovery metadata from authority configuration"),this.logger.verbosePii(`Known Authorities: ${this.authorityOptions.knownAuthorities||$.NOT_APPLICABLE}`),this.logger.verbosePii(`Authority Metadata: ${this.authorityOptions.authorityMetadata||$.NOT_APPLICABLE}`),this.logger.verbosePii(`Canonical Authority: ${e.canonical_authority||$.NOT_APPLICABLE}`);const t=this.getCloudDiscoveryMetadataFromConfig();if(t)return this.logger.verbose("Found cloud discovery metadata in authority configuration"),ah(e,t,!1),Pn.CONFIG;if(this.logger.verbose("Did not find cloud discovery metadata in the config... Attempting to get cloud discovery metadata from the hardcoded values."),this.options.skipAuthorityMetadataCache)this.logger.verbose("Skipping hardcoded cloud discovery metadata cache since skipAuthorityMetadataCache is set to true. Attempting to get cloud discovery metadata from the network metadata cache.");else{const o=o2(this.hostnameAndPort);if(o)return this.logger.verbose("Found cloud discovery metadata from hardcoded values."),ah(e,o,!1),Pn.HARDCODED_VALUES;this.logger.verbose("Did not find cloud discovery metadata in hardcoded values... Attempting to get cloud discovery metadata from the network metadata cache.")}const r=j_(e);return this.isAuthoritySameType(e)&&e.aliasesFromNetwork&&!r?(this.logger.verbose("Found cloud discovery metadata in the cache."),Pn.CACHE):(r&&this.logger.verbose("The metadata entity is expired."),null)}getCloudDiscoveryMetadataFromConfig(){if(this.authorityType===pr.Ciam)return this.logger.verbose("CIAM authorities do not support cloud discovery metadata, generate the aliases from authority host."),Xt.createCloudDiscoveryMetadataFromHost(this.hostnameAndPort);if(this.authorityOptions.cloudDiscoveryMetadata){this.logger.verbose("The cloud discovery metadata has been provided as a network response, in the config.");try{this.logger.verbose("Attempting to parse the cloud discovery metadata.");const e=JSON.parse(this.authorityOptions.cloudDiscoveryMetadata),t=Ll(e.metadata,this.hostnameAndPort);if(this.logger.verbose("Parsed the cloud discovery metadata."),t)return this.logger.verbose("There is returnable metadata attached to the parsed cloud discovery metadata."),t;this.logger.verbose("There is no metadata attached to the parsed cloud discovery metadata.")}catch{throw this.logger.verbose("Unable to parse the cloud discovery metadata. Throwing Invalid Cloud Discovery Metadata Error."),Ze(em)}}return this.isInKnownAuthorities()?(this.logger.verbose("The host is included in knownAuthorities. Creating new cloud discovery metadata from the host."),Xt.createCloudDiscoveryMetadataFromHost(this.hostnameAndPort)):null}async getCloudDiscoveryMetadataFromNetwork(){var o;(o=this.performanceClient)==null||o.addQueueMeasurement(x.AuthorityGetCloudDiscoveryMetadataFromNetwork,this.correlationId);const e=`${$.AAD_INSTANCE_DISCOVERY_ENDPT}${this.canonicalAuthority}oauth2/v2.0/authorize`,t={};let r=null;try{const a=await this.networkInterface.sendGetRequestAsync(e,t);let l,d;if(Z2(a.body))l=a.body,d=l.metadata,this.logger.verbosePii(`tenant_discovery_endpoint is: ${l.tenant_discovery_endpoint}`);else if(e$(a.body)){if(this.logger.warning(`A CloudInstanceDiscoveryErrorResponse was returned. The cloud instance discovery network request's status code is: ${a.status}`),l=a.body,l.error===$.INVALID_INSTANCE)return this.logger.error("The CloudInstanceDiscoveryErrorResponse error is invalid_instance."),null;this.logger.warning(`The CloudInstanceDiscoveryErrorResponse error is ${l.error}`),this.logger.warning(`The CloudInstanceDiscoveryErrorResponse error description is ${l.error_description}`),this.logger.warning("Setting the value of the CloudInstanceDiscoveryMetadata (returned from the network) to []"),d=[]}else return this.logger.error("AAD did not return a CloudInstanceDiscoveryResponse or CloudInstanceDiscoveryErrorResponse"),null;this.logger.verbose("Attempting to find a match between the developer's authority and the CloudInstanceDiscoveryMetadata returned from the network request."),r=Ll(d,this.hostnameAndPort)}catch(a){if(a instanceof lt)this.logger.error(`There was a network error while attempting to get the cloud discovery instance metadata.
|
|
108
|
+
Error: ${a.errorCode}
|
|
109
|
+
Error Description: ${a.errorMessage}`);else{const l=a;this.logger.error(`A non-MSALJS error was thrown while attempting to get the cloud instance discovery metadata.
|
|
110
|
+
Error: ${l.name}
|
|
111
|
+
Error Description: ${l.message}`)}return null}return r||(this.logger.warning("The developer's authority was not found within the CloudInstanceDiscoveryMetadata returned from the network request."),this.logger.verbose("Creating custom Authority for custom domain scenario."),r=Xt.createCloudDiscoveryMetadataFromHost(this.hostnameAndPort)),r}isInKnownAuthorities(){return this.authorityOptions.knownAuthorities.filter(t=>t&&Le.getDomainFromUrl(t).toLowerCase()===this.hostnameAndPort).length>0}static generateAuthority(e,t){let r;if(t&&t.azureCloudInstance!==Jf.None){const o=t.tenant?t.tenant:$.DEFAULT_COMMON_TENANT;r=`${t.azureCloudInstance}/${o}/`}return r||e}static createCloudDiscoveryMetadataFromHost(e){return{preferred_network:e,preferred_cache:e,aliases:[e]}}getPreferredCache(){if(this.managedIdentity)return $.DEFAULT_AUTHORITY_HOST;if(this.discoveryComplete())return this.metadata.preferred_cache;throw Y(so)}isAlias(e){return this.metadata.aliases.indexOf(e)>-1}isAliasOfKnownMicrosoftAuthority(e){return Hw.has(e)}static isPublicCloudAuthority(e){return $.KNOWN_PUBLIC_CLOUDS.indexOf(e)>=0}static buildRegionalAuthorityString(e,t,r){const o=new Le(e);o.validateAsUri();const a=o.getUrlComponents();let l=`${t}.${a.HostNameAndPort}`;this.isPublicCloudAuthority(a.HostNameAndPort)&&(l=`${t}.${$.REGIONAL_AUTH_PUBLIC_CLOUD_SUFFIX}`);const d=Le.constructAuthorityUriFromObject({...o.getUrlComponents(),HostNameAndPort:l}).urlString;return r?`${d}?${r}`:d}static replaceWithRegionalInformation(e,t){const r={...e};return r.authorization_endpoint=Xt.buildRegionalAuthorityString(r.authorization_endpoint,t),r.token_endpoint=Xt.buildRegionalAuthorityString(r.token_endpoint,t),r.end_session_endpoint&&(r.end_session_endpoint=Xt.buildRegionalAuthorityString(r.end_session_endpoint,t)),r}static transformCIAMAuthority(e){let t=e;const o=new Le(e).getUrlComponents();if(o.PathSegments.length===0&&o.HostNameAndPort.endsWith($.CIAM_AUTH_URL)){const a=o.HostNameAndPort.split(".")[0];t=`${t}${a}${$.AAD_TENANT_DOMAIN_SUFFIX}`}return t}}Xt.reservedTenantDomains=new Set(["{tenant}","{tenantid}",Wo.COMMON,Wo.CONSUMERS,Wo.ORGANIZATIONS]);function n$(n){var o;const r=(o=new Le(n).getUrlComponents().PathSegments.slice(-1)[0])==null?void 0:o.toLowerCase();switch(r){case Wo.COMMON:case Wo.ORGANIZATIONS:case Wo.CONSUMERS:return;default:return r}}function Gw(n){return n.endsWith($.FORWARD_SLASH)?n:`${n}${$.FORWARD_SLASH}`}function r$(n){const e=n.cloudDiscoveryMetadata;let t;if(e)try{t=JSON.parse(e)}catch{throw Ze(em)}return{canonicalAuthority:n.authority?Gw(n.authority):void 0,knownAuthorities:n.knownAuthorities,cloudDiscoveryMetadata:t}}/*! @azure/msal-common v14.16.0 2024-11-05 */async function qw(n,e,t,r,o,a,l){l==null||l.addQueueMeasurement(x.AuthorityFactoryCreateDiscoveredInstance,a);const d=Xt.transformCIAMAuthority(Gw(n)),h=new Xt(d,e,t,r,o,a,l);try{return await Q(h.resolveEndpointsAsync.bind(h),x.AuthorityResolveEndpointsAsync,o,l,a)(),h}catch{throw Y(so)}}/*! @azure/msal-common v14.16.0 2024-11-05 */class qo extends lt{constructor(e,t,r,o,a){super(e,t,r),this.name="ServerError",this.errorNo=o,this.status=a,Object.setPrototypeOf(this,qo.prototype)}}/*! @azure/msal-common v14.16.0 2024-11-05 */class Vr{static generateThrottlingStorageKey(e){return`${Ts.THROTTLING_PREFIX}.${JSON.stringify(e)}`}static preProcess(e,t){var a;const r=Vr.generateThrottlingStorageKey(t),o=e.getThrottlingCache(r);if(o){if(o.throttleTime<Date.now()){e.removeItem(r);return}throw new qo(((a=o.errorCodes)==null?void 0:a.join(" "))||$.EMPTY_STRING,o.errorMessage,o.subError)}}static postProcess(e,t,r){if(Vr.checkResponseStatus(r)||Vr.checkResponseForRetryAfter(r)){const o={throttleTime:Vr.calculateThrottleTime(parseInt(r.headers[hn.RETRY_AFTER])),error:r.body.error,errorCodes:r.body.error_codes,errorMessage:r.body.error_description,subError:r.body.suberror};e.setThrottlingCache(Vr.generateThrottlingStorageKey(t),o)}}static checkResponseStatus(e){return e.status===429||e.status>=500&&e.status<600}static checkResponseForRetryAfter(e){return e.headers?e.headers.hasOwnProperty(hn.RETRY_AFTER)&&(e.status<200||e.status>=300):!1}static calculateThrottleTime(e){const t=e<=0?0:e,r=Date.now()/1e3;return Math.floor(Math.min(r+(t||Ts.DEFAULT_THROTTLE_TIME_SECONDS),r+Ts.DEFAULT_MAX_THROTTLE_TIME_SECONDS)*1e3)}static removeThrottle(e,t,r,o){const a={clientId:t,authority:r.authority,scopes:r.scopes,homeAccountIdentifier:o,claims:r.claims,authenticationScheme:r.authenticationScheme,resourceRequestMethod:r.resourceRequestMethod,resourceRequestUri:r.resourceRequestUri,shrClaims:r.shrClaims,sshKid:r.sshKid},l=this.generateThrottlingStorageKey(a);e.removeItem(l)}}/*! @azure/msal-common v14.16.0 2024-11-05 */class hu extends lt{constructor(e,t,r){super(e.errorCode,e.errorMessage,e.subError),Object.setPrototypeOf(this,hu.prototype),this.name="NetworkError",this.error=e,this.httpStatus=t,this.responseHeaders=r}}function ty(n,e,t){return new hu(n,e,t)}/*! @azure/msal-common v14.16.0 2024-11-05 */class sm{constructor(e,t){this.config=f2(e),this.logger=new Go(this.config.loggerOptions,ww,Yf),this.cryptoUtils=this.config.cryptoInterface,this.cacheManager=this.config.storageInterface,this.networkClient=this.config.networkInterface,this.serverTelemetryManager=this.config.serverTelemetryManager,this.authority=this.config.authOptions.authority,this.performanceClient=t}createTokenRequestHeaders(e){const t={};if(t[hn.CONTENT_TYPE]=$.URL_FORM_CONTENT_TYPE,!this.config.systemOptions.preventCorsPreflight&&e)switch(e.type){case Bn.HOME_ACCOUNT_ID:try{const r=_a(e.credential);t[hn.CCS_HEADER]=`Oid:${r.uid}@${r.utid}`}catch(r){this.logger.verbose("Could not parse home account ID for CCS Header: "+r)}break;case Bn.UPN:t[hn.CCS_HEADER]=`UPN: ${e.credential}`;break}return t}async executePostToTokenEndpoint(e,t,r,o,a,l){var h;l&&((h=this.performanceClient)==null||h.addQueueMeasurement(l,a));const d=await this.sendPostRequest(o,e,{body:t,headers:r},a);return this.config.serverTelemetryManager&&d.status<500&&d.status!==429&&this.config.serverTelemetryManager.clearTelemetryCache(),d}async sendPostRequest(e,t,r,o){var l,d,h;Vr.preProcess(this.cacheManager,e);let a;try{a=await Q(this.networkClient.sendPostRequestAsync.bind(this.networkClient),x.NetworkClientSendPostRequestAsync,this.logger,this.performanceClient,o)(t,r);const f=a.headers||{};(d=this.performanceClient)==null||d.addFields({refreshTokenSize:((l=a.body.refresh_token)==null?void 0:l.length)||0,httpVerToken:f[hn.X_MS_HTTP_VERSION]||"",requestId:f[hn.X_MS_REQUEST_ID]||""},o)}catch(f){if(f instanceof hu){const g=f.responseHeaders;throw g&&((h=this.performanceClient)==null||h.addFields({httpVerToken:g[hn.X_MS_HTTP_VERSION]||"",requestId:g[hn.X_MS_REQUEST_ID]||"",contentTypeHeader:g[hn.CONTENT_TYPE]||void 0,contentLengthHeader:g[hn.CONTENT_LENGTH]||void 0,httpStatus:f.httpStatus},o)),f.error}throw f instanceof lt?f:Y(sw)}return Vr.postProcess(this.cacheManager,e,a),a}async updateAuthority(e,t){var a;(a=this.performanceClient)==null||a.addQueueMeasurement(x.UpdateTokenEndpointAuthority,t);const r=`https://${e}/${this.authority.tenant}/`,o=await qw(r,this.networkClient,this.cacheManager,this.authority.options,this.logger,t,this.performanceClient);this.authority=o}createTokenQueryParameters(e){const t=new bs(e.correlationId,this.performanceClient);return e.embeddedClientId&&t.addBrokerParameters({brokerClientId:this.config.authOptions.clientId,brokerRedirectUri:this.config.authOptions.redirectUri}),e.tokenQueryParameters&&t.addExtraQueryParameters(e.tokenQueryParameters),t.addCorrelationId(e.correlationId),t.createQueryString()}}/*! @azure/msal-common v14.16.0 2024-11-05 */const xl="no_tokens_found",jw="native_account_unavailable",cm="refresh_token_expired",o$="interaction_required",i$="consent_required",a$="login_required",fu="bad_token";/*! @azure/msal-common v14.16.0 2024-11-05 */const ny=[o$,i$,a$,fu],s$=["message_only","additional_action","basic_action","user_password_expired","consent_required","bad_token"],c$={[xl]:"No refresh token found in the cache. Please sign-in.",[jw]:"The requested account is not available in the native broker. It may have been deleted or logged out. Please sign-in again using an interactive API.",[cm]:"Refresh token has expired.",[fu]:"Identity provider returned bad_token due to an expired or invalid refresh token. Please invoke an interactive API to resolve."};class br extends lt{constructor(e,t,r,o,a,l,d,h){super(e,t,r),Object.setPrototypeOf(this,br.prototype),this.timestamp=o||$.EMPTY_STRING,this.traceId=a||$.EMPTY_STRING,this.correlationId=l||$.EMPTY_STRING,this.claims=d||$.EMPTY_STRING,this.name="InteractionRequiredAuthError",this.errorNo=h}}function ry(n,e,t){const r=!!n&&ny.indexOf(n)>-1,o=!!t&&s$.indexOf(t)>-1,a=!!e&&ny.some(l=>e.indexOf(l)>-1);return r||a||o}function tf(n){return new br(n,c$[n])}/*! @azure/msal-common v14.16.0 2024-11-05 */class wr{static setRequestState(e,t,r){const o=wr.generateLibraryState(e,r);return t?`${o}${$.RESOURCE_DELIM}${t}`:o}static generateLibraryState(e,t){if(!e)throw Y(Jh);const r={id:e.createNewGuid()};t&&(r.meta=t);const o=JSON.stringify(r);return e.base64Encode(o)}static parseRequestState(e,t){if(!e)throw Y(Jh);if(!t)throw Y(Aa);try{const r=t.split($.RESOURCE_DELIM),o=r[0],a=r.length>1?r.slice(1).join($.RESOURCE_DELIM):$.EMPTY_STRING,l=e.base64Decode(o),d=JSON.parse(l);return{userRequestState:a||$.EMPTY_STRING,libraryState:d}}catch{throw Y(Aa)}}}/*! @azure/msal-common v14.16.0 2024-11-05 */const l$={SW:"sw"};class Na{constructor(e,t){this.cryptoUtils=e,this.performanceClient=t}async generateCnf(e,t){var a;(a=this.performanceClient)==null||a.addQueueMeasurement(x.PopTokenGenerateCnf,e.correlationId);const r=await Q(this.generateKid.bind(this),x.PopTokenGenerateCnf,t,this.performanceClient,e.correlationId)(e),o=this.cryptoUtils.base64UrlEncode(JSON.stringify(r));return{kid:r.kid,reqCnfString:o}}async generateKid(e){var r;return(r=this.performanceClient)==null||r.addQueueMeasurement(x.PopTokenGenerateKid,e.correlationId),{kid:await this.cryptoUtils.getPublicKeyThumbprint(e),xms_ksl:l$.SW}}async signPopToken(e,t,r){return this.signPayload(e,t,r)}async signPayload(e,t,r,o){const{resourceRequestMethod:a,resourceRequestUri:l,shrClaims:d,shrNonce:h,shrOptions:f}=r,g=l?new Le(l):void 0,v=g==null?void 0:g.getUrlComponents();return this.cryptoUtils.signJwt({at:e,ts:Gr(),m:a==null?void 0:a.toUpperCase(),u:v==null?void 0:v.HostNameAndPort,nonce:h||this.cryptoUtils.createNewGuid(),p:v==null?void 0:v.AbsolutePath,q:v!=null&&v.QueryString?[[],v.QueryString]:void 0,client_claims:d||void 0,...o},t,f,r.correlationId)}}/*! @azure/msal-common v14.16.0 2024-11-05 */class u${constructor(e,t){this.cache=e,this.hasChanged=t}get cacheHasChanged(){return this.hasChanged}get tokenCache(){return this.cache}}/*! @azure/msal-common v14.16.0 2024-11-05 */function d$(n){var r,o;const e="code=",t=(r=n.error_uri)==null?void 0:r.lastIndexOf(e);return t&&t>=0?(o=n.error_uri)==null?void 0:o.substring(t+e.length):void 0}class Ai{constructor(e,t,r,o,a,l,d){this.clientId=e,this.cacheStorage=t,this.cryptoObj=r,this.logger=o,this.serializableCache=a,this.persistencePlugin=l,this.performanceClient=d}validateServerAuthorizationCodeResponse(e,t){if(!e.state||!t)throw e.state?Y(Ol,"Cached State"):Y(Ol,"Server State");let r,o;try{r=decodeURIComponent(e.state)}catch{throw Y(Aa,e.state)}try{o=decodeURIComponent(t)}catch{throw Y(Aa,e.state)}if(r!==o)throw Y(uw);if(e.error||e.error_description||e.suberror){const a=d$(e);throw ry(e.error,e.error_description,e.suberror)?new br(e.error||"",e.error_description,e.suberror,e.timestamp||"",e.trace_id||"",e.correlation_id||"",e.claims||"",a):new qo(e.error||"",e.error_description,e.suberror,a)}}validateTokenResponse(e,t){var r;if(e.error||e.error_description||e.suberror){const o=`Error(s): ${e.error_codes||$.NOT_AVAILABLE} - Timestamp: ${e.timestamp||$.NOT_AVAILABLE} - Description: ${e.error_description||$.NOT_AVAILABLE} - Correlation ID: ${e.correlation_id||$.NOT_AVAILABLE} - Trace ID: ${e.trace_id||$.NOT_AVAILABLE}`,a=(r=e.error_codes)!=null&&r.length?e.error_codes[0]:void 0,l=new qo(e.error,o,e.suberror,a,e.status);if(t&&e.status&&e.status>=Gc.SERVER_ERROR_RANGE_START&&e.status<=Gc.SERVER_ERROR_RANGE_END){this.logger.warning(`executeTokenRequest:validateTokenResponse - AAD is currently unavailable and the access token is unable to be refreshed.
|
|
112
|
+
${l}`);return}else if(t&&e.status&&e.status>=Gc.CLIENT_ERROR_RANGE_START&&e.status<=Gc.CLIENT_ERROR_RANGE_END){this.logger.warning(`executeTokenRequest:validateTokenResponse - AAD is currently available but is unable to refresh the access token.
|
|
113
|
+
${l}`);return}throw ry(e.error,e.error_description,e.suberror)?new br(e.error,e.error_description,e.suberror,e.timestamp||$.EMPTY_STRING,e.trace_id||$.EMPTY_STRING,e.correlation_id||$.EMPTY_STRING,e.claims||$.EMPTY_STRING,a):l}}async handleServerTokenResponse(e,t,r,o,a,l,d,h,f){var C;(C=this.performanceClient)==null||C.addQueueMeasurement(x.HandleServerTokenResponse,e.correlation_id);let g;if(e.id_token){if(g=Ri(e.id_token||$.EMPTY_STRING,this.cryptoObj.base64Decode),a&&a.nonce&&g.nonce!==a.nonce)throw Y(dw);if(o.maxAge||o.maxAge===0){const T=g.auth_time;if(!T)throw Y(zf);Tw(T,o.maxAge)}}this.homeAccountIdentifier=Mt.generateHomeAccountId(e.client_info||$.EMPTY_STRING,t.authorityType,this.logger,this.cryptoObj,g);let v;a&&a.state&&(v=wr.parseRequestState(this.cryptoObj,a.state)),e.key_id=e.key_id||o.sshKid||void 0;const p=this.generateCacheRecord(e,t,r,o,g,l,a);let w;try{if(this.persistencePlugin&&this.serializableCache&&(this.logger.verbose("Persistence enabled, calling beforeCacheAccess"),w=new u$(this.serializableCache,!0),await this.persistencePlugin.beforeCacheAccess(w)),d&&!h&&p.account){const T=p.account.generateAccountKey();if(!this.cacheStorage.getAccount(T,this.logger))return this.logger.warning("Account used to refresh tokens not in persistence, refreshed tokens will not be stored in the cache"),await Ai.generateAuthenticationResult(this.cryptoObj,t,p,!1,o,g,v,void 0,f)}await this.cacheStorage.saveCacheRecord(p,o.storeInCache,o.correlationId)}finally{this.persistencePlugin&&this.serializableCache&&w&&(this.logger.verbose("Persistence enabled, calling afterCacheAccess"),await this.persistencePlugin.afterCacheAccess(w))}return Ai.generateAuthenticationResult(this.cryptoObj,t,p,!1,o,g,v,e,f)}generateCacheRecord(e,t,r,o,a,l,d){const h=t.getPreferredCache();if(!h)throw Y(qf);const f=Bw(a);let g,v;e.id_token&&a&&(g=cu(this.homeAccountIdentifier,h,e.id_token,this.clientId,f||""),v=lm(this.cacheStorage,t,this.homeAccountIdentifier,this.cryptoObj.base64Decode,a,e.client_info,h,f,d,void 0,this.logger));let p=null;if(e.access_token){const T=e.scope?_t.fromString(e.scope):new _t(o.scopes||[]),S=(typeof e.expires_in=="string"?parseInt(e.expires_in,10):e.expires_in)||0,I=(typeof e.ext_expires_in=="string"?parseInt(e.ext_expires_in,10):e.ext_expires_in)||0,N=(typeof e.refresh_in=="string"?parseInt(e.refresh_in,10):e.refresh_in)||void 0,D=r+S,L=D+I,U=N&&N>0?r+N:void 0;p=lu(this.homeAccountIdentifier,h,e.access_token,this.clientId,f||t.tenant||"",T.printScopes(),D,L,this.cryptoObj.base64Decode,U,e.token_type,l,e.key_id,o.claims,o.requestedClaimsHash)}let w=null;if(e.refresh_token){let T;if(e.refresh_token_expires_in){const S=typeof e.refresh_token_expires_in=="string"?parseInt(e.refresh_token_expires_in,10):e.refresh_token_expires_in;T=r+S}w=bw(this.homeAccountIdentifier,h,e.refresh_token,this.clientId,e.foci,l,T)}let C=null;return e.foci&&(C={clientId:this.clientId,environment:h,familyId:e.foci}),{account:v,idToken:g,accessToken:p,refreshToken:w,appMetadata:C}}static async generateAuthenticationResult(e,t,r,o,a,l,d,h,f){var D,L,U,F,R;let g=$.EMPTY_STRING,v=[],p=null,w,C,T=$.EMPTY_STRING;if(r.accessToken){if(r.accessToken.tokenType===je.POP&&!a.popKid){const ae=new Na(e),{secret:se,keyId:X}=r.accessToken;if(!X)throw Y(jf);g=await ae.signPopToken(se,X,a)}else g=r.accessToken.secret;v=_t.fromString(r.accessToken.target).asArray(),p=new Date(Number(r.accessToken.expiresOn)*1e3),w=new Date(Number(r.accessToken.extendedExpiresOn)*1e3),r.accessToken.refreshOn&&(C=new Date(Number(r.accessToken.refreshOn)*1e3))}r.appMetadata&&(T=r.appMetadata.familyId===ws?ws:"");const S=(l==null?void 0:l.oid)||(l==null?void 0:l.sub)||"",I=(l==null?void 0:l.tid)||"";h!=null&&h.spa_accountid&&r.account&&(r.account.nativeAccountId=h==null?void 0:h.spa_accountid);const N=r.account?rm(r.account.getAccountInfo(),void 0,l,(D=r.idToken)==null?void 0:D.secret):null;return{authority:t.canonicalAuthority,uniqueId:S,tenantId:I,scopes:v,account:N,idToken:((L=r==null?void 0:r.idToken)==null?void 0:L.secret)||"",idTokenClaims:l||{},accessToken:g,fromCache:o,expiresOn:p,extExpiresOn:w,refreshOn:C,correlationId:a.correlationId,requestId:f||$.EMPTY_STRING,familyId:T,tokenType:((U=r.accessToken)==null?void 0:U.tokenType)||$.EMPTY_STRING,state:d?d.userRequestState:$.EMPTY_STRING,cloudGraphHostName:((F=r.account)==null?void 0:F.cloudGraphHostName)||$.EMPTY_STRING,msGraphHost:((R=r.account)==null?void 0:R.msGraphHost)||$.EMPTY_STRING,code:h==null?void 0:h.spa_code,fromNativeBroker:!1}}}function lm(n,e,t,r,o,a,l,d,h,f,g){g==null||g.verbose("setCachedAccount called");const p=n.getAccountKeys().find(I=>I.startsWith(t));let w=null;p&&(w=n.getAccount(p,g));const C=w||Mt.createAccount({homeAccountId:t,idTokenClaims:o,clientInfo:a,environment:l,cloudGraphHostName:h==null?void 0:h.cloud_graph_host_name,msGraphHost:h==null?void 0:h.msgraph_host,nativeAccountId:f},e,r),T=C.tenantProfiles||[],S=d||C.realm;if(S&&!T.find(I=>I.tenantId===S)){const I=nm(t,C.localAccountId,S,o);T.push(I)}return C.tenantProfiles=T,C}/*! @azure/msal-common v14.16.0 2024-11-05 */async function Yw(n,e,t){return typeof n=="string"?n:n({clientId:e,tokenEndpoint:t})}/*! @azure/msal-common v14.16.0 2024-11-05 */class Jw extends sm{constructor(e,t){var r;super(e,t),this.includeRedirectUri=!0,this.oidcDefaultScopes=(r=this.config.authOptions.authority.options.OIDCOptions)==null?void 0:r.defaultScopes}async getAuthCodeUrl(e){var r;(r=this.performanceClient)==null||r.addQueueMeasurement(x.GetAuthCodeUrl,e.correlationId);const t=await Q(this.createAuthCodeUrlQueryString.bind(this),x.AuthClientCreateQueryString,this.logger,this.performanceClient,e.correlationId)(e);return Le.appendQueryString(this.authority.authorizationEndpoint,t)}async acquireToken(e,t){var d,h;if((d=this.performanceClient)==null||d.addQueueMeasurement(x.AuthClientAcquireToken,e.correlationId),!e.code)throw Y(mw);const r=Gr(),o=await Q(this.executeTokenRequest.bind(this),x.AuthClientExecuteTokenRequest,this.logger,this.performanceClient,e.correlationId)(this.authority,e),a=(h=o.headers)==null?void 0:h[hn.X_MS_REQUEST_ID],l=new Ai(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,this.config.serializableCache,this.config.persistencePlugin,this.performanceClient);return l.validateTokenResponse(o.body),Q(l.handleServerTokenResponse.bind(l),x.HandleServerTokenResponse,this.logger,this.performanceClient,e.correlationId)(o.body,this.authority,r,e,t,void 0,void 0,void 0,a)}handleFragmentResponse(e,t){if(new Ai(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,null,null).validateServerAuthorizationCodeResponse(e,t),!e.code)throw Y(yw);return e}getLogoutUri(e){if(!e)throw Ze(Rw);const t=this.createLogoutUrlQueryString(e);return Le.appendQueryString(this.authority.endSessionEndpoint,t)}async executeTokenRequest(e,t){var f,g;(f=this.performanceClient)==null||f.addQueueMeasurement(x.AuthClientExecuteTokenRequest,t.correlationId);const r=this.createTokenQueryParameters(t),o=Le.appendQueryString(e.tokenEndpoint,r),a=await Q(this.createTokenRequestBody.bind(this),x.AuthClientCreateTokenRequestBody,this.logger,this.performanceClient,t.correlationId)(t);let l;if(t.clientInfo)try{const v=Pl(t.clientInfo,this.cryptoUtils.base64Decode);l={credential:`${v.uid}${tn.CLIENT_INFO_SEPARATOR}${v.utid}`,type:Bn.HOME_ACCOUNT_ID}}catch(v){this.logger.verbose("Could not parse client info for CCS Header: "+v)}const d=this.createTokenRequestHeaders(l||t.ccsCredential),h={clientId:((g=t.tokenBodyParameters)==null?void 0:g.clientId)||this.config.authOptions.clientId,authority:e.canonicalAuthority,scopes:t.scopes,claims:t.claims,authenticationScheme:t.authenticationScheme,resourceRequestMethod:t.resourceRequestMethod,resourceRequestUri:t.resourceRequestUri,shrClaims:t.shrClaims,sshKid:t.sshKid};return Q(this.executePostToTokenEndpoint.bind(this),x.AuthorizationCodeClientExecutePostToTokenEndpoint,this.logger,this.performanceClient,t.correlationId)(o,a,d,h,t.correlationId,x.AuthorizationCodeClientExecutePostToTokenEndpoint)}async createTokenRequestBody(e){var o,a;(o=this.performanceClient)==null||o.addQueueMeasurement(x.AuthClientCreateTokenRequestBody,e.correlationId);const t=new bs(e.correlationId,this.performanceClient);if(t.addClientId(e.embeddedClientId||((a=e.tokenBodyParameters)==null?void 0:a[Ii])||this.config.authOptions.clientId),this.includeRedirectUri?t.addRedirectUri(e.redirectUri):ua.validateRedirectUri(e.redirectUri),t.addScopes(e.scopes,!0,this.oidcDefaultScopes),t.addAuthorizationCode(e.code),t.addLibraryInfo(this.config.libraryInfo),t.addApplicationTelemetry(this.config.telemetry.application),t.addThrottling(),this.serverTelemetryManager&&!Zh(this.config)&&t.addServerTelemetry(this.serverTelemetryManager),e.codeVerifier&&t.addCodeVerifier(e.codeVerifier),this.config.clientCredentials.clientSecret&&t.addClientSecret(this.config.clientCredentials.clientSecret),this.config.clientCredentials.clientAssertion){const l=this.config.clientCredentials.clientAssertion;t.addClientAssertion(await Yw(l.assertion,this.config.authOptions.clientId,e.resourceRequestUri)),t.addClientAssertionType(l.assertionType)}if(t.addGrantType(rw.AUTHORIZATION_CODE_GRANT),t.addClientInfo(),e.authenticationScheme===je.POP){const l=new Na(this.cryptoUtils,this.performanceClient);let d;e.popKid?d=this.cryptoUtils.encodeKid(e.popKid):d=(await Q(l.generateCnf.bind(l),x.PopTokenGenerateCnf,this.logger,this.performanceClient,e.correlationId)(e,this.logger)).reqCnfString,t.addPopToken(d)}else if(e.authenticationScheme===je.SSH)if(e.sshJwk)t.addSshJwk(e.sshJwk);else throw Ze(uu);(!Er.isEmptyObj(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&t.addClaims(e.claims,this.config.authOptions.clientCapabilities);let r;if(e.clientInfo)try{const l=Pl(e.clientInfo,this.cryptoUtils.base64Decode);r={credential:`${l.uid}${tn.CLIENT_INFO_SEPARATOR}${l.utid}`,type:Bn.HOME_ACCOUNT_ID}}catch(l){this.logger.verbose("Could not parse client info for CCS Header: "+l)}else r=e.ccsCredential;if(this.config.systemOptions.preventCorsPreflight&&r)switch(r.type){case Bn.HOME_ACCOUNT_ID:try{const l=_a(r.credential);t.addCcsOid(l)}catch(l){this.logger.verbose("Could not parse home account ID for CCS Header: "+l)}break;case Bn.UPN:t.addCcsUpn(r.credential);break}return e.embeddedClientId&&t.addBrokerParameters({brokerClientId:this.config.authOptions.clientId,brokerRedirectUri:this.config.authOptions.redirectUri}),e.tokenBodyParameters&&t.addExtraQueryParameters(e.tokenBodyParameters),e.enableSpaAuthorizationCode&&(!e.tokenBodyParameters||!e.tokenBodyParameters[ey])&&t.addExtraQueryParameters({[ey]:"1"}),t.createQueryString()}async createAuthCodeUrlQueryString(e){var a,l;const t=e.correlationId||this.config.cryptoInterface.createNewGuid();(a=this.performanceClient)==null||a.addQueueMeasurement(x.AuthClientCreateQueryString,t);const r=new bs(t,this.performanceClient);r.addClientId(e.embeddedClientId||((l=e.extraQueryParameters)==null?void 0:l[Ii])||this.config.authOptions.clientId);const o=[...e.scopes||[],...e.extraScopesToConsent||[]];if(r.addScopes(o,!0,this.oidcDefaultScopes),r.addRedirectUri(e.redirectUri),r.addCorrelationId(t),r.addResponseMode(e.responseMode),r.addResponseTypeCode(),r.addLibraryInfo(this.config.libraryInfo),Zh(this.config)||r.addApplicationTelemetry(this.config.telemetry.application),r.addClientInfo(),e.codeChallenge&&e.codeChallengeMethod&&r.addCodeChallengeParams(e.codeChallenge,e.codeChallengeMethod),e.prompt&&r.addPrompt(e.prompt),e.domainHint&&r.addDomainHint(e.domainHint),e.prompt!==Bt.SELECT_ACCOUNT)if(e.sid&&e.prompt===Bt.NONE)this.logger.verbose("createAuthCodeUrlQueryString: Prompt is none, adding sid from request"),r.addSid(e.sid);else if(e.account){const d=this.extractAccountSid(e.account);let h=this.extractLoginHint(e.account);if(h&&e.domainHint&&(this.logger.warning('AuthorizationCodeClient.createAuthCodeUrlQueryString: "domainHint" param is set, skipping opaque "login_hint" claim. Please consider not passing domainHint'),h=null),h){this.logger.verbose("createAuthCodeUrlQueryString: login_hint claim present on account"),r.addLoginHint(h);try{const f=_a(e.account.homeAccountId);r.addCcsOid(f)}catch{this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}else if(d&&e.prompt===Bt.NONE){this.logger.verbose("createAuthCodeUrlQueryString: Prompt is none, adding sid from account"),r.addSid(d);try{const f=_a(e.account.homeAccountId);r.addCcsOid(f)}catch{this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}else if(e.loginHint)this.logger.verbose("createAuthCodeUrlQueryString: Adding login_hint from request"),r.addLoginHint(e.loginHint),r.addCcsUpn(e.loginHint);else if(e.account.username){this.logger.verbose("createAuthCodeUrlQueryString: Adding login_hint from account"),r.addLoginHint(e.account.username);try{const f=_a(e.account.homeAccountId);r.addCcsOid(f)}catch{this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}}else e.loginHint&&(this.logger.verbose("createAuthCodeUrlQueryString: No account, adding login_hint from request"),r.addLoginHint(e.loginHint),r.addCcsUpn(e.loginHint));else this.logger.verbose("createAuthCodeUrlQueryString: Prompt is select_account, ignoring account hints");if(e.nonce&&r.addNonce(e.nonce),e.state&&r.addState(e.state),(e.claims||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&r.addClaims(e.claims,this.config.authOptions.clientCapabilities),e.embeddedClientId&&r.addBrokerParameters({brokerClientId:this.config.authOptions.clientId,brokerRedirectUri:this.config.authOptions.redirectUri}),this.addExtraQueryParams(e,r),e.nativeBroker&&(r.addNativeBroker(),e.authenticationScheme===je.POP)){const d=new Na(this.cryptoUtils);let h;e.popKid?h=this.cryptoUtils.encodeKid(e.popKid):h=(await Q(d.generateCnf.bind(d),x.PopTokenGenerateCnf,this.logger,this.performanceClient,e.correlationId)(e,this.logger)).reqCnfString,r.addPopToken(h)}return r.createQueryString()}createLogoutUrlQueryString(e){const t=new bs(e.correlationId,this.performanceClient);return e.postLogoutRedirectUri&&t.addPostLogoutRedirectUri(e.postLogoutRedirectUri),e.correlationId&&t.addCorrelationId(e.correlationId),e.idTokenHint&&t.addIdTokenHint(e.idTokenHint),e.state&&t.addState(e.state),e.logoutHint&&t.addLogoutHint(e.logoutHint),this.addExtraQueryParams(e,t),t.createQueryString()}addExtraQueryParams(e,t){!(e.extraQueryParameters&&e.extraQueryParameters.hasOwnProperty("instance_aware"))&&this.config.authOptions.instanceAware&&(e.extraQueryParameters=e.extraQueryParameters||{},e.extraQueryParameters.instance_aware="true"),e.extraQueryParameters&&t.addExtraQueryParameters(e.extraQueryParameters)}extractAccountSid(e){var t;return((t=e.idTokenClaims)==null?void 0:t.sid)||null}extractLoginHint(e){var t;return((t=e.idTokenClaims)==null?void 0:t.login_hint)||null}}/*! @azure/msal-common v14.16.0 2024-11-05 */const h$=300;class nf extends sm{constructor(e,t){super(e,t)}async acquireToken(e){var l,d;(l=this.performanceClient)==null||l.addQueueMeasurement(x.RefreshTokenClientAcquireToken,e.correlationId);const t=Gr(),r=await Q(this.executeTokenRequest.bind(this),x.RefreshTokenClientExecuteTokenRequest,this.logger,this.performanceClient,e.correlationId)(e,this.authority),o=(d=r.headers)==null?void 0:d[hn.X_MS_REQUEST_ID],a=new Ai(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,this.config.serializableCache,this.config.persistencePlugin);return a.validateTokenResponse(r.body),Q(a.handleServerTokenResponse.bind(a),x.HandleServerTokenResponse,this.logger,this.performanceClient,e.correlationId)(r.body,this.authority,t,e,void 0,void 0,!0,e.forceCache,o)}async acquireTokenByRefreshToken(e){var r;if(!e)throw Ze(Ow);if((r=this.performanceClient)==null||r.addQueueMeasurement(x.RefreshTokenClientAcquireTokenByRefreshToken,e.correlationId),!e.account)throw Y(Gf);if(this.cacheManager.isAppMetadataFOCI(e.account.environment))try{return await Q(this.acquireTokenWithCachedRefreshToken.bind(this),x.RefreshTokenClientAcquireTokenWithCachedRefreshToken,this.logger,this.performanceClient,e.correlationId)(e,!0)}catch(o){const a=o instanceof br&&o.errorCode===xl,l=o instanceof qo&&o.errorCode===F_.INVALID_GRANT_ERROR&&o.subError===F_.CLIENT_MISMATCH_ERROR;if(a||l)return Q(this.acquireTokenWithCachedRefreshToken.bind(this),x.RefreshTokenClientAcquireTokenWithCachedRefreshToken,this.logger,this.performanceClient,e.correlationId)(e,!1);throw o}return Q(this.acquireTokenWithCachedRefreshToken.bind(this),x.RefreshTokenClientAcquireTokenWithCachedRefreshToken,this.logger,this.performanceClient,e.correlationId)(e,!1)}async acquireTokenWithCachedRefreshToken(e,t){var a;(a=this.performanceClient)==null||a.addQueueMeasurement(x.RefreshTokenClientAcquireTokenWithCachedRefreshToken,e.correlationId);const r=Pi(this.cacheManager.getRefreshToken.bind(this.cacheManager),x.CacheManagerGetRefreshToken,this.logger,this.performanceClient,e.correlationId)(e.account,t,void 0,this.performanceClient,e.correlationId);if(!r)throw tf(xl);if(r.expiresOn&&Xh(r.expiresOn,e.refreshTokenExpirationOffsetSeconds||h$))throw tf(cm);const o={...e,refreshToken:r.secret,authenticationScheme:e.authenticationScheme||je.BEARER,ccsCredential:{credential:e.account.homeAccountId,type:Bn.HOME_ACCOUNT_ID}};try{return await Q(this.acquireToken.bind(this),x.RefreshTokenClientAcquireToken,this.logger,this.performanceClient,e.correlationId)(o)}catch(l){if(l instanceof br&&l.subError===fu){this.logger.verbose("acquireTokenWithRefreshToken: bad refresh token, removing from cache");const d=va(r);this.cacheManager.removeRefreshToken(d)}throw l}}async executeTokenRequest(e,t){var h,f;(h=this.performanceClient)==null||h.addQueueMeasurement(x.RefreshTokenClientExecuteTokenRequest,e.correlationId);const r=this.createTokenQueryParameters(e),o=Le.appendQueryString(t.tokenEndpoint,r),a=await Q(this.createTokenRequestBody.bind(this),x.RefreshTokenClientCreateTokenRequestBody,this.logger,this.performanceClient,e.correlationId)(e),l=this.createTokenRequestHeaders(e.ccsCredential),d={clientId:((f=e.tokenBodyParameters)==null?void 0:f.clientId)||this.config.authOptions.clientId,authority:t.canonicalAuthority,scopes:e.scopes,claims:e.claims,authenticationScheme:e.authenticationScheme,resourceRequestMethod:e.resourceRequestMethod,resourceRequestUri:e.resourceRequestUri,shrClaims:e.shrClaims,sshKid:e.sshKid};return Q(this.executePostToTokenEndpoint.bind(this),x.RefreshTokenClientExecutePostToTokenEndpoint,this.logger,this.performanceClient,e.correlationId)(o,a,l,d,e.correlationId,x.RefreshTokenClientExecutePostToTokenEndpoint)}async createTokenRequestBody(e){var o,a,l;(o=this.performanceClient)==null||o.addQueueMeasurement(x.RefreshTokenClientCreateTokenRequestBody,e.correlationId);const t=e.correlationId,r=new bs(t,this.performanceClient);if(r.addClientId(e.embeddedClientId||((a=e.tokenBodyParameters)==null?void 0:a[Ii])||this.config.authOptions.clientId),e.redirectUri&&r.addRedirectUri(e.redirectUri),r.addScopes(e.scopes,!0,(l=this.config.authOptions.authority.options.OIDCOptions)==null?void 0:l.defaultScopes),r.addGrantType(rw.REFRESH_TOKEN_GRANT),r.addClientInfo(),r.addLibraryInfo(this.config.libraryInfo),r.addApplicationTelemetry(this.config.telemetry.application),r.addThrottling(),this.serverTelemetryManager&&!Zh(this.config)&&r.addServerTelemetry(this.serverTelemetryManager),r.addRefreshToken(e.refreshToken),this.config.clientCredentials.clientSecret&&r.addClientSecret(this.config.clientCredentials.clientSecret),this.config.clientCredentials.clientAssertion){const d=this.config.clientCredentials.clientAssertion;r.addClientAssertion(await Yw(d.assertion,this.config.authOptions.clientId,e.resourceRequestUri)),r.addClientAssertionType(d.assertionType)}if(e.authenticationScheme===je.POP){const d=new Na(this.cryptoUtils,this.performanceClient);let h;e.popKid?h=this.cryptoUtils.encodeKid(e.popKid):h=(await Q(d.generateCnf.bind(d),x.PopTokenGenerateCnf,this.logger,this.performanceClient,e.correlationId)(e,this.logger)).reqCnfString,r.addPopToken(h)}else if(e.authenticationScheme===je.SSH)if(e.sshJwk)r.addSshJwk(e.sshJwk);else throw Ze(uu);if((!Er.isEmptyObj(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&r.addClaims(e.claims,this.config.authOptions.clientCapabilities),this.config.systemOptions.preventCorsPreflight&&e.ccsCredential)switch(e.ccsCredential.type){case Bn.HOME_ACCOUNT_ID:try{const d=_a(e.ccsCredential.credential);r.addCcsOid(d)}catch(d){this.logger.verbose("Could not parse home account ID for CCS Header: "+d)}break;case Bn.UPN:r.addCcsUpn(e.ccsCredential.credential);break}return e.embeddedClientId&&r.addBrokerParameters({brokerClientId:this.config.authOptions.clientId,brokerRedirectUri:this.config.authOptions.redirectUri}),e.tokenBodyParameters&&r.addExtraQueryParameters(e.tokenBodyParameters),r.createQueryString()}}/*! @azure/msal-common v14.16.0 2024-11-05 */class f$ extends sm{constructor(e,t){super(e,t)}async acquireToken(e){var t;try{const[r,o]=await this.acquireCachedToken({...e,scopes:(t=e.scopes)!=null&&t.length?e.scopes:[...Ua]});return o===xo.PROACTIVELY_REFRESHED&&(this.logger.info("SilentFlowClient:acquireCachedToken - Cached access token's refreshOn property has been exceeded'. It's not expired, but must be refreshed."),new nf(this.config,this.performanceClient).acquireTokenByRefreshToken(e).catch(()=>{})),r}catch(r){if(r instanceof su&&r.errorCode===lo)return new nf(this.config,this.performanceClient).acquireTokenByRefreshToken(e);throw r}}async acquireCachedToken(e){var h;(h=this.performanceClient)==null||h.addQueueMeasurement(x.SilentFlowClientAcquireCachedToken,e.correlationId);let t=xo.NOT_APPLICABLE;if(e.forceRefresh||!this.config.cacheOptions.claimsBasedCachingEnabled&&!Er.isEmptyObj(e.claims))throw this.setCacheOutcome(xo.FORCE_REFRESH_OR_CLAIMS,e.correlationId),Y(lo);if(!e.account)throw Y(Gf);const r=e.account.tenantId||n$(e.authority),o=this.cacheManager.getTokenKeys(),a=this.cacheManager.getAccessToken(e.account,e,o,r,this.performanceClient,e.correlationId);if(a){if(HF(a.cachedAt)||Xh(a.expiresOn,this.config.systemOptions.tokenRenewalOffsetSeconds))throw this.setCacheOutcome(xo.CACHED_ACCESS_TOKEN_EXPIRED,e.correlationId),Y(lo);a.refreshOn&&Xh(a.refreshOn,0)&&(t=xo.PROACTIVELY_REFRESHED)}else throw this.setCacheOutcome(xo.NO_CACHED_ACCESS_TOKEN,e.correlationId),Y(lo);const l=e.authority||this.authority.getPreferredCache(),d={account:this.cacheManager.readAccountFromCache(e.account),accessToken:a,idToken:this.cacheManager.getIdToken(e.account,o,r,this.performanceClient,e.correlationId),refreshToken:null,appMetadata:this.cacheManager.readAppMetadataFromCache(l)};return this.setCacheOutcome(t,e.correlationId),this.config.serverTelemetryManager&&this.config.serverTelemetryManager.incrementCacheHits(),[await Q(this.generateResultFromCacheRecord.bind(this),x.SilentFlowClientGenerateResultFromCacheRecord,this.logger,this.performanceClient,e.correlationId)(d,e),t]}setCacheOutcome(e,t){var r,o;(r=this.serverTelemetryManager)==null||r.setCacheOutcome(e),(o=this.performanceClient)==null||o.addFields({cacheOutcome:e},t),e!==xo.NOT_APPLICABLE&&this.logger.info(`Token refresh is required due to cache outcome: ${e}`)}async generateResultFromCacheRecord(e,t){var o;(o=this.performanceClient)==null||o.addQueueMeasurement(x.SilentFlowClientGenerateResultFromCacheRecord,t.correlationId);let r;if(e.idToken&&(r=Ri(e.idToken.secret,this.config.cryptoInterface.base64Decode)),t.maxAge||t.maxAge===0){const a=r==null?void 0:r.auth_time;if(!a)throw Y(zf);Tw(a,t.maxAge)}return Ai.generateAuthenticationResult(this.cryptoUtils,this.authority,e,!0,t,r)}}/*! @azure/msal-common v14.16.0 2024-11-05 */const m$={sendGetRequestAsync:()=>Promise.reject(Y(Ae)),sendPostRequestAsync:()=>Promise.reject(Y(Ae))};/*! @azure/msal-common v14.16.0 2024-11-05 */const oy=",",Qw="|";function g$(n){const{skus:e,libraryName:t,libraryVersion:r,extensionName:o,extensionVersion:a}=n,l=new Map([[0,[t,r]],[2,[o,a]]]);let d=[];if(e!=null&&e.length){if(d=e.split(oy),d.length<4)return e}else d=Array.from({length:4},()=>Qw);return l.forEach((h,f)=>{var g,v;h.length===2&&((g=h[0])!=null&&g.length)&&((v=h[1])!=null&&v.length)&&p$({skuArr:d,index:f,skuName:h[0],skuVersion:h[1]})}),d.join(oy)}function p$(n){const{skuArr:e,index:t,skuName:r,skuVersion:o}=n;t>=e.length||(e[t]=[r,o].join(Qw))}class xs{constructor(e,t){this.cacheOutcome=xo.NOT_APPLICABLE,this.cacheManager=t,this.apiId=e.apiId,this.correlationId=e.correlationId,this.wrapperSKU=e.wrapperSKU||$.EMPTY_STRING,this.wrapperVer=e.wrapperVer||$.EMPTY_STRING,this.telemetryCacheKey=zt.CACHE_KEY+tn.CACHE_KEY_SEPARATOR+e.clientId}generateCurrentRequestHeaderValue(){const e=`${this.apiId}${zt.VALUE_SEPARATOR}${this.cacheOutcome}`,t=[this.wrapperSKU,this.wrapperVer],r=this.getNativeBrokerErrorCode();r!=null&&r.length&&t.push(`broker_error=${r}`);const o=t.join(zt.VALUE_SEPARATOR),a=this.getRegionDiscoveryFields(),l=[e,a].join(zt.VALUE_SEPARATOR);return[zt.SCHEMA_VERSION,l,o].join(zt.CATEGORY_SEPARATOR)}generateLastRequestHeaderValue(){const e=this.getLastRequests(),t=xs.maxErrorsToSend(e),r=e.failedRequests.slice(0,2*t).join(zt.VALUE_SEPARATOR),o=e.errors.slice(0,t).join(zt.VALUE_SEPARATOR),a=e.errors.length,l=t<a?zt.OVERFLOW_TRUE:zt.OVERFLOW_FALSE,d=[a,l].join(zt.VALUE_SEPARATOR);return[zt.SCHEMA_VERSION,e.cacheHits,r,o,d].join(zt.CATEGORY_SEPARATOR)}cacheFailedRequest(e){const t=this.getLastRequests();t.errors.length>=zt.MAX_CACHED_ERRORS&&(t.failedRequests.shift(),t.failedRequests.shift(),t.errors.shift()),t.failedRequests.push(this.apiId,this.correlationId),e instanceof Error&&e&&e.toString()?e instanceof lt?e.subError?t.errors.push(e.subError):e.errorCode?t.errors.push(e.errorCode):t.errors.push(e.toString()):t.errors.push(e.toString()):t.errors.push(zt.UNKNOWN_ERROR),this.cacheManager.setServerTelemetry(this.telemetryCacheKey,t)}incrementCacheHits(){const e=this.getLastRequests();return e.cacheHits+=1,this.cacheManager.setServerTelemetry(this.telemetryCacheKey,e),e.cacheHits}getLastRequests(){const e={failedRequests:[],errors:[],cacheHits:0};return this.cacheManager.getServerTelemetry(this.telemetryCacheKey)||e}clearTelemetryCache(){const e=this.getLastRequests(),t=xs.maxErrorsToSend(e),r=e.errors.length;if(t===r)this.cacheManager.removeItem(this.telemetryCacheKey);else{const o={failedRequests:e.failedRequests.slice(t*2),errors:e.errors.slice(t),cacheHits:0};this.cacheManager.setServerTelemetry(this.telemetryCacheKey,o)}}static maxErrorsToSend(e){let t,r=0,o=0;const a=e.errors.length;for(t=0;t<a;t++){const l=e.failedRequests[2*t]||$.EMPTY_STRING,d=e.failedRequests[2*t+1]||$.EMPTY_STRING,h=e.errors[t]||$.EMPTY_STRING;if(o+=l.toString().length+d.toString().length+h.length+3,o<zt.MAX_LAST_HEADER_BYTES)r+=1;else break}return r}getRegionDiscoveryFields(){const e=[];return e.push(this.regionUsed||$.EMPTY_STRING),e.push(this.regionSource||$.EMPTY_STRING),e.push(this.regionOutcome||$.EMPTY_STRING),e.join(",")}updateRegionDiscoveryMetadata(e){this.regionUsed=e.region_used,this.regionSource=e.region_source,this.regionOutcome=e.region_outcome}setCacheOutcome(e){this.cacheOutcome=e}setNativeBrokerErrorCode(e){const t=this.getLastRequests();t.nativeBrokerErrorCode=e,this.cacheManager.setServerTelemetry(this.telemetryCacheKey,t)}getNativeBrokerErrorCode(){return this.getLastRequests().nativeBrokerErrorCode}clearNativeBrokerErrorCode(){const e=this.getLastRequests();delete e.nativeBrokerErrorCode,this.cacheManager.setServerTelemetry(this.telemetryCacheKey,e)}static makeExtraSkuString(e){return g$(e)}}/*! @azure/msal-common v14.16.0 2024-11-05 */const Xw="missing_kid_error",Zw="missing_alg_error";/*! @azure/msal-common v14.16.0 2024-11-05 */const v$={[Xw]:"The JOSE Header for the requested JWT, JWS or JWK object requires a keyId to be configured as the 'kid' header claim. No 'kid' value was provided.",[Zw]:"The JOSE Header for the requested JWT, JWS or JWK object requires an algorithm to be specified as the 'alg' header claim. No 'alg' value was provided."};class um extends lt{constructor(e,t){super(e,t),this.name="JoseHeaderError",Object.setPrototypeOf(this,um.prototype)}}function iy(n){return new um(n,v$[n])}/*! @azure/msal-common v14.16.0 2024-11-05 */class dm{constructor(e){this.typ=e.typ,this.alg=e.alg,this.kid=e.kid}static getShrHeaderString(e){if(!e.kid)throw iy(Xw);if(!e.alg)throw iy(Zw);const t=new dm({typ:e.typ||IF.Pop,kid:e.kid,alg:e.alg});return JSON.stringify(t)}}/*! @azure/msal-common v14.16.0 2024-11-05 */class ay{startMeasurement(){}endMeasurement(){}flushMeasurement(){return null}}class _${generateId(){return"callback-id"}startMeasurement(e,t){return{end:()=>null,discard:()=>{},add:()=>{},increment:()=>{},event:{eventId:this.generateId(),status:t$.InProgress,authority:"",libraryName:"",libraryVersion:"",clientId:"",name:e,startTimeMs:Date.now(),correlationId:t||""},measurement:new ay}}startPerformanceMeasurement(){return new ay}calculateQueuedTime(){return 0}addQueueMeasurement(){}setPreQueueTime(){}endMeasurement(){return null}discardMeasurements(){}removePerformanceCallback(){return!0}addPerformanceCallback(){return""}emitEvents(){}addFields(){}incrementFields(){}cacheEventByCorrelationId(){}}/*! @azure/msal-browser v3.28.1 2025-01-14 */const hm="pkce_not_created",rf="crypto_nonexistent",mu="empty_navigate_uri",eT="hash_empty_error",fm="no_state_in_hash",tT="hash_does_not_contain_known_properties",nT="unable_to_parse_state",rT="state_interaction_type_mismatch",oT="interaction_in_progress",iT="popup_window_error",aT="empty_window_error",ki="user_cancelled",y$="monitor_popup_timeout",sT="monitor_window_timeout",cT="redirect_in_iframe",lT="block_iframe_reload",uT="block_nested_popups",C$="iframe_closed_prematurely",gu="silent_logout_unsupported",dT="no_account_error",E$="silent_prompt_value_error",hT="no_token_request_cache_error",fT="unable_to_parse_token_request_cache_error",mm="no_cached_authority_error",w$="auth_request_not_set_error",T$="invalid_cache_type",pu="non_browser_environment",da="database_not_open",Ul="no_network_connectivity",mT="post_request_failed",gT="get_request_failed",of="failed_to_parse_response",pT="unable_to_load_token",gm="crypto_key_not_found",vT="auth_code_required",_T="auth_code_or_nativeAccountId_required",yT="spa_code_and_nativeAccountId_present",pm="database_unavailable",CT="unable_to_acquire_token_from_native_platform",ET="native_handshake_timeout",wT="native_extension_not_installed",qs="native_connection_not_established",TT="uninitialized_public_client_application",bT="native_prompt_not_supported",ST="invalid_base64_string",IT="invalid_pop_token_request",AT="failed_to_build_headers",kT="failed_to_parse_headers";/*! @azure/msal-browser v3.28.1 2025-01-14 */const ao="For more visit: aka.ms/msaljs/browser-errors",b$={[hm]:"The PKCE code challenge and verifier could not be generated.",[rf]:"The crypto object or function is not available.",[mu]:"Navigation URI is empty. Please check stack trace for more info.",[eT]:`Hash value cannot be processed because it is empty. Please verify that your redirectUri is not clearing the hash. ${ao}`,[fm]:"Hash does not contain state. Please verify that the request originated from msal.",[tT]:`Hash does not contain known properites. Please verify that your redirectUri is not changing the hash. ${ao}`,[nT]:"Unable to parse state. Please verify that the request originated from msal.",[rT]:"Hash contains state but the interaction type does not match the caller.",[oT]:`Interaction is currently in progress. Please ensure that this interaction has been completed before calling an interactive API. ${ao}`,[iT]:"Error opening popup window. This can happen if you are using IE or if popups are blocked in the browser.",[aT]:"window.open returned null or undefined window object.",[ki]:"User cancelled the flow.",[y$]:`Token acquisition in popup failed due to timeout. ${ao}`,[sT]:`Token acquisition in iframe failed due to timeout. ${ao}`,[cT]:"Redirects are not supported for iframed or brokered applications. Please ensure you are using MSAL.js in a top frame of the window if using the redirect APIs, or use the popup APIs.",[lT]:`Request was blocked inside an iframe because MSAL detected an authentication response. ${ao}`,[uT]:"Request was blocked inside a popup because MSAL detected it was running in a popup.",[C$]:"The iframe being monitored was closed prematurely.",[gu]:"Silent logout not supported. Please call logoutRedirect or logoutPopup instead.",[dT]:"No account object provided to acquireTokenSilent and no active account has been set. Please call setActiveAccount or provide an account on the request.",[E$]:"The value given for the prompt value is not valid for silent requests - must be set to 'none' or 'no_session'.",[hT]:"No token request found in cache.",[fT]:"The cached token request could not be parsed.",[mm]:"No cached authority found.",[w$]:"Auth Request not set. Please ensure initiateAuthRequest was called from the InteractionHandler",[T$]:"Invalid cache type",[pu]:"Login and token requests are not supported in non-browser environments.",[da]:"Database is not open!",[Ul]:"No network connectivity. Check your internet connection.",[mT]:"Network request failed: If the browser threw a CORS error, check that the redirectUri is registered in the Azure App Portal as type 'SPA'",[gT]:"Network request failed. Please check the network trace to determine root cause.",[of]:"Failed to parse network response. Check network trace.",[pT]:"Error loading token to cache.",[gm]:"Cryptographic Key or Keypair not found in browser storage.",[vT]:"An authorization code must be provided (as the `code` property on the request) to this flow.",[_T]:"An authorization code or nativeAccountId must be provided to this flow.",[yT]:"Request cannot contain both spa code and native account id.",[pm]:"IndexedDB, which is required for persistent cryptographic key storage, is unavailable. This may be caused by browser privacy features which block persistent storage in third-party contexts.",[CT]:`Unable to acquire token from native platform. ${ao}`,[ET]:"Timed out while attempting to establish connection to browser extension",[wT]:"Native extension is not installed. If you think this is a mistake call the initialize function.",[qs]:`Connection to native platform has not been established. Please install a compatible browser extension and run initialize(). ${ao}`,[TT]:`You must call and await the initialize function before attempting to call any other MSAL API. ${ao}`,[bT]:"The provided prompt is not supported by the native platform. This request should be routed to the web based flow.",[ST]:"Invalid base64 encoded string.",[IT]:"Invalid PoP token request. The request should not have both a popKid value and signPopToken set to true.",[AT]:"Failed to build request headers object.",[kT]:"Failed to parse response headers"};class js extends lt{constructor(e,t){super(e,b$[e],t),Object.setPrototypeOf(this,js.prototype),this.name="BrowserAuthError"}}function ie(n,e){return new js(n,e)}/*! @azure/msal-browser v3.28.1 2025-01-14 */const Ln={INVALID_GRANT_ERROR:"invalid_grant",POPUP_WIDTH:483,POPUP_HEIGHT:600,POPUP_NAME_PREFIX:"msal",DEFAULT_POLL_INTERVAL_MS:30,MSAL_SKU:"msal.js.browser"},ya={CHANNEL_ID:"53ee284d-920a-4b59-9d30-a60315b26836",PREFERRED_EXTENSION_ID:"ppnbnpeolgkicgegkbkbjmhlideopiji",MATS_TELEMETRY:"MATS"},yi={HandshakeRequest:"Handshake",HandshakeResponse:"HandshakeResponse",GetToken:"GetToken",Response:"Response"},yn={LocalStorage:"localStorage",SessionStorage:"sessionStorage",MemoryStorage:"memoryStorage"},sy={GET:"GET",POST:"POST"},ze={AUTHORITY:"authority",ACQUIRE_TOKEN_ACCOUNT:"acquireToken.account",SESSION_STATE:"session.state",REQUEST_STATE:"request.state",NONCE_IDTOKEN:"nonce.id_token",ORIGIN_URI:"request.origin",RENEW_STATUS:"token.renew.status",URL_HASH:"urlHash",REQUEST_PARAMS:"request.params",SCOPES:"scopes",INTERACTION_STATUS_KEY:"interaction.status",CCS_CREDENTIAL:"ccs.credential",CORRELATION_ID:"request.correlationId",NATIVE_REQUEST:"request.native",REDIRECT_CONTEXT:"request.redirect.context"},Lo={ACCOUNT_KEYS:"msal.account.keys",TOKEN_KEYS:"msal.token.keys"},Qc={WRAPPER_SKU:"wrapper.sku",WRAPPER_VER:"wrapper.version"},it={acquireTokenRedirect:861,acquireTokenPopup:862,ssoSilent:863,acquireTokenSilent_authCode:864,handleRedirectPromise:865,acquireTokenByCode:866,acquireTokenSilent_silentFlow:61,logout:961,logoutPopup:962};var ue;(function(n){n.Redirect="redirect",n.Popup="popup",n.Silent="silent",n.None="none"})(ue||(ue={}));const cy={scopes:Ua},NT="jwk",af="msal.db",S$=1,I$=`${af}.keys`,Mn={Default:0,AccessToken:1,AccessTokenAndRefreshToken:2,RefreshToken:3,RefreshTokenAndNetwork:4,Skip:5},A$=[Mn.Default,Mn.Skip,Mn.RefreshTokenAndNetwork],k$="msal.browser.log.level",N$="msal.browser.log.pii";/*! @azure/msal-browser v3.28.1 2025-01-14 */function Xc(n){return encodeURIComponent(vm(n).replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_"))}function vu(n){return OT(n).replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_")}function vm(n){return OT(new TextEncoder().encode(n))}function OT(n){const e=Array.from(n,t=>String.fromCodePoint(t)).join("");return btoa(e)}/*! @azure/msal-browser v3.28.1 2025-01-14 */const O$="RSASSA-PKCS1-v1_5",RT="SHA-256",R$=2048,P$=new Uint8Array([1,0,1]),ly="0123456789abcdef",uy=new Uint32Array(1),M$="crypto_subtle_undefined",_m={name:O$,hash:RT,modulusLength:R$,publicExponent:P$};function D$(n){if(!window)throw ie(pu);if(!window.crypto)throw ie(rf);if(!n&&!window.crypto.subtle)throw ie(rf,M$)}async function PT(n,e,t){e==null||e.addQueueMeasurement(x.Sha256Digest,t);const o=new TextEncoder().encode(n);return window.crypto.subtle.digest(RT,o)}function L$(n){return window.crypto.getRandomValues(n)}function ch(){return window.crypto.getRandomValues(uy),uy[0]}function _o(){const n=Date.now(),e=ch()*1024+(ch()&1023),t=new Uint8Array(16),r=Math.trunc(e/2**30),o=e&2**30-1,a=ch();t[0]=n/2**40,t[1]=n/2**32,t[2]=n/2**24,t[3]=n/2**16,t[4]=n/2**8,t[5]=n,t[6]=112|r>>>8,t[7]=r,t[8]=128|o>>>24,t[9]=o>>>16,t[10]=o>>>8,t[11]=o,t[12]=a>>>24,t[13]=a>>>16,t[14]=a>>>8,t[15]=a;let l="";for(let d=0;d<t.length;d++)l+=ly.charAt(t[d]>>>4),l+=ly.charAt(t[d]&15),(d===3||d===5||d===7||d===9)&&(l+="-");return l}async function x$(n,e){return window.crypto.subtle.generateKey(_m,n,e)}async function lh(n){return window.crypto.subtle.exportKey(NT,n)}async function U$(n,e,t){return window.crypto.subtle.importKey(NT,n,_m,e,t)}async function V$(n,e){return window.crypto.subtle.sign(_m,n,e)}async function MT(n){const e=await PT(n),t=new Uint8Array(e);return vu(t)}/*! @azure/msal-browser v3.28.1 2025-01-14 */const ym="storage_not_supported",B$="stubbed_public_client_application_called",DT="in_mem_redirect_unavailable";/*! @azure/msal-browser v3.28.1 2025-01-14 */const F$={[ym]:"Given storage configuration option was not supported.",[B$]:"Stub instance of Public Client Application was called. If using msal-react, please ensure context is not used without a provider. For more visit: aka.ms/msaljs/browser-errors",[DT]:"Redirect cannot be supported. In-memory storage was selected and storeAuthStateInCookie=false, which would cause the library to be unable to handle the incoming hash. If you would like to use the redirect API, please use session/localStorage or set storeAuthStateInCookie=true."};class Cm extends lt{constructor(e,t){super(e,t),this.name="BrowserConfigurationAuthError",Object.setPrototypeOf(this,Cm.prototype)}}function Em(n){return new Cm(n,F$[n])}/*! @azure/msal-browser v3.28.1 2025-01-14 */function $$(n){n.location.hash="",typeof n.history.replaceState=="function"&&n.history.replaceState(null,"",`${n.location.origin}${n.location.pathname}${n.location.search}`)}function H$(n){const e=n.split("#");e.shift(),window.location.hash=e.length>0?e.join("#"):""}function wm(){return window.parent!==window}function K$(){return typeof window<"u"&&!!window.opener&&window.opener!==window&&typeof window.name=="string"&&window.name.indexOf(`${Ln.POPUP_NAME_PREFIX}.`)===0}function uo(){return typeof window<"u"&&window.location?window.location.href.split("?")[0].split("#")[0]:""}function W$(){const e=new Le(window.location.href).getUrlComponents();return`${e.Protocol}//${e.HostNameAndPort}/`}function z$(){if(Le.hashContainsKnownProperties(window.location.hash)&&wm())throw ie(lT)}function G$(n){if(wm()&&!n)throw ie(cT)}function q$(){if(K$())throw ie(uT)}function LT(){if(typeof window>"u")throw ie(pu)}function xT(n){if(!n)throw ie(TT)}function Tm(n){LT(),z$(),q$(),xT(n)}function dy(n,e){if(Tm(n),G$(e.system.allowRedirectInIframe),e.cache.cacheLocation===yn.MemoryStorage&&!e.cache.storeAuthStateInCookie)throw Em(DT)}function UT(n){const e=document.createElement("link");e.rel="preconnect",e.href=new URL(n).origin,e.crossOrigin="anonymous",document.head.appendChild(e),window.setTimeout(()=>{try{document.head.removeChild(e)}catch{}},1e4)}function j$(){return _o()}/*! @azure/msal-browser v3.28.1 2025-01-14 */class Vl{navigateInternal(e,t){return Vl.defaultNavigateWindow(e,t)}navigateExternal(e,t){return Vl.defaultNavigateWindow(e,t)}static defaultNavigateWindow(e,t){return t.noHistory?window.location.replace(e):window.location.assign(e),new Promise(r=>{setTimeout(()=>{r(!0)},t.timeout)})}}/*! @azure/msal-browser v3.28.1 2025-01-14 */class Y${async sendGetRequestAsync(e,t){let r,o={},a=0;const l=hy(t);try{r=await fetch(e,{method:sy.GET,headers:l})}catch{throw ie(window.navigator.onLine?gT:Ul)}o=fy(r.headers);try{return a=r.status,{headers:o,body:await r.json(),status:a}}catch{throw ty(ie(of),a,o)}}async sendPostRequestAsync(e,t){const r=t&&t.body||"",o=hy(t);let a,l=0,d={};try{a=await fetch(e,{method:sy.POST,headers:o,body:r})}catch{throw ie(window.navigator.onLine?mT:Ul)}d=fy(a.headers);try{return l=a.status,{headers:d,body:await a.json(),status:l}}catch{throw ty(ie(of),l,d)}}}function hy(n){try{const e=new Headers;if(!(n&&n.headers))return e;const t=n.headers;return Object.entries(t).forEach(([r,o])=>{e.append(r,o)}),e}catch{throw ie(AT)}}function fy(n){try{const e={};return n.forEach((t,r)=>{e[r]=t}),e}catch{throw ie(kT)}}/*! @azure/msal-browser v3.28.1 2025-01-14 */const J$=6e4,sf=1e4,Q$=3e4,X$=2e3;function Z$({auth:n,cache:e,system:t,telemetry:r},o){const a={clientId:$.EMPTY_STRING,authority:`${$.DEFAULT_AUTHORITY}`,knownAuthorities:[],cloudDiscoveryMetadata:$.EMPTY_STRING,authorityMetadata:$.EMPTY_STRING,redirectUri:typeof window<"u"?uo():"",postLogoutRedirectUri:$.EMPTY_STRING,navigateToLoginRequestUrl:!0,clientCapabilities:[],protocolMode:po.AAD,OIDCOptions:{serverResponseType:Gs.FRAGMENT,defaultScopes:[$.OPENID_SCOPE,$.PROFILE_SCOPE,$.OFFLINE_ACCESS_SCOPE]},azureCloudOptions:{azureCloudInstance:Jf.None,tenant:$.EMPTY_STRING},skipAuthorityMetadataCache:!1,supportsNestedAppAuth:!1,instanceAware:!1},l={cacheLocation:yn.SessionStorage,temporaryCacheLocation:yn.SessionStorage,storeAuthStateInCookie:!1,secureCookies:!1,cacheMigrationEnabled:!!(e&&e.cacheLocation===yn.LocalStorage),claimsBasedCachingEnabled:!1},d={loggerCallback:()=>{},logLevel:nt.Info,piiLoggingEnabled:!1},f={...{...Ww,loggerOptions:d,networkClient:o?new Y$:m$,navigationClient:new Vl,loadFrameTimeout:0,windowHashTimeout:(t==null?void 0:t.loadFrameTimeout)||J$,iframeHashTimeout:(t==null?void 0:t.loadFrameTimeout)||sf,navigateFrameWait:0,redirectNavigationTimeout:Q$,asyncPopups:!1,allowRedirectInIframe:!1,allowNativeBroker:!1,nativeBrokerHandshakeTimeout:(t==null?void 0:t.nativeBrokerHandshakeTimeout)||X$,pollIntervalMilliseconds:Ln.DEFAULT_POLL_INTERVAL_MS},...t,loggerOptions:(t==null?void 0:t.loggerOptions)||d},g={application:{appName:$.EMPTY_STRING,appVersion:$.EMPTY_STRING},client:new _$};if((n==null?void 0:n.protocolMode)!==po.OIDC&&(n!=null&&n.OIDCOptions)&&new Go(f.loggerOptions).warning(JSON.stringify(Ze(xw))),n!=null&&n.protocolMode&&n.protocolMode!==po.AAD&&(f!=null&&f.allowNativeBroker))throw Ze(Uw);return{auth:{...a,...n,OIDCOptions:{...a.OIDCOptions,...n==null?void 0:n.OIDCOptions}},cache:{...l,...e},system:f,telemetry:{...g,...r}}}/*! @azure/msal-browser v3.28.1 2025-01-14 */const eH="@azure/msal-browser",_u="3.28.1";/*! @azure/msal-browser v3.28.1 2025-01-14 */class bm{static loggerCallback(e,t){switch(e){case nt.Error:console.error(t);return;case nt.Info:console.info(t);return;case nt.Verbose:console.debug(t);return;case nt.Warning:console.warn(t);return;default:console.log(t);return}}constructor(e){var h;this.browserEnvironment=typeof window<"u",this.config=Z$(e,this.browserEnvironment);let t;try{t=window[yn.SessionStorage]}catch{}const r=t==null?void 0:t.getItem(k$),o=(h=t==null?void 0:t.getItem(N$))==null?void 0:h.toLowerCase(),a=o==="true"?!0:o==="false"?!1:void 0,l={...this.config.system.loggerOptions},d=r&&Object.keys(nt).includes(r)?nt[r]:void 0;d&&(l.loggerCallback=bm.loggerCallback,l.logLevel=d),a!==void 0&&(l.piiLoggingEnabled=a),this.logger=new Go(l,eH,_u),this.available=!1}getConfig(){return this.config}getLogger(){return this.logger}isAvailable(){return this.available}isBrowserEnvironment(){return this.browserEnvironment}}/*! @azure/msal-browser v3.28.1 2025-01-14 */class Ni extends bm{getModuleName(){return Ni.MODULE_NAME}getId(){return Ni.ID}async initialize(){return this.available=typeof window<"u",this.available}}Ni.MODULE_NAME="";Ni.ID="StandardOperatingContext";/*! @azure/msal-browser v3.28.1 2025-01-14 */function Wr(n){return new TextDecoder().decode(tH(n))}function tH(n){let e=n.replace(/-/g,"+").replace(/_/g,"/");switch(e.length%4){case 0:break;case 2:e+="==";break;case 3:e+="=";break;default:throw ie(ST)}const t=atob(e);return Uint8Array.from(t,r=>r.codePointAt(0)||0)}/*! @azure/msal-browser v3.28.1 2025-01-14 */class nH{constructor(){this.dbName=af,this.version=S$,this.tableName=I$,this.dbOpen=!1}async open(){return new Promise((e,t)=>{const r=window.indexedDB.open(this.dbName,this.version);r.addEventListener("upgradeneeded",o=>{o.target.result.createObjectStore(this.tableName)}),r.addEventListener("success",o=>{const a=o;this.db=a.target.result,this.dbOpen=!0,e()}),r.addEventListener("error",()=>t(ie(pm)))})}closeConnection(){const e=this.db;e&&this.dbOpen&&(e.close(),this.dbOpen=!1)}async validateDbIsOpen(){if(!this.dbOpen)return this.open()}async getItem(e){return await this.validateDbIsOpen(),new Promise((t,r)=>{if(!this.db)return r(ie(da));const l=this.db.transaction([this.tableName],"readonly").objectStore(this.tableName).get(e);l.addEventListener("success",d=>{const h=d;this.closeConnection(),t(h.target.result)}),l.addEventListener("error",d=>{this.closeConnection(),r(d)})})}async setItem(e,t){return await this.validateDbIsOpen(),new Promise((r,o)=>{if(!this.db)return o(ie(da));const d=this.db.transaction([this.tableName],"readwrite").objectStore(this.tableName).put(t,e);d.addEventListener("success",()=>{this.closeConnection(),r()}),d.addEventListener("error",h=>{this.closeConnection(),o(h)})})}async removeItem(e){return await this.validateDbIsOpen(),new Promise((t,r)=>{if(!this.db)return r(ie(da));const l=this.db.transaction([this.tableName],"readwrite").objectStore(this.tableName).delete(e);l.addEventListener("success",()=>{this.closeConnection(),t()}),l.addEventListener("error",d=>{this.closeConnection(),r(d)})})}async getKeys(){return await this.validateDbIsOpen(),new Promise((e,t)=>{if(!this.db)return t(ie(da));const a=this.db.transaction([this.tableName],"readonly").objectStore(this.tableName).getAllKeys();a.addEventListener("success",l=>{const d=l;this.closeConnection(),e(d.target.result)}),a.addEventListener("error",l=>{this.closeConnection(),t(l)})})}async containsKey(e){return await this.validateDbIsOpen(),new Promise((t,r)=>{if(!this.db)return r(ie(da));const l=this.db.transaction([this.tableName],"readonly").objectStore(this.tableName).count(e);l.addEventListener("success",d=>{const h=d;this.closeConnection(),t(h.target.result===1)}),l.addEventListener("error",d=>{this.closeConnection(),r(d)})})}async deleteDatabase(){return this.db&&this.dbOpen&&this.closeConnection(),new Promise((e,t)=>{const r=window.indexedDB.deleteDatabase(af),o=setTimeout(()=>t(!1),200);r.addEventListener("success",()=>(clearTimeout(o),e(!0))),r.addEventListener("blocked",()=>(clearTimeout(o),e(!0))),r.addEventListener("error",()=>(clearTimeout(o),t(!1)))})}}/*! @azure/msal-browser v3.28.1 2025-01-14 */class cf{constructor(){this.cache=new Map}getItem(e){return this.cache.get(e)||null}setItem(e,t){this.cache.set(e,t)}removeItem(e){this.cache.delete(e)}getKeys(){const e=[];return this.cache.forEach((t,r)=>{e.push(r)}),e}containsKey(e){return this.cache.has(e)}clear(){this.cache.clear()}}/*! @azure/msal-browser v3.28.1 2025-01-14 */class rH{constructor(e){this.inMemoryCache=new cf,this.indexedDBCache=new nH,this.logger=e}handleDatabaseAccessError(e){if(e instanceof js&&e.errorCode===pm)this.logger.error("Could not access persistent storage. This may be caused by browser privacy features which block persistent storage in third-party contexts.");else throw e}async getItem(e){const t=this.inMemoryCache.getItem(e);if(!t)try{return this.logger.verbose("Queried item not found in in-memory cache, now querying persistent storage."),await this.indexedDBCache.getItem(e)}catch(r){this.handleDatabaseAccessError(r)}return t}async setItem(e,t){this.inMemoryCache.setItem(e,t);try{await this.indexedDBCache.setItem(e,t)}catch(r){this.handleDatabaseAccessError(r)}}async removeItem(e){this.inMemoryCache.removeItem(e);try{await this.indexedDBCache.removeItem(e)}catch(t){this.handleDatabaseAccessError(t)}}async getKeys(){const e=this.inMemoryCache.getKeys();if(e.length===0)try{return this.logger.verbose("In-memory cache is empty, now querying persistent storage."),await this.indexedDBCache.getKeys()}catch(t){this.handleDatabaseAccessError(t)}return e}async containsKey(e){const t=this.inMemoryCache.containsKey(e);if(!t)try{return this.logger.verbose("Key not found in in-memory cache, now querying persistent storage."),await this.indexedDBCache.containsKey(e)}catch(r){this.handleDatabaseAccessError(r)}return t}clearInMemory(){this.logger.verbose("Deleting in-memory keystore"),this.inMemoryCache.clear(),this.logger.verbose("In-memory keystore deleted")}async clearPersistent(){try{this.logger.verbose("Deleting persistent keystore");const e=await this.indexedDBCache.deleteDatabase();return e&&this.logger.verbose("Persistent keystore deleted"),e}catch(e){return this.handleDatabaseAccessError(e),!1}}}/*! @azure/msal-browser v3.28.1 2025-01-14 */class Oa{constructor(e,t,r){this.logger=e,D$(r??!1),this.cache=new rH(this.logger),this.performanceClient=t}createNewGuid(){return _o()}base64Encode(e){return vm(e)}base64Decode(e){return Wr(e)}base64UrlEncode(e){return Xc(e)}encodeKid(e){return this.base64UrlEncode(JSON.stringify({kid:e}))}async getPublicKeyThumbprint(e){var g;const t=(g=this.performanceClient)==null?void 0:g.startMeasurement(x.CryptoOptsGetPublicKeyThumbprint,e.correlationId),r=await x$(Oa.EXTRACTABLE,Oa.POP_KEY_USAGES),o=await lh(r.publicKey),a={e:o.e,kty:o.kty,n:o.n},l=my(a),d=await this.hashString(l),h=await lh(r.privateKey),f=await U$(h,!1,["sign"]);return await this.cache.setItem(d,{privateKey:f,publicKey:r.publicKey,requestMethod:e.resourceRequestMethod,requestUri:e.resourceRequestUri}),t&&t.end({success:!0}),d}async removeTokenBindingKey(e){return await this.cache.removeItem(e),!await this.cache.containsKey(e)}async clearKeystore(){this.cache.clearInMemory();try{return await this.cache.clearPersistent(),!0}catch(e){return e instanceof Error?this.logger.error(`Clearing keystore failed with error: ${e.message}`):this.logger.error("Clearing keystore failed with unknown error"),!1}}async signJwt(e,t,r,o){var D;const a=(D=this.performanceClient)==null?void 0:D.startMeasurement(x.CryptoOptsSignJwt,o),l=await this.cache.getItem(t);if(!l)throw ie(gm);const d=await lh(l.publicKey),h=my(d),f=Xc(JSON.stringify({kid:t})),g=dm.getShrHeaderString({...r==null?void 0:r.header,alg:d.alg,kid:f}),v=Xc(g);e.cnf={jwk:JSON.parse(h)};const p=Xc(JSON.stringify(e)),w=`${v}.${p}`,T=new TextEncoder().encode(w),S=await V$(l.privateKey,T),I=vu(new Uint8Array(S)),N=`${w}.${I}`;return a&&a.end({success:!0}),N}async hashString(e){return MT(e)}}Oa.POP_KEY_USAGES=["sign","verify"];Oa.EXTRACTABLE=!0;function my(n){return JSON.stringify(n,Object.keys(n).sort())}/*! @azure/msal-browser v3.28.1 2025-01-14 */class oH{constructor(){if(!window.localStorage)throw Em(ym)}getItem(e){return window.localStorage.getItem(e)}setItem(e,t){window.localStorage.setItem(e,t)}removeItem(e){window.localStorage.removeItem(e)}getKeys(){return Object.keys(window.localStorage)}containsKey(e){return window.localStorage.hasOwnProperty(e)}}/*! @azure/msal-browser v3.28.1 2025-01-14 */class iH{constructor(){if(!window.sessionStorage)throw Em(ym)}getItem(e){return window.sessionStorage.getItem(e)}setItem(e,t){window.sessionStorage.setItem(e,t)}removeItem(e){window.sessionStorage.removeItem(e)}getKeys(){return Object.keys(window.sessionStorage)}containsKey(e){return window.sessionStorage.hasOwnProperty(e)}}/*! @azure/msal-browser v3.28.1 2025-01-14 */function VT(n,e){if(!e)return null;try{return wr.parseRequestState(n,e).libraryState.meta}catch{throw Y(Aa)}}/*! @azure/msal-browser v3.28.1 2025-01-14 */const aH=24*60*60*1e3;class sH{getItem(e){const t=`${encodeURIComponent(e)}`,r=document.cookie.split(";");for(let o=0;o<r.length;o++){const a=r[o],[l,...d]=decodeURIComponent(a).trim().split("="),h=d.join("=");if(l===t)return h}return""}setItem(e,t,r,o=!0){let a=`${encodeURIComponent(e)}=${encodeURIComponent(t)};path=/;SameSite=Lax;`;if(r){const l=cH(r);a+=`expires=${l};`}o&&(a+="Secure;"),document.cookie=a}removeItem(e){this.setItem(e,"",-1)}getKeys(){const e=document.cookie.split(";"),t=[];return e.forEach(r=>{const o=decodeURIComponent(r).trim().split("=");t.push(o[0])}),t}containsKey(e){return this.getKeys().includes(e)}}function cH(n){const e=new Date;return new Date(e.getTime()+n*aH).toUTCString()}/*! @azure/msal-browser v3.28.1 2025-01-14 */class lf extends ka{constructor(e,t,r,o,a,l){super(e,r,o,a),this.cacheConfig=t,this.logger=o,this.internalStorage=new cf,this.browserStorage=this.setupBrowserStorage(this.cacheConfig.cacheLocation),this.temporaryCacheStorage=this.setupBrowserStorage(this.cacheConfig.temporaryCacheLocation),this.cookieStorage=new sH,t.cacheMigrationEnabled&&(this.migrateCacheEntries(),this.createKeyMaps()),this.performanceClient=l}setupBrowserStorage(e){try{switch(e){case yn.LocalStorage:return new oH;case yn.SessionStorage:return new iH;case yn.MemoryStorage:default:break}}catch(t){this.logger.error(t)}return this.cacheConfig.cacheLocation=yn.MemoryStorage,new cf}migrateCacheEntries(){const e=`${$.CACHE_PREFIX}.${xt.ID_TOKEN}`,t=`${$.CACHE_PREFIX}.${xt.CLIENT_INFO}`,r=`${$.CACHE_PREFIX}.${xt.ERROR}`,o=`${$.CACHE_PREFIX}.${xt.ERROR_DESC}`,a=this.browserStorage.getItem(e),l=this.browserStorage.getItem(t),d=this.browserStorage.getItem(r),h=this.browserStorage.getItem(o),f=[a,l,d,h];[xt.ID_TOKEN,xt.CLIENT_INFO,xt.ERROR,xt.ERROR_DESC].forEach((v,p)=>{const w=f[p];w&&this.setTemporaryCache(v,w,!0)})}createKeyMaps(){this.logger.trace("BrowserCacheManager - createKeyMaps called.");const e=this.getItem(Lo.ACCOUNT_KEYS),t=this.getItem(`${Lo.TOKEN_KEYS}.${this.clientId}`);if(e&&t){this.logger.verbose("BrowserCacheManager:createKeyMaps - account and token key maps already exist, skipping migration.");return}this.browserStorage.getKeys().forEach(o=>{if(this.isCredentialKey(o)){const a=this.getItem(o);if(a){const l=this.validateAndParseJson(a);if(l&&l.hasOwnProperty("credentialType"))switch(l.credentialType){case pe.ID_TOKEN:if(z_(l)){this.logger.trace("BrowserCacheManager:createKeyMaps - idToken found, saving key to token key map"),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - idToken with key: ${o} found, saving key to token key map`);const d=l,h=this.updateCredentialCacheKey(o,d);this.addTokenKey(h,pe.ID_TOKEN);return}else this.logger.trace("BrowserCacheManager:createKeyMaps - key found matching idToken schema with value containing idToken credentialType field but value failed IdTokenEntity validation, skipping."),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - failed idToken validation on key: ${o}`);break;case pe.ACCESS_TOKEN:case pe.ACCESS_TOKEN_WITH_AUTH_SCHEME:if(W_(l)){this.logger.trace("BrowserCacheManager:createKeyMaps - accessToken found, saving key to token key map"),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - accessToken with key: ${o} found, saving key to token key map`);const d=l,h=this.updateCredentialCacheKey(o,d);this.addTokenKey(h,pe.ACCESS_TOKEN);return}else this.logger.trace("BrowserCacheManager:createKeyMaps - key found matching accessToken schema with value containing accessToken credentialType field but value failed AccessTokenEntity validation, skipping."),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - failed accessToken validation on key: ${o}`);break;case pe.REFRESH_TOKEN:if(G_(l)){this.logger.trace("BrowserCacheManager:createKeyMaps - refreshToken found, saving key to token key map"),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - refreshToken with key: ${o} found, saving key to token key map`);const d=l,h=this.updateCredentialCacheKey(o,d);this.addTokenKey(h,pe.REFRESH_TOKEN);return}else this.logger.trace("BrowserCacheManager:createKeyMaps - key found matching refreshToken schema with value containing refreshToken credentialType field but value failed RefreshTokenEntity validation, skipping."),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - failed refreshToken validation on key: ${o}`);break}}}if(this.isAccountKey(o)){const a=this.getItem(o);if(a){const l=this.validateAndParseJson(a);l&&Mt.isAccountEntity(l)&&(this.logger.trace("BrowserCacheManager:createKeyMaps - account found, saving key to account key map"),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - account with key: ${o} found, saving key to account key map`),this.addAccountKeyToMap(o))}}})}validateAndParseJson(e){try{const t=JSON.parse(e);return t&&typeof t=="object"?t:null}catch{return null}}getItem(e){return this.browserStorage.getItem(e)}setItem(e,t){this.browserStorage.setItem(e,t)}getAccount(e,t){this.logger.trace("BrowserCacheManager.getAccount called");const r=this.getCachedAccountEntity(e);return this.updateOutdatedCachedAccount(e,r,t)}getCachedAccountEntity(e){const t=this.getItem(e);if(!t)return this.removeAccountKeyFromMap(e),null;const r=this.validateAndParseJson(t);return!r||!Mt.isAccountEntity(r)?(this.removeAccountKeyFromMap(e),null):ka.toObject(new Mt,r)}setAccount(e){this.logger.trace("BrowserCacheManager.setAccount called");const t=e.generateAccountKey();this.setItem(t,JSON.stringify(e)),this.addAccountKeyToMap(t)}getAccountKeys(){this.logger.trace("BrowserCacheManager.getAccountKeys called");const e=this.getItem(Lo.ACCOUNT_KEYS);return e?JSON.parse(e):(this.logger.verbose("BrowserCacheManager.getAccountKeys - No account keys found"),[])}addAccountKeyToMap(e){this.logger.trace("BrowserCacheManager.addAccountKeyToMap called"),this.logger.tracePii(`BrowserCacheManager.addAccountKeyToMap called with key: ${e}`);const t=this.getAccountKeys();t.indexOf(e)===-1?(t.push(e),this.setItem(Lo.ACCOUNT_KEYS,JSON.stringify(t)),this.logger.verbose("BrowserCacheManager.addAccountKeyToMap account key added")):this.logger.verbose("BrowserCacheManager.addAccountKeyToMap account key already exists in map")}removeAccountKeyFromMap(e){this.logger.trace("BrowserCacheManager.removeAccountKeyFromMap called"),this.logger.tracePii(`BrowserCacheManager.removeAccountKeyFromMap called with key: ${e}`);const t=this.getAccountKeys(),r=t.indexOf(e);r>-1?(t.splice(r,1),this.setItem(Lo.ACCOUNT_KEYS,JSON.stringify(t)),this.logger.trace("BrowserCacheManager.removeAccountKeyFromMap account key removed")):this.logger.trace("BrowserCacheManager.removeAccountKeyFromMap key not found in existing map")}async removeAccount(e){super.removeAccount(e),this.removeAccountKeyFromMap(e)}removeOutdatedAccount(e){this.removeItem(e),this.removeAccountKeyFromMap(e)}removeIdToken(e){super.removeIdToken(e),this.removeTokenKey(e,pe.ID_TOKEN)}async removeAccessToken(e){super.removeAccessToken(e),this.removeTokenKey(e,pe.ACCESS_TOKEN)}removeRefreshToken(e){super.removeRefreshToken(e),this.removeTokenKey(e,pe.REFRESH_TOKEN)}getTokenKeys(){this.logger.trace("BrowserCacheManager.getTokenKeys called");const e=this.getItem(`${Lo.TOKEN_KEYS}.${this.clientId}`);if(e){const t=this.validateAndParseJson(e);if(t&&t.hasOwnProperty("idToken")&&t.hasOwnProperty("accessToken")&&t.hasOwnProperty("refreshToken"))return t;this.logger.error("BrowserCacheManager.getTokenKeys - Token keys found but in an unknown format. Returning empty key map.")}else this.logger.verbose("BrowserCacheManager.getTokenKeys - No token keys found");return{idToken:[],accessToken:[],refreshToken:[]}}addTokenKey(e,t){this.logger.trace("BrowserCacheManager addTokenKey called");const r=this.getTokenKeys();switch(t){case pe.ID_TOKEN:r.idToken.indexOf(e)===-1&&(this.logger.info("BrowserCacheManager: addTokenKey - idToken added to map"),r.idToken.push(e));break;case pe.ACCESS_TOKEN:r.accessToken.indexOf(e)===-1&&(this.logger.info("BrowserCacheManager: addTokenKey - accessToken added to map"),r.accessToken.push(e));break;case pe.REFRESH_TOKEN:r.refreshToken.indexOf(e)===-1&&(this.logger.info("BrowserCacheManager: addTokenKey - refreshToken added to map"),r.refreshToken.push(e));break;default:throw this.logger.error(`BrowserCacheManager:addTokenKey - CredentialType provided invalid. CredentialType: ${t}`),Y(Qh)}this.setItem(`${Lo.TOKEN_KEYS}.${this.clientId}`,JSON.stringify(r))}removeTokenKey(e,t){this.logger.trace("BrowserCacheManager removeTokenKey called");const r=this.getTokenKeys();switch(t){case pe.ID_TOKEN:this.logger.infoPii(`BrowserCacheManager: removeTokenKey - attempting to remove idToken with key: ${e} from map`);const o=r.idToken.indexOf(e);o>-1?(this.logger.info("BrowserCacheManager: removeTokenKey - idToken removed from map"),r.idToken.splice(o,1)):this.logger.info("BrowserCacheManager: removeTokenKey - idToken does not exist in map. Either it was previously removed or it was never added.");break;case pe.ACCESS_TOKEN:this.logger.infoPii(`BrowserCacheManager: removeTokenKey - attempting to remove accessToken with key: ${e} from map`);const a=r.accessToken.indexOf(e);a>-1?(this.logger.info("BrowserCacheManager: removeTokenKey - accessToken removed from map"),r.accessToken.splice(a,1)):this.logger.info("BrowserCacheManager: removeTokenKey - accessToken does not exist in map. Either it was previously removed or it was never added.");break;case pe.REFRESH_TOKEN:this.logger.infoPii(`BrowserCacheManager: removeTokenKey - attempting to remove refreshToken with key: ${e} from map`);const l=r.refreshToken.indexOf(e);l>-1?(this.logger.info("BrowserCacheManager: removeTokenKey - refreshToken removed from map"),r.refreshToken.splice(l,1)):this.logger.info("BrowserCacheManager: removeTokenKey - refreshToken does not exist in map. Either it was previously removed or it was never added.");break;default:throw this.logger.error(`BrowserCacheManager:removeTokenKey - CredentialType provided invalid. CredentialType: ${t}`),Y(Qh)}this.setItem(`${Lo.TOKEN_KEYS}.${this.clientId}`,JSON.stringify(r))}getIdTokenCredential(e){const t=this.getItem(e);if(!t)return this.logger.trace("BrowserCacheManager.getIdTokenCredential: called, no cache hit"),this.removeTokenKey(e,pe.ID_TOKEN),null;const r=this.validateAndParseJson(t);return!r||!z_(r)?(this.logger.trace("BrowserCacheManager.getIdTokenCredential: called, no cache hit"),this.removeTokenKey(e,pe.ID_TOKEN),null):(this.logger.trace("BrowserCacheManager.getIdTokenCredential: cache hit"),r)}setIdTokenCredential(e){this.logger.trace("BrowserCacheManager.setIdTokenCredential called");const t=va(e);this.setItem(t,JSON.stringify(e)),this.addTokenKey(t,pe.ID_TOKEN)}getAccessTokenCredential(e){const t=this.getItem(e);if(!t)return this.logger.trace("BrowserCacheManager.getAccessTokenCredential: called, no cache hit"),this.removeTokenKey(e,pe.ACCESS_TOKEN),null;const r=this.validateAndParseJson(t);return!r||!W_(r)?(this.logger.trace("BrowserCacheManager.getAccessTokenCredential: called, no cache hit"),this.removeTokenKey(e,pe.ACCESS_TOKEN),null):(this.logger.trace("BrowserCacheManager.getAccessTokenCredential: cache hit"),r)}setAccessTokenCredential(e){this.logger.trace("BrowserCacheManager.setAccessTokenCredential called");const t=va(e);this.setItem(t,JSON.stringify(e)),this.addTokenKey(t,pe.ACCESS_TOKEN)}getRefreshTokenCredential(e){const t=this.getItem(e);if(!t)return this.logger.trace("BrowserCacheManager.getRefreshTokenCredential: called, no cache hit"),this.removeTokenKey(e,pe.REFRESH_TOKEN),null;const r=this.validateAndParseJson(t);return!r||!G_(r)?(this.logger.trace("BrowserCacheManager.getRefreshTokenCredential: called, no cache hit"),this.removeTokenKey(e,pe.REFRESH_TOKEN),null):(this.logger.trace("BrowserCacheManager.getRefreshTokenCredential: cache hit"),r)}setRefreshTokenCredential(e){this.logger.trace("BrowserCacheManager.setRefreshTokenCredential called");const t=va(e);this.setItem(t,JSON.stringify(e)),this.addTokenKey(t,pe.REFRESH_TOKEN)}getAppMetadata(e){const t=this.getItem(e);if(!t)return this.logger.trace("BrowserCacheManager.getAppMetadata: called, no cache hit"),null;const r=this.validateAndParseJson(t);return!r||!QF(e,r)?(this.logger.trace("BrowserCacheManager.getAppMetadata: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getAppMetadata: cache hit"),r)}setAppMetadata(e){this.logger.trace("BrowserCacheManager.setAppMetadata called");const t=JF(e);this.setItem(t,JSON.stringify(e))}getServerTelemetry(e){const t=this.getItem(e);if(!t)return this.logger.trace("BrowserCacheManager.getServerTelemetry: called, no cache hit"),null;const r=this.validateAndParseJson(t);return!r||!jF(e,r)?(this.logger.trace("BrowserCacheManager.getServerTelemetry: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getServerTelemetry: cache hit"),r)}setServerTelemetry(e,t){this.logger.trace("BrowserCacheManager.setServerTelemetry called"),this.setItem(e,JSON.stringify(t))}getAuthorityMetadata(e){const t=this.internalStorage.getItem(e);if(!t)return this.logger.trace("BrowserCacheManager.getAuthorityMetadata: called, no cache hit"),null;const r=this.validateAndParseJson(t);return r&&XF(e,r)?(this.logger.trace("BrowserCacheManager.getAuthorityMetadata: cache hit"),r):null}getAuthorityMetadataKeys(){return this.internalStorage.getKeys().filter(t=>this.isAuthorityMetadata(t))}setWrapperMetadata(e,t){this.internalStorage.setItem(Qc.WRAPPER_SKU,e),this.internalStorage.setItem(Qc.WRAPPER_VER,t)}getWrapperMetadata(){const e=this.internalStorage.getItem(Qc.WRAPPER_SKU)||$.EMPTY_STRING,t=this.internalStorage.getItem(Qc.WRAPPER_VER)||$.EMPTY_STRING;return[e,t]}setAuthorityMetadata(e,t){this.logger.trace("BrowserCacheManager.setAuthorityMetadata called"),this.internalStorage.setItem(e,JSON.stringify(t))}getActiveAccount(){const e=this.generateCacheKey(xt.ACTIVE_ACCOUNT_FILTERS),t=this.getItem(e);if(!t){this.logger.trace("BrowserCacheManager.getActiveAccount: No active account filters cache schema found, looking for legacy schema");const o=this.generateCacheKey(xt.ACTIVE_ACCOUNT),a=this.getItem(o);if(!a)return this.logger.trace("BrowserCacheManager.getActiveAccount: No active account found"),null;const l=this.getAccountInfoFilteredBy({localAccountId:a});return l?(this.logger.trace("BrowserCacheManager.getActiveAccount: Legacy active account cache schema found"),this.logger.trace("BrowserCacheManager.getActiveAccount: Adding active account filters cache schema"),this.setActiveAccount(l),l):null}const r=this.validateAndParseJson(t);return r?(this.logger.trace("BrowserCacheManager.getActiveAccount: Active account filters schema found"),this.getAccountInfoFilteredBy({homeAccountId:r.homeAccountId,localAccountId:r.localAccountId,tenantId:r.tenantId})):(this.logger.trace("BrowserCacheManager.getActiveAccount: No active account found"),null)}setActiveAccount(e){const t=this.generateCacheKey(xt.ACTIVE_ACCOUNT_FILTERS),r=this.generateCacheKey(xt.ACTIVE_ACCOUNT);if(e){this.logger.verbose("setActiveAccount: Active account set");const o={homeAccountId:e.homeAccountId,localAccountId:e.localAccountId,tenantId:e.tenantId};this.browserStorage.setItem(t,JSON.stringify(o)),this.browserStorage.setItem(r,e.localAccountId)}else this.logger.verbose("setActiveAccount: No account passed, active account not set"),this.browserStorage.removeItem(t),this.browserStorage.removeItem(r)}getThrottlingCache(e){const t=this.getItem(e);if(!t)return this.logger.trace("BrowserCacheManager.getThrottlingCache: called, no cache hit"),null;const r=this.validateAndParseJson(t);return!r||!YF(e,r)?(this.logger.trace("BrowserCacheManager.getThrottlingCache: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getThrottlingCache: cache hit"),r)}setThrottlingCache(e,t){this.logger.trace("BrowserCacheManager.setThrottlingCache called"),this.setItem(e,JSON.stringify(t))}getTemporaryCache(e,t){const r=t?this.generateCacheKey(e):e;if(this.cacheConfig.storeAuthStateInCookie){const a=this.cookieStorage.getItem(r);if(a)return this.logger.trace("BrowserCacheManager.getTemporaryCache: storeAuthStateInCookies set to true, retrieving from cookies"),a}const o=this.temporaryCacheStorage.getItem(r);if(!o){if(this.cacheConfig.cacheLocation===yn.LocalStorage){const a=this.browserStorage.getItem(r);if(a)return this.logger.trace("BrowserCacheManager.getTemporaryCache: Temporary cache item found in local storage"),a}return this.logger.trace("BrowserCacheManager.getTemporaryCache: No cache item found in local storage"),null}return this.logger.trace("BrowserCacheManager.getTemporaryCache: Temporary cache item returned"),o}setTemporaryCache(e,t,r){const o=r?this.generateCacheKey(e):e;this.temporaryCacheStorage.setItem(o,t),this.cacheConfig.storeAuthStateInCookie&&(this.logger.trace("BrowserCacheManager.setTemporaryCache: storeAuthStateInCookie set to true, setting item cookie"),this.cookieStorage.setItem(o,t,void 0,this.cacheConfig.secureCookies))}removeItem(e){this.browserStorage.removeItem(e)}removeTemporaryItem(e){this.temporaryCacheStorage.removeItem(e),this.cacheConfig.storeAuthStateInCookie&&(this.logger.trace("BrowserCacheManager.removeItem: storeAuthStateInCookie is true, clearing item cookie"),this.cookieStorage.removeItem(e))}getKeys(){return this.browserStorage.getKeys()}async clear(){await this.removeAllAccounts(),this.removeAppMetadata(),this.temporaryCacheStorage.getKeys().forEach(e=>{(e.indexOf($.CACHE_PREFIX)!==-1||e.indexOf(this.clientId)!==-1)&&this.removeTemporaryItem(e)}),this.browserStorage.getKeys().forEach(e=>{(e.indexOf($.CACHE_PREFIX)!==-1||e.indexOf(this.clientId)!==-1)&&this.browserStorage.removeItem(e)}),this.internalStorage.clear()}async clearTokensAndKeysWithClaims(e,t){e.addQueueMeasurement(x.ClearTokensAndKeysWithClaims,t);const r=this.getTokenKeys(),o=[];r.accessToken.forEach(a=>{const l=this.getAccessTokenCredential(a);l!=null&&l.requestedClaimsHash&&a.includes(l.requestedClaimsHash.toLowerCase())&&o.push(this.removeAccessToken(a))}),await Promise.all(o),o.length>0&&this.logger.warning(`${o.length} access tokens with claims in the cache keys have been removed from the cache.`)}generateCacheKey(e){return this.validateAndParseJson(e)?JSON.stringify(e):Er.startsWith(e,$.CACHE_PREFIX)||Er.startsWith(e,xt.ADAL_ID_TOKEN)?e:`${$.CACHE_PREFIX}.${this.clientId}.${e}`}generateAuthorityKey(e){const{libraryState:{id:t}}=wr.parseRequestState(this.cryptoImpl,e);return this.generateCacheKey(`${ze.AUTHORITY}.${t}`)}generateNonceKey(e){const{libraryState:{id:t}}=wr.parseRequestState(this.cryptoImpl,e);return this.generateCacheKey(`${ze.NONCE_IDTOKEN}.${t}`)}generateStateKey(e){const{libraryState:{id:t}}=wr.parseRequestState(this.cryptoImpl,e);return this.generateCacheKey(`${ze.REQUEST_STATE}.${t}`)}getCachedAuthority(e){const t=this.generateStateKey(e),r=this.getTemporaryCache(t);if(!r)return null;const o=this.generateAuthorityKey(r);return this.getTemporaryCache(o)}updateCacheEntries(e,t,r,o,a){this.logger.trace("BrowserCacheManager.updateCacheEntries called");const l=this.generateStateKey(e);this.setTemporaryCache(l,e,!1);const d=this.generateNonceKey(e);this.setTemporaryCache(d,t,!1);const h=this.generateAuthorityKey(e);if(this.setTemporaryCache(h,r,!1),a){const f={credential:a.homeAccountId,type:Bn.HOME_ACCOUNT_ID};this.setTemporaryCache(ze.CCS_CREDENTIAL,JSON.stringify(f),!0)}else if(o){const f={credential:o,type:Bn.UPN};this.setTemporaryCache(ze.CCS_CREDENTIAL,JSON.stringify(f),!0)}}resetRequestCache(e){this.logger.trace("BrowserCacheManager.resetRequestCache called"),e&&(this.temporaryCacheStorage.getKeys().forEach(t=>{t.indexOf(e)!==-1&&this.removeTemporaryItem(t)}),this.removeTemporaryItem(this.generateStateKey(e)),this.removeTemporaryItem(this.generateNonceKey(e)),this.removeTemporaryItem(this.generateAuthorityKey(e))),this.removeTemporaryItem(this.generateCacheKey(ze.REQUEST_PARAMS)),this.removeTemporaryItem(this.generateCacheKey(ze.ORIGIN_URI)),this.removeTemporaryItem(this.generateCacheKey(ze.URL_HASH)),this.removeTemporaryItem(this.generateCacheKey(ze.CORRELATION_ID)),this.removeTemporaryItem(this.generateCacheKey(ze.CCS_CREDENTIAL)),this.removeTemporaryItem(this.generateCacheKey(ze.NATIVE_REQUEST)),this.setInteractionInProgress(!1)}cleanRequestByState(e){if(this.logger.trace("BrowserCacheManager.cleanRequestByState called"),e){const t=this.generateStateKey(e),r=this.temporaryCacheStorage.getItem(t);this.logger.infoPii(`BrowserCacheManager.cleanRequestByState: Removing temporary cache items for state: ${r}`),this.resetRequestCache(r||$.EMPTY_STRING)}}cleanRequestByInteractionType(e){this.logger.trace("BrowserCacheManager.cleanRequestByInteractionType called"),this.temporaryCacheStorage.getKeys().forEach(t=>{if(t.indexOf(ze.REQUEST_STATE)===-1)return;const r=this.temporaryCacheStorage.getItem(t);if(!r)return;const o=VT(this.cryptoImpl,r);o&&o.interactionType===e&&(this.logger.infoPii(`BrowserCacheManager.cleanRequestByInteractionType: Removing temporary cache items for state: ${r}`),this.resetRequestCache(r))}),this.setInteractionInProgress(!1)}cacheCodeRequest(e){this.logger.trace("BrowserCacheManager.cacheCodeRequest called");const t=vm(JSON.stringify(e));this.setTemporaryCache(ze.REQUEST_PARAMS,t,!0)}getCachedRequest(e){this.logger.trace("BrowserCacheManager.getCachedRequest called");const t=this.getTemporaryCache(ze.REQUEST_PARAMS,!0);if(!t)throw ie(hT);let r;try{r=JSON.parse(Wr(t))}catch(o){throw this.logger.errorPii(`Attempted to parse: ${t}`),this.logger.error(`Parsing cached token request threw with error: ${o}`),ie(fT)}if(this.removeTemporaryItem(this.generateCacheKey(ze.REQUEST_PARAMS)),!r.authority){const o=this.generateAuthorityKey(e),a=this.getTemporaryCache(o);if(!a)throw ie(mm);r.authority=a}return r}getCachedNativeRequest(){this.logger.trace("BrowserCacheManager.getCachedNativeRequest called");const e=this.getTemporaryCache(ze.NATIVE_REQUEST,!0);if(!e)return this.logger.trace("BrowserCacheManager.getCachedNativeRequest: No cached native request found"),null;const t=this.validateAndParseJson(e);return t||(this.logger.error("BrowserCacheManager.getCachedNativeRequest: Unable to parse native request"),null)}isInteractionInProgress(e){const t=this.getInteractionInProgress();return e?t===this.clientId:!!t}getInteractionInProgress(){const e=`${$.CACHE_PREFIX}.${ze.INTERACTION_STATUS_KEY}`;return this.getTemporaryCache(e,!1)}setInteractionInProgress(e){const t=`${$.CACHE_PREFIX}.${ze.INTERACTION_STATUS_KEY}`;if(e){if(this.getInteractionInProgress())throw ie(oT);this.setTemporaryCache(t,this.clientId,!1)}else!e&&this.getInteractionInProgress()===this.clientId&&this.removeTemporaryItem(t)}getLegacyLoginHint(){const e=this.getTemporaryCache(xt.ADAL_ID_TOKEN);e&&(this.browserStorage.removeItem(xt.ADAL_ID_TOKEN),this.logger.verbose("Cached ADAL id token retrieved."));const t=this.getTemporaryCache(xt.ID_TOKEN,!0);t&&(this.browserStorage.removeItem(this.generateCacheKey(xt.ID_TOKEN)),this.logger.verbose("Cached MSAL.js v1 id token retrieved"));const r=t||e;if(r){const o=Ri(r,Wr);if(o.preferred_username)return this.logger.verbose("No SSO params used and ADAL/MSAL v1 token retrieved, setting ADAL/MSAL v1 preferred_username as loginHint"),o.preferred_username;if(o.upn)return this.logger.verbose("No SSO params used and ADAL/MSAL v1 token retrieved, setting ADAL/MSAL v1 upn as loginHint"),o.upn;this.logger.verbose("No SSO params used and ADAL/MSAL v1 token retrieved, however, no account hint claim found. Enable preferred_username or upn id token claim to get SSO.")}return null}updateCredentialCacheKey(e,t){const r=va(t);if(e!==r){const o=this.getItem(e);if(o)return this.browserStorage.removeItem(e),this.setItem(r,o),this.logger.verbose(`Updated an outdated ${t.credentialType} cache key`),r;this.logger.error(`Attempted to update an outdated ${t.credentialType} cache key but no item matching the outdated key was found in storage`)}return e}async hydrateCache(e,t){var d,h,f;const r=cu((d=e.account)==null?void 0:d.homeAccountId,(h=e.account)==null?void 0:h.environment,e.idToken,this.clientId,e.tenantId);let o;t.claims&&(o=await this.cryptoImpl.hashString(t.claims));const a=lu((f=e.account)==null?void 0:f.homeAccountId,e.account.environment,e.accessToken,this.clientId,e.tenantId,e.scopes.join(" "),e.expiresOn?e.expiresOn.getTime()/1e3:0,e.extExpiresOn?e.extExpiresOn.getTime()/1e3:0,Wr,void 0,e.tokenType,void 0,t.sshKid,t.claims,o),l={idToken:r,accessToken:a};return this.saveCacheRecord(l)}async saveCacheRecord(e,t,r){try{await super.saveCacheRecord(e,t,r)}catch(o){if(o instanceof Ea&&this.performanceClient&&r)try{const a=this.getTokenKeys();this.performanceClient.addFields({cacheRtCount:a.refreshToken.length,cacheIdCount:a.idToken.length,cacheAtCount:a.accessToken.length},r)}catch{}throw o}}}const lH=(n,e)=>{const t={cacheLocation:yn.MemoryStorage,temporaryCacheLocation:yn.MemoryStorage,storeAuthStateInCookie:!1,secureCookies:!1,cacheMigrationEnabled:!1,claimsBasedCachingEnabled:!1};return new lf(n,t,Rl,e)};/*! @azure/msal-browser v3.28.1 2025-01-14 */function uH(n,e,t,r){return n.verbose("getAllAccounts called"),t?e.getAllAccounts(r):[]}function dH(n,e,t){if(e.trace("getAccount called"),Object.keys(n).length===0)return e.warning("getAccount: No accountFilter provided"),null;const r=t.getAccountInfoFilteredBy(n);return r?(e.verbose("getAccount: Account matching provided filter found, returning"),r):(e.verbose("getAccount: No matching account found, returning null"),null)}function hH(n,e,t){if(e.trace("getAccountByUsername called"),!n)return e.warning("getAccountByUsername: No username provided"),null;const r=t.getAccountInfoFilteredBy({username:n});return r?(e.verbose("getAccountByUsername: Account matching username found, returning"),e.verbosePii(`getAccountByUsername: Returning signed-in accounts matching username: ${n}`),r):(e.verbose("getAccountByUsername: No matching account found, returning null"),null)}function fH(n,e,t){if(e.trace("getAccountByHomeId called"),!n)return e.warning("getAccountByHomeId: No homeAccountId provided"),null;const r=t.getAccountInfoFilteredBy({homeAccountId:n});return r?(e.verbose("getAccountByHomeId: Account matching homeAccountId found, returning"),e.verbosePii(`getAccountByHomeId: Returning signed-in accounts matching homeAccountId: ${n}`),r):(e.verbose("getAccountByHomeId: No matching account found, returning null"),null)}function mH(n,e,t){if(e.trace("getAccountByLocalId called"),!n)return e.warning("getAccountByLocalId: No localAccountId provided"),null;const r=t.getAccountInfoFilteredBy({localAccountId:n});return r?(e.verbose("getAccountByLocalId: Account matching localAccountId found, returning"),e.verbosePii(`getAccountByLocalId: Returning signed-in accounts matching localAccountId: ${n}`),r):(e.verbose("getAccountByLocalId: No matching account found, returning null"),null)}function gH(n,e){e.setActiveAccount(n)}function pH(n){return n.getActiveAccount()}/*! @azure/msal-browser v3.28.1 2025-01-14 */const ge={INITIALIZE_START:"msal:initializeStart",INITIALIZE_END:"msal:initializeEnd",ACCOUNT_ADDED:"msal:accountAdded",ACCOUNT_REMOVED:"msal:accountRemoved",ACTIVE_ACCOUNT_CHANGED:"msal:activeAccountChanged",LOGIN_START:"msal:loginStart",LOGIN_SUCCESS:"msal:loginSuccess",LOGIN_FAILURE:"msal:loginFailure",ACQUIRE_TOKEN_START:"msal:acquireTokenStart",ACQUIRE_TOKEN_SUCCESS:"msal:acquireTokenSuccess",ACQUIRE_TOKEN_FAILURE:"msal:acquireTokenFailure",ACQUIRE_TOKEN_NETWORK_START:"msal:acquireTokenFromNetworkStart",SSO_SILENT_START:"msal:ssoSilentStart",SSO_SILENT_SUCCESS:"msal:ssoSilentSuccess",SSO_SILENT_FAILURE:"msal:ssoSilentFailure",ACQUIRE_TOKEN_BY_CODE_START:"msal:acquireTokenByCodeStart",ACQUIRE_TOKEN_BY_CODE_SUCCESS:"msal:acquireTokenByCodeSuccess",ACQUIRE_TOKEN_BY_CODE_FAILURE:"msal:acquireTokenByCodeFailure",HANDLE_REDIRECT_START:"msal:handleRedirectStart",HANDLE_REDIRECT_END:"msal:handleRedirectEnd",POPUP_OPENED:"msal:popupOpened",LOGOUT_START:"msal:logoutStart",LOGOUT_SUCCESS:"msal:logoutSuccess",LOGOUT_FAILURE:"msal:logoutFailure",LOGOUT_END:"msal:logoutEnd",RESTORE_FROM_BFCACHE:"msal:restoreFromBFCache"};/*! @azure/msal-browser v3.28.1 2025-01-14 */class vH{constructor(e){this.eventCallbacks=new Map,this.logger=e||new Go({})}addEventCallback(e,t,r){if(typeof window<"u"){const o=r||j$();return this.eventCallbacks.has(o)?(this.logger.error(`Event callback with id: ${o} is already registered. Please provide a unique id or remove the existing callback and try again.`),null):(this.eventCallbacks.set(o,[e,t||[]]),this.logger.verbose(`Event callback registered with id: ${o}`),o)}return null}removeEventCallback(e){this.eventCallbacks.delete(e),this.logger.verbose(`Event callback ${e} removed.`)}emitEvent(e,t,r,o){if(typeof window<"u"){const a={eventType:e,interactionType:t||null,payload:r||null,error:o||null,timestamp:Date.now()};this.eventCallbacks.forEach(([l,d],h)=>{(d.length===0||d.includes(e))&&(this.logger.verbose(`Emitting event to callback ${h}: ${e}`),l.apply(null,[a]))})}}}/*! @azure/msal-browser v3.28.1 2025-01-14 */class BT{constructor(e,t,r,o,a,l,d,h,f){this.config=e,this.browserStorage=t,this.browserCrypto=r,this.networkClient=this.config.system.networkClient,this.eventHandler=a,this.navigationClient=l,this.nativeMessageHandler=h,this.correlationId=f||_o(),this.logger=o.clone(Ln.MSAL_SKU,_u,this.correlationId),this.performanceClient=d}async clearCacheOnLogout(e){if(e){Mt.accountInfoIsEqual(e,this.browserStorage.getActiveAccount(),!1)&&(this.logger.verbose("Setting active account to null"),this.browserStorage.setActiveAccount(null));try{await this.browserStorage.removeAccount(Mt.generateAccountCacheKey(e)),this.logger.verbose("Cleared cache items belonging to the account provided in the logout request.")}catch{this.logger.error("Account provided in logout request was not found. Local cache unchanged.")}}else try{this.logger.verbose("No account provided in logout request, clearing all cache items.",this.correlationId),await this.browserStorage.clear(),await this.browserCrypto.clearKeystore()}catch{this.logger.error("Attempted to clear all MSAL cache items and failed. Local cache unchanged.")}}getRedirectUri(e){this.logger.verbose("getRedirectUri called");const t=e||this.config.auth.redirectUri;return Le.getAbsoluteUrl(t,uo())}initializeServerTelemetryManager(e,t){this.logger.verbose("initializeServerTelemetryManager called");const r={clientId:this.config.auth.clientId,correlationId:this.correlationId,apiId:e,forceRefresh:t||!1,wrapperSKU:this.browserStorage.getWrapperMetadata()[0],wrapperVer:this.browserStorage.getWrapperMetadata()[1]};return new xs(r,this.browserStorage)}async getDiscoveredAuthority(e){const{account:t}=e,r=e.requestExtraQueryParameters&&e.requestExtraQueryParameters.hasOwnProperty("instance_aware")?e.requestExtraQueryParameters.instance_aware:void 0;this.performanceClient.addQueueMeasurement(x.StandardInteractionClientGetDiscoveredAuthority,this.correlationId);const o={protocolMode:this.config.auth.protocolMode,OIDCOptions:this.config.auth.OIDCOptions,knownAuthorities:this.config.auth.knownAuthorities,cloudDiscoveryMetadata:this.config.auth.cloudDiscoveryMetadata,authorityMetadata:this.config.auth.authorityMetadata,skipAuthorityMetadataCache:this.config.auth.skipAuthorityMetadataCache},a=e.requestAuthority||this.config.auth.authority,l=r!=null&&r.length?r==="true":this.config.auth.instanceAware,d=t&&l?this.config.auth.authority.replace(Le.getDomainFromUrl(a),t.environment):a,h=Xt.generateAuthority(d,e.requestAzureCloudOptions||this.config.auth.azureCloudOptions),f=await Q(qw,x.AuthorityFactoryCreateDiscoveredInstance,this.logger,this.performanceClient,this.correlationId)(h,this.config.system.networkClient,this.browserStorage,o,this.logger,this.correlationId,this.performanceClient);if(t&&!f.isAlias(t.environment))throw Ze(Vw);return f}}/*! @azure/msal-browser v3.28.1 2025-01-14 */const _H=32;async function yH(n,e,t){n.addQueueMeasurement(x.GeneratePkceCodes,t);const r=Pi(CH,x.GenerateCodeVerifier,e,n,t)(n,e,t),o=await Q(EH,x.GenerateCodeChallengeFromVerifier,e,n,t)(r,n,e,t);return{verifier:r,challenge:o}}function CH(n,e,t){try{const r=new Uint8Array(_H);return Pi(L$,x.GetRandomValues,e,n,t)(r),vu(r)}catch{throw ie(hm)}}async function EH(n,e,t,r){e.addQueueMeasurement(x.GenerateCodeChallengeFromVerifier,r);try{const o=await Q(PT,x.Sha256Digest,t,e,r)(n,e,r);return vu(new Uint8Array(o))}catch{throw ie(hm)}}/*! @azure/msal-browser v3.28.1 2025-01-14 */async function Sm(n,e,t,r){t.addQueueMeasurement(x.InitializeBaseRequest,n.correlationId);const o=n.authority||e.auth.authority,a=[...n&&n.scopes||[]],l={...n,correlationId:n.correlationId,authority:o,scopes:a};if(!l.authenticationScheme)l.authenticationScheme=je.BEARER,r.verbose(`Authentication Scheme wasn't explicitly set in request, defaulting to "Bearer" request`);else{if(l.authenticationScheme===je.SSH){if(!n.sshJwk)throw Ze(uu);if(!n.sshKid)throw Ze(Lw)}r.verbose(`Authentication Scheme set to "${l.authenticationScheme}" as configured in Auth request`)}return e.cache.claimsBasedCachingEnabled&&n.claims&&!Er.isEmptyObj(n.claims)&&(l.requestedClaimsHash=await MT(n.claims)),l}async function wH(n,e,t,r,o){r.addQueueMeasurement(x.InitializeSilentRequest,n.correlationId);const a=await Q(Sm,x.InitializeBaseRequest,o,r,n.correlationId)(n,t,r,o);return{...n,...a,account:e,forceRefresh:n.forceRefresh||!1}}/*! @azure/msal-browser v3.28.1 2025-01-14 */class Va extends BT{async initializeAuthorizationCodeRequest(e){this.performanceClient.addQueueMeasurement(x.StandardInteractionClientInitializeAuthorizationCodeRequest,this.correlationId);const t=await Q(yH,x.GeneratePkceCodes,this.logger,this.performanceClient,this.correlationId)(this.performanceClient,this.logger,this.correlationId),r={...e,redirectUri:e.redirectUri,code:$.EMPTY_STRING,codeVerifier:t.verifier};return e.codeChallenge=t.challenge,e.codeChallengeMethod=$.S256_CODE_CHALLENGE_METHOD,r}initializeLogoutRequest(e){this.logger.verbose("initializeLogoutRequest called",e==null?void 0:e.correlationId);const t={correlationId:this.correlationId||_o(),...e};if(e)if(e.logoutHint)this.logger.verbose("logoutHint has already been set in logoutRequest");else if(e.account){const r=this.getLogoutHintFromIdTokenClaims(e.account);r&&(this.logger.verbose("Setting logoutHint to login_hint ID Token Claim value for the account provided"),t.logoutHint=r)}else this.logger.verbose("logoutHint was not set and account was not passed into logout request, logoutHint will not be set");else this.logger.verbose("logoutHint will not be set since no logout request was configured");return!e||e.postLogoutRedirectUri!==null?e&&e.postLogoutRedirectUri?(this.logger.verbose("Setting postLogoutRedirectUri to uri set on logout request",t.correlationId),t.postLogoutRedirectUri=Le.getAbsoluteUrl(e.postLogoutRedirectUri,uo())):this.config.auth.postLogoutRedirectUri===null?this.logger.verbose("postLogoutRedirectUri configured as null and no uri set on request, not passing post logout redirect",t.correlationId):this.config.auth.postLogoutRedirectUri?(this.logger.verbose("Setting postLogoutRedirectUri to configured uri",t.correlationId),t.postLogoutRedirectUri=Le.getAbsoluteUrl(this.config.auth.postLogoutRedirectUri,uo())):(this.logger.verbose("Setting postLogoutRedirectUri to current page",t.correlationId),t.postLogoutRedirectUri=Le.getAbsoluteUrl(uo(),uo())):this.logger.verbose("postLogoutRedirectUri passed as null, not setting post logout redirect uri",t.correlationId),t}getLogoutHintFromIdTokenClaims(e){const t=e.idTokenClaims;if(t){if(t.login_hint)return t.login_hint;this.logger.verbose("The ID Token Claims tied to the provided account do not contain a login_hint claim, logoutHint will not be added to logout request")}else this.logger.verbose("The provided account does not contain ID Token Claims, logoutHint will not be added to logout request");return null}async createAuthCodeClient(e){this.performanceClient.addQueueMeasurement(x.StandardInteractionClientCreateAuthCodeClient,this.correlationId);const t=await Q(this.getClientConfiguration.bind(this),x.StandardInteractionClientGetClientConfiguration,this.logger,this.performanceClient,this.correlationId)(e);return new Jw(t,this.performanceClient)}async getClientConfiguration(e){const{serverTelemetryManager:t,requestAuthority:r,requestAzureCloudOptions:o,requestExtraQueryParameters:a,account:l}=e;this.performanceClient.addQueueMeasurement(x.StandardInteractionClientGetClientConfiguration,this.correlationId);const d=await Q(this.getDiscoveredAuthority.bind(this),x.StandardInteractionClientGetDiscoveredAuthority,this.logger,this.performanceClient,this.correlationId)({requestAuthority:r,requestAzureCloudOptions:o,requestExtraQueryParameters:a,account:l}),h=this.config.system.loggerOptions;return{authOptions:{clientId:this.config.auth.clientId,authority:d,clientCapabilities:this.config.auth.clientCapabilities,redirectUri:this.config.auth.redirectUri},systemOptions:{tokenRenewalOffsetSeconds:this.config.system.tokenRenewalOffsetSeconds,preventCorsPreflight:!0},loggerOptions:{loggerCallback:h.loggerCallback,piiLoggingEnabled:h.piiLoggingEnabled,logLevel:h.logLevel,correlationId:this.correlationId},cacheOptions:{claimsBasedCachingEnabled:this.config.cache.claimsBasedCachingEnabled},cryptoInterface:this.browserCrypto,networkInterface:this.networkClient,storageInterface:this.browserStorage,serverTelemetryManager:t,libraryInfo:{sku:Ln.MSAL_SKU,version:_u,cpu:$.EMPTY_STRING,os:$.EMPTY_STRING},telemetry:this.config.telemetry}}async initializeAuthorizationRequest(e,t){this.performanceClient.addQueueMeasurement(x.StandardInteractionClientInitializeAuthorizationRequest,this.correlationId);const r=this.getRedirectUri(e.redirectUri),o={interactionType:t},a=wr.setRequestState(this.browserCrypto,e&&e.state||$.EMPTY_STRING,o),d={...await Q(Sm,x.InitializeBaseRequest,this.logger,this.performanceClient,this.correlationId)({...e,correlationId:this.correlationId},this.config,this.performanceClient,this.logger),redirectUri:r,state:a,nonce:e.nonce||_o(),responseMode:this.config.auth.OIDCOptions.serverResponseType};if(e.loginHint||e.sid)return d;const h=e.account||this.browserStorage.getActiveAccount();if(h&&(this.logger.verbose("Setting validated request account",this.correlationId),this.logger.verbosePii(`Setting validated request account: ${h.homeAccountId}`,this.correlationId),d.account=h),!d.loginHint&&!h){const f=this.browserStorage.getLegacyLoginHint();f&&(d.loginHint=f)}return d}}/*! @azure/msal-browser v3.28.1 2025-01-14 */const TH="ContentError",FT="user_switch";/*! @azure/msal-browser v3.28.1 2025-01-14 */const bH="USER_INTERACTION_REQUIRED",SH="USER_CANCEL",IH="NO_NETWORK",AH="PERSISTENT_ERROR",kH="DISABLED",NH="ACCOUNT_UNAVAILABLE";/*! @azure/msal-browser v3.28.1 2025-01-14 */const OH=-2147186943,RH={[FT]:"User attempted to switch accounts in the native broker, which is not allowed. All new accounts must sign-in through the standard web flow first, please try again."};class Br extends lt{constructor(e,t,r){super(e,t),Object.setPrototypeOf(this,Br.prototype),this.name="NativeAuthError",this.ext=r}}function ha(n){if(n.ext&&n.ext.status&&(n.ext.status===AH||n.ext.status===kH)||n.ext&&n.ext.error&&n.ext.error===OH)return!0;switch(n.errorCode){case TH:return!0;default:return!1}}function uf(n,e,t){if(t&&t.status)switch(t.status){case NH:return tf(jw);case bH:return new br(n,e);case SH:return ie(ki);case IH:return ie(Ul)}return new Br(n,RH[n]||e,t)}/*! @azure/msal-browser v3.28.1 2025-01-14 */class $T extends Va{async acquireToken(e){this.performanceClient.addQueueMeasurement(x.SilentCacheClientAcquireToken,e.correlationId);const t=this.initializeServerTelemetryManager(it.acquireTokenSilent_silentFlow),r=await Q(this.getClientConfiguration.bind(this),x.StandardInteractionClientGetClientConfiguration,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:t,requestAuthority:e.authority,requestAzureCloudOptions:e.azureCloudOptions,account:e.account}),o=new f$(r,this.performanceClient);this.logger.verbose("Silent auth client created");try{const l=(await Q(o.acquireCachedToken.bind(o),x.SilentFlowClientAcquireCachedToken,this.logger,this.performanceClient,e.correlationId)(e))[0];return this.performanceClient.addFields({fromCache:!0},e.correlationId),l}catch(a){throw a instanceof js&&a.errorCode===gm&&this.logger.verbose("Signing keypair for bound access token not found. Refreshing bound access token and generating a new crypto keypair."),a}}logout(e){this.logger.verbose("logoutRedirect called");const t=this.initializeLogoutRequest(e);return this.clearCacheOnLogout(t==null?void 0:t.account)}}/*! @azure/msal-browser v3.28.1 2025-01-14 */class wa extends BT{constructor(e,t,r,o,a,l,d,h,f,g,v,p){var C;super(e,t,r,o,a,l,h,f,p),this.apiId=d,this.accountId=g,this.nativeMessageHandler=f,this.nativeStorageManager=v,this.silentCacheClient=new $T(e,this.nativeStorageManager,r,o,a,l,h,f,p),this.serverTelemetryManager=this.initializeServerTelemetryManager(this.apiId);const w=this.nativeMessageHandler.getExtensionId()===ya.PREFERRED_EXTENSION_ID?"chrome":(C=this.nativeMessageHandler.getExtensionId())!=null&&C.length?"unknown":void 0;this.skus=xs.makeExtraSkuString({libraryName:Ln.MSAL_SKU,libraryVersion:_u,extensionName:w,extensionVersion:this.nativeMessageHandler.getExtensionVersion()})}addRequestSKUs(e){e.extraParameters={...e.extraParameters,[J2]:this.skus}}async acquireToken(e){this.performanceClient.addQueueMeasurement(x.NativeInteractionClientAcquireToken,e.correlationId),this.logger.trace("NativeInteractionClient - acquireToken called.");const t=this.performanceClient.startMeasurement(x.NativeInteractionClientAcquireToken,e.correlationId),r=Gr();try{const o=await this.initializeNativeRequest(e);try{const f=await this.acquireTokensFromCache(this.accountId,o);return t.end({success:!0,isNativeBroker:!1,fromCache:!0}),f}catch{this.logger.info("MSAL internal Cache does not contain tokens, proceed to make a native call")}const{...a}=o,l={method:yi.GetToken,request:a},d=await this.nativeMessageHandler.sendMessage(l),h=this.validateNativeResponse(d);return await this.handleNativeResponse(h,o,r).then(f=>(t.end({success:!0,isNativeBroker:!0,requestId:f.requestId}),this.serverTelemetryManager.clearNativeBrokerErrorCode(),f)).catch(f=>{throw t.end({success:!1,errorCode:f.errorCode,subErrorCode:f.subError,isNativeBroker:!0}),f})}catch(o){throw o instanceof Br&&this.serverTelemetryManager.setNativeBrokerErrorCode(o.errorCode),o}}createSilentCacheRequest(e,t){return{authority:e.authority,correlationId:this.correlationId,scopes:_t.fromString(e.scope).asArray(),account:t,forceRefresh:!1}}async acquireTokensFromCache(e,t){if(!e)throw this.logger.warning("NativeInteractionClient:acquireTokensFromCache - No nativeAccountId provided"),Y(Yh);const r=this.browserStorage.getBaseAccountInfo({nativeAccountId:e});if(!r)throw Y(Yh);try{const o=this.createSilentCacheRequest(t,r),a=await this.silentCacheClient.acquireToken(o),l={...r,idTokenClaims:a==null?void 0:a.idTokenClaims,idToken:a==null?void 0:a.idToken};return{...a,account:l}}catch(o){throw o}}async acquireTokenRedirect(e,t){this.logger.trace("NativeInteractionClient - acquireTokenRedirect called.");const{...r}=e;delete r.onRedirectNavigate;const o=await this.initializeNativeRequest(r),a={method:yi.GetToken,request:o};try{const h=await this.nativeMessageHandler.sendMessage(a);this.validateNativeResponse(h)}catch(h){if(h instanceof Br&&(this.serverTelemetryManager.setNativeBrokerErrorCode(h.errorCode),ha(h)))throw h}this.browserStorage.setTemporaryCache(ze.NATIVE_REQUEST,JSON.stringify(o),!0);const l={apiId:it.acquireTokenRedirect,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},d=this.config.auth.navigateToLoginRequestUrl?window.location.href:this.getRedirectUri(e.redirectUri);t.end({success:!0}),await this.navigationClient.navigateExternal(d,l)}async handleRedirectPromise(e,t){if(this.logger.trace("NativeInteractionClient - handleRedirectPromise called."),!this.browserStorage.isInteractionInProgress(!0))return this.logger.info("handleRedirectPromise called but there is no interaction in progress, returning null."),null;const r=this.browserStorage.getCachedNativeRequest();if(!r)return this.logger.verbose("NativeInteractionClient - handleRedirectPromise called but there is no cached request, returning null."),e&&t&&(e==null||e.addFields({errorCode:"no_cached_request"},t)),null;const{prompt:o,...a}=r;o&&this.logger.verbose("NativeInteractionClient - handleRedirectPromise called and prompt was included in the original request, removing prompt from cached request to prevent second interaction with native broker window."),this.browserStorage.removeItem(this.browserStorage.generateCacheKey(ze.NATIVE_REQUEST));const l={method:yi.GetToken,request:a},d=Gr();try{this.logger.verbose("NativeInteractionClient - handleRedirectPromise sending message to native broker.");const h=await this.nativeMessageHandler.sendMessage(l);this.validateNativeResponse(h);const f=this.handleNativeResponse(h,a,d);this.browserStorage.setInteractionInProgress(!1);const g=await f;return this.serverTelemetryManager.clearNativeBrokerErrorCode(),g}catch(h){throw this.browserStorage.setInteractionInProgress(!1),h}}logout(){return this.logger.trace("NativeInteractionClient - logout called."),Promise.reject("Logout not implemented yet")}async handleNativeResponse(e,t,r){var g;this.logger.trace("NativeInteractionClient - handleNativeResponse called.");const o=Ri(e.id_token,Wr),a=this.createHomeAccountIdentifier(e,o),l=(g=this.browserStorage.getAccountInfoFilteredBy({nativeAccountId:t.accountId}))==null?void 0:g.homeAccountId;if(a!==l&&e.account.id!==t.accountId)throw uf(FT);const d=await this.getDiscoveredAuthority({requestAuthority:t.authority}),h=lm(this.browserStorage,d,a,Wr,o,e.client_info,void 0,o.tid,void 0,e.account.id,this.logger),f=await this.generateAuthenticationResult(e,t,o,h,d.canonicalAuthority,r);return this.cacheAccount(h),this.cacheNativeTokens(e,t,a,o,e.access_token,f.tenantId,r),f}createHomeAccountIdentifier(e,t){return Mt.generateHomeAccountId(e.client_info||$.EMPTY_STRING,pr.Default,this.logger,this.browserCrypto,t)}generateScopes(e,t){return e.scope?_t.fromString(e.scope):_t.fromString(t.scope)}async generatePopAccessToken(e,t){if(t.tokenType===je.POP&&t.signPopToken){if(e.shr)return this.logger.trace("handleNativeServerResponse: SHR is enabled in native layer"),e.shr;const r=new Na(this.browserCrypto),o={resourceRequestMethod:t.resourceRequestMethod,resourceRequestUri:t.resourceRequestUri,shrClaims:t.shrClaims,shrNonce:t.shrNonce};if(!t.keyId)throw Y(jf);return r.signPopToken(e.access_token,t.keyId,o)}else return e.access_token}async generateAuthenticationResult(e,t,r,o,a,l){const d=this.addTelemetryFromNativeResponse(e),h=e.scope?_t.fromString(e.scope):_t.fromString(t.scope),f=e.account.properties||{},g=f.UID||r.oid||r.sub||$.EMPTY_STRING,v=f.TenantId||r.tid||$.EMPTY_STRING,p=rm(o.getAccountInfo(),void 0,r,e.id_token);p.nativeAccountId!==e.account.id&&(p.nativeAccountId=e.account.id);const w=await this.generatePopAccessToken(e,t),C=t.tokenType===je.POP?je.POP:je.BEARER;return{authority:a,uniqueId:g,tenantId:v,scopes:h.asArray(),account:p,idToken:e.id_token,idTokenClaims:r,accessToken:w,fromCache:d?this.isResponseFromCache(d):!1,expiresOn:new Date(Number(l+e.expires_in)*1e3),tokenType:C,correlationId:this.correlationId,state:e.state,fromNativeBroker:!0}}cacheAccount(e){this.browserStorage.setAccount(e),this.browserStorage.removeAccountContext(e).catch(t=>{this.logger.error(`Error occurred while removing account context from browser storage. ${t}`)})}cacheNativeTokens(e,t,r,o,a,l,d){const h=cu(r,t.authority,e.id_token||"",t.clientId,o.tid||""),f=t.tokenType===je.POP?$.SHR_NONCE_VALIDITY:(typeof e.expires_in=="string"?parseInt(e.expires_in,10):e.expires_in)||0,g=d+f,v=this.generateScopes(e,t),p=lu(r,t.authority,a,t.clientId,o.tid||l,v.printScopes(),g,0,Wr,void 0,t.tokenType,void 0,t.keyId),w={idToken:h,accessToken:p};this.nativeStorageManager.saveCacheRecord(w,t.storeInCache)}addTelemetryFromNativeResponse(e){const t=this.getMATSFromResponse(e);return t?(this.performanceClient.addFields({extensionId:this.nativeMessageHandler.getExtensionId(),extensionVersion:this.nativeMessageHandler.getExtensionVersion(),matsBrokerVersion:t.broker_version,matsAccountJoinOnStart:t.account_join_on_start,matsAccountJoinOnEnd:t.account_join_on_end,matsDeviceJoin:t.device_join,matsPromptBehavior:t.prompt_behavior,matsApiErrorCode:t.api_error_code,matsUiVisible:t.ui_visible,matsSilentCode:t.silent_code,matsSilentBiSubCode:t.silent_bi_sub_code,matsSilentMessage:t.silent_message,matsSilentStatus:t.silent_status,matsHttpStatus:t.http_status,matsHttpEventCount:t.http_event_count},this.correlationId),t):null}validateNativeResponse(e){if(e.hasOwnProperty("access_token")&&e.hasOwnProperty("id_token")&&e.hasOwnProperty("client_info")&&e.hasOwnProperty("account")&&e.hasOwnProperty("scope")&&e.hasOwnProperty("expires_in"))return e;throw ow(Hf,"Response missing expected properties.")}getMATSFromResponse(e){if(e.properties.MATS)try{return JSON.parse(e.properties.MATS)}catch{this.logger.error("NativeInteractionClient - Error parsing MATS telemetry, returning null instead")}return null}isResponseFromCache(e){return typeof e.is_cached>"u"?(this.logger.verbose("NativeInteractionClient - MATS telemetry does not contain field indicating if response was served from cache. Returning false."),!1):!!e.is_cached}async initializeNativeRequest(e){this.logger.trace("NativeInteractionClient - initializeNativeRequest called");const t=e.authority||this.config.auth.authority;e.account&&await this.getDiscoveredAuthority({requestAuthority:t,requestAzureCloudOptions:e.azureCloudOptions,account:e.account});const r=new Le(t);r.validateAsUri();const{scopes:o,...a}=e,l=new _t(o||[]);l.appendScopes(Ua);const d=()=>{switch(this.apiId){case it.ssoSilent:case it.acquireTokenSilent_silentFlow:return this.logger.trace("initializeNativeRequest: silent request sets prompt to none"),Bt.NONE}if(!e.prompt){this.logger.trace("initializeNativeRequest: prompt was not provided");return}switch(e.prompt){case Bt.NONE:case Bt.CONSENT:case Bt.LOGIN:return this.logger.trace("initializeNativeRequest: prompt is compatible with native flow"),e.prompt;default:throw this.logger.trace(`initializeNativeRequest: prompt = ${e.prompt} is not compatible with native flow`),ie(bT)}},h={...a,accountId:this.accountId,clientId:this.config.auth.clientId,authority:r.urlString,scope:l.printScopes(),redirectUri:this.getRedirectUri(e.redirectUri),prompt:d(),correlationId:this.correlationId,tokenType:e.authenticationScheme,windowTitleSubstring:document.title,extraParameters:{...e.extraQueryParameters,...e.tokenQueryParameters},extendedExpiryToken:!1,keyId:e.popKid};if(h.signPopToken&&e.popKid)throw ie(IT);if(this.handleExtraBrokerParams(h),h.extraParameters=h.extraParameters||{},h.extraParameters.telemetry=ya.MATS_TELEMETRY,e.authenticationScheme===je.POP){const f={resourceRequestUri:e.resourceRequestUri,resourceRequestMethod:e.resourceRequestMethod,shrClaims:e.shrClaims,shrNonce:e.shrNonce},g=new Na(this.browserCrypto);let v;if(h.keyId)v=this.browserCrypto.base64UrlEncode(JSON.stringify({kid:h.keyId})),h.signPopToken=!1;else{const p=await Q(g.generateCnf.bind(g),x.PopTokenGenerateCnf,this.logger,this.performanceClient,e.correlationId)(f,this.logger);v=p.reqCnfString,h.keyId=p.kid,h.signPopToken=!0}h.reqCnf=v}return this.addRequestSKUs(h),h}handleExtraBrokerParams(e){var a;const t=e.extraParameters&&e.extraParameters.hasOwnProperty(am)&&e.extraParameters.hasOwnProperty(ef)&&e.extraParameters.hasOwnProperty(Ii);if(!e.embeddedClientId&&!t)return;let r="";const o=e.redirectUri;e.embeddedClientId?(e.redirectUri=this.config.auth.redirectUri,r=e.embeddedClientId):e.extraParameters&&(e.redirectUri=e.extraParameters[ef],r=e.extraParameters[Ii]),e.extraParameters={child_client_id:r,child_redirect_uri:o},(a=this.performanceClient)==null||a.addFields({embeddedClientId:r,embeddedRedirectUri:o},e.correlationId)}}/*! @azure/msal-browser v3.28.1 2025-01-14 */class Fr{constructor(e,t,r,o){this.logger=e,this.handshakeTimeoutMs=t,this.extensionId=o,this.resolvers=new Map,this.handshakeResolvers=new Map,this.messageChannel=new MessageChannel,this.windowListener=this.onWindowMessage.bind(this),this.performanceClient=r,this.handshakeEvent=r.startMeasurement(x.NativeMessageHandlerHandshake)}async sendMessage(e){this.logger.trace("NativeMessageHandler - sendMessage called.");const t={channel:ya.CHANNEL_ID,extensionId:this.extensionId,responseId:_o(),body:e};return this.logger.trace("NativeMessageHandler - Sending request to browser extension"),this.logger.tracePii(`NativeMessageHandler - Sending request to browser extension: ${JSON.stringify(t)}`),this.messageChannel.port1.postMessage(t),new Promise((r,o)=>{this.resolvers.set(t.responseId,{resolve:r,reject:o})})}static async createProvider(e,t,r){e.trace("NativeMessageHandler - createProvider called.");try{const o=new Fr(e,t,r,ya.PREFERRED_EXTENSION_ID);return await o.sendHandshakeRequest(),o}catch{const a=new Fr(e,t,r);return await a.sendHandshakeRequest(),a}}async sendHandshakeRequest(){this.logger.trace("NativeMessageHandler - sendHandshakeRequest called."),window.addEventListener("message",this.windowListener,!1);const e={channel:ya.CHANNEL_ID,extensionId:this.extensionId,responseId:_o(),body:{method:yi.HandshakeRequest}};return this.handshakeEvent.add({extensionId:this.extensionId,extensionHandshakeTimeoutMs:this.handshakeTimeoutMs}),this.messageChannel.port1.onmessage=t=>{this.onChannelMessage(t)},window.postMessage(e,window.origin,[this.messageChannel.port2]),new Promise((t,r)=>{this.handshakeResolvers.set(e.responseId,{resolve:t,reject:r}),this.timeoutId=window.setTimeout(()=>{window.removeEventListener("message",this.windowListener,!1),this.messageChannel.port1.close(),this.messageChannel.port2.close(),this.handshakeEvent.end({extensionHandshakeTimedOut:!0,success:!1}),r(ie(ET)),this.handshakeResolvers.delete(e.responseId)},this.handshakeTimeoutMs)})}onWindowMessage(e){if(this.logger.trace("NativeMessageHandler - onWindowMessage called"),e.source!==window)return;const t=e.data;if(!(!t.channel||t.channel!==ya.CHANNEL_ID)&&!(t.extensionId&&t.extensionId!==this.extensionId)&&t.body.method===yi.HandshakeRequest){const r=this.handshakeResolvers.get(t.responseId);if(!r){this.logger.trace(`NativeMessageHandler.onWindowMessage - resolver can't be found for request ${t.responseId}`);return}this.logger.verbose(t.extensionId?`Extension with id: ${t.extensionId} not installed`:"No extension installed"),clearTimeout(this.timeoutId),this.messageChannel.port1.close(),this.messageChannel.port2.close(),window.removeEventListener("message",this.windowListener,!1),this.handshakeEvent.end({success:!1,extensionInstalled:!1}),r.reject(ie(wT))}}onChannelMessage(e){this.logger.trace("NativeMessageHandler - onChannelMessage called.");const t=e.data,r=this.resolvers.get(t.responseId),o=this.handshakeResolvers.get(t.responseId);try{const a=t.body.method;if(a===yi.Response){if(!r)return;const l=t.body.response;if(this.logger.trace("NativeMessageHandler - Received response from browser extension"),this.logger.tracePii(`NativeMessageHandler - Received response from browser extension: ${JSON.stringify(l)}`),l.status!=="Success")r.reject(uf(l.code,l.description,l.ext));else if(l.result)l.result.code&&l.result.description?r.reject(uf(l.result.code,l.result.description,l.result.ext)):r.resolve(l.result);else throw ow(Hf,"Event does not contain result.");this.resolvers.delete(t.responseId)}else if(a===yi.HandshakeResponse){if(!o){this.logger.trace(`NativeMessageHandler.onChannelMessage - resolver can't be found for request ${t.responseId}`);return}clearTimeout(this.timeoutId),window.removeEventListener("message",this.windowListener,!1),this.extensionId=t.extensionId,this.extensionVersion=t.body.version,this.logger.verbose(`NativeMessageHandler - Received HandshakeResponse from extension: ${this.extensionId}`),this.handshakeEvent.end({extensionInstalled:!0,success:!0}),o.resolve(),this.handshakeResolvers.delete(t.responseId)}}catch(a){this.logger.error("Error parsing response from WAM Extension"),this.logger.errorPii(`Error parsing response from WAM Extension: ${a}`),this.logger.errorPii(`Unable to parse ${e}`),r?r.reject(a):o&&o.reject(a)}}getExtensionId(){return this.extensionId}getExtensionVersion(){return this.extensionVersion}static isNativeAvailable(e,t,r,o){if(t.trace("isNativeAvailable called"),!e.system.allowNativeBroker)return t.trace("isNativeAvailable: allowNativeBroker is not enabled, returning false"),!1;if(!r)return t.trace("isNativeAvailable: WAM extension provider is not initialized, returning false"),!1;if(o)switch(o){case je.BEARER:case je.POP:return t.trace("isNativeAvailable: authenticationScheme is supported, returning true"),!0;default:return t.trace("isNativeAvailable: authenticationScheme is not supported, returning false"),!1}return!0}}/*! @azure/msal-browser v3.28.1 2025-01-14 */class Im{constructor(e,t,r,o,a){this.authModule=e,this.browserStorage=t,this.authCodeRequest=r,this.logger=o,this.performanceClient=a}async handleCodeResponse(e,t){this.performanceClient.addQueueMeasurement(x.HandleCodeResponse,t.correlationId);let r;try{r=this.authModule.handleFragmentResponse(e,t.state)}catch(o){throw o instanceof qo&&o.subError===ki?ie(ki):o}return Q(this.handleCodeResponseFromServer.bind(this),x.HandleCodeResponseFromServer,this.logger,this.performanceClient,t.correlationId)(r,t)}async handleCodeResponseFromServer(e,t,r=!0){if(this.performanceClient.addQueueMeasurement(x.HandleCodeResponseFromServer,t.correlationId),this.logger.trace("InteractionHandler.handleCodeResponseFromServer called"),this.authCodeRequest.code=e.code,e.cloud_instance_host_name&&await Q(this.authModule.updateAuthority.bind(this.authModule),x.UpdateTokenEndpointAuthority,this.logger,this.performanceClient,t.correlationId)(e.cloud_instance_host_name,t.correlationId),r&&(e.nonce=t.nonce||void 0),e.state=t.state,e.client_info)this.authCodeRequest.clientInfo=e.client_info;else{const a=this.createCcsCredentials(t);a&&(this.authCodeRequest.ccsCredential=a)}return await Q(this.authModule.acquireToken.bind(this.authModule),x.AuthClientAcquireToken,this.logger,this.performanceClient,t.correlationId)(this.authCodeRequest,e)}createCcsCredentials(e){return e.account?{credential:e.account.homeAccountId,type:Bn.HOME_ACCOUNT_ID}:e.loginHint?{credential:e.loginHint,type:Bn.UPN}:null}}/*! @azure/msal-browser v3.28.1 2025-01-14 */function HT(n,e,t){const r=Dl(n);if(!r)throw Fw(n)?(t.error(`A ${e} is present in the iframe but it does not contain known properties. It's likely that the ${e} has been replaced by code running on the redirectUri page.`),t.errorPii(`The ${e} detected is: ${n}`),ie(tT)):(t.error(`The request has returned to the redirectUri but a ${e} is not present. It's likely that the ${e} has been removed or the page has been redirected by code running on the redirectUri page.`),ie(eT));return r}function PH(n,e,t){if(!n.state)throw ie(fm);const r=VT(e,n.state);if(!r)throw ie(nT);if(r.interactionType!==t)throw ie(rT)}/*! @azure/msal-browser v3.28.1 2025-01-14 */class MH extends Va{constructor(e,t,r,o,a,l,d,h,f,g){super(e,t,r,o,a,l,d,f,g),this.unloadWindow=this.unloadWindow.bind(this),this.nativeStorage=h}acquireToken(e){try{const r={popupName:this.generatePopupName(e.scopes||Ua,e.authority||this.config.auth.authority),popupWindowAttributes:e.popupWindowAttributes||{},popupWindowParent:e.popupWindowParent??window};return this.config.system.asyncPopups?(this.logger.verbose("asyncPopups set to true, acquiring token"),this.acquireTokenPopupAsync(e,r)):(this.logger.verbose("asyncPopup set to false, opening popup before acquiring token"),r.popup=this.openSizedPopup("about:blank",r),this.acquireTokenPopupAsync(e,r))}catch(t){return Promise.reject(t)}}logout(e){try{this.logger.verbose("logoutPopup called");const t=this.initializeLogoutRequest(e),r={popupName:this.generateLogoutPopupName(t),popupWindowAttributes:(e==null?void 0:e.popupWindowAttributes)||{},popupWindowParent:(e==null?void 0:e.popupWindowParent)??window},o=e&&e.authority,a=e&&e.mainWindowRedirectUri;return this.config.system.asyncPopups?(this.logger.verbose("asyncPopups set to true"),this.logoutPopupAsync(t,r,o,a)):(this.logger.verbose("asyncPopup set to false, opening popup"),r.popup=this.openSizedPopup("about:blank",r),this.logoutPopupAsync(t,r,o,a))}catch(t){return Promise.reject(t)}}async acquireTokenPopupAsync(e,t){var a;this.logger.verbose("acquireTokenPopupAsync called");const r=this.initializeServerTelemetryManager(it.acquireTokenPopup),o=await Q(this.initializeAuthorizationRequest.bind(this),x.StandardInteractionClientInitializeAuthorizationRequest,this.logger,this.performanceClient,this.correlationId)(e,ue.Popup);UT(o.authority);try{const l=await Q(this.initializeAuthorizationCodeRequest.bind(this),x.StandardInteractionClientInitializeAuthorizationCodeRequest,this.logger,this.performanceClient,this.correlationId)(o),d=await Q(this.createAuthCodeClient.bind(this),x.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:r,requestAuthority:o.authority,requestAzureCloudOptions:o.azureCloudOptions,requestExtraQueryParameters:o.extraQueryParameters,account:o.account}),h=Fr.isNativeAvailable(this.config,this.logger,this.nativeMessageHandler,e.authenticationScheme);let f;h&&(f=this.performanceClient.startMeasurement(x.FetchAccountIdWithNativeBroker,e.correlationId));const g=await d.getAuthCodeUrl({...o,nativeBroker:h}),v=new Im(d,this.browserStorage,l,this.logger,this.performanceClient),p=this.initiateAuthRequest(g,t);this.eventHandler.emitEvent(ge.POPUP_OPENED,ue.Popup,{popupWindow:p},null);const w=await this.monitorPopupForHash(p,t.popupWindowParent),C=Pi(HT,x.DeserializeResponse,this.logger,this.performanceClient,this.correlationId)(w,this.config.auth.OIDCOptions.serverResponseType,this.logger);if(Vr.removeThrottle(this.browserStorage,this.config.auth.clientId,l),C.accountId){if(this.logger.verbose("Account id found in hash, calling WAM for token"),f&&f.end({success:!0,isNativeBroker:!0}),!this.nativeMessageHandler)throw ie(qs);const S=new wa(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,it.acquireTokenPopup,this.performanceClient,this.nativeMessageHandler,C.accountId,this.nativeStorage,o.correlationId),{userRequestState:I}=wr.parseRequestState(this.browserCrypto,o.state);return await S.acquireToken({...o,state:I,prompt:void 0})}return await v.handleCodeResponse(C,o)}catch(l){throw(a=t.popup)==null||a.close(),l instanceof lt&&(l.setCorrelationId(this.correlationId),r.cacheFailedRequest(l)),l}}async logoutPopupAsync(e,t,r,o){var l,d,h,f;this.logger.verbose("logoutPopupAsync called"),this.eventHandler.emitEvent(ge.LOGOUT_START,ue.Popup,e);const a=this.initializeServerTelemetryManager(it.logoutPopup);try{await this.clearCacheOnLogout(e.account);const g=await Q(this.createAuthCodeClient.bind(this),x.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:a,requestAuthority:r,account:e.account||void 0});try{g.authority.endSessionEndpoint}catch{if((l=e.account)!=null&&l.homeAccountId&&e.postLogoutRedirectUri&&g.authority.protocolMode===po.OIDC){if(this.browserStorage.removeAccount((d=e.account)==null?void 0:d.homeAccountId),this.eventHandler.emitEvent(ge.LOGOUT_SUCCESS,ue.Popup,e),o){const w={apiId:it.logoutPopup,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},C=Le.getAbsoluteUrl(o,uo());await this.navigationClient.navigateInternal(C,w)}(h=t.popup)==null||h.close();return}}const v=g.getLogoutUri(e);this.eventHandler.emitEvent(ge.LOGOUT_SUCCESS,ue.Popup,e);const p=this.openPopup(v,t);if(this.eventHandler.emitEvent(ge.POPUP_OPENED,ue.Popup,{popupWindow:p},null),await this.monitorPopupForHash(p,t.popupWindowParent).catch(()=>{}),o){const w={apiId:it.logoutPopup,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},C=Le.getAbsoluteUrl(o,uo());this.logger.verbose("Redirecting main window to url specified in the request"),this.logger.verbosePii(`Redirecting main window to: ${C}`),await this.navigationClient.navigateInternal(C,w)}else this.logger.verbose("No main window navigation requested")}catch(g){throw(f=t.popup)==null||f.close(),g instanceof lt&&(g.setCorrelationId(this.correlationId),a.cacheFailedRequest(g)),this.browserStorage.setInteractionInProgress(!1),this.eventHandler.emitEvent(ge.LOGOUT_FAILURE,ue.Popup,null,g),this.eventHandler.emitEvent(ge.LOGOUT_END,ue.Popup),g}this.eventHandler.emitEvent(ge.LOGOUT_END,ue.Popup)}initiateAuthRequest(e,t){if(e)return this.logger.infoPii(`Navigate to: ${e}`),this.openPopup(e,t);throw this.logger.error("Navigate url is empty"),ie(mu)}monitorPopupForHash(e,t){return new Promise((r,o)=>{this.logger.verbose("PopupHandler.monitorPopupForHash - polling started");const a=setInterval(()=>{if(e.closed){this.logger.error("PopupHandler.monitorPopupForHash - window closed"),clearInterval(a),o(ie(ki));return}let l="";try{l=e.location.href}catch{}if(!l||l==="about:blank")return;clearInterval(a);let d="";const h=this.config.auth.OIDCOptions.serverResponseType;e&&(h===Gs.QUERY?d=e.location.search:d=e.location.hash),this.logger.verbose("PopupHandler.monitorPopupForHash - popup window is on same origin as caller"),r(d)},this.config.system.pollIntervalMilliseconds)}).finally(()=>{this.cleanPopup(e,t)})}openPopup(e,t){try{let r;if(t.popup?(r=t.popup,this.logger.verbosePii(`Navigating popup window to: ${e}`),r.location.assign(e)):typeof t.popup>"u"&&(this.logger.verbosePii(`Opening popup window to: ${e}`),r=this.openSizedPopup(e,t)),!r)throw ie(aT);return r.focus&&r.focus(),this.currentWindow=r,t.popupWindowParent.addEventListener("beforeunload",this.unloadWindow),r}catch(r){throw this.logger.error("error opening popup "+r.message),this.browserStorage.setInteractionInProgress(!1),ie(iT)}}openSizedPopup(e,{popupName:t,popupWindowAttributes:r,popupWindowParent:o}){var w,C,T,S;const a=o.screenLeft?o.screenLeft:o.screenX,l=o.screenTop?o.screenTop:o.screenY,d=o.innerWidth||document.documentElement.clientWidth||document.body.clientWidth,h=o.innerHeight||document.documentElement.clientHeight||document.body.clientHeight;let f=(w=r.popupSize)==null?void 0:w.width,g=(C=r.popupSize)==null?void 0:C.height,v=(T=r.popupPosition)==null?void 0:T.top,p=(S=r.popupPosition)==null?void 0:S.left;return(!f||f<0||f>d)&&(this.logger.verbose("Default popup window width used. Window width not configured or invalid."),f=Ln.POPUP_WIDTH),(!g||g<0||g>h)&&(this.logger.verbose("Default popup window height used. Window height not configured or invalid."),g=Ln.POPUP_HEIGHT),(!v||v<0||v>h)&&(this.logger.verbose("Default popup window top position used. Window top not configured or invalid."),v=Math.max(0,h/2-Ln.POPUP_HEIGHT/2+l)),(!p||p<0||p>d)&&(this.logger.verbose("Default popup window left position used. Window left not configured or invalid."),p=Math.max(0,d/2-Ln.POPUP_WIDTH/2+a)),o.open(e,t,`width=${f}, height=${g}, top=${v}, left=${p}, scrollbars=yes`)}unloadWindow(e){this.browserStorage.cleanRequestByInteractionType(ue.Popup),this.currentWindow&&this.currentWindow.close(),e.preventDefault()}cleanPopup(e,t){e.close(),t.removeEventListener("beforeunload",this.unloadWindow),this.browserStorage.setInteractionInProgress(!1)}generatePopupName(e,t){return`${Ln.POPUP_NAME_PREFIX}.${this.config.auth.clientId}.${e.join("-")}.${t}.${this.correlationId}`}generateLogoutPopupName(e){const t=e.account&&e.account.homeAccountId;return`${Ln.POPUP_NAME_PREFIX}.${this.config.auth.clientId}.${t}.${this.correlationId}`}}/*! @azure/msal-browser v3.28.1 2025-01-14 */class gy{constructor(e,t,r,o,a){this.authModule=e,this.browserStorage=t,this.authCodeRequest=r,this.logger=o,this.performanceClient=a}async initiateAuthRequest(e,t){if(this.logger.verbose("RedirectHandler.initiateAuthRequest called"),e){t.redirectStartPage&&(this.logger.verbose("RedirectHandler.initiateAuthRequest: redirectStartPage set, caching start page"),this.browserStorage.setTemporaryCache(ze.ORIGIN_URI,t.redirectStartPage,!0)),this.browserStorage.setTemporaryCache(ze.CORRELATION_ID,this.authCodeRequest.correlationId,!0),this.browserStorage.cacheCodeRequest(this.authCodeRequest),this.logger.infoPii(`RedirectHandler.initiateAuthRequest: Navigate to: ${e}`);const r={apiId:it.acquireTokenRedirect,timeout:t.redirectTimeout,noHistory:!1};if(typeof t.onRedirectNavigate=="function")if(this.logger.verbose("RedirectHandler.initiateAuthRequest: Invoking onRedirectNavigate callback"),t.onRedirectNavigate(e)!==!1){this.logger.verbose("RedirectHandler.initiateAuthRequest: onRedirectNavigate did not return false, navigating"),await t.navigationClient.navigateExternal(e,r);return}else{this.logger.verbose("RedirectHandler.initiateAuthRequest: onRedirectNavigate returned false, stopping navigation");return}else{this.logger.verbose("RedirectHandler.initiateAuthRequest: Navigating window to navigate url"),await t.navigationClient.navigateExternal(e,r);return}}else throw this.logger.info("RedirectHandler.initiateAuthRequest: Navigate url is empty"),ie(mu)}async handleCodeResponse(e,t){this.logger.verbose("RedirectHandler.handleCodeResponse called"),this.browserStorage.setInteractionInProgress(!1);const r=this.browserStorage.generateStateKey(t),o=this.browserStorage.getTemporaryCache(r);if(!o)throw Y(Ol,"Cached State");let a;try{a=this.authModule.handleFragmentResponse(e,o)}catch(f){throw f instanceof qo&&f.subError===ki?ie(ki):f}const l=this.browserStorage.generateNonceKey(o),d=this.browserStorage.getTemporaryCache(l);if(this.authCodeRequest.code=a.code,a.cloud_instance_host_name&&await Q(this.authModule.updateAuthority.bind(this.authModule),x.UpdateTokenEndpointAuthority,this.logger,this.performanceClient,this.authCodeRequest.correlationId)(a.cloud_instance_host_name,this.authCodeRequest.correlationId),a.nonce=d||void 0,a.state=o,a.client_info)this.authCodeRequest.clientInfo=a.client_info;else{const f=this.checkCcsCredentials();f&&(this.authCodeRequest.ccsCredential=f)}const h=await this.authModule.acquireToken(this.authCodeRequest,a);return this.browserStorage.cleanRequestByState(t),h}checkCcsCredentials(){const e=this.browserStorage.getTemporaryCache(ze.CCS_CREDENTIAL,!0);if(e)try{return JSON.parse(e)}catch{this.authModule.logger.error("Cache credential could not be parsed"),this.authModule.logger.errorPii(`Cache credential could not be parsed: ${e}`)}return null}}/*! @azure/msal-browser v3.28.1 2025-01-14 */function DH(){if(typeof window>"u"||typeof window.performance>"u"||typeof window.performance.getEntriesByType!="function")return;const n=window.performance.getEntriesByType("navigation"),e=n.length?n[0]:void 0;return e==null?void 0:e.type}class LH extends Va{constructor(e,t,r,o,a,l,d,h,f,g){super(e,t,r,o,a,l,d,f,g),this.nativeStorage=h}async acquireToken(e){const t=await Q(this.initializeAuthorizationRequest.bind(this),x.StandardInteractionClientInitializeAuthorizationRequest,this.logger,this.performanceClient,this.correlationId)(e,ue.Redirect);this.browserStorage.updateCacheEntries(t.state,t.nonce,t.authority,t.loginHint||"",t.account||null);const r=this.initializeServerTelemetryManager(it.acquireTokenRedirect),o=a=>{a.persisted&&(this.logger.verbose("Page was restored from back/forward cache. Clearing temporary cache."),this.browserStorage.cleanRequestByState(t.state),this.eventHandler.emitEvent(ge.RESTORE_FROM_BFCACHE,ue.Redirect))};try{const a=await Q(this.initializeAuthorizationCodeRequest.bind(this),x.StandardInteractionClientInitializeAuthorizationCodeRequest,this.logger,this.performanceClient,this.correlationId)(t),l=await Q(this.createAuthCodeClient.bind(this),x.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:r,requestAuthority:t.authority,requestAzureCloudOptions:t.azureCloudOptions,requestExtraQueryParameters:t.extraQueryParameters,account:t.account}),d=new gy(l,this.browserStorage,a,this.logger,this.performanceClient),h=await l.getAuthCodeUrl({...t,nativeBroker:Fr.isNativeAvailable(this.config,this.logger,this.nativeMessageHandler,e.authenticationScheme)}),f=this.getRedirectStartPage(e.redirectStartPage);return this.logger.verbosePii(`Redirect start page: ${f}`),window.addEventListener("pageshow",o),await d.initiateAuthRequest(h,{navigationClient:this.navigationClient,redirectTimeout:this.config.system.redirectNavigationTimeout,redirectStartPage:f,onRedirectNavigate:e.onRedirectNavigate||this.config.auth.onRedirectNavigate})}catch(a){throw a instanceof lt&&(a.setCorrelationId(this.correlationId),r.cacheFailedRequest(a)),window.removeEventListener("pageshow",o),this.browserStorage.cleanRequestByState(t.state),a}}async handleRedirectPromise(e="",t){const r=this.initializeServerTelemetryManager(it.handleRedirectPromise);try{if(!this.browserStorage.isInteractionInProgress(!0))return this.logger.info("handleRedirectPromise called but there is no interaction in progress, returning null."),null;const[o,a]=this.getRedirectResponse(e||"");if(!o)return this.logger.info("handleRedirectPromise did not detect a response as a result of a redirect. Cleaning temporary cache."),this.browserStorage.cleanRequestByInteractionType(ue.Redirect),DH()!=="back_forward"?t.event.errorCode="no_server_response":this.logger.verbose("Back navigation event detected. Muting no_server_response error"),null;const l=this.browserStorage.getTemporaryCache(ze.ORIGIN_URI,!0)||$.EMPTY_STRING,d=Le.removeHashFromUrl(l),h=Le.removeHashFromUrl(window.location.href);if(d===h&&this.config.auth.navigateToLoginRequestUrl)return this.logger.verbose("Current page is loginRequestUrl, handling response"),l.indexOf("#")>-1&&H$(l),await this.handleResponse(o,r);if(this.config.auth.navigateToLoginRequestUrl){if(!wm()||this.config.system.allowRedirectInIframe){this.browserStorage.setTemporaryCache(ze.URL_HASH,a,!0);const f={apiId:it.handleRedirectPromise,timeout:this.config.system.redirectNavigationTimeout,noHistory:!0};let g=!0;if(!l||l==="null"){const v=W$();this.browserStorage.setTemporaryCache(ze.ORIGIN_URI,v,!0),this.logger.warning("Unable to get valid login request url from cache, redirecting to home page"),g=await this.navigationClient.navigateInternal(v,f)}else this.logger.verbose(`Navigating to loginRequestUrl: ${l}`),g=await this.navigationClient.navigateInternal(l,f);if(!g)return await this.handleResponse(o,r)}}else return this.logger.verbose("NavigateToLoginRequestUrl set to false, handling response"),await this.handleResponse(o,r);return null}catch(o){throw o instanceof lt&&(o.setCorrelationId(this.correlationId),r.cacheFailedRequest(o)),this.browserStorage.cleanRequestByInteractionType(ue.Redirect),o}}getRedirectResponse(e){this.logger.verbose("getRedirectResponseHash called");let t=e;t||(this.config.auth.OIDCOptions.serverResponseType===Gs.QUERY?t=window.location.search:t=window.location.hash);let r=Dl(t);if(r){try{PH(r,this.browserCrypto,ue.Redirect)}catch(a){return a instanceof lt&&this.logger.error(`Interaction type validation failed due to ${a.errorCode}: ${a.errorMessage}`),[null,""]}return $$(window),this.logger.verbose("Hash contains known properties, returning response hash"),[r,t]}const o=this.browserStorage.getTemporaryCache(ze.URL_HASH,!0);return this.browserStorage.removeItem(this.browserStorage.generateCacheKey(ze.URL_HASH)),o&&(r=Dl(o),r)?(this.logger.verbose("Hash does not contain known properties, returning cached hash"),[r,o]):[null,""]}async handleResponse(e,t){const r=e.state;if(!r)throw ie(fm);const o=this.browserStorage.getCachedRequest(r);if(this.logger.verbose("handleResponse called, retrieved cached request"),e.accountId){if(this.logger.verbose("Account id found in hash, calling WAM for token"),!this.nativeMessageHandler)throw ie(qs);const h=new wa(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,it.acquireTokenPopup,this.performanceClient,this.nativeMessageHandler,e.accountId,this.nativeStorage,o.correlationId),{userRequestState:f}=wr.parseRequestState(this.browserCrypto,r);return h.acquireToken({...o,state:f,prompt:void 0}).finally(()=>{this.browserStorage.cleanRequestByState(r)})}const a=this.browserStorage.getCachedAuthority(r);if(!a)throw ie(mm);const l=await Q(this.createAuthCodeClient.bind(this),x.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:t,requestAuthority:a});return Vr.removeThrottle(this.browserStorage,this.config.auth.clientId,o),new gy(l,this.browserStorage,o,this.logger,this.performanceClient).handleCodeResponse(e,r)}async logout(e){var o,a;this.logger.verbose("logoutRedirect called");const t=this.initializeLogoutRequest(e),r=this.initializeServerTelemetryManager(it.logout);try{this.eventHandler.emitEvent(ge.LOGOUT_START,ue.Redirect,e),await this.clearCacheOnLogout(t.account);const l={apiId:it.logout,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},d=await Q(this.createAuthCodeClient.bind(this),x.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:r,requestAuthority:e&&e.authority,requestExtraQueryParameters:e==null?void 0:e.extraQueryParameters,account:e&&e.account||void 0});if(d.authority.protocolMode===po.OIDC)try{d.authority.endSessionEndpoint}catch{if((o=t.account)!=null&&o.homeAccountId){this.browserStorage.removeAccount((a=t.account)==null?void 0:a.homeAccountId),this.eventHandler.emitEvent(ge.LOGOUT_SUCCESS,ue.Redirect,t);return}}const h=d.getLogoutUri(t);if(this.eventHandler.emitEvent(ge.LOGOUT_SUCCESS,ue.Redirect,t),e&&typeof e.onRedirectNavigate=="function")if(e.onRedirectNavigate(h)!==!1){this.logger.verbose("Logout onRedirectNavigate did not return false, navigating"),this.browserStorage.getInteractionInProgress()||this.browserStorage.setInteractionInProgress(!0),await this.navigationClient.navigateExternal(h,l);return}else this.browserStorage.setInteractionInProgress(!1),this.logger.verbose("Logout onRedirectNavigate returned false, stopping navigation");else{this.browserStorage.getInteractionInProgress()||this.browserStorage.setInteractionInProgress(!0),await this.navigationClient.navigateExternal(h,l);return}}catch(l){throw l instanceof lt&&(l.setCorrelationId(this.correlationId),r.cacheFailedRequest(l)),this.eventHandler.emitEvent(ge.LOGOUT_FAILURE,ue.Redirect,null,l),this.eventHandler.emitEvent(ge.LOGOUT_END,ue.Redirect),l}this.eventHandler.emitEvent(ge.LOGOUT_END,ue.Redirect)}getRedirectStartPage(e){const t=e||window.location.href;return Le.getAbsoluteUrl(t,uo())}}/*! @azure/msal-browser v3.28.1 2025-01-14 */async function xH(n,e,t,r,o){if(e.addQueueMeasurement(x.SilentHandlerInitiateAuthRequest,r),!n)throw t.info("Navigate url is empty"),ie(mu);return o?Q(VH,x.SilentHandlerLoadFrame,t,e,r)(n,o,e,r):Pi(BH,x.SilentHandlerLoadFrameSync,t,e,r)(n)}async function UH(n,e,t,r,o,a,l){return r.addQueueMeasurement(x.SilentHandlerMonitorIframeForHash,a),new Promise((d,h)=>{e<sf&&o.warning(`system.loadFrameTimeout or system.iframeHashTimeout set to lower (${e}ms) than the default (${sf}ms). This may result in timeouts.`);const f=window.setTimeout(()=>{window.clearInterval(g),h(ie(sT))},e),g=window.setInterval(()=>{let v="";const p=n.contentWindow;try{v=p?p.location.href:""}catch{}if(!v||v==="about:blank")return;let w="";p&&(l===Gs.QUERY?w=p.location.search:w=p.location.hash),window.clearTimeout(f),window.clearInterval(g),d(w)},t)}).finally(()=>{Pi(FH,x.RemoveHiddenIframe,o,r,a)(n)})}function VH(n,e,t,r){return t.addQueueMeasurement(x.SilentHandlerLoadFrame,r),new Promise((o,a)=>{const l=KT();window.setTimeout(()=>{if(!l){a("Unable to load iframe");return}l.src=n,o(l)},e)})}function BH(n){const e=KT();return e.src=n,e}function KT(){const n=document.createElement("iframe");return n.className="msalSilentIframe",n.style.visibility="hidden",n.style.position="absolute",n.style.width=n.style.height="0",n.style.border="0",n.setAttribute("sandbox","allow-scripts allow-same-origin allow-forms"),document.body.appendChild(n),n}function FH(n){document.body===n.parentNode&&document.body.removeChild(n)}/*! @azure/msal-browser v3.28.1 2025-01-14 */class $H extends Va{constructor(e,t,r,o,a,l,d,h,f,g,v){super(e,t,r,o,a,l,h,g,v),this.apiId=d,this.nativeStorage=f}async acquireToken(e){this.performanceClient.addQueueMeasurement(x.SilentIframeClientAcquireToken,e.correlationId),!e.loginHint&&!e.sid&&(!e.account||!e.account.username)&&this.logger.warning("No user hint provided. The authorization server may need more information to complete this request.");const t={...e};t.prompt?t.prompt!==Bt.NONE&&t.prompt!==Bt.NO_SESSION&&(this.logger.warning(`SilentIframeClient. Replacing invalid prompt ${t.prompt} with ${Bt.NONE}`),t.prompt=Bt.NONE):t.prompt=Bt.NONE;const r=await Q(this.initializeAuthorizationRequest.bind(this),x.StandardInteractionClientInitializeAuthorizationRequest,this.logger,this.performanceClient,e.correlationId)(t,ue.Silent);UT(r.authority);const o=this.initializeServerTelemetryManager(this.apiId);let a;try{return a=await Q(this.createAuthCodeClient.bind(this),x.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,e.correlationId)({serverTelemetryManager:o,requestAuthority:r.authority,requestAzureCloudOptions:r.azureCloudOptions,requestExtraQueryParameters:r.extraQueryParameters,account:r.account}),await Q(this.silentTokenHelper.bind(this),x.SilentIframeClientTokenHelper,this.logger,this.performanceClient,e.correlationId)(a,r)}catch(l){if(l instanceof lt&&(l.setCorrelationId(this.correlationId),o.cacheFailedRequest(l)),!a||!(l instanceof lt)||l.errorCode!==Ln.INVALID_GRANT_ERROR)throw l;this.performanceClient.addFields({retryError:l.errorCode},this.correlationId);const d=await Q(this.initializeAuthorizationRequest.bind(this),x.StandardInteractionClientInitializeAuthorizationRequest,this.logger,this.performanceClient,e.correlationId)(t,ue.Silent);return await Q(this.silentTokenHelper.bind(this),x.SilentIframeClientTokenHelper,this.logger,this.performanceClient,this.correlationId)(a,d)}}logout(){return Promise.reject(ie(gu))}async silentTokenHelper(e,t){const r=t.correlationId;this.performanceClient.addQueueMeasurement(x.SilentIframeClientTokenHelper,r);const o=await Q(this.initializeAuthorizationCodeRequest.bind(this),x.StandardInteractionClientInitializeAuthorizationCodeRequest,this.logger,this.performanceClient,r)(t),a=await Q(e.getAuthCodeUrl.bind(e),x.GetAuthCodeUrl,this.logger,this.performanceClient,r)({...t,nativeBroker:Fr.isNativeAvailable(this.config,this.logger,this.nativeMessageHandler,t.authenticationScheme)}),l=new Im(e,this.browserStorage,o,this.logger,this.performanceClient),d=await Q(xH,x.SilentHandlerInitiateAuthRequest,this.logger,this.performanceClient,r)(a,this.performanceClient,this.logger,r,this.config.system.navigateFrameWait),h=this.config.auth.OIDCOptions.serverResponseType,f=await Q(UH,x.SilentHandlerMonitorIframeForHash,this.logger,this.performanceClient,r)(d,this.config.system.iframeHashTimeout,this.config.system.pollIntervalMilliseconds,this.performanceClient,this.logger,r,h),g=Pi(HT,x.DeserializeResponse,this.logger,this.performanceClient,this.correlationId)(f,h,this.logger);if(g.accountId){if(this.logger.verbose("Account id found in hash, calling WAM for token"),!this.nativeMessageHandler)throw ie(qs);const v=new wa(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.apiId,this.performanceClient,this.nativeMessageHandler,g.accountId,this.browserStorage,r),{userRequestState:p}=wr.parseRequestState(this.browserCrypto,t.state);return Q(v.acquireToken.bind(v),x.NativeInteractionClientAcquireToken,this.logger,this.performanceClient,r)({...t,state:p,prompt:t.prompt||Bt.NONE})}return Q(l.handleCodeResponse.bind(l),x.HandleCodeResponse,this.logger,this.performanceClient,r)(g,t)}}/*! @azure/msal-browser v3.28.1 2025-01-14 */class HH extends Va{async acquireToken(e){this.performanceClient.addQueueMeasurement(x.SilentRefreshClientAcquireToken,e.correlationId);const t=await Q(Sm,x.InitializeBaseRequest,this.logger,this.performanceClient,e.correlationId)(e,this.config,this.performanceClient,this.logger),r={...e,...t};e.redirectUri&&(r.redirectUri=this.getRedirectUri(e.redirectUri));const o=this.initializeServerTelemetryManager(it.acquireTokenSilent_silentFlow),a=await this.createRefreshTokenClient({serverTelemetryManager:o,authorityUrl:r.authority,azureCloudOptions:r.azureCloudOptions,account:r.account});return Q(a.acquireTokenByRefreshToken.bind(a),x.RefreshTokenClientAcquireTokenByRefreshToken,this.logger,this.performanceClient,e.correlationId)(r).catch(l=>{throw l.setCorrelationId(this.correlationId),o.cacheFailedRequest(l),l})}logout(){return Promise.reject(ie(gu))}async createRefreshTokenClient(e){const t=await Q(this.getClientConfiguration.bind(this),x.StandardInteractionClientGetClientConfiguration,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:e.serverTelemetryManager,requestAuthority:e.authorityUrl,requestAzureCloudOptions:e.azureCloudOptions,requestExtraQueryParameters:e.extraQueryParameters,account:e.account});return new nf(t,this.performanceClient)}}/*! @azure/msal-browser v3.28.1 2025-01-14 */class KH{constructor(e,t,r,o){this.isBrowserEnvironment=typeof window<"u",this.config=e,this.storage=t,this.logger=r,this.cryptoObj=o}loadExternalTokens(e,t,r){if(!this.isBrowserEnvironment)throw ie(pu);const o=t.id_token?Ri(t.id_token,Wr):void 0,a={protocolMode:this.config.auth.protocolMode,knownAuthorities:this.config.auth.knownAuthorities,cloudDiscoveryMetadata:this.config.auth.cloudDiscoveryMetadata,authorityMetadata:this.config.auth.authorityMetadata,skipAuthorityMetadataCache:this.config.auth.skipAuthorityMetadataCache},l=e.authority?new Xt(Xt.generateAuthority(e.authority,e.azureCloudOptions),this.config.system.networkClient,this.storage,a,this.logger,e.correlationId||_o()):void 0,d=this.loadAccount(e,r.clientInfo||t.client_info||"",o,l),h=this.loadIdToken(t,d.homeAccountId,d.environment,d.realm),f=this.loadAccessToken(e,t,d.homeAccountId,d.environment,d.realm,r),g=this.loadRefreshToken(t,d.homeAccountId,d.environment);return this.generateAuthenticationResult(e,{account:d,idToken:h,accessToken:f,refreshToken:g},o,l)}loadAccount(e,t,r,o){if(this.logger.verbose("TokenCache - loading account"),e.account){const h=Mt.createFromAccountInfo(e.account);return this.storage.setAccount(h),h}else if(!o||!t&&!r)throw this.logger.error("TokenCache - if an account is not provided on the request, authority and either clientInfo or idToken must be provided instead."),ie(pT);const a=Mt.generateHomeAccountId(t,o.authorityType,this.logger,this.cryptoObj,r),l=r==null?void 0:r.tid,d=lm(this.storage,o,a,Wr,r,t,o.hostnameAndPort,l,void 0,void 0,this.logger);return this.storage.setAccount(d),d}loadIdToken(e,t,r,o){if(!e.id_token)return this.logger.verbose("TokenCache - no id token found in response"),null;this.logger.verbose("TokenCache - loading id token");const a=cu(t,r,e.id_token,this.config.auth.clientId,o);return this.storage.setIdTokenCredential(a),a}loadAccessToken(e,t,r,o,a,l){if(t.access_token)if(t.expires_in){if(!t.scope&&(!e.scopes||!e.scopes.length))return this.logger.error("TokenCache - scopes not specified in the request or response. Cannot add token to the cache."),null}else return this.logger.error("TokenCache - no expiration set on the access token. Cannot add it to the cache."),null;else return this.logger.verbose("TokenCache - no access token found in response"),null;this.logger.verbose("TokenCache - loading access token");const d=t.scope?_t.fromString(t.scope):new _t(e.scopes),h=l.expiresOn||t.expires_in+new Date().getTime()/1e3,f=l.extendedExpiresOn||(t.ext_expires_in||t.expires_in)+new Date().getTime()/1e3,g=lu(r,o,t.access_token,this.config.auth.clientId,a,d.printScopes(),h,f,Wr);return this.storage.setAccessTokenCredential(g),g}loadRefreshToken(e,t,r){if(!e.refresh_token)return this.logger.verbose("TokenCache - no refresh token found in response"),null;this.logger.verbose("TokenCache - loading refresh token");const o=bw(t,r,e.refresh_token,this.config.auth.clientId,e.foci,void 0,e.refresh_token_expires_in);return this.storage.setRefreshTokenCredential(o),o}generateAuthenticationResult(e,t,r,o){var g,v,p;let a="",l=[],d=null,h;t!=null&&t.accessToken&&(a=t.accessToken.secret,l=_t.fromString(t.accessToken.target).asArray(),d=new Date(Number(t.accessToken.expiresOn)*1e3),h=new Date(Number(t.accessToken.extendedExpiresOn)*1e3));const f=t.account;return{authority:o?o.canonicalAuthority:"",uniqueId:t.account.localAccountId,tenantId:t.account.realm,scopes:l,account:f.getAccountInfo(),idToken:((g=t.idToken)==null?void 0:g.secret)||"",idTokenClaims:r||{},accessToken:a,fromCache:!0,expiresOn:d,correlationId:e.correlationId||"",requestId:"",extExpiresOn:h,familyId:((v=t.refreshToken)==null?void 0:v.familyId)||"",tokenType:((p=t==null?void 0:t.accessToken)==null?void 0:p.tokenType)||"",state:e.state||"",cloudGraphHostName:f.cloudGraphHostName||"",msGraphHost:f.msGraphHost||"",fromNativeBroker:!1}}}/*! @azure/msal-browser v3.28.1 2025-01-14 */class WH extends Jw{constructor(e){super(e),this.includeRedirectUri=!1}}/*! @azure/msal-browser v3.28.1 2025-01-14 */class zH extends Va{constructor(e,t,r,o,a,l,d,h,f,g){super(e,t,r,o,a,l,h,f,g),this.apiId=d}async acquireToken(e){if(!e.code)throw ie(vT);const t=await Q(this.initializeAuthorizationRequest.bind(this),x.StandardInteractionClientInitializeAuthorizationRequest,this.logger,this.performanceClient,e.correlationId)(e,ue.Silent),r=this.initializeServerTelemetryManager(this.apiId);try{const o={...t,code:e.code},a=await Q(this.getClientConfiguration.bind(this),x.StandardInteractionClientGetClientConfiguration,this.logger,this.performanceClient,e.correlationId)({serverTelemetryManager:r,requestAuthority:t.authority,requestAzureCloudOptions:t.azureCloudOptions,requestExtraQueryParameters:t.extraQueryParameters,account:t.account}),l=new WH(a);this.logger.verbose("Auth code client created");const d=new Im(l,this.browserStorage,o,this.logger,this.performanceClient);return await Q(d.handleCodeResponseFromServer.bind(d),x.HandleCodeResponseFromServer,this.logger,this.performanceClient,e.correlationId)({code:e.code,msgraph_host:e.msGraphHost,cloud_graph_host_name:e.cloudGraphHostName,cloud_instance_host_name:e.cloudInstanceHostName},t,!1)}catch(o){throw o instanceof lt&&(o.setCorrelationId(this.correlationId),r.cacheFailedRequest(o)),o}}logout(){return Promise.reject(ie(gu))}}/*! @azure/msal-browser v3.28.1 2025-01-14 */function Lr(n){const e=n==null?void 0:n.idTokenClaims;if(e!=null&&e.tfp||e!=null&&e.acr)return"B2C";if(e!=null&&e.tid){if((e==null?void 0:e.tid)==="9188040d-6c67-4c5b-b112-36a304b66dad")return"MSA"}else return;return"AAD"}function Zc(n,e){try{Tm(n)}catch(t){throw e.end({success:!1},t),t}}class yu{constructor(e){this.operatingContext=e,this.isBrowserEnvironment=this.operatingContext.isBrowserEnvironment(),this.config=e.getConfig(),this.initialized=!1,this.logger=this.operatingContext.getLogger(),this.networkClient=this.config.system.networkClient,this.navigationClient=this.config.system.navigationClient,this.redirectResponse=new Map,this.hybridAuthCodeResponses=new Map,this.performanceClient=this.config.telemetry.client,this.browserCrypto=this.isBrowserEnvironment?new Oa(this.logger,this.performanceClient):Rl,this.eventHandler=new vH(this.logger),this.browserStorage=this.isBrowserEnvironment?new lf(this.config.auth.clientId,this.config.cache,this.browserCrypto,this.logger,r$(this.config.auth),this.performanceClient):lH(this.config.auth.clientId,this.logger);const t={cacheLocation:yn.MemoryStorage,temporaryCacheLocation:yn.MemoryStorage,storeAuthStateInCookie:!1,secureCookies:!1,cacheMigrationEnabled:!1,claimsBasedCachingEnabled:!1};this.nativeInternalStorage=new lf(this.config.auth.clientId,t,this.browserCrypto,this.logger,void 0,this.performanceClient),this.tokenCache=new KH(this.config,this.browserStorage,this.logger,this.browserCrypto),this.activeSilentTokenRequests=new Map,this.trackPageVisibility=this.trackPageVisibility.bind(this),this.trackPageVisibilityWithMeasurement=this.trackPageVisibilityWithMeasurement.bind(this),this.listeningToStorageEvents=!1,this.handleAccountCacheChange=this.handleAccountCacheChange.bind(this)}static async createController(e,t){const r=new yu(e);return await r.initialize(t),r}trackPageVisibility(e){e&&(this.logger.info("Perf: Visibility change detected"),this.performanceClient.incrementFields({visibilityChangeCount:1},e))}async initialize(e){if(this.logger.trace("initialize called"),this.initialized){this.logger.info("initialize has already been called, exiting early.");return}if(!this.isBrowserEnvironment){this.logger.info("in non-browser environment, exiting early."),this.initialized=!0,this.eventHandler.emitEvent(ge.INITIALIZE_END);return}const t=(e==null?void 0:e.correlationId)||this.getRequestCorrelationId(),r=this.config.system.allowNativeBroker,o=this.performanceClient.startMeasurement(x.InitializeClientApplication,t);if(this.eventHandler.emitEvent(ge.INITIALIZE_START),r)try{this.nativeExtensionProvider=await Fr.createProvider(this.logger,this.config.system.nativeBrokerHandshakeTimeout,this.performanceClient)}catch(a){this.logger.verbose(a)}this.config.cache.claimsBasedCachingEnabled||(this.logger.verbose("Claims-based caching is disabled. Clearing the previous cache with claims"),await Q(this.browserStorage.clearTokensAndKeysWithClaims.bind(this.browserStorage),x.ClearTokensAndKeysWithClaims,this.logger,this.performanceClient,t)(this.performanceClient,t)),this.initialized=!0,this.eventHandler.emitEvent(ge.INITIALIZE_END),o.end({allowNativeBroker:r,success:!0})}async handleRedirectPromise(e){if(this.logger.verbose("handleRedirectPromise called"),xT(this.initialized),this.isBrowserEnvironment){const t=e||"";let r=this.redirectResponse.get(t);return typeof r>"u"?(r=this.handleRedirectPromiseInternal(e),this.redirectResponse.set(t,r),this.logger.verbose("handleRedirectPromise has been called for the first time, storing the promise")):this.logger.verbose("handleRedirectPromise has been called previously, returning the result from the first call"),r}return this.logger.verbose("handleRedirectPromise returns null, not browser environment"),null}async handleRedirectPromiseInternal(e){const t=this.getAllAccounts(),r=this.browserStorage.getCachedNativeRequest(),o=r&&Fr.isNativeAvailable(this.config,this.logger,this.nativeExtensionProvider)&&this.nativeExtensionProvider&&!e,a=o?r==null?void 0:r.correlationId:this.browserStorage.getTemporaryCache(ze.CORRELATION_ID,!0)||"",l=this.performanceClient.startMeasurement(x.AcquireTokenRedirect,a);this.eventHandler.emitEvent(ge.HANDLE_REDIRECT_START,ue.Redirect);let d;if(o&&this.nativeExtensionProvider){this.logger.trace("handleRedirectPromise - acquiring token from native platform");const h=new wa(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,it.handleRedirectPromise,this.performanceClient,this.nativeExtensionProvider,r.accountId,this.nativeInternalStorage,r.correlationId);d=Q(h.handleRedirectPromise.bind(h),x.HandleNativeRedirectPromiseMeasurement,this.logger,this.performanceClient,l.event.correlationId)(this.performanceClient,l.event.correlationId)}else{this.logger.trace("handleRedirectPromise - acquiring token from web flow");const h=this.createRedirectClient(a);d=Q(h.handleRedirectPromise.bind(h),x.HandleRedirectPromiseMeasurement,this.logger,this.performanceClient,l.event.correlationId)(e,l)}return d.then(h=>(h?(t.length<this.getAllAccounts().length?(this.eventHandler.emitEvent(ge.LOGIN_SUCCESS,ue.Redirect,h),this.logger.verbose("handleRedirectResponse returned result, login success")):(this.eventHandler.emitEvent(ge.ACQUIRE_TOKEN_SUCCESS,ue.Redirect,h),this.logger.verbose("handleRedirectResponse returned result, acquire token success")),l.end({success:!0,accountType:Lr(h.account)})):l.event.errorCode?l.end({success:!1}):l.discard(),this.eventHandler.emitEvent(ge.HANDLE_REDIRECT_END,ue.Redirect),h)).catch(h=>{const f=h;throw t.length>0?this.eventHandler.emitEvent(ge.ACQUIRE_TOKEN_FAILURE,ue.Redirect,null,f):this.eventHandler.emitEvent(ge.LOGIN_FAILURE,ue.Redirect,null,f),this.eventHandler.emitEvent(ge.HANDLE_REDIRECT_END,ue.Redirect),l.end({success:!1},f),h})}async acquireTokenRedirect(e){const t=this.getRequestCorrelationId(e);this.logger.verbose("acquireTokenRedirect called",t);const r=this.performanceClient.startMeasurement(x.AcquireTokenPreRedirect,t);r.add({accountType:Lr(e.account),scenarioId:e.scenarioId});const o=e.onRedirectNavigate;if(o)e.onRedirectNavigate=l=>{const d=typeof o=="function"?o(l):void 0;return d!==!1?r.end({success:!0}):r.discard(),d};else{const l=this.config.auth.onRedirectNavigate;this.config.auth.onRedirectNavigate=d=>{const h=typeof l=="function"?l(d):void 0;return h!==!1?r.end({success:!0}):r.discard(),h}}const a=this.getAllAccounts().length>0;try{dy(this.initialized,this.config),this.browserStorage.setInteractionInProgress(!0),a?this.eventHandler.emitEvent(ge.ACQUIRE_TOKEN_START,ue.Redirect,e):this.eventHandler.emitEvent(ge.LOGIN_START,ue.Redirect,e);let l;return this.nativeExtensionProvider&&this.canUseNative(e)?l=new wa(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,it.acquireTokenRedirect,this.performanceClient,this.nativeExtensionProvider,this.getNativeAccountId(e),this.nativeInternalStorage,t).acquireTokenRedirect(e,r).catch(h=>{if(h instanceof Br&&ha(h))return this.nativeExtensionProvider=void 0,this.createRedirectClient(t).acquireToken(e);if(h instanceof br)return this.logger.verbose("acquireTokenRedirect - Resolving interaction required error thrown by native broker by falling back to web flow"),this.createRedirectClient(t).acquireToken(e);throw this.browserStorage.setInteractionInProgress(!1),h}):l=this.createRedirectClient(t).acquireToken(e),await l}catch(l){throw r.end({success:!1},l),a?this.eventHandler.emitEvent(ge.ACQUIRE_TOKEN_FAILURE,ue.Redirect,null,l):this.eventHandler.emitEvent(ge.LOGIN_FAILURE,ue.Redirect,null,l),l}}acquireTokenPopup(e){const t=this.getRequestCorrelationId(e),r=this.performanceClient.startMeasurement(x.AcquireTokenPopup,t);r.add({scenarioId:e.scenarioId,accountType:Lr(e.account)});try{this.logger.verbose("acquireTokenPopup called",t),Zc(this.initialized,r),this.browserStorage.setInteractionInProgress(!0)}catch(l){return Promise.reject(l)}const o=this.getAllAccounts();o.length>0?this.eventHandler.emitEvent(ge.ACQUIRE_TOKEN_START,ue.Popup,e):this.eventHandler.emitEvent(ge.LOGIN_START,ue.Popup,e);let a;return this.canUseNative(e)?a=this.acquireTokenNative({...e,correlationId:t},it.acquireTokenPopup).then(l=>(this.browserStorage.setInteractionInProgress(!1),r.end({success:!0,isNativeBroker:!0,accountType:Lr(l.account)}),l)).catch(l=>{if(l instanceof Br&&ha(l))return this.nativeExtensionProvider=void 0,this.createPopupClient(t).acquireToken(e);if(l instanceof br)return this.logger.verbose("acquireTokenPopup - Resolving interaction required error thrown by native broker by falling back to web flow"),this.createPopupClient(t).acquireToken(e);throw this.browserStorage.setInteractionInProgress(!1),l}):a=this.createPopupClient(t).acquireToken(e),a.then(l=>(o.length<this.getAllAccounts().length?this.eventHandler.emitEvent(ge.LOGIN_SUCCESS,ue.Popup,l):this.eventHandler.emitEvent(ge.ACQUIRE_TOKEN_SUCCESS,ue.Popup,l),r.end({success:!0,accessTokenSize:l.accessToken.length,idTokenSize:l.idToken.length,accountType:Lr(l.account)}),l)).catch(l=>(o.length>0?this.eventHandler.emitEvent(ge.ACQUIRE_TOKEN_FAILURE,ue.Popup,null,l):this.eventHandler.emitEvent(ge.LOGIN_FAILURE,ue.Popup,null,l),r.end({success:!1},l),Promise.reject(l)))}trackPageVisibilityWithMeasurement(){const e=this.ssoSilentMeasurement||this.acquireTokenByCodeAsyncMeasurement;e&&(this.logger.info("Perf: Visibility change detected in ",e.event.name),e.increment({visibilityChangeCount:1}))}async ssoSilent(e){var a,l;const t=this.getRequestCorrelationId(e),r={...e,prompt:e.prompt,correlationId:t};this.ssoSilentMeasurement=this.performanceClient.startMeasurement(x.SsoSilent,t),(a=this.ssoSilentMeasurement)==null||a.add({scenarioId:e.scenarioId,accountType:Lr(e.account)}),Zc(this.initialized,this.ssoSilentMeasurement),(l=this.ssoSilentMeasurement)==null||l.increment({visibilityChangeCount:0}),document.addEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement),this.logger.verbose("ssoSilent called",t),this.eventHandler.emitEvent(ge.SSO_SILENT_START,ue.Silent,r);let o;return this.canUseNative(r)?o=this.acquireTokenNative(r,it.ssoSilent).catch(d=>{if(d instanceof Br&&ha(d))return this.nativeExtensionProvider=void 0,this.createSilentIframeClient(r.correlationId).acquireToken(r);throw d}):o=this.createSilentIframeClient(r.correlationId).acquireToken(r),o.then(d=>{var h;return this.eventHandler.emitEvent(ge.SSO_SILENT_SUCCESS,ue.Silent,d),(h=this.ssoSilentMeasurement)==null||h.end({success:!0,isNativeBroker:d.fromNativeBroker,accessTokenSize:d.accessToken.length,idTokenSize:d.idToken.length,accountType:Lr(d.account)}),d}).catch(d=>{var h;throw this.eventHandler.emitEvent(ge.SSO_SILENT_FAILURE,ue.Silent,null,d),(h=this.ssoSilentMeasurement)==null||h.end({success:!1},d),d}).finally(()=>{document.removeEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement)})}async acquireTokenByCode(e){const t=this.getRequestCorrelationId(e);this.logger.trace("acquireTokenByCode called",t);const r=this.performanceClient.startMeasurement(x.AcquireTokenByCode,t);Zc(this.initialized,r),this.eventHandler.emitEvent(ge.ACQUIRE_TOKEN_BY_CODE_START,ue.Silent,e),r.add({scenarioId:e.scenarioId});try{if(e.code&&e.nativeAccountId)throw ie(yT);if(e.code){const o=e.code;let a=this.hybridAuthCodeResponses.get(o);return a?(this.logger.verbose("Existing acquireTokenByCode request found",t),r.discard()):(this.logger.verbose("Initiating new acquireTokenByCode request",t),a=this.acquireTokenByCodeAsync({...e,correlationId:t}).then(l=>(this.eventHandler.emitEvent(ge.ACQUIRE_TOKEN_BY_CODE_SUCCESS,ue.Silent,l),this.hybridAuthCodeResponses.delete(o),r.end({success:!0,isNativeBroker:l.fromNativeBroker,accessTokenSize:l.accessToken.length,idTokenSize:l.idToken.length,accountType:Lr(l.account)}),l)).catch(l=>{throw this.hybridAuthCodeResponses.delete(o),this.eventHandler.emitEvent(ge.ACQUIRE_TOKEN_BY_CODE_FAILURE,ue.Silent,null,l),r.end({success:!1},l),l}),this.hybridAuthCodeResponses.set(o,a)),await a}else if(e.nativeAccountId)if(this.canUseNative(e,e.nativeAccountId)){const o=await this.acquireTokenNative({...e,correlationId:t},it.acquireTokenByCode,e.nativeAccountId).catch(a=>{throw a instanceof Br&&ha(a)&&(this.nativeExtensionProvider=void 0),a});return r.end({accountType:Lr(o.account),success:!0}),o}else throw ie(CT);else throw ie(_T)}catch(o){throw this.eventHandler.emitEvent(ge.ACQUIRE_TOKEN_BY_CODE_FAILURE,ue.Silent,null,o),r.end({success:!1},o),o}}async acquireTokenByCodeAsync(e){var o;return this.logger.trace("acquireTokenByCodeAsync called",e.correlationId),this.acquireTokenByCodeAsyncMeasurement=this.performanceClient.startMeasurement(x.AcquireTokenByCodeAsync,e.correlationId),(o=this.acquireTokenByCodeAsyncMeasurement)==null||o.increment({visibilityChangeCount:0}),document.addEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement),await this.createSilentAuthCodeClient(e.correlationId).acquireToken(e).then(a=>{var l;return(l=this.acquireTokenByCodeAsyncMeasurement)==null||l.end({success:!0,fromCache:a.fromCache,isNativeBroker:a.fromNativeBroker}),a}).catch(a=>{var l;throw(l=this.acquireTokenByCodeAsyncMeasurement)==null||l.end({success:!1},a),a}).finally(()=>{document.removeEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement)})}async acquireTokenFromCache(e,t){switch(this.performanceClient.addQueueMeasurement(x.AcquireTokenFromCache,e.correlationId),t){case Mn.Default:case Mn.AccessToken:case Mn.AccessTokenAndRefreshToken:const r=this.createSilentCacheClient(e.correlationId);return Q(r.acquireToken.bind(r),x.SilentCacheClientAcquireToken,this.logger,this.performanceClient,e.correlationId)(e);default:throw Y(lo)}}async acquireTokenByRefreshToken(e,t){switch(this.performanceClient.addQueueMeasurement(x.AcquireTokenByRefreshToken,e.correlationId),t){case Mn.Default:case Mn.AccessTokenAndRefreshToken:case Mn.RefreshToken:case Mn.RefreshTokenAndNetwork:const r=this.createSilentRefreshClient(e.correlationId);return Q(r.acquireToken.bind(r),x.SilentRefreshClientAcquireToken,this.logger,this.performanceClient,e.correlationId)(e);default:throw Y(lo)}}async acquireTokenBySilentIframe(e){this.performanceClient.addQueueMeasurement(x.AcquireTokenBySilentIframe,e.correlationId);const t=this.createSilentIframeClient(e.correlationId);return Q(t.acquireToken.bind(t),x.SilentIframeClientAcquireToken,this.logger,this.performanceClient,e.correlationId)(e)}async logout(e){const t=this.getRequestCorrelationId(e);return this.logger.warning("logout API is deprecated and will be removed in msal-browser v3.0.0. Use logoutRedirect instead.",t),this.logoutRedirect({correlationId:t,...e})}async logoutRedirect(e){const t=this.getRequestCorrelationId(e);return dy(this.initialized,this.config),this.browserStorage.setInteractionInProgress(!0),this.createRedirectClient(t).logout(e)}logoutPopup(e){try{const t=this.getRequestCorrelationId(e);return Tm(this.initialized),this.browserStorage.setInteractionInProgress(!0),this.createPopupClient(t).logout(e)}catch(t){return Promise.reject(t)}}async clearCache(e){if(!this.isBrowserEnvironment){this.logger.info("in non-browser environment, returning early.");return}const t=this.getRequestCorrelationId(e);return this.createSilentCacheClient(t).logout(e)}getAllAccounts(e){return uH(this.logger,this.browserStorage,this.isBrowserEnvironment,e)}getAccount(e){return dH(e,this.logger,this.browserStorage)}getAccountByUsername(e){return hH(e,this.logger,this.browserStorage)}getAccountByHomeId(e){return fH(e,this.logger,this.browserStorage)}getAccountByLocalId(e){return mH(e,this.logger,this.browserStorage)}setActiveAccount(e){gH(e,this.browserStorage)}getActiveAccount(){return pH(this.browserStorage)}async hydrateCache(e,t){this.logger.verbose("hydrateCache called");const r=Mt.createFromAccountInfo(e.account,e.cloudGraphHostName,e.msGraphHost);return this.browserStorage.setAccount(r),e.fromNativeBroker?(this.logger.verbose("Response was from native broker, storing in-memory"),this.nativeInternalStorage.hydrateCache(e,t)):this.browserStorage.hydrateCache(e,t)}async acquireTokenNative(e,t,r){if(this.logger.trace("acquireTokenNative called"),!this.nativeExtensionProvider)throw ie(qs);return new wa(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,t,this.performanceClient,this.nativeExtensionProvider,r||this.getNativeAccountId(e),this.nativeInternalStorage,e.correlationId).acquireToken(e)}canUseNative(e,t){if(this.logger.trace("canUseNative called"),!Fr.isNativeAvailable(this.config,this.logger,this.nativeExtensionProvider,e.authenticationScheme))return this.logger.trace("canUseNative: isNativeAvailable returned false, returning false"),!1;if(e.prompt)switch(e.prompt){case Bt.NONE:case Bt.CONSENT:case Bt.LOGIN:this.logger.trace("canUseNative: prompt is compatible with native flow");break;default:return this.logger.trace(`canUseNative: prompt = ${e.prompt} is not compatible with native flow, returning false`),!1}return!t&&!this.getNativeAccountId(e)?(this.logger.trace("canUseNative: nativeAccountId is not available, returning false"),!1):!0}getNativeAccountId(e){const t=e.account||this.getAccount({loginHint:e.loginHint,sid:e.sid})||this.getActiveAccount();return t&&t.nativeAccountId||""}createPopupClient(e){return new MH(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeInternalStorage,this.nativeExtensionProvider,e)}createRedirectClient(e){return new LH(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeInternalStorage,this.nativeExtensionProvider,e)}createSilentIframeClient(e){return new $H(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,it.ssoSilent,this.performanceClient,this.nativeInternalStorage,this.nativeExtensionProvider,e)}createSilentCacheClient(e){return new $T(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeExtensionProvider,e)}createSilentRefreshClient(e){return new HH(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeExtensionProvider,e)}createSilentAuthCodeClient(e){return new zH(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,it.acquireTokenByCode,this.performanceClient,this.nativeExtensionProvider,e)}addEventCallback(e,t){return this.eventHandler.addEventCallback(e,t)}removeEventCallback(e){this.eventHandler.removeEventCallback(e)}addPerformanceCallback(e){return LT(),this.performanceClient.addPerformanceCallback(e)}removePerformanceCallback(e){return this.performanceClient.removePerformanceCallback(e)}enableAccountStorageEvents(){typeof window>"u"||(this.listeningToStorageEvents?this.logger.verbose("Account storage listener already registered."):(this.logger.verbose("Adding account storage listener."),this.listeningToStorageEvents=!0,window.addEventListener("storage",this.handleAccountCacheChange)))}disableAccountStorageEvents(){typeof window>"u"||(this.listeningToStorageEvents?(this.logger.verbose("Removing account storage listener."),window.removeEventListener("storage",this.handleAccountCacheChange),this.listeningToStorageEvents=!1):this.logger.verbose("No account storage listener registered."))}handleAccountCacheChange(e){var t;try{(t=e.key)!=null&&t.includes(xt.ACTIVE_ACCOUNT_FILTERS)&&this.eventHandler.emitEvent(ge.ACTIVE_ACCOUNT_CHANGED);const r=e.newValue||e.oldValue;if(!r)return;const o=JSON.parse(r);if(typeof o!="object"||!Mt.isAccountEntity(o))return;const l=ka.toObject(new Mt,o).getAccountInfo();!e.oldValue&&e.newValue?(this.logger.info("Account was added to cache in a different window"),this.eventHandler.emitEvent(ge.ACCOUNT_ADDED,void 0,l)):!e.newValue&&e.oldValue&&(this.logger.info("Account was removed from cache in a different window"),this.eventHandler.emitEvent(ge.ACCOUNT_REMOVED,void 0,l))}catch{return}}getTokenCache(){return this.tokenCache}getLogger(){return this.logger}setLogger(e){this.logger=e}initializeWrapperLibrary(e,t){this.browserStorage.setWrapperMetadata(e,t)}setNavigationClient(e){this.navigationClient=e}getConfiguration(){return this.config}getPerformanceClient(){return this.performanceClient}isBrowserEnv(){return this.isBrowserEnvironment}getRequestCorrelationId(e){return e!=null&&e.correlationId?e.correlationId:this.isBrowserEnvironment?_o():$.EMPTY_STRING}async loginRedirect(e){const t=this.getRequestCorrelationId(e);return this.logger.verbose("loginRedirect called",t),this.acquireTokenRedirect({correlationId:t,...e||cy})}loginPopup(e){const t=this.getRequestCorrelationId(e);return this.logger.verbose("loginPopup called",t),this.acquireTokenPopup({correlationId:t,...e||cy})}async acquireTokenSilent(e){const t=this.getRequestCorrelationId(e),r=this.performanceClient.startMeasurement(x.AcquireTokenSilent,t);r.add({cacheLookupPolicy:e.cacheLookupPolicy,scenarioId:e.scenarioId}),Zc(this.initialized,r),this.logger.verbose("acquireTokenSilent called",t);const o=e.account||this.getActiveAccount();if(!o)throw ie(dT);r.add({accountType:Lr(o)});const a={clientId:this.config.auth.clientId,authority:e.authority||$.EMPTY_STRING,scopes:e.scopes,homeAccountIdentifier:o.homeAccountId,claims:e.claims,authenticationScheme:e.authenticationScheme,resourceRequestMethod:e.resourceRequestMethod,resourceRequestUri:e.resourceRequestUri,shrClaims:e.shrClaims,sshKid:e.sshKid,shrOptions:e.shrOptions},l=JSON.stringify(a),d=this.activeSilentTokenRequests.get(l);if(typeof d>"u"){this.logger.verbose("acquireTokenSilent called for the first time, storing active request",t);const h=Q(this.acquireTokenSilentAsync.bind(this),x.AcquireTokenSilentAsync,this.logger,this.performanceClient,t)({...e,correlationId:t},o).then(f=>(this.activeSilentTokenRequests.delete(l),r.end({success:!0,fromCache:f.fromCache,isNativeBroker:f.fromNativeBroker,cacheLookupPolicy:e.cacheLookupPolicy,accessTokenSize:f.accessToken.length,idTokenSize:f.idToken.length}),f)).catch(f=>{throw this.activeSilentTokenRequests.delete(l),r.end({success:!1},f),f});return this.activeSilentTokenRequests.set(l,h),{...await h,state:e.state}}else return this.logger.verbose("acquireTokenSilent has been called previously, returning the result from the first call",t),r.discard(),{...await d,state:e.state}}async acquireTokenSilentAsync(e,t){const r=()=>this.trackPageVisibility(e.correlationId);this.performanceClient.addQueueMeasurement(x.AcquireTokenSilentAsync,e.correlationId),this.eventHandler.emitEvent(ge.ACQUIRE_TOKEN_START,ue.Silent,e),e.correlationId&&this.performanceClient.incrementFields({visibilityChangeCount:0},e.correlationId),document.addEventListener("visibilitychange",r);const o=await Q(wH,x.InitializeSilentRequest,this.logger,this.performanceClient,e.correlationId)(e,t,this.config,this.performanceClient,this.logger),a=e.cacheLookupPolicy||Mn.Default;return this.acquireTokenSilentNoIframe(o,a).catch(async d=>{if(GH(d,a))if(this.activeIframeRequest)if(a!==Mn.Skip){const[f,g]=this.activeIframeRequest;this.logger.verbose(`Iframe request is already in progress, awaiting resolution for request with correlationId: ${g}`,o.correlationId);const v=this.performanceClient.startMeasurement(x.AwaitConcurrentIframe,o.correlationId);v.add({awaitIframeCorrelationId:g});const p=await f;if(v.end({success:p}),p)return this.logger.verbose(`Parallel iframe request with correlationId: ${g} succeeded. Retrying cache and/or RT redemption`,o.correlationId),this.acquireTokenSilentNoIframe(o,a);throw this.logger.info(`Iframe request with correlationId: ${g} failed. Interaction is required.`),d}else return this.logger.warning("Another iframe request is currently in progress and CacheLookupPolicy is set to Skip. This may result in degraded performance and/or reliability for both calls. Please consider changing the CacheLookupPolicy to take advantage of request queuing and token cache.",o.correlationId),Q(this.acquireTokenBySilentIframe.bind(this),x.AcquireTokenBySilentIframe,this.logger,this.performanceClient,o.correlationId)(o);else{let f;return this.activeIframeRequest=[new Promise(g=>{f=g}),o.correlationId],this.logger.verbose("Refresh token expired/invalid or CacheLookupPolicy is set to Skip, attempting acquire token by iframe.",o.correlationId),Q(this.acquireTokenBySilentIframe.bind(this),x.AcquireTokenBySilentIframe,this.logger,this.performanceClient,o.correlationId)(o).then(g=>(f(!0),g)).catch(g=>{throw f(!1),g}).finally(()=>{this.activeIframeRequest=void 0})}else throw d}).then(d=>(this.eventHandler.emitEvent(ge.ACQUIRE_TOKEN_SUCCESS,ue.Silent,d),e.correlationId&&this.performanceClient.addFields({fromCache:d.fromCache,isNativeBroker:d.fromNativeBroker},e.correlationId),d)).catch(d=>{throw this.eventHandler.emitEvent(ge.ACQUIRE_TOKEN_FAILURE,ue.Silent,null,d),d}).finally(()=>{document.removeEventListener("visibilitychange",r)})}async acquireTokenSilentNoIframe(e,t){return Fr.isNativeAvailable(this.config,this.logger,this.nativeExtensionProvider,e.authenticationScheme)&&e.account.nativeAccountId?(this.logger.verbose("acquireTokenSilent - attempting to acquire token from native platform"),this.acquireTokenNative(e,it.acquireTokenSilent_silentFlow).catch(async r=>{throw r instanceof Br&&ha(r)?(this.logger.verbose("acquireTokenSilent - native platform unavailable, falling back to web flow"),this.nativeExtensionProvider=void 0,Y(lo)):r})):(this.logger.verbose("acquireTokenSilent - attempting to acquire token from web flow"),Q(this.acquireTokenFromCache.bind(this),x.AcquireTokenFromCache,this.logger,this.performanceClient,e.correlationId)(e,t).catch(r=>{if(t===Mn.AccessToken)throw r;return this.eventHandler.emitEvent(ge.ACQUIRE_TOKEN_NETWORK_START,ue.Silent,e),Q(this.acquireTokenByRefreshToken.bind(this),x.AcquireTokenByRefreshToken,this.logger,this.performanceClient,e.correlationId)(e,t)}))}}function GH(n,e){const t=!(n instanceof br&&n.subError!==fu),r=n.errorCode===Ln.INVALID_GRANT_ERROR||n.errorCode===lo,o=t&&r||n.errorCode===xl||n.errorCode===cm,a=A$.includes(e);return o&&a}/*! @azure/msal-browser v3.28.1 2025-01-14 */async function qH(n,e){const t=new Ni(n);return await t.initialize(),yu.createController(t,e)}/*! @azure/msal-browser v3.28.1 2025-01-14 */class Am{static async createPublicClientApplication(e){const t=await qH(e);return new Am(e,t)}constructor(e,t){this.controller=t||new yu(new Ni(e))}async initialize(e){return this.controller.initialize(e)}async acquireTokenPopup(e){return this.controller.acquireTokenPopup(e)}acquireTokenRedirect(e){return this.controller.acquireTokenRedirect(e)}acquireTokenSilent(e){return this.controller.acquireTokenSilent(e)}acquireTokenByCode(e){return this.controller.acquireTokenByCode(e)}addEventCallback(e,t){return this.controller.addEventCallback(e,t)}removeEventCallback(e){return this.controller.removeEventCallback(e)}addPerformanceCallback(e){return this.controller.addPerformanceCallback(e)}removePerformanceCallback(e){return this.controller.removePerformanceCallback(e)}enableAccountStorageEvents(){this.controller.enableAccountStorageEvents()}disableAccountStorageEvents(){this.controller.disableAccountStorageEvents()}getAccount(e){return this.controller.getAccount(e)}getAccountByHomeId(e){return this.controller.getAccountByHomeId(e)}getAccountByLocalId(e){return this.controller.getAccountByLocalId(e)}getAccountByUsername(e){return this.controller.getAccountByUsername(e)}getAllAccounts(e){return this.controller.getAllAccounts(e)}handleRedirectPromise(e){return this.controller.handleRedirectPromise(e)}loginPopup(e){return this.controller.loginPopup(e)}loginRedirect(e){return this.controller.loginRedirect(e)}logout(e){return this.controller.logout(e)}logoutRedirect(e){return this.controller.logoutRedirect(e)}logoutPopup(e){return this.controller.logoutPopup(e)}ssoSilent(e){return this.controller.ssoSilent(e)}getTokenCache(){return this.controller.getTokenCache()}getLogger(){return this.controller.getLogger()}setLogger(e){this.controller.setLogger(e)}setActiveAccount(e){this.controller.setActiveAccount(e)}getActiveAccount(){return this.controller.getActiveAccount()}initializeWrapperLibrary(e,t){return this.controller.initializeWrapperLibrary(e,t)}setNavigationClient(e){this.controller.setNavigationClient(e)}getConfiguration(){return this.controller.getConfiguration()}async hydrateCache(e,t){return this.controller.hydrateCache(e,t)}clearCache(e){return this.controller.clearCache(e)}}const uh=process.env.JPLAN_WEBAPP__APP_PROXY_TENANT_NAME??"",jH=process.env.JPLAN_WEBAPP__APP_PROXY_CLIENT_ID??"",YH=process.env.JPLAN_WEBAPP__APP_PROXY_USER_FLOW??"",df=process.env.JPLAN_WEBAPP__URL_AUTH??process.env.JPLAN_WEBAPP__URL_BASE??"",JH={auth:{clientId:jH,authority:`https://${uh}.b2clogin.com/${uh}.onmicrosoft.com/${YH}`,knownAuthorities:[`${uh}.b2clogin.com`],redirectUri:process.env.JPLAN_AUTOMATION_ENVIRONMENT?`${df}/_/dashboard`:df},cache:{cacheLocation:"localStorage",storeAuthStateInCookie:!1},system:{loggerOptions:{loggerCallback:(n,e)=>{n===nt.Error&&console.error(e)},logLevel:nt.Warning}}},WT=(n,e)=>({scopes:["https://graph.microsoft.com/.default","openid","profile"],redirectStartPage:`${df}${n}`,extraQueryParameters:e}),qt=new Am(JH),py=s.ref(null);function zT(){async function n(e){var t;if(e)try{const r=e.idTokenClaims;if(!(r!=null&&r.aud))throw new Error("User audience (aud) is missing in ID token claims");const o=localStorage.getItem(`msal.token.keys.${r.aud}`);if(!o)throw new Error(`Token keys para ${r.aud} não encontrados no localStorage`);const a=JSON.parse(o),l=(t=a==null?void 0:a.idToken)==null?void 0:t[0];if(!l)throw new Error("idToken não encontrado nos token keys");const d=localStorage.getItem(l);if(!d)throw new Error(`Dados do token para ID ${l} não encontrados no localStorage`);const h=JSON.parse(d),f=h==null?void 0:h.secret;if(!f)throw new Error("Secret não encontrado nos dados do token");sessionStorage.setItem("isAuthenticated","true"),py.value=f}catch(r){console.error("Erro ao obter token de acesso:",r)}}return{jToken:py,setJToken:n}}let el=null;const nr=s.ref(null),ta=s.ref(null),GT=s.ref(Math.floor(Date.now()/1e3));hf.useIntervalFn(()=>QH(),1e3);function QH(){var r,o;if(!((o=(r=nr.value)==null?void 0:r.idTokenClaims)!=null&&o.exp))return;const n=Math.floor(Date.now()/1e3),e=300,t=nr.value.idTokenClaims.exp;GT.value=t-n-e}function km(){if(el)return el;const{setJToken:n,jToken:e}=zT(),t=s.computed(()=>!!nr.value),r=s.computed(()=>nr.value);let o;async function a(p,w){if(!t.value)switch(p){case"redirect":w&&(o=w,await h());break;case"tab":default:await l();break}}const l=async()=>new Promise((p,w)=>{try{localStorage.clear();const C=process.env.JPLAN_WEBAPP__URL_AUTH,T=window.open(C);if(!T){console.error("Failed to open authentication window"),w("Failed to open authentication window");return}const S=Date.now(),I=6e4,N=setInterval(()=>{if(Date.now()-S>I||T.closed){clearInterval(N),console.error("Authentication canceled or timeout reached."),w("Authentication canceled or timeout reached.");return}Object.keys(localStorage).some(L=>L.startsWith("msal.account.keys"))&&(clearInterval(N),d(),T.close(),p())},500)}catch(C){console.error("Error in handleRedirect:",C),w(C)}}),d=async()=>{try{await qt.initialize();const p=qt.getActiveAccount();if(p)nr.value=p;else{const w=await qt.handleRedirectPromise();w?(qt.setActiveAccount(w.account),nr.value=qt.getActiveAccount()):console.error("Falha na autenticação")}}catch(p){console.error("Erro no processo de autenticação:",p)}nr.value&&await n(nr.value)},h=async()=>{try{await qt.initialize();const p=await qt.handleRedirectPromise();if(!p||qt.getAllAccounts().length===0){const w=WT(o);await qt.loginRedirect(w);return}qt.setActiveAccount(p.account),nr.value=qt.getActiveAccount(),nr.value&&await n(nr.value),ta.value="updated"}catch(p){console.error("handleRedirect failed",p)}};async function f(){le.value=!0,ta.value="updating";try{const p=await qt.acquireTokenSilent({scopes:["https://graph.microsoft.com/.default","openid","profile"]});qt.setActiveAccount(p.account),await n(nr.value),ta.value="updated"}catch(p){console.error("Failed to refresh token, forcing new login.",p),ta.value="error",localStorage.clear(),window.location.reload()}le.value=!1}const g=async()=>{try{await qt.initialize(),localStorage.clear(),await qt.logoutRedirect({postLogoutRedirectUri:"/"})}catch(p){console.error("Logout error",p)}};s.watch(GT,async p=>{p<=0&&ta.value==="updated"&&await f()});const v=s.computed(()=>e.value);return el={isAuthenticated:t,authState:ta,account:r,token:v,refreshToken:f,handleRedirect:a,logout:g},el}const{jToken:vy}=zT(),Nm=()=>{const{toast:n}=aC(),e=gt.create({headers:{"Content-Type":"application/json"}});function t(l,d){const h={url:l.url||"",method:(l.method||"get").toUpperCase(),status:(d==null?void 0:d.status)||0};return{success:f=>n.server.success(f,h),error:f=>n.server.error(f,h),warning:f=>n.server.warning(f,h),info:f=>n.server.info(f,h)}}s.watch(vy,l=>{e.interceptors.request.use(d=>(l&&(d.headers.Authorization=`Bearer ${l}`),d))},{immediate:!0});let r=1;e.interceptors.response.use(l=>(l.notify=t(l.config,l),l),async l=>{var d;if(l.config&&(l.notify=t(l.config,l.response)),l.config&&l.config.headers){const h=l.config;if(((d=l.response)==null?void 0:d.status)===401&&r>0){r--;try{return h.headers.Authorization=`Bearer ${vy.value}`,await e(h)}catch(f){return Promise.reject(f)}}}return Promise.reject(l)});async function o({url:l,method:d,header:h={},body:f,baseURL:g}){return g&&(e.defaults.baseURL=g),e({url:l,method:d,headers:h,data:f})}async function a({url:l,method:d,header:h,body:f,baseURL:g}){return g&&(e.defaults.baseURL=g),e({url:l,method:d,headers:h,data:f})}return Object.assign(e,{_request:o,rawRequest:a})},{request:_y}=Nm(),yy=s.ref(null),Cy=s.ref("default"),dh=s.ref(null),hh=s.ref({scope_type:"org"});function Cu(){var v,p;const{handleRedirect:n,account:e,logout:t}=km();(p=(v=e.value)==null?void 0:v.idTokenClaims)==null||p.domain;const r=s.computed(()=>{var w,C;return{domain:(C=(w=e.value)==null?void 0:w.idTokenClaims)==null?void 0:C.domain,environment:Cy.value,...hh.value}}),o=s.computed(()=>hh.value);async function a(){var w;(!e.value||!((w=e.value.idTokenClaims)!=null&&w.email))&&await n();try{await l(),await d()}catch{}}async function l(){var w,C;try{const T=(C=(w=e.value)==null?void 0:w.idTokenClaims)==null?void 0:C.email;if(!T)throw new Error("Email is undefined");const S=await _y({url:`https://api.jplan.com.br/platform/user/profile/?email=${T}`,method:"GET"});dh.value=S.data??null}catch(T){console.error("Failed to fetch user profile:",T)}}async function d(){var w;try{if(!((w=dh.value)!=null&&w.email))throw new Error("User email is undefined");const C=await _y({url:"https://api.jplan.com.br/platform/user/domain/",method:"GET"});yy.value=C.data.data??[]}catch(C){console.error("Failed to fetch user domains:",C)}}function h(w){hh.value=w}function f(w){Cy.value=w,h(r.value)}async function g(w,C){const T=WT(w,{request_domain:C});await qt.loginRedirect(T)}return{__init__:a,user:dh,userDomains:yy,setEnv:f,setScope:h,changeDomain:g,session:r,scope:o,logout:t}}const XH={path:"/_/dashboard",component:()=>Promise.resolve().then(()=>require("./AuthRoute-Cn52r32r.js")),meta:{requiresAuth:!1}},ZH={path:"/jplan-auth-fail",component:()=>Promise.resolve().then(()=>require("./AuthFailRoute-DHl-IhUQ.js")),meta:{requiresAuth:!1}},{isAuthenticated:Ey,handleRedirect:e4}=km(),t4=Cu();function n4(n,e){n.addRoute(XH),n.addRoute(ZH),n.beforeEach(async(t,r,o)=>{function a(d){return d.matched.some(h=>h.meta.requiresAuth)}if(!a(t))return o();if(!Ey.value){le.value=!0;try{await e4(e,t.fullPath),await t4.__init__()}catch(d){console.error("Fail to authenticate",d),await n.push("/jplan-auth-fail")}le.value=!1}if(Ey.value){if(localStorage.getItem("returnRoute")&&localStorage.getItem("returnRoute")!==null){const d=localStorage.getItem("returnRoute")??"/";console.log("trying to go to saved route:",d),o(d),localStorage.removeItem("returnRoute");return}o()}})}const{scope:wy}=Cu();function r4(){const n=Nm(),e=s.ref({scope_type:"org"});async function t(r){e.value=r}return s.watch(wy,()=>{n.interceptors.request.use(r=>{const o=r.headers,a=o.Authorization;a&&(o.Authorization=a);const l=wy.value;return l&&(l.scope_type&&(o["j-scope-type"]=l.scope_type,l.organization&&(o["j-scope-organization"]=l.organization),l.team&&(o["j-scope-team"]=l.team)),l.environment&&(o["j-scope-environment"]=l.environment)),r})},{immediate:!0}),Object.assign(n,{setScope:t,scope:e})}function Ba(n){const e=r4();e.defaults.baseURL=n;const t=s.ref({scope_type:"org"});async function r(o){t.value=o}return s.watch(t,()=>{e.interceptors.request.use(o=>{const a=t.value;return delete o.headers["j-scope-type"],delete o.headers["j-scope-organization"],delete o.headers["j-scope-team"],a!=null&&a.scope_type&&(o.headers["j-scope-type"]=a.scope_type),a!=null&&a.organization&&(o.headers["j-scope-organization"]=a.organization),a!=null&&a.team&&(o.headers["j-scope-team"]=a.team),o})},{immediate:!0}),Object.assign(e,{setScope:r,scope:t})}function o4(){const n=Ba("https://api.jplan.com.br/management/organization"),{error:e}=sr();return{async getOrgList(t){try{const r=t?`?filter_query=${t}`:"",o=await n.get(`/list/${r}`);if(o.data.error)throw e(W.global.t("toast.error.fetch_failed",{entity:"Organization"})),new Error(o.data.error);return o.data.data}catch(r){console.error("Error in getOrgList:",r),e(W.global.t("toast.error.fetch_failed",{entity:"Organization"}));return}},async createOrg(t){var r,o;try{const a=await n.post("/item",t);return a.status>=200&&a.status<300?a:void 0}catch(a){throw console.error("Error in createOrg:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.create_failed",{entity:"Organization"})),a}},async updateOrg(t){var r,o;try{const a=await n.patch("/item",t);if(a.data.error)throw e(W.global.t("toast.error.update_failed",{entity:"Organization"})),new Error(a.data.error);return a}catch(a){throw console.error("Error in updateOrg:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.update_failed",{entity:"Organization"})),a}},async getOrg(t){var r,o;try{const a=await n.get(`/item/${t}`);if(a.data.error)throw e(W.global.t("toast.error.fetch_failed",{entity:"Organization"})),new Error(a.data.error);return a.data}catch(a){throw console.error("Error in getOrg:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.fetch_failed",{entity:"Organization"})),a}},async activateOrg(t){var r,o;try{const a=await n.post(`/item/${t}/activate`);if(a.data.error)throw e(W.global.t("toast.error.activate_failed",{entity:"Organization"})),new Error(a.data.error)}catch(a){throw console.error("Error in activateOrg:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.activate_failed",{entity:"Organization"})),a}},async deactivateOrg(t){var r,o;try{const a=await n.post(`/item/${t}/deactivate`);if(a.data.error)throw e(W.global.t("toast.error.deactivate_failed",{entity:"Organization"})),new Error(a.data.error)}catch(a){throw console.error("Error in deactivateOrg:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.deactivate_failed",{entity:"Organization"})),a}}}}const Bo=o4();function i4(){const n=Ba("https://api.jplan.com.br/management/branch/"),{error:e}=sr();return{async getBranchList(t){try{const r=t?`?filter_query=${t}`:"",o=await n.get(`/list/${r}`);if(o.data.error){e(W.global.t("toast.error.fetch_failed",{entity:"Branch"}));return}return o.data.data}catch(r){console.error("Error in getBranchList:",r),e(W.global.t("toast.error.fetch_failed",{entity:"Branch"}))}},async createBranch(t){var r,o;try{const a=await n.post("/item",t);return a.status>=200&&a.status<300?a:void 0}catch(a){console.error("Error in createBranch:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.create_failed",{entity:"Branch"}))}},async updateBranch(t){var r,o;try{const a=await n.patch("/item",t);if(a.data.error){e(a.data.error||W.global.t("toast.error.update_failed",{entity:"Branch"}));return}return a}catch(a){console.error("Error in updateBranch:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.update_failed",{entity:"Branch"}))}},async getBranch(t){var r,o;try{const a=await n.get(`/item/${t}`);if(a.data.error){e(a.data.error||W.global.t("toast.error.fetch_failed",{entity:"Branch"}));return}return a.data}catch(a){console.error("Error in getBranch:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.fetch_failed",{entity:"Branch"}))}},async activateBranch(t){var r,o;try{const a=await n.post(`/item/${t}/activate`);if(a.data.error){e(a.data.error||W.global.t("toast.error.activate_failed",{entity:"Branch"}));return}}catch(a){console.error("Error in activateBranch:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.activate_failed",{entity:"Branch"}))}},async deactivateBranch(t){var r,o;try{const a=await n.post(`/item/${t}/deactivate`);if(a.data.error){e(a.data.error||W.global.t("toast.error.deactivate_failed",{entity:"Branch"}));return}}catch(a){console.error("Error in deactivateBranch:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.deactivate_failed",{entity:"Branch"}))}}}}const Fo=i4();function a4(){const n=Ba("https://api.jplan.com.br/management/team"),{error:e}=sr();return{async getTeamList(t){try{const r=t?`?filter_query=${t}`:"",o=await n.get(`/list/${r}`);if(o.data.error)throw e(W.global.t("toast.error.fetch_failed",{entity:"Team"})),new Error(o.data.error);return o.data.data}catch(r){console.error("Error in getTeamList:",r),e(W.global.t("toast.error.fetch_failed",{entity:"Team"}));return}},async createTeam(t){var r,o;try{const a=await n.post("/item",t);if(a.data.error)throw e(W.global.t("toast.error.create_failed",{entity:"Team"})),new Error(a.data.error);return a}catch(a){throw console.error("Error in createTeam:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.create_failed",{entity:"Team"})),a}},async updateTeam(t){var r,o;try{const a=await n.patch("/item",t);return a.status>=200&&a.status<300?a:void 0}catch(a){throw console.error("Error in updateTeam:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.update_failed",{entity:"Team"})),a}},async getTeam(t){var r,o;try{const a=await n.get(`/item/${t}`);return a.data.error&&e(W.global.t("toast.error.fetch_failed",{entity:"Team"})),a.data}catch(a){console.error("Error in getTeam:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.fetch_failed",{entity:"Team"}));return}},async activateTeam(t){var r,o;try{const a=await n.post(`/item/${t}/activate`);if(a.data.error)throw e(W.global.t("toast.error.activate_failed",{entity:"Team"})),new Error(a.data.error)}catch(a){throw console.error("Error in activateTeam:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.activate_failed",{entity:"Team"})),a}},async deactivateTeam(t){var r,o;try{const a=await n.post(`/item/${t}/deactivate`);if(a.data.error)throw e(W.global.t("toast.error.deactivate_failed",{entity:"Team"})),new Error(a.data.error)}catch(a){throw console.error("Error in deactivateTeam:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.deactivate_failed",{entity:"Team"})),a}},async getTeamUserList(t,r){try{const o=r?`?filter_query=${r}`:"",a=await n.get(`/item/${t}/user/list/${o}`);if(a.data.error)throw e(W.global.t("toast.error.fetch_failed",{entity:"User"})),new Error(a.data.error);return a.data.data}catch(o){console.error("Error in getTeamUserList:",o),e(W.global.t("toast.error.fetch_failed",{entity:"User"}));return}},async linkManageUser(t,r){try{const o=await n.post(`/item/${t}/user/item/`,r);if(o.data.error)throw e(W.global.t("toast.error.link_failed",{entity:"User"})),new Error(o.data.error);return o.data}catch(o){console.error("Error in link User:",o),e(W.global.t("toast.error.link_failed",{entity:"User"}));return}},async updateManageUser(t,r){try{const o=await n.patch(`/item/${t}/user/item/`,r);if(o.data.error)throw e(W.global.t("toast.error.update_failed",{entity:"User"})),new Error(o.data.error);return o.data.data}catch(o){throw console.error("Error in update User:",o),e(W.global.t("toast.error.update_failed",{entity:"User"})),o}},async getManageUser(t,r,o){try{const a=o?`?filter_query=${o}`:"",l=await n.get(`/item/${t}/user/item/${r}/${a}`);if(l.data.error)throw e(W.global.t("toast.error.fetch_failed",{entity:"User"})),new Error(l.data.error);return l.data.data}catch(a){console.error("Error in getUser:",a),e(W.global.t("toast.error.fetch_failed",{entity:"User"}));return}},async unlinkManageUser(t,r,o){try{const a=o?`?filter_query=${o}`:"";await n.delete(`/item/${t}/user/item/${r}/${a}`)}catch(a){throw console.error("Error in unlink User:",a),e(W.global.t("toast.error.unlink_failed",{entity:"User"})),a}}}}const Dn=a4();let tl=!1;const fh=s.ref(!1),Yn=s.ref([]),Ty=s.ref([]),ht=s.ref(null),na=s.ref([]),ra=s.ref([]),qT=()=>{const n=sr(),e=async C=>{fh.value=!0;const T=C?`_active eq true and ${C}`:"_active eq true",S=await Bo.getOrgList(T);S&&(Yn.value=S,tl=!0),fh.value=!1},t=async C=>{var T;return(T=Yn.value)!=null&&T.length||await e(C),Yn.value};function r(C){if(!Yn.value)throw new Error("Data not stored yet");const T=xa(Yn.value,C,["name","description"]);return C!==""?T:Yn.value}const o=C=>{Ty.value=C},a=C=>{ht.value=Oi.cloneDeep(C)},l=async C=>await Bo.getOrg(C),d=async()=>{if(ht.value!=null){const C=await Bo.createOrg(ht.value);return C!=null&&C.data.created_at&&(n.success(W.global.t("toast.success.create_success",{entity:"Organization"})),tl&&Yn.value.push(C.data)),C==null?void 0:C.data}},h=async()=>{if(le.value=!0,ht.value&&ht.value.__id){const C=await Bo.updateOrg(ht.value);if(tl&&(C!=null&&C.data.__id)){const T=Yn.value.findIndex(S=>S.__id===C.data.__id);return T!==-1?(Yn.value[T]=C.data,n.success(W.global.t("toast.success.update_success",{entity:"Organization"}))):n.error(W.global.t("toast.error.update_failed",{entity:"Organization"})),le.value=!1,C.data}}else le.value=!1,n.error(W.global.t("toast.error.update_failed",{entity:"Organization"}))},f=async()=>{if(le.value=!0,ht.value&&ht.value.created_at){if(await Bo.deactivateOrg(ht.value.__id),tl){const C=Yn.value.findIndex(T=>{var S;return T.__id===((S=ht.value)==null?void 0:S.__id)});if(C!==-1)return Yn.value.splice(C,1),ht.value;n.error(W.global.t("toast.error.deactivate_failed",{entity:"Organization"}))}le.value=!1}};async function g(C){le.value=!0;try{if(ht.value&&ht.value.__id){const T={...C,organization:ht.value.__id};if(!await Fo.updateBranch(T)){le.value=!1;return}if(na.value.findIndex(N=>N.__id===C.__id)===-1)return n.success(W.global.t("toast.success.link_success",{entity:"Branch"})),na.value.push(T),T;n.info(W.global.t("toast.info.already_linked",{entity:"Branch"}))}}catch(T){console.error(T)}finally{le.value=!1}}async function v(C){if(le.value=!0,ht.value&&ht.value.__id){const T={...C,organization:null};if(!await Fo.updateBranch(T)){le.value=!1;return}const I=na.value.findIndex(N=>N.__id===C.__id);if(I!==-1)return na.value.splice(I,1),le.value=!1,na.value;throw new Error("Item not found to remove")}le.value=!1}async function p(C){le.value=!0;try{if(ht.value&&ht.value.__id){const T={...C,organization:ht.value.__id};if(!await Dn.updateTeam(T)){le.value=!1;return}if(ra.value.findIndex(N=>N.__id===C.__id)===-1)return n.success(W.global.t("toast.success.link_success",{entity:"Team"})),ra.value.push(T),T;n.info(W.global.t("toast.info.already_linked",{entity:"Team"}))}}catch(T){console.error(T)}finally{le.value=!1}}async function w(C){if(le.value=!0,ht.value&&ht.value.__id){const T={...C,organization:null};if(!await Dn.updateTeam(T)){le.value=!1;return}const I=ra.value.findIndex(N=>N.__id===C.__id);if(I!==-1)return ra.value.splice(I,1),le.value=!1,ra.value;throw new Error("Item not found to remove")}le.value=!1}return{data:Yn,loading:fh,columns:Ty,item:ht,filterData:r,__init__:e,getData:t,setColumns:o,setItem:a,getItem:l,createItem:d,updateItem:h,removeItem:f,orgBranches:na,orgTeams:ra,linkBranch:g,unlinkBranch:v,linkTeam:p,unlinkTeam:w}};let nl=!1;const Jn=s.ref([]),by=s.ref([]),Ot=s.ref(null),mh=s.ref(!1),oa=s.ref([]),jT=()=>{const n=sr(),e=async p=>{mh.value=!0;const w=p?`_active eq true and ${p}`:"_active eq true",C=await Dn.getTeamList(w);C&&(Jn.value=C,nl=!0),mh.value=!1},t=async p=>(Jn.value.length||await e(p),Jn.value);function r(p){if(!Jn.value)throw new Error("Data not stored yet");const w=xa(Jn.value,p,["name","description"]);return p!==""?w:Jn.value}const o=p=>{by.value=p},a=p=>{Ot.value=Oi.cloneDeep(p)},l=async p=>await Dn.getTeam(p),d=async()=>{if(Ot.value!=null){const p=await Dn.createTeam(Ot.value);return p!=null&&p.data.created_at&&(n.success(W.global.t("toast.success.create_success",{entity:"Team"})),nl&&Jn.value.push(p.data)),p==null?void 0:p.data}},h=async()=>{if(le.value=!0,Ot.value&&Ot.value.__id){const p=await Dn.updateTeam(Ot.value);if(nl&&(p!=null&&p.data.__id)){const w=Jn.value.findIndex(C=>C.__id===p.data.__id);return w!==-1?(Jn.value[w]=p.data,n.success(W.global.t("toast.success.update_success",{entity:"Team"}))):n.error(W.global.t("toast.error.update_failed",{entity:"Team"})),p.data}}else n.error(W.global.t("toast.error.update_failed",{entity:"Team"}))},f=async()=>{if(Ot.value&&Ot.value.created_at&&(await Dn.deactivateTeam(Ot.value.__id),nl)){const p=Jn.value.findIndex(w=>{var C;return w.__id===((C=Ot.value)==null?void 0:C.__id)});if(p!==-1)return Jn.value.splice(p,1),Ot.value;n.error(W.global.t("toast.error.deactivate_failed",{entity:"Team"}))}};async function g(p){var w;if(le.value=!0,(w=Ot.value)!=null&&w.__id)if(oa.value.findIndex(T=>T.__id===p.__id)===-1)try{const T=await Dn.linkManageUser(Ot.value.__id,{team:Ot.value.__id,user:p.__id,role:"string",joined_at:"string",comments:"string"}),S=await Dn.getTeamUserList(Ot.value.__id);return S&&(oa.value=S),n.success(W.global.t("toast.success.link_success",{entity:"User"})),T}catch(T){console.error(T),n.error(W.global.t("toast.error.link_failed",{entity:"User"}))}finally{le.value=!1}else n.info(W.global.t("toast.info.already_linked",{entity:"User"}));else console.warn("No item selected or item ID is missing."),n.info(W.global.t("toast.info.select_valid_item"));le.value=!1}async function v(p){if(le.value=!0,Ot.value&&Ot.value.__id){const w=oa.value.findIndex(C=>C.__id===p);if(w!==-1)return await Dn.unlinkManageUser(Ot.value.__id,p),oa.value.splice(w,1),le.value=!1,oa.value;throw new Error("Item not found to remove")}le.value=!1}return{data:Jn,loading:mh,columns:by,item:Ot,usersTeam:oa,__init__:e,getData:t,filterData:r,setColumns:o,setItem:a,getItem:l,createItem:d,updateItem:h,removeItem:f,linkUser:g,unlinkUser:v}},YT=s.defineComponent({__name:"GlobalScopeFilter",setup(n){var T,S,I;const{openDialog:e}=Ra("global-scope__J-"),{user:t,scope:r,session:o,setScope:a}=Cu(),{getData:l,data:d}=qT(),{getData:h,data:f}=jT(),g=s.ref(!1);s.onBeforeMount(async()=>{g.value=!0,await l(),await h(),g.value=!1});const v=s.ref({scope_type:(T=r.value)==null?void 0:T.scope_type,organization:((S=r.value)==null?void 0:S.organization)??"org",team:(I=r.value)==null?void 0:I.team});function p(){var N,D,L;v.value={...r.value,scope_type:(N=r.value)==null?void 0:N.scope_type,organization:((D=r.value)==null?void 0:D.organization)??"",team:(L=r.value)==null?void 0:L.team},e()}const w=s.computed(()=>{var N;switch((N=r.value)==null?void 0:N.scope_type){case"user":return EF;case"org":return yF;case"team":return wF;default:return CF}});async function C(){var N;((N=r.value)==null?void 0:N.scope_type)!==""&&a(v.value)}return(N,D)=>(s.openBlock(),s.createElementBlock(s.Fragment,null,[s.createVNode(Me.VBtn,{onClick:p,icon:"",class:"text-secondary",color:"surface",rounded:"sm",size:"small",variant:"flat"},{default:s.withCtx(()=>[(s.openBlock(),s.createBlock(s.resolveDynamicComponent(w.value),{size:"20"}))]),_:1}),s.createVNode(s.unref(Pa),{loading:g.value,title:s.unref(W).global.t("dialogs.scope.title"),"dd-id":"global-scope__J-",onOnSave:C},{default:s.withCtx(()=>[s.createElementVNode("div",null,[s.createVNode(xe.VRow,null,{default:s.withCtx(()=>[s.createVNode(xe.VCol,{cols:"4",class:"d-flex flex-row align-center"},{default:s.withCtx(()=>[s.createVNode(Tt.VListItem,null,{default:s.withCtx(()=>[s.createVNode(Tt.VListItemTitle,null,{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(s.unref(W).global.t("dialogs.scope.user")),1)]),_:1}),s.createVNode(Tt.VListItemSubtitle,null,{default:s.withCtx(()=>{var L;return[s.createTextVNode(s.toDisplayString(((L=s.unref(t))==null?void 0:L.name)||s.unref(W).global.t("dialogs.scope.unknownUser")),1)]}),_:1})]),_:1})]),_:1}),s.createVNode(xe.VCol,{cols:"4"},{default:s.withCtx(()=>[s.createVNode(Tt.VListItem,null,{default:s.withCtx(()=>[s.createVNode(Tt.VListItemTitle,null,{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(s.unref(W).global.t("dialogs.scope.environment")),1)]),_:1}),s.createVNode(Tt.VListItemSubtitle,null,{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(s.unref(o).domain),1)]),_:1})]),_:1})]),_:1}),s.createVNode(xe.VCol,{cols:"4"},{default:s.withCtx(()=>[s.createVNode(Tt.VListItem,null,{default:s.withCtx(()=>[s.createVNode(Tt.VListItemTitle,null,{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(s.unref(W).global.t("dialogs.scope.environment")),1)]),_:1}),s.createVNode(Tt.VListItemSubtitle,null,{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(s.unref(o).environment),1)]),_:1})]),_:1})]),_:1})]),_:1}),s.createVNode(UR.VBtnToggle,{density:"compact",variant:"outlined",modelValue:v.value.scope_type,"onUpdate:modelValue":D[0]||(D[0]=L=>v.value.scope_type=L),class:"d-flex justify-center my-4"},{default:s.withCtx(()=>[s.createVNode(Me.VBtn,{value:"org",label:s.unref(W).global.t("dialogs.scope.organizational"),color:"secondary"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(s.unref(W).global.t("dialogs.scope.organizational")),1)]),_:1},8,["label"]),s.createVNode(Me.VBtn,{value:"team",label:s.unref(W).global.t("dialogs.scope.team"),color:"secondary"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(s.unref(W).global.t("dialogs.scope.team")),1)]),_:1},8,["label"]),s.createVNode(Me.VBtn,{value:"user",label:s.unref(W).global.t("dialogs.scope.user"),color:"secondary"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(s.unref(W).global.t("dialogs.scope.user")),1)]),_:1},8,["label"]),s.createVNode(Me.VBtn,{value:"",label:s.unref(W).global.t("dialogs.scope.none"),color:"lightext"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(s.unref(W).global.t("dialogs.scope.none")),1)]),_:1},8,["label"])]),_:1},8,["modelValue"]),s.createElementVNode("div",null,[s.createVNode(Ei.VLabel,{class:"text-subtitle-1 text-high-emphasis mb-2"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(s.unref(W).global.t("dialogs.scope.organization")),1)]),_:1}),s.createVNode(Ko.VSelect,{items:s.unref(d),"item-title":"name","item-value":"__id",variant:"solo","bg-color":"containerBg",rounded:"false",placeholder:s.unref(W).global.t("dialogs.scope.selectOrganization"),class:"min-w-50",modelValue:v.value.organization,"onUpdate:modelValue":D[1]||(D[1]=L=>v.value.organization=L),clearable:""},null,8,["items","placeholder","modelValue"]),s.createVNode(Ei.VLabel,{class:"text-subtitle-1 text-high-emphasis mb-2"},{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(s.unref(W).global.t("dialogs.scope.team")),1)]),_:1}),s.createVNode(Ko.VSelect,{items:s.unref(f),"item-title":"name","item-value":"__id",variant:"solo","bg-color":"containerBg",rounded:"false",placeholder:s.unref(W).global.t("dialogs.scope.selectTeam"),class:"min-w-50",modelValue:v.value.team,"onUpdate:modelValue":D[2]||(D[2]=L=>v.value.team=L),clearable:""},null,8,["items","placeholder","modelValue"])])])]),_:1},8,["loading","title"])],64))}}),s4={},c4={class:"double-ring-spinner-container"};function l4(n,e){return s.openBlock(),s.createElementBlock("div",c4,e[0]||(e[0]=[s.createElementVNode("div",{class:"spinner-loading"},[s.createElementVNode("div"),s.createElementVNode("div"),s.createElementVNode("div",null,[s.createElementVNode("div")]),s.createElementVNode("div",null,[s.createElementVNode("div")])],-1)]))}const JT=Qo(s4,[["render",l4],["__scopeId","data-v-00d7a69f"]]),u4={key:0,class:"_jspinner-overlay_jj"},QT=s.defineComponent({__name:"GlobalSpinner",setup(n){return(e,t)=>s.unref(le)?(s.openBlock(),s.createElementBlock("div",u4,t[0]||(t[0]=[s.createElementVNode("div",{class:"j-double-ring-spinner-container"},[s.createElementVNode("div",{class:"j-global-spinner-loading"},[s.createElementVNode("div"),s.createElementVNode("div"),s.createElementVNode("div",null,[s.createElementVNode("div")]),s.createElementVNode("div",null,[s.createElementVNode("div")])])],-1)]))):s.createCommentVNode("",!0)}}),XT=s.defineComponent({__name:"SubMenu",props:{title:{}},setup(n,{expose:e}){return e({props:n}),(r,o)=>(s.openBlock(),s.createBlock(Tt.VListItem,{onClick:o[0]||(o[0]=()=>{}),density:"compact"},{append:s.withCtx(()=>[s.createVNode(s.unref(TF))]),default:s.withCtx(()=>[s.createVNode(Tt.VListItemTitle,null,{default:s.withCtx(()=>[s.createTextVNode(s.toDisplayString(r.title),1)]),_:1}),s.createVNode(Fl.VMenu,{activator:"parent","open-on-hover":"",submenu:"",density:"compact"},{default:s.withCtx(()=>[s.renderSlot(r.$slots,"default")]),_:3})]),_:3}))}}),d4=Object.freeze(Object.defineProperty({__proto__:null,AvatarPicture:JC,ColumnSettingsDialog:xf,ConfirmDialog:jC,ContextMenu:QC,CopyButton:Us,DeleteAllBtn:Yl,DotsMenu:qC,EditButton:GC,FormHeadless:nw,FormMetadata:au,GlobalScopeFilter:YT,GlobalSpinner:QT,JAutocomplete:YE,JAvatar:YC,JBtn:Oy,JDialog:Pa,JForm:ZE,JIconBtn:Ny,JNumberField:jE,JSelect:qE,JTextArea:JE,JTextField:wE,ParentCard:Jl,SearchFilter:Hs,SpinnerLoader:JT,SubMenu:XT,TabFormHeader:ew,TabFormHeaderV2:tw,TableAdvanced:yE,TableCard:Uf,TableCardsView:EE,TableFlash:ZC,TableHeader:CE,TableHeaderFlash:mE,UiTable:XC,UiTableFooter:Df},Symbol.toStringTag,{value:"Module"})),h4=h0(),f4={transition:"Vue-Toastification__fade",maxToasts:20,newestOnTop:!0},m4="https://app-files.jplan.com.br/pub/resources/assets/thumbs/empty_list.svg";let gh=!1;const ph=s.ref(!1),Qn=s.ref([]),Sy=s.ref([]),Kt=s.ref(null),ia=s.ref([]),g4=()=>{const n=sr(),e=async p=>{ph.value=!0;const w=p?`_active eq true and ${p}`:"_active eq true",C=await Fo.getBranchList(w);C&&(Qn.value=C,gh=!0),ph.value=!1},t=async p=>(Qn.value.length||await e(p),Qn.value);function r(p){if(!Qn.value)throw new Error("Data not stored yet");const w=xa(Qn.value,p,["name","description"]);return p!==""?w:Qn.value}const o=p=>{Sy.value=p},a=p=>{Kt.value=Oi.cloneDeep(p)},l=async p=>await Fo.getBranch(p),d=async()=>{if(Kt.value!=null){const p=await Fo.createBranch(Kt.value);return p!=null&&p.data.created_at&&(n.success(W.global.t("toast.success.create_success",{entity:"Branch"})),gh&&Qn.value.push(p.data)),p==null?void 0:p.data}},h=async()=>{if(Kt.value&&Kt.value.__id){const p=await Fo.updateBranch(Kt.value);if(gh&&p){const w=Qn.value.findIndex(C=>C.__id===p.data.__id);return w!==-1?(Qn.value[w]=p.data,n.success(W.global.t("toast.success.update_success",{entity:"Branch"}))):n.error(W.global.t("toast.error.update_failed",{entity:"Branch"})),p}}else n.error(W.global.t("toast.error.update_failed",{entity:"Branch"}))},f=async()=>{if(Kt.value&&Kt.value.created_at){await Fo.deactivateBranch(Kt.value.__id);const p=Qn.value.findIndex(w=>{var C;return w.__id===((C=Kt.value)==null?void 0:C.__id)});if(p!==-1)return Qn.value.splice(p,1),Kt.value;n.error(W.global.t("toast.error.deactivate_failed",{entity:"Branch"}))}};async function g(p){le.value=!0;try{if(Kt.value&&Kt.value.__id){const w={...p,branch:Kt.value.__id};if(!await Dn.updateTeam(w)){n.error(W.global.t("toast.error.link_failed",{entity:"Team"}));return}if(ia.value.findIndex(S=>S.__id===p.__id)===-1)return n.success(W.global.t("toast.success.link_success",{entity:"Team"})),ia.value.push(w),w;n.info(W.global.t("toast.info.already_linked",{entity:"Team"}))}else throw new Error("Item is not defined")}catch(w){console.error(w)}finally{le.value=!1}}async function v(p){if(le.value=!0,Kt.value&&Kt.value.__id){const w={...p,branch:null};if(!await Dn.updateTeam(w))return;const T=ia.value.findIndex(S=>S.__id===p.__id);if(T!==-1)return ia.value.splice(T,1),le.value=!1,ia.value;throw new Error("Item not found to remove")}le.value=!1}return{data:Qn,columns:Sy,item:Kt,loading:ph,__init__:e,getData:t,filterData:r,setColumns:o,setItem:a,getItem:l,createItem:d,updateItem:h,removeItem:f,branchTeams:ia,linkTeam:g,unlinkTeam:v}};function p4(){const n=Ba("https://api.jplan.com.br/management/division"),{error:e}=sr();return{async getDivisionList(t){try{const r=t?`?filter_query=${t}`:"",o=await n.get(`/list/${r}`);if(o.data.error)throw e(W.global.t("toast.error.fetch_failed",{entity:"Division"})),new Error(o.data.error);return o.data.data}catch(r){console.error("Error in getDivisionList:",r),e(W.global.t("toast.error.fetch_failed",{entity:"Division"}));return}},async createDivision(t){var r,o;try{const a=await n.post("/item",t);return a.status>=200&&a.status<300?a:void 0}catch(a){throw console.error("Error in createDivision:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.create_failed",{entity:"Division"})),a}},async updateDivision(t){var r,o;try{const a=await n.patch("/item",t);if(a.data.error)throw e(W.global.t("toast.error.update_failed",{entity:"Division"})),new Error(a.data.error);return a}catch(a){throw console.error("Error in updateDivision:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.update_failed",{entity:"Division"})),a}},async getDivision(t){var r,o;try{const a=await n.get(`/item/${t}`);if(a.data.error)throw e(W.global.t("toast.error.fetch_failed",{entity:"Division"})),new Error(a.data.error);return a.data}catch(a){throw console.error("Error in getDivision:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.fetch_failed",{entity:"Division"})),a}},async activateDivision(t){var r,o;try{const a=await n.post(`/item/${t}/activate`);if(a.data.error)throw e(W.global.t("toast.error.activate_failed",{entity:"Division"})),new Error(a.data.error)}catch(a){throw console.error("Error in activateDivision:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.activate_failed",{entity:"Division"})),a}},async deactivateDivision(t){var r,o;try{const a=await n.post(`/item/${t}/deactivate`);if(a.data.error)throw e(W.global.t("toast.error.deactivate_failed",{entity:"Division"})),new Error(a.data.error)}catch(a){throw console.error("Error in deactivateDivision:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.deactivate_failed",{entity:"Division"})),a}}}}const fa=p4();let vh=!1;const _h=s.ref(!1),Xn=s.ref([]),Iy=s.ref([]),Wt=s.ref(null),aa=s.ref([]),v4=()=>{const n=sr(),e=async p=>{_h.value=!0;const w=p?`_active eq true and ${p}`:"_active eq true",C=await fa.getDivisionList(w);C&&(Xn.value=C,vh=!0),_h.value=!1},t=async p=>(Xn.value.length||await e(p),Xn.value);function r(p){if(!Xn.value)throw new Error("Data not stored yet");const w=xa(Xn.value,p,["name","description"]);return p!==""?w:Xn.value}const o=p=>{Iy.value=p},a=p=>{Wt.value=Oi.cloneDeep(p)},l=async p=>await fa.getDivision(p),d=async()=>{if(Wt.value!=null){const p=await fa.createDivision(Wt.value);return p!=null&&p.data.created_at&&(n.success(W.global.t("toast.success.create_success",{entity:"Division"})),vh&&Xn.value.push(p.data)),p==null?void 0:p.data}},h=async()=>{if(le.value=!0,Wt.value&&Wt.value.__id){const p=await fa.updateDivision(Wt.value);if(vh&&(p!=null&&p.data.__id)){const w=Xn.value.findIndex(C=>C.__id===p.data.__id);return w!==-1?(Xn.value[w]=p.data,n.success(W.global.t("toast.success.update_success",{entity:"Division"}))):n.error(W.global.t("toast.error.update_failed",{entity:"Division"})),le.value=!1,p}}else le.value=!1,n.error(W.global.t("toast.error.update_failed",{entity:"Division"}))},f=async()=>{if(le.value=!0,Wt.value&&Wt.value.created_at){await fa.deactivateDivision(Wt.value.__id);const p=Xn.value.findIndex(w=>{var C;return w.__id===((C=Wt.value)==null?void 0:C.__id)});if(p!==-1)return Xn.value.splice(p,1),Wt.value;n.error(W.global.t("toast.error.deactivate_failed",{entity:"Division"}))}le.value=!1};async function g(p){le.value=!0;try{if(Wt.value&&Wt.value.__id){const w={...p,division:Wt.value.__id};return await Bo.updateOrg(w)?(aa.value.findIndex(S=>S.__id===p.__id)===-1?(n.success(W.global.t("toast.success.link_success",{entity:"Organization"})),aa.value.push(w)):n.info(W.global.t("toast.info.already_linked",{entity:"Organization"})),w):void 0}else throw new Error("Item is not defined")}catch(w){console.error(w)}finally{le.value=!1}}async function v(p){if(le.value=!0,Wt.value&&Wt.value.__id){const w={...p,division:null};if(!await Bo.updateOrg(w))return;const T=aa.value.findIndex(S=>S.__id===p.__id);if(T!==-1)aa.value.splice(T,1);else throw new Error("Item not found to remove")}else throw new Error("Item is not defined");return le.value=!1,aa.value}return{data:Xn,columns:Iy,item:Wt,loading:_h,__init__:e,filterData:r,getData:t,setColumns:o,setItem:a,getItem:l,createItem:d,updateItem:h,removeItem:f,orgs:aa,linkDivision:g,unlinkDivision:v}};function _4(){const n=Ba("https://api.jplan.com.br/management/user"),{error:e}=sr();return{async getManageUserList(t){try{const r=t?`?filter_query=${t}`:"",o=await n.get(`/list/${r}`);if(o.data.error)throw e(W.global.t("toast.error.fetch_failed",{entity:"User"})),new Error(o.data.error);return o.data.data}catch(r){console.error("Error in getManageUserList:",r),e(W.global.t("toast.error.fetch_failed",{entity:"User"}));return}},async createManageUser(t){var r,o;try{const a=await n.post("/item",t);return a.status>=200&&a.status<300?a:void 0}catch(a){throw console.error("Error in createManageUser:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.create_failed",{entity:"User"})),a}},async updateManageUser(t){var r,o;try{const a=await n.patch("/item",t);if(a.data.error)throw e(W.global.t("toast.error.update_failed",{entity:"User"})),new Error(a.data.error);return a}catch(a){throw console.error("Error in updateManageUser:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.update_failed",{entity:"User"})),a}},async getManageUser(t){var r,o;try{const a=await n.get(`/item/${t}`);if(a.data.error)throw e(W.global.t("toast.error.fetch_failed",{entity:"User"})),new Error(a.data.error);return a.data}catch(a){console.error("Error in getManageUser:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.fetch_failed",{entity:"User"}));return}},async activateManageUser(t){var r,o;try{const a=await n.post(`/item/${t}/activate`);if(a.data.error)throw e(W.global.t("toast.error.activate_failed",{entity:"User"})),new Error(a.data.error)}catch(a){throw console.error("Error in activateManageUser:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.activate_failed",{entity:"User"})),a}},async deactivateManageUser(t){var r,o;try{const a=await n.post(`/item/${t}/deactivate`);if(a.data.error)throw e(W.global.t("toast.error.deactivate_failed",{entity:"User"})),new Error(a.data.error)}catch(a){throw console.error("Error in deactivateManageUser:",a),e(((o=(r=a.response)==null?void 0:r.data)==null?void 0:o.message)||W.global.t("toast.error.deactivate_failed",{entity:"User"})),a}}}}const ma=_4();let yh=!1,Ch=s.ref(!1);const Zn=s.ref([]),Ay=s.ref([]),er=s.ref(null),y4=s.ref(null),C4=s.ref([]),E4=()=>{const n=sr(),e=async g=>{Ch.value=!0;const v=g?`_active eq true and ${g}`:"_active eq true",p=await ma.getManageUserList(v);p&&(Zn.value=p,yh=!0),Ch.value=!1},t=async g=>(Zn.value.length||await e(g),Zn.value);function r(g){if(!Zn.value)throw new Error("Data not stored yet");const v=xa(Zn.value,g,["name","description"]);return g!==""?v:Zn.value}return{data:Zn,loading:Ch,columns:Ay,item:er,filterData:r,__init__:e,getData:t,setColumns:g=>{Ay.value=g},setItem:g=>{er.value=Oi.cloneDeep(g)},getItem:async g=>await ma.getManageUser(g),createItem:async()=>{if(er.value!=null){const g=crypto.randomUUID(),v=await ma.createManageUser({...er.value,__id:g});return v!=null&&v.data.created_at&&(n.success(W.global.t("toast.success.create_success",{entity:"User"})),yh&&Zn.value.push(v.data)),v==null?void 0:v.data}},updateItem:async()=>{if(le.value=!0,er.value&&er.value.created_at){const g=await ma.updateManageUser(er.value);if(yh&&(g!=null&&g.data)){const v=Zn.value.findIndex(p=>p.__id===(g==null?void 0:g.data.__id));v!==-1?(Zn.value[v]=g==null?void 0:g.data,n.success(W.global.t("toast.success.update_success",{entity:"User"}))):n.error(W.global.t("toast.error.update_failed",{entity:"User"}))}return le.value=!1,g==null?void 0:g.data}},removeItem:async()=>{if(er.value&&er.value.created_at){try{await ma.deactivateManageUser(er.value.__id)}catch{n.error(W.global.t("toast.error.deactivate_failed",{entity:"User"}));return}const g=Zn.value.findIndex(v=>{var p;return v.__id===((p=er.value)==null?void 0:p.__id)});if(g!==-1)return Zn.value.splice(g,1),n.success(W.global.t("toast.success.deactivate_success",{entity:"User"})),er.value}},userOrg:y4,userTeams:C4}},Eh=Object.freeze({colNum:24,rowHeight:50,useCssTransforms:!0,responsive:!0,margin:[12,10]}),sa=s.ref(!1),w4=s.ref([]);function T4(){const n=s.ref({...Eh,isResizable:!1,isDraggable:!1,useStyleCursor:!1,cursor:"default"});function e(){if(sa.value=!sa.value,n.value.isDraggable=sa.value,n.value.isResizable=sa.value,!sa.value){n.value.useStyleCursor=!0,n.value.cursor="pointer";return}n.value.useStyleCursor=!1,n.value.cursor="move"}function t(){n.value={...Eh,isResizable:!1,isDraggable:!1,useStyleCursor:!1,cursor:"default"}}return{DEFAULT_CONFIG:Eh,config:n,layout:w4,edition:sa,toggleEdit:e,resetLayout:t}}const b4=s.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./WidgetTask-BryId_NG.js"))),S4=s.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./WidgetImage-CmXW7a_H.js"))),I4=s.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./WidgetShortcut-Bs51Jvm4.js"))),A4=s.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./WidgetSpacer-C9hW1xHQ.js"))),k4=s.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./WidgetLabel-Bw9j6pzJ.js"))),N4=s.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./WidgetChartBar-bQdowxNO.js"))),O4=s.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./WidgetChartPie-B2LJPFQ3.js"))),R4={WidgetSpacer:A4,WidgetLabel:k4,WidgetTask:b4,WidgetImage:S4,WidgetShortcut:I4,WidgetChartBar:N4,WidgetChartPie:O4},P4={defaultI18n:!0},M4=(n,e)=>{const t={...P4,...e};n.use(h4),n.use(m1,f4),t.defaultI18n&&n.use(W),Object.entries(d4).forEach(([r,o])=>{n.component(r,o)}),Object.entries(BR).forEach(([r,o])=>{n.provide(r,o)})},D4={install:M4};exports.ContextMenu=QC;exports.EmptyListImg=m4;exports.EventBus=Kl;exports.FormHeadless=nw;exports.HttpCore=FB;exports.I18nMessages=Of;exports.SpinnerLoader=JT;exports.TableCardsView=EE;exports.TableHeader=CE;exports.TableHeaderFlash=mE;exports.__spinner=le;exports._export_sfc=Qo;exports._sfc_main=Pa;exports._sfc_main$1=XC;exports._sfc_main$10=qC;exports._sfc_main$11=au;exports._sfc_main$12=Oy;exports._sfc_main$13=Yl;exports._sfc_main$14=GC;exports._sfc_main$15=Ny;exports._sfc_main$16=qE;exports._sfc_main$17=jE;exports._sfc_main$18=YE;exports._sfc_main$19=JE;exports._sfc_main$2=ZC;exports._sfc_main$20=wE;exports._sfc_main$21=ZE;exports._sfc_main$22=ew;exports._sfc_main$23=tw;exports._sfc_main$24=Jl;exports._sfc_main$25=YC;exports._sfc_main$26=JC;exports._sfc_main$27=XT;exports._sfc_main$28=YT;exports._sfc_main$29=QT;exports._sfc_main$3=Df;exports._sfc_main$4=yE;exports._sfc_main$5=xf;exports._sfc_main$6=Uf;exports._sfc_main$7=Hs;exports._sfc_main$8=jC;exports._sfc_main$9=Us;exports.branchInstance=Fo;exports.coreClient=Nm;exports.createToastInterface=As;exports.dateFormat=Es;exports.divisionInstance=fa;exports.filterQuery=xa;exports.globalEventBus=vf;exports.i18n=W;exports.index=D4;exports.manageUserInstance=ma;exports.msal=qt;exports.orgInstance=Bo;exports.provideToast=f1;exports.scopedClient=Ba;exports.setupAuthGuard=n4;exports.teamInstance=Dn;exports.toastInjectionKey=Wl;exports.useAuth=km;exports.useBranchStore=g4;exports.useCustomizer=v0;exports.useDashboardStore=T4;exports.useDialog=Ra;exports.useDivisionStore=v4;exports.useManageUserStore=E4;exports.useNotifications=aC;exports.useOrganizationStore=qT;exports.useSession=Cu;exports.useTeamStore=jT;exports.useToast=sr;exports.widgets=R4;exports.withSpinner=KB;
|