diff --git a/frontend/dist/assets/index-88509652.js b/frontend/dist/assets/index-88509652.js index 7ba64db..890ea40 100644 --- a/frontend/dist/assets/index-88509652.js +++ b/frontend/dist/assets/index-88509652.js @@ -2,7 +2,7 @@ var rw=Object.defineProperty;var cw=(e,t,n)=>t in e?rw(e,t,{enumerable:!0,config * vue-router v4.2.5 * (c) 2023 Eduardo San Martin Morote * @license MIT - */const no=typeof window<"u";function pC(e){return e.__esModule||e[Symbol.toStringTag]==="Module"}const ht=Object.assign;function od(e,t){const n={};for(const i in t){const a=t[i];n[i]=yi(a)?a.map(e):e(a)}return n}const vl=()=>{},yi=Array.isArray,yC=/\/$/,bC=e=>e.replace(yC,"");function ld(e,t,n="/"){let i,a={},s="",o="";const l=t.indexOf("#");let r=t.indexOf("?");return l=0&&(r=-1),r>-1&&(i=t.slice(0,r),s=t.slice(r+1,l>-1?l:t.length),a=e(s)),l>-1&&(i=i||t.slice(0,l),o=t.slice(l,t.length)),i=wC(i??t,n),{fullPath:i+(s&&"?")+s+o,path:i,query:a,hash:o}}function _C(e,t){const n=t.query?e(t.query):"";return t.path+(n&&"?")+n+(t.hash||"")}function Cm(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||"/"}function xC(e,t,n){const i=t.matched.length-1,a=n.matched.length-1;return i>-1&&i===a&&go(t.matched[i],n.matched[a])&&Db(t.params,n.params)&&e(t.query)===e(n.query)&&t.hash===n.hash}function go(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function Db(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(!SC(e[n],t[n]))return!1;return!0}function SC(e,t){return yi(e)?Pm(e,t):yi(t)?Pm(t,e):e===t}function Pm(e,t){return yi(t)?e.length===t.length&&e.every((n,i)=>n===t[i]):e.length===1&&e[0]===t}function wC(e,t){if(e.startsWith("/"))return e;if(!e)return t;const n=t.split("/"),i=e.split("/"),a=i[i.length-1];(a===".."||a===".")&&i.push("");let s=n.length-1,o,l;for(o=0;o1&&s--;else break;return n.slice(0,s).join("/")+"/"+i.slice(o-(o===i.length?1:0)).join("/")}var Dl;(function(e){e.pop="pop",e.push="push"})(Dl||(Dl={}));var ml;(function(e){e.back="back",e.forward="forward",e.unknown=""})(ml||(ml={}));function kC(e){if(!e)if(no){const t=document.querySelector("base");e=t&&t.getAttribute("href")||"/",e=e.replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return e[0]!=="/"&&e[0]!=="#"&&(e="/"+e),bC(e)}const CC=/^[^#]+#/;function PC(e,t){return e.replace(CC,"#")+t}function IC(e,t){const n=document.documentElement.getBoundingClientRect(),i=e.getBoundingClientRect();return{behavior:t.behavior,left:i.left-n.left-(t.left||0),top:i.top-n.top-(t.top||0)}}const su=()=>({left:window.pageXOffset,top:window.pageYOffset});function VC(e){let t;if("el"in e){const n=e.el,i=typeof n=="string"&&n.startsWith("#"),a=typeof n=="string"?i?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!a)return;t=IC(a,e)}else t=e;"scrollBehavior"in document.documentElement.style?window.scrollTo(t):window.scrollTo(t.left!=null?t.left:window.pageXOffset,t.top!=null?t.top:window.pageYOffset)}function Im(e,t){return(history.state?history.state.position-t:-1)+e}const Yd=new Map;function AC(e,t){Yd.set(e,t)}function TC(e){const t=Yd.get(e);return Yd.delete(e),t}let MC=()=>location.protocol+"//"+location.host;function Ob(e,t){const{pathname:n,search:i,hash:a}=t,s=e.indexOf("#");if(s>-1){let l=a.includes(e.slice(s))?e.slice(s).length:1,r=a.slice(l);return r[0]!=="/"&&(r="/"+r),Cm(r,"")}return Cm(n,e)+i+a}function EC(e,t,n,i){let a=[],s=[],o=null;const l=({state:f})=>{const v=Ob(e,location),m=n.value,g=t.value;let p=0;if(f){if(n.value=v,t.value=f,o&&o===m){o=null;return}p=g?f.position-g.position:0}else i(v);a.forEach(y=>{y(n.value,m,{delta:p,type:Dl.pop,direction:p?p>0?ml.forward:ml.back:ml.unknown})})};function r(){o=n.value}function c(f){a.push(f);const v=()=>{const m=a.indexOf(f);m>-1&&a.splice(m,1)};return s.push(v),v}function u(){const{history:f}=window;f.state&&f.replaceState(ht({},f.state,{scroll:su()}),"")}function d(){for(const f of s)f();s=[],window.removeEventListener("popstate",l),window.removeEventListener("beforeunload",u)}return window.addEventListener("popstate",l),window.addEventListener("beforeunload",u,{passive:!0}),{pauseListeners:r,listen:c,destroy:d}}function Vm(e,t,n,i=!1,a=!1){return{back:e,current:t,forward:n,replaced:i,position:window.history.length,scroll:a?su():null}}function DC(e){const{history:t,location:n}=window,i={value:Ob(e,n)},a={value:t.state};a.value||s(i.value,{back:null,current:i.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function s(r,c,u){const d=e.indexOf("#"),f=d>-1?(n.host&&document.querySelector("base")?e:e.slice(d))+r:MC()+e+r;try{t[u?"replaceState":"pushState"](c,"",f),a.value=c}catch(v){console.error(v),n[u?"replace":"assign"](f)}}function o(r,c){const u=ht({},t.state,Vm(a.value.back,r,a.value.forward,!0),c,{position:a.value.position});s(r,u,!0),i.value=r}function l(r,c){const u=ht({},a.value,t.state,{forward:r,scroll:su()});s(u.current,u,!0);const d=ht({},Vm(i.value,r,null),{position:u.position+1},c);s(r,d,!1),i.value=r}return{location:i,state:a,push:l,replace:o}}function OC(e){e=kC(e);const t=DC(e),n=EC(e,t.state,t.location,t.replace);function i(s,o=!0){o||n.pauseListeners(),history.go(s)}const a=ht({location:"",base:e,go:i,createHref:PC.bind(null,e)},t,n);return Object.defineProperty(a,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(a,"state",{enumerable:!0,get:()=>t.state.value}),a}function RC(e){return typeof e=="string"||e&&typeof e=="object"}function Rb(e){return typeof e=="string"||typeof e=="symbol"}const va={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0},Lb=Symbol("");var Am;(function(e){e[e.aborted=4]="aborted",e[e.cancelled=8]="cancelled",e[e.duplicated=16]="duplicated"})(Am||(Am={}));function po(e,t){return ht(new Error,{type:e,[Lb]:!0},t)}function Fi(e,t){return e instanceof Error&&Lb in e&&(t==null||!!(e.type&t))}const Tm="[^/]+?",LC={sensitive:!1,strict:!1,start:!0,end:!0},BC=/[.+*?^${}()[\]/\\]/g;function NC(e,t){const n=ht({},LC,t),i=[];let a=n.start?"^":"";const s=[];for(const c of e){const u=c.length?[]:[90];n.strict&&!c.length&&(a+="/");for(let d=0;dt.length?t.length===1&&t[0]===40+40?1:-1:0}function $C(e,t){let n=0;const i=e.score,a=t.score;for(;n0&&t[t.length-1]<0}const zC={type:0,value:""},HC=/[a-zA-Z0-9_]/;function jC(e){if(!e)return[[]];if(e==="/")return[[zC]];if(!e.startsWith("/"))throw new Error(`Invalid path "${e}"`);function t(v){throw new Error(`ERR (${n})/"${c}": ${v}`)}let n=0,i=n;const a=[];let s;function o(){s&&a.push(s),s=[]}let l=0,r,c="",u="";function d(){c&&(n===0?s.push({type:0,value:c}):n===1||n===2||n===3?(s.length>1&&(r==="*"||r==="+")&&t(`A repeatable param (${c}) must be alone in its segment. eg: '/:ids+.`),s.push({type:1,value:c,regexp:u,repeatable:r==="*"||r==="+",optional:r==="*"||r==="?"})):t("Invalid state to consume buffer"),c="")}function f(){c+=r}for(;l{o(b)}:vl}function o(u){if(Rb(u)){const d=i.get(u);d&&(i.delete(u),n.splice(n.indexOf(d),1),d.children.forEach(o),d.alias.forEach(o))}else{const d=n.indexOf(u);d>-1&&(n.splice(d,1),u.record.name&&i.delete(u.record.name),u.children.forEach(o),u.alias.forEach(o))}}function l(){return n}function r(u){let d=0;for(;d=0&&(u.record.path!==n[d].record.path||!Bb(u,n[d]));)d++;n.splice(d,0,u),u.record.name&&!Dm(u)&&i.set(u.record.name,u)}function c(u,d){let f,v={},m,g;if("name"in u&&u.name){if(f=i.get(u.name),!f)throw po(1,{location:u});g=f.record.name,v=ht(Em(d.params,f.keys.filter(b=>!b.optional).map(b=>b.name)),u.params&&Em(u.params,f.keys.map(b=>b.name))),m=f.stringify(v)}else if("path"in u)m=u.path,f=n.find(b=>b.re.test(m)),f&&(v=f.parse(m),g=f.record.name);else{if(f=d.name?i.get(d.name):n.find(b=>b.re.test(d.path)),!f)throw po(1,{location:u,currentLocation:d});g=f.record.name,v=ht({},d.params,u.params),m=f.stringify(v)}const p=[];let y=f;for(;y;)p.unshift(y.record),y=y.parent;return{name:g,path:m,params:v,matched:p,meta:GC(p)}}return e.forEach(u=>s(u)),{addRoute:s,resolve:c,removeRoute:o,getRoutes:l,getRecordMatcher:a}}function Em(e,t){const n={};for(const i of t)i in e&&(n[i]=e[i]);return n}function YC(e){return{path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:void 0,beforeEnter:e.beforeEnter,props:KC(e),children:e.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in e?e.components||null:e.component&&{default:e.component}}}function KC(e){const t={},n=e.props||!1;if("component"in e)t.default=n;else for(const i in e.components)t[i]=typeof n=="object"?n[i]:n;return t}function Dm(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function GC(e){return e.reduce((t,n)=>ht(t,n.meta),{})}function Om(e,t){const n={};for(const i in e)n[i]=i in t?t[i]:e[i];return n}function Bb(e,t){return t.children.some(n=>n===e||Bb(e,n))}const Nb=/#/g,XC=/&/g,qC=/\//g,ZC=/=/g,JC=/\?/g,Fb=/\+/g,QC=/%5B/g,eP=/%5D/g,$b=/%5E/g,tP=/%60/g,zb=/%7B/g,nP=/%7C/g,Hb=/%7D/g,iP=/%20/g;function mh(e){return encodeURI(""+e).replace(nP,"|").replace(QC,"[").replace(eP,"]")}function aP(e){return mh(e).replace(zb,"{").replace(Hb,"}").replace($b,"^")}function Kd(e){return mh(e).replace(Fb,"%2B").replace(iP,"+").replace(Nb,"%23").replace(XC,"%26").replace(tP,"`").replace(zb,"{").replace(Hb,"}").replace($b,"^")}function sP(e){return Kd(e).replace(ZC,"%3D")}function oP(e){return mh(e).replace(Nb,"%23").replace(JC,"%3F")}function lP(e){return e==null?"":oP(e).replace(qC,"%2F")}function pc(e){try{return decodeURIComponent(""+e)}catch{}return""+e}function rP(e){const t={};if(e===""||e==="?")return t;const i=(e[0]==="?"?e.slice(1):e).split("&");for(let a=0;as&&Kd(s)):[i&&Kd(i)]).forEach(s=>{s!==void 0&&(t+=(t.length?"&":"")+n,s!=null&&(t+="="+s))})}return t}function cP(e){const t={};for(const n in e){const i=e[n];i!==void 0&&(t[n]=yi(i)?i.map(a=>a==null?null:""+a):i==null?i:""+i)}return t}const uP=Symbol(""),Lm=Symbol(""),ou=Symbol(""),gh=Symbol(""),Gd=Symbol("");function Yo(){let e=[];function t(i){return e.push(i),()=>{const a=e.indexOf(i);a>-1&&e.splice(a,1)}}function n(){e=[]}return{add:t,list:()=>e.slice(),reset:n}}function ba(e,t,n,i,a){const s=i&&(i.enterCallbacks[a]=i.enterCallbacks[a]||[]);return()=>new Promise((o,l)=>{const r=d=>{d===!1?l(po(4,{from:n,to:t})):d instanceof Error?l(d):RC(d)?l(po(2,{from:t,to:d})):(s&&i.enterCallbacks[a]===s&&typeof d=="function"&&s.push(d),o())},c=e.call(i&&i.instances[a],t,n,r);let u=Promise.resolve(c);e.length<3&&(u=u.then(r)),u.catch(d=>l(d))})}function rd(e,t,n,i){const a=[];for(const s of e)for(const o in s.components){let l=s.components[o];if(!(t!=="beforeRouteEnter"&&!s.instances[o]))if(dP(l)){const c=(l.__vccOpts||l)[t];c&&a.push(ba(c,n,i,s,o))}else{let r=l();a.push(()=>r.then(c=>{if(!c)return Promise.reject(new Error(`Couldn't resolve component "${o}" at "${s.path}"`));const u=pC(c)?c.default:c;s.components[o]=u;const f=(u.__vccOpts||u)[t];return f&&ba(f,n,i,s,o)()}))}}return a}function dP(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function Bm(e){const t=Ke(ou),n=Ke(gh),i=w(()=>t.resolve(Je(e.to))),a=w(()=>{const{matched:r}=i.value,{length:c}=r,u=r[c-1],d=n.matched;if(!u||!d.length)return-1;const f=d.findIndex(go.bind(null,u));if(f>-1)return f;const v=Nm(r[c-2]);return c>1&&Nm(u)===v&&d[d.length-1].path!==v?d.findIndex(go.bind(null,r[c-2])):f}),s=w(()=>a.value>-1&&mP(n.params,i.value.params)),o=w(()=>a.value>-1&&a.value===n.matched.length-1&&Db(n.params,i.value.params));function l(r={}){return vP(r)?t[Je(e.replace)?"replace":"push"](Je(e.to)).catch(vl):Promise.resolve()}return{route:i,href:w(()=>i.value.href),isActive:s,isExactActive:o,navigate:l}}const fP=La({name:"RouterLink",compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:"page"}},useLink:Bm,setup(e,{slots:t}){const n=Ft(Bm(e)),{options:i}=Ke(ou),a=w(()=>({[Fm(e.activeClass,i.linkActiveClass,"router-link-active")]:n.isActive,[Fm(e.exactActiveClass,i.linkExactActiveClass,"router-link-exact-active")]:n.isExactActive}));return()=>{const s=t.default&&t.default(n);return e.custom?s:Fn("a",{"aria-current":n.isExactActive?e.ariaCurrentValue:null,href:n.href,onClick:n.navigate,class:a.value},s)}}}),hP=fP;function vP(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){const t=e.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(t))return}return e.preventDefault&&e.preventDefault(),!0}}function mP(e,t){for(const n in t){const i=t[n],a=e[n];if(typeof i=="string"){if(i!==a)return!1}else if(!yi(a)||a.length!==i.length||i.some((s,o)=>s!==a[o]))return!1}return!0}function Nm(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}const Fm=(e,t,n)=>e??t??n,gP=La({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){const i=Ke(Gd),a=w(()=>e.route||i.value),s=Ke(Lm,0),o=w(()=>{let c=Je(s);const{matched:u}=a.value;let d;for(;(d=u[c])&&!d.components;)c++;return c}),l=w(()=>a.value.matched[o.value]);lt(Lm,w(()=>o.value+1)),lt(uP,l),lt(Gd,a);const r=Z();return _e(()=>[r.value,l.value,e.name],([c,u,d],[f,v,m])=>{u&&(u.instances[d]=c,v&&v!==u&&c&&c===f&&(u.leaveGuards.size||(u.leaveGuards=v.leaveGuards),u.updateGuards.size||(u.updateGuards=v.updateGuards))),c&&u&&(!v||!go(u,v)||!f)&&(u.enterCallbacks[d]||[]).forEach(g=>g(c))},{flush:"post"}),()=>{const c=a.value,u=e.name,d=l.value,f=d&&d.components[u];if(!f)return $m(n.default,{Component:f,route:c});const v=d.props[u],m=v?v===!0?c.params:typeof v=="function"?v(c):v:null,p=Fn(f,ht({},m,t,{onVnodeUnmounted:y=>{y.component.isUnmounted&&(d.instances[u]=null)},ref:r}));return $m(n.default,{Component:p,route:c})||p}}});function $m(e,t){if(!e)return null;const n=e(t);return n.length===1?n[0]:n}const pP=gP;function yP(e){const t=UC(e.routes,e),n=e.parseQuery||rP,i=e.stringifyQuery||Rm,a=e.history,s=Yo(),o=Yo(),l=Yo(),r=Se(va);let c=va;no&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const u=od.bind(null,U=>""+U),d=od.bind(null,lP),f=od.bind(null,pc);function v(U,Q){let ae,X;return Rb(U)?(ae=t.getRecordMatcher(U),X=Q):X=U,t.addRoute(X,ae)}function m(U){const Q=t.getRecordMatcher(U);Q&&t.removeRoute(Q)}function g(){return t.getRoutes().map(U=>U.record)}function p(U){return!!t.getRecordMatcher(U)}function y(U,Q){if(Q=ht({},Q||r.value),typeof U=="string"){const F=ld(n,U,Q.path),q=t.resolve({path:F.path},Q),oe=a.createHref(F.fullPath);return ht(F,q,{params:f(q.params),hash:pc(F.hash),redirectedFrom:void 0,href:oe})}let ae;if("path"in U)ae=ht({},U,{path:ld(n,U.path,Q.path).path});else{const F=ht({},U.params);for(const q in F)F[q]==null&&delete F[q];ae=ht({},U,{params:d(F)}),Q.params=d(Q.params)}const X=t.resolve(ae,Q),Ie=U.hash||"";X.params=u(f(X.params));const E=_C(i,ht({},U,{hash:aP(Ie),path:X.path})),R=a.createHref(E);return ht({fullPath:E,hash:Ie,query:i===Rm?cP(U.query):U.query||{}},X,{redirectedFrom:void 0,href:R})}function b(U){return typeof U=="string"?ld(n,U,r.value.path):ht({},U)}function S(U,Q){if(c!==U)return po(8,{from:Q,to:U})}function _(U){return C(U)}function x(U){return _(ht(b(U),{replace:!0}))}function P(U){const Q=U.matched[U.matched.length-1];if(Q&&Q.redirect){const{redirect:ae}=Q;let X=typeof ae=="function"?ae(U):ae;return typeof X=="string"&&(X=X.includes("?")||X.includes("#")?X=b(X):{path:X},X.params={}),ht({query:U.query,hash:U.hash,params:"path"in X?{}:U.params},X)}}function C(U,Q){const ae=c=y(U),X=r.value,Ie=U.state,E=U.force,R=U.replace===!0,F=P(ae);if(F)return C(ht(b(F),{state:typeof F=="object"?ht({},Ie,F.state):Ie,force:E,replace:R}),Q||ae);const q=ae;q.redirectedFrom=Q;let oe;return!E&&xC(i,X,ae)&&(oe=po(16,{to:q,from:X}),le(X,X,!0,!1)),(oe?Promise.resolve(oe):M(q,X)).catch(he=>Fi(he)?Fi(he,2)?he:ee(he):B(he,q,X)).then(he=>{if(he){if(Fi(he,2))return C(ht({replace:R},b(he.to),{state:typeof he.to=="object"?ht({},Ie,he.to.state):Ie,force:E}),Q||q)}else he=D(q,X,!0,R,Ie);return O(q,X,he),he})}function V(U,Q){const ae=S(U,Q);return ae?Promise.reject(ae):Promise.resolve()}function I(U){const Q=Me.values().next().value;return Q&&typeof Q.runWithContext=="function"?Q.runWithContext(U):U()}function M(U,Q){let ae;const[X,Ie,E]=bP(U,Q);ae=rd(X.reverse(),"beforeRouteLeave",U,Q);for(const F of X)F.leaveGuards.forEach(q=>{ae.push(ba(q,U,Q))});const R=V.bind(null,U,Q);return ae.push(R),te(ae).then(()=>{ae=[];for(const F of s.list())ae.push(ba(F,U,Q));return ae.push(R),te(ae)}).then(()=>{ae=rd(Ie,"beforeRouteUpdate",U,Q);for(const F of Ie)F.updateGuards.forEach(q=>{ae.push(ba(q,U,Q))});return ae.push(R),te(ae)}).then(()=>{ae=[];for(const F of E)if(F.beforeEnter)if(yi(F.beforeEnter))for(const q of F.beforeEnter)ae.push(ba(q,U,Q));else ae.push(ba(F.beforeEnter,U,Q));return ae.push(R),te(ae)}).then(()=>(U.matched.forEach(F=>F.enterCallbacks={}),ae=rd(E,"beforeRouteEnter",U,Q),ae.push(R),te(ae))).then(()=>{ae=[];for(const F of o.list())ae.push(ba(F,U,Q));return ae.push(R),te(ae)}).catch(F=>Fi(F,8)?F:Promise.reject(F))}function O(U,Q,ae){l.list().forEach(X=>I(()=>X(U,Q,ae)))}function D(U,Q,ae,X,Ie){const E=S(U,Q);if(E)return E;const R=Q===va,F=no?history.state:{};ae&&(X||R?a.replace(U.fullPath,ht({scroll:R&&F&&F.scroll},Ie)):a.push(U.fullPath,Ie)),r.value=U,le(U,Q,ae,R),ee()}let N;function j(){N||(N=a.listen((U,Q,ae)=>{if(!Oe.listening)return;const X=y(U),Ie=P(X);if(Ie){C(ht(Ie,{replace:!0}),X).catch(vl);return}c=X;const E=r.value;no&&AC(Im(E.fullPath,ae.delta),su()),M(X,E).catch(R=>Fi(R,12)?R:Fi(R,2)?(C(R.to,X).then(F=>{Fi(F,20)&&!ae.delta&&ae.type===Dl.pop&&a.go(-1,!1)}).catch(vl),Promise.reject()):(ae.delta&&a.go(-ae.delta,!1),B(R,X,E))).then(R=>{R=R||D(X,E,!1),R&&(ae.delta&&!Fi(R,8)?a.go(-ae.delta,!1):ae.type===Dl.pop&&Fi(R,20)&&a.go(-1,!1)),O(X,E,R)}).catch(vl)}))}let Y=Yo(),K=Yo(),J;function B(U,Q,ae){ee(U);const X=K.list();return X.length?X.forEach(Ie=>Ie(U,Q,ae)):console.error(U),Promise.reject(U)}function G(){return J&&r.value!==va?Promise.resolve():new Promise((U,Q)=>{Y.add([U,Q])})}function ee(U){return J||(J=!U,j(),Y.list().forEach(([Q,ae])=>U?ae(U):Q()),Y.reset()),U}function le(U,Q,ae,X){const{scrollBehavior:Ie}=e;if(!no||!Ie)return Promise.resolve();const E=!ae&&TC(Im(U.fullPath,0))||(X||!ae)&&history.state&&history.state.scroll||null;return Ze().then(()=>Ie(U,Q,E)).then(R=>R&&VC(R)).catch(R=>B(R,U,Q))}const ce=U=>a.go(U);let ge;const Me=new Set,Oe={currentRoute:r,listening:!0,addRoute:v,removeRoute:m,hasRoute:p,getRoutes:g,resolve:y,options:e,push:_,replace:x,go:ce,back:()=>ce(-1),forward:()=>ce(1),beforeEach:s.add,beforeResolve:o.add,afterEach:l.add,onError:K.add,isReady:G,install(U){const Q=this;U.component("RouterLink",hP),U.component("RouterView",pP),U.config.globalProperties.$router=Q,Object.defineProperty(U.config.globalProperties,"$route",{enumerable:!0,get:()=>Je(r)}),no&&!ge&&r.value===va&&(ge=!0,_(a.location).catch(Ie=>{}));const ae={};for(const Ie in va)Object.defineProperty(ae,Ie,{get:()=>r.value[Ie],enumerable:!0});U.provide(ou,Q),U.provide(gh,Yf(ae)),U.provide(Gd,r);const X=U.unmount;Me.add(U),U.unmount=function(){Me.delete(U),Me.size<1&&(c=va,N&&N(),N=null,r.value=va,ge=!1,J=!1),X()}}};function te(U){return U.reduce((Q,ae)=>Q.then(()=>I(ae)),Promise.resolve())}return Oe}function bP(e,t){const n=[],i=[],a=[],s=Math.max(t.matched.length,e.matched.length);for(let o=0;ogo(c,l))?i.push(l):n.push(l));const r=e.matched[o];r&&(t.matched.find(c=>go(c,r))||a.push(r))}return[n,i,a]}function ph(){return Ke(ou)}function _P(){return Ke(gh)}const at=(e,t)=>{const n=e.__vccOpts||e;for(const[i,a]of t)n[i]=a;return n},xP=e=>(Oa("data-v-66ce0b56"),e=e(),Ra(),e),SP={class:"image-view"},wP=["src","alt"],kP={key:0,class:"spinner"},CP=xP(()=>be("img",{alt:"loading...",class:"preloader-gif",src:"data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4KPHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBzdHlsZT0ibWFyZ2luOiBhdXRvOyBiYWNrZ3JvdW5kOiBub25lOyBkaXNwbGF5OiBibG9jazsgc2hhcGUtcmVuZGVyaW5nOiBhdXRvOyIgd2lkdGg9IjIwMHB4IiBoZWlnaHQ9IjIwMHB4IiB2aWV3Qm94PSIwIDAgMTAwIDEwMCIgcHJlc2VydmVBc3BlY3RSYXRpbz0ieE1pZFlNaWQiPgo8Y2lyY2xlIGN4PSI1MCIgY3k9IjUwIiByPSIzMiIgc3Ryb2tlLXdpZHRoPSI4IiBzdHJva2U9IiM1NDUxNTEiIHN0cm9rZS1kYXNoYXJyYXk9IjUwLjI2NTQ4MjQ1NzQzNjY5IDUwLjI2NTQ4MjQ1NzQzNjY5IiBmaWxsPSJub25lIiBzdHJva2UtbGluZWNhcD0icm91bmQiPgogIDxhbmltYXRlVHJhbnNmb3JtIGF0dHJpYnV0ZU5hbWU9InRyYW5zZm9ybSIgdHlwZT0icm90YXRlIiBkdXI9IjFzIiByZXBlYXRDb3VudD0iaW5kZWZpbml0ZSIga2V5VGltZXM9IjA7MSIgdmFsdWVzPSIwIDUwIDUwOzM2MCA1MCA1MCI+PC9hbmltYXRlVHJhbnNmb3JtPgo8L2NpcmNsZT4KPGNpcmNsZSBjeD0iNTAiIGN5PSI1MCIgcj0iMjMiIHN0cm9rZS13aWR0aD0iOCIgc3Ryb2tlPSIjYzNjM2M1IiBzdHJva2UtZGFzaGFycmF5PSIzNi4xMjgzMTU1MTYyODI2MiAzNi4xMjgzMTU1MTYyODI2MiIgc3Ryb2tlLWRhc2hvZmZzZXQ9IjM2LjEyODMxNTUxNjI4MjYyIiBmaWxsPSJub25lIiBzdHJva2UtbGluZWNhcD0icm91bmQiPgogIDxhbmltYXRlVHJhbnNmb3JtIGF0dHJpYnV0ZU5hbWU9InRyYW5zZm9ybSIgdHlwZT0icm90YXRlIiBkdXI9IjFzIiByZXBlYXRDb3VudD0iaW5kZWZpbml0ZSIga2V5VGltZXM9IjA7MSIgdmFsdWVzPSIwIDUwIDUwOy0zNjAgNTAgNTAiPjwvYW5pbWF0ZVRyYW5zZm9ybT4KPC9jaXJjbGU+CjwhLS0gW2xkaW9dIGdlbmVyYXRlZCBieSBodHRwczovL2xvYWRpbmcuaW8vIC0tPjwvc3ZnPg=="},null,-1)),PP=[CP],IP={__name:"ImageView",props:{src:String,alt:String,ignoreOnImageCount:Boolean,spinnerEnabled:Boolean},emits:["loading","loaded","error","completed"],setup(e,{expose:t,emit:n}){const i=e,a=au(),s=n,o=Z(null),l=Z(null),r=w(()=>a.HTML_CLASSES.imageViewImage+(i.ignoreOnImageCount?` ${a.HTML_CLASSES.imageViewImageIgnoredOnCount}`:""));_t(()=>{v()}),_e(()=>i.src,()=>{v()});const c=()=>l.value===a.LoadStatus.LOADED||l.value===a.LoadStatus.ERROR,u=()=>{f(a.LoadStatus.LOADED)},d=()=>{f(a.LoadStatus.ERROR)},f=m=>{switch(l.value=m,o.value.setAttribute("loadStatus",m),m){case a.LoadStatus.LOADING:s("loading");break;case a.LoadStatus.LOADED:s("loaded"),s("completed");break;case a.LoadStatus.ERROR:s("error"),s("completed");break}},v=()=>{f(typeof i.src!="string"?a.LoadStatus.ERROR:a.LoadStatus.LOADING)};return t({isLoaded:c}),(m,g)=>(me(),Te("div",SP,[ft(be("img",{ref_key:"img",ref:o,src:i.src,alt:i.alt,class:xt(r.value),onLoad:u,onError:d},null,42,wP),[[mn,c()]]),i.spinnerEnabled?ft((me(),Te("div",kP,PP,512)),[[mn,!c()]]):kt("",!0)]))}},yh=at(IP,[["__scopeId","data-v-66ce0b56"]]);const VP={class:"nav-profile-card"},AP={class:"nav-profile-card-title lead-2"},TP={class:"nav-profile-card-subtitle text-4 mb-1"},MP={__name:"NavProfileCard",props:{profileData:Object},setup(e){const t=e;return(n,i)=>(me(),Te("div",VP,[h(yh,{src:t.profileData.profilePictureUrl,alt:t.profileData.name,class:"img-pfp"},null,8,["src","alt"]),be("h4",AP,wt(t.profileData.name),1),be("h6",TP,wt(t.profileData.locales.role),1)]))}},jb=at(MP,[["__scopeId","data-v-ad1c764a"]]);const Wb=e=>(Oa("data-v-1fb31b9d"),e=e(),Ra(),e),EP={class:"nav-sidebar"},DP={key:0,class:"nav-sidebar-content"},OP={class:"nav-links"},RP=["onClick"],LP={class:"nav-links"},BP={class:"nav-item"},NP=Wb(()=>be("i",{class:"fa-solid fa-magnifying-glass"},null,-1)),FP={key:0,class:"nav-item"},$P=Wb(()=>be("i",{class:"fa-solid fa-pen-to-square"},null,-1)),zP={key:1,class:"nav-sidebar-footer"},HP={__name:"NavSidebar",emits:["linkClicked"],setup(e,{emit:t}){const n=t,i=Oi(),a=Na(),s=ph(),o=Z(""),l=Z(null);Qc(()=>{s.currentRoute.value.query.query?r():s.push("/login")}),Jt(async()=>{await r()});async function r(){let v="";if(s.currentRoute.value.query.query)v=s.currentRoute.value.query.query;else try{const p=await(await fetch("https://res-a-me-api.tobywinz.com/loadUser",{method:"GET",headers:{"Content-type":"application/json; charset=UTF-8",Authorization:"Bearer "+sessionStorage.getItem("access_token")}})).json();p.status===200&&(v=p.logged_in_as)}catch(g){console.error("Error fetching user data:",g)}try{const p=await(await fetch("https://res-a-me-api.tobywinz.com/updateResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8"},body:JSON.stringify({email:v})})).json();p.status!==200&&console.error("Error fetching user resume: ",p.message)}catch{console.error("Error fetching user resume: ",error)}let m=i.getProfile();fetch(`/images/pictures/${v}.png`).then(g=>{g.ok?m.profilePictureUrl=`/images/pictures/${v}.png`:m.profilePictureUrl="/images/pictures/avatar.png"}).then(()=>{l.value=m})}const c=v=>{let m="nav-item";return a.isSectionActive(v.id)&&(m+=" nav-item-selected"),m},u=v=>{n("linkClicked",v.id)},d=()=>!!sessionStorage.getItem("access_token"),f=()=>{fetch("https://res-a-me-api.tobywinz.com/logout",{method:"GET",headers:{"Content-type":"application/json; charset=UTF-8"}}).then(v=>{if(!v.ok)throw new Error("Network response was not ok");return v.json()}).then(v=>{v.message==="Logout successful"?(sessionStorage.clear(),s.push("/")):o.value=v.message||"Logout failed. Please try again."}).catch(v=>{console.error("Logout error:",v),o.value=v.message||"An error occurred. Please try again."})};return(v,m)=>{const g=we("v-btn"),p=we("v-col");return me(),Te("nav",EP,[l.value?(me(),Te("div",DP,[h(jb,{"profile-data":l.value},null,8,["profile-data"]),be("ul",OP,[(me(!0),Te(Pe,null,At(Je(i).getSections(),y=>(me(),Te("li",{class:xt(c(y))},[be("button",{class:"nav-link",onClick:b=>u(y)},[be("i",{class:xt(y.faIcon)},null,2),Xe(" "+wt(Je(i).getString(y.id)),1)],8,RP)],2))),256))]),be("ul",LP,[be("li",BP,[be("button",{class:"nav-link",onClick:m[0]||(m[0]=y=>Je(s).push("/"))},[NP,Xe(" Search ")])]),d()?(me(),Te("li",FP,[be("button",{class:"nav-link",onClick:m[1]||(m[1]=y=>Je(s).push("/edit"))},[$P,Xe(" Edit Resume ")])])):kt("",!0)])])):kt("",!0),l.value?(me(),Te("div",zP,[h(p,null,{default:ie(()=>[d()?(me(),Tt(g,{key:0,variant:"flat",onClick:f,color:"#1a73e8"},{default:ie(()=>[Xe("Logout")]),_:1})):kt("",!0),d()?kt("",!0):(me(),Tt(g,{key:1,variant:"flat",onClick:m[2]||(m[2]=y=>Je(s).push("/login")),color:"#1a73e8"},{default:ie(()=>[Xe("Login")]),_:1}))]),_:1})])):kt("",!0)])}}},jP=at(HP,[["__scopeId","data-v-1fb31b9d"]]);const WP={key:0,class:"nav-pills"},UP=["onClick"],YP={class:"d-none d-sm-inline"},KP={__name:"NavPills",props:{sections:Array},emits:["linkClicked"],setup(e,{emit:t}){const n=e,i=Oi(),a=Na(),s=t,o=r=>`nav-item ${a.isSectionActive(r.id)?"nav-item-selected":""}`,l=r=>{s("linkClicked",r)};return(r,c)=>n.sections&&n.sections.length>=2?(me(),Te("div",WP,[(me(!0),Te(Pe,null,At(n.sections,u=>(me(),Te("button",{class:xt(o(u)),onClick:d=>l(u)},[be("i",{class:xt(["nav-pill-icon",u.faIcon])},null,2),be("span",YP,wt(Je(i).getString(u.id)),1)],10,UP))),256))])):kt("",!0)}},zm=at(KP,[["__scopeId","data-v-77e48e8c"]]);const GP={class:"nav-header"},XP={class:"nav-header-container"},qP={key:0,class:"nav-pills-fixed-container nav-pills-fixed-container-shrink",id:"nav-pills-fixed-container"},ZP={key:0,class:"nav-pills-page-title text-white"},JP={__name:"NavHeader",emits:["linkClicked"],setup(e,{emit:t}){const n=Oi(),i=To(),a=Na(),s=Ba(),o=t,l=w(()=>{const d=a.getActiveCategoryId();return n.getCategorySections(d)}),r=w(()=>{if(!s.isIOS()||window.innerHeight<600)return null;const d=a.getActiveSectionId();return n.getString(d)});_t(()=>{window.addEventListener("resize",c),window.addEventListener("scroll",c),c()}),Ms(()=>{window.removeEventListener("resize",c),window.removeEventListener("scroll",c)}),_e(()=>a.getActiveSectionId(),()=>{const d=document.getElementById("nav-pills-fixed-container");d&&(d.classList.add("nav-pills-fixed-container-no-transition"),setTimeout(()=>{d.classList.remove("nav-pills-fixed-container-no-transition")},100))});const c=()=>{const d=document.getElementById("nav-pills"),f=document.getElementById("nav-pills-fixed-container");if(!d||!f)return;i.isElementOutsideBounds(d)?f.classList.remove("nav-pills-fixed-container-shrink"):f.classList.add("nav-pills-fixed-container-shrink")},u=d=>{o("linkClicked",d.id)};return(d,f)=>(me(),Te("div",GP,[be("div",XP,[Je(n).getProfile()?(me(),Tt(jb,{key:0,"profile-data":Je(n).getProfile()},null,8,["profile-data"])):kt("",!0),h(zm,{class:"nav-pills",id:"nav-pills",sections:l.value,onLinkClicked:u},null,8,["sections"])]),l.value.length>=2?(me(),Te("div",qP,[r.value?(me(),Te("h4",ZP,wt(r.value),1)):kt("",!0),h(zm,{class:"nav-pills-fixed",id:"nav-pills-fixed",sections:l.value,onLinkClicked:u},null,8,["sections"])])):kt("",!0)]))}},QP=at(JP,[["__scopeId","data-v-0b712a98"]]);const eI={class:"nav-tabs-wrapper"},tI={class:"nav-tabs"},nI=["onClick"],iI={class:"nav-tab-button-label"},aI={__name:"NavTabs",emits:["linkClicked"],setup(e,{emit:t}){const n=t,i=Oi(),a=Na(),s=l=>{let r="nav-tab-button";return a.isCategoryActive(l.id)&&(r+=" nav-tab-button-selected"),r},o=l=>{n("linkClicked",l.id)};return(l,r)=>(me(),Te("div",eI,[be("nav",tI,[(me(!0),Te(Pe,null,At(Je(i).getCategories(),c=>(me(),Te("button",{class:xt(s(c)),onClick:u=>o(c)},[be("i",{class:xt(["nav-tab-button-icon",c.faIcon])},null,2),be("span",iI,wt(Je(i).getString(c.id)),1)],10,nI))),256))])]))}},sI=at(aI,[["__scopeId","data-v-37eedae7"]]);const oI=e=>(Oa("data-v-8790a924"),e=e(),Ra(),e),lI=["id"],rI={key:0,class:"section-container"},cI={key:0,class:"section-header"},uI=["innerHTML"],dI=oI(()=>be("hr",{class:"solid-divider ms-1 me-1 mb-3 mb-lg-4"},null,-1)),fI={key:0,class:"lead text-muted"},hI={class:"section-content"},vI={__name:"SectionTemplate",props:{sectionData:Object},setup(e){const t=e,n=Oi(),i=Na(),a=w(()=>t.sectionData&&i.isSectionVisible(t.sectionData.id)),s=w(()=>{let l="section";return i.isAllAtOnceMode()&&(l+=" section-with-division"),t.sectionData.cover&&(l+=" section-cover"),l}),o=w(()=>i.isAllAtOnceMode()?t.sectionData.content.locales.title:n.getString(t.sectionData.id));return(l,r)=>ft((me(),Te("section",{id:t.sectionData.id,class:xt(s.value)},[t.sectionData.content?(me(),Te("div",rI,[t.sectionData.content.locales.title?(me(),Te("div",cI,[be("h1",{class:"section-title mb-1 mb-lg-2 fw-bold text-uppercase",innerHTML:o.value},null,8,uI),dI,t.sectionData.content.locales.description?(me(),Te("p",fI,wt(t.sectionData.content.locales.description),1)):kt("",!0)])):kt("",!0),be("div",hI,[Fy(l.$slots,"default",{},void 0,!0)])])):kt("",!0)],10,lI)),[[mn,a.value]])}},yo=at(vI,[["__scopeId","data-v-8790a924"]]);const mI={class:"inline-list lead"},gI={class:"list-item"},pI=["href"],yI={key:1},bI={__name:"InlineList",props:{items:Array},setup(e){const t=e,n=s=>s.valueShort||s.value,i=s=>s.href,a=s=>s.faIcon;return(s,o)=>(me(),Te("div",mI,[(me(!0),Te(Pe,null,At(t.items,l=>(me(),Te("div",gI,[i(l)?(me(),Te("a",{key:0,href:i(l),class:"info-item-link"},[a(l)?(me(),Te("i",{key:0,class:xt([a(l),"list-item-icon"])},null,2)):kt("",!0),Xe(" "+wt(n(l)),1)],8,pI)):(me(),Te("span",yI,[a(l)?(me(),Te("i",{key:0,class:xt([a(l),"list-item-icon"])},null,2)):kt("",!0),Xe(" "+wt(n(l)),1)]))]))),256))]))}},_I=at(bI,[["__scopeId","data-v-c4644c6f"]]);const xI=e=>(Oa("data-v-e6f3fa6c"),e=e(),Ra(),e),SI=["innerHTML"],wI=xI(()=>be("hr",{class:"solid-divider ms-1 me-1"},null,-1)),kI=["innerHTML"],CI={__name:"CoverSection",props:{sectionData:Object},setup(e){const t=Na(),n=e,i=w(()=>t.isAllAtOnceMode()?n.sectionData.content.locales.welcome:n.sectionData.content.locales.welcomeShort);return(a,s)=>(me(),Tt(yo,{"section-data":n.sectionData},{default:ie(()=>[be("h1",{class:"cover-title display-1",innerHTML:i.value},null,8,SI),wI,h(_I,{class:"info-list",items:n.sectionData.content.items.contactListItems},null,8,["items"]),be("p",{class:"cover-description lead text-normal mb-4 mb-md-5",innerHTML:n.sectionData.content.locales.bio},null,8,kI)]),_:1},8,["section-data"]))}},PI=at(CI,[["__scopeId","data-v-e6f3fa6c"]]),II={class:"section-subheading"},VI={class:"section-subheading-title mb-2 fw-bold text-uppercase"},AI={key:0,class:"section-subheading-description lead text-muted"},Ub={__name:"SubHeading",props:{title:String,description:String,faIcon:String},setup(e){const t=e;return(n,i)=>(me(),Te("div",II,[be("h3",VI,[be("span",null,wt(t.title),1),t.faIcon?(me(),Te("i",{key:0,class:xt([t.faIcon,"ms-2"])},null,2)):kt("",!0)]),be("hr",{class:xt(["solid-divider ms-1 me-1 mb-3",{"mb-sm-4":!t.description}])},null,2),t.description?(me(),Te("p",AI,wt(t.description),1)):kt("",!0)]))}};const TI={__name:"CircleIcon",props:{src:String,type:String,color:String,textClass:String},setup(e){const t=e,n=Ba(),i=["standard","small"],a=()=>n.isStringAnImageUrl(t.src),s=()=>{let r=t.type;i.indexOf(r)===-1&&(r=i[0]);let c="circle-icon";return c+=` circle-icon-${r}`,c},o=()=>{let r=t.src;return t.textClass&&(r+=" "+t.textClass),r},l=()=>!t.color||a()?"":`background-color:${t.color}`;return(r,c)=>(me(),Te("div",{class:xt(s())},[a()?(me(),Tt(yh,{key:0,class:"circle-icon-img",src:t.src,alt:"icon",style:Xi(l())},null,8,["src","style"])):(me(),Te("div",{key:1,class:"circle-icon-fa-icon",style:Xi(l())},[be("i",{class:xt(["fa-inverse",o()])},null,2)],4))],2))}},MI=at(TI,[["__scopeId","data-v-340ab9f5"]]);const EI={class:"progress-bar-wrapper"},DI={class:"progress"},OI=["aria-valuenow"],RI={class:"progress-description"},LI=["innerHTML"],BI={__name:"ProgressBar",props:{percentage:Number,description:String,color:String},setup(e){const t=e,n=Ba(),i=w(()=>n.clamp(t.percentage,0,100)),a=w(()=>{const s=i.value,o=(50+s*.5)/100,l=t.color?`background-color: ${t.color}`:"";return`width: ${s}%; opacity: ${o}; ${l}`});return(s,o)=>(me(),Te("div",EI,[be("div",DI,[be("div",{class:"progress-bar",role:"progressbar",style:Xi(a.value),"aria-valuenow":i.value,"aria-valuemin":"0","aria-valuemax":"100"},null,12,OI)]),be("div",RI,[t.description?(me(),Te("p",{key:0,class:"text-1 text-description mb-0",innerHTML:t.description},null,8,LI)):kt("",!0)])]))}},Yb=at(BI,[["__scopeId","data-v-286948d5"]]);const NI={class:"info-item"},FI={class:"info-item-content"},$I={key:0,class:"info-item-content-header-highlight mb-1"},zI={class:"info-item-title text-4 fw-bold text-normal mb-0"},HI={class:"info-item-progress-span text-1 text-muted fw-bold"},jI={key:1,class:"info-item-content-header"},WI={class:"text-light-7 text-4 mb-0"},UI={key:0,class:"text-3"},YI={key:3,class:"info-item-description-wrapper"},KI=["innerHTML"],GI={__name:"InfoItem",props:{item:Object,highlightedHeader:Boolean,descriptionWithProgressBar:Boolean,iconColorStyle:String,smallDescription:Boolean},setup(e){const t=e,n=s=>{if(t.iconColorStyle==="transparent")return"transparent";if(t.iconColorStyle==="customColor")return t.item.customColor},i=s=>t.iconColorStyle==="customColor"?t.item.customColor:null,a=s=>t.iconColorStyle==="transparent"?"text-primary":"text-white";return(s,o)=>(me(),Te("div",NI,[h(MI,{src:"fa-solid fa-circle fa-xs",type:"standard",color:n(e.item),"text-class":a(e.item),class:"info-item-icon"},null,8,["color","text-class"]),be("div",FI,[e.highlightedHeader?(me(),Te("div",$I,[be("p",zI,wt(e.item.locales.title),1),be("span",HI,wt(e.item.formattedPercentage??""),1)])):(me(),Te("div",jI,[be("p",WI,[be("strong",null,wt(e.item.locales.title),1),e.item.formattedPercentage?(me(),Te("span",UI," – "+wt(e.item.formattedPercentage),1)):kt("",!0)])])),t.descriptionWithProgressBar&&e.item.formattedPercentage?(me(),Tt(Yb,{key:2,percentage:e.item.value,description:e.item.locales.description,color:i(e.item),class:"mt-1"},null,8,["percentage","description","color"])):(me(),Te("div",YI,[be("p",{class:xt(["item-description text-muted mb-0",e.smallDescription?"text-1":"text-2"]),innerHTML:e.item.locales.description},null,10,KI)]))])]))}},bh=at(GI,[["__scopeId","data-v-7d771ca9"]]);const XI={class:"row"},qI={class:"col-12 item-container"},ZI={__name:"InfoList",props:{items:Array},setup(e){const t=e;return(n,i)=>(me(),Te("div",XI,[(me(!0),Te(Pe,null,At(t.items,a=>(me(),Te("div",qI,[h(bh,{item:a,"highlighted-header":!1,"small-description":!1,"description-with-progress-bar":!1,"icon-color-style":"transparent"},null,8,["item"])]))),256))]))}},Hm=at(ZI,[["__scopeId","data-v-5be3d4c5"]]);const JI={class:"row gx-5"},QI={class:"col-12 col-md-6 item-container"},eV={__name:"InfoGrid",props:{items:Array},setup(e){const t=e;return(n,i)=>(me(),Te("div",JI,[(me(!0),Te(Pe,null,At(t.items,a=>(me(),Te("div",QI,[h(bh,{item:a,"highlighted-header":!0,"small-description":!1,"description-with-progress-bar":!0,"icon-color-style":a.formattedPercentage?"transparent":"solid",class:"info-item"},null,8,["item","icon-color-style"])]))),256))]))}},tV=at(eV,[["__scopeId","data-v-506a4c5d"]]);/*! + */const no=typeof window<"u";function pC(e){return e.__esModule||e[Symbol.toStringTag]==="Module"}const ht=Object.assign;function od(e,t){const n={};for(const i in t){const a=t[i];n[i]=yi(a)?a.map(e):e(a)}return n}const vl=()=>{},yi=Array.isArray,yC=/\/$/,bC=e=>e.replace(yC,"");function ld(e,t,n="/"){let i,a={},s="",o="";const l=t.indexOf("#");let r=t.indexOf("?");return l=0&&(r=-1),r>-1&&(i=t.slice(0,r),s=t.slice(r+1,l>-1?l:t.length),a=e(s)),l>-1&&(i=i||t.slice(0,l),o=t.slice(l,t.length)),i=wC(i??t,n),{fullPath:i+(s&&"?")+s+o,path:i,query:a,hash:o}}function _C(e,t){const n=t.query?e(t.query):"";return t.path+(n&&"?")+n+(t.hash||"")}function Cm(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||"/"}function xC(e,t,n){const i=t.matched.length-1,a=n.matched.length-1;return i>-1&&i===a&&go(t.matched[i],n.matched[a])&&Db(t.params,n.params)&&e(t.query)===e(n.query)&&t.hash===n.hash}function go(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function Db(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(!SC(e[n],t[n]))return!1;return!0}function SC(e,t){return yi(e)?Pm(e,t):yi(t)?Pm(t,e):e===t}function Pm(e,t){return yi(t)?e.length===t.length&&e.every((n,i)=>n===t[i]):e.length===1&&e[0]===t}function wC(e,t){if(e.startsWith("/"))return e;if(!e)return t;const n=t.split("/"),i=e.split("/"),a=i[i.length-1];(a===".."||a===".")&&i.push("");let s=n.length-1,o,l;for(o=0;o1&&s--;else break;return n.slice(0,s).join("/")+"/"+i.slice(o-(o===i.length?1:0)).join("/")}var Dl;(function(e){e.pop="pop",e.push="push"})(Dl||(Dl={}));var ml;(function(e){e.back="back",e.forward="forward",e.unknown=""})(ml||(ml={}));function kC(e){if(!e)if(no){const t=document.querySelector("base");e=t&&t.getAttribute("href")||"/",e=e.replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return e[0]!=="/"&&e[0]!=="#"&&(e="/"+e),bC(e)}const CC=/^[^#]+#/;function PC(e,t){return e.replace(CC,"#")+t}function IC(e,t){const n=document.documentElement.getBoundingClientRect(),i=e.getBoundingClientRect();return{behavior:t.behavior,left:i.left-n.left-(t.left||0),top:i.top-n.top-(t.top||0)}}const su=()=>({left:window.pageXOffset,top:window.pageYOffset});function VC(e){let t;if("el"in e){const n=e.el,i=typeof n=="string"&&n.startsWith("#"),a=typeof n=="string"?i?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!a)return;t=IC(a,e)}else t=e;"scrollBehavior"in document.documentElement.style?window.scrollTo(t):window.scrollTo(t.left!=null?t.left:window.pageXOffset,t.top!=null?t.top:window.pageYOffset)}function Im(e,t){return(history.state?history.state.position-t:-1)+e}const Yd=new Map;function AC(e,t){Yd.set(e,t)}function TC(e){const t=Yd.get(e);return Yd.delete(e),t}let MC=()=>location.protocol+"//"+location.host;function Ob(e,t){const{pathname:n,search:i,hash:a}=t,s=e.indexOf("#");if(s>-1){let l=a.includes(e.slice(s))?e.slice(s).length:1,r=a.slice(l);return r[0]!=="/"&&(r="/"+r),Cm(r,"")}return Cm(n,e)+i+a}function EC(e,t,n,i){let a=[],s=[],o=null;const l=({state:f})=>{const v=Ob(e,location),m=n.value,g=t.value;let p=0;if(f){if(n.value=v,t.value=f,o&&o===m){o=null;return}p=g?f.position-g.position:0}else i(v);a.forEach(y=>{y(n.value,m,{delta:p,type:Dl.pop,direction:p?p>0?ml.forward:ml.back:ml.unknown})})};function r(){o=n.value}function c(f){a.push(f);const v=()=>{const m=a.indexOf(f);m>-1&&a.splice(m,1)};return s.push(v),v}function u(){const{history:f}=window;f.state&&f.replaceState(ht({},f.state,{scroll:su()}),"")}function d(){for(const f of s)f();s=[],window.removeEventListener("popstate",l),window.removeEventListener("beforeunload",u)}return window.addEventListener("popstate",l),window.addEventListener("beforeunload",u,{passive:!0}),{pauseListeners:r,listen:c,destroy:d}}function Vm(e,t,n,i=!1,a=!1){return{back:e,current:t,forward:n,replaced:i,position:window.history.length,scroll:a?su():null}}function DC(e){const{history:t,location:n}=window,i={value:Ob(e,n)},a={value:t.state};a.value||s(i.value,{back:null,current:i.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function s(r,c,u){const d=e.indexOf("#"),f=d>-1?(n.host&&document.querySelector("base")?e:e.slice(d))+r:MC()+e+r;try{t[u?"replaceState":"pushState"](c,"",f),a.value=c}catch(v){console.error(v),n[u?"replace":"assign"](f)}}function o(r,c){const u=ht({},t.state,Vm(a.value.back,r,a.value.forward,!0),c,{position:a.value.position});s(r,u,!0),i.value=r}function l(r,c){const u=ht({},a.value,t.state,{forward:r,scroll:su()});s(u.current,u,!0);const d=ht({},Vm(i.value,r,null),{position:u.position+1},c);s(r,d,!1),i.value=r}return{location:i,state:a,push:l,replace:o}}function OC(e){e=kC(e);const t=DC(e),n=EC(e,t.state,t.location,t.replace);function i(s,o=!0){o||n.pauseListeners(),history.go(s)}const a=ht({location:"",base:e,go:i,createHref:PC.bind(null,e)},t,n);return Object.defineProperty(a,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(a,"state",{enumerable:!0,get:()=>t.state.value}),a}function RC(e){return typeof e=="string"||e&&typeof e=="object"}function Rb(e){return typeof e=="string"||typeof e=="symbol"}const va={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0},Lb=Symbol("");var Am;(function(e){e[e.aborted=4]="aborted",e[e.cancelled=8]="cancelled",e[e.duplicated=16]="duplicated"})(Am||(Am={}));function po(e,t){return ht(new Error,{type:e,[Lb]:!0},t)}function Fi(e,t){return e instanceof Error&&Lb in e&&(t==null||!!(e.type&t))}const Tm="[^/]+?",LC={sensitive:!1,strict:!1,start:!0,end:!0},BC=/[.+*?^${}()[\]/\\]/g;function NC(e,t){const n=ht({},LC,t),i=[];let a=n.start?"^":"";const s=[];for(const c of e){const u=c.length?[]:[90];n.strict&&!c.length&&(a+="/");for(let d=0;dt.length?t.length===1&&t[0]===40+40?1:-1:0}function $C(e,t){let n=0;const i=e.score,a=t.score;for(;n0&&t[t.length-1]<0}const zC={type:0,value:""},HC=/[a-zA-Z0-9_]/;function jC(e){if(!e)return[[]];if(e==="/")return[[zC]];if(!e.startsWith("/"))throw new Error(`Invalid path "${e}"`);function t(v){throw new Error(`ERR (${n})/"${c}": ${v}`)}let n=0,i=n;const a=[];let s;function o(){s&&a.push(s),s=[]}let l=0,r,c="",u="";function d(){c&&(n===0?s.push({type:0,value:c}):n===1||n===2||n===3?(s.length>1&&(r==="*"||r==="+")&&t(`A repeatable param (${c}) must be alone in its segment. eg: '/:ids+.`),s.push({type:1,value:c,regexp:u,repeatable:r==="*"||r==="+",optional:r==="*"||r==="?"})):t("Invalid state to consume buffer"),c="")}function f(){c+=r}for(;l{o(b)}:vl}function o(u){if(Rb(u)){const d=i.get(u);d&&(i.delete(u),n.splice(n.indexOf(d),1),d.children.forEach(o),d.alias.forEach(o))}else{const d=n.indexOf(u);d>-1&&(n.splice(d,1),u.record.name&&i.delete(u.record.name),u.children.forEach(o),u.alias.forEach(o))}}function l(){return n}function r(u){let d=0;for(;d=0&&(u.record.path!==n[d].record.path||!Bb(u,n[d]));)d++;n.splice(d,0,u),u.record.name&&!Dm(u)&&i.set(u.record.name,u)}function c(u,d){let f,v={},m,g;if("name"in u&&u.name){if(f=i.get(u.name),!f)throw po(1,{location:u});g=f.record.name,v=ht(Em(d.params,f.keys.filter(b=>!b.optional).map(b=>b.name)),u.params&&Em(u.params,f.keys.map(b=>b.name))),m=f.stringify(v)}else if("path"in u)m=u.path,f=n.find(b=>b.re.test(m)),f&&(v=f.parse(m),g=f.record.name);else{if(f=d.name?i.get(d.name):n.find(b=>b.re.test(d.path)),!f)throw po(1,{location:u,currentLocation:d});g=f.record.name,v=ht({},d.params,u.params),m=f.stringify(v)}const p=[];let y=f;for(;y;)p.unshift(y.record),y=y.parent;return{name:g,path:m,params:v,matched:p,meta:GC(p)}}return e.forEach(u=>s(u)),{addRoute:s,resolve:c,removeRoute:o,getRoutes:l,getRecordMatcher:a}}function Em(e,t){const n={};for(const i of t)i in e&&(n[i]=e[i]);return n}function YC(e){return{path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:void 0,beforeEnter:e.beforeEnter,props:KC(e),children:e.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in e?e.components||null:e.component&&{default:e.component}}}function KC(e){const t={},n=e.props||!1;if("component"in e)t.default=n;else for(const i in e.components)t[i]=typeof n=="object"?n[i]:n;return t}function Dm(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function GC(e){return e.reduce((t,n)=>ht(t,n.meta),{})}function Om(e,t){const n={};for(const i in e)n[i]=i in t?t[i]:e[i];return n}function Bb(e,t){return t.children.some(n=>n===e||Bb(e,n))}const Nb=/#/g,XC=/&/g,qC=/\//g,ZC=/=/g,JC=/\?/g,Fb=/\+/g,QC=/%5B/g,eP=/%5D/g,$b=/%5E/g,tP=/%60/g,zb=/%7B/g,nP=/%7C/g,Hb=/%7D/g,iP=/%20/g;function mh(e){return encodeURI(""+e).replace(nP,"|").replace(QC,"[").replace(eP,"]")}function aP(e){return mh(e).replace(zb,"{").replace(Hb,"}").replace($b,"^")}function Kd(e){return mh(e).replace(Fb,"%2B").replace(iP,"+").replace(Nb,"%23").replace(XC,"%26").replace(tP,"`").replace(zb,"{").replace(Hb,"}").replace($b,"^")}function sP(e){return Kd(e).replace(ZC,"%3D")}function oP(e){return mh(e).replace(Nb,"%23").replace(JC,"%3F")}function lP(e){return e==null?"":oP(e).replace(qC,"%2F")}function pc(e){try{return decodeURIComponent(""+e)}catch{}return""+e}function rP(e){const t={};if(e===""||e==="?")return t;const i=(e[0]==="?"?e.slice(1):e).split("&");for(let a=0;as&&Kd(s)):[i&&Kd(i)]).forEach(s=>{s!==void 0&&(t+=(t.length?"&":"")+n,s!=null&&(t+="="+s))})}return t}function cP(e){const t={};for(const n in e){const i=e[n];i!==void 0&&(t[n]=yi(i)?i.map(a=>a==null?null:""+a):i==null?i:""+i)}return t}const uP=Symbol(""),Lm=Symbol(""),ou=Symbol(""),gh=Symbol(""),Gd=Symbol("");function Yo(){let e=[];function t(i){return e.push(i),()=>{const a=e.indexOf(i);a>-1&&e.splice(a,1)}}function n(){e=[]}return{add:t,list:()=>e.slice(),reset:n}}function ba(e,t,n,i,a){const s=i&&(i.enterCallbacks[a]=i.enterCallbacks[a]||[]);return()=>new Promise((o,l)=>{const r=d=>{d===!1?l(po(4,{from:n,to:t})):d instanceof Error?l(d):RC(d)?l(po(2,{from:t,to:d})):(s&&i.enterCallbacks[a]===s&&typeof d=="function"&&s.push(d),o())},c=e.call(i&&i.instances[a],t,n,r);let u=Promise.resolve(c);e.length<3&&(u=u.then(r)),u.catch(d=>l(d))})}function rd(e,t,n,i){const a=[];for(const s of e)for(const o in s.components){let l=s.components[o];if(!(t!=="beforeRouteEnter"&&!s.instances[o]))if(dP(l)){const c=(l.__vccOpts||l)[t];c&&a.push(ba(c,n,i,s,o))}else{let r=l();a.push(()=>r.then(c=>{if(!c)return Promise.reject(new Error(`Couldn't resolve component "${o}" at "${s.path}"`));const u=pC(c)?c.default:c;s.components[o]=u;const f=(u.__vccOpts||u)[t];return f&&ba(f,n,i,s,o)()}))}}return a}function dP(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function Bm(e){const t=Ke(ou),n=Ke(gh),i=w(()=>t.resolve(Je(e.to))),a=w(()=>{const{matched:r}=i.value,{length:c}=r,u=r[c-1],d=n.matched;if(!u||!d.length)return-1;const f=d.findIndex(go.bind(null,u));if(f>-1)return f;const v=Nm(r[c-2]);return c>1&&Nm(u)===v&&d[d.length-1].path!==v?d.findIndex(go.bind(null,r[c-2])):f}),s=w(()=>a.value>-1&&mP(n.params,i.value.params)),o=w(()=>a.value>-1&&a.value===n.matched.length-1&&Db(n.params,i.value.params));function l(r={}){return vP(r)?t[Je(e.replace)?"replace":"push"](Je(e.to)).catch(vl):Promise.resolve()}return{route:i,href:w(()=>i.value.href),isActive:s,isExactActive:o,navigate:l}}const fP=La({name:"RouterLink",compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:"page"}},useLink:Bm,setup(e,{slots:t}){const n=Ft(Bm(e)),{options:i}=Ke(ou),a=w(()=>({[Fm(e.activeClass,i.linkActiveClass,"router-link-active")]:n.isActive,[Fm(e.exactActiveClass,i.linkExactActiveClass,"router-link-exact-active")]:n.isExactActive}));return()=>{const s=t.default&&t.default(n);return e.custom?s:Fn("a",{"aria-current":n.isExactActive?e.ariaCurrentValue:null,href:n.href,onClick:n.navigate,class:a.value},s)}}}),hP=fP;function vP(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){const t=e.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(t))return}return e.preventDefault&&e.preventDefault(),!0}}function mP(e,t){for(const n in t){const i=t[n],a=e[n];if(typeof i=="string"){if(i!==a)return!1}else if(!yi(a)||a.length!==i.length||i.some((s,o)=>s!==a[o]))return!1}return!0}function Nm(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}const Fm=(e,t,n)=>e??t??n,gP=La({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){const i=Ke(Gd),a=w(()=>e.route||i.value),s=Ke(Lm,0),o=w(()=>{let c=Je(s);const{matched:u}=a.value;let d;for(;(d=u[c])&&!d.components;)c++;return c}),l=w(()=>a.value.matched[o.value]);lt(Lm,w(()=>o.value+1)),lt(uP,l),lt(Gd,a);const r=Z();return _e(()=>[r.value,l.value,e.name],([c,u,d],[f,v,m])=>{u&&(u.instances[d]=c,v&&v!==u&&c&&c===f&&(u.leaveGuards.size||(u.leaveGuards=v.leaveGuards),u.updateGuards.size||(u.updateGuards=v.updateGuards))),c&&u&&(!v||!go(u,v)||!f)&&(u.enterCallbacks[d]||[]).forEach(g=>g(c))},{flush:"post"}),()=>{const c=a.value,u=e.name,d=l.value,f=d&&d.components[u];if(!f)return $m(n.default,{Component:f,route:c});const v=d.props[u],m=v?v===!0?c.params:typeof v=="function"?v(c):v:null,p=Fn(f,ht({},m,t,{onVnodeUnmounted:y=>{y.component.isUnmounted&&(d.instances[u]=null)},ref:r}));return $m(n.default,{Component:p,route:c})||p}}});function $m(e,t){if(!e)return null;const n=e(t);return n.length===1?n[0]:n}const pP=gP;function yP(e){const t=UC(e.routes,e),n=e.parseQuery||rP,i=e.stringifyQuery||Rm,a=e.history,s=Yo(),o=Yo(),l=Yo(),r=Se(va);let c=va;no&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const u=od.bind(null,U=>""+U),d=od.bind(null,lP),f=od.bind(null,pc);function v(U,Q){let ae,X;return Rb(U)?(ae=t.getRecordMatcher(U),X=Q):X=U,t.addRoute(X,ae)}function m(U){const Q=t.getRecordMatcher(U);Q&&t.removeRoute(Q)}function g(){return t.getRoutes().map(U=>U.record)}function p(U){return!!t.getRecordMatcher(U)}function y(U,Q){if(Q=ht({},Q||r.value),typeof U=="string"){const F=ld(n,U,Q.path),q=t.resolve({path:F.path},Q),oe=a.createHref(F.fullPath);return ht(F,q,{params:f(q.params),hash:pc(F.hash),redirectedFrom:void 0,href:oe})}let ae;if("path"in U)ae=ht({},U,{path:ld(n,U.path,Q.path).path});else{const F=ht({},U.params);for(const q in F)F[q]==null&&delete F[q];ae=ht({},U,{params:d(F)}),Q.params=d(Q.params)}const X=t.resolve(ae,Q),Ie=U.hash||"";X.params=u(f(X.params));const E=_C(i,ht({},U,{hash:aP(Ie),path:X.path})),R=a.createHref(E);return ht({fullPath:E,hash:Ie,query:i===Rm?cP(U.query):U.query||{}},X,{redirectedFrom:void 0,href:R})}function b(U){return typeof U=="string"?ld(n,U,r.value.path):ht({},U)}function S(U,Q){if(c!==U)return po(8,{from:Q,to:U})}function _(U){return C(U)}function x(U){return _(ht(b(U),{replace:!0}))}function P(U){const Q=U.matched[U.matched.length-1];if(Q&&Q.redirect){const{redirect:ae}=Q;let X=typeof ae=="function"?ae(U):ae;return typeof X=="string"&&(X=X.includes("?")||X.includes("#")?X=b(X):{path:X},X.params={}),ht({query:U.query,hash:U.hash,params:"path"in X?{}:U.params},X)}}function C(U,Q){const ae=c=y(U),X=r.value,Ie=U.state,E=U.force,R=U.replace===!0,F=P(ae);if(F)return C(ht(b(F),{state:typeof F=="object"?ht({},Ie,F.state):Ie,force:E,replace:R}),Q||ae);const q=ae;q.redirectedFrom=Q;let oe;return!E&&xC(i,X,ae)&&(oe=po(16,{to:q,from:X}),le(X,X,!0,!1)),(oe?Promise.resolve(oe):M(q,X)).catch(he=>Fi(he)?Fi(he,2)?he:ee(he):B(he,q,X)).then(he=>{if(he){if(Fi(he,2))return C(ht({replace:R},b(he.to),{state:typeof he.to=="object"?ht({},Ie,he.to.state):Ie,force:E}),Q||q)}else he=D(q,X,!0,R,Ie);return O(q,X,he),he})}function V(U,Q){const ae=S(U,Q);return ae?Promise.reject(ae):Promise.resolve()}function I(U){const Q=Me.values().next().value;return Q&&typeof Q.runWithContext=="function"?Q.runWithContext(U):U()}function M(U,Q){let ae;const[X,Ie,E]=bP(U,Q);ae=rd(X.reverse(),"beforeRouteLeave",U,Q);for(const F of X)F.leaveGuards.forEach(q=>{ae.push(ba(q,U,Q))});const R=V.bind(null,U,Q);return ae.push(R),te(ae).then(()=>{ae=[];for(const F of s.list())ae.push(ba(F,U,Q));return ae.push(R),te(ae)}).then(()=>{ae=rd(Ie,"beforeRouteUpdate",U,Q);for(const F of Ie)F.updateGuards.forEach(q=>{ae.push(ba(q,U,Q))});return ae.push(R),te(ae)}).then(()=>{ae=[];for(const F of E)if(F.beforeEnter)if(yi(F.beforeEnter))for(const q of F.beforeEnter)ae.push(ba(q,U,Q));else ae.push(ba(F.beforeEnter,U,Q));return ae.push(R),te(ae)}).then(()=>(U.matched.forEach(F=>F.enterCallbacks={}),ae=rd(E,"beforeRouteEnter",U,Q),ae.push(R),te(ae))).then(()=>{ae=[];for(const F of o.list())ae.push(ba(F,U,Q));return ae.push(R),te(ae)}).catch(F=>Fi(F,8)?F:Promise.reject(F))}function O(U,Q,ae){l.list().forEach(X=>I(()=>X(U,Q,ae)))}function D(U,Q,ae,X,Ie){const E=S(U,Q);if(E)return E;const R=Q===va,F=no?history.state:{};ae&&(X||R?a.replace(U.fullPath,ht({scroll:R&&F&&F.scroll},Ie)):a.push(U.fullPath,Ie)),r.value=U,le(U,Q,ae,R),ee()}let N;function j(){N||(N=a.listen((U,Q,ae)=>{if(!Oe.listening)return;const X=y(U),Ie=P(X);if(Ie){C(ht(Ie,{replace:!0}),X).catch(vl);return}c=X;const E=r.value;no&&AC(Im(E.fullPath,ae.delta),su()),M(X,E).catch(R=>Fi(R,12)?R:Fi(R,2)?(C(R.to,X).then(F=>{Fi(F,20)&&!ae.delta&&ae.type===Dl.pop&&a.go(-1,!1)}).catch(vl),Promise.reject()):(ae.delta&&a.go(-ae.delta,!1),B(R,X,E))).then(R=>{R=R||D(X,E,!1),R&&(ae.delta&&!Fi(R,8)?a.go(-ae.delta,!1):ae.type===Dl.pop&&Fi(R,20)&&a.go(-1,!1)),O(X,E,R)}).catch(vl)}))}let Y=Yo(),K=Yo(),J;function B(U,Q,ae){ee(U);const X=K.list();return X.length?X.forEach(Ie=>Ie(U,Q,ae)):console.error(U),Promise.reject(U)}function G(){return J&&r.value!==va?Promise.resolve():new Promise((U,Q)=>{Y.add([U,Q])})}function ee(U){return J||(J=!U,j(),Y.list().forEach(([Q,ae])=>U?ae(U):Q()),Y.reset()),U}function le(U,Q,ae,X){const{scrollBehavior:Ie}=e;if(!no||!Ie)return Promise.resolve();const E=!ae&&TC(Im(U.fullPath,0))||(X||!ae)&&history.state&&history.state.scroll||null;return Ze().then(()=>Ie(U,Q,E)).then(R=>R&&VC(R)).catch(R=>B(R,U,Q))}const ce=U=>a.go(U);let ge;const Me=new Set,Oe={currentRoute:r,listening:!0,addRoute:v,removeRoute:m,hasRoute:p,getRoutes:g,resolve:y,options:e,push:_,replace:x,go:ce,back:()=>ce(-1),forward:()=>ce(1),beforeEach:s.add,beforeResolve:o.add,afterEach:l.add,onError:K.add,isReady:G,install(U){const Q=this;U.component("RouterLink",hP),U.component("RouterView",pP),U.config.globalProperties.$router=Q,Object.defineProperty(U.config.globalProperties,"$route",{enumerable:!0,get:()=>Je(r)}),no&&!ge&&r.value===va&&(ge=!0,_(a.location).catch(Ie=>{}));const ae={};for(const Ie in va)Object.defineProperty(ae,Ie,{get:()=>r.value[Ie],enumerable:!0});U.provide(ou,Q),U.provide(gh,Yf(ae)),U.provide(Gd,r);const X=U.unmount;Me.add(U),U.unmount=function(){Me.delete(U),Me.size<1&&(c=va,N&&N(),N=null,r.value=va,ge=!1,J=!1),X()}}};function te(U){return U.reduce((Q,ae)=>Q.then(()=>I(ae)),Promise.resolve())}return Oe}function bP(e,t){const n=[],i=[],a=[],s=Math.max(t.matched.length,e.matched.length);for(let o=0;ogo(c,l))?i.push(l):n.push(l));const r=e.matched[o];r&&(t.matched.find(c=>go(c,r))||a.push(r))}return[n,i,a]}function ph(){return Ke(ou)}function _P(){return Ke(gh)}const at=(e,t)=>{const n=e.__vccOpts||e;for(const[i,a]of t)n[i]=a;return n},xP=e=>(Oa("data-v-66ce0b56"),e=e(),Ra(),e),SP={class:"image-view"},wP=["src","alt"],kP={key:0,class:"spinner"},CP=xP(()=>be("img",{alt:"loading...",class:"preloader-gif",src:"data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4KPHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBzdHlsZT0ibWFyZ2luOiBhdXRvOyBiYWNrZ3JvdW5kOiBub25lOyBkaXNwbGF5OiBibG9jazsgc2hhcGUtcmVuZGVyaW5nOiBhdXRvOyIgd2lkdGg9IjIwMHB4IiBoZWlnaHQ9IjIwMHB4IiB2aWV3Qm94PSIwIDAgMTAwIDEwMCIgcHJlc2VydmVBc3BlY3RSYXRpbz0ieE1pZFlNaWQiPgo8Y2lyY2xlIGN4PSI1MCIgY3k9IjUwIiByPSIzMiIgc3Ryb2tlLXdpZHRoPSI4IiBzdHJva2U9IiM1NDUxNTEiIHN0cm9rZS1kYXNoYXJyYXk9IjUwLjI2NTQ4MjQ1NzQzNjY5IDUwLjI2NTQ4MjQ1NzQzNjY5IiBmaWxsPSJub25lIiBzdHJva2UtbGluZWNhcD0icm91bmQiPgogIDxhbmltYXRlVHJhbnNmb3JtIGF0dHJpYnV0ZU5hbWU9InRyYW5zZm9ybSIgdHlwZT0icm90YXRlIiBkdXI9IjFzIiByZXBlYXRDb3VudD0iaW5kZWZpbml0ZSIga2V5VGltZXM9IjA7MSIgdmFsdWVzPSIwIDUwIDUwOzM2MCA1MCA1MCI+PC9hbmltYXRlVHJhbnNmb3JtPgo8L2NpcmNsZT4KPGNpcmNsZSBjeD0iNTAiIGN5PSI1MCIgcj0iMjMiIHN0cm9rZS13aWR0aD0iOCIgc3Ryb2tlPSIjYzNjM2M1IiBzdHJva2UtZGFzaGFycmF5PSIzNi4xMjgzMTU1MTYyODI2MiAzNi4xMjgzMTU1MTYyODI2MiIgc3Ryb2tlLWRhc2hvZmZzZXQ9IjM2LjEyODMxNTUxNjI4MjYyIiBmaWxsPSJub25lIiBzdHJva2UtbGluZWNhcD0icm91bmQiPgogIDxhbmltYXRlVHJhbnNmb3JtIGF0dHJpYnV0ZU5hbWU9InRyYW5zZm9ybSIgdHlwZT0icm90YXRlIiBkdXI9IjFzIiByZXBlYXRDb3VudD0iaW5kZWZpbml0ZSIga2V5VGltZXM9IjA7MSIgdmFsdWVzPSIwIDUwIDUwOy0zNjAgNTAgNTAiPjwvYW5pbWF0ZVRyYW5zZm9ybT4KPC9jaXJjbGU+CjwhLS0gW2xkaW9dIGdlbmVyYXRlZCBieSBodHRwczovL2xvYWRpbmcuaW8vIC0tPjwvc3ZnPg=="},null,-1)),PP=[CP],IP={__name:"ImageView",props:{src:String,alt:String,ignoreOnImageCount:Boolean,spinnerEnabled:Boolean},emits:["loading","loaded","error","completed"],setup(e,{expose:t,emit:n}){const i=e,a=au(),s=n,o=Z(null),l=Z(null),r=w(()=>a.HTML_CLASSES.imageViewImage+(i.ignoreOnImageCount?` ${a.HTML_CLASSES.imageViewImageIgnoredOnCount}`:""));_t(()=>{v()}),_e(()=>i.src,()=>{v()});const c=()=>l.value===a.LoadStatus.LOADED||l.value===a.LoadStatus.ERROR,u=()=>{f(a.LoadStatus.LOADED)},d=()=>{f(a.LoadStatus.ERROR)},f=m=>{switch(l.value=m,o.value.setAttribute("loadStatus",m),m){case a.LoadStatus.LOADING:s("loading");break;case a.LoadStatus.LOADED:s("loaded"),s("completed");break;case a.LoadStatus.ERROR:s("error"),s("completed");break}},v=()=>{f(typeof i.src!="string"?a.LoadStatus.ERROR:a.LoadStatus.LOADING)};return t({isLoaded:c}),(m,g)=>(me(),Te("div",SP,[ft(be("img",{ref_key:"img",ref:o,src:i.src,alt:i.alt,class:xt(r.value),onLoad:u,onError:d},null,42,wP),[[mn,c()]]),i.spinnerEnabled?ft((me(),Te("div",kP,PP,512)),[[mn,!c()]]):kt("",!0)]))}},yh=at(IP,[["__scopeId","data-v-66ce0b56"]]);const VP={class:"nav-profile-card"},AP={class:"nav-profile-card-title lead-2"},TP={class:"nav-profile-card-subtitle text-4 mb-1"},MP={__name:"NavProfileCard",props:{profileData:Object},setup(e){const t=e;return(n,i)=>(me(),Te("div",VP,[h(yh,{src:t.profileData.profilePictureUrl,alt:t.profileData.name,class:"img-pfp"},null,8,["src","alt"]),be("h4",AP,wt(t.profileData.name),1),be("h6",TP,wt(t.profileData.locales.role),1)]))}},jb=at(MP,[["__scopeId","data-v-ad1c764a"]]);const Wb=e=>(Oa("data-v-1fb31b9d"),e=e(),Ra(),e),EP={class:"nav-sidebar"},DP={key:0,class:"nav-sidebar-content"},OP={class:"nav-links"},RP=["onClick"],LP={class:"nav-links"},BP={class:"nav-item"},NP=Wb(()=>be("i",{class:"fa-solid fa-magnifying-glass"},null,-1)),FP={key:0,class:"nav-item"},$P=Wb(()=>be("i",{class:"fa-solid fa-pen-to-square"},null,-1)),zP={key:1,class:"nav-sidebar-footer"},HP={__name:"NavSidebar",emits:["linkClicked"],setup(e,{emit:t}){const n=t,i=Oi(),a=Na(),s=ph(),o=Z(""),l=Z(null);Qc(()=>{s.currentRoute.value.query.query?r():s.push("/login")}),Jt(async()=>{await r()});async function r(){let v="";if(s.currentRoute.value.query.query)v=s.currentRoute.value.query.query;else try{const p=await(await fetch("https://res-a-me-api.resilientdb.com/loadUser",{method:"GET",headers:{"Content-type":"application/json; charset=UTF-8",Authorization:"Bearer "+sessionStorage.getItem("access_token")}})).json();p.status===200&&(v=p.logged_in_as)}catch(g){console.error("Error fetching user data:",g)}try{const p=await(await fetch("https://res-a-me-api.resilientdb.com/updateResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8"},body:JSON.stringify({email:v})})).json();p.status!==200&&console.error("Error fetching user resume: ",p.message)}catch{console.error("Error fetching user resume: ",error)}let m=i.getProfile();fetch(`/images/pictures/${v}.png`).then(g=>{g.ok?m.profilePictureUrl=`/images/pictures/${v}.png`:m.profilePictureUrl="/images/pictures/avatar.png"}).then(()=>{l.value=m})}const c=v=>{let m="nav-item";return a.isSectionActive(v.id)&&(m+=" nav-item-selected"),m},u=v=>{n("linkClicked",v.id)},d=()=>!!sessionStorage.getItem("access_token"),f=()=>{fetch("https://res-a-me-api.resilientdb.com/logout",{method:"GET",headers:{"Content-type":"application/json; charset=UTF-8"}}).then(v=>{if(!v.ok)throw new Error("Network response was not ok");return v.json()}).then(v=>{v.message==="Logout successful"?(sessionStorage.clear(),s.push("/")):o.value=v.message||"Logout failed. Please try again."}).catch(v=>{console.error("Logout error:",v),o.value=v.message||"An error occurred. Please try again."})};return(v,m)=>{const g=we("v-btn"),p=we("v-col");return me(),Te("nav",EP,[l.value?(me(),Te("div",DP,[h(jb,{"profile-data":l.value},null,8,["profile-data"]),be("ul",OP,[(me(!0),Te(Pe,null,At(Je(i).getSections(),y=>(me(),Te("li",{class:xt(c(y))},[be("button",{class:"nav-link",onClick:b=>u(y)},[be("i",{class:xt(y.faIcon)},null,2),Xe(" "+wt(Je(i).getString(y.id)),1)],8,RP)],2))),256))]),be("ul",LP,[be("li",BP,[be("button",{class:"nav-link",onClick:m[0]||(m[0]=y=>Je(s).push("/"))},[NP,Xe(" Search ")])]),d()?(me(),Te("li",FP,[be("button",{class:"nav-link",onClick:m[1]||(m[1]=y=>Je(s).push("/edit"))},[$P,Xe(" Edit Resume ")])])):kt("",!0)])])):kt("",!0),l.value?(me(),Te("div",zP,[h(p,null,{default:ie(()=>[d()?(me(),Tt(g,{key:0,variant:"flat",onClick:f,color:"#1a73e8"},{default:ie(()=>[Xe("Logout")]),_:1})):kt("",!0),d()?kt("",!0):(me(),Tt(g,{key:1,variant:"flat",onClick:m[2]||(m[2]=y=>Je(s).push("/login")),color:"#1a73e8"},{default:ie(()=>[Xe("Login")]),_:1}))]),_:1})])):kt("",!0)])}}},jP=at(HP,[["__scopeId","data-v-1fb31b9d"]]);const WP={key:0,class:"nav-pills"},UP=["onClick"],YP={class:"d-none d-sm-inline"},KP={__name:"NavPills",props:{sections:Array},emits:["linkClicked"],setup(e,{emit:t}){const n=e,i=Oi(),a=Na(),s=t,o=r=>`nav-item ${a.isSectionActive(r.id)?"nav-item-selected":""}`,l=r=>{s("linkClicked",r)};return(r,c)=>n.sections&&n.sections.length>=2?(me(),Te("div",WP,[(me(!0),Te(Pe,null,At(n.sections,u=>(me(),Te("button",{class:xt(o(u)),onClick:d=>l(u)},[be("i",{class:xt(["nav-pill-icon",u.faIcon])},null,2),be("span",YP,wt(Je(i).getString(u.id)),1)],10,UP))),256))])):kt("",!0)}},zm=at(KP,[["__scopeId","data-v-77e48e8c"]]);const GP={class:"nav-header"},XP={class:"nav-header-container"},qP={key:0,class:"nav-pills-fixed-container nav-pills-fixed-container-shrink",id:"nav-pills-fixed-container"},ZP={key:0,class:"nav-pills-page-title text-white"},JP={__name:"NavHeader",emits:["linkClicked"],setup(e,{emit:t}){const n=Oi(),i=To(),a=Na(),s=Ba(),o=t,l=w(()=>{const d=a.getActiveCategoryId();return n.getCategorySections(d)}),r=w(()=>{if(!s.isIOS()||window.innerHeight<600)return null;const d=a.getActiveSectionId();return n.getString(d)});_t(()=>{window.addEventListener("resize",c),window.addEventListener("scroll",c),c()}),Ms(()=>{window.removeEventListener("resize",c),window.removeEventListener("scroll",c)}),_e(()=>a.getActiveSectionId(),()=>{const d=document.getElementById("nav-pills-fixed-container");d&&(d.classList.add("nav-pills-fixed-container-no-transition"),setTimeout(()=>{d.classList.remove("nav-pills-fixed-container-no-transition")},100))});const c=()=>{const d=document.getElementById("nav-pills"),f=document.getElementById("nav-pills-fixed-container");if(!d||!f)return;i.isElementOutsideBounds(d)?f.classList.remove("nav-pills-fixed-container-shrink"):f.classList.add("nav-pills-fixed-container-shrink")},u=d=>{o("linkClicked",d.id)};return(d,f)=>(me(),Te("div",GP,[be("div",XP,[Je(n).getProfile()?(me(),Tt(jb,{key:0,"profile-data":Je(n).getProfile()},null,8,["profile-data"])):kt("",!0),h(zm,{class:"nav-pills",id:"nav-pills",sections:l.value,onLinkClicked:u},null,8,["sections"])]),l.value.length>=2?(me(),Te("div",qP,[r.value?(me(),Te("h4",ZP,wt(r.value),1)):kt("",!0),h(zm,{class:"nav-pills-fixed",id:"nav-pills-fixed",sections:l.value,onLinkClicked:u},null,8,["sections"])])):kt("",!0)]))}},QP=at(JP,[["__scopeId","data-v-0b712a98"]]);const eI={class:"nav-tabs-wrapper"},tI={class:"nav-tabs"},nI=["onClick"],iI={class:"nav-tab-button-label"},aI={__name:"NavTabs",emits:["linkClicked"],setup(e,{emit:t}){const n=t,i=Oi(),a=Na(),s=l=>{let r="nav-tab-button";return a.isCategoryActive(l.id)&&(r+=" nav-tab-button-selected"),r},o=l=>{n("linkClicked",l.id)};return(l,r)=>(me(),Te("div",eI,[be("nav",tI,[(me(!0),Te(Pe,null,At(Je(i).getCategories(),c=>(me(),Te("button",{class:xt(s(c)),onClick:u=>o(c)},[be("i",{class:xt(["nav-tab-button-icon",c.faIcon])},null,2),be("span",iI,wt(Je(i).getString(c.id)),1)],10,nI))),256))])]))}},sI=at(aI,[["__scopeId","data-v-37eedae7"]]);const oI=e=>(Oa("data-v-8790a924"),e=e(),Ra(),e),lI=["id"],rI={key:0,class:"section-container"},cI={key:0,class:"section-header"},uI=["innerHTML"],dI=oI(()=>be("hr",{class:"solid-divider ms-1 me-1 mb-3 mb-lg-4"},null,-1)),fI={key:0,class:"lead text-muted"},hI={class:"section-content"},vI={__name:"SectionTemplate",props:{sectionData:Object},setup(e){const t=e,n=Oi(),i=Na(),a=w(()=>t.sectionData&&i.isSectionVisible(t.sectionData.id)),s=w(()=>{let l="section";return i.isAllAtOnceMode()&&(l+=" section-with-division"),t.sectionData.cover&&(l+=" section-cover"),l}),o=w(()=>i.isAllAtOnceMode()?t.sectionData.content.locales.title:n.getString(t.sectionData.id));return(l,r)=>ft((me(),Te("section",{id:t.sectionData.id,class:xt(s.value)},[t.sectionData.content?(me(),Te("div",rI,[t.sectionData.content.locales.title?(me(),Te("div",cI,[be("h1",{class:"section-title mb-1 mb-lg-2 fw-bold text-uppercase",innerHTML:o.value},null,8,uI),dI,t.sectionData.content.locales.description?(me(),Te("p",fI,wt(t.sectionData.content.locales.description),1)):kt("",!0)])):kt("",!0),be("div",hI,[Fy(l.$slots,"default",{},void 0,!0)])])):kt("",!0)],10,lI)),[[mn,a.value]])}},yo=at(vI,[["__scopeId","data-v-8790a924"]]);const mI={class:"inline-list lead"},gI={class:"list-item"},pI=["href"],yI={key:1},bI={__name:"InlineList",props:{items:Array},setup(e){const t=e,n=s=>s.valueShort||s.value,i=s=>s.href,a=s=>s.faIcon;return(s,o)=>(me(),Te("div",mI,[(me(!0),Te(Pe,null,At(t.items,l=>(me(),Te("div",gI,[i(l)?(me(),Te("a",{key:0,href:i(l),class:"info-item-link"},[a(l)?(me(),Te("i",{key:0,class:xt([a(l),"list-item-icon"])},null,2)):kt("",!0),Xe(" "+wt(n(l)),1)],8,pI)):(me(),Te("span",yI,[a(l)?(me(),Te("i",{key:0,class:xt([a(l),"list-item-icon"])},null,2)):kt("",!0),Xe(" "+wt(n(l)),1)]))]))),256))]))}},_I=at(bI,[["__scopeId","data-v-c4644c6f"]]);const xI=e=>(Oa("data-v-e6f3fa6c"),e=e(),Ra(),e),SI=["innerHTML"],wI=xI(()=>be("hr",{class:"solid-divider ms-1 me-1"},null,-1)),kI=["innerHTML"],CI={__name:"CoverSection",props:{sectionData:Object},setup(e){const t=Na(),n=e,i=w(()=>t.isAllAtOnceMode()?n.sectionData.content.locales.welcome:n.sectionData.content.locales.welcomeShort);return(a,s)=>(me(),Tt(yo,{"section-data":n.sectionData},{default:ie(()=>[be("h1",{class:"cover-title display-1",innerHTML:i.value},null,8,SI),wI,h(_I,{class:"info-list",items:n.sectionData.content.items.contactListItems},null,8,["items"]),be("p",{class:"cover-description lead text-normal mb-4 mb-md-5",innerHTML:n.sectionData.content.locales.bio},null,8,kI)]),_:1},8,["section-data"]))}},PI=at(CI,[["__scopeId","data-v-e6f3fa6c"]]),II={class:"section-subheading"},VI={class:"section-subheading-title mb-2 fw-bold text-uppercase"},AI={key:0,class:"section-subheading-description lead text-muted"},Ub={__name:"SubHeading",props:{title:String,description:String,faIcon:String},setup(e){const t=e;return(n,i)=>(me(),Te("div",II,[be("h3",VI,[be("span",null,wt(t.title),1),t.faIcon?(me(),Te("i",{key:0,class:xt([t.faIcon,"ms-2"])},null,2)):kt("",!0)]),be("hr",{class:xt(["solid-divider ms-1 me-1 mb-3",{"mb-sm-4":!t.description}])},null,2),t.description?(me(),Te("p",AI,wt(t.description),1)):kt("",!0)]))}};const TI={__name:"CircleIcon",props:{src:String,type:String,color:String,textClass:String},setup(e){const t=e,n=Ba(),i=["standard","small"],a=()=>n.isStringAnImageUrl(t.src),s=()=>{let r=t.type;i.indexOf(r)===-1&&(r=i[0]);let c="circle-icon";return c+=` circle-icon-${r}`,c},o=()=>{let r=t.src;return t.textClass&&(r+=" "+t.textClass),r},l=()=>!t.color||a()?"":`background-color:${t.color}`;return(r,c)=>(me(),Te("div",{class:xt(s())},[a()?(me(),Tt(yh,{key:0,class:"circle-icon-img",src:t.src,alt:"icon",style:Xi(l())},null,8,["src","style"])):(me(),Te("div",{key:1,class:"circle-icon-fa-icon",style:Xi(l())},[be("i",{class:xt(["fa-inverse",o()])},null,2)],4))],2))}},MI=at(TI,[["__scopeId","data-v-340ab9f5"]]);const EI={class:"progress-bar-wrapper"},DI={class:"progress"},OI=["aria-valuenow"],RI={class:"progress-description"},LI=["innerHTML"],BI={__name:"ProgressBar",props:{percentage:Number,description:String,color:String},setup(e){const t=e,n=Ba(),i=w(()=>n.clamp(t.percentage,0,100)),a=w(()=>{const s=i.value,o=(50+s*.5)/100,l=t.color?`background-color: ${t.color}`:"";return`width: ${s}%; opacity: ${o}; ${l}`});return(s,o)=>(me(),Te("div",EI,[be("div",DI,[be("div",{class:"progress-bar",role:"progressbar",style:Xi(a.value),"aria-valuenow":i.value,"aria-valuemin":"0","aria-valuemax":"100"},null,12,OI)]),be("div",RI,[t.description?(me(),Te("p",{key:0,class:"text-1 text-description mb-0",innerHTML:t.description},null,8,LI)):kt("",!0)])]))}},Yb=at(BI,[["__scopeId","data-v-286948d5"]]);const NI={class:"info-item"},FI={class:"info-item-content"},$I={key:0,class:"info-item-content-header-highlight mb-1"},zI={class:"info-item-title text-4 fw-bold text-normal mb-0"},HI={class:"info-item-progress-span text-1 text-muted fw-bold"},jI={key:1,class:"info-item-content-header"},WI={class:"text-light-7 text-4 mb-0"},UI={key:0,class:"text-3"},YI={key:3,class:"info-item-description-wrapper"},KI=["innerHTML"],GI={__name:"InfoItem",props:{item:Object,highlightedHeader:Boolean,descriptionWithProgressBar:Boolean,iconColorStyle:String,smallDescription:Boolean},setup(e){const t=e,n=s=>{if(t.iconColorStyle==="transparent")return"transparent";if(t.iconColorStyle==="customColor")return t.item.customColor},i=s=>t.iconColorStyle==="customColor"?t.item.customColor:null,a=s=>t.iconColorStyle==="transparent"?"text-primary":"text-white";return(s,o)=>(me(),Te("div",NI,[h(MI,{src:"fa-solid fa-circle fa-xs",type:"standard",color:n(e.item),"text-class":a(e.item),class:"info-item-icon"},null,8,["color","text-class"]),be("div",FI,[e.highlightedHeader?(me(),Te("div",$I,[be("p",zI,wt(e.item.locales.title),1),be("span",HI,wt(e.item.formattedPercentage??""),1)])):(me(),Te("div",jI,[be("p",WI,[be("strong",null,wt(e.item.locales.title),1),e.item.formattedPercentage?(me(),Te("span",UI," – "+wt(e.item.formattedPercentage),1)):kt("",!0)])])),t.descriptionWithProgressBar&&e.item.formattedPercentage?(me(),Tt(Yb,{key:2,percentage:e.item.value,description:e.item.locales.description,color:i(e.item),class:"mt-1"},null,8,["percentage","description","color"])):(me(),Te("div",YI,[be("p",{class:xt(["item-description text-muted mb-0",e.smallDescription?"text-1":"text-2"]),innerHTML:e.item.locales.description},null,10,KI)]))])]))}},bh=at(GI,[["__scopeId","data-v-7d771ca9"]]);const XI={class:"row"},qI={class:"col-12 item-container"},ZI={__name:"InfoList",props:{items:Array},setup(e){const t=e;return(n,i)=>(me(),Te("div",XI,[(me(!0),Te(Pe,null,At(t.items,a=>(me(),Te("div",qI,[h(bh,{item:a,"highlighted-header":!1,"small-description":!1,"description-with-progress-bar":!1,"icon-color-style":"transparent"},null,8,["item"])]))),256))]))}},Hm=at(ZI,[["__scopeId","data-v-5be3d4c5"]]);const JI={class:"row gx-5"},QI={class:"col-12 col-md-6 item-container"},eV={__name:"InfoGrid",props:{items:Array},setup(e){const t=e;return(n,i)=>(me(),Te("div",JI,[(me(!0),Te(Pe,null,At(t.items,a=>(me(),Te("div",QI,[h(bh,{item:a,"highlighted-header":!0,"small-description":!1,"description-with-progress-bar":!0,"icon-color-style":a.formattedPercentage?"transparent":"solid",class:"info-item"},null,8,["item","icon-color-style"])]))),256))]))}},tV=at(eV,[["__scopeId","data-v-506a4c5d"]]);/*! * @kurkle/color v0.3.2 * https://github.com/kurkle/color#readme * (c) 2023 Jukka Kurkela @@ -19,7 +19,7 @@ var rw=Object.defineProperty;var cw=(e,t,n)=>t in e?rw(e,t,{enumerable:!0,config * Released under the MIT License */class VA{constructor(){this._request=null,this._charts=new Map,this._running=!1,this._lastDate=void 0}_notify(t,n,i,a){const s=n.listeners[a],o=n.duration;s.forEach(l=>l({chart:t,initial:n.initial,numSteps:o,currentStep:Math.min(i-n.start,o)}))}_refresh(){this._request||(this._running=!0,this._request=t_.call(window,()=>{this._update(),this._request=null,this._running&&this._refresh()}))}_update(t=Date.now()){let n=0;this._charts.forEach((i,a)=>{if(!i.running||!i.items.length)return;const s=i.items;let o=s.length-1,l=!1,r;for(;o>=0;--o)r=s[o],r._active?(r._total>i.duration&&(i.duration=r._total),r.tick(t),l=!0):(s[o]=s[s.length-1],s.pop());l&&(a.draw(),this._notify(a,i,t,"progress")),s.length||(i.running=!1,this._notify(a,i,t,"complete"),i.initial=!1),n+=s.length}),this._lastDate=t,n===0&&(this._running=!1)}_getAnims(t){const n=this._charts;let i=n.get(t);return i||(i={running:!1,initial:!0,items:[],listeners:{complete:[],progress:[]}},n.set(t,i)),i}listen(t,n,i){this._getAnims(t).listeners[n].push(i)}add(t,n){!n||!n.length||this._getAnims(t).items.push(...n)}has(t){return this._getAnims(t).items.length>0}start(t){const n=this._charts.get(t);n&&(n.running=!0,n.start=Date.now(),n.duration=n.items.reduce((i,a)=>Math.max(i,a._duration),0),this._refresh())}running(t){if(!this._running)return!1;const n=this._charts.get(t);return!(!n||!n.running||!n.items.length)}stop(t){const n=this._charts.get(t);if(!n||!n.items.length)return;const i=n.items;let a=i.length-1;for(;a>=0;--a)i[a].cancel();n.items=[],this._notify(t,n,Date.now(),"complete")}remove(t){return this._charts.delete(t)}}var Hi=new VA;const cg="transparent",AA={boolean(e,t,n){return n>.5?t:e},color(e,t,n){const i=tg(e||cg),a=i.valid&&tg(t||cg);return a&&a.valid?a.mix(i,n).hexString():t},number(e,t,n){return e+(t-e)*n}};class TA{constructor(t,n,i,a){const s=n[i];a=Lr([t.to,a,s,t.from]);const o=Lr([t.from,s,a]);this._active=!0,this._fn=t.fn||AA[t.type||typeof o],this._easing=yl[t.easing]||yl.linear,this._start=Math.floor(Date.now()+(t.delay||0)),this._duration=this._total=Math.floor(t.duration),this._loop=!!t.loop,this._target=n,this._prop=i,this._from=o,this._to=a,this._promises=void 0}active(){return this._active}update(t,n,i){if(this._active){this._notify(!1);const a=this._target[this._prop],s=i-this._start,o=this._duration-s;this._start=i,this._duration=Math.floor(Math.max(o,t.duration)),this._total+=s,this._loop=!!t.loop,this._to=Lr([t.to,n,a,t.from]),this._from=Lr([t.from,a,n])}}cancel(){this._active&&(this.tick(Date.now()),this._active=!1,this._notify(!1))}tick(t){const n=t-this._start,i=this._duration,a=this._prop,s=this._from,o=this._loop,l=this._to;let r;if(this._active=s!==l&&(o||n1?2-r:r,r=this._easing(Math.min(1,Math.max(0,r))),this._target[a]=this._fn(s,l,r)}wait(){const t=this._promises||(this._promises=[]);return new Promise((n,i)=>{t.push({res:n,rej:i})})}_notify(t){const n=t?"res":"rej",i=this._promises||[];for(let a=0;a{const s=t[a];if(!st(s))return;const o={};for(const l of n)o[l]=s[l];(Ot(s.properties)&&s.properties||[a]).forEach(l=>{(l===a||!i.has(l))&&i.set(l,o)})})}_animateOptions(t,n){const i=n.options,a=EA(t,i);if(!a)return[];const s=this._createAnimations(a,i);return i.$shared&&MA(t.options.$animations,i).then(()=>{t.options=i},()=>{}),s}_createAnimations(t,n){const i=this._properties,a=[],s=t.$animations||(t.$animations={}),o=Object.keys(n),l=Date.now();let r;for(r=o.length-1;r>=0;--r){const c=o[r];if(c.charAt(0)==="$")continue;if(c==="options"){a.push(...this._animateOptions(t,n));continue}const u=n[c];let d=s[c];const f=i.get(c);if(d)if(f&&d.active()){d.update(f,u,l);continue}else d.cancel();if(!f||!f.duration){t[c]=u;continue}s[c]=d=new TA(f,t,c,u),a.push(d)}return a}update(t,n){if(this._properties.size===0){Object.assign(t,n);return}const i=this._createAnimations(t,n);if(i.length)return Hi.add(this._chart,i),!0}}function MA(e,t){const n=[],i=Object.keys(t);for(let a=0;a0||!n&&s<0)return a.index}return null}function vg(e,t){const{chart:n,_cachedMeta:i}=e,a=n._stacks||(n._stacks={}),{iScale:s,vScale:o,index:l}=i,r=s.axis,c=o.axis,u=LA(s,o,i),d=t.length;let f;for(let v=0;vn[i].axis===t).shift()}function FA(e,t){return Es(e,{active:!1,dataset:void 0,datasetIndex:t,index:t,mode:"default",type:"dataset"})}function $A(e,t,n){return Es(e,{active:!1,dataIndex:t,parsed:void 0,raw:void 0,element:n,index:t,mode:"default",type:"data"})}function Ko(e,t){const n=e.controller.index,i=e.vScale&&e.vScale.axis;if(i){t=t||e._parsed;for(const a of t){const s=a._stacks;if(!s||s[i]===void 0||s[i][n]===void 0)return;delete s[i][n],s[i]._visualValues!==void 0&&s[i]._visualValues[n]!==void 0&&delete s[i]._visualValues[n]}}}const vd=e=>e==="reset"||e==="none",mg=(e,t)=>t?e:Object.assign({},e),zA=(e,t,n)=>e&&!t.hidden&&t._stacked&&{keys:h_(n,!0),values:null};class xl{constructor(t,n){this.chart=t,this._ctx=t.ctx,this.index=n,this._cachedDataOpts={},this._cachedMeta=this.getMeta(),this._type=this._cachedMeta.type,this.options=void 0,this._parsing=!1,this._data=void 0,this._objectData=void 0,this._sharedOptions=void 0,this._drawStart=void 0,this._drawCount=void 0,this.enableOptionSharing=!1,this.supportsDecimation=!1,this.$context=void 0,this._syncList=[],this.datasetElementType=new.target.datasetElementType,this.dataElementType=new.target.dataElementType,this.initialize()}initialize(){const t=this._cachedMeta;this.configure(),this.linkScales(),t._stacked=fg(t.vScale,t),this.addElements(),this.options.fill&&!this.chart.isPluginEnabled("filler")&&console.warn("Tried to use the 'fill' option without the 'Filler' plugin enabled. Please import and register the 'Filler' plugin and make sure it is not disabled in the options")}updateIndex(t){this.index!==t&&Ko(this._cachedMeta),this.index=t}linkScales(){const t=this.chart,n=this._cachedMeta,i=this.getDataset(),a=(d,f,v,m)=>d==="x"?f:d==="r"?m:v,s=n.xAxisID=Rt(i.xAxisID,hd(t,"x")),o=n.yAxisID=Rt(i.yAxisID,hd(t,"y")),l=n.rAxisID=Rt(i.rAxisID,hd(t,"r")),r=n.indexAxis,c=n.iAxisID=a(r,s,o,l),u=n.vAxisID=a(r,o,s,l);n.xScale=this.getScaleForId(s),n.yScale=this.getScaleForId(o),n.rScale=this.getScaleForId(l),n.iScale=this.getScaleForId(c),n.vScale=this.getScaleForId(u)}getDataset(){return this.chart.data.datasets[this.index]}getMeta(){return this.chart.getDatasetMeta(this.index)}getScaleForId(t){return this.chart.scales[t]}_getOtherScale(t){const n=this._cachedMeta;return t===n.iScale?n.vScale:n.iScale}reset(){this._update("reset")}_destroy(){const t=this._cachedMeta;this._data&&Jm(this._data,this),t._stacked&&Ko(t)}_dataCheck(){const t=this.getDataset(),n=t.data||(t.data=[]),i=this._data;if(st(n))this._data=RA(n);else if(i!==n){if(i){Jm(i,this);const a=this._cachedMeta;Ko(a),a._parsed=[]}n&&Object.isExtensible(n)&&FV(n,this),this._syncList=[],this._data=n}}addElements(){const t=this._cachedMeta;this._dataCheck(),this.datasetElementType&&(t.dataset=new this.datasetElementType)}buildOrUpdateElements(t){const n=this._cachedMeta,i=this.getDataset();let a=!1;this._dataCheck();const s=n._stacked;n._stacked=fg(n.vScale,n),n.stack!==i.stack&&(a=!0,Ko(n),n.stack=i.stack),this._resyncElements(t),(a||s!==n._stacked)&&vg(this,n._parsed)}configure(){const t=this.chart.config,n=t.datasetScopeKeys(this._type),i=t.getOptionScopes(this.getDataset(),n,!0);this.options=t.createResolver(i,this.getContext()),this._parsing=this.options.parsing,this._cachedDataOpts={}}parse(t,n){const{_cachedMeta:i,_data:a}=this,{iScale:s,_stacked:o}=i,l=s.axis;let r=t===0&&n===a.length?!0:i._sorted,c=t>0&&i._parsed[t-1],u,d,f;if(this._parsing===!1)i._parsed=a,i._sorted=!0,f=a;else{Ot(a[t])?f=this.parseArrayData(i,a,t,n):st(a[t])?f=this.parseObjectData(i,a,t,n):f=this.parsePrimitiveData(i,a,t,n);const v=()=>d[l]===null||c&&d[l]g||d=0;--f)if(!m()){this.updateRangeFromParsed(c,t,v,r);break}}return c}getAllParsedValues(t){const n=this._cachedMeta._parsed,i=[];let a,s,o;for(a=0,s=n.length;a=0&&tthis.getContext(i,a,n),g=c.resolveNamedOptions(f,v,m,d);return g.$shared&&(g.$shared=r,s[o]=Object.freeze(mg(g,r))),g}_resolveAnimations(t,n,i){const a=this.chart,s=this._cachedDataOpts,o=`animation-${n}`,l=s[o];if(l)return l;let r;if(a.options.animation!==!1){const u=this.chart.config,d=u.datasetAnimationScopeKeys(this._type,n),f=u.getOptionScopes(this.getDataset(),d);r=u.createResolver(f,this.getContext(t,i,n))}const c=new f_(a,r&&r.animations);return r&&r._cacheable&&(s[o]=Object.freeze(c)),c}getSharedOptions(t){if(t.$shared)return this._sharedOptions||(this._sharedOptions=Object.assign({},t))}includeOptions(t,n){return!n||vd(t)||this.chart._animationsDisabled}_getSharedOptions(t,n){const i=this.resolveDataElementOptions(t,n),a=this._sharedOptions,s=this.getSharedOptions(i),o=this.includeOptions(n,s)||s!==a;return this.updateSharedOptions(s,n,i),{sharedOptions:s,includeOptions:o}}updateElement(t,n,i,a){vd(a)?Object.assign(t,i):this._resolveAnimations(n,a).update(t,i)}updateSharedOptions(t,n,i){t&&!vd(n)&&this._resolveAnimations(void 0,n).update(t,i)}_setStyle(t,n,i,a){t.active=a;const s=this.getStyle(n,a);this._resolveAnimations(n,i,a).update(t,{options:!a&&this.getSharedOptions(s)||s})}removeHoverStyle(t,n,i){this._setStyle(t,i,"active",!1)}setHoverStyle(t,n,i){this._setStyle(t,i,"active",!0)}_removeDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!1)}_setDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!0)}_resyncElements(t){const n=this._data,i=this._cachedMeta.data;for(const[l,r,c]of this._syncList)this[l](r,c);this._syncList=[];const a=i.length,s=n.length,o=Math.min(s,a);o&&this.parse(0,o),s>a?this._insertElements(a,s-a,t):s{for(c.length+=n,l=c.length-1;l>=o;l--)c[l]=c[l-n]};for(r(s),l=t;lkc(S,l,r,!0)?1:Math.max(_,_*n,x,x*n),m=(S,_,x)=>kc(S,l,r,!0)?-1:Math.min(_,_*n,x,x*n),g=v(0,c,d),p=v(Wt,u,f),y=m(zt,c,d),b=m(zt+Wt,u,f);i=(g-y)/2,a=(p-b)/2,s=-(g+y)/2,o=-(p+b)/2}return{ratioX:i,ratioY:a,offsetX:s,offsetY:o}}class il extends xl{constructor(t,n){super(t,n),this.enableOptionSharing=!0,this.innerRadius=void 0,this.outerRadius=void 0,this.offsetX=void 0,this.offsetY=void 0}linkScales(){}parse(t,n){const i=this.getDataset().data,a=this._cachedMeta;if(this._parsing===!1)a._parsed=i;else{let s=r=>+i[r];if(st(i[t])){const{key:r="value"}=this._parsing;s=c=>+Ll(i[c],r)}let o,l;for(o=t,l=t+n;o0&&!isNaN(t)?$t*(Math.abs(t)/n):0}getLabelAndValue(t){const n=this._cachedMeta,i=this.chart,a=i.data.labels||[],s=lu(n._parsed[t],i.options.locale);return{label:a[t]||"",value:s}}getMaxBorderWidth(t){let n=0;const i=this.chart;let a,s,o,l,r;if(!t){for(a=0,s=i.data.datasets.length;at!=="spacing",_indexable:t=>t!=="spacing"&&!t.startsWith("borderDash")&&!t.startsWith("hoverBorderDash")}),He(il,"overrides",{aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){const n=t.data;if(n.labels.length&&n.datasets.length){const{labels:{pointStyle:i,color:a}}=t.legend.options;return n.labels.map((s,o)=>{const r=t.getDatasetMeta(0).controller.getStyle(o);return{text:s,fillStyle:r.backgroundColor,strokeStyle:r.borderColor,fontColor:a,lineWidth:r.borderWidth,pointStyle:i,hidden:!t.getDataVisibility(o),index:o}})}return[]}},onClick(t,n,i){i.chart.toggleDataVisibility(n.index),i.chart.update()}}}});class Qd extends il{}He(Qd,"id","pie"),He(Qd,"defaults",{cutout:0,rotation:0,circumference:360,radius:"100%"});function Qa(){throw new Error("This method is not implemented: Check that a complete date adapter is provided.")}class Eh{constructor(t){He(this,"options");this.options=t||{}}static override(t){Object.assign(Eh.prototype,t)}init(){}formats(){return Qa()}parse(){return Qa()}format(){return Qa()}add(){return Qa()}diff(){return Qa()}startOf(){return Qa()}endOf(){return Qa()}}var jA={_date:Eh};function WA(e,t,n,i){const{controller:a,data:s,_sorted:o}=e,l=a._cachedMeta.iScale;if(l&&t===l.axis&&t!=="r"&&o&&s.length){const r=l._reversePixels?BV:qd;if(i){if(a._sharedOptions){const c=s[0],u=typeof c.getRange=="function"&&c.getRange(t);if(u){const d=r(s,t,n-u),f=r(s,t,n+u);return{lo:d.lo,hi:f.hi}}}}else return r(s,t,n)}return{lo:0,hi:s.length-1}}function sr(e,t,n,i,a){const s=e.getSortedVisibleDatasetMetas(),o=n[t];for(let l=0,r=s.length;l{r[o](t[n],a)&&(s.push({element:r,datasetIndex:c,index:u}),l=l||r.inRange(t.x,t.y,a))}),i&&!l?[]:s}var GA={evaluateInteractionItems:sr,modes:{index(e,t,n,i){const a=is(t,e),s=n.axis||"x",o=n.includeInvisible||!1,l=n.intersect?md(e,a,s,i,o):gd(e,a,s,!1,i,o),r=[];return l.length?(e.getSortedVisibleDatasetMetas().forEach(c=>{const u=l[0].index,d=c.data[u];d&&!d.skip&&r.push({element:d,datasetIndex:c.index,index:u})}),r):[]},dataset(e,t,n,i){const a=is(t,e),s=n.axis||"xy",o=n.includeInvisible||!1;let l=n.intersect?md(e,a,s,i,o):gd(e,a,s,!1,i,o);if(l.length>0){const r=l[0].datasetIndex,c=e.getDatasetMeta(r).data;l=[];for(let u=0;un.pos===t)}function pg(e,t){return e.filter(n=>v_.indexOf(n.pos)===-1&&n.box.axis===t)}function Xo(e,t){return e.sort((n,i)=>{const a=t?i:n,s=t?n:i;return a.weight===s.weight?a.index-s.index:a.weight-s.weight})}function XA(e){const t=[];let n,i,a,s,o,l;for(n=0,i=(e||[]).length;nc.box.fullSize),!0),i=Xo(Go(t,"left"),!0),a=Xo(Go(t,"right")),s=Xo(Go(t,"top"),!0),o=Xo(Go(t,"bottom")),l=pg(t,"x"),r=pg(t,"y");return{fullSize:n,leftAndTop:i.concat(s),rightAndBottom:a.concat(r).concat(o).concat(l),chartArea:Go(t,"chartArea"),vertical:i.concat(a).concat(r),horizontal:s.concat(o).concat(l)}}function yg(e,t,n,i){return Math.max(e[n],t[n])+Math.max(e[i],t[i])}function m_(e,t){e.top=Math.max(e.top,t.top),e.left=Math.max(e.left,t.left),e.bottom=Math.max(e.bottom,t.bottom),e.right=Math.max(e.right,t.right)}function QA(e,t,n,i){const{pos:a,box:s}=n,o=e.maxPadding;if(!st(a)){n.size&&(e[a]-=n.size);const d=i[n.stack]||{size:0,count:1};d.size=Math.max(d.size,n.horizontal?s.height:s.width),n.size=d.size/d.count,e[a]+=n.size}s.getPadding&&m_(o,s.getPadding());const l=Math.max(0,t.outerWidth-yg(o,e,"left","right")),r=Math.max(0,t.outerHeight-yg(o,e,"top","bottom")),c=l!==e.w,u=r!==e.h;return e.w=l,e.h=r,n.horizontal?{same:c,other:u}:{same:u,other:c}}function eT(e){const t=e.maxPadding;function n(i){const a=Math.max(t[i]-e[i],0);return e[i]+=a,a}e.y+=n("top"),e.x+=n("left"),n("right"),n("bottom")}function tT(e,t){const n=t.maxPadding;function i(a){const s={left:0,top:0,right:0,bottom:0};return a.forEach(o=>{s[o]=Math.max(t[o],n[o])}),s}return i(e?["left","right"]:["top","bottom"])}function al(e,t,n,i){const a=[];let s,o,l,r,c,u;for(s=0,o=e.length,c=0;s{typeof g.beforeLayout=="function"&&g.beforeLayout()});const u=r.reduce((g,p)=>p.box.options&&p.box.options.display===!1?g:g+1,0)||1,d=Object.freeze({outerWidth:t,outerHeight:n,padding:a,availableWidth:s,availableHeight:o,vBoxMaxWidth:s/2/u,hBoxMaxHeight:o/2}),f=Object.assign({},a);m_(f,Kn(i));const v=Object.assign({maxPadding:f,w:s,h:o,x:a.left,y:a.top},a),m=ZA(r.concat(c),d);al(l.fullSize,v,d,m),al(r,v,d,m),al(c,v,d,m)&&al(r,v,d,m),eT(v),bg(l.leftAndTop,v,d,m),v.x+=v.w,v.y+=v.h,bg(l.rightAndBottom,v,d,m),e.chartArea={left:v.left,top:v.top,right:v.left+v.w,bottom:v.top+v.h,height:v.h,width:v.w},vt(l.chartArea,g=>{const p=g.box;Object.assign(p,e.chartArea),p.update(v.w,v.h,{left:0,top:0,right:0,bottom:0})})}};class g_{acquireContext(t,n){}releaseContext(t){return!1}addEventListener(t,n,i){}removeEventListener(t,n,i){}getDevicePixelRatio(){return 1}getMaximumSize(t,n,i,a){return n=Math.max(0,n||t.width),i=i||t.height,{width:n,height:Math.max(0,a?Math.floor(n/a):i)}}isAttached(t){return!0}updateConfig(t){}}class nT extends g_{acquireContext(t){return t&&t.getContext&&t.getContext("2d")||null}updateConfig(t){t.options.animation=!1}}const nc="$chartjs",iT={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},_g=e=>e===null||e==="";function aT(e,t){const n=e.style,i=e.getAttribute("height"),a=e.getAttribute("width");if(e[nc]={initial:{height:i,width:a,style:{display:n.display,height:n.height,width:n.width}}},n.display=n.display||"block",n.boxSizing=n.boxSizing||"border-box",_g(a)){const s=rg(e,"width");s!==void 0&&(e.width=s)}if(_g(i))if(e.style.height==="")e.height=e.width/(t||2);else{const s=rg(e,"height");s!==void 0&&(e.height=s)}return e}const p_=wA?{passive:!0}:!1;function sT(e,t,n){e.addEventListener(t,n,p_)}function oT(e,t,n){e.canvas.removeEventListener(t,n,p_)}function lT(e,t){const n=iT[e.type]||e.type,{x:i,y:a}=is(e,t);return{type:n,chart:t,native:e,x:i!==void 0?i:null,y:a!==void 0?a:null}}function Ic(e,t){for(const n of e)if(n===t||n.contains(t))return!0}function rT(e,t,n){const i=e.canvas,a=new MutationObserver(s=>{let o=!1;for(const l of s)o=o||Ic(l.addedNodes,i),o=o&&!Ic(l.removedNodes,i);o&&n()});return a.observe(document,{childList:!0,subtree:!0}),a}function cT(e,t,n){const i=e.canvas,a=new MutationObserver(s=>{let o=!1;for(const l of s)o=o||Ic(l.removedNodes,i),o=o&&!Ic(l.addedNodes,i);o&&n()});return a.observe(document,{childList:!0,subtree:!0}),a}const Nl=new Map;let xg=0;function y_(){const e=window.devicePixelRatio;e!==xg&&(xg=e,Nl.forEach((t,n)=>{n.currentDevicePixelRatio!==e&&t()}))}function uT(e,t){Nl.size||window.addEventListener("resize",y_),Nl.set(e,t)}function dT(e){Nl.delete(e),Nl.size||window.removeEventListener("resize",y_)}function fT(e,t,n){const i=e.canvas,a=i&&Mh(i);if(!a)return;const s=n_((l,r)=>{const c=a.clientWidth;n(l,r),c{const r=l[0],c=r.contentRect.width,u=r.contentRect.height;c===0&&u===0||s(c,u)});return o.observe(a),uT(e,s),o}function pd(e,t,n){n&&n.disconnect(),t==="resize"&&dT(e)}function hT(e,t,n){const i=e.canvas,a=n_(s=>{e.ctx!==null&&n(lT(s,e))},e);return sT(i,t,a),a}class vT extends g_{acquireContext(t,n){const i=t&&t.getContext&&t.getContext("2d");return i&&i.canvas===t?(aT(t,n),i):null}releaseContext(t){const n=t.canvas;if(!n[nc])return!1;const i=n[nc].initial;["height","width"].forEach(s=>{const o=i[s];Dt(o)?n.removeAttribute(s):n.setAttribute(s,o)});const a=i.style||{};return Object.keys(a).forEach(s=>{n.style[s]=a[s]}),n.width=n.width,delete n[nc],!0}addEventListener(t,n,i){this.removeEventListener(t,n);const a=t.$proxies||(t.$proxies={}),o={attach:rT,detach:cT,resize:fT}[n]||hT;a[n]=o(t,n,i)}removeEventListener(t,n){const i=t.$proxies||(t.$proxies={}),a=i[n];if(!a)return;({attach:pd,detach:pd,resize:pd}[n]||oT)(t,n,a),i[n]=void 0}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(t,n,i,a){return SA(t,n,i,a)}isAttached(t){const n=Mh(t);return!!(n&&n.isConnected)}}function mT(e){return!Th()||typeof OffscreenCanvas<"u"&&e instanceof OffscreenCanvas?nT:vT}var Jr;let or=(Jr=class{constructor(){He(this,"x");He(this,"y");He(this,"active",!1);He(this,"options");He(this,"$animations")}tooltipPosition(t){const{x:n,y:i}=this.getProps(["x","y"],t);return{x:n,y:i}}hasValue(){return wc(this.x)&&wc(this.y)}getProps(t,n){const i=this.$animations;if(!n||!i)return this;const a={};return t.forEach(s=>{a[s]=i[s]&&i[s].active()?i[s]._to:this[s]}),a}},He(Jr,"defaults",{}),He(Jr,"defaultRoutes"),Jr);function gT(e,t){const n=e.options.ticks,i=pT(e),a=Math.min(n.maxTicksLimit||i,i),s=n.major.enabled?bT(t):[],o=s.length,l=s[0],r=s[o-1],c=[];if(o>a)return _T(t,c,s,o/a),c;const u=yT(s,t,a);if(o>0){let d,f;const v=o>1?Math.round((r-l)/(o-1)):null;for(Fr(t,c,u,Dt(v)?0:l-v,l),d=0,f=o-1;da)return r}return Math.max(a,1)}function bT(e){const t=[];let n,i;for(n=0,i=e.length;ne==="left"?"right":e==="right"?"left":e,Sg=(e,t,n)=>t==="top"||t==="left"?e[t]+n:e[t]-n,wg=(e,t)=>Math.min(t||e,e);function kg(e,t){const n=[],i=e.length/t,a=e.length;let s=0;for(;so+l)))return r}function kT(e,t){vt(e,n=>{const i=n.gc,a=i.length/2;let s;if(a>t){for(s=0;si?i:n,i=a&&n>i?n:i,{min:Hn(n,Hn(i,n)),max:Hn(i,Hn(n,i))}}getPadding(){return{left:this.paddingLeft||0,top:this.paddingTop||0,right:this.paddingRight||0,bottom:this.paddingBottom||0}}getTicks(){return this.ticks}getLabels(){const t=this.chart.data;return this.options.labels||(this.isHorizontal()?t.xLabels:t.yLabels)||t.labels||[]}getLabelItems(t=this.chart.chartArea){return this._labelItems||(this._labelItems=this._computeLabelItems(t))}beforeLayout(){this._cache={},this._dataLimitsCached=!1}beforeUpdate(){Nt(this.options.beforeUpdate,[this])}update(t,n,i){const{beginAtZero:a,grace:s,ticks:o}=this.options,l=o.sampleSize;this.beforeUpdate(),this.maxWidth=t,this.maxHeight=n,this._margins=i=Object.assign({left:0,right:0,top:0,bottom:0},i),this.ticks=null,this._labelSizes=null,this._gridLineItems=null,this._labelItems=null,this.beforeSetDimensions(),this.setDimensions(),this.afterSetDimensions(),this._maxLength=this.isHorizontal()?this.width+i.left+i.right:this.height+i.top+i.bottom,this._dataLimitsCached||(this.beforeDataLimits(),this.determineDataLimits(),this.afterDataLimits(),this._range=lA(this,s,a),this._dataLimitsCached=!0),this.beforeBuildTicks(),this.ticks=this.buildTicks()||[],this.afterBuildTicks();const r=l=s||i<=1||!this.isHorizontal()){this.labelRotation=a;return}const u=this._getLabelSizes(),d=u.widest.width,f=u.highest.height,v=ai(this.chart.width-d,0,this.maxWidth);l=t.offset?this.maxWidth/i:v/(i-1),d+6>l&&(l=v/(i-(t.offset?.5:1)),r=this.maxHeight-qo(t.grid)-n.padding-Cg(t.title,this.chart.options.font),c=Math.sqrt(d*d+f*f),o=kh(Math.min(Math.asin(ai((u.highest.height+6)/l,-1,1)),Math.asin(ai(r/c,-1,1))-Math.asin(ai(f/c,-1,1)))),o=Math.max(a,Math.min(s,o))),this.labelRotation=o}afterCalculateLabelRotation(){Nt(this.options.afterCalculateLabelRotation,[this])}afterAutoSkip(){}beforeFit(){Nt(this.options.beforeFit,[this])}fit(){const t={width:0,height:0},{chart:n,options:{ticks:i,title:a,grid:s}}=this,o=this._isVisible(),l=this.isHorizontal();if(o){const r=Cg(a,n.options.font);if(l?(t.width=this.maxWidth,t.height=qo(s)+r):(t.height=this.maxHeight,t.width=qo(s)+r),i.display&&this.ticks.length){const{first:c,last:u,widest:d,highest:f}=this._getLabelSizes(),v=i.padding*2,m=Ai(this.labelRotation),g=Math.cos(m),p=Math.sin(m);if(l){const y=i.mirror?0:p*d.width+g*f.height;t.height=Math.min(this.maxHeight,t.height+y+v)}else{const y=i.mirror?0:g*d.width+p*f.height;t.width=Math.min(this.maxWidth,t.width+y+v)}this._calculatePadding(c,u,p,g)}}this._handleMargins(),l?(this.width=this._length=n.width-this._margins.left-this._margins.right,this.height=t.height):(this.width=t.width,this.height=this._length=n.height-this._margins.top-this._margins.bottom)}_calculatePadding(t,n,i,a){const{ticks:{align:s,padding:o},position:l}=this.options,r=this.labelRotation!==0,c=l!=="top"&&this.axis==="x";if(this.isHorizontal()){const u=this.getPixelForTick(0)-this.left,d=this.right-this.getPixelForTick(this.ticks.length-1);let f=0,v=0;r?c?(f=a*t.width,v=i*n.height):(f=i*t.height,v=a*n.width):s==="start"?v=n.width:s==="end"?f=t.width:s!=="inner"&&(f=t.width/2,v=n.width/2),this.paddingLeft=Math.max((f-u+o)*this.width/(this.width-u),0),this.paddingRight=Math.max((v-d+o)*this.width/(this.width-d),0)}else{let u=n.height/2,d=t.height/2;s==="start"?(u=0,d=t.height):s==="end"&&(u=n.height,d=0),this.paddingTop=u+o,this.paddingBottom=d+o}}_handleMargins(){this._margins&&(this._margins.left=Math.max(this.paddingLeft,this._margins.left),this._margins.top=Math.max(this.paddingTop,this._margins.top),this._margins.right=Math.max(this.paddingRight,this._margins.right),this._margins.bottom=Math.max(this.paddingBottom,this._margins.bottom))}afterFit(){Nt(this.options.afterFit,[this])}isHorizontal(){const{axis:t,position:n}=this.options;return n==="top"||n==="bottom"||t==="x"}isFullSize(){return this.options.fullSize}_convertTicksToLabels(t){this.beforeTickToLabelConversion(),this.generateTickLabels(t);let n,i;for(n=0,i=t.length;n({width:o[I]||0,height:l[I]||0});return{first:V(0),last:V(n-1),widest:V(P),highest:V(C),widths:o,heights:l}}getLabelForValue(t){return t}getPixelForValue(t,n){return NaN}getValueForPixel(t){}getPixelForTick(t){const n=this.ticks;return t<0||t>n.length-1?null:this.getPixelForValue(n[t].value)}getPixelForDecimal(t){this._reversePixels&&(t=1-t);const n=this._startPixel+t*this._length;return RV(this._alignToPixels?Ja(this.chart,n,0):n)}getDecimalForPixel(t){const n=(t-this._startPixel)/this._length;return this._reversePixels?1-n:n}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){const{min:t,max:n}=this;return t<0&&n<0?n:t>0&&n>0?t:0}getContext(t){const n=this.ticks||[];if(t>=0&&tl*a?l/i:r/a:r*a0}_computeGridLineItems(t){const n=this.axis,i=this.chart,a=this.options,{grid:s,position:o,border:l}=a,r=s.offset,c=this.isHorizontal(),d=this.ticks.length+(r?1:0),f=qo(s),v=[],m=l.setContext(this.getContext()),g=m.display?m.width:0,p=g/2,y=function(K){return Ja(i,K,g)};let b,S,_,x,P,C,V,I,M,O,D,N;if(o==="top")b=y(this.bottom),C=this.bottom-f,I=b-p,O=y(t.top)+p,N=t.bottom;else if(o==="bottom")b=y(this.top),O=t.top,N=y(t.bottom)-p,C=b+p,I=this.top+f;else if(o==="left")b=y(this.right),P=this.right-f,V=b-p,M=y(t.left)+p,D=t.right;else if(o==="right")b=y(this.left),M=t.left,D=y(t.right)-p,P=b+p,V=this.left+f;else if(n==="x"){if(o==="center")b=y((t.top+t.bottom)/2+.5);else if(st(o)){const K=Object.keys(o)[0],J=o[K];b=y(this.chart.scales[K].getPixelForValue(J))}O=t.top,N=t.bottom,C=b+p,I=C+f}else if(n==="y"){if(o==="center")b=y((t.left+t.right)/2);else if(st(o)){const K=Object.keys(o)[0],J=o[K];b=y(this.chart.scales[K].getPixelForValue(J))}P=b-p,V=P-f,M=t.left,D=t.right}const j=Rt(a.ticks.maxTicksLimit,d),Y=Math.max(1,Math.ceil(d/j));for(S=0;S0&&(te-=Me/2);break}le={left:te,top:Oe,width:Me+ce.width,height:ge+ce.height,color:Y.backdropColor}}p.push({label:_,font:I,textOffset:D,options:{rotation:g,color:J,strokeColor:B,strokeWidth:G,textAlign:ee,textBaseline:N,translation:[x,P],backdrop:le}})}return p}_getXAxisLabelAlignment(){const{position:t,ticks:n}=this.options;if(-Ai(this.labelRotation))return t==="top"?"left":"right";let a="center";return n.align==="start"?a="left":n.align==="end"?a="right":n.align==="inner"&&(a="inner"),a}_getYAxisLabelAlignment(t){const{position:n,ticks:{crossAlign:i,mirror:a,padding:s}}=this.options,o=this._getLabelSizes(),l=t+s,r=o.widest.width;let c,u;return n==="left"?a?(u=this.right+s,i==="near"?c="left":i==="center"?(c="center",u+=r/2):(c="right",u+=r)):(u=this.right-l,i==="near"?c="right":i==="center"?(c="center",u-=r/2):(c="left",u=this.left)):n==="right"?a?(u=this.left+s,i==="near"?c="right":i==="center"?(c="center",u-=r/2):(c="left",u-=r)):(u=this.left+l,i==="near"?c="left":i==="center"?(c="center",u+=r/2):(c="right",u=this.right)):c="right",{textAlign:c,x:u}}_computeLabelArea(){if(this.options.ticks.mirror)return;const t=this.chart,n=this.options.position;if(n==="left"||n==="right")return{top:0,left:this.left,bottom:t.height,right:this.right};if(n==="top"||n==="bottom")return{top:this.top,left:0,bottom:this.bottom,right:t.width}}drawBackground(){const{ctx:t,options:{backgroundColor:n},left:i,top:a,width:s,height:o}=this;n&&(t.save(),t.fillStyle=n,t.fillRect(i,a,s,o),t.restore())}getLineWidthForValue(t){const n=this.options.grid;if(!this._isVisible()||!n.display)return 0;const a=this.ticks.findIndex(s=>s.value===t);return a>=0?n.setContext(this.getContext(a)).lineWidth:0}drawGrid(t){const n=this.options.grid,i=this.ctx,a=this._gridLineItems||(this._gridLineItems=this._computeGridLineItems(t));let s,o;const l=(r,c,u)=>{!u.width||!u.color||(i.save(),i.lineWidth=u.width,i.strokeStyle=u.color,i.setLineDash(u.borderDash||[]),i.lineDashOffset=u.borderDashOffset,i.beginPath(),i.moveTo(r.x,r.y),i.lineTo(c.x,c.y),i.stroke(),i.restore())};if(n.display)for(s=0,o=a.length;s{this.draw(s)}}]:[{z:i,draw:s=>{this.drawBackground(),this.drawGrid(s),this.drawTitle()}},{z:a,draw:()=>{this.drawBorder()}},{z:n,draw:s=>{this.drawLabels(s)}}]}getMatchingVisibleMetas(t){const n=this.chart.getSortedVisibleDatasetMetas(),i=this.axis+"AxisID",a=[];let s,o;for(s=0,o=n.length;s{const i=n.split("."),a=i.pop(),s=[e].concat(i).join("."),o=t[n].split("."),l=o.pop(),r=o.join(".");Ut.route(s,a,r,l)})}function MT(e){return"id"in e&&"defaults"in e}class ET{constructor(){this.controllers=new $r(xl,"datasets",!0),this.elements=new $r(or,"elements"),this.plugins=new $r(Object,"plugins"),this.scales=new $r(Mo,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements]}add(...t){this._each("register",t)}remove(...t){this._each("unregister",t)}addControllers(...t){this._each("register",t,this.controllers)}addElements(...t){this._each("register",t,this.elements)}addPlugins(...t){this._each("register",t,this.plugins)}addScales(...t){this._each("register",t,this.scales)}getController(t){return this._get(t,this.controllers,"controller")}getElement(t){return this._get(t,this.elements,"element")}getPlugin(t){return this._get(t,this.plugins,"plugin")}getScale(t){return this._get(t,this.scales,"scale")}removeControllers(...t){this._each("unregister",t,this.controllers)}removeElements(...t){this._each("unregister",t,this.elements)}removePlugins(...t){this._each("unregister",t,this.plugins)}removeScales(...t){this._each("unregister",t,this.scales)}_each(t,n,i){[...n].forEach(a=>{const s=i||this._getRegistryForType(a);i||s.isForType(a)||s===this.plugins&&a.id?this._exec(t,s,a):vt(a,o=>{const l=i||this._getRegistryForType(o);this._exec(t,l,o)})})}_exec(t,n,i){const a=wh(t);Nt(i["before"+a],[],i),n[t](i),Nt(i["after"+a],[],i)}_getRegistryForType(t){for(let n=0;ns.filter(l=>!o.some(r=>l.plugin.id===r.plugin.id));this._notify(a(n,i),t,"stop"),this._notify(a(i,n),t,"start")}}function OT(e){const t={},n=[],i=Object.keys(Ci.plugins.items);for(let s=0;s1&&Pg(e[0].toLowerCase());if(i)return i}throw new Error(`Cannot determine type of '${e}' axis. Please provide 'axis' or 'position' option.`)}function Ig(e,t,n){if(n[t+"AxisID"]===e)return{axis:t}}function zT(e,t){if(t.data&&t.data.datasets){const n=t.data.datasets.filter(i=>i.xAxisID===e||i.yAxisID===e);if(n.length)return Ig(e,"x",n[0])||Ig(e,"y",n[0])}return{}}function HT(e,t){const n=xs[e.type]||{scales:{}},i=t.scales||{},a=ef(e.type,t),s=Object.create(null);return Object.keys(i).forEach(o=>{const l=i[o];if(!st(l))return console.error(`Invalid scale configuration for scale: ${o}`);if(l._proxy)return console.warn(`Ignoring resolver passed as options for scale: ${o}`);const r=tf(o,l,zT(o,e),Ut.scales[l.type]),c=FT(r,a),u=n.scales||{};s[o]=gl(Object.create(null),[{axis:r},l,u[r],u[c]])}),e.data.datasets.forEach(o=>{const l=o.type||e.type,r=o.indexAxis||ef(l,t),u=(xs[l]||{}).scales||{};Object.keys(u).forEach(d=>{const f=NT(d,r),v=o[f+"AxisID"]||f;s[v]=s[v]||Object.create(null),gl(s[v],[{axis:f},i[v],u[d]])})}),Object.keys(s).forEach(o=>{const l=s[o];gl(l,[Ut.scales[l.type],Ut.scale])}),s}function b_(e){const t=e.options||(e.options={});t.plugins=Rt(t.plugins,{}),t.scales=HT(e,t)}function __(e){return e=e||{},e.datasets=e.datasets||[],e.labels=e.labels||[],e}function jT(e){return e=e||{},e.data=__(e.data),b_(e),e}const Vg=new Map,x_=new Set;function zr(e,t){let n=Vg.get(e);return n||(n=t(),Vg.set(e,n),x_.add(n)),n}const Zo=(e,t,n)=>{const i=Ll(t,n);i!==void 0&&e.add(i)};class WT{constructor(t){this._config=jT(t),this._scopeCache=new Map,this._resolverCache=new Map}get platform(){return this._config.platform}get type(){return this._config.type}set type(t){this._config.type=t}get data(){return this._config.data}set data(t){this._config.data=__(t)}get options(){return this._config.options}set options(t){this._config.options=t}get plugins(){return this._config.plugins}update(){const t=this._config;this.clearCache(),b_(t)}clearCache(){this._scopeCache.clear(),this._resolverCache.clear()}datasetScopeKeys(t){return zr(t,()=>[[`datasets.${t}`,""]])}datasetAnimationScopeKeys(t,n){return zr(`${t}.transition.${n}`,()=>[[`datasets.${t}.transitions.${n}`,`transitions.${n}`],[`datasets.${t}`,""]])}datasetElementScopeKeys(t,n){return zr(`${t}-${n}`,()=>[[`datasets.${t}.elements.${n}`,`datasets.${t}`,`elements.${n}`,""]])}pluginScopeKeys(t){const n=t.id,i=this.type;return zr(`${i}-plugin-${n}`,()=>[[`plugins.${n}`,...t.additionalOptionScopes||[]]])}_cachedScopes(t,n){const i=this._scopeCache;let a=i.get(t);return(!a||n)&&(a=new Map,i.set(t,a)),a}getOptionScopes(t,n,i){const{options:a,type:s}=this,o=this._cachedScopes(t,i),l=o.get(n);if(l)return l;const r=new Set;n.forEach(u=>{t&&(r.add(t),u.forEach(d=>Zo(r,t,d))),u.forEach(d=>Zo(r,a,d)),u.forEach(d=>Zo(r,xs[s]||{},d)),u.forEach(d=>Zo(r,Ut,d)),u.forEach(d=>Zo(r,Zd,d))});const c=Array.from(r);return c.length===0&&c.push(Object.create(null)),x_.has(n)&&o.set(n,c),c}chartOptionScopes(){const{options:t,type:n}=this;return[t,xs[n]||{},Ut.datasets[n]||{},{type:n},Ut,Zd]}resolveNamedOptions(t,n,i,a=[""]){const s={$shared:!0},{resolver:o,subPrefixes:l}=Ag(this._resolverCache,t,a);let r=o;if(YT(o,n)){s.$shared=!1,i=Da(i)?i():i;const c=this.createResolver(t,i,l);r=bo(o,i,c)}for(const c of n)s[c]=r[c];return s}createResolver(t,n,i=[""],a){const{resolver:s}=Ag(this._resolverCache,t,i);return st(n)?bo(s,n,void 0,a):s}}function Ag(e,t,n){let i=e.get(t);i||(i=new Map,e.set(t,i));const a=n.join();let s=i.get(a);return s||(s={resolver:Ih(t,n),subPrefixes:n.filter(l=>!l.toLowerCase().includes("hover"))},i.set(a,s)),s}const UT=e=>st(e)&&Object.getOwnPropertyNames(e).some(t=>Da(e[t]));function YT(e,t){const{isScriptable:n,isIndexable:i}=r_(e);for(const a of t){const s=n(a),o=i(a),l=(o||s)&&e[a];if(s&&(Da(l)||UT(l))||o&&Ot(l))return!0}return!1}var KT="4.4.1";const GT=["top","bottom","left","right","chartArea"];function Tg(e,t){return e==="top"||e==="bottom"||GT.indexOf(e)===-1&&t==="x"}function Mg(e,t){return function(n,i){return n[e]===i[e]?n[t]-i[t]:n[e]-i[e]}}function Eg(e){const t=e.chart,n=t.options.animation;t.notifyPlugins("afterRender"),Nt(n&&n.onComplete,[e],t)}function XT(e){const t=e.chart,n=t.options.animation;Nt(n&&n.onProgress,[e],t)}function S_(e){return Th()&&typeof e=="string"?e=document.getElementById(e):e&&e.length&&(e=e[0]),e&&e.canvas&&(e=e.canvas),e}const ic={},Dg=e=>{const t=S_(e);return Object.values(ic).filter(n=>n.canvas===t).pop()};function qT(e,t,n){const i=Object.keys(e);for(const a of i){const s=+a;if(s>=t){const o=e[a];delete e[a],(n>0||s>t)&&(e[s+n]=o)}}}function ZT(e,t,n,i){return!n||e.type==="mouseout"?null:i?t:e}function Hr(e,t,n){return e.options.clip?e[n]:t[n]}function JT(e,t){const{xScale:n,yScale:i}=e;return n&&i?{left:Hr(n,t,"left"),right:Hr(n,t,"right"),top:Hr(i,t,"top"),bottom:Hr(i,t,"bottom")}:t}var ma;let uu=(ma=class{static register(...t){Ci.add(...t),Og()}static unregister(...t){Ci.remove(...t),Og()}constructor(t,n){const i=this.config=new WT(n),a=S_(t),s=Dg(a);if(s)throw new Error("Canvas is already in use. Chart with ID '"+s.id+"' must be destroyed before the canvas with ID '"+s.canvas.id+"' can be reused.");const o=i.createResolver(i.chartOptionScopes(),this.getContext());this.platform=new(i.platform||mT(a)),this.platform.updateConfig(i);const l=this.platform.acquireContext(a,o.aspectRatio),r=l&&l.canvas,c=r&&r.height,u=r&&r.width;if(this.id=kV(),this.ctx=l,this.canvas=r,this.width=u,this.height=c,this._options=o,this._aspectRatio=this.aspectRatio,this._layers=[],this._metasets=[],this._stacks=void 0,this.boxes=[],this.currentDevicePixelRatio=void 0,this.chartArea=void 0,this._active=[],this._lastEvent=void 0,this._listeners={},this._responsiveListeners=void 0,this._sortedMetasets=[],this.scales={},this._plugins=new DT,this.$proxies={},this._hiddenIndices={},this.attached=!1,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=zV(d=>this.update(d),o.resizeDelay||0),this._dataChanges=[],ic[this.id]=this,!l||!r){console.error("Failed to create chart: can't acquire context from the given item");return}Hi.listen(this,"complete",Eg),Hi.listen(this,"progress",XT),this._initialize(),this.attached&&this.update()}get aspectRatio(){const{options:{aspectRatio:t,maintainAspectRatio:n},width:i,height:a,_aspectRatio:s}=this;return Dt(t)?n&&s?s:a?i/a:null:t}get data(){return this.config.data}set data(t){this.config.data=t}get options(){return this._options}set options(t){this.config.options=t}get registry(){return Ci}_initialize(){return this.notifyPlugins("beforeInit"),this.options.responsive?this.resize():lg(this,this.options.devicePixelRatio),this.bindEvents(),this.notifyPlugins("afterInit"),this}clear(){return ig(this.canvas,this.ctx),this}stop(){return Hi.stop(this),this}resize(t,n){Hi.running(this)?this._resizeBeforeDraw={width:t,height:n}:this._resize(t,n)}_resize(t,n){const i=this.options,a=this.canvas,s=i.maintainAspectRatio&&this.aspectRatio,o=this.platform.getMaximumSize(a,t,n,s),l=i.devicePixelRatio||this.platform.getDevicePixelRatio(),r=this.width?"resize":"attach";this.width=o.width,this.height=o.height,this._aspectRatio=this.aspectRatio,lg(this,l,!0)&&(this.notifyPlugins("resize",{size:o}),Nt(i.onResize,[this,o],this),this.attached&&this._doResize(r)&&this.render())}ensureScalesHaveIDs(){const n=this.options.scales||{};vt(n,(i,a)=>{i.id=a})}buildOrUpdateScales(){const t=this.options,n=t.scales,i=this.scales,a=Object.keys(i).reduce((o,l)=>(o[l]=!1,o),{});let s=[];n&&(s=s.concat(Object.keys(n).map(o=>{const l=n[o],r=tf(o,l),c=r==="r",u=r==="x";return{options:l,dposition:c?"chartArea":u?"bottom":"left",dtype:c?"radialLinear":u?"category":"linear"}}))),vt(s,o=>{const l=o.options,r=l.id,c=tf(r,l),u=Rt(l.type,o.dtype);(l.position===void 0||Tg(l.position,c)!==Tg(o.dposition))&&(l.position=o.dposition),a[r]=!0;let d=null;if(r in i&&i[r].type===u)d=i[r];else{const f=Ci.getScale(u);d=new f({id:r,type:u,ctx:this.ctx,chart:this}),i[d.id]=d}d.init(l,t)}),vt(a,(o,l)=>{o||delete i[l]}),vt(i,o=>{Sa.configure(this,o,o.options),Sa.addBox(this,o)})}_updateMetasets(){const t=this._metasets,n=this.data.datasets.length,i=t.length;if(t.sort((a,s)=>a.index-s.index),i>n){for(let a=n;an.length&&delete this._stacks,t.forEach((i,a)=>{n.filter(s=>s===i._dataset).length===0&&this._destroyDatasetMeta(a)})}buildOrUpdateControllers(){const t=[],n=this.data.datasets;let i,a;for(this._removeUnreferencedMetasets(),i=0,a=n.length;i{this.getDatasetMeta(n).controller.reset()},this)}reset(){this._resetElements(),this.notifyPlugins("reset")}update(t){const n=this.config;n.update();const i=this._options=n.createResolver(n.chartOptionScopes(),this.getContext()),a=this._animationsDisabled=!i.animation;if(this._updateScales(),this._checkEventBindings(),this._updateHiddenIndices(),this._plugins.invalidate(),this.notifyPlugins("beforeUpdate",{mode:t,cancelable:!0})===!1)return;const s=this.buildOrUpdateControllers();this.notifyPlugins("beforeElementsUpdate");let o=0;for(let c=0,u=this.data.datasets.length;c{c.reset()}),this._updateDatasets(t),this.notifyPlugins("afterUpdate",{mode:t}),this._layers.sort(Mg("z","_idx"));const{_active:l,_lastEvent:r}=this;r?this._eventHandler(r,!0):l.length&&this._updateHoverStyles(l,l,!0),this.render()}_updateScales(){vt(this.scales,t=>{Sa.removeBox(this,t)}),this.ensureScalesHaveIDs(),this.buildOrUpdateScales()}_checkEventBindings(){const t=this.options,n=new Set(Object.keys(this._listeners)),i=new Set(t.events);(!Gm(n,i)||!!this._responsiveListeners!==t.responsive)&&(this.unbindEvents(),this.bindEvents())}_updateHiddenIndices(){const{_hiddenIndices:t}=this,n=this._getUniformDataChanges()||[];for(const{method:i,start:a,count:s}of n){const o=i==="_removeElements"?-s:s;qT(t,a,o)}}_getUniformDataChanges(){const t=this._dataChanges;if(!t||!t.length)return;this._dataChanges=[];const n=this.data.datasets.length,i=s=>new Set(t.filter(o=>o[0]===s).map((o,l)=>l+","+o.splice(1).join(","))),a=i(0);for(let s=1;ss.split(",")).map(s=>({method:s[1],start:+s[2],count:+s[3]}))}_updateLayout(t){if(this.notifyPlugins("beforeLayout",{cancelable:!0})===!1)return;Sa.update(this,this.width,this.height,t);const n=this.chartArea,i=n.width<=0||n.height<=0;this._layers=[],vt(this.boxes,a=>{i&&a.position==="chartArea"||(a.configure&&a.configure(),this._layers.push(...a._layers()))},this),this._layers.forEach((a,s)=>{a._idx=s}),this.notifyPlugins("afterLayout")}_updateDatasets(t){if(this.notifyPlugins("beforeDatasetsUpdate",{mode:t,cancelable:!0})!==!1){for(let n=0,i=this.data.datasets.length;n=0;--n)this._drawDataset(t[n]);this.notifyPlugins("afterDatasetsDraw")}_drawDataset(t){const n=this.ctx,i=t._clip,a=!i.disabled,s=JT(t,this.chartArea),o={meta:t,index:t.index,cancelable:!0};this.notifyPlugins("beforeDatasetDraw",o)!==!1&&(a&&o_(n,{left:i.left===!1?0:s.left-i.left,right:i.right===!1?this.width:s.right+i.right,top:i.top===!1?0:s.top-i.top,bottom:i.bottom===!1?this.height:s.bottom+i.bottom}),t.controller.draw(),a&&l_(n),o.cancelable=!1,this.notifyPlugins("afterDatasetDraw",o))}isPointInArea(t){return io(t,this.chartArea,this._minPadding)}getElementsAtEventForMode(t,n,i,a){const s=GA.modes[n];return typeof s=="function"?s(this,t,i,a):[]}getDatasetMeta(t){const n=this.data.datasets[t],i=this._metasets;let a=i.filter(s=>s&&s._dataset===n).pop();return a||(a={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:n&&n.order||0,index:t,_dataset:n,_parsed:[],_sorted:!1},i.push(a)),a}getContext(){return this.$context||(this.$context=Es(null,{chart:this,type:"chart"}))}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(t){const n=this.data.datasets[t];if(!n)return!1;const i=this.getDatasetMeta(t);return typeof i.hidden=="boolean"?!i.hidden:!n.hidden}setDatasetVisibility(t,n){const i=this.getDatasetMeta(t);i.hidden=!n}toggleDataVisibility(t){this._hiddenIndices[t]=!this._hiddenIndices[t]}getDataVisibility(t){return!this._hiddenIndices[t]}_updateVisibility(t,n,i){const a=i?"show":"hide",s=this.getDatasetMeta(t),o=s.controller._resolveAnimations(void 0,a);_c(n)?(s.data[n].hidden=!i,this.update()):(this.setDatasetVisibility(t,i),o.update(s,{visible:i}),this.update(l=>l.datasetIndex===t?a:void 0))}hide(t,n){this._updateVisibility(t,n,!1)}show(t,n){this._updateVisibility(t,n,!0)}_destroyDatasetMeta(t){const n=this._metasets[t];n&&n.controller&&n.controller._destroy(),delete this._metasets[t]}_stop(){let t,n;for(this.stop(),Hi.remove(this),t=0,n=this.data.datasets.length;t{n.addEventListener(this,s,o),t[s]=o},a=(s,o,l)=>{s.offsetX=o,s.offsetY=l,this._eventHandler(s)};vt(this.options.events,s=>i(s,a))}bindResponsiveEvents(){this._responsiveListeners||(this._responsiveListeners={});const t=this._responsiveListeners,n=this.platform,i=(r,c)=>{n.addEventListener(this,r,c),t[r]=c},a=(r,c)=>{t[r]&&(n.removeEventListener(this,r,c),delete t[r])},s=(r,c)=>{this.canvas&&this.resize(r,c)};let o;const l=()=>{a("attach",l),this.attached=!0,this.resize(),i("resize",s),i("detach",o)};o=()=>{this.attached=!1,a("resize",s),this._stop(),this._resize(0,0),i("attach",l)},n.isAttached(this.canvas)?l():o()}unbindEvents(){vt(this._listeners,(t,n)=>{this.platform.removeEventListener(this,n,t)}),this._listeners={},vt(this._responsiveListeners,(t,n)=>{this.platform.removeEventListener(this,n,t)}),this._responsiveListeners=void 0}updateHoverStyle(t,n,i){const a=i?"set":"remove";let s,o,l,r;for(n==="dataset"&&(s=this.getDatasetMeta(t[0].datasetIndex),s.controller["_"+a+"DatasetHoverStyle"]()),l=0,r=t.length;l{const l=this.getDatasetMeta(s);if(!l)throw new Error("No dataset found at index "+s);return{datasetIndex:s,element:l.data[o],index:o}});!yc(i,n)&&(this._active=i,this._lastEvent=null,this._updateHoverStyles(i,n))}notifyPlugins(t,n,i){return this._plugins.notify(this,t,n,i)}isPluginEnabled(t){return this._plugins._cache.filter(n=>n.plugin.id===t).length===1}_updateHoverStyles(t,n,i){const a=this.options.hover,s=(r,c)=>r.filter(u=>!c.some(d=>u.datasetIndex===d.datasetIndex&&u.index===d.index)),o=s(n,t),l=i?t:s(t,n);o.length&&this.updateHoverStyle(o,a.mode,!1),l.length&&a.mode&&this.updateHoverStyle(l,a.mode,!0)}_eventHandler(t,n){const i={event:t,replay:n,cancelable:!0,inChartArea:this.isPointInArea(t)},a=o=>(o.options.events||this.options.events).includes(t.native.type);if(this.notifyPlugins("beforeEvent",i,a)===!1)return;const s=this._handleEvent(t,n,i.inChartArea);return i.cancelable=!1,this.notifyPlugins("afterEvent",i,a),(s||i.changed)&&this.render(),this}_handleEvent(t,n,i){const{_active:a=[],options:s}=this,o=n,l=this._getActiveElements(t,a,i,o),r=TV(t),c=ZT(t,this._lastEvent,i,r);i&&(this._lastEvent=null,Nt(s.onHover,[t,l,this],this),r&&Nt(s.onClick,[t,l,this],this));const u=!yc(l,a);return(u||n)&&(this._active=l,this._updateHoverStyles(l,a,n)),this._lastEvent=c,u}_getActiveElements(t,n,i,a){if(t.type==="mouseout")return[];if(!i)return n;const s=this.options.hover;return this.getElementsAtEventForMode(t,s.mode,s,a)}},He(ma,"defaults",Ut),He(ma,"instances",ic),He(ma,"overrides",xs),He(ma,"registry",Ci),He(ma,"version",KT),He(ma,"getChart",Dg),ma);function Og(){return vt(uu.instances,e=>e._plugins.invalidate())}function QT(e,t,n){const{startAngle:i,pixelMargin:a,x:s,y:o,outerRadius:l,innerRadius:r}=t;let c=a/l;e.beginPath(),e.arc(s,o,l,i-c,n+c),r>a?(c=a/r,e.arc(s,o,r,n+c,i-c,!0)):e.arc(s,o,a,n+Wt,i-Wt),e.closePath(),e.clip()}function eM(e){return Ph(e,["outerStart","outerEnd","innerStart","innerEnd"])}function tM(e,t,n,i){const a=eM(e.options.borderRadius),s=(n-t)/2,o=Math.min(s,i*t/2),l=r=>{const c=(n-Math.min(s,r))*i/2;return ai(r,0,Math.min(s,c))};return{outerStart:l(a.outerStart),outerEnd:l(a.outerEnd),innerStart:ai(a.innerStart,0,o),innerEnd:ai(a.innerEnd,0,o)}}function Gs(e,t,n,i){return{x:n+e*Math.cos(t),y:i+e*Math.sin(t)}}function Vc(e,t,n,i,a,s){const{x:o,y:l,startAngle:r,pixelMargin:c,innerRadius:u}=t,d=Math.max(t.outerRadius+i+n-c,0),f=u>0?u+i+n+c:0;let v=0;const m=a-r;if(i){const Y=u>0?u-i:0,K=d>0?d-i:0,J=(Y+K)/2,B=J!==0?m*J/(J+i):m;v=(m-B)/2}const g=Math.max(.001,m*d-n/zt)/d,p=(m-g)/2,y=r+p+v,b=a-p-v,{outerStart:S,outerEnd:_,innerStart:x,innerEnd:P}=tM(t,f,d,b-y),C=d-S,V=d-_,I=y+S/C,M=b-_/V,O=f+x,D=f+P,N=y+x/O,j=b-P/D;if(e.beginPath(),s){const Y=(I+M)/2;if(e.arc(o,l,d,I,Y),e.arc(o,l,d,Y,M),_>0){const G=Gs(V,M,o,l);e.arc(G.x,G.y,_,M,b+Wt)}const K=Gs(D,b,o,l);if(e.lineTo(K.x,K.y),P>0){const G=Gs(D,j,o,l);e.arc(G.x,G.y,P,b+Wt,j+Math.PI)}const J=(b-P/f+(y+x/f))/2;if(e.arc(o,l,f,b-P/f,J,!0),e.arc(o,l,f,J,y+x/f,!0),x>0){const G=Gs(O,N,o,l);e.arc(G.x,G.y,x,N+Math.PI,y-Wt)}const B=Gs(C,y,o,l);if(e.lineTo(B.x,B.y),S>0){const G=Gs(C,I,o,l);e.arc(G.x,G.y,S,y-Wt,I)}}else{e.moveTo(o,l);const Y=Math.cos(I)*d+o,K=Math.sin(I)*d+l;e.lineTo(Y,K);const J=Math.cos(M)*d+o,B=Math.sin(M)*d+l;e.lineTo(J,B)}e.closePath()}function nM(e,t,n,i,a){const{fullCircles:s,startAngle:o,circumference:l}=t;let r=t.endAngle;if(s){Vc(e,t,n,i,r,a);for(let c=0;c=$t||kc(o,r,c),p=LV(l,u+v,d+v);return g&&p}getCenterPoint(n){const{x:i,y:a,startAngle:s,endAngle:o,innerRadius:l,outerRadius:r}=this.getProps(["x","y","startAngle","endAngle","innerRadius","outerRadius"],n),{offset:c,spacing:u}=this.options,d=(s+o)/2,f=(l+r+u+c)/2;return{x:i+Math.cos(d)*f,y:a+Math.sin(d)*f}}tooltipPosition(n){return this.getCenterPoint(n)}draw(n){const{options:i,circumference:a}=this,s=(i.offset||0)/4,o=(i.spacing||0)/2,l=i.circular;if(this.pixelMargin=i.borderAlign==="inner"?.33:0,this.fullCircles=a>$t?Math.floor(a/$t):0,a===0||this.innerRadius<0||this.outerRadius<0)return;n.save();const r=(this.startAngle+this.endAngle)/2;n.translate(Math.cos(r)*s,Math.sin(r)*s);const c=1-Math.sin(Math.min(zt,a||0)),u=s*c;n.fillStyle=i.backgroundColor,n.strokeStyle=i.borderColor,nM(n,this,u,o,l),iM(n,this,u,o,l),n.restore()}}He(sl,"id","arc"),He(sl,"defaults",{borderAlign:"center",borderColor:"#fff",borderDash:[],borderDashOffset:0,borderJoinStyle:void 0,borderRadius:0,borderWidth:2,offset:0,spacing:0,angle:void 0,circular:!0}),He(sl,"defaultRoutes",{backgroundColor:"backgroundColor"}),He(sl,"descriptors",{_scriptable:!0,_indexable:n=>n!=="borderDash"});class w_ extends or{constructor(t){super(),this.chart=t.chart,this.options=t.options,this.ctx=t.ctx,this._padding=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(t,n){const i=this.options;if(this.left=0,this.top=0,!i.display){this.width=this.height=this.right=this.bottom=0;return}this.width=this.right=t,this.height=this.bottom=n;const a=Ot(i.text)?i.text.length:1;this._padding=Kn(i.padding);const s=a*Cn(i.font).lineHeight+this._padding.height;this.isHorizontal()?this.height=s:this.width=s}isHorizontal(){const t=this.options.position;return t==="top"||t==="bottom"}_drawArgs(t){const{top:n,left:i,bottom:a,right:s,options:o}=this,l=o.align;let r=0,c,u,d;return this.isHorizontal()?(u=pl(l,i,s),d=n+t,c=s-i):(o.position==="left"?(u=i+t,d=pl(l,a,n),r=zt*-.5):(u=s-t,d=pl(l,n,a),r=zt*.5),c=a-n),{titleX:u,titleY:d,maxWidth:c,rotation:r}}draw(){const t=this.ctx,n=this.options;if(!n.display)return;const i=Cn(n.font),s=i.lineHeight/2+this._padding.top,{titleX:o,titleY:l,maxWidth:r,rotation:c}=this._drawArgs(s);Bl(t,n.text,0,0,i,{color:n.color,maxWidth:r,rotation:c,textAlign:i_(n.align),textBaseline:"middle",translation:[o,l]})}}function aM(e,t){const n=new w_({ctx:e.ctx,options:t,chart:e});Sa.configure(e,n,t),Sa.addBox(e,n),e.titleBlock=n}var sM={id:"title",_element:w_,start(e,t,n){aM(e,n)},stop(e){const t=e.titleBlock;Sa.removeBox(e,t),delete e.titleBlock},beforeUpdate(e,t,n){const i=e.titleBlock;Sa.configure(e,i,n),i.options=n},defaults:{align:"center",display:!1,font:{weight:"bold"},fullSize:!0,padding:10,position:"top",text:"",weight:2e3},defaultRoutes:{color:"color"},descriptors:{_scriptable:!0,_indexable:!1}};const ol={average(e){if(!e.length)return!1;let t,n,i=0,a=0,s=0;for(t=0,n=e.length;t-1?e.split(` -`):e}function oM(e,t){const{element:n,datasetIndex:i,index:a}=t,s=e.getDatasetMeta(i).controller,{label:o,value:l}=s.getLabelAndValue(a);return{chart:e,label:o,parsed:s.getParsed(a),raw:e.data.datasets[i].data[a],formattedValue:l,dataset:s.getDataset(),dataIndex:a,datasetIndex:i,element:n}}function Rg(e,t){const n=e.chart.ctx,{body:i,footer:a,title:s}=e,{boxWidth:o,boxHeight:l}=t,r=Cn(t.bodyFont),c=Cn(t.titleFont),u=Cn(t.footerFont),d=s.length,f=a.length,v=i.length,m=Kn(t.padding);let g=m.height,p=0,y=i.reduce((_,x)=>_+x.before.length+x.lines.length+x.after.length,0);if(y+=e.beforeBody.length+e.afterBody.length,d&&(g+=d*c.lineHeight+(d-1)*t.titleSpacing+t.titleMarginBottom),y){const _=t.displayColors?Math.max(l,r.lineHeight):r.lineHeight;g+=v*_+(y-v)*r.lineHeight+(y-1)*t.bodySpacing}f&&(g+=t.footerMarginTop+f*u.lineHeight+(f-1)*t.footerSpacing);let b=0;const S=function(_){p=Math.max(p,n.measureText(_).width+b)};return n.save(),n.font=c.string,vt(e.title,S),n.font=r.string,vt(e.beforeBody.concat(e.afterBody),S),b=t.displayColors?o+2+t.boxPadding:0,vt(i,_=>{vt(_.before,S),vt(_.lines,S),vt(_.after,S)}),b=0,n.font=u.string,vt(e.footer,S),n.restore(),p+=m.width,{width:p,height:g}}function lM(e,t){const{y:n,height:i}=t;return ne.height-i/2?"bottom":"center"}function rM(e,t,n,i){const{x:a,width:s}=i,o=n.caretSize+n.caretPadding;if(e==="left"&&a+s+o>t.width||e==="right"&&a-s-o<0)return!0}function cM(e,t,n,i){const{x:a,width:s}=n,{width:o,chartArea:{left:l,right:r}}=e;let c="center";return i==="center"?c=a<=(l+r)/2?"left":"right":a<=s/2?c="left":a>=o-s/2&&(c="right"),rM(c,e,t,n)&&(c="center"),c}function Lg(e,t,n){const i=n.yAlign||t.yAlign||lM(e,n);return{xAlign:n.xAlign||t.xAlign||cM(e,t,n,i),yAlign:i}}function uM(e,t){let{x:n,width:i}=e;return t==="right"?n-=i:t==="center"&&(n-=i/2),n}function dM(e,t,n){let{y:i,height:a}=e;return t==="top"?i+=n:t==="bottom"?i-=a+n:i-=a/2,i}function Bg(e,t,n,i){const{caretSize:a,caretPadding:s,cornerRadius:o}=e,{xAlign:l,yAlign:r}=n,c=a+s,{topLeft:u,topRight:d,bottomLeft:f,bottomRight:v}=_l(o);let m=uM(t,l);const g=dM(t,r,c);return r==="center"?l==="left"?m+=c:l==="right"&&(m-=c):l==="left"?m-=Math.max(u,f)+a:l==="right"&&(m+=Math.max(d,v)+a),{x:ai(m,0,i.width-t.width),y:ai(g,0,i.height-t.height)}}function jr(e,t,n){const i=Kn(n.padding);return t==="center"?e.x+e.width/2:t==="right"?e.x+e.width-i.right:e.x+i.left}function Ng(e){return ki([],ji(e))}function fM(e,t,n){return Es(e,{tooltip:t,tooltipItems:n,type:"tooltip"})}function Fg(e,t){const n=t&&t.dataset&&t.dataset.tooltip&&t.dataset.tooltip.callbacks;return n?e.override(n):e}const k_={beforeTitle:$i,title(e){if(e.length>0){const t=e[0],n=t.chart.data.labels,i=n?n.length:0;if(this&&this.options&&this.options.mode==="dataset")return t.dataset.label||"";if(t.label)return t.label;if(i>0&&t.dataIndex"u"?k_[t].call(n,i):a}class nf extends or{constructor(t){super(),this.opacity=0,this._active=[],this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.chart=t.chart,this.options=t.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0}initialize(t){this.options=t,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){const t=this._cachedAnimations;if(t)return t;const n=this.chart,i=this.options.setContext(this.getContext()),a=i.enabled&&n.options.animation&&i.animations,s=new f_(this.chart,a);return a._cacheable&&(this._cachedAnimations=Object.freeze(s)),s}getContext(){return this.$context||(this.$context=fM(this.chart.getContext(),this,this._tooltipItems))}getTitle(t,n){const{callbacks:i}=n,a=Dn(i,"beforeTitle",this,t),s=Dn(i,"title",this,t),o=Dn(i,"afterTitle",this,t);let l=[];return l=ki(l,ji(a)),l=ki(l,ji(s)),l=ki(l,ji(o)),l}getBeforeBody(t,n){return Ng(Dn(n.callbacks,"beforeBody",this,t))}getBody(t,n){const{callbacks:i}=n,a=[];return vt(t,s=>{const o={before:[],lines:[],after:[]},l=Fg(i,s);ki(o.before,ji(Dn(l,"beforeLabel",this,s))),ki(o.lines,Dn(l,"label",this,s)),ki(o.after,ji(Dn(l,"afterLabel",this,s))),a.push(o)}),a}getAfterBody(t,n){return Ng(Dn(n.callbacks,"afterBody",this,t))}getFooter(t,n){const{callbacks:i}=n,a=Dn(i,"beforeFooter",this,t),s=Dn(i,"footer",this,t),o=Dn(i,"afterFooter",this,t);let l=[];return l=ki(l,ji(a)),l=ki(l,ji(s)),l=ki(l,ji(o)),l}_createItems(t){const n=this._active,i=this.chart.data,a=[],s=[],o=[];let l=[],r,c;for(r=0,c=n.length;rt.filter(u,d,f,i))),t.itemSort&&(l=l.sort((u,d)=>t.itemSort(u,d,i))),vt(l,u=>{const d=Fg(t.callbacks,u);a.push(Dn(d,"labelColor",this,u)),s.push(Dn(d,"labelPointStyle",this,u)),o.push(Dn(d,"labelTextColor",this,u))}),this.labelColors=a,this.labelPointStyles=s,this.labelTextColors=o,this.dataPoints=l,l}update(t,n){const i=this.options.setContext(this.getContext()),a=this._active;let s,o=[];if(!a.length)this.opacity!==0&&(s={opacity:0});else{const l=ol[i.position].call(this,a,this._eventPosition);o=this._createItems(i),this.title=this.getTitle(o,i),this.beforeBody=this.getBeforeBody(o,i),this.body=this.getBody(o,i),this.afterBody=this.getAfterBody(o,i),this.footer=this.getFooter(o,i);const r=this._size=Rg(this,i),c=Object.assign({},l,r),u=Lg(this.chart,i,c),d=Bg(i,c,u,this.chart);this.xAlign=u.xAlign,this.yAlign=u.yAlign,s={opacity:1,x:d.x,y:d.y,width:r.width,height:r.height,caretX:l.x,caretY:l.y}}this._tooltipItems=o,this.$context=void 0,s&&this._resolveAnimations().update(this,s),t&&i.external&&i.external.call(this,{chart:this.chart,tooltip:this,replay:n})}drawCaret(t,n,i,a){const s=this.getCaretPosition(t,i,a);n.lineTo(s.x1,s.y1),n.lineTo(s.x2,s.y2),n.lineTo(s.x3,s.y3)}getCaretPosition(t,n,i){const{xAlign:a,yAlign:s}=this,{caretSize:o,cornerRadius:l}=i,{topLeft:r,topRight:c,bottomLeft:u,bottomRight:d}=_l(l),{x:f,y:v}=t,{width:m,height:g}=n;let p,y,b,S,_,x;return s==="center"?(_=v+g/2,a==="left"?(p=f,y=p-o,S=_+o,x=_-o):(p=f+m,y=p+o,S=_-o,x=_+o),b=p):(a==="left"?y=f+Math.max(r,u)+o:a==="right"?y=f+m-Math.max(c,d)-o:y=this.caretX,s==="top"?(S=v,_=S-o,p=y-o,b=y+o):(S=v+g,_=S+o,p=y+o,b=y-o),x=S),{x1:p,x2:y,x3:b,y1:S,y2:_,y3:x}}drawTitle(t,n,i){const a=this.title,s=a.length;let o,l,r;if(s){const c=fd(i.rtl,this.x,this.width);for(t.x=jr(this,i.titleAlign,i),n.textAlign=c.textAlign(i.titleAlign),n.textBaseline="middle",o=Cn(i.titleFont),l=i.titleSpacing,n.fillStyle=i.titleColor,n.font=o.string,r=0;rb!==0)?(t.beginPath(),t.fillStyle=s.multiKeyBackground,Jd(t,{x:g,y:m,w:c,h:r,radius:y}),t.fill(),t.stroke(),t.fillStyle=o.backgroundColor,t.beginPath(),Jd(t,{x:p,y:m+1,w:c-2,h:r-2,radius:y}),t.fill()):(t.fillStyle=s.multiKeyBackground,t.fillRect(g,m,c,r),t.strokeRect(g,m,c,r),t.fillStyle=o.backgroundColor,t.fillRect(p,m+1,c-2,r-2))}t.fillStyle=this.labelTextColors[i]}drawBody(t,n,i){const{body:a}=this,{bodySpacing:s,bodyAlign:o,displayColors:l,boxHeight:r,boxWidth:c,boxPadding:u}=i,d=Cn(i.bodyFont);let f=d.lineHeight,v=0;const m=fd(i.rtl,this.x,this.width),g=function(V){n.fillText(V,m.x(t.x+v),t.y+f/2),t.y+=f+s},p=m.textAlign(o);let y,b,S,_,x,P,C;for(n.textAlign=o,n.textBaseline="middle",n.font=d.string,t.x=jr(this,p,i),n.fillStyle=i.bodyColor,vt(this.beforeBody,g),v=l&&p!=="right"?o==="center"?c/2+u:c+2+u:0,_=0,P=a.length;_0&&n.stroke()}_updateAnimationTarget(t){const n=this.chart,i=this.$animations,a=i&&i.x,s=i&&i.y;if(a||s){const o=ol[t.position].call(this,this._active,this._eventPosition);if(!o)return;const l=this._size=Rg(this,t),r=Object.assign({},o,this._size),c=Lg(n,t,r),u=Bg(t,r,c,n);(a._to!==u.x||s._to!==u.y)&&(this.xAlign=c.xAlign,this.yAlign=c.yAlign,this.width=l.width,this.height=l.height,this.caretX=o.x,this.caretY=o.y,this._resolveAnimations().update(this,u))}}_willRender(){return!!this.opacity}draw(t){const n=this.options.setContext(this.getContext());let i=this.opacity;if(!i)return;this._updateAnimationTarget(n);const a={width:this.width,height:this.height},s={x:this.x,y:this.y};i=Math.abs(i)<.001?0:i;const o=Kn(n.padding),l=this.title.length||this.beforeBody.length||this.body.length||this.afterBody.length||this.footer.length;n.enabled&&l&&(t.save(),t.globalAlpha=i,this.drawBackground(s,t,a,n),PA(t,n.textDirection),s.y+=o.top,this.drawTitle(s,t,n),this.drawBody(s,t,n),this.drawFooter(s,t,n),IA(t,n.textDirection),t.restore())}getActiveElements(){return this._active||[]}setActiveElements(t,n){const i=this._active,a=t.map(({datasetIndex:l,index:r})=>{const c=this.chart.getDatasetMeta(l);if(!c)throw new Error("Cannot find a dataset at index "+l);return{datasetIndex:l,element:c.data[r],index:r}}),s=!yc(i,a),o=this._positionChanged(a,n);(s||o)&&(this._active=a,this._eventPosition=n,this._ignoreReplayEvents=!0,this.update(!0))}handleEvent(t,n,i=!0){if(n&&this._ignoreReplayEvents)return!1;this._ignoreReplayEvents=!1;const a=this.options,s=this._active||[],o=this._getActiveElements(t,s,n,i),l=this._positionChanged(o,t),r=n||!yc(o,s)||l;return r&&(this._active=o,(a.enabled||a.external)&&(this._eventPosition={x:t.x,y:t.y},this.update(!0,n))),r}_getActiveElements(t,n,i,a){const s=this.options;if(t.type==="mouseout")return[];if(!a)return n.filter(l=>this.chart.data.datasets[l.datasetIndex]&&this.chart.getDatasetMeta(l.datasetIndex).controller.getParsed(l.index)!==void 0);const o=this.chart.getElementsAtEventForMode(t,s.mode,s,i);return s.reverse&&o.reverse(),o}_positionChanged(t,n){const{caretX:i,caretY:a,options:s}=this,o=ol[s.position].call(this,t,n);return o!==!1&&(i!==o.x||a!==o.y)}}He(nf,"positioners",ol);var hM={id:"tooltip",_element:nf,positioners:ol,afterInit(e,t,n){n&&(e.tooltip=new nf({chart:e,options:n}))},beforeUpdate(e,t,n){e.tooltip&&e.tooltip.initialize(n)},reset(e,t,n){e.tooltip&&e.tooltip.initialize(n)},afterDraw(e){const t=e.tooltip;if(t&&t._willRender()){const n={tooltip:t};if(e.notifyPlugins("beforeTooltipDraw",{...n,cancelable:!0})===!1)return;t.draw(e.ctx),e.notifyPlugins("afterTooltipDraw",n)}},afterEvent(e,t){if(e.tooltip){const n=t.replay;e.tooltip.handleEvent(t.event,n,t.inChartArea)&&(t.changed=!0)}},defaults:{enabled:!0,external:null,position:"average",backgroundColor:"rgba(0,0,0,0.8)",titleColor:"#fff",titleFont:{weight:"bold"},titleSpacing:2,titleMarginBottom:6,titleAlign:"left",bodyColor:"#fff",bodySpacing:2,bodyFont:{},bodyAlign:"left",footerColor:"#fff",footerSpacing:2,footerMarginTop:6,footerFont:{weight:"bold"},footerAlign:"left",padding:6,caretPadding:2,caretSize:5,cornerRadius:6,boxHeight:(e,t)=>t.bodyFont.size,boxWidth:(e,t)=>t.bodyFont.size,multiKeyBackground:"#fff",displayColors:!0,boxPadding:0,borderColor:"rgba(0,0,0,0)",borderWidth:0,animation:{duration:400,easing:"easeOutQuart"},animations:{numbers:{type:"number",properties:["x","y","width","height","caretX","caretY"]},opacity:{easing:"linear",duration:200}},callbacks:k_},defaultRoutes:{bodyFont:"font",footerFont:"font",titleFont:"font"},descriptors:{_scriptable:e=>e!=="filter"&&e!=="itemSort"&&e!=="external",_indexable:!1,callbacks:{_scriptable:!1,_indexable:!1},animation:{_fallback:!1},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]};function vM(e,t){const n=[],{bounds:a,step:s,min:o,max:l,precision:r,count:c,maxTicks:u,maxDigits:d,includeBounds:f}=e,v=s||1,m=u-1,{min:g,max:p}=t,y=!Dt(o),b=!Dt(l),S=!Dt(c),_=(p-g)/(d+1);let x=qm((p-g)/m/v)*v,P,C,V,I;if(x<1e-14&&!y&&!b)return[{value:g},{value:p}];I=Math.ceil(p/x)-Math.floor(g/x),I>m&&(x=qm(I*x/m/v)*v),Dt(r)||(P=Math.pow(10,r),x=Math.ceil(x*P)/P),a==="ticks"?(C=Math.floor(g/x)*x,V=Math.ceil(p/x)*x):(C=g,V=p),y&&b&&s&&DV((l-o)/s,x/1e3)?(I=Math.round(Math.min((l-o)/x,u)),x=(l-o)/I,C=o,V=l):S?(C=y?o:C,V=b?l:V,I=c-1,x=(V-C)/I):(I=(V-C)/x,tc(I,Math.round(I),x/1e3)?I=Math.round(I):I=Math.ceil(I));const M=Math.max(Zm(x),Zm(C));P=Math.pow(10,Dt(r)?M:r),C=Math.round(C*P)/P,V=Math.round(V*P)/P;let O=0;for(y&&(f&&C!==o?(n.push({value:o}),Cl)break;n.push({value:D})}return b&&f&&V!==l?n.length&&tc(n[n.length-1].value,l,$g(l,_,e))?n[n.length-1].value=l:n.push({value:l}):(!b||V===l)&&n.push({value:V}),n}function $g(e,t,{horizontal:n,minRotation:i}){const a=Ai(i),s=(n?Math.sin(a):Math.cos(a))||.001,o=.75*t*(""+e).length;return Math.min(t/s,o)}class Ac extends Mo{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(t,n){return Dt(t)||(typeof t=="number"||t instanceof Number)&&!isFinite(+t)?null:+t}handleTickRangeOptions(){const{beginAtZero:t}=this.options,{minDefined:n,maxDefined:i}=this.getUserBounds();let{min:a,max:s}=this;const o=r=>a=n?a:r,l=r=>s=i?s:r;if(t){const r=Sc(a),c=Sc(s);r<0&&c<0?l(0):r>0&&c>0&&o(0)}if(a===s){let r=s===0?1:Math.abs(s*.05);l(s+r),t||o(a-r)}this.min=a,this.max=s}getTickLimit(){const t=this.options.ticks;let{maxTicksLimit:n,stepSize:i}=t,a;return i?(a=Math.ceil(this.max/i)-Math.floor(this.min/i)+1,a>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${i} would result generating up to ${a} ticks. Limiting to 1000.`),a=1e3)):(a=this.computeTickLimit(),n=n||11),n&&(a=Math.min(n,a)),a}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){const t=this.options,n=t.ticks;let i=this.getTickLimit();i=Math.max(2,i);const a={maxTicks:i,bounds:t.bounds,min:t.min,max:t.max,precision:n.precision,step:n.stepSize,count:n.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:n.minRotation||0,includeBounds:n.includeBounds!==!1},s=this._range||this,o=vM(a,s);return t.bounds==="ticks"&&Jb(o,this,"value"),t.reverse?(o.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),o}configure(){const t=this.ticks;let n=this.min,i=this.max;if(super.configure(),this.options.offset&&t.length){const a=(i-n)/Math.max(t.length-1,1)/2;n-=a,i+=a}this._startValue=n,this._endValue=i,this._valueRange=i-n}getLabelForValue(t){return lu(t,this.chart.options.locale,this.options.ticks.format)}}class zg extends Ac{determineDataLimits(){const{min:t,max:n}=this.getMinMax(!0);this.min=un(t)?t:0,this.max=un(n)?n:1,this.handleTickRangeOptions()}computeTickLimit(){const t=this.isHorizontal(),n=t?this.width:this.height,i=Ai(this.options.ticks.minRotation),a=(t?Math.sin(i):Math.cos(i))||.001,s=this._resolveTickFontOptions(0);return Math.ceil(n/Math.min(40,s.lineHeight/a))}getPixelForValue(t){return t===null?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getValueForPixel(t){return this._startValue+this.getDecimalForPixel(t)*this._valueRange}}He(zg,"id","linear"),He(zg,"defaults",{ticks:{callback:ru.formatters.numeric}});const Fl=e=>Math.floor(xa(e)),es=(e,t)=>Math.pow(10,Fl(e)+t);function Hg(e){return e/Math.pow(10,Fl(e))===1}function jg(e,t,n){const i=Math.pow(10,n),a=Math.floor(e/i);return Math.ceil(t/i)-a}function mM(e,t){const n=t-e;let i=Fl(n);for(;jg(e,t,i)>10;)i++;for(;jg(e,t,i)<10;)i--;return Math.min(i,Fl(e))}function gM(e,{min:t,max:n}){t=Hn(e.min,t);const i=[],a=Fl(t);let s=mM(t,n),o=s<0?Math.pow(10,Math.abs(s)):1;const l=Math.pow(10,s),r=a>s?Math.pow(10,a):0,c=Math.round((t-r)*o)/o,u=Math.floor((t-r)/l/10)*l*10;let d=Math.floor((c-u)/Math.pow(10,s)),f=Hn(e.min,Math.round((r+u+d*Math.pow(10,s))*o)/o);for(;f=10?d=d<15?15:20:d++,d>=20&&(s++,d=2,o=s>=0?1:o),f=Math.round((r+u+d*Math.pow(10,s))*o)/o;const v=Hn(e.max,f);return i.push({value:v,major:Hg(v),significand:d}),i}class Wg extends Mo{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._valueRange=0}parse(t,n){const i=Ac.prototype.parse.apply(this,[t,n]);if(i===0){this._zero=!0;return}return un(i)&&i>0?i:null}determineDataLimits(){const{min:t,max:n}=this.getMinMax(!0);this.min=un(t)?Math.max(0,t):null,this.max=un(n)?Math.max(0,n):null,this.options.beginAtZero&&(this._zero=!0),this._zero&&this.min!==this._suggestedMin&&!un(this._userMin)&&(this.min=t===es(this.min,0)?es(this.min,-1):es(this.min,0)),this.handleTickRangeOptions()}handleTickRangeOptions(){const{minDefined:t,maxDefined:n}=this.getUserBounds();let i=this.min,a=this.max;const s=l=>i=t?i:l,o=l=>a=n?a:l;i===a&&(i<=0?(s(1),o(10)):(s(es(i,-1)),o(es(a,1)))),i<=0&&s(es(a,-1)),a<=0&&o(es(i,1)),this.min=i,this.max=a}buildTicks(){const t=this.options,n={min:this._userMin,max:this._userMax},i=gM(n,this);return t.bounds==="ticks"&&Jb(i,this,"value"),t.reverse?(i.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),i}getLabelForValue(t){return t===void 0?"0":lu(t,this.chart.options.locale,this.options.ticks.format)}configure(){const t=this.min;super.configure(),this._startValue=xa(t),this._valueRange=xa(this.max)-xa(t)}getPixelForValue(t){return(t===void 0||t===0)&&(t=this.min),t===null||isNaN(t)?NaN:this.getPixelForDecimal(t===this.min?0:(xa(t)-this._startValue)/this._valueRange)}getValueForPixel(t){const n=this.getDecimalForPixel(t);return Math.pow(10,this._startValue+n*this._valueRange)}}He(Wg,"id","logarithmic"),He(Wg,"defaults",{ticks:{callback:ru.formatters.logarithmic,major:{enabled:!0}}});function af(e){const t=e.ticks;if(t.display&&e.display){const n=Kn(t.backdropPadding);return Rt(t.font&&t.font.size,Ut.font.size)+n.height}return 0}function pM(e,t,n){return n=Ot(n)?n:[n],{w:ZV(e,t.string,n),h:n.length*t.lineHeight}}function Ug(e,t,n,i,a){return e===i||e===a?{start:t-n/2,end:t+n/2}:ea?{start:t-n,end:t}:{start:t,end:t+n}}function yM(e){const t={l:e.left+e._padding.left,r:e.right-e._padding.right,t:e.top+e._padding.top,b:e.bottom-e._padding.bottom},n=Object.assign({},t),i=[],a=[],s=e._pointLabels.length,o=e.options.pointLabels,l=o.centerPointLabels?zt/s:0;for(let r=0;rt.r&&(l=(i.end-t.r)/s,e.r=Math.max(e.r,t.r+l)),a.startt.b&&(r=(a.end-t.b)/o,e.b=Math.max(e.b,t.b+r))}function _M(e,t,n){const i=e.drawingArea,{extra:a,additionalAngle:s,padding:o,size:l}=n,r=e.getPointPosition(t,i+a+o,s),c=Math.round(kh(Ii(r.angle+Wt))),u=CM(r.y,l.h,c),d=wM(c),f=kM(r.x,l.w,d);return{visible:!0,x:r.x,y:u,textAlign:d,left:f,top:u,right:f+l.w,bottom:u+l.h}}function xM(e,t){if(!t)return!0;const{left:n,top:i,right:a,bottom:s}=e;return!(io({x:n,y:i},t)||io({x:n,y:s},t)||io({x:a,y:i},t)||io({x:a,y:s},t))}function SM(e,t,n){const i=[],a=e._pointLabels.length,s=e.options,{centerPointLabels:o,display:l}=s.pointLabels,r={extra:af(s)/2,additionalAngle:o?zt/a:0};let c;for(let u=0;u270||n<90)&&(e-=t),e}function PM(e,t,n){const{left:i,top:a,right:s,bottom:o}=n,{backdropColor:l}=t;if(!Dt(l)){const r=_l(t.borderRadius),c=Kn(t.backdropPadding);e.fillStyle=l;const u=i-c.left,d=a-c.top,f=s-i+c.width,v=o-a+c.height;Object.values(r).some(m=>m!==0)?(e.beginPath(),Jd(e,{x:u,y:d,w:f,h:v,radius:r}),e.fill()):e.fillRect(u,d,f,v)}}function IM(e,t){const{ctx:n,options:{pointLabels:i}}=e;for(let a=t-1;a>=0;a--){const s=e._pointLabelItems[a];if(!s.visible)continue;const o=i.setContext(e.getPointLabelContext(a));PM(n,o,s);const l=Cn(o.font),{x:r,y:c,textAlign:u}=s;Bl(n,e._pointLabels[a],r,c+l.lineHeight/2,l,{color:o.color,textAlign:u,textBaseline:"middle"})}}function C_(e,t,n,i){const{ctx:a}=e;if(n)a.arc(e.xCenter,e.yCenter,t,0,$t);else{let s=e.getPointPosition(0,t);a.moveTo(s.x,s.y);for(let o=1;o{const a=Nt(this.options.pointLabels.callback,[n,i],this);return a||a===0?a:""}).filter((n,i)=>this.chart.getDataVisibility(i))}fit(){const t=this.options;t.display&&t.pointLabels.display?yM(this):this.setCenterPoint(0,0,0,0)}setCenterPoint(t,n,i,a){this.xCenter+=Math.floor((t-n)/2),this.yCenter+=Math.floor((i-a)/2),this.drawingArea-=Math.min(this.drawingArea/2,Math.max(t,n,i,a))}getIndexAngle(t){const n=$t/(this._pointLabels.length||1),i=this.options.startAngle||0;return Ii(t*n+Ai(i))}getDistanceFromCenterForValue(t){if(Dt(t))return NaN;const n=this.drawingArea/(this.max-this.min);return this.options.reverse?(this.max-t)*n:(t-this.min)*n}getValueForDistanceFromCenter(t){if(Dt(t))return NaN;const n=t/(this.drawingArea/(this.max-this.min));return this.options.reverse?this.max-n:this.min+n}getPointLabelContext(t){const n=this._pointLabels||[];if(t>=0&&t{if(d!==0){r=this.getDistanceFromCenterForValue(u.value);const f=this.getContext(d),v=a.setContext(f),m=s.setContext(f);VM(this,v,r,o,m)}}),i.display){for(t.save(),l=o-1;l>=0;l--){const u=i.setContext(this.getPointLabelContext(l)),{color:d,lineWidth:f}=u;!f||!d||(t.lineWidth=f,t.strokeStyle=d,t.setLineDash(u.borderDash),t.lineDashOffset=u.borderDashOffset,r=this.getDistanceFromCenterForValue(n.ticks.reverse?this.min:this.max),c=this.getPointPosition(l,r),t.beginPath(),t.moveTo(this.xCenter,this.yCenter),t.lineTo(c.x,c.y),t.stroke())}t.restore()}}drawBorder(){}drawLabels(){const t=this.ctx,n=this.options,i=n.ticks;if(!i.display)return;const a=this.getIndexAngle(0);let s,o;t.save(),t.translate(this.xCenter,this.yCenter),t.rotate(a),t.textAlign="center",t.textBaseline="middle",this.ticks.forEach((l,r)=>{if(r===0&&!n.reverse)return;const c=i.setContext(this.getContext(r)),u=Cn(c.font);if(s=this.getDistanceFromCenterForValue(this.ticks[r].value),c.showLabelBackdrop){t.font=u.string,o=t.measureText(l.label).width,t.fillStyle=c.backdropColor;const d=Kn(c.backdropPadding);t.fillRect(-o/2-d.left,-s-u.size/2-d.top,o+d.width,u.size+d.height)}Bl(t,l.label,0,-s,u,{color:c.color,strokeColor:c.textStrokeColor,strokeWidth:c.textStrokeWidth})}),t.restore()}drawTitle(){}}He(Wr,"id","radialLinear"),He(Wr,"defaults",{display:!0,animate:!0,position:"chartArea",angleLines:{display:!0,lineWidth:1,borderDash:[],borderDashOffset:0},grid:{circular:!1},startAngle:0,ticks:{showLabelBackdrop:!0,callback:ru.formatters.numeric},pointLabels:{backdropColor:void 0,backdropPadding:2,display:!0,font:{size:10},callback(t){return t},padding:5,centerPointLabels:!1}}),He(Wr,"defaultRoutes",{"angleLines.color":"borderColor","pointLabels.color":"color","ticks.color":"color"}),He(Wr,"descriptors",{angleLines:{_fallback:"grid"}});const du={millisecond:{common:!0,size:1,steps:1e3},second:{common:!0,size:1e3,steps:60},minute:{common:!0,size:6e4,steps:60},hour:{common:!0,size:36e5,steps:24},day:{common:!0,size:864e5,steps:30},week:{common:!1,size:6048e5,steps:4},month:{common:!0,size:2628e6,steps:12},quarter:{common:!1,size:7884e6,steps:4},year:{common:!0,size:3154e7}},Rn=Object.keys(du);function Yg(e,t){return e-t}function Kg(e,t){if(Dt(t))return null;const n=e._adapter,{parser:i,round:a,isoWeekday:s}=e._parseOpts;let o=t;return typeof i=="function"&&(o=i(o)),un(o)||(o=typeof i=="string"?n.parse(o,i):n.parse(o)),o===null?null:(a&&(o=a==="week"&&(wc(s)||s===!0)?n.startOf(o,"isoWeek",s):n.startOf(o,a)),+o)}function Gg(e,t,n,i){const a=Rn.length;for(let s=Rn.indexOf(e);s=Rn.indexOf(n);s--){const o=Rn[s];if(du[o].common&&e._adapter.diff(a,i,o)>=t-1)return o}return Rn[n?Rn.indexOf(n):0]}function MM(e){for(let t=Rn.indexOf(e)+1,n=Rn.length;t=t?n[i]:n[a];e[s]=!0}}function EM(e,t,n,i){const a=e._adapter,s=+a.startOf(t[0].value,i),o=t[t.length-1].value;let l,r;for(l=s;l<=o;l=+a.add(l,1,i))r=n[l],r>=0&&(t[r].major=!0);return t}function qg(e,t,n){const i=[],a={},s=t.length;let o,l;for(o=0;o+t.value))}initOffsets(t=[]){let n=0,i=0,a,s;this.options.offset&&t.length&&(a=this.getDecimalForValue(t[0]),t.length===1?n=1-a:n=(this.getDecimalForValue(t[1])-a)/2,s=this.getDecimalForValue(t[t.length-1]),t.length===1?i=s:i=(s-this.getDecimalForValue(t[t.length-2]))/2);const o=t.length<3?.5:.25;n=ai(n,0,o),i=ai(i,0,o),this._offsets={start:n,end:i,factor:1/(n+1+i)}}_generate(){const t=this._adapter,n=this.min,i=this.max,a=this.options,s=a.time,o=s.unit||Gg(s.minUnit,n,i,this._getLabelCapacity(n)),l=Rt(a.ticks.stepSize,1),r=o==="week"?s.isoWeekday:!1,c=wc(r)||r===!0,u={};let d=n,f,v;if(c&&(d=+t.startOf(d,"isoWeek",r)),d=+t.startOf(d,c?"day":o),t.diff(i,n,o)>1e5*l)throw new Error(n+" and "+i+" are too far apart with stepSize of "+l+" "+o);const m=a.ticks.source==="data"&&this.getDataTimestamps();for(f=d,v=0;f+g)}getLabelForValue(t){const n=this._adapter,i=this.options.time;return i.tooltipFormat?n.format(t,i.tooltipFormat):n.format(t,i.displayFormats.datetime)}format(t,n){const a=this.options.time.displayFormats,s=this._unit,o=n||a[s];return this._adapter.format(t,o)}_tickFormatFunction(t,n,i,a){const s=this.options,o=s.ticks.callback;if(o)return Nt(o,[t,n,i],this);const l=s.time.displayFormats,r=this._unit,c=this._majorUnit,u=r&&l[r],d=c&&l[c],f=i[n],v=c&&d&&f&&f.major;return this._adapter.format(t,a||(v?d:u))}generateTickLabels(t){let n,i,a;for(n=0,i=t.length;n0?l:1}getDataTimestamps(){let t=this._cache.data||[],n,i;if(t.length)return t;const a=this.getMatchingVisibleMetas();if(this._normalized&&a.length)return this._cache.data=a[0].controller.getAllParsedValues(this);for(n=0,i=a.length;n=e[i].pos&&t<=e[a].pos&&({lo:i,hi:a}=qd(e,"pos",t)),{pos:s,time:l}=e[i],{pos:o,time:r}=e[a]):(t>=e[i].time&&t<=e[a].time&&({lo:i,hi:a}=qd(e,"time",t)),{time:s,pos:l}=e[i],{time:o,pos:r}=e[a]);const c=o-s;return c?l+(r-l)*(t-s)/c:l}class Zg extends Tc{constructor(t){super(t),this._table=[],this._minPos=void 0,this._tableRange=void 0}initOffsets(){const t=this._getTimestampsForTable(),n=this._table=this.buildLookupTable(t);this._minPos=Ur(n,this.min),this._tableRange=Ur(n,this.max)-this._minPos,super.initOffsets(t)}buildLookupTable(t){const{min:n,max:i}=this,a=[],s=[];let o,l,r,c,u;for(o=0,l=t.length;o=n&&c<=i&&a.push(c);if(a.length<2)return[{time:n,pos:0},{time:i,pos:1}];for(o=0,l=a.length;oa-s)}_getTimestampsForTable(){let t=this._cache.all||[];if(t.length)return t;const n=this.getDataTimestamps(),i=this.getLabelTimestamps();return n.length&&i.length?t=this.normalize(n.concat(i)):t=n.length?n:i,t=this._cache.all=t,t}getDecimalForValue(t){return(Ur(this._table,t)-this._minPos)/this._tableRange}getValueForPixel(t){const n=this._offsets,i=this.getDecimalForPixel(t)/n.factor-n.end;return Ur(this._table,i*this._tableRange+this._minPos,!0)}}He(Zg,"id","timeseries"),He(Zg,"defaults",Tc.defaults);const P_={data:{type:Object,required:!0},options:{type:Object,default:()=>({})},plugins:{type:Array,default:()=>[]},datasetIdKey:{type:String,default:"label"},updateMode:{type:String,default:void 0}},DM={ariaLabel:{type:String},ariaDescribedby:{type:String}},OM={type:{type:String,required:!0},...P_,...DM},RM=dh[0]==="2"?(e,t)=>Object.assign(e,{attrs:t}):(e,t)=>Object.assign(e,t);function Xs(e){return Jl(e)?Ye(e):e}function LM(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:e;return Jl(t)?new Proxy(e,{}):e}function BM(e,t){const n=e.options;n&&t&&Object.assign(n,t)}function I_(e,t){e.labels=t}function V_(e,t,n){const i=[];e.datasets=t.map(a=>{const s=e.datasets.find(o=>o[n]===a[n]);return!s||!a.data||i.includes(s)?{...a}:(i.push(s),Object.assign(s,a),s)})}function NM(e,t){const n={labels:[],datasets:[]};return I_(n,e.labels),V_(n,e.datasets,t),n}const FM=La({props:OM,setup(e,t){let{expose:n,slots:i}=t;const a=Z(null),s=Se(null);n({chart:s});const o=()=>{if(!a.value)return;const{type:c,data:u,options:d,plugins:f,datasetIdKey:v}=e,m=NM(u,v),g=LM(m,u);s.value=new uu(a.value,{type:c,data:g,options:{...d},plugins:f})},l=()=>{const c=Ye(s.value);c&&(c.destroy(),s.value=null)},r=c=>{c.update(e.updateMode)};return _t(o),an(l),_e([()=>e.options,()=>e.data],(c,u)=>{let[d,f]=c,[v,m]=u;const g=Ye(s.value);if(!g)return;let p=!1;if(d){const y=Xs(d),b=Xs(v);y&&y!==b&&(BM(g,y),p=!0)}if(f){const y=Xs(f.labels),b=Xs(m.labels),S=Xs(f.datasets),_=Xs(m.datasets);y!==b&&(I_(g.config.data,y),p=!0),S&&S!==_&&(V_(g.config.data,S,e.datasetIdKey),p=!0)}p&&Ze(()=>{r(g)})},{deep:!0}),()=>Fn("canvas",{role:"img",ariaLabel:e.ariaLabel,ariaDescribedby:e.ariaDescribedby,ref:a},[Fn("p",{},[i.default?i.default():""])])}});function $M(e,t){return uu.register(t),La({props:P_,setup(n,i){let{expose:a}=i;const s=Se(null),o=l=>{s.value=l==null?void 0:l.chart};return a({chart:s}),()=>Fn(FM,RM({ref:o},{type:e,...n}))}})}const zM=$M("pie",Qd);const HM={class:"row gx-0 mb-1 mb-md-3 mb-xl-4"},jM={class:"col-12 col-xl-5 col-xxl-4 d-flex"},WM={class:"chart-wrapper"},UM={class:"col-12 col-xl-7 col-xxl-8 d-flex pt-3"},YM={class:"row gy-1 gy-xl-3 gx-md-5 items-wrapper"},KM={class:"col-12 col-sm-6 item-container"},GM={__name:"InfoPie",props:{items:Array},setup(e){const t=e;uu.register(sM,hM,sl);const n={responsive:!0,maintainAspectRatio:!1,animation:!1,plugins:{tooltip:{callbacks:{label:(a,s)=>" "+Math.round(a.parsed)+"% "}}}},i=w(()=>{const a={labels:[],datasets:[{data:[],backgroundColor:[]}]},s=t.items.reduce((l,r)=>{const c=r.locales.title,u=r.value;return a.labels.push(c),l+u},0),o=a.datasets[0];return t.items.forEach((l,r)=>{const c=l.value,u=Math.round(c*100/s);o.data.push(u),o.backgroundColor.push(l.customColor)}),a});return(a,s)=>(me(),Te("div",HM,[be("div",jM,[be("div",WM,[h(Je(zM),{class:"chart",data:i.value,options:n},null,8,["data"])])]),be("div",UM,[be("div",YM,[(me(!0),Te(Pe,null,At(t.items,o=>(me(),Te("div",KM,[h(bh,{item:o,"highlighted-header":!1,"small-description":!0,"description-with-progress-bar":!1,"icon-color-style":"customColor"},null,8,["item"])]))),256))])])]))}},XM=at(GM,[["__scopeId","data-v-437f703f"]]);const qM={class:"info-row row gx-4 gx-xl-5"},ZM={class:"col-12 subcategory-col"},JM={__name:"InfoSection",props:{sectionData:Object},setup(e){const t=e,n=Oi(),i=To(),a=Ba(),s={grid:tV,pie:XM,list:Hm,fallback:Hm},o=i.getStylePreferencesForPlugins(),l=c=>{const u=c.type;return s[u]||s.fallback},r=c=>{const u=t.sectionData.content.items[c.id];let d=0;for(const f of u)if(f.customColor=o.colors.random[d],d++,c.progress){const v=f.value,m=c.progress,g=a.parsePercentage(v,m);f.formattedPercentage=typeof m!="string"?n.getString(g):g}return u};return(c,u)=>(me(),Tt(yo,{"section-data":t.sectionData},{default:ie(()=>[be("div",qM,[(me(!0),Te(Pe,null,At(t.sectionData.content.subcategories.filter(d=>d.id==="abilities"),d=>(me(),Te("div",ZM,[d.locales.title?(me(),Tt(Ub,{key:0,title:d.locales.title,"fa-icon":d.faIcon},null,8,["title","fa-icon"])):kt("",!0),(me(),Tt(qc(l(d)),{items:r(d)},null,8,["items"]))]))),256))])]),_:1},8,["section-data"]))}},QM=at(JM,[["__scopeId","data-v-15744d8c"]]);const eE={class:"tags"},tE=["innerHTML"],nE={__name:"Tags",props:{items:Array,itemClass:String},setup(e){const t=e,n=w(()=>t.itemClass?t.itemClass:"bg-light text-dark");return(i,a)=>(me(),Te("div",eE,[(me(!0),Te(Pe,null,At(t.items,s=>(me(),Te("div",{class:xt(["tag badge text-1",n.value])},[s.faIcon?(me(),Te("i",{key:0,class:xt([s.faIcon,"me-2"])},null,2)):kt("",!0),be("span",{innerHTML:s.label||s},null,8,tE)],2))),256))]))}},A_=at(nE,[["__scopeId","data-v-233bbf6e"]]);const T_=e=>(Oa("data-v-85240ad3"),e=e(),Ra(),e),iE={class:"thread"},aE={class:"thread-item"},sE=T_(()=>be("span",{class:"fa fa-stack thread-icon"},[be("i",{class:"fa fa-circle fa-stack-1x"})],-1)),oE={class:"thread-item-content"},lE={class:"thread-item-title fw-bold pt-1 mb-1"},rE=["innerHTML"],cE=T_(()=>be("li",{class:"thread-item thread-item-end"},[be("span",{class:"fa fa-stack thread-icon thread-icon-small"},[be("i",{class:"fa fa-circle fa-stack-1x"})])],-1)),uE={__name:"Thread",props:{items:Array,linkLabel:String},setup(e){const t=e,n=ir(),i=Ba(),a=w(()=>i.reverseArray(t.items)),s=o=>{const l=o.place;return[{faIcon:"fa fa-calendar-check",label:i.localizeDate(o.date,n.getSelectedLanguage().id)},{faIcon:l.faIcon?l.faIcon:"fa fa-building",label:l.locales?l.locales.name:l}]};return(o,l)=>(me(),Te("ul",iE,[(me(!0),Te(Pe,null,At(a.value,r=>(me(),Te("li",aE,[sE,be("div",oE,[be("h6",lE,wt(r.locales.title),1),h(A_,{items:s(r),class:"mt-1 mb-2 mt-lg-2"},null,8,["items"]),be("p",{innerHTML:r.locales.description,class:"thread-item-description text-3 text-normal mb-1 mb-md-2"},null,8,rE)])]))),256)),cE]))}},dE=at(uE,[["__scopeId","data-v-85240ad3"]]);const fE={class:"row g-4 g-lg-5"},hE={class:"col-12 col-xxl-6 thread-container"},vE={__name:"ThreadsSection",props:{sectionData:Object},setup(e){const t=e;return(n,i)=>(me(),Tt(yo,{"section-data":t.sectionData},{default:ie(()=>[be("div",fE,[(me(!0),Te(Pe,null,At(t.sectionData.content.subcategories,a=>(me(),Te("div",hE,[h(Ub,{title:a.locales.title,"fa-icon":a.faIcon},null,8,["title","fa-icon"]),h(dE,{items:t.sectionData.content.items[a.id],"link-label":a.locales.buttonLabel},null,8,["items","link-label"])]))),256))])]),_:1},8,["section-data"]))}},mE=at(vE,[["__scopeId","data-v-09ad8a41"]]);const M_=e=>(Oa("data-v-5ab2d325"),e=e(),Ra(),e),gE={class:"timeline"},pE={class:"timeline-item"},yE={class:"timeline-item-content"},bE={class:"timeline-item-content-header"},_E={class:"flex-column-title"},xE=["innerHTML"],SE={class:"timeline-item-subtitle text-light-6 text-3"},wE=M_(()=>be("i",{class:"fa-solid fa-building me-2 ms-2"},null,-1)),kE={class:"flex-column-date"},CE={class:"timeline-item-content-body mt-3"},PE=["innerHTML"],IE=M_(()=>be("li",{class:"timeline-item timeline-item-tail"},[be("div",{class:"timeline-item-logo"})],-1)),VE={__name:"TimelineSection",props:{sectionData:Object},setup(e){const t=ir(),n=Ba(),i=e,a=w(()=>n.reverseArray(i.sectionData.content.items)),s=o=>{const l=o.period,r=n.localizeDate(l[0],t.getSelectedLanguage().id),c=n.localizeDate(l[1],t.getSelectedLanguage().id);return[{faIcon:"fa fa-calendar-check",label:r+' '+c}]};return(o,l)=>(me(),Tt(yo,{"section-data":i.sectionData},{default:ie(()=>[be("ul",gE,[(me(!0),Te(Pe,null,At(a.value,r=>(me(),Te("li",pE,[be("div",{class:xt(["timeline-item-logo",{"timeline-item-logo-bg-primary":!(r.place&&r.place.logoUrl)}])},[be("i",{class:xt(["timeline-item-fa-icon","fa-solid"])})],2),be("div",yE,[be("div",bE,[be("div",_E,[be("h4",{class:"timeline-item-title fw-bold",innerHTML:r.locales.title},null,8,xE),be("h6",SE,[wE,be("span",null,wt(r.place?r.place:""),1)])]),be("div",kE,[h(A_,{items:s(r),class:"mt-1 me-1"},null,8,["items"])])]),be("div",CE,[be("p",{class:"text-3 text-normal",innerHTML:r.locales.description},null,8,PE)])])]))),256)),IE])]),_:1},8,["section-data"]))}},AE=at(VE,[["__scopeId","data-v-5ab2d325"]]);const TE={class:"resume"},ME={class:"sidebar-column"},EE={class:"content-column"},DE={class:"nav-tabs-column"},OE={__name:"RouterView",setup(e){const t=Oi(),n=Na(),i=To(),a=ir(),s=_P(),o=ph(),l={},r={DefaultSection:yo,CoverSection:PI,InfoSection:QM,ThreadsSection:mE,TimelineSection:AE},c=m=>r[m]?r[m]:yo;_t(()=>{window.addEventListener("resize",u),window.addEventListener("scroll",u),_e(()=>s.name,()=>{u()}),_e(()=>a.getSelectedLanguage(),()=>{d()}),u(),n.isAllAtOnceMode()&&i.smoothScrollToElement(s.name,!0)}),Ms(()=>{window.removeEventListener("resize",u),window.removeEventListener("scroll",u)});const u=()=>{n.update(s.name)},d=()=>{const m=n.getActiveSectionId();n.isAllAtOnceMode()&&(i.instantScrollTo(window.scrollY-100,!0),i.smoothScrollToElement(m,!0))},f=m=>{if(n.registerSectionVisit(m),n.isAllAtOnceMode()){i.smoothScrollToElement(m,!1);return}const g=s.name;l[g]=window.scrollY,o.push({name:m}),n.update(g),i.instantScrollTo(l[m]??0,!0)},v=m=>{const g=n.getLastVisitedSectionOn(m);f(g)};return(m,g)=>(me(),Te("div",TE,[be("div",ME,[h(jP,{onLinkClicked:f})]),be("div",EE,[h(QP,{onLinkClicked:f}),(me(!0),Te(Pe,null,At(Je(t).getSections(),p=>(me(),Tt(qc(c(p.component)),{"section-data":p},null,8,["section-data"]))),256))]),be("div",DE,[h(sI,{onLinkClicked:v})])]))}},Jg=at(OE,[["__scopeId","data-v-77f976fb"]]);const RE={name:"App",data(){return{email:"",password:"",confirmPassword:"",isRegister:!1,errorMessage:"",stateObj:{register:{name:"Register",message:"Already have an Account? Login."},login:{name:"Login",message:"Register"}},rules:{emailRules:[e=>!!e||"E-mail is required",e=>/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|.(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/i.test(e)||"Must be a valid e-mail"]}}},methods:{validateEmailFormat(){for(let e of this.rules.emailRules){const t=e(this.email);if(t!==!0)return this.errorMessage=t,!1}return!0},login(){const e={email:this.email,password:this.password};this.validateEmailFormat()&&fetch("https://res-a-me-api.tobywinz.com/login",{method:"POST",body:JSON.stringify(e),headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*"},credentials:"include"}).then(t=>t.json()).then(async t=>{if(t.status===200){console.log("Login successful"),console.log(t),sessionStorage.setItem("access_token",t.access_token),sessionStorage.setItem("refresh_token",t.refresh_token);try{const i=await(await fetch("https://res-a-me-api.tobywinz.com/updateResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8"},body:JSON.stringify({email:this.email})})).json();i.status!==200&&console.error("Error fetching user resume: ",i.message),this.$router.push({path:"/home"}).then(()=>window.location.reload(!0))}catch(n){console.error("Error fetching user resume: ",n)}}else this.errorMessage="Login failed. Please try again."}).catch(t=>{console.error("There was an error!",t),this.errorMessage=t.message||"An error occurred. Please try again."})},register(){if(this.password===this.confirmPassword){const e={email:this.email,password:this.password};fetch("https://res-a-me-api.tobywinz.com/register",{method:"POST",headers:{"Content-Type":"application/json; charset=UTF-8"},body:JSON.stringify(e)}).then(t=>{if(!t.ok)throw new Error("Network response was not ok");return t.json()}).then(t=>{t.message==="Register successful"?(console.log("Registration successful"),sessionStorage.setItem("access_token",t.access_token),sessionStorage.setItem("refresh_token",t.refresh_token),this.$router.push("/edit")):this.errorMessage=t.message||"Registration failed. Please try again."}).catch(t=>{console.error("Registration error:",t),this.errorMessage=t.message||"An error occurred during registration."}),this.isRegister=!1,this.$refs.form.reset()}else this.errorMessage="Passwords did not match"}},computed:{toggleMessage:function(){return this.isRegister?this.stateObj.register.message:this.stateObj.login.message}}},LE={class:"red--text"};function BE(e,t,n,i,a,s){const o=we("v-col"),l=we("v-row"),r=we("v-img"),c=we("v-toolbar-title"),u=we("v-toolbar"),d=we("v-text-field"),f=we("v-btn"),v=we("v-card-text"),m=we("v-card"),g=we("v-container"),p=we("v-main"),y=we("v-app");return me(),Tt(y,{class:"background-image"},{default:ie(()=>[h(p,null,{default:ie(()=>[h(g,{"fill-height":""},{default:ie(()=>[h(l,{justify:"center",align:"center"},{default:ie(()=>[h(o,{cols:"12",sm:"8",md:"4"},{default:ie(()=>[(me(),Te(Pe,null,At(11,b=>h(l,{key:"row-"+b,justify:"center",align:"center"},{default:ie(()=>[(me(),Te(Pe,null,At(3,S=>h(o,{key:S,justify:"center",align:"center"})),64))]),_:2},1024)),64)),h(r,{class:"my-image",src:"images/background/icon.png"})]),_:1}),(me(),Te(Pe,null,At(1,b=>h(o,{key:"col-"+b,justify:"center",align:"center"})),64)),h(o,{cols:"12",sm:"8",md:"4"},{default:ie(()=>[(me(),Te(Pe,null,At(11,b=>h(l,{key:"row-"+b,justify:"center",align:"center"},{default:ie(()=>[(me(),Te(Pe,null,At(3,S=>h(o,{key:S,justify:"center",align:"center"})),64))]),_:2},1024)),64)),h(m,{class:"elevation-12"},{default:ie(()=>[h(u,{class:"toolbar-banner"},{default:ie(()=>[h(c,{class:"toolbar-title"},{default:ie(()=>[Xe(wt(a.isRegister?a.stateObj.register.name+" for ":a.stateObj.login.name+" to ")+" Res-a-Me",1)]),_:1})]),_:1}),h(v,null,{default:ie(()=>[be("form",{ref:"form",onSubmit:t[4]||(t[4]=El(b=>a.isRegister?s.register():s.login(),["prevent"]))},[h(d,{modelValue:a.email,"onUpdate:modelValue":t[0]||(t[0]=b=>a.email=b),rules:[a.rules.emailRules],label:"email",required:""},null,8,["modelValue","rules"]),h(d,{modelValue:a.password,"onUpdate:modelValue":t[1]||(t[1]=b=>a.password=b),label:"Password",type:"password",required:""},null,8,["modelValue"]),a.isRegister?(me(),Tt(d,{key:0,modelValue:a.confirmPassword,"onUpdate:modelValue":t[2]||(t[2]=b=>a.confirmPassword=b),label:"Confirm Password",type:"password",required:""},null,8,["modelValue"])):kt("",!0),be("div",LE,wt(a.errorMessage),1),h(f,{type:"submit",class:"mt-4 toolbar-banner",block:"",style:{color:"white"}},{default:ie(()=>[Xe(wt(a.isRegister?a.stateObj.register.name:a.stateObj.login.name),1)]),_:1}),h(l,{justify:"center"},{default:ie(()=>[h(o,{cols:"12",class:"text-center"},{default:ie(()=>[be("div",{class:"grey--text mt-4 yellow-text",onClick:t[3]||(t[3]=b=>{a.isRegister=!a.isRegister})},wt(s.toggleMessage),1)]),_:1})]),_:1})],544)]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})}const NE=at(RE,[["render",BE],["__scopeId","data-v-0813d3cc"]]);const FE={props:["skills"],setup(e,{emit:t}){return{deleteSkill:s=>{s!=-1&&t("delete-skill",s)},addNew:()=>{t("add-skill")},saveSkill:s=>{let o=!0;s.forEach((l,r)=>{(!l.title||!l.description)&&(o=!1)}),o?(alert("Your Skill information has been saved!"),t("save-skill",s)):confirm("Some fields may be incorrect. Please check!")}}}},$E=be("p",{class:"titletext",style:{"font-weight":"500"}},"Skill Set",-1),zE={class:"d-flex justify-center"};function HE(e,t,n,i,a,s){const o=we("v-icon"),l=we("v-row"),r=we("v-expansion-panel-title"),c=we("v-text-field"),u=we("v-col"),d=we("v-btn"),f=we("v-expansion-panel-text"),v=we("v-expansion-panel");return me(),Tt(v,null,{default:ie(()=>[h(r,{id:"title"},{default:ie(({expanded:m})=>[h(l,{"no-gutters":"",class:"d-flex jusitfy-start"},{default:ie(()=>[$E,h(o,{class:"ml-2",size:"xx-large",icon:"mdi-arrow-up-bold-box-outline"})]),_:1})]),_:1}),h(f,null,{default:ie(()=>[(me(!0),Te(Pe,null,At(n.skills,(m,g)=>(me(),Te("div",{key:g},[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"2"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.title,"onUpdate:modelValue":p=>m.title=p,rules:[()=>!!m.title||"This field is required"],counter:20,label:"Skill"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,{cols:"9"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.description,"onUpdate:modelValue":p=>m.description=p,rules:[()=>!!m.description||"This field is required"],counter:200,label:"Description"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,{class:"button-container"},{default:ie(()=>[h(d,{color:"red-lighten-2",onClick:p=>i.deleteSkill(g),class:"mb-4"},{default:ie(()=>[h(o,{size:"x-large",icon:"mdi-trash-can"})]),_:2},1032,["onClick"])]),_:2},1024)]),_:2},1024)]))),128)),be("div",zE,[h(d,{color:"grey-lighten-1",onClick:t[0]||(t[0]=m=>i.addNew())},{default:ie(()=>[Xe("Add more "),h(o,{size:"x-large",icon:"mdi-plus-thick"})]),_:1}),h(d,{color:"green",class:"ml-5",onClick:t[1]||(t[1]=m=>i.saveSkill(n.skills))},{default:ie(()=>[Xe("Save "),h(o,{size:"x-large",icon:"mdi-content-save"})]),_:1})])]),_:1})]),_:1})}const jE=at(FE,[["render",HE]]);var WE=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function UE(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function i(){return this instanceof i?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(i){var a=Object.getOwnPropertyDescriptor(e,i);Object.defineProperty(n,i,a.get?a:{enumerable:!0,get:function(){return e[i]}})}),n}var E_={};const YE=UE(vC);var D_={exports:{}};/*! +`):e}function oM(e,t){const{element:n,datasetIndex:i,index:a}=t,s=e.getDatasetMeta(i).controller,{label:o,value:l}=s.getLabelAndValue(a);return{chart:e,label:o,parsed:s.getParsed(a),raw:e.data.datasets[i].data[a],formattedValue:l,dataset:s.getDataset(),dataIndex:a,datasetIndex:i,element:n}}function Rg(e,t){const n=e.chart.ctx,{body:i,footer:a,title:s}=e,{boxWidth:o,boxHeight:l}=t,r=Cn(t.bodyFont),c=Cn(t.titleFont),u=Cn(t.footerFont),d=s.length,f=a.length,v=i.length,m=Kn(t.padding);let g=m.height,p=0,y=i.reduce((_,x)=>_+x.before.length+x.lines.length+x.after.length,0);if(y+=e.beforeBody.length+e.afterBody.length,d&&(g+=d*c.lineHeight+(d-1)*t.titleSpacing+t.titleMarginBottom),y){const _=t.displayColors?Math.max(l,r.lineHeight):r.lineHeight;g+=v*_+(y-v)*r.lineHeight+(y-1)*t.bodySpacing}f&&(g+=t.footerMarginTop+f*u.lineHeight+(f-1)*t.footerSpacing);let b=0;const S=function(_){p=Math.max(p,n.measureText(_).width+b)};return n.save(),n.font=c.string,vt(e.title,S),n.font=r.string,vt(e.beforeBody.concat(e.afterBody),S),b=t.displayColors?o+2+t.boxPadding:0,vt(i,_=>{vt(_.before,S),vt(_.lines,S),vt(_.after,S)}),b=0,n.font=u.string,vt(e.footer,S),n.restore(),p+=m.width,{width:p,height:g}}function lM(e,t){const{y:n,height:i}=t;return ne.height-i/2?"bottom":"center"}function rM(e,t,n,i){const{x:a,width:s}=i,o=n.caretSize+n.caretPadding;if(e==="left"&&a+s+o>t.width||e==="right"&&a-s-o<0)return!0}function cM(e,t,n,i){const{x:a,width:s}=n,{width:o,chartArea:{left:l,right:r}}=e;let c="center";return i==="center"?c=a<=(l+r)/2?"left":"right":a<=s/2?c="left":a>=o-s/2&&(c="right"),rM(c,e,t,n)&&(c="center"),c}function Lg(e,t,n){const i=n.yAlign||t.yAlign||lM(e,n);return{xAlign:n.xAlign||t.xAlign||cM(e,t,n,i),yAlign:i}}function uM(e,t){let{x:n,width:i}=e;return t==="right"?n-=i:t==="center"&&(n-=i/2),n}function dM(e,t,n){let{y:i,height:a}=e;return t==="top"?i+=n:t==="bottom"?i-=a+n:i-=a/2,i}function Bg(e,t,n,i){const{caretSize:a,caretPadding:s,cornerRadius:o}=e,{xAlign:l,yAlign:r}=n,c=a+s,{topLeft:u,topRight:d,bottomLeft:f,bottomRight:v}=_l(o);let m=uM(t,l);const g=dM(t,r,c);return r==="center"?l==="left"?m+=c:l==="right"&&(m-=c):l==="left"?m-=Math.max(u,f)+a:l==="right"&&(m+=Math.max(d,v)+a),{x:ai(m,0,i.width-t.width),y:ai(g,0,i.height-t.height)}}function jr(e,t,n){const i=Kn(n.padding);return t==="center"?e.x+e.width/2:t==="right"?e.x+e.width-i.right:e.x+i.left}function Ng(e){return ki([],ji(e))}function fM(e,t,n){return Es(e,{tooltip:t,tooltipItems:n,type:"tooltip"})}function Fg(e,t){const n=t&&t.dataset&&t.dataset.tooltip&&t.dataset.tooltip.callbacks;return n?e.override(n):e}const k_={beforeTitle:$i,title(e){if(e.length>0){const t=e[0],n=t.chart.data.labels,i=n?n.length:0;if(this&&this.options&&this.options.mode==="dataset")return t.dataset.label||"";if(t.label)return t.label;if(i>0&&t.dataIndex"u"?k_[t].call(n,i):a}class nf extends or{constructor(t){super(),this.opacity=0,this._active=[],this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.chart=t.chart,this.options=t.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0}initialize(t){this.options=t,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){const t=this._cachedAnimations;if(t)return t;const n=this.chart,i=this.options.setContext(this.getContext()),a=i.enabled&&n.options.animation&&i.animations,s=new f_(this.chart,a);return a._cacheable&&(this._cachedAnimations=Object.freeze(s)),s}getContext(){return this.$context||(this.$context=fM(this.chart.getContext(),this,this._tooltipItems))}getTitle(t,n){const{callbacks:i}=n,a=Dn(i,"beforeTitle",this,t),s=Dn(i,"title",this,t),o=Dn(i,"afterTitle",this,t);let l=[];return l=ki(l,ji(a)),l=ki(l,ji(s)),l=ki(l,ji(o)),l}getBeforeBody(t,n){return Ng(Dn(n.callbacks,"beforeBody",this,t))}getBody(t,n){const{callbacks:i}=n,a=[];return vt(t,s=>{const o={before:[],lines:[],after:[]},l=Fg(i,s);ki(o.before,ji(Dn(l,"beforeLabel",this,s))),ki(o.lines,Dn(l,"label",this,s)),ki(o.after,ji(Dn(l,"afterLabel",this,s))),a.push(o)}),a}getAfterBody(t,n){return Ng(Dn(n.callbacks,"afterBody",this,t))}getFooter(t,n){const{callbacks:i}=n,a=Dn(i,"beforeFooter",this,t),s=Dn(i,"footer",this,t),o=Dn(i,"afterFooter",this,t);let l=[];return l=ki(l,ji(a)),l=ki(l,ji(s)),l=ki(l,ji(o)),l}_createItems(t){const n=this._active,i=this.chart.data,a=[],s=[],o=[];let l=[],r,c;for(r=0,c=n.length;rt.filter(u,d,f,i))),t.itemSort&&(l=l.sort((u,d)=>t.itemSort(u,d,i))),vt(l,u=>{const d=Fg(t.callbacks,u);a.push(Dn(d,"labelColor",this,u)),s.push(Dn(d,"labelPointStyle",this,u)),o.push(Dn(d,"labelTextColor",this,u))}),this.labelColors=a,this.labelPointStyles=s,this.labelTextColors=o,this.dataPoints=l,l}update(t,n){const i=this.options.setContext(this.getContext()),a=this._active;let s,o=[];if(!a.length)this.opacity!==0&&(s={opacity:0});else{const l=ol[i.position].call(this,a,this._eventPosition);o=this._createItems(i),this.title=this.getTitle(o,i),this.beforeBody=this.getBeforeBody(o,i),this.body=this.getBody(o,i),this.afterBody=this.getAfterBody(o,i),this.footer=this.getFooter(o,i);const r=this._size=Rg(this,i),c=Object.assign({},l,r),u=Lg(this.chart,i,c),d=Bg(i,c,u,this.chart);this.xAlign=u.xAlign,this.yAlign=u.yAlign,s={opacity:1,x:d.x,y:d.y,width:r.width,height:r.height,caretX:l.x,caretY:l.y}}this._tooltipItems=o,this.$context=void 0,s&&this._resolveAnimations().update(this,s),t&&i.external&&i.external.call(this,{chart:this.chart,tooltip:this,replay:n})}drawCaret(t,n,i,a){const s=this.getCaretPosition(t,i,a);n.lineTo(s.x1,s.y1),n.lineTo(s.x2,s.y2),n.lineTo(s.x3,s.y3)}getCaretPosition(t,n,i){const{xAlign:a,yAlign:s}=this,{caretSize:o,cornerRadius:l}=i,{topLeft:r,topRight:c,bottomLeft:u,bottomRight:d}=_l(l),{x:f,y:v}=t,{width:m,height:g}=n;let p,y,b,S,_,x;return s==="center"?(_=v+g/2,a==="left"?(p=f,y=p-o,S=_+o,x=_-o):(p=f+m,y=p+o,S=_-o,x=_+o),b=p):(a==="left"?y=f+Math.max(r,u)+o:a==="right"?y=f+m-Math.max(c,d)-o:y=this.caretX,s==="top"?(S=v,_=S-o,p=y-o,b=y+o):(S=v+g,_=S+o,p=y+o,b=y-o),x=S),{x1:p,x2:y,x3:b,y1:S,y2:_,y3:x}}drawTitle(t,n,i){const a=this.title,s=a.length;let o,l,r;if(s){const c=fd(i.rtl,this.x,this.width);for(t.x=jr(this,i.titleAlign,i),n.textAlign=c.textAlign(i.titleAlign),n.textBaseline="middle",o=Cn(i.titleFont),l=i.titleSpacing,n.fillStyle=i.titleColor,n.font=o.string,r=0;rb!==0)?(t.beginPath(),t.fillStyle=s.multiKeyBackground,Jd(t,{x:g,y:m,w:c,h:r,radius:y}),t.fill(),t.stroke(),t.fillStyle=o.backgroundColor,t.beginPath(),Jd(t,{x:p,y:m+1,w:c-2,h:r-2,radius:y}),t.fill()):(t.fillStyle=s.multiKeyBackground,t.fillRect(g,m,c,r),t.strokeRect(g,m,c,r),t.fillStyle=o.backgroundColor,t.fillRect(p,m+1,c-2,r-2))}t.fillStyle=this.labelTextColors[i]}drawBody(t,n,i){const{body:a}=this,{bodySpacing:s,bodyAlign:o,displayColors:l,boxHeight:r,boxWidth:c,boxPadding:u}=i,d=Cn(i.bodyFont);let f=d.lineHeight,v=0;const m=fd(i.rtl,this.x,this.width),g=function(V){n.fillText(V,m.x(t.x+v),t.y+f/2),t.y+=f+s},p=m.textAlign(o);let y,b,S,_,x,P,C;for(n.textAlign=o,n.textBaseline="middle",n.font=d.string,t.x=jr(this,p,i),n.fillStyle=i.bodyColor,vt(this.beforeBody,g),v=l&&p!=="right"?o==="center"?c/2+u:c+2+u:0,_=0,P=a.length;_0&&n.stroke()}_updateAnimationTarget(t){const n=this.chart,i=this.$animations,a=i&&i.x,s=i&&i.y;if(a||s){const o=ol[t.position].call(this,this._active,this._eventPosition);if(!o)return;const l=this._size=Rg(this,t),r=Object.assign({},o,this._size),c=Lg(n,t,r),u=Bg(t,r,c,n);(a._to!==u.x||s._to!==u.y)&&(this.xAlign=c.xAlign,this.yAlign=c.yAlign,this.width=l.width,this.height=l.height,this.caretX=o.x,this.caretY=o.y,this._resolveAnimations().update(this,u))}}_willRender(){return!!this.opacity}draw(t){const n=this.options.setContext(this.getContext());let i=this.opacity;if(!i)return;this._updateAnimationTarget(n);const a={width:this.width,height:this.height},s={x:this.x,y:this.y};i=Math.abs(i)<.001?0:i;const o=Kn(n.padding),l=this.title.length||this.beforeBody.length||this.body.length||this.afterBody.length||this.footer.length;n.enabled&&l&&(t.save(),t.globalAlpha=i,this.drawBackground(s,t,a,n),PA(t,n.textDirection),s.y+=o.top,this.drawTitle(s,t,n),this.drawBody(s,t,n),this.drawFooter(s,t,n),IA(t,n.textDirection),t.restore())}getActiveElements(){return this._active||[]}setActiveElements(t,n){const i=this._active,a=t.map(({datasetIndex:l,index:r})=>{const c=this.chart.getDatasetMeta(l);if(!c)throw new Error("Cannot find a dataset at index "+l);return{datasetIndex:l,element:c.data[r],index:r}}),s=!yc(i,a),o=this._positionChanged(a,n);(s||o)&&(this._active=a,this._eventPosition=n,this._ignoreReplayEvents=!0,this.update(!0))}handleEvent(t,n,i=!0){if(n&&this._ignoreReplayEvents)return!1;this._ignoreReplayEvents=!1;const a=this.options,s=this._active||[],o=this._getActiveElements(t,s,n,i),l=this._positionChanged(o,t),r=n||!yc(o,s)||l;return r&&(this._active=o,(a.enabled||a.external)&&(this._eventPosition={x:t.x,y:t.y},this.update(!0,n))),r}_getActiveElements(t,n,i,a){const s=this.options;if(t.type==="mouseout")return[];if(!a)return n.filter(l=>this.chart.data.datasets[l.datasetIndex]&&this.chart.getDatasetMeta(l.datasetIndex).controller.getParsed(l.index)!==void 0);const o=this.chart.getElementsAtEventForMode(t,s.mode,s,i);return s.reverse&&o.reverse(),o}_positionChanged(t,n){const{caretX:i,caretY:a,options:s}=this,o=ol[s.position].call(this,t,n);return o!==!1&&(i!==o.x||a!==o.y)}}He(nf,"positioners",ol);var hM={id:"tooltip",_element:nf,positioners:ol,afterInit(e,t,n){n&&(e.tooltip=new nf({chart:e,options:n}))},beforeUpdate(e,t,n){e.tooltip&&e.tooltip.initialize(n)},reset(e,t,n){e.tooltip&&e.tooltip.initialize(n)},afterDraw(e){const t=e.tooltip;if(t&&t._willRender()){const n={tooltip:t};if(e.notifyPlugins("beforeTooltipDraw",{...n,cancelable:!0})===!1)return;t.draw(e.ctx),e.notifyPlugins("afterTooltipDraw",n)}},afterEvent(e,t){if(e.tooltip){const n=t.replay;e.tooltip.handleEvent(t.event,n,t.inChartArea)&&(t.changed=!0)}},defaults:{enabled:!0,external:null,position:"average",backgroundColor:"rgba(0,0,0,0.8)",titleColor:"#fff",titleFont:{weight:"bold"},titleSpacing:2,titleMarginBottom:6,titleAlign:"left",bodyColor:"#fff",bodySpacing:2,bodyFont:{},bodyAlign:"left",footerColor:"#fff",footerSpacing:2,footerMarginTop:6,footerFont:{weight:"bold"},footerAlign:"left",padding:6,caretPadding:2,caretSize:5,cornerRadius:6,boxHeight:(e,t)=>t.bodyFont.size,boxWidth:(e,t)=>t.bodyFont.size,multiKeyBackground:"#fff",displayColors:!0,boxPadding:0,borderColor:"rgba(0,0,0,0)",borderWidth:0,animation:{duration:400,easing:"easeOutQuart"},animations:{numbers:{type:"number",properties:["x","y","width","height","caretX","caretY"]},opacity:{easing:"linear",duration:200}},callbacks:k_},defaultRoutes:{bodyFont:"font",footerFont:"font",titleFont:"font"},descriptors:{_scriptable:e=>e!=="filter"&&e!=="itemSort"&&e!=="external",_indexable:!1,callbacks:{_scriptable:!1,_indexable:!1},animation:{_fallback:!1},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]};function vM(e,t){const n=[],{bounds:a,step:s,min:o,max:l,precision:r,count:c,maxTicks:u,maxDigits:d,includeBounds:f}=e,v=s||1,m=u-1,{min:g,max:p}=t,y=!Dt(o),b=!Dt(l),S=!Dt(c),_=(p-g)/(d+1);let x=qm((p-g)/m/v)*v,P,C,V,I;if(x<1e-14&&!y&&!b)return[{value:g},{value:p}];I=Math.ceil(p/x)-Math.floor(g/x),I>m&&(x=qm(I*x/m/v)*v),Dt(r)||(P=Math.pow(10,r),x=Math.ceil(x*P)/P),a==="ticks"?(C=Math.floor(g/x)*x,V=Math.ceil(p/x)*x):(C=g,V=p),y&&b&&s&&DV((l-o)/s,x/1e3)?(I=Math.round(Math.min((l-o)/x,u)),x=(l-o)/I,C=o,V=l):S?(C=y?o:C,V=b?l:V,I=c-1,x=(V-C)/I):(I=(V-C)/x,tc(I,Math.round(I),x/1e3)?I=Math.round(I):I=Math.ceil(I));const M=Math.max(Zm(x),Zm(C));P=Math.pow(10,Dt(r)?M:r),C=Math.round(C*P)/P,V=Math.round(V*P)/P;let O=0;for(y&&(f&&C!==o?(n.push({value:o}),Cl)break;n.push({value:D})}return b&&f&&V!==l?n.length&&tc(n[n.length-1].value,l,$g(l,_,e))?n[n.length-1].value=l:n.push({value:l}):(!b||V===l)&&n.push({value:V}),n}function $g(e,t,{horizontal:n,minRotation:i}){const a=Ai(i),s=(n?Math.sin(a):Math.cos(a))||.001,o=.75*t*(""+e).length;return Math.min(t/s,o)}class Ac extends Mo{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(t,n){return Dt(t)||(typeof t=="number"||t instanceof Number)&&!isFinite(+t)?null:+t}handleTickRangeOptions(){const{beginAtZero:t}=this.options,{minDefined:n,maxDefined:i}=this.getUserBounds();let{min:a,max:s}=this;const o=r=>a=n?a:r,l=r=>s=i?s:r;if(t){const r=Sc(a),c=Sc(s);r<0&&c<0?l(0):r>0&&c>0&&o(0)}if(a===s){let r=s===0?1:Math.abs(s*.05);l(s+r),t||o(a-r)}this.min=a,this.max=s}getTickLimit(){const t=this.options.ticks;let{maxTicksLimit:n,stepSize:i}=t,a;return i?(a=Math.ceil(this.max/i)-Math.floor(this.min/i)+1,a>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${i} would result generating up to ${a} ticks. Limiting to 1000.`),a=1e3)):(a=this.computeTickLimit(),n=n||11),n&&(a=Math.min(n,a)),a}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){const t=this.options,n=t.ticks;let i=this.getTickLimit();i=Math.max(2,i);const a={maxTicks:i,bounds:t.bounds,min:t.min,max:t.max,precision:n.precision,step:n.stepSize,count:n.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:n.minRotation||0,includeBounds:n.includeBounds!==!1},s=this._range||this,o=vM(a,s);return t.bounds==="ticks"&&Jb(o,this,"value"),t.reverse?(o.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),o}configure(){const t=this.ticks;let n=this.min,i=this.max;if(super.configure(),this.options.offset&&t.length){const a=(i-n)/Math.max(t.length-1,1)/2;n-=a,i+=a}this._startValue=n,this._endValue=i,this._valueRange=i-n}getLabelForValue(t){return lu(t,this.chart.options.locale,this.options.ticks.format)}}class zg extends Ac{determineDataLimits(){const{min:t,max:n}=this.getMinMax(!0);this.min=un(t)?t:0,this.max=un(n)?n:1,this.handleTickRangeOptions()}computeTickLimit(){const t=this.isHorizontal(),n=t?this.width:this.height,i=Ai(this.options.ticks.minRotation),a=(t?Math.sin(i):Math.cos(i))||.001,s=this._resolveTickFontOptions(0);return Math.ceil(n/Math.min(40,s.lineHeight/a))}getPixelForValue(t){return t===null?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getValueForPixel(t){return this._startValue+this.getDecimalForPixel(t)*this._valueRange}}He(zg,"id","linear"),He(zg,"defaults",{ticks:{callback:ru.formatters.numeric}});const Fl=e=>Math.floor(xa(e)),es=(e,t)=>Math.pow(10,Fl(e)+t);function Hg(e){return e/Math.pow(10,Fl(e))===1}function jg(e,t,n){const i=Math.pow(10,n),a=Math.floor(e/i);return Math.ceil(t/i)-a}function mM(e,t){const n=t-e;let i=Fl(n);for(;jg(e,t,i)>10;)i++;for(;jg(e,t,i)<10;)i--;return Math.min(i,Fl(e))}function gM(e,{min:t,max:n}){t=Hn(e.min,t);const i=[],a=Fl(t);let s=mM(t,n),o=s<0?Math.pow(10,Math.abs(s)):1;const l=Math.pow(10,s),r=a>s?Math.pow(10,a):0,c=Math.round((t-r)*o)/o,u=Math.floor((t-r)/l/10)*l*10;let d=Math.floor((c-u)/Math.pow(10,s)),f=Hn(e.min,Math.round((r+u+d*Math.pow(10,s))*o)/o);for(;f=10?d=d<15?15:20:d++,d>=20&&(s++,d=2,o=s>=0?1:o),f=Math.round((r+u+d*Math.pow(10,s))*o)/o;const v=Hn(e.max,f);return i.push({value:v,major:Hg(v),significand:d}),i}class Wg extends Mo{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._valueRange=0}parse(t,n){const i=Ac.prototype.parse.apply(this,[t,n]);if(i===0){this._zero=!0;return}return un(i)&&i>0?i:null}determineDataLimits(){const{min:t,max:n}=this.getMinMax(!0);this.min=un(t)?Math.max(0,t):null,this.max=un(n)?Math.max(0,n):null,this.options.beginAtZero&&(this._zero=!0),this._zero&&this.min!==this._suggestedMin&&!un(this._userMin)&&(this.min=t===es(this.min,0)?es(this.min,-1):es(this.min,0)),this.handleTickRangeOptions()}handleTickRangeOptions(){const{minDefined:t,maxDefined:n}=this.getUserBounds();let i=this.min,a=this.max;const s=l=>i=t?i:l,o=l=>a=n?a:l;i===a&&(i<=0?(s(1),o(10)):(s(es(i,-1)),o(es(a,1)))),i<=0&&s(es(a,-1)),a<=0&&o(es(i,1)),this.min=i,this.max=a}buildTicks(){const t=this.options,n={min:this._userMin,max:this._userMax},i=gM(n,this);return t.bounds==="ticks"&&Jb(i,this,"value"),t.reverse?(i.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),i}getLabelForValue(t){return t===void 0?"0":lu(t,this.chart.options.locale,this.options.ticks.format)}configure(){const t=this.min;super.configure(),this._startValue=xa(t),this._valueRange=xa(this.max)-xa(t)}getPixelForValue(t){return(t===void 0||t===0)&&(t=this.min),t===null||isNaN(t)?NaN:this.getPixelForDecimal(t===this.min?0:(xa(t)-this._startValue)/this._valueRange)}getValueForPixel(t){const n=this.getDecimalForPixel(t);return Math.pow(10,this._startValue+n*this._valueRange)}}He(Wg,"id","logarithmic"),He(Wg,"defaults",{ticks:{callback:ru.formatters.logarithmic,major:{enabled:!0}}});function af(e){const t=e.ticks;if(t.display&&e.display){const n=Kn(t.backdropPadding);return Rt(t.font&&t.font.size,Ut.font.size)+n.height}return 0}function pM(e,t,n){return n=Ot(n)?n:[n],{w:ZV(e,t.string,n),h:n.length*t.lineHeight}}function Ug(e,t,n,i,a){return e===i||e===a?{start:t-n/2,end:t+n/2}:ea?{start:t-n,end:t}:{start:t,end:t+n}}function yM(e){const t={l:e.left+e._padding.left,r:e.right-e._padding.right,t:e.top+e._padding.top,b:e.bottom-e._padding.bottom},n=Object.assign({},t),i=[],a=[],s=e._pointLabels.length,o=e.options.pointLabels,l=o.centerPointLabels?zt/s:0;for(let r=0;rt.r&&(l=(i.end-t.r)/s,e.r=Math.max(e.r,t.r+l)),a.startt.b&&(r=(a.end-t.b)/o,e.b=Math.max(e.b,t.b+r))}function _M(e,t,n){const i=e.drawingArea,{extra:a,additionalAngle:s,padding:o,size:l}=n,r=e.getPointPosition(t,i+a+o,s),c=Math.round(kh(Ii(r.angle+Wt))),u=CM(r.y,l.h,c),d=wM(c),f=kM(r.x,l.w,d);return{visible:!0,x:r.x,y:u,textAlign:d,left:f,top:u,right:f+l.w,bottom:u+l.h}}function xM(e,t){if(!t)return!0;const{left:n,top:i,right:a,bottom:s}=e;return!(io({x:n,y:i},t)||io({x:n,y:s},t)||io({x:a,y:i},t)||io({x:a,y:s},t))}function SM(e,t,n){const i=[],a=e._pointLabels.length,s=e.options,{centerPointLabels:o,display:l}=s.pointLabels,r={extra:af(s)/2,additionalAngle:o?zt/a:0};let c;for(let u=0;u270||n<90)&&(e-=t),e}function PM(e,t,n){const{left:i,top:a,right:s,bottom:o}=n,{backdropColor:l}=t;if(!Dt(l)){const r=_l(t.borderRadius),c=Kn(t.backdropPadding);e.fillStyle=l;const u=i-c.left,d=a-c.top,f=s-i+c.width,v=o-a+c.height;Object.values(r).some(m=>m!==0)?(e.beginPath(),Jd(e,{x:u,y:d,w:f,h:v,radius:r}),e.fill()):e.fillRect(u,d,f,v)}}function IM(e,t){const{ctx:n,options:{pointLabels:i}}=e;for(let a=t-1;a>=0;a--){const s=e._pointLabelItems[a];if(!s.visible)continue;const o=i.setContext(e.getPointLabelContext(a));PM(n,o,s);const l=Cn(o.font),{x:r,y:c,textAlign:u}=s;Bl(n,e._pointLabels[a],r,c+l.lineHeight/2,l,{color:o.color,textAlign:u,textBaseline:"middle"})}}function C_(e,t,n,i){const{ctx:a}=e;if(n)a.arc(e.xCenter,e.yCenter,t,0,$t);else{let s=e.getPointPosition(0,t);a.moveTo(s.x,s.y);for(let o=1;o{const a=Nt(this.options.pointLabels.callback,[n,i],this);return a||a===0?a:""}).filter((n,i)=>this.chart.getDataVisibility(i))}fit(){const t=this.options;t.display&&t.pointLabels.display?yM(this):this.setCenterPoint(0,0,0,0)}setCenterPoint(t,n,i,a){this.xCenter+=Math.floor((t-n)/2),this.yCenter+=Math.floor((i-a)/2),this.drawingArea-=Math.min(this.drawingArea/2,Math.max(t,n,i,a))}getIndexAngle(t){const n=$t/(this._pointLabels.length||1),i=this.options.startAngle||0;return Ii(t*n+Ai(i))}getDistanceFromCenterForValue(t){if(Dt(t))return NaN;const n=this.drawingArea/(this.max-this.min);return this.options.reverse?(this.max-t)*n:(t-this.min)*n}getValueForDistanceFromCenter(t){if(Dt(t))return NaN;const n=t/(this.drawingArea/(this.max-this.min));return this.options.reverse?this.max-n:this.min+n}getPointLabelContext(t){const n=this._pointLabels||[];if(t>=0&&t{if(d!==0){r=this.getDistanceFromCenterForValue(u.value);const f=this.getContext(d),v=a.setContext(f),m=s.setContext(f);VM(this,v,r,o,m)}}),i.display){for(t.save(),l=o-1;l>=0;l--){const u=i.setContext(this.getPointLabelContext(l)),{color:d,lineWidth:f}=u;!f||!d||(t.lineWidth=f,t.strokeStyle=d,t.setLineDash(u.borderDash),t.lineDashOffset=u.borderDashOffset,r=this.getDistanceFromCenterForValue(n.ticks.reverse?this.min:this.max),c=this.getPointPosition(l,r),t.beginPath(),t.moveTo(this.xCenter,this.yCenter),t.lineTo(c.x,c.y),t.stroke())}t.restore()}}drawBorder(){}drawLabels(){const t=this.ctx,n=this.options,i=n.ticks;if(!i.display)return;const a=this.getIndexAngle(0);let s,o;t.save(),t.translate(this.xCenter,this.yCenter),t.rotate(a),t.textAlign="center",t.textBaseline="middle",this.ticks.forEach((l,r)=>{if(r===0&&!n.reverse)return;const c=i.setContext(this.getContext(r)),u=Cn(c.font);if(s=this.getDistanceFromCenterForValue(this.ticks[r].value),c.showLabelBackdrop){t.font=u.string,o=t.measureText(l.label).width,t.fillStyle=c.backdropColor;const d=Kn(c.backdropPadding);t.fillRect(-o/2-d.left,-s-u.size/2-d.top,o+d.width,u.size+d.height)}Bl(t,l.label,0,-s,u,{color:c.color,strokeColor:c.textStrokeColor,strokeWidth:c.textStrokeWidth})}),t.restore()}drawTitle(){}}He(Wr,"id","radialLinear"),He(Wr,"defaults",{display:!0,animate:!0,position:"chartArea",angleLines:{display:!0,lineWidth:1,borderDash:[],borderDashOffset:0},grid:{circular:!1},startAngle:0,ticks:{showLabelBackdrop:!0,callback:ru.formatters.numeric},pointLabels:{backdropColor:void 0,backdropPadding:2,display:!0,font:{size:10},callback(t){return t},padding:5,centerPointLabels:!1}}),He(Wr,"defaultRoutes",{"angleLines.color":"borderColor","pointLabels.color":"color","ticks.color":"color"}),He(Wr,"descriptors",{angleLines:{_fallback:"grid"}});const du={millisecond:{common:!0,size:1,steps:1e3},second:{common:!0,size:1e3,steps:60},minute:{common:!0,size:6e4,steps:60},hour:{common:!0,size:36e5,steps:24},day:{common:!0,size:864e5,steps:30},week:{common:!1,size:6048e5,steps:4},month:{common:!0,size:2628e6,steps:12},quarter:{common:!1,size:7884e6,steps:4},year:{common:!0,size:3154e7}},Rn=Object.keys(du);function Yg(e,t){return e-t}function Kg(e,t){if(Dt(t))return null;const n=e._adapter,{parser:i,round:a,isoWeekday:s}=e._parseOpts;let o=t;return typeof i=="function"&&(o=i(o)),un(o)||(o=typeof i=="string"?n.parse(o,i):n.parse(o)),o===null?null:(a&&(o=a==="week"&&(wc(s)||s===!0)?n.startOf(o,"isoWeek",s):n.startOf(o,a)),+o)}function Gg(e,t,n,i){const a=Rn.length;for(let s=Rn.indexOf(e);s=Rn.indexOf(n);s--){const o=Rn[s];if(du[o].common&&e._adapter.diff(a,i,o)>=t-1)return o}return Rn[n?Rn.indexOf(n):0]}function MM(e){for(let t=Rn.indexOf(e)+1,n=Rn.length;t=t?n[i]:n[a];e[s]=!0}}function EM(e,t,n,i){const a=e._adapter,s=+a.startOf(t[0].value,i),o=t[t.length-1].value;let l,r;for(l=s;l<=o;l=+a.add(l,1,i))r=n[l],r>=0&&(t[r].major=!0);return t}function qg(e,t,n){const i=[],a={},s=t.length;let o,l;for(o=0;o+t.value))}initOffsets(t=[]){let n=0,i=0,a,s;this.options.offset&&t.length&&(a=this.getDecimalForValue(t[0]),t.length===1?n=1-a:n=(this.getDecimalForValue(t[1])-a)/2,s=this.getDecimalForValue(t[t.length-1]),t.length===1?i=s:i=(s-this.getDecimalForValue(t[t.length-2]))/2);const o=t.length<3?.5:.25;n=ai(n,0,o),i=ai(i,0,o),this._offsets={start:n,end:i,factor:1/(n+1+i)}}_generate(){const t=this._adapter,n=this.min,i=this.max,a=this.options,s=a.time,o=s.unit||Gg(s.minUnit,n,i,this._getLabelCapacity(n)),l=Rt(a.ticks.stepSize,1),r=o==="week"?s.isoWeekday:!1,c=wc(r)||r===!0,u={};let d=n,f,v;if(c&&(d=+t.startOf(d,"isoWeek",r)),d=+t.startOf(d,c?"day":o),t.diff(i,n,o)>1e5*l)throw new Error(n+" and "+i+" are too far apart with stepSize of "+l+" "+o);const m=a.ticks.source==="data"&&this.getDataTimestamps();for(f=d,v=0;f+g)}getLabelForValue(t){const n=this._adapter,i=this.options.time;return i.tooltipFormat?n.format(t,i.tooltipFormat):n.format(t,i.displayFormats.datetime)}format(t,n){const a=this.options.time.displayFormats,s=this._unit,o=n||a[s];return this._adapter.format(t,o)}_tickFormatFunction(t,n,i,a){const s=this.options,o=s.ticks.callback;if(o)return Nt(o,[t,n,i],this);const l=s.time.displayFormats,r=this._unit,c=this._majorUnit,u=r&&l[r],d=c&&l[c],f=i[n],v=c&&d&&f&&f.major;return this._adapter.format(t,a||(v?d:u))}generateTickLabels(t){let n,i,a;for(n=0,i=t.length;n0?l:1}getDataTimestamps(){let t=this._cache.data||[],n,i;if(t.length)return t;const a=this.getMatchingVisibleMetas();if(this._normalized&&a.length)return this._cache.data=a[0].controller.getAllParsedValues(this);for(n=0,i=a.length;n=e[i].pos&&t<=e[a].pos&&({lo:i,hi:a}=qd(e,"pos",t)),{pos:s,time:l}=e[i],{pos:o,time:r}=e[a]):(t>=e[i].time&&t<=e[a].time&&({lo:i,hi:a}=qd(e,"time",t)),{time:s,pos:l}=e[i],{time:o,pos:r}=e[a]);const c=o-s;return c?l+(r-l)*(t-s)/c:l}class Zg extends Tc{constructor(t){super(t),this._table=[],this._minPos=void 0,this._tableRange=void 0}initOffsets(){const t=this._getTimestampsForTable(),n=this._table=this.buildLookupTable(t);this._minPos=Ur(n,this.min),this._tableRange=Ur(n,this.max)-this._minPos,super.initOffsets(t)}buildLookupTable(t){const{min:n,max:i}=this,a=[],s=[];let o,l,r,c,u;for(o=0,l=t.length;o=n&&c<=i&&a.push(c);if(a.length<2)return[{time:n,pos:0},{time:i,pos:1}];for(o=0,l=a.length;oa-s)}_getTimestampsForTable(){let t=this._cache.all||[];if(t.length)return t;const n=this.getDataTimestamps(),i=this.getLabelTimestamps();return n.length&&i.length?t=this.normalize(n.concat(i)):t=n.length?n:i,t=this._cache.all=t,t}getDecimalForValue(t){return(Ur(this._table,t)-this._minPos)/this._tableRange}getValueForPixel(t){const n=this._offsets,i=this.getDecimalForPixel(t)/n.factor-n.end;return Ur(this._table,i*this._tableRange+this._minPos,!0)}}He(Zg,"id","timeseries"),He(Zg,"defaults",Tc.defaults);const P_={data:{type:Object,required:!0},options:{type:Object,default:()=>({})},plugins:{type:Array,default:()=>[]},datasetIdKey:{type:String,default:"label"},updateMode:{type:String,default:void 0}},DM={ariaLabel:{type:String},ariaDescribedby:{type:String}},OM={type:{type:String,required:!0},...P_,...DM},RM=dh[0]==="2"?(e,t)=>Object.assign(e,{attrs:t}):(e,t)=>Object.assign(e,t);function Xs(e){return Jl(e)?Ye(e):e}function LM(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:e;return Jl(t)?new Proxy(e,{}):e}function BM(e,t){const n=e.options;n&&t&&Object.assign(n,t)}function I_(e,t){e.labels=t}function V_(e,t,n){const i=[];e.datasets=t.map(a=>{const s=e.datasets.find(o=>o[n]===a[n]);return!s||!a.data||i.includes(s)?{...a}:(i.push(s),Object.assign(s,a),s)})}function NM(e,t){const n={labels:[],datasets:[]};return I_(n,e.labels),V_(n,e.datasets,t),n}const FM=La({props:OM,setup(e,t){let{expose:n,slots:i}=t;const a=Z(null),s=Se(null);n({chart:s});const o=()=>{if(!a.value)return;const{type:c,data:u,options:d,plugins:f,datasetIdKey:v}=e,m=NM(u,v),g=LM(m,u);s.value=new uu(a.value,{type:c,data:g,options:{...d},plugins:f})},l=()=>{const c=Ye(s.value);c&&(c.destroy(),s.value=null)},r=c=>{c.update(e.updateMode)};return _t(o),an(l),_e([()=>e.options,()=>e.data],(c,u)=>{let[d,f]=c,[v,m]=u;const g=Ye(s.value);if(!g)return;let p=!1;if(d){const y=Xs(d),b=Xs(v);y&&y!==b&&(BM(g,y),p=!0)}if(f){const y=Xs(f.labels),b=Xs(m.labels),S=Xs(f.datasets),_=Xs(m.datasets);y!==b&&(I_(g.config.data,y),p=!0),S&&S!==_&&(V_(g.config.data,S,e.datasetIdKey),p=!0)}p&&Ze(()=>{r(g)})},{deep:!0}),()=>Fn("canvas",{role:"img",ariaLabel:e.ariaLabel,ariaDescribedby:e.ariaDescribedby,ref:a},[Fn("p",{},[i.default?i.default():""])])}});function $M(e,t){return uu.register(t),La({props:P_,setup(n,i){let{expose:a}=i;const s=Se(null),o=l=>{s.value=l==null?void 0:l.chart};return a({chart:s}),()=>Fn(FM,RM({ref:o},{type:e,...n}))}})}const zM=$M("pie",Qd);const HM={class:"row gx-0 mb-1 mb-md-3 mb-xl-4"},jM={class:"col-12 col-xl-5 col-xxl-4 d-flex"},WM={class:"chart-wrapper"},UM={class:"col-12 col-xl-7 col-xxl-8 d-flex pt-3"},YM={class:"row gy-1 gy-xl-3 gx-md-5 items-wrapper"},KM={class:"col-12 col-sm-6 item-container"},GM={__name:"InfoPie",props:{items:Array},setup(e){const t=e;uu.register(sM,hM,sl);const n={responsive:!0,maintainAspectRatio:!1,animation:!1,plugins:{tooltip:{callbacks:{label:(a,s)=>" "+Math.round(a.parsed)+"% "}}}},i=w(()=>{const a={labels:[],datasets:[{data:[],backgroundColor:[]}]},s=t.items.reduce((l,r)=>{const c=r.locales.title,u=r.value;return a.labels.push(c),l+u},0),o=a.datasets[0];return t.items.forEach((l,r)=>{const c=l.value,u=Math.round(c*100/s);o.data.push(u),o.backgroundColor.push(l.customColor)}),a});return(a,s)=>(me(),Te("div",HM,[be("div",jM,[be("div",WM,[h(Je(zM),{class:"chart",data:i.value,options:n},null,8,["data"])])]),be("div",UM,[be("div",YM,[(me(!0),Te(Pe,null,At(t.items,o=>(me(),Te("div",KM,[h(bh,{item:o,"highlighted-header":!1,"small-description":!0,"description-with-progress-bar":!1,"icon-color-style":"customColor"},null,8,["item"])]))),256))])])]))}},XM=at(GM,[["__scopeId","data-v-437f703f"]]);const qM={class:"info-row row gx-4 gx-xl-5"},ZM={class:"col-12 subcategory-col"},JM={__name:"InfoSection",props:{sectionData:Object},setup(e){const t=e,n=Oi(),i=To(),a=Ba(),s={grid:tV,pie:XM,list:Hm,fallback:Hm},o=i.getStylePreferencesForPlugins(),l=c=>{const u=c.type;return s[u]||s.fallback},r=c=>{const u=t.sectionData.content.items[c.id];let d=0;for(const f of u)if(f.customColor=o.colors.random[d],d++,c.progress){const v=f.value,m=c.progress,g=a.parsePercentage(v,m);f.formattedPercentage=typeof m!="string"?n.getString(g):g}return u};return(c,u)=>(me(),Tt(yo,{"section-data":t.sectionData},{default:ie(()=>[be("div",qM,[(me(!0),Te(Pe,null,At(t.sectionData.content.subcategories.filter(d=>d.id==="abilities"),d=>(me(),Te("div",ZM,[d.locales.title?(me(),Tt(Ub,{key:0,title:d.locales.title,"fa-icon":d.faIcon},null,8,["title","fa-icon"])):kt("",!0),(me(),Tt(qc(l(d)),{items:r(d)},null,8,["items"]))]))),256))])]),_:1},8,["section-data"]))}},QM=at(JM,[["__scopeId","data-v-15744d8c"]]);const eE={class:"tags"},tE=["innerHTML"],nE={__name:"Tags",props:{items:Array,itemClass:String},setup(e){const t=e,n=w(()=>t.itemClass?t.itemClass:"bg-light text-dark");return(i,a)=>(me(),Te("div",eE,[(me(!0),Te(Pe,null,At(t.items,s=>(me(),Te("div",{class:xt(["tag badge text-1",n.value])},[s.faIcon?(me(),Te("i",{key:0,class:xt([s.faIcon,"me-2"])},null,2)):kt("",!0),be("span",{innerHTML:s.label||s},null,8,tE)],2))),256))]))}},A_=at(nE,[["__scopeId","data-v-233bbf6e"]]);const T_=e=>(Oa("data-v-85240ad3"),e=e(),Ra(),e),iE={class:"thread"},aE={class:"thread-item"},sE=T_(()=>be("span",{class:"fa fa-stack thread-icon"},[be("i",{class:"fa fa-circle fa-stack-1x"})],-1)),oE={class:"thread-item-content"},lE={class:"thread-item-title fw-bold pt-1 mb-1"},rE=["innerHTML"],cE=T_(()=>be("li",{class:"thread-item thread-item-end"},[be("span",{class:"fa fa-stack thread-icon thread-icon-small"},[be("i",{class:"fa fa-circle fa-stack-1x"})])],-1)),uE={__name:"Thread",props:{items:Array,linkLabel:String},setup(e){const t=e,n=ir(),i=Ba(),a=w(()=>i.reverseArray(t.items)),s=o=>{const l=o.place;return[{faIcon:"fa fa-calendar-check",label:i.localizeDate(o.date,n.getSelectedLanguage().id)},{faIcon:l.faIcon?l.faIcon:"fa fa-building",label:l.locales?l.locales.name:l}]};return(o,l)=>(me(),Te("ul",iE,[(me(!0),Te(Pe,null,At(a.value,r=>(me(),Te("li",aE,[sE,be("div",oE,[be("h6",lE,wt(r.locales.title),1),h(A_,{items:s(r),class:"mt-1 mb-2 mt-lg-2"},null,8,["items"]),be("p",{innerHTML:r.locales.description,class:"thread-item-description text-3 text-normal mb-1 mb-md-2"},null,8,rE)])]))),256)),cE]))}},dE=at(uE,[["__scopeId","data-v-85240ad3"]]);const fE={class:"row g-4 g-lg-5"},hE={class:"col-12 col-xxl-6 thread-container"},vE={__name:"ThreadsSection",props:{sectionData:Object},setup(e){const t=e;return(n,i)=>(me(),Tt(yo,{"section-data":t.sectionData},{default:ie(()=>[be("div",fE,[(me(!0),Te(Pe,null,At(t.sectionData.content.subcategories,a=>(me(),Te("div",hE,[h(Ub,{title:a.locales.title,"fa-icon":a.faIcon},null,8,["title","fa-icon"]),h(dE,{items:t.sectionData.content.items[a.id],"link-label":a.locales.buttonLabel},null,8,["items","link-label"])]))),256))])]),_:1},8,["section-data"]))}},mE=at(vE,[["__scopeId","data-v-09ad8a41"]]);const M_=e=>(Oa("data-v-5ab2d325"),e=e(),Ra(),e),gE={class:"timeline"},pE={class:"timeline-item"},yE={class:"timeline-item-content"},bE={class:"timeline-item-content-header"},_E={class:"flex-column-title"},xE=["innerHTML"],SE={class:"timeline-item-subtitle text-light-6 text-3"},wE=M_(()=>be("i",{class:"fa-solid fa-building me-2 ms-2"},null,-1)),kE={class:"flex-column-date"},CE={class:"timeline-item-content-body mt-3"},PE=["innerHTML"],IE=M_(()=>be("li",{class:"timeline-item timeline-item-tail"},[be("div",{class:"timeline-item-logo"})],-1)),VE={__name:"TimelineSection",props:{sectionData:Object},setup(e){const t=ir(),n=Ba(),i=e,a=w(()=>n.reverseArray(i.sectionData.content.items)),s=o=>{const l=o.period,r=n.localizeDate(l[0],t.getSelectedLanguage().id),c=n.localizeDate(l[1],t.getSelectedLanguage().id);return[{faIcon:"fa fa-calendar-check",label:r+' '+c}]};return(o,l)=>(me(),Tt(yo,{"section-data":i.sectionData},{default:ie(()=>[be("ul",gE,[(me(!0),Te(Pe,null,At(a.value,r=>(me(),Te("li",pE,[be("div",{class:xt(["timeline-item-logo",{"timeline-item-logo-bg-primary":!(r.place&&r.place.logoUrl)}])},[be("i",{class:xt(["timeline-item-fa-icon","fa-solid"])})],2),be("div",yE,[be("div",bE,[be("div",_E,[be("h4",{class:"timeline-item-title fw-bold",innerHTML:r.locales.title},null,8,xE),be("h6",SE,[wE,be("span",null,wt(r.place?r.place:""),1)])]),be("div",kE,[h(A_,{items:s(r),class:"mt-1 me-1"},null,8,["items"])])]),be("div",CE,[be("p",{class:"text-3 text-normal",innerHTML:r.locales.description},null,8,PE)])])]))),256)),IE])]),_:1},8,["section-data"]))}},AE=at(VE,[["__scopeId","data-v-5ab2d325"]]);const TE={class:"resume"},ME={class:"sidebar-column"},EE={class:"content-column"},DE={class:"nav-tabs-column"},OE={__name:"RouterView",setup(e){const t=Oi(),n=Na(),i=To(),a=ir(),s=_P(),o=ph(),l={},r={DefaultSection:yo,CoverSection:PI,InfoSection:QM,ThreadsSection:mE,TimelineSection:AE},c=m=>r[m]?r[m]:yo;_t(()=>{window.addEventListener("resize",u),window.addEventListener("scroll",u),_e(()=>s.name,()=>{u()}),_e(()=>a.getSelectedLanguage(),()=>{d()}),u(),n.isAllAtOnceMode()&&i.smoothScrollToElement(s.name,!0)}),Ms(()=>{window.removeEventListener("resize",u),window.removeEventListener("scroll",u)});const u=()=>{n.update(s.name)},d=()=>{const m=n.getActiveSectionId();n.isAllAtOnceMode()&&(i.instantScrollTo(window.scrollY-100,!0),i.smoothScrollToElement(m,!0))},f=m=>{if(n.registerSectionVisit(m),n.isAllAtOnceMode()){i.smoothScrollToElement(m,!1);return}const g=s.name;l[g]=window.scrollY,o.push({name:m}),n.update(g),i.instantScrollTo(l[m]??0,!0)},v=m=>{const g=n.getLastVisitedSectionOn(m);f(g)};return(m,g)=>(me(),Te("div",TE,[be("div",ME,[h(jP,{onLinkClicked:f})]),be("div",EE,[h(QP,{onLinkClicked:f}),(me(!0),Te(Pe,null,At(Je(t).getSections(),p=>(me(),Tt(qc(c(p.component)),{"section-data":p},null,8,["section-data"]))),256))]),be("div",DE,[h(sI,{onLinkClicked:v})])]))}},Jg=at(OE,[["__scopeId","data-v-77f976fb"]]);const RE={name:"App",data(){return{email:"",password:"",confirmPassword:"",isRegister:!1,errorMessage:"",stateObj:{register:{name:"Register",message:"Already have an Account? Login."},login:{name:"Login",message:"Register"}},rules:{emailRules:[e=>!!e||"E-mail is required",e=>/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|.(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/i.test(e)||"Must be a valid e-mail"]}}},methods:{validateEmailFormat(){for(let e of this.rules.emailRules){const t=e(this.email);if(t!==!0)return this.errorMessage=t,!1}return!0},login(){const e={email:this.email,password:this.password};this.validateEmailFormat()&&fetch("https://res-a-me-api.resilientdb.com/login",{method:"POST",body:JSON.stringify(e),headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*"},credentials:"include"}).then(t=>t.json()).then(async t=>{if(t.status===200){console.log("Login successful"),console.log(t),sessionStorage.setItem("access_token",t.access_token),sessionStorage.setItem("refresh_token",t.refresh_token);try{const i=await(await fetch("https://res-a-me-api.resilientdb.com/updateResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8"},body:JSON.stringify({email:this.email})})).json();i.status!==200&&console.error("Error fetching user resume: ",i.message),this.$router.push({path:"/home"}).then(()=>window.location.reload(!0))}catch(n){console.error("Error fetching user resume: ",n)}}else this.errorMessage="Login failed. Please try again."}).catch(t=>{console.error("There was an error!",t),this.errorMessage=t.message||"An error occurred. Please try again."})},register(){if(this.password===this.confirmPassword){const e={email:this.email,password:this.password};fetch("https://res-a-me-api.resilientdb.com/register",{method:"POST",headers:{"Content-Type":"application/json; charset=UTF-8"},body:JSON.stringify(e)}).then(t=>{if(!t.ok)throw new Error("Network response was not ok");return t.json()}).then(t=>{t.message==="Register successful"?(console.log("Registration successful"),sessionStorage.setItem("access_token",t.access_token),sessionStorage.setItem("refresh_token",t.refresh_token),this.$router.push("/edit")):this.errorMessage=t.message||"Registration failed. Please try again."}).catch(t=>{console.error("Registration error:",t),this.errorMessage=t.message||"An error occurred during registration."}),this.isRegister=!1,this.$refs.form.reset()}else this.errorMessage="Passwords did not match"}},computed:{toggleMessage:function(){return this.isRegister?this.stateObj.register.message:this.stateObj.login.message}}},LE={class:"red--text"};function BE(e,t,n,i,a,s){const o=we("v-col"),l=we("v-row"),r=we("v-img"),c=we("v-toolbar-title"),u=we("v-toolbar"),d=we("v-text-field"),f=we("v-btn"),v=we("v-card-text"),m=we("v-card"),g=we("v-container"),p=we("v-main"),y=we("v-app");return me(),Tt(y,{class:"background-image"},{default:ie(()=>[h(p,null,{default:ie(()=>[h(g,{"fill-height":""},{default:ie(()=>[h(l,{justify:"center",align:"center"},{default:ie(()=>[h(o,{cols:"12",sm:"8",md:"4"},{default:ie(()=>[(me(),Te(Pe,null,At(11,b=>h(l,{key:"row-"+b,justify:"center",align:"center"},{default:ie(()=>[(me(),Te(Pe,null,At(3,S=>h(o,{key:S,justify:"center",align:"center"})),64))]),_:2},1024)),64)),h(r,{class:"my-image",src:"images/background/icon.png"})]),_:1}),(me(),Te(Pe,null,At(1,b=>h(o,{key:"col-"+b,justify:"center",align:"center"})),64)),h(o,{cols:"12",sm:"8",md:"4"},{default:ie(()=>[(me(),Te(Pe,null,At(11,b=>h(l,{key:"row-"+b,justify:"center",align:"center"},{default:ie(()=>[(me(),Te(Pe,null,At(3,S=>h(o,{key:S,justify:"center",align:"center"})),64))]),_:2},1024)),64)),h(m,{class:"elevation-12"},{default:ie(()=>[h(u,{class:"toolbar-banner"},{default:ie(()=>[h(c,{class:"toolbar-title"},{default:ie(()=>[Xe(wt(a.isRegister?a.stateObj.register.name+" for ":a.stateObj.login.name+" to ")+" Res-a-Me",1)]),_:1})]),_:1}),h(v,null,{default:ie(()=>[be("form",{ref:"form",onSubmit:t[4]||(t[4]=El(b=>a.isRegister?s.register():s.login(),["prevent"]))},[h(d,{modelValue:a.email,"onUpdate:modelValue":t[0]||(t[0]=b=>a.email=b),rules:[a.rules.emailRules],label:"email",required:""},null,8,["modelValue","rules"]),h(d,{modelValue:a.password,"onUpdate:modelValue":t[1]||(t[1]=b=>a.password=b),label:"Password",type:"password",required:""},null,8,["modelValue"]),a.isRegister?(me(),Tt(d,{key:0,modelValue:a.confirmPassword,"onUpdate:modelValue":t[2]||(t[2]=b=>a.confirmPassword=b),label:"Confirm Password",type:"password",required:""},null,8,["modelValue"])):kt("",!0),be("div",LE,wt(a.errorMessage),1),h(f,{type:"submit",class:"mt-4 toolbar-banner",block:"",style:{color:"white"}},{default:ie(()=>[Xe(wt(a.isRegister?a.stateObj.register.name:a.stateObj.login.name),1)]),_:1}),h(l,{justify:"center"},{default:ie(()=>[h(o,{cols:"12",class:"text-center"},{default:ie(()=>[be("div",{class:"grey--text mt-4 yellow-text",onClick:t[3]||(t[3]=b=>{a.isRegister=!a.isRegister})},wt(s.toggleMessage),1)]),_:1})]),_:1})],544)]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})}const NE=at(RE,[["render",BE],["__scopeId","data-v-0813d3cc"]]);const FE={props:["skills"],setup(e,{emit:t}){return{deleteSkill:s=>{s!=-1&&t("delete-skill",s)},addNew:()=>{t("add-skill")},saveSkill:s=>{let o=!0;s.forEach((l,r)=>{(!l.title||!l.description)&&(o=!1)}),o?(alert("Your Skill information has been saved!"),t("save-skill",s)):confirm("Some fields may be incorrect. Please check!")}}}},$E=be("p",{class:"titletext",style:{"font-weight":"500"}},"Skill Set",-1),zE={class:"d-flex justify-center"};function HE(e,t,n,i,a,s){const o=we("v-icon"),l=we("v-row"),r=we("v-expansion-panel-title"),c=we("v-text-field"),u=we("v-col"),d=we("v-btn"),f=we("v-expansion-panel-text"),v=we("v-expansion-panel");return me(),Tt(v,null,{default:ie(()=>[h(r,{id:"title"},{default:ie(({expanded:m})=>[h(l,{"no-gutters":"",class:"d-flex jusitfy-start"},{default:ie(()=>[$E,h(o,{class:"ml-2",size:"xx-large",icon:"mdi-arrow-up-bold-box-outline"})]),_:1})]),_:1}),h(f,null,{default:ie(()=>[(me(!0),Te(Pe,null,At(n.skills,(m,g)=>(me(),Te("div",{key:g},[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"2"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.title,"onUpdate:modelValue":p=>m.title=p,rules:[()=>!!m.title||"This field is required"],counter:20,label:"Skill"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,{cols:"9"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.description,"onUpdate:modelValue":p=>m.description=p,rules:[()=>!!m.description||"This field is required"],counter:200,label:"Description"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,{class:"button-container"},{default:ie(()=>[h(d,{color:"red-lighten-2",onClick:p=>i.deleteSkill(g),class:"mb-4"},{default:ie(()=>[h(o,{size:"x-large",icon:"mdi-trash-can"})]),_:2},1032,["onClick"])]),_:2},1024)]),_:2},1024)]))),128)),be("div",zE,[h(d,{color:"grey-lighten-1",onClick:t[0]||(t[0]=m=>i.addNew())},{default:ie(()=>[Xe("Add more "),h(o,{size:"x-large",icon:"mdi-plus-thick"})]),_:1}),h(d,{color:"green",class:"ml-5",onClick:t[1]||(t[1]=m=>i.saveSkill(n.skills))},{default:ie(()=>[Xe("Save "),h(o,{size:"x-large",icon:"mdi-content-save"})]),_:1})])]),_:1})]),_:1})}const jE=at(FE,[["render",HE]]);var WE=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function UE(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function i(){return this instanceof i?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(i){var a=Object.getOwnPropertyDescriptor(e,i);Object.defineProperty(n,i,a.get?a:{enumerable:!0,get:function(){return e[i]}})}),n}var E_={};const YE=UE(vC);var D_={exports:{}};/*! * Cropper.js v1.6.1 * https://fengyuanchen.github.io/cropperjs * @@ -28,7 +28,7 @@ var rw=Object.defineProperty;var cw=(e,t,n)=>t in e?rw(e,t,{enumerable:!0,config * * Date: 2023-09-17T03:44:19.860Z */(function(e,t){(function(n,i){e.exports=i()})(WE,function(){function n(L,k){var T=Object.keys(L);if(Object.getOwnPropertySymbols){var A=Object.getOwnPropertySymbols(L);k&&(A=A.filter(function(H){return Object.getOwnPropertyDescriptor(L,H).enumerable})),T.push.apply(T,A)}return T}function i(L){for(var k=1;kL.length)&&(k=L.length);for(var T=0,A=new Array(k);T
',gr=Number.isNaN||b.isNaN;function ze(L){return typeof L=="number"&&!gr(L)}var $n=function(k){return k>0&&k<1/0};function $s(L){return typeof L>"u"}function Ua(L){return a(L)==="object"&&L!==null}var RS=Object.prototype.hasOwnProperty;function zs(L){if(!Ua(L))return!1;try{var k=L.constructor,T=k.prototype;return k&&T&&RS.call(T,"isPrototypeOf")}catch{return!1}}function Tn(L){return typeof L=="function"}var LS=Array.prototype.slice;function wv(L){return Array.from?Array.from(L):LS.call(L)}function Gt(L,k){return L&&Tn(k)&&(Array.isArray(L)||ze(L.length)?wv(L).forEach(function(T,A){k.call(L,T,A,L)}):Ua(L)&&Object.keys(L).forEach(function(T){k.call(L,L[T],T,L)})),L}var It=Object.assign||function(k){for(var T=arguments.length,A=new Array(T>1?T-1:0),H=1;H0&&A.forEach(function($){Ua($)&&Object.keys($).forEach(function(z){k[z]=$[z]})}),k},BS=/\.\d*(?:0|9){12}\d*$/;function Hs(L){var k=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1e11;return BS.test(L)?Math.round(L*k)/k:L}var NS=/^width|height|left|top|marginLeft|marginTop$/;function la(L,k){var T=L.style;Gt(k,function(A,H){NS.test(H)&&ze(A)&&(A="".concat(A,"px")),T[H]=A})}function FS(L,k){return L.classList?L.classList.contains(k):L.className.indexOf(k)>-1}function on(L,k){if(k){if(ze(L.length)){Gt(L,function(A){on(A,k)});return}if(L.classList){L.classList.add(k);return}var T=L.className.trim();T?T.indexOf(k)<0&&(L.className="".concat(T," ").concat(k)):L.className=k}}function xi(L,k){if(k){if(ze(L.length)){Gt(L,function(T){xi(T,k)});return}if(L.classList){L.classList.remove(k);return}L.className.indexOf(k)>=0&&(L.className=L.className.replace(k,""))}}function js(L,k,T){if(k){if(ze(L.length)){Gt(L,function(A){js(A,k,T)});return}T?on(L,k):xi(L,k)}}var $S=/([a-z\d])([A-Z])/g;function Uu(L){return L.replace($S,"$1-$2").toLowerCase()}function Yu(L,k){return Ua(L[k])?L[k]:L.dataset?L.dataset[k]:L.getAttribute("data-".concat(Uu(k)))}function zo(L,k,T){Ua(T)?L[k]=T:L.dataset?L.dataset[k]=T:L.setAttribute("data-".concat(Uu(k)),T)}function zS(L,k){if(Ua(L[k]))try{delete L[k]}catch{L[k]=void 0}else if(L.dataset)try{delete L.dataset[k]}catch{L.dataset[k]=void 0}else L.removeAttribute("data-".concat(Uu(k)))}var kv=/\s\s*/,Cv=function(){var L=!1;if(y){var k=!1,T=function(){},A=Object.defineProperty({},"once",{get:function(){return L=!0,k},set:function($){k=$}});b.addEventListener("test",T,A),b.removeEventListener("test",T,A)}return L}();function di(L,k,T){var A=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},H=T;k.trim().split(kv).forEach(function($){if(!Cv){var z=L.listeners;z&&z[$]&&z[$][T]&&(H=z[$][T],delete z[$][T],Object.keys(z[$]).length===0&&delete z[$],Object.keys(z).length===0&&delete L.listeners)}L.removeEventListener($,H,A)})}function Jn(L,k,T){var A=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},H=T;k.trim().split(kv).forEach(function($){if(A.once&&!Cv){var z=L.listeners,re=z===void 0?{}:z;H=function(){delete re[$][T],L.removeEventListener($,H,A);for(var ye=arguments.length,ue=new Array(ye),de=0;deMath.abs(T)&&(T=Ce)})}),T}function pr(L,k){var T=L.pageX,A=L.pageY,H={endX:T,endY:A};return k?H:i({startX:T,startY:A},H)}function WS(L){var k=0,T=0,A=0;return Gt(L,function(H){var $=H.startX,z=H.startY;k+=$,T+=z,A+=1}),k/=A,T/=A,{pageX:k,pageY:T}}function ra(L){var k=L.aspectRatio,T=L.height,A=L.width,H=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"contain",$=$n(A),z=$n(T);if($&&z){var re=T*k;H==="contain"&&re>A||H==="cover"&&re90?{width:Ae,height:re}:{width:re,height:Ae}}function YS(L,k,T,A){var H=k.aspectRatio,$=k.naturalWidth,z=k.naturalHeight,re=k.rotate,Ae=re===void 0?0:re,ye=k.scaleX,ue=ye===void 0?1:ye,de=k.scaleY,Ce=de===void 0?1:de,nt=T.aspectRatio,et=T.naturalWidth,Vt=T.naturalHeight,ct=A.fillColor,en=ct===void 0?"transparent":ct,ln=A.imageSmoothingEnabled,Xt=ln===void 0?!0:ln,Bi=A.imageSmoothingQuality,zn=Bi===void 0?"low":Bi,De=A.maxWidth,ut=De===void 0?1/0:De,tn=A.maxHeight,Qn=tn===void 0?1/0:tn,Ni=A.minWidth,Ya=Ni===void 0?0:Ni,Ka=A.minHeight,ca=Ka===void 0?0:Ka,Si=document.createElement("canvas"),Mn=Si.getContext("2d"),Ga=ra({aspectRatio:nt,width:ut,height:Qn}),yr=ra({aspectRatio:nt,width:Ya,height:ca},"cover"),Gu=Math.min(Ga.width,Math.max(yr.width,et)),Xu=Math.min(Ga.height,Math.max(yr.height,Vt)),Mv=ra({aspectRatio:H,width:ut,height:Qn}),Ev=ra({aspectRatio:H,width:Ya,height:ca},"cover"),Dv=Math.min(Mv.width,Math.max(Ev.width,$)),Ov=Math.min(Mv.height,Math.max(Ev.height,z)),ow=[-Dv/2,-Ov/2,Dv,Ov];return Si.width=Hs(Gu),Si.height=Hs(Xu),Mn.fillStyle=en,Mn.fillRect(0,0,Gu,Xu),Mn.save(),Mn.translate(Gu/2,Xu/2),Mn.rotate(Ae*Math.PI/180),Mn.scale(ue,Ce),Mn.imageSmoothingEnabled=Xt,Mn.imageSmoothingQuality=zn,Mn.drawImage.apply(Mn,[L].concat(c(ow.map(function(lw){return Math.floor(Hs(lw))})))),Mn.restore(),Si}var Av=String.fromCharCode;function KS(L,k,T){var A="";T+=k;for(var H=k;H0;)T.push(Av.apply(null,wv(H.subarray(0,A)))),H=H.subarray(A);return"data:".concat(k,";base64,").concat(btoa(T.join("")))}function ZS(L){var k=new DataView(L),T;try{var A,H,$;if(k.getUint8(0)===255&&k.getUint8(1)===216)for(var z=k.byteLength,re=2;re+1=8&&($=ye+de)}}}if($){var Ce=k.getUint16($,A),nt,et;for(et=0;et=0?$:An),height:Math.max(A.offsetHeight,z>=0?z:Li)};this.containerData=re,la(H,{width:re.width,height:re.height}),on(k,ee),xi(H,ee)},initCanvas:function(){var k=this.containerData,T=this.imageData,A=this.options.viewMode,H=Math.abs(T.rotate)%180===90,$=H?T.naturalHeight:T.naturalWidth,z=H?T.naturalWidth:T.naturalHeight,re=$/z,Ae=k.width,ye=k.height;k.height*re>k.width?A===3?Ae=k.height*re:ye=k.width/re:A===3?ye=k.width/re:Ae=k.height*re;var ue={aspectRatio:re,naturalWidth:$,naturalHeight:z,width:Ae,height:ye};this.canvasData=ue,this.limited=A===1||A===2,this.limitCanvas(!0,!0),ue.width=Math.min(Math.max(ue.width,ue.minWidth),ue.maxWidth),ue.height=Math.min(Math.max(ue.height,ue.minHeight),ue.maxHeight),ue.left=(k.width-ue.width)/2,ue.top=(k.height-ue.height)/2,ue.oldLeft=ue.left,ue.oldTop=ue.top,this.initialCanvasData=It({},ue)},limitCanvas:function(k,T){var A=this.options,H=this.containerData,$=this.canvasData,z=this.cropBoxData,re=A.viewMode,Ae=$.aspectRatio,ye=this.cropped&&z;if(k){var ue=Number(A.minCanvasWidth)||0,de=Number(A.minCanvasHeight)||0;re>1?(ue=Math.max(ue,H.width),de=Math.max(de,H.height),re===3&&(de*Ae>ue?ue=de*Ae:de=ue/Ae)):re>0&&(ue?ue=Math.max(ue,ye?z.width:0):de?de=Math.max(de,ye?z.height:0):ye&&(ue=z.width,de=z.height,de*Ae>ue?ue=de*Ae:de=ue/Ae));var Ce=ra({aspectRatio:Ae,width:ue,height:de});ue=Ce.width,de=Ce.height,$.minWidth=ue,$.minHeight=de,$.maxWidth=1/0,$.maxHeight=1/0}if(T)if(re>(ye?0:1)){var nt=H.width-$.width,et=H.height-$.height;$.minLeft=Math.min(0,nt),$.minTop=Math.min(0,et),$.maxLeft=Math.max(0,nt),$.maxTop=Math.max(0,et),ye&&this.limited&&($.minLeft=Math.min(z.left,z.left+(z.width-$.width)),$.minTop=Math.min(z.top,z.top+(z.height-$.height)),$.maxLeft=z.left,$.maxTop=z.top,re===2&&($.width>=H.width&&($.minLeft=Math.min(0,nt),$.maxLeft=Math.max(0,nt)),$.height>=H.height&&($.minTop=Math.min(0,et),$.maxTop=Math.max(0,et))))}else $.minLeft=-$.width,$.minTop=-$.height,$.maxLeft=H.width,$.maxTop=H.height},renderCanvas:function(k,T){var A=this.canvasData,H=this.imageData;if(T){var $=US({width:H.naturalWidth*Math.abs(H.scaleX||1),height:H.naturalHeight*Math.abs(H.scaleY||1),degree:H.rotate||0}),z=$.width,re=$.height,Ae=A.width*(z/A.naturalWidth),ye=A.height*(re/A.naturalHeight);A.left-=(Ae-A.width)/2,A.top-=(ye-A.height)/2,A.width=Ae,A.height=ye,A.aspectRatio=z/re,A.naturalWidth=z,A.naturalHeight=re,this.limitCanvas(!0,!1)}(A.width>A.maxWidth||A.widthA.maxHeight||A.heightT.width?$.height=$.width/A:$.width=$.height*A),this.cropBoxData=$,this.limitCropBox(!0,!0),$.width=Math.min(Math.max($.width,$.minWidth),$.maxWidth),$.height=Math.min(Math.max($.height,$.minHeight),$.maxHeight),$.width=Math.max($.minWidth,$.width*H),$.height=Math.max($.minHeight,$.height*H),$.left=T.left+(T.width-$.width)/2,$.top=T.top+(T.height-$.height)/2,$.oldLeft=$.left,$.oldTop=$.top,this.initialCropBoxData=It({},$)},limitCropBox:function(k,T){var A=this.options,H=this.containerData,$=this.canvasData,z=this.cropBoxData,re=this.limited,Ae=A.aspectRatio;if(k){var ye=Number(A.minCropBoxWidth)||0,ue=Number(A.minCropBoxHeight)||0,de=re?Math.min(H.width,$.width,$.width+$.left,H.width-$.left):H.width,Ce=re?Math.min(H.height,$.height,$.height+$.top,H.height-$.top):H.height;ye=Math.min(ye,H.width),ue=Math.min(ue,H.height),Ae&&(ye&&ue?ue*Ae>ye?ue=ye/Ae:ye=ue*Ae:ye?ue=ye/Ae:ue&&(ye=ue*Ae),Ce*Ae>de?Ce=de/Ae:de=Ce*Ae),z.minWidth=Math.min(ye,de),z.minHeight=Math.min(ue,Ce),z.maxWidth=de,z.maxHeight=Ce}T&&(re?(z.minLeft=Math.max(0,$.left),z.minTop=Math.max(0,$.top),z.maxLeft=Math.min(H.width,$.left+$.width)-z.width,z.maxTop=Math.min(H.height,$.top+$.height)-z.height):(z.minLeft=0,z.minTop=0,z.maxLeft=H.width-z.width,z.maxTop=H.height-z.height))},renderCropBox:function(){var k=this.options,T=this.containerData,A=this.cropBoxData;(A.width>A.maxWidth||A.widthA.maxHeight||A.height=T.width&&A.height>=T.height?V:P),la(this.cropBox,It({width:A.width,height:A.height},Ho({translateX:A.left,translateY:A.top}))),this.cropped&&this.limited&&this.limitCanvas(!0,!0),this.disabled||this.output()},output:function(){this.preview(),Ws(this.element,X,this.getData())}},ew={initPreview:function(){var k=this.element,T=this.crossOrigin,A=this.options.preview,H=T?this.crossOriginUrl:this.url,$=k.alt||"The image to preview",z=document.createElement("img");if(T&&(z.crossOrigin=T),z.src=H,z.alt=$,this.viewBox.appendChild(z),this.viewBoxImage=z,!!A){var re=A;typeof A=="string"?re=k.ownerDocument.querySelectorAll(A):A.querySelector&&(re=[A]),this.previews=re,Gt(re,function(Ae){var ye=document.createElement("img");zo(Ae,te,{width:Ae.offsetWidth,height:Ae.offsetHeight,html:Ae.innerHTML}),T&&(ye.crossOrigin=T),ye.src=H,ye.alt=$,ye.style.cssText='display:block;width:100%;height:auto;min-width:0!important;min-height:0!important;max-width:none!important;max-height:none!important;image-orientation:0deg!important;"',Ae.innerHTML="",Ae.appendChild(ye)})}},resetPreview:function(){Gt(this.previews,function(k){var T=Yu(k,te);la(k,{width:T.width,height:T.height}),k.innerHTML=T.html,zS(k,te)})},preview:function(){var k=this.imageData,T=this.canvasData,A=this.cropBoxData,H=A.width,$=A.height,z=k.width,re=k.height,Ae=A.left-T.left-k.left,ye=A.top-T.top-k.top;!this.cropped||this.disabled||(la(this.viewBoxImage,It({width:z,height:re},Ho(It({translateX:-Ae,translateY:-ye},k)))),Gt(this.previews,function(ue){var de=Yu(ue,te),Ce=de.width,nt=de.height,et=Ce,Vt=nt,ct=1;H&&(ct=Ce/H,Vt=$*ct),$&&Vt>nt&&(ct=nt/$,et=H*ct,Vt=nt),la(ue,{width:et,height:Vt}),la(ue.getElementsByTagName("img")[0],It({width:z*ct,height:re*ct},Ho(It({translateX:-Ae*ct,translateY:-ye*ct},k))))}))}},tw={bind:function(){var k=this.element,T=this.options,A=this.cropper;Tn(T.cropstart)&&Jn(k,R,T.cropstart),Tn(T.cropmove)&&Jn(k,E,T.cropmove),Tn(T.cropend)&&Jn(k,Ie,T.cropend),Tn(T.crop)&&Jn(k,X,T.crop),Tn(T.zoom)&&Jn(k,Fe,T.zoom),Jn(A,ke,this.onCropStart=this.cropStart.bind(this)),T.zoomable&&T.zoomOnWheel&&Jn(A,Le,this.onWheel=this.wheel.bind(this),{passive:!1,capture:!0}),T.toggleDragModeOnDblclick&&Jn(A,F,this.onDblclick=this.dblclick.bind(this)),Jn(k.ownerDocument,xe,this.onCropMove=this.cropMove.bind(this)),Jn(k.ownerDocument,Ve,this.onCropEnd=this.cropEnd.bind(this)),T.responsive&&Jn(window,Ne,this.onResize=this.resize.bind(this))},unbind:function(){var k=this.element,T=this.options,A=this.cropper;Tn(T.cropstart)&&di(k,R,T.cropstart),Tn(T.cropmove)&&di(k,E,T.cropmove),Tn(T.cropend)&&di(k,Ie,T.cropend),Tn(T.crop)&&di(k,X,T.crop),Tn(T.zoom)&&di(k,Fe,T.zoom),di(A,ke,this.onCropStart),T.zoomable&&T.zoomOnWheel&&di(A,Le,this.onWheel,{passive:!1,capture:!0}),T.toggleDragModeOnDblclick&&di(A,F,this.onDblclick),di(k.ownerDocument,xe,this.onCropMove),di(k.ownerDocument,Ve,this.onCropEnd),T.responsive&&di(window,Ne,this.onResize)}},nw={resize:function(){if(!this.disabled){var k=this.options,T=this.container,A=this.containerData,H=T.offsetWidth/A.width,$=T.offsetHeight/A.height,z=Math.abs(H-1)>Math.abs($-1)?H:$;if(z!==1){var re,Ae;k.restore&&(re=this.getCanvasData(),Ae=this.getCropBoxData()),this.render(),k.restore&&(this.setCanvasData(Gt(re,function(ye,ue){re[ue]=ye*z})),this.setCropBoxData(Gt(Ae,function(ye,ue){Ae[ue]=ye*z})))}}},dblclick:function(){this.disabled||this.options.dragMode===ae||this.setDragMode(FS(this.dragBox,B)?Q:U)},wheel:function(k){var T=this,A=Number(this.options.wheelZoomRatio)||.1,H=1;this.disabled||(k.preventDefault(),!this.wheeling&&(this.wheeling=!0,setTimeout(function(){T.wheeling=!1},50),k.deltaY?H=k.deltaY>0?1:-1:k.wheelDelta?H=-k.wheelDelta/120:k.detail&&(H=k.detail>0?1:-1),this.zoom(-H*A,k)))},cropStart:function(k){var T=k.buttons,A=k.button;if(!(this.disabled||(k.type==="mousedown"||k.type==="pointerdown"&&k.pointerType==="mouse")&&(ze(T)&&T!==1||ze(A)&&A!==0||k.ctrlKey))){var H=this.options,$=this.pointers,z;k.changedTouches?Gt(k.changedTouches,function(re){$[re.identifier]=pr(re)}):$[k.pointerId||0]=pr(k),Object.keys($).length>1&&H.zoomable&&H.zoomOnTouch?z=I:z=Yu(k.target,Oe),qe.test(z)&&Ws(this.element,R,{originalEvent:k,action:z})!==!1&&(k.preventDefault(),this.action=z,this.cropping=!1,z===C&&(this.cropping=!0,on(this.dragBox,ge)))}},cropMove:function(k){var T=this.action;if(!(this.disabled||!T)){var A=this.pointers;k.preventDefault(),Ws(this.element,E,{originalEvent:k,action:T})!==!1&&(k.changedTouches?Gt(k.changedTouches,function(H){It(A[H.identifier]||{},pr(H,!0))}):It(A[k.pointerId||0]||{},pr(k,!0)),this.change(k))}},cropEnd:function(k){if(!this.disabled){var T=this.action,A=this.pointers;k.changedTouches?Gt(k.changedTouches,function(H){delete A[H.identifier]}):delete A[k.pointerId||0],T&&(k.preventDefault(),Object.keys(A).length||(this.action=""),this.cropping&&(this.cropping=!1,js(this.dragBox,ge,this.cropped&&this.options.modal)),Ws(this.element,Ie,{originalEvent:k,action:T}))}}},iw={change:function(k){var T=this.options,A=this.canvasData,H=this.containerData,$=this.cropBoxData,z=this.pointers,re=this.action,Ae=T.aspectRatio,ye=$.left,ue=$.top,de=$.width,Ce=$.height,nt=ye+de,et=ue+Ce,Vt=0,ct=0,en=H.width,ln=H.height,Xt=!0,Bi;!Ae&&k.shiftKey&&(Ae=de&&Ce?de/Ce:1),this.limited&&(Vt=$.minLeft,ct=$.minTop,en=Vt+Math.min(H.width,A.width,A.left+A.width),ln=ct+Math.min(H.height,A.height,A.top+A.height));var zn=z[Object.keys(z)[0]],De={x:zn.endX-zn.startX,y:zn.endY-zn.startY},ut=function(Qn){switch(Qn){case M:nt+De.x>en&&(De.x=en-nt);break;case O:ye+De.xln&&(De.y=ln-et);break}};switch(re){case P:ye+=De.x,ue+=De.y;break;case M:if(De.x>=0&&(nt>=en||Ae&&(ue<=ct||et>=ln))){Xt=!1;break}ut(M),de+=De.x,de<0&&(re=O,de=-de,ye-=de),Ae&&(Ce=de/Ae,ue+=($.height-Ce)/2);break;case N:if(De.y<=0&&(ue<=ct||Ae&&(ye<=Vt||nt>=en))){Xt=!1;break}ut(N),Ce-=De.y,ue+=De.y,Ce<0&&(re=D,Ce=-Ce,ue-=Ce),Ae&&(de=Ce*Ae,ye+=($.width-de)/2);break;case O:if(De.x<=0&&(ye<=Vt||Ae&&(ue<=ct||et>=ln))){Xt=!1;break}ut(O),de-=De.x,ye+=De.x,de<0&&(re=M,de=-de,ye-=de),Ae&&(Ce=de/Ae,ue+=($.height-Ce)/2);break;case D:if(De.y>=0&&(et>=ln||Ae&&(ye<=Vt||nt>=en))){Xt=!1;break}ut(D),Ce+=De.y,Ce<0&&(re=N,Ce=-Ce,ue-=Ce),Ae&&(de=Ce*Ae,ye+=($.width-de)/2);break;case j:if(Ae){if(De.y<=0&&(ue<=ct||nt>=en)){Xt=!1;break}ut(N),Ce-=De.y,ue+=De.y,de=Ce*Ae}else ut(N),ut(M),De.x>=0?ntct&&(Ce-=De.y,ue+=De.y):(Ce-=De.y,ue+=De.y);de<0&&Ce<0?(re=J,Ce=-Ce,de=-de,ue-=Ce,ye-=de):de<0?(re=Y,de=-de,ye-=de):Ce<0&&(re=K,Ce=-Ce,ue-=Ce);break;case Y:if(Ae){if(De.y<=0&&(ue<=ct||ye<=Vt)){Xt=!1;break}ut(N),Ce-=De.y,ue+=De.y,de=Ce*Ae,ye+=$.width-de}else ut(N),ut(O),De.x<=0?ye>Vt?(de-=De.x,ye+=De.x):De.y<=0&&ue<=ct&&(Xt=!1):(de-=De.x,ye+=De.x),De.y<=0?ue>ct&&(Ce-=De.y,ue+=De.y):(Ce-=De.y,ue+=De.y);de<0&&Ce<0?(re=K,Ce=-Ce,de=-de,ue-=Ce,ye-=de):de<0?(re=j,de=-de,ye-=de):Ce<0&&(re=J,Ce=-Ce,ue-=Ce);break;case J:if(Ae){if(De.x<=0&&(ye<=Vt||et>=ln)){Xt=!1;break}ut(O),de-=De.x,ye+=De.x,Ce=de/Ae}else ut(D),ut(O),De.x<=0?ye>Vt?(de-=De.x,ye+=De.x):De.y>=0&&et>=ln&&(Xt=!1):(de-=De.x,ye+=De.x),De.y>=0?et=0&&(nt>=en||et>=ln)){Xt=!1;break}ut(M),de+=De.x,Ce=de/Ae}else ut(D),ut(M),De.x>=0?nt=0&&et>=ln&&(Xt=!1):de+=De.x,De.y>=0?et0?re=De.y>0?K:j:De.x<0&&(ye-=de,re=De.y>0?J:Y),De.y<0&&(ue-=Ce),this.cropped||(xi(this.cropBox,ee),this.cropped=!0,this.limited&&this.limitCropBox(!0,!0));break}Xt&&($.width=de,$.height=Ce,$.left=ye,$.top=ue,this.action=re,this.renderCropBox()),Gt(z,function(tn){tn.startX=tn.endX,tn.startY=tn.endY})}},aw={crop:function(){return this.ready&&!this.cropped&&!this.disabled&&(this.cropped=!0,this.limitCropBox(!0,!0),this.options.modal&&on(this.dragBox,ge),xi(this.cropBox,ee),this.setCropBoxData(this.initialCropBoxData)),this},reset:function(){return this.ready&&!this.disabled&&(this.imageData=It({},this.initialImageData),this.canvasData=It({},this.initialCanvasData),this.cropBoxData=It({},this.initialCropBoxData),this.renderCanvas(),this.cropped&&this.renderCropBox()),this},clear:function(){return this.cropped&&!this.disabled&&(It(this.cropBoxData,{left:0,top:0,width:0,height:0}),this.cropped=!1,this.renderCropBox(),this.limitCanvas(!0,!0),this.renderCanvas(),xi(this.dragBox,ge),on(this.cropBox,ee)),this},replace:function(k){var T=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return!this.disabled&&k&&(this.isImg&&(this.element.src=k),T?(this.url=k,this.image.src=k,this.ready&&(this.viewBoxImage.src=k,Gt(this.previews,function(A){A.getElementsByTagName("img")[0].src=k}))):(this.isImg&&(this.replaced=!0),this.options.data=null,this.uncreate(),this.load(k))),this},enable:function(){return this.ready&&this.disabled&&(this.disabled=!1,xi(this.cropper,G)),this},disable:function(){return this.ready&&!this.disabled&&(this.disabled=!0,on(this.cropper,G)),this},destroy:function(){var k=this.element;return k[x]?(k[x]=void 0,this.isImg&&this.replaced&&(k.src=this.originalUrl),this.uncreate(),this):this},move:function(k){var T=arguments.length>1&&arguments[1]!==void 0?arguments[1]:k,A=this.canvasData,H=A.left,$=A.top;return this.moveTo($s(k)?k:H+Number(k),$s(T)?T:$+Number(T))},moveTo:function(k){var T=arguments.length>1&&arguments[1]!==void 0?arguments[1]:k,A=this.canvasData,H=!1;return k=Number(k),T=Number(T),this.ready&&!this.disabled&&this.options.movable&&(ze(k)&&(A.left=k,H=!0),ze(T)&&(A.top=T,H=!0),H&&this.renderCanvas(!0)),this},zoom:function(k,T){var A=this.canvasData;return k=Number(k),k<0?k=1/(1-k):k=1+k,this.zoomTo(A.width*k/A.naturalWidth,null,T)},zoomTo:function(k,T,A){var H=this.options,$=this.canvasData,z=$.width,re=$.height,Ae=$.naturalWidth,ye=$.naturalHeight;if(k=Number(k),k>=0&&this.ready&&!this.disabled&&H.zoomable){var ue=Ae*k,de=ye*k;if(Ws(this.element,Fe,{ratio:k,oldRatio:z/Ae,originalEvent:A})===!1)return this;if(A){var Ce=this.pointers,nt=Pv(this.cropper),et=Ce&&Object.keys(Ce).length?WS(Ce):{pageX:A.pageX,pageY:A.pageY};$.left-=(ue-z)*((et.pageX-nt.left-$.left)/z),$.top-=(de-re)*((et.pageY-nt.top-$.top)/re)}else zs(T)&&ze(T.x)&&ze(T.y)?($.left-=(ue-z)*((T.x-$.left)/z),$.top-=(de-re)*((T.y-$.top)/re)):($.left-=(ue-z)/2,$.top-=(de-re)/2);$.width=ue,$.height=de,this.renderCanvas(!0)}return this},rotate:function(k){return this.rotateTo((this.imageData.rotate||0)+Number(k))},rotateTo:function(k){return k=Number(k),ze(k)&&this.ready&&!this.disabled&&this.options.rotatable&&(this.imageData.rotate=k%360,this.renderCanvas(!0,!0)),this},scaleX:function(k){var T=this.imageData.scaleY;return this.scale(k,ze(T)?T:1)},scaleY:function(k){var T=this.imageData.scaleX;return this.scale(ze(T)?T:1,k)},scale:function(k){var T=arguments.length>1&&arguments[1]!==void 0?arguments[1]:k,A=this.imageData,H=!1;return k=Number(k),T=Number(T),this.ready&&!this.disabled&&this.options.scalable&&(ze(k)&&(A.scaleX=k,H=!0),ze(T)&&(A.scaleY=T,H=!0),H&&this.renderCanvas(!0,!0)),this},getData:function(){var k=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,T=this.options,A=this.imageData,H=this.canvasData,$=this.cropBoxData,z;if(this.ready&&this.cropped){z={x:$.left-H.left,y:$.top-H.top,width:$.width,height:$.height};var re=A.width/A.naturalWidth;if(Gt(z,function(ue,de){z[de]=ue/re}),k){var Ae=Math.round(z.y+z.height),ye=Math.round(z.x+z.width);z.x=Math.round(z.x),z.y=Math.round(z.y),z.width=ye-z.x,z.height=Ae-z.y}}else z={x:0,y:0,width:0,height:0};return T.rotatable&&(z.rotate=A.rotate||0),T.scalable&&(z.scaleX=A.scaleX||1,z.scaleY=A.scaleY||1),z},setData:function(k){var T=this.options,A=this.imageData,H=this.canvasData,$={};if(this.ready&&!this.disabled&&zs(k)){var z=!1;T.rotatable&&ze(k.rotate)&&k.rotate!==A.rotate&&(A.rotate=k.rotate,z=!0),T.scalable&&(ze(k.scaleX)&&k.scaleX!==A.scaleX&&(A.scaleX=k.scaleX,z=!0),ze(k.scaleY)&&k.scaleY!==A.scaleY&&(A.scaleY=k.scaleY,z=!0)),z&&this.renderCanvas(!0,!0);var re=A.width/A.naturalWidth;ze(k.x)&&($.left=k.x*re+H.left),ze(k.y)&&($.top=k.y*re+H.top),ze(k.width)&&($.width=k.width*re),ze(k.height)&&($.height=k.height*re),this.setCropBoxData($)}return this},getContainerData:function(){return this.ready?It({},this.containerData):{}},getImageData:function(){return this.sized?It({},this.imageData):{}},getCanvasData:function(){var k=this.canvasData,T={};return this.ready&&Gt(["left","top","width","height","naturalWidth","naturalHeight"],function(A){T[A]=k[A]}),T},setCanvasData:function(k){var T=this.canvasData,A=T.aspectRatio;return this.ready&&!this.disabled&&zs(k)&&(ze(k.left)&&(T.left=k.left),ze(k.top)&&(T.top=k.top),ze(k.width)?(T.width=k.width,T.height=k.width/A):ze(k.height)&&(T.height=k.height,T.width=k.height*A),this.renderCanvas(!0)),this},getCropBoxData:function(){var k=this.cropBoxData,T;return this.ready&&this.cropped&&(T={left:k.left,top:k.top,width:k.width,height:k.height}),T||{}},setCropBoxData:function(k){var T=this.cropBoxData,A=this.options.aspectRatio,H,$;return this.ready&&this.cropped&&!this.disabled&&zs(k)&&(ze(k.left)&&(T.left=k.left),ze(k.top)&&(T.top=k.top),ze(k.width)&&k.width!==T.width&&(H=!0,T.width=k.width),ze(k.height)&&k.height!==T.height&&($=!0,T.height=k.height),A&&(H?T.height=T.width/A:$&&(T.width=T.height*A)),this.renderCropBox()),this},getCroppedCanvas:function(){var k=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!this.ready||!window.HTMLCanvasElement)return null;var T=this.canvasData,A=YS(this.image,this.imageData,T,k);if(!this.cropped)return A;var H=this.getData(k.rounded),$=H.x,z=H.y,re=H.width,Ae=H.height,ye=A.width/Math.floor(T.naturalWidth);ye!==1&&($*=ye,z*=ye,re*=ye,Ae*=ye);var ue=re/Ae,de=ra({aspectRatio:ue,width:k.maxWidth||1/0,height:k.maxHeight||1/0}),Ce=ra({aspectRatio:ue,width:k.minWidth||0,height:k.minHeight||0},"cover"),nt=ra({aspectRatio:ue,width:k.width||(ye!==1?A.width:re),height:k.height||(ye!==1?A.height:Ae)}),et=nt.width,Vt=nt.height;et=Math.min(de.width,Math.max(Ce.width,et)),Vt=Math.min(de.height,Math.max(Ce.height,Vt));var ct=document.createElement("canvas"),en=ct.getContext("2d");ct.width=Hs(et),ct.height=Hs(Vt),en.fillStyle=k.fillColor||"transparent",en.fillRect(0,0,et,Vt);var ln=k.imageSmoothingEnabled,Xt=ln===void 0?!0:ln,Bi=k.imageSmoothingQuality;en.imageSmoothingEnabled=Xt,Bi&&(en.imageSmoothingQuality=Bi);var zn=A.width,De=A.height,ut=$,tn=z,Qn,Ni,Ya,Ka,ca,Si;ut<=-re||ut>zn?(ut=0,Qn=0,Ya=0,ca=0):ut<=0?(Ya=-ut,ut=0,Qn=Math.min(zn,re+ut),ca=Qn):ut<=zn&&(Ya=0,Qn=Math.min(re,zn-ut),ca=Qn),Qn<=0||tn<=-Ae||tn>De?(tn=0,Ni=0,Ka=0,Si=0):tn<=0?(Ka=-tn,tn=0,Ni=Math.min(De,Ae+tn),Si=Ni):tn<=De&&(Ka=0,Ni=Math.min(Ae,De-tn),Si=Ni);var Mn=[ut,tn,Qn,Ni];if(ca>0&&Si>0){var Ga=et/re;Mn.push(Ya*Ga,Ka*Ga,ca*Ga,Si*Ga)}return en.drawImage.apply(en,[A].concat(c(Mn.map(function(yr){return Math.floor(Hs(yr))})))),ct},setAspectRatio:function(k){var T=this.options;return!this.disabled&&!$s(k)&&(T.aspectRatio=Math.max(0,k)||NaN,this.ready&&(this.initCropBox(),this.cropped&&this.renderCropBox())),this},setDragMode:function(k){var T=this.options,A=this.dragBox,H=this.face;if(this.ready&&!this.disabled){var $=k===U,z=T.movable&&k===Q;k=$||z?k:ae,T.dragMode=k,zo(A,Oe,k),js(A,B,$),js(A,Me,z),T.cropBoxMovable||(zo(H,Oe,k),js(H,B,$),js(H,Me,z))}return this}},sw=b.Cropper,Tv=function(){function L(k){var T=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(s(this,L),!k||!Bt.test(k.tagName))throw new Error("The first argument is required and must be an or element.");this.element=k,this.options=It({},$o,zs(T)&&T),this.cropped=!1,this.disabled=!1,this.pointers={},this.ready=!1,this.reloading=!1,this.replaced=!1,this.sized=!1,this.sizing=!1,this.init()}return l(L,[{key:"init",value:function(){var T=this.element,A=T.tagName.toLowerCase(),H;if(!T[x]){if(T[x]=this,A==="img"){if(this.isImg=!0,H=T.getAttribute("src")||"",this.originalUrl=H,!H)return;H=T.src}else A==="canvas"&&window.HTMLCanvasElement&&(H=T.toDataURL());this.load(H)}}},{key:"load",value:function(T){var A=this;if(T){this.url=T,this.imageData={};var H=this.element,$=this.options;if(!$.rotatable&&!$.scalable&&($.checkOrientation=!1),!$.checkOrientation||!window.ArrayBuffer){this.clone();return}if(gt.test(T)){rt.test(T)?this.read(XS(T)):this.clone();return}var z=new XMLHttpRequest,re=this.clone.bind(this);this.reloading=!0,this.xhr=z,z.onabort=re,z.onerror=re,z.ontimeout=re,z.onprogress=function(){z.getResponseHeader("content-type")!==Ue&&z.abort()},z.onload=function(){A.read(z.response)},z.onloadend=function(){A.reloading=!1,A.xhr=null},$.checkCrossOrigin&&Iv(T)&&H.crossOrigin&&(T=Vv(T)),z.open("GET",T,!0),z.responseType="arraybuffer",z.withCredentials=H.crossOrigin==="use-credentials",z.send()}}},{key:"read",value:function(T){var A=this.options,H=this.imageData,$=ZS(T),z=0,re=1,Ae=1;if($>1){this.url=qS(T,Ue);var ye=JS($);z=ye.rotate,re=ye.scaleX,Ae=ye.scaleY}A.rotatable&&(H.rotate=z),A.scalable&&(H.scaleX=re,H.scaleY=Ae),this.clone()}},{key:"clone",value:function(){var T=this.element,A=this.url,H=T.crossOrigin,$=A;this.options.checkCrossOrigin&&Iv(A)&&(H||(H="anonymous"),$=Vv(A)),this.crossOrigin=H,this.crossOriginUrl=$;var z=document.createElement("img");H&&(z.crossOrigin=H),z.src=$||A,z.alt=T.alt||"The image to crop",this.image=z,z.onload=this.start.bind(this),z.onerror=this.stop.bind(this),on(z,le),T.parentNode.insertBefore(z,T.nextSibling)}},{key:"start",value:function(){var T=this,A=this.image;A.onload=null,A.onerror=null,this.sizing=!0;var H=b.navigator&&/(?:iPad|iPhone|iPod).*?AppleWebKit/i.test(b.navigator.userAgent),$=function(ye,ue){It(T.imageData,{naturalWidth:ye,naturalHeight:ue,aspectRatio:ye/ue}),T.initialImageData=It({},T.imageData),T.sizing=!1,T.sized=!0,T.build()};if(A.naturalWidth&&!H){$(A.naturalWidth,A.naturalHeight);return}var z=document.createElement("img"),re=document.body||document.documentElement;this.sizingImage=z,z.onload=function(){$(z.width,z.height),H||re.removeChild(z)},z.src=A.src,H||(z.style.cssText="left:0;max-height:none!important;max-width:none!important;min-height:0!important;min-width:0!important;opacity:0;position:absolute;top:0;z-index:-1;",re.appendChild(z))}},{key:"stop",value:function(){var T=this.image;T.onload=null,T.onerror=null,T.parentNode.removeChild(T),this.image=null}},{key:"build",value:function(){if(!(!this.sized||this.ready)){var T=this.element,A=this.options,H=this.image,$=T.parentNode,z=document.createElement("div");z.innerHTML=Wa;var re=z.querySelector(".".concat(x,"-container")),Ae=re.querySelector(".".concat(x,"-canvas")),ye=re.querySelector(".".concat(x,"-drag-box")),ue=re.querySelector(".".concat(x,"-crop-box")),de=ue.querySelector(".".concat(x,"-face"));this.container=$,this.cropper=re,this.canvas=Ae,this.dragBox=ye,this.cropBox=ue,this.viewBox=re.querySelector(".".concat(x,"-view-box")),this.face=de,Ae.appendChild(H),on(T,ee),$.insertBefore(re,T.nextSibling),xi(H,le),this.initPreview(),this.bind(),A.initialAspectRatio=Math.max(0,A.initialAspectRatio)||NaN,A.aspectRatio=Math.max(0,A.aspectRatio)||NaN,A.viewMode=Math.max(0,Math.min(3,Math.round(A.viewMode)))||0,on(ue,ee),A.guides||on(ue.getElementsByClassName("".concat(x,"-dashed")),ee),A.center||on(ue.getElementsByClassName("".concat(x,"-center")),ee),A.background&&on(re,"".concat(x,"-bg")),A.highlight||on(de,ce),A.cropBoxMovable&&(on(de,Me),zo(de,Oe,P)),A.cropBoxResizable||(on(ue.getElementsByClassName("".concat(x,"-line")),ee),on(ue.getElementsByClassName("".concat(x,"-point")),ee)),this.render(),this.ready=!0,this.setDragMode(A.dragMode),A.autoCrop&&this.crop(),this.setData(A.data),Tn(A.ready)&&Jn(T,pe,A.ready,{once:!0}),Ws(T,pe)}}},{key:"unbuild",value:function(){if(this.ready){this.ready=!1,this.unbind(),this.resetPreview();var T=this.cropper.parentNode;T&&T.removeChild(this.cropper),xi(this.element,ee)}}},{key:"uncreate",value:function(){this.ready?(this.unbuild(),this.ready=!1,this.cropped=!1):this.sizing?(this.sizingImage.onload=null,this.sizing=!1,this.sized=!1):this.reloading?(this.xhr.onabort=null,this.xhr.abort()):this.image&&this.stop()}}],[{key:"noConflict",value:function(){return window.Cropper=sw,L}},{key:"setDefaults",value:function(T){It($o,zs(T)&&T)}}]),L}();return It(Tv.prototype,QS,ew,tw,nw,iw,aw),Tv})})(D_);var KE=D_.exports;Object.defineProperty(E_,"__esModule",{value:!0});var Qg=YE,GE=KE,XE=qE(GE);function qE(e){return e&&e.__esModule?e:{default:e}}function ZE(e,t){var n={};for(var i in e)t.indexOf(i)>=0||Object.prototype.hasOwnProperty.call(e,i)&&(n[i]=e[i]);return n}var JE=typeof window>"u"?[String,Array]:[String,Array,Element,NodeList],QE=E_.default={render:function(){var t=this.crossorigin||void 0;return(0,Qg.h)("div",{style:this.containerStyle},[(0,Qg.h)("img",{ref:"img",src:this.src,alt:this.alt||"image",style:[{"max-width":"100%"},this.imgStyle],crossorigin:t})])},props:{containerStyle:Object,src:{type:String,default:""},alt:String,imgStyle:Object,viewMode:Number,dragMode:String,initialAspectRatio:Number,aspectRatio:Number,data:Object,preview:JE,responsive:{type:Boolean,default:!0},restore:{type:Boolean,default:!0},checkCrossOrigin:{type:Boolean,default:!0},checkOrientation:{type:Boolean,default:!0},crossorigin:{type:String},modal:{type:Boolean,default:!0},guides:{type:Boolean,default:!0},center:{type:Boolean,default:!0},highlight:{type:Boolean,default:!0},background:{type:Boolean,default:!0},autoCrop:{type:Boolean,default:!0},autoCropArea:Number,movable:{type:Boolean,default:!0},rotatable:{type:Boolean,default:!0},scalable:{type:Boolean,default:!0},zoomable:{type:Boolean,default:!0},zoomOnTouch:{type:Boolean,default:!0},zoomOnWheel:{type:Boolean,default:!0},wheelZoomRatio:Number,cropBoxMovable:{type:Boolean,default:!0},cropBoxResizable:{type:Boolean,default:!0},toggleDragModeOnDblclick:{type:Boolean,default:!0},minCanvasWidth:Number,minCanvasHeight:Number,minCropBoxWidth:Number,minCropBoxHeight:Number,minContainerWidth:Number,minContainerHeight:Number,ready:Function,cropstart:Function,cropmove:Function,cropend:Function,crop:Function,zoom:Function},mounted:function(){var t=this.$options.props;t.containerStyle,t.src,t.alt,t.imgStyle;var n=ZE(t,["containerStyle","src","alt","imgStyle"]),i={};for(var a in n)this[a]!==void 0&&(i[a]=this[a]);this.cropper=new XE.default(this.$refs.img,i)},methods:{reset:function(){return this.cropper.reset()},clear:function(){return this.cropper.clear()},initCrop:function(){return this.cropper.crop()},replace:function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return this.cropper.replace(t,n)},enable:function(){return this.cropper.enable()},disable:function(){return this.cropper.disable()},destroy:function(){return this.cropper.destroy()},move:function(t,n){return this.cropper.move(t,n)},moveTo:function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:t;return this.cropper.moveTo(t,n)},relativeZoom:function(t,n){return this.cropper.zoom(t,n)},zoomTo:function(t,n){return this.cropper.zoomTo(t,n)},rotate:function(t){return this.cropper.rotate(t)},rotateTo:function(t){return this.cropper.rotateTo(t)},scaleX:function(t){return this.cropper.scaleX(t)},scaleY:function(t){return this.cropper.scaleY(t)},scale:function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:t;return this.cropper.scale(t,n)},getData:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;return this.cropper.getData(t)},setData:function(t){return this.cropper.setData(t)},getContainerData:function(){return this.cropper.getContainerData()},getImageData:function(){return this.cropper.getImageData()},getCanvasData:function(){return this.cropper.getCanvasData()},setCanvasData:function(t){return this.cropper.setCanvasData(t)},getCropBoxData:function(){return this.cropper.getCropBoxData()},setCropBoxData:function(t){return this.cropper.setCropBoxData(t)},getCroppedCanvas:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return this.cropper.getCroppedCanvas(t)},setAspectRatio:function(t){return this.cropper.setAspectRatio(t)},setDragMode:function(t){return this.cropper.setDragMode(t)}}};const eD={props:["about"],components:{VueCropper:QE},setup(e,{emit:t}){const n=Z(null),i=Z(null),a=Z(!1),s=Z(null),o=v=>{const m=v.target.files[0];m&&m.type.includes("image")?(n.value=m,i.value=URL.createObjectURL(m),a.value=!0):alert("Please select an image file.")},l=()=>{if(s.value&&s.value.cropper){const m=s.value.cropper.getCroppedCanvas(),g=n.value&&n.value.type?n.value.type:"image/png";m.toBlob(p=>{const y=URL.createObjectURL(p);i.value=y,n.value=new File([p],".png",{type:g}),a.value=!1},g)}else console.error("Cropper instance is not available")},r=()=>!!e.about.name&&e.about.name.length>=2&&e.about.name.length<=20,c=()=>!!e.about.role&&e.about.role.length>=2&&e.about.role.length<=20,u=()=>!!e.about.description&&e.about.description.length<=250;return{saveAbout:v=>{let m=!0;(!r()||!c()||!u())&&(m=!1),m?(alert("Your About information has been saved!"),t("save-about",v)):confirm("Some fields may be incorrect. Please check!")},isNameValid:r,isPositionValid:c,isDescriptionValid:u,handleFileChange:o,upload:v=>{if(!n.value){alert("Please select a file first.");return}const m=new FormData;m.append("image",n.value),fetch("https://res-a-me-api.tobywinz.com/upload",{method:"POST",headers:{Authorization:"Bearer "+sessionStorage.getItem("access_token")},body:m}).then(g=>g.json()).then(g=>{console.log("Upload successful:",g)}).catch(g=>{console.error("Upload error:",g)})},selectedFile:n,selectedImageUrl:i,cropperDialog:a,cropperRef:s,handleFileChange:o,cropImage:l}}},tD=be("p",{class:"titletext"}," About ",-1),nD={class:"d-flex justify-center"};function iD(e,t,n,i,a,s){const o=we("v-icon"),l=we("v-row"),r=we("v-expansion-panel-title"),c=we("v-text-field"),u=we("v-col"),d=we("v-btn"),f=we("v-card-title"),v=we("vue-cropper"),m=we("v-card-text"),g=we("v-spacer"),p=we("v-card-actions"),y=we("v-card"),b=we("v-dialog"),S=we("v-expansion-panel-text"),_=we("v-expansion-panel");return me(),Tt(_,null,{default:ie(()=>[h(r,{id:"title"},{default:ie(({expanded:x})=>[h(l,{"no-gutters":"",class:"d-flex jusitfy-start"},{default:ie(()=>[tD,h(o,{class:"ml-2",size:"xx-large",icon:"mdi-information-outline"})]),_:1})]),_:1}),h(S,null,{default:ie(()=>[h(l,{"no-gutters":""},{default:ie(()=>[h(u,null,{default:ie(()=>[h(c,{class:"pa-2",modelValue:n.about.name,"onUpdate:modelValue":t[0]||(t[0]=x=>n.about.name=x),rules:[()=>!!n.about.name||"This field is required",()=>i.isNameValid()||"Name must be at least 2 characters and less than 20 characters"],counter:20,label:"Name"},null,8,["modelValue","rules"])]),_:1}),h(u,null,{default:ie(()=>[h(c,{class:"pa-2",modelValue:n.about.role,"onUpdate:modelValue":t[1]||(t[1]=x=>n.about.role=x),rules:[()=>!!n.about.role||"This field is required",()=>i.isPositionValid()||"Position must be at least 2 characters and less than 20 characters"],counter:20,label:"Job Title"},null,8,["modelValue","rules"])]),_:1})]),_:1}),h(l,{"no-gutters":""},{default:ie(()=>[h(c,{class:"pa-2",modelValue:n.about.description,"onUpdate:modelValue":t[2]||(t[2]=x=>n.about.description=x),rules:[()=>!!n.about.description||"This field is required",()=>i.isDescriptionValid()||"Introduction must be less than 250 characters"],counter:250,label:"Introduction"},null,8,["modelValue","rules"])]),_:1}),be("div",nD,[be("form",{onSubmit:t[5]||(t[5]=El((...x)=>e.uploadImage&&e.uploadImage(...x),["prevent"]))},[be("input",{type:"file",onChange:t[3]||(t[3]=(...x)=>i.handleFileChange&&i.handleFileChange(...x)),accept:"image/png"},null,32),h(d,{color:"grey-lighten-1",class:"ml-5",onClick:t[4]||(t[4]=x=>i.upload(n.about))},{default:ie(()=>[Xe("Upload IMG "),h(o,{size:"x-large",icon:"mdi-upload"})]),_:1})],32),h(b,{modelValue:i.cropperDialog,"onUpdate:modelValue":t[7]||(t[7]=x=>i.cropperDialog=x),"max-width":"500px"},{default:ie(()=>[h(y,null,{default:ie(()=>[h(f,null,{default:ie(()=>[Xe("Crop Image")]),_:1}),h(m,null,{default:ie(()=>[h(v,{ref:"cropperRef",src:i.selectedImageUrl,"aspect-ratio":1,style:{width:"100%"}},null,8,["src"])]),_:1}),h(p,null,{default:ie(()=>[h(g),h(d,{color:"primary",onClick:i.cropImage},{default:ie(()=>[Xe("Crop")]),_:1},8,["onClick"]),h(d,{color:"primary",text:"",onClick:t[6]||(t[6]=x=>i.cropperDialog=!1)},{default:ie(()=>[Xe("Cancel")]),_:1})]),_:1})]),_:1})]),_:1},8,["modelValue"]),h(d,{color:"green",class:"ml-5",onClick:t[8]||(t[8]=x=>i.saveAbout(n.about))},{default:ie(()=>[Xe("Save "),h(o,{size:"x-large",icon:"mdi-content-save"})]),_:1})])]),_:1})]),_:1})}const aD=at(eD,[["render",iD]]);const sD={props:["educations"],setup(e,{emit:t}){const n=u=>!!u.schoolName,i=u=>!!u.title,a=u=>!!u.startDate&&/\b\d{4}\/(0[1-9]|1[0-2])\b/.test(u.startDate),s=u=>!!u.endDate&&/\b\d{4}\/(0[1-9]|1[0-2])\b/.test(u.endDate),o=u=>!!u.description;return{deleteEdu:u=>{u!=-1&&t("delete-edu",u)},addNewEdu:()=>{t("add-edu")},saveEdu:u=>{let d=!0;u.forEach((f,v)=>{(!n(f)||!i(f)||!a(f)||!s(f)||!o(f))&&(d=!1)}),d?(alert("Your Education information has been saved!"),t("save-edu",u)):confirm("Some fields may be incorrect. Please check!")},isSchoolnameValid:n,isDiplomaValid:i,isDescriptionValid:o,isStartDateValid:a,isEndDateValid:s}}},oD=be("p",{class:"titletext"},"Educational Background",-1),lD={class:"d-flex justify-center"};function rD(e,t,n,i,a,s){const o=we("v-icon"),l=we("v-row"),r=we("v-expansion-panel-title"),c=we("v-text-field"),u=we("v-col"),d=we("v-btn"),f=we("v-expansion-panel-text"),v=we("v-expansion-panel");return me(),Tt(v,null,{default:ie(()=>[h(r,{id:"title"},{default:ie(({expanded:m})=>[h(l,{"no-gutters":"",class:"d-flex jusitfy-start"},{default:ie(()=>[oD,h(o,{class:"ml-2",size:"xx-large",icon:"mdi-school-outline"})]),_:1})]),_:1}),h(f,null,{default:ie(()=>[(me(!0),Te(Pe,null,At(n.educations,(m,g)=>(me(),Te("div",{key:g,class:"mb-3",style:{border:"2px solid rgb(198, 194, 194)"}},[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"11"},{default:ie(()=>[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"3"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.schoolName,"onUpdate:modelValue":p=>m.schoolName=p,rules:[()=>i.isSchoolnameValid(m)||"This field is required"],counter:20,label:"School"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,{cols:"4"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.title,"onUpdate:modelValue":p=>m.title=p,rules:[()=>i.isDiplomaValid(m)||"This field is required"],counter:20,label:"Diploma"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,null,{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.startDate,"onUpdate:modelValue":p=>m.startDate=p,rules:[()=>!!m.startDate||"This field is required",()=>i.isStartDateValid(m)||"Date must be in YYYY/MM format"],counter:10,label:"Start Date"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,null,{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.endDate,"onUpdate:modelValue":p=>m.endDate=p,rules:[()=>!!m.endDate||"This field is required",()=>i.isEndDateValid(m)||"Date must be in YYYY/MM format"],counter:10,label:"End Date"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024)]),_:2},1024),h(l,{"no-gutters":""},{default:ie(()=>[h(c,{class:"pl-2 pr-2",modelValue:m.description,"onUpdate:modelValue":p=>m.description=p,rules:[()=>i.isDescriptionValid(m)||"This field is required"],counter:200,label:"Description"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024)]),_:2},1024),h(u,{class:"button-container mr-2"},{default:ie(()=>[h(d,{onClick:p=>i.deleteEdu(g),color:"red-lighten-2"},{default:ie(()=>[h(o,{size:"x-large",icon:"mdi-trash-can"})]),_:2},1032,["onClick"])]),_:2},1024)]),_:2},1024)]))),128)),be("div",lD,[h(d,{color:"grey-lighten-1",onClick:t[0]||(t[0]=m=>i.addNewEdu())},{default:ie(()=>[Xe("Add more "),h(o,{size:"x-large",icon:"mdi-plus-thick"})]),_:1}),h(d,{class:"ml-5",color:"green",onClick:t[1]||(t[1]=m=>i.saveEdu(n.educations))},{default:ie(()=>[Xe("Save "),h(o,{size:"x-large",icon:"mdi-content-save"})]),_:1})])]),_:1})]),_:1})}const cD=at(sD,[["render",rD]]);const uD={props:["professions"],setup(e,{emit:t}){const n=u=>!!u.company,i=u=>!!u.title,a=u=>!!u.startDate&&/\b\d{4}\/(0[1-9]|1[0-2])\b/.test(u.startDate),s=u=>!!u.endDate&&/\b\d{4}\/(0[1-9]|1[0-2])\b/.test(u.endDate),o=u=>!!u.description;return{deletePro:u=>{u!=-1&&t("delete-pro",u)},addNewPro:()=>{t("add-pro")},savePro:u=>{let d=!0;u.forEach((f,v)=>{(!n(f)||!i(f)||!a(f)||!s(f)||!o(f))&&(d=!1)}),d?(alert("Your Profession information has been saved!"),t("save-pro",u)):confirm("Some fields may be incorrect. Please check!")},isCompanyValid:n,isPositionValid:i,isDescriptionValid:o,isStartDateValid:a,isEndDateValid:s}}},dD=be("p",{class:"titletext"},"Professional Experience",-1),fD={class:"d-flex justify-center"};function hD(e,t,n,i,a,s){const o=we("v-icon"),l=we("v-row"),r=we("v-expansion-panel-title"),c=we("v-text-field"),u=we("v-col"),d=we("v-btn"),f=we("v-expansion-panel-text"),v=we("v-expansion-panel");return me(),Tt(v,null,{default:ie(()=>[h(r,{id:"title"},{default:ie(({expanded:m})=>[h(l,{"no-gutters":"",class:"d-flex jusitfy-start"},{default:ie(()=>[dD,h(o,{class:"ml-2",size:"xx-large",icon:"mdi-briefcase-outline"})]),_:1})]),_:1}),h(f,null,{default:ie(()=>[(me(!0),Te(Pe,null,At(n.professions,(m,g)=>(me(),Te("div",{key:g,class:"mb-3",style:{border:"2px solid rgb(198, 194, 194)"}},[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"11"},{default:ie(()=>[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"3"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.company,"onUpdate:modelValue":p=>m.company=p,rules:[()=>i.isCompanyValid(m)||"This field is required"],counter:20,label:"Company"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,{cols:"4"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.title,"onUpdate:modelValue":p=>m.title=p,rules:[()=>i.isPositionValid(m)||"This field is required"],counter:30,label:"Position"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,null,{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.startDate,"onUpdate:modelValue":p=>m.startDate=p,rules:[()=>!!m.startDate||"This field is required",()=>i.isStartDateValid(m)||"Date must be in YYYY/MM format"],counter:10,label:"Start Date"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,null,{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.endDate,"onUpdate:modelValue":p=>m.endDate=p,rules:[()=>!!m.endDate||"This field is required",()=>i.isEndDateValid(m)||"Date must be in YYYY/MM format"],counter:10,label:"End Date"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024)]),_:2},1024),h(l,{"no-gutters":""},{default:ie(()=>[h(c,{class:"pl-2 pr-2",modelValue:m.description,"onUpdate:modelValue":p=>m.description=p,rules:[()=>i.isDescriptionValid(m)||"This field is required"],counter:300,label:"Description"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024)]),_:2},1024),h(u,{class:"button-container"},{default:ie(()=>[h(d,{onClick:p=>i.deletePro(g),color:"red-lighten-2"},{default:ie(()=>[h(o,{size:"x-large",icon:"mdi-trash-can"})]),_:2},1032,["onClick"])]),_:2},1024)]),_:2},1024)]))),128)),be("div",fD,[h(d,{color:"grey-lighten-1",onClick:t[0]||(t[0]=m=>i.addNewPro())},{default:ie(()=>[Xe("Add more "),h(o,{size:"x-large",icon:"mdi-plus-thick"})]),_:1}),h(d,{class:"ml-5",color:"green",onClick:t[1]||(t[1]=m=>i.savePro(n.professions))},{default:ie(()=>[Xe("Save "),h(o,{size:"x-large",icon:"mdi-content-save"})]),_:1})])]),_:1})]),_:1})}const vD=at(uD,[["render",hD]]);const mD={props:["certifications"],setup(e,{emit:t}){const n=c=>!!c.title,i=c=>!!c.company_school,a=c=>!!c.date&&/\b\d{4}\/(0[1-9]|1[0-2])\b/.test(c.date),s=c=>!!c.description;return{deleteCer:c=>{c!=-1&&t("delete-cer",c)},addNewCer:()=>{t("add-cer")},saveCer:c=>{let u=!0;c.forEach((d,f)=>{(!n(d)||!i(d)||!a(d)||!s(d))&&(u=!1)}),u?(alert("Your Certificate information has been saved!"),t("save-cer",c)):confirm("Some fields may be incorrect. Please check!")},isTitleValid:n,isCompanySchoolValid:i,isDescriptionValid:s,isDateValid:a}}},gD=be("p",{class:"titletext"},"Certification",-1),pD={class:"d-flex justify-center"};function yD(e,t,n,i,a,s){const o=we("v-icon"),l=we("v-row"),r=we("v-expansion-panel-title"),c=we("v-text-field"),u=we("v-col"),d=we("v-btn"),f=we("v-expansion-panel-text"),v=we("v-expansion-panel");return me(),Tt(v,null,{default:ie(()=>[h(r,{id:"title"},{default:ie(({expanded:m})=>[h(l,{"no-gutters":"",class:"d-flex jusitfy-start"},{default:ie(()=>[gD,h(o,{class:"ml-2",size:"xx-large",icon:"mdi-certificate-outline"})]),_:1})]),_:1}),h(f,null,{default:ie(()=>[(me(!0),Te(Pe,null,At(n.certifications,(m,g)=>(me(),Te("div",{key:g,class:"mb-3",style:{border:"2px solid rgb(198, 194, 194)"}},[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"11"},{default:ie(()=>[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"3"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.title,"onUpdate:modelValue":p=>m.title=p,rules:[()=>i.isTitleValid(m)||"This field is required"],counter:40,label:"Title"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,{cols:"4"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.date,"onUpdate:modelValue":p=>m.date=p,rules:[()=>!!m.date||"This field is required",()=>i.isDateValid(m)||"Date must be in YYYY/MM format"],counter:20,label:"Date"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,null,{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.company_school,"onUpdate:modelValue":p=>m.company_school=p,rules:[()=>i.isCompanySchoolValid(m)||"This field is required"],counter:10,label:"Company/School"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024)]),_:2},1024),h(l,{"no-gutters":""},{default:ie(()=>[h(c,{class:"pl-2 pr-2",modelValue:m.description,"onUpdate:modelValue":p=>m.description=p,rules:[()=>i.isDescriptionValid(m)||"This field is required"],counter:200,label:"Description"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024)]),_:2},1024),h(u,{class:"button-container"},{default:ie(()=>[h(d,{onClick:p=>i.deleteCer(g),color:"red-lighten-2"},{default:ie(()=>[h(o,{size:"x-large",icon:"mdi-trash-can"})]),_:2},1032,["onClick"])]),_:2},1024)]),_:2},1024)]))),128)),be("div",pD,[h(d,{color:"grey-lighten-1",onClick:t[0]||(t[0]=m=>i.addNewCer())},{default:ie(()=>[Xe("Add more "),h(o,{size:"x-large",icon:"mdi-plus-thick"})]),_:1}),h(d,{class:"ml-5",color:"green",onClick:t[1]||(t[1]=m=>i.saveCer(n.certifications))},{default:ie(()=>[Xe("Save "),h(o,{size:"x-large",icon:"mdi-content-save"})]),_:1})])]),_:1})]),_:1})}const bD=at(mD,[["render",yD]]);const _D={props:["awards"],setup(e,{emit:t}){const n=c=>!!c.title,i=c=>!!c.company_school,a=c=>!!c.date&&/\b\d{4}\/(0[1-9]|1[0-2])\b/.test(c.date),s=c=>!!c.description;return{deleteAward:c=>{c!=-1&&t("delete-award",c)},addNewAward:()=>{t("add-award")},saveAward:c=>{let u=!0;c.forEach((d,f)=>{(!n(d)||!i(d)||!s(d))&&(u=!1)}),u?(alert("Your Award information has been saved!"),t("save-award",c)):confirm("Some fields may be incorrect. Please check!")},isTitleValid:n,isCompanySchoolValid:i,isDescriptionValid:s,isDateValid:a}}},xD=be("p",{class:"titletext"},"Award",-1),SD={class:"d-flex justify-center"};function wD(e,t,n,i,a,s){const o=we("v-icon"),l=we("v-row"),r=we("v-expansion-panel-title"),c=we("v-text-field"),u=we("v-col"),d=we("v-btn"),f=we("v-expansion-panel-text"),v=we("v-expansion-panel");return me(),Tt(v,null,{default:ie(()=>[h(r,{id:"title"},{default:ie(({expanded:m})=>[h(l,{"no-gutters":"",class:"d-flex jusitfy-start"},{default:ie(()=>[xD,h(o,{class:"ml-2",size:"xx-large",icon:"mdi-license"})]),_:1})]),_:1}),h(f,null,{default:ie(()=>[(me(!0),Te(Pe,null,At(n.awards,(m,g)=>(me(),Te("div",{key:g,class:"mb-3",style:{border:"2px solid rgb(198, 194, 194)"}},[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"11"},{default:ie(()=>[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"4"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.title,"onUpdate:modelValue":p=>m.title=p,rules:[()=>i.isTitleValid(m)||"This field is required"],counter:40,label:"Title"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,{cols:"4"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.date,"onUpdate:modelValue":p=>m.date=p,rules:[()=>!!m.date||"This field is required",()=>i.isDateValid(m)||"Date must be in YYYY/MM format"],counter:20,label:"Date"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,null,{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.company_school,"onUpdate:modelValue":p=>m.company_school=p,rules:[()=>i.isCompanySchoolValid(m)||"This field is required"],counter:10,label:"Company/School"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024)]),_:2},1024),h(l,{"no-gutters":""},{default:ie(()=>[h(c,{class:"pl-2 pr-2",modelValue:m.description,"onUpdate:modelValue":p=>m.description=p,rules:[()=>i.isDescriptionValid(m)||"This field is required"],counter:200,label:"Description"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024)]),_:2},1024),h(u,{class:"button-container"},{default:ie(()=>[h(d,{onClick:p=>i.deleteAward(g),color:"red-lighten-2"},{default:ie(()=>[h(o,{size:"x-large",icon:"mdi-trash-can"})]),_:2},1032,["onClick"])]),_:2},1024)]),_:2},1024)]))),128)),be("div",SD,[h(d,{color:"grey-lighten-1",onClick:t[0]||(t[0]=m=>i.addNewAward())},{default:ie(()=>[Xe("Add more "),h(o,{size:"x-large",icon:"mdi-plus-thick"})]),_:1}),h(d,{class:"ml-5",color:"green",onClick:t[1]||(t[1]=m=>i.saveAward(n.awards))},{default:ie(()=>[Xe("Save "),h(o,{size:"x-large",icon:"mdi-content-save"})]),_:1})])]),_:1})]),_:1})}const kD=at(_D,[["render",wD]]);ph();const CD={components:{Skill:jE,About:aD,Education:cD,Profession:vD,Certification:bD,Award:kD},data:()=>({panel:[0],defaultSkill:{id:0,title:"New skill",description:"add your description"},defaultEdu:{id:0,title:"New diploma",schoolName:"New shool name",startDate:"2023/01",endDate:"2023/12",description:"add your description"},defaultPro:{id:0,title:"New position",company:"New company name",startDate:"2023/01",endDate:"2023/12",description:"add your description"},defaultCer:{id:0,title:"New certification",date:"2023/01",company_school:"New company name or school name",description:"add your description"},defaultAward:{id:0,title:"New award",date:"2023/01",company_school:"New company name or school name",description:"add your description"}}),setup(){const e=Z([]),t=Z([]),n=Z([]),i=Z([]),a=Z([]),s=Z([]),o=Z([]),l=Z([]),r=Z([]),c=Z([]),u=Z([]),d=Z([]);return _t(async()=>{try{const v=await(await fetch("https://res-a-me-api.tobywinz.com/loadResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*",Authorization:"Bearer "+sessionStorage.getItem("access_token")},body:JSON.stringify({category:"skills"})})).json();r.value=v;const m=v.items.abilities.map((B,G)=>{const{faIcon:ee,locales:le}=B,{title:ce,description:ge}=le.en;return{id:G,title:ce||"",description:ge||""}});e.value=m;const p=await(await fetch("https://res-a-me-api.tobywinz.com/loadResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*",Authorization:"Bearer "+sessionStorage.getItem("access_token")},body:JSON.stringify({category:"cover"})})).json();o.value=p;const b=await(await fetch("https://res-a-me-api.tobywinz.com/loadResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*",Authorization:"Bearer "+sessionStorage.getItem("access_token")},body:JSON.stringify({category:"profile"})})).json();l.value=b;const S=p.locales.en.bio,_=b.name,x=b.profilePictureUrl,P=b.locales.en.role,C={name:_,profilePictureUrl:x,role:P,description:S};t.value=C;const I=await(await fetch("https://res-a-me-api.tobywinz.com/loadResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*",Authorization:"Bearer "+sessionStorage.getItem("access_token")},body:JSON.stringify({category:"education"})})).json();c.value=I;const M=I.items.map(B=>({title:B.locales.en.title,schoolName:B.place,startDate:B.period[0],endDate:B.period[1],description:B.locales.en.description}));n.value=M;const D=await(await fetch("https://res-a-me-api.tobywinz.com/loadResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*",Authorization:"Bearer "+sessionStorage.getItem("access_token")},body:JSON.stringify({category:"experience"})})).json();u.value=D;const N=D.items.map(B=>({title:B.locales.en.title,company:B.place,startDate:B.period[0],endDate:B.period[1],description:B.locales.en.description}));i.value=N;const Y=await(await fetch("https://res-a-me-api.tobywinz.com/loadResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*",Authorization:"Bearer "+sessionStorage.getItem("access_token")},body:JSON.stringify({category:"achievements"})})).json();d.value=Y;const K=Y.items.certifications.map(B=>({title:B.locales.en.title,date:B.date,company_school:B.place,description:B.locales.en.description})),J=Y.items.awards.map(B=>({title:B.locales.en.title,date:B.date,company_school:B.place,description:B.locales.en.description}));a.value=K,s.value=J}catch(f){console.error("Error fetching data:",f)}}),{skills:e,about:t,educations:n,professions:i,certifications:a,awards:s,cover_data_old:o,profile_data_old:l,skill_data_old:r,edu_data_old:c,pro_data_old:u,achi_data_old:d}},methods:{async returnButton(){if(confirm("Are you sure you want to leave this page? Make sure you have saved your changes!")){let e="";try{const n=await(await fetch("https://res-a-me-api.tobywinz.com/loadUser",{method:"GET",headers:{"Content-type":"application/json; charset=UTF-8",Authorization:"Bearer "+sessionStorage.getItem("access_token")}})).json();n.status===200&&(e=n.logged_in_as)}catch(t){console.error("Error fetching user data:",t)}try{const n=await(await fetch("https://res-a-me-api.tobywinz.com/updateResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8"},body:JSON.stringify({email:e})})).json();n.status!==200&&console.error("Error fetching user resume: ",n.message)}catch{console.error("Error fetching user resume: ",error)}this.$router.push({path:"/home"}).then(()=>window.location.reload(!0)).then(()=>window.location.reload(!0))}},handleDeleteSkill(e){confirm("Are you sure you want to delete this item?")&&(this.skills.splice(e,1),this.skills.forEach((t,n)=>{t.id=n}))},handleAddSkill(){const e={...this.defaultSkill};e.id=this.skills.length,this.skills.push(e),this.skills.forEach((t,n)=>{t.id=n})},handleSaveSkill(e){this.skills=e,this.skill_data_old.items.abilities=[];for(let t=0;t{t.id=n}))},handleAddEdu(){const e={...this.defaultEdu};e.id=this.educations.length,this.educations.push(e),this.educations.forEach((t,n)=>{t.id=n})},handleSaveEdu(e){this.educations=e,this.edu_data_old.items=[];for(let t=0;t{t.id=n}))},handleAddPro(){const e={...this.defaultPro};e.id=this.professions.length,this.professions.push(e),this.professions.forEach((t,n)=>{t.id=n})},handleSavePro(e){this.professions=e,this.pro_data_old.items=[];for(let t=0;t{t.id=n}))},handleAddCer(){const e={...this.defaultCer};e.id=this.certifications.length,this.certifications.push(e),this.certifications.forEach((t,n)=>{t.id=n})},async handleSaveCer(e){this.certifications=e,this.achi_data_old.items.certifications=[];for(let t=0;t{t.id=n}))},handleAddAward(){const e={...this.defaultAward};e.id=this.awards.length,this.awards.push(e),this.awards.forEach((t,n)=>{t.id=n})},async handleSaveAward(e){this.awards=e,this.achi_data_old.items.awards=[];for(let t=0;t[h(r,{align:"center"},{default:ie(()=>[be("p",ID,[Xe(" Edit your information here! "),h(l,{onClick:t[0]||(t[0]=y=>s.returnButton()),class:"ml-5 mb-2"},{default:ie(()=>[h(o,{size:"xx-large",icon:"mdi-file-account"}),Xe(" back to resume ")]),_:1})])]),_:1})]),_:1}),h(p,{modelValue:e.panel,"onUpdate:modelValue":t[1]||(t[1]=y=>e.panel=y)},{default:ie(()=>[h(u,{about:i.about,onSaveAbout:s.handleSaveAbout},null,8,["about","onSaveAbout"]),h(d,{educations:i.educations,onDeleteEdu:s.handleDeleteEdu,onAddEdu:s.handleAddEdu,onSaveEdu:s.handleSaveEdu},null,8,["educations","onDeleteEdu","onAddEdu","onSaveEdu"]),h(f,{professions:i.professions,onDeletePro:s.handleDeletePro,onAddPro:s.handleAddPro,onSavePro:s.handleSavePro},null,8,["professions","onDeletePro","onAddPro","onSavePro"]),h(v,{skills:i.skills,onDeleteSkill:s.handleDeleteSkill,onAddSkill:s.handleAddSkill,onSaveSkill:s.handleSaveSkill},null,8,["skills","onDeleteSkill","onAddSkill","onSaveSkill"]),h(m,{certifications:i.certifications,onDeleteCer:s.handleDeleteCer,onAddCer:s.handleAddCer,onSaveCer:s.handleSaveCer},null,8,["certifications","onDeleteCer","onAddCer","onSaveCer"]),h(g,{awards:i.awards,onDeleteAward:s.handleDeleteAward,onAddAward:s.handleAddAward,onSaveAward:s.handleSaveAward},null,8,["awards","onDeleteAward","onAddAward","onSaveAward"])]),_:1},8,["modelValue"])])}const AD=at(CD,[["render",VD]]);const TD={async mounted(){document.getElementById("signinButton").style.display="none",document.getElementById("profileShortcut").style.display="none",document.getElementById("logoutButton").style.display="none",document.getElementById("userNameDisplay").style.display="none",await fetch("https://res-a-me-api.tobywinz.com/loadUser",{method:"GET",headers:{"Content-type":"application/json; charset=UTF-8",Authorization:"Bearer "+sessionStorage.getItem("access_token")}}).then(e=>e.json()).then(e=>{e.status===200?(this.userEmail=e.logged_in_as,fetch(`https://res-a-me-api.tobywinz.com/static/images/${this.userEmail}.png`).then(t=>{t.ok?this.shortCutIcon=`https://res-a-me-api.tobywinz.com/static/images/${this.userEmail}.png`:this.shortCutIcon="/images/pictures/avatar.png"}),document.getElementById("profileShortcut").style.display="block",document.getElementById("logoutButton").style.display="block"):(this.errorMessage="User are not logged in",document.getElementById("signinButton").style.display="block")}).catch(e=>{console.error("There was an error!",e),this.errorMessage=e.message||"An error occurred. Please try again."}),fetch("https://res-a-me-api.tobywinz.com/userList",{method:"GET",headers:{"Content-type":"application/json; charset=UTF-8"}}).then(e=>e.json()).then(e=>{for(let n in e.user_list){e.user_list[n].email===this.userEmail&&(this.userName=e.user_list[n].name,document.getElementById("userNameDisplay").style.display="block");var t="";fetch(`https://res-a-me-api.tobywinz.com/static/images/${e.user_list[n].email}.png`).then(i=>{i.ok?t=`https://res-a-me-api.tobywinz.com/static/images/${e.user_list[n].email}.png`:t="/images/pictures/avatar.png"}).then(()=>{const i={name:e.user_list[n].name,group:e.user_list[n].position,avatar:t,email:e.user_list[n].email};this.people.push(i)})}})},methods:{logout(){const e="";fetch("https://res-a-me-api.tobywinz.com/logout",{method:"GET",headers:{"Content-type":"application/json; charset=UTF-8"}}).then(t=>{if(!t.ok)throw new Error("Network response was not ok");return t.json()}).then(t=>{t.message==="Logout successful"?(sessionStorage.clear(),document.getElementById("logoutButton").style.display="none",document.getElementById("signinButton").style.display="block",document.getElementById("profileShortcut").style.display="none",document.getElementById("userNameDisplay").style.display="none",alert("Logout Successful")):e.value=t.message||"Logout failed. Please try again."}).catch(t=>{console.error("Logout error:",t),e.value=t.message||"An error occurred. Please try again."})},async profileShortcutAction(){try{const t=await(await fetch("https://res-a-me-api.tobywinz.com/updateResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8"},body:JSON.stringify({email:this.userEmail})})).json();t.status!==200&&console.error("Error fetching user resume: ",t.message),this.$router.push({path:"/home"}).then(()=>window.location.reload(!0))}catch{console.error("profileShortcutAction error ")}},async search(){var e="";this.query.email?e=this.query.email:e=this.userEmail;try{const n=await(await fetch("https://res-a-me-api.tobywinz.com/updateResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8"},body:JSON.stringify({email:e})})).json();n.status!==200&&console.error("Error fetching user resume: ",n.message),this.query.email&&this.$router.push({path:"/home",query:{query:this.query.email}}).then(()=>window.location.reload(!0))}catch{console.error("search error")}},async makeConntections(){for(var e=this.userEmail,t="";e===this.userEmail;)t=this.people[Math.floor(Math.random()*this.people.length)],e=t.email;try{const i=await(await fetch("https://res-a-me-api.tobywinz.com/updateResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8"},body:JSON.stringify({email:t.email})})).json();i.status!==200&&console.error("Error fetching user resume: ",i.message),this.$router.push({path:"/home",query:{query:t.email}}).then(()=>window.location.reload(!0))}catch(n){console.error("Error fetching user resume: ",n)}}},data(){return{userName:"",userEmail:"",shortCutIcon:"",autoUpdate:!0,isUpdating:!1,name:"Midnight Crew",query:[],people:[],title:"The summer breeze",timeout:null}}},MD={style:{position:"fixed","z-index":"999",color:"black",right:"140px",top:"28px","text-transform":"none","letter-spacing":"0px","font-size":"13px"},id:"userNameDisplay"},ED=be("div",{class:"text-caption text-truncate"},"My Res-A-Me",-1);function DD(e,t,n,i,a,s){const o=we("v-btn"),l=we("v-hover"),r=we("v-img"),c=we("v-chip"),u=we("v-list-item"),d=we("v-autocomplete"),f=we("v-row"),v=we("v-avatar"),m=we("v-card"),g=we("v-col"),p=we("v-container"),y=we("v-responsive"),b=we("v-app");return me(),Tt(b,{style:{width:"100%",height:"100%"}},{default:ie(()=>[h(l,null,{default:ie(({hover:S})=>[h(o,{variant:"plain",density:"compact",href:"https://tobyyu007.github.io/resame-about-page/",style:Xi({position:"fixed","z-index":"999",color:"black",left:"20px",top:"27px","text-transform":"none","letter-spacing":"0px",opacity:"1","text-decoration":S?"underline":"none"})},{default:ie(()=>[Xe(" About ")]),_:2},1032,["style"])]),_:1}),be("p",MD," Hi, "+wt(a.userName),1),h(o,{variant:"flat",color:"#1a73e8",style:{position:"fixed","z-index":"999",color:"white",right:"40px",top:"20px","text-transform":"none"},id:"signinButton",onClick:t[0]||(t[0]=S=>this.$router.push("/login"))},{default:ie(()=>[Xe(" Sign in ")]),_:1}),h(o,{variant:"flat",color:"#1a73e8",style:{position:"fixed","z-index":"999",color:"white",right:"40px",top:"20px","text-transform":"none"},id:"logoutButton",onClick:t[1]||(t[1]=S=>s.logout())},{default:ie(()=>[Xe(" Logout ")]),_:1}),h(m,{theme:"light",class:"d-flex justify-center align-center flex-wrap",style:{width:"100%",height:"100%"}},{default:ie(()=>[h(y,{"max-width":"550"},{default:ie(()=>[h(r,{class:"mx-auto mt-12 mb-16","max-width":"340",src:"./images/icons/Res-A-Me.png"}),h(d,{modelValue:a.query,"onUpdate:modelValue":t[2]||(t[2]=S=>a.query=S),disabled:a.isUpdating,items:a.people,chips:"",color:"blue-grey-lighten-2","item-title":"name","item-value":"name",label:"Search People","prepend-inner-icon":"mdi-magnify",density:"comfortable","auto-select-first":"","return-object":"",rounded:"",theme:"light",variant:"outlined"},{chip:ie(({props:S,item:_})=>[h(c,ve(S,{"prepend-avatar":_.raw.avatar,text:_.raw.name}),null,16,["prepend-avatar","text"])]),item:ie(({props:S,item:_})=>{var x,P,C;return[h(u,ve(S,{"prepend-avatar":(x=_==null?void 0:_.raw)==null?void 0:x.avatar,title:(P=_==null?void 0:_.raw)==null?void 0:P.name,subtitle:(C=_==null?void 0:_.raw)==null?void 0:C.group}),null,16,["prepend-avatar","title","subtitle"])]}),_:1},8,["modelValue","disabled","items"]),h(f,{dense:"",justify:"center",class:"pt-5 pb-5"},{default:ie(()=>[h(o,{variant:"flat",color:"#ededf0",style:{"text-transform":"none","letter-spacing":"0px"},class:"mr-5",onClick:t[3]||(t[3]=S=>s.search())},{default:ie(()=>[Xe(" Res-A-Me Search ")]),_:1}),h(o,{variant:"flat",color:"#ededf0",style:{"text-transform":"none","letter-spacing":"0px"},onClick:t[4]||(t[4]=S=>s.makeConntections())},{default:ie(()=>[Xe(" Make Connections ")]),_:1})]),_:1}),h(p,{class:"text-center pt-15",id:"profileShortcut"},{default:ie(()=>[h(f,{justify:"center",dense:""},{default:ie(()=>[h(g,{cols:"auto"},{default:ie(()=>[h(m,{class:"pa-4",flat:"",rel:"noopener noreferer",target:"_blank",width:"112",onClick:t[5]||(t[5]=S=>s.profileShortcutAction())},{default:ie(()=>[h(v,{variant:"tonal",class:"mb-2",size:"60"},{default:ie(()=>[h(r,{src:a.shortCutIcon},null,8,["src"])]),_:1}),ED]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})}const OD=at(TD,[["render",DD]]);function RD(){const t=Oi().getSections(),n=t[0]||{id:"home"},i=["edit"],a=[{path:"/",name:"LandingPage",component:OD},{path:"/login",name:"login",component:NE},{path:"/home",name:n.id,component:Jg},{path:"/edit",name:"edit",component:AD}];for(let o=1;o{let c=!1;try{const d=await(await fetch("https://res-a-me-api.tobywinz.com/loadUser",{method:"GET",headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*",Authorization:"Bearer "+sessionStorage.getItem("access_token")}})).json();if(d.status===200)c=!0;else if(d.msg==="Token has expired"){const v=await(await fetch("https://res-a-me-api.tobywinz.com/refresh",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*",Authorization:"Bearer "+sessionStorage.getItem("refresh_token")}})).json();if(v.status===200)sessionStorage.setItem("access_token",v.access_token),c=!0;else throw new Error("Refresh Token Expired!!! Please Log In Again")}}catch(u){console.error("There was an error!",u)}console.log("isAuthenticated = ",c),o.name==="login"&&c?r({name:n.id}):i.includes(o.name)&&!c?r({name:"login"}):r()}),s}const LD={class:"loader-full-screen-content"},BD={class:"mt-2 mb-2 text-2"},ep=1/60,ND={__name:"Loader",emits:["willShow","shown","completed","willHide","hidden"],setup(e,{expose:t,emit:n}){const i=n,a=[{id:0,label:"startingUp",duration:null},{id:1,label:"logoTweenIn",duration:.5},{id:2,label:"progressTweenIn",duration:.3},{id:3,label:"loading",minDuration:.4},{id:4,label:"waiting",duration:.3},{id:5,label:"disappearing",duration:1.2}],s=Z(""),o=Z(""),l=Z(0),r=Z(null),c=Z(0),u=Z(-1);let d=0,f=null;_t(()=>{v()});const v=()=>{clearInterval(f),f=null,u.value=-1,d=0,c.value=0},m=(x,P)=>{s.value=x,o.value=P,u.value=0,f=setInterval(p,ep*1e3)},g=x=>{l.value=x},p=()=>{const x=a[u.value];d+=ep;let P=!1;switch(x.label){case"startingUp":P=r.value.isLoaded();break;case"loading":const C=Math.min(Math.max(100*d/x.minDuration,0),100);c.value=Math.round(Math.min(C,l.value)),P=c.value>=100;break;default:P=d>=x.duration}P&&y()},y=()=>{if(u.value++,d=0,u.value>=a.length){i("hidden"),v();return}switch(a[u.value].label){case"logoTweenIn":i("willShow");break;case"loading":i("shown");break;case"waiting":i("completed");break;case"disappearing":i("willHide");break}},b=x=>{const P=a.find(C=>C.label===x);return P&&u.value>=P.id},S=()=>u.value>=0&&u.valueS()?b("disappearing")?"loader-full-screen-transition":"loader-full-screen-show":"d-none";return t({run:m,setTaskProgress:g}),(x,P)=>S()?(me(),Te("div",{key:0,class:xt(["loader-full-screen",_()])},[ft(be("div",LD,[h(yh,{src:o.value,alt:"Preloader Logo","ignore-on-image-count":!0,ref_key:"logo",ref:r,class:"img-fluid img-logo"},null,8,["src"]),be("div",{class:xt(["progress-display",{"progress-display-expanded":b("progressTweenIn")}])},[be("p",BD,wt(s.value)+"...",1),h(Yb,{ref:"progressBar",percentage:c.value},null,8,["percentage"])],2)],512),[[mn,b("logoTweenIn")]])],2)):kt("",!0)}},FD=at(ND,[["__scopeId","data-v-e789e4ad"]]);const $D=e=>(Oa("data-v-c428fd9e"),e=e(),Ra(),e),zD={class:"activity-spinner-content text-center"},HD=$D(()=>be("img",{alt:"loading...",class:"preloader-gif",src:"data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4KPHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBzdHlsZT0ibWFyZ2luOiBhdXRvOyBiYWNrZ3JvdW5kOiBub25lOyBkaXNwbGF5OiBibG9jazsgc2hhcGUtcmVuZGVyaW5nOiBhdXRvOyIgd2lkdGg9IjIwMHB4IiBoZWlnaHQ9IjIwMHB4IiB2aWV3Qm94PSIwIDAgMTAwIDEwMCIgcHJlc2VydmVBc3BlY3RSYXRpbz0ieE1pZFlNaWQiPgo8Y2lyY2xlIGN4PSI1MCIgY3k9IjUwIiByPSIzMiIgc3Ryb2tlLXdpZHRoPSI4IiBzdHJva2U9IiM1NDUxNTEiIHN0cm9rZS1kYXNoYXJyYXk9IjUwLjI2NTQ4MjQ1NzQzNjY5IDUwLjI2NTQ4MjQ1NzQzNjY5IiBmaWxsPSJub25lIiBzdHJva2UtbGluZWNhcD0icm91bmQiPgogIDxhbmltYXRlVHJhbnNmb3JtIGF0dHJpYnV0ZU5hbWU9InRyYW5zZm9ybSIgdHlwZT0icm90YXRlIiBkdXI9IjFzIiByZXBlYXRDb3VudD0iaW5kZWZpbml0ZSIga2V5VGltZXM9IjA7MSIgdmFsdWVzPSIwIDUwIDUwOzM2MCA1MCA1MCI+PC9hbmltYXRlVHJhbnNmb3JtPgo8L2NpcmNsZT4KPGNpcmNsZSBjeD0iNTAiIGN5PSI1MCIgcj0iMjMiIHN0cm9rZS13aWR0aD0iOCIgc3Ryb2tlPSIjYzNjM2M1IiBzdHJva2UtZGFzaGFycmF5PSIzNi4xMjgzMTU1MTYyODI2MiAzNi4xMjgzMTU1MTYyODI2MiIgc3Ryb2tlLWRhc2hvZmZzZXQ9IjM2LjEyODMxNTUxNjI4MjYyIiBmaWxsPSJub25lIiBzdHJva2UtbGluZWNhcD0icm91bmQiPgogIDxhbmltYXRlVHJhbnNmb3JtIGF0dHJpYnV0ZU5hbWU9InRyYW5zZm9ybSIgdHlwZT0icm90YXRlIiBkdXI9IjFzIiByZXBlYXRDb3VudD0iaW5kZWZpbml0ZSIga2V5VGltZXM9IjA7MSIgdmFsdWVzPSIwIDUwIDUwOy0zNjAgNTAgNTAiPjwvYW5pbWF0ZVRyYW5zZm9ybT4KPC9jaXJjbGU+CjwhLS0gW2xkaW9dIGdlbmVyYXRlZCBieSBodHRwczovL2xvYWRpbmcuaW8vIC0tPjwvc3ZnPg=="},null,-1)),jD={class:"text-light-5"},WD={__name:"ActivitySpinner",setup(e,{expose:t}){const n=Z(""),i=Z(!1);return t({show:o=>{n.value=o,i.value=!0},hide:()=>{i.value=!1}}),(o,l)=>(me(),Te("div",{class:xt(["activity-spinner",{"d-none":!i.value}])},[be("div",zD,[HD,be("h5",jD,wt(n.value),1)])],2))}},UD=at(WD,[["__scopeId","data-v-c428fd9e"]]);const YD={__name:"FeedbackView",setup(e,{expose:t}){const n=To(),i=Z(null),a=Z(null),s={onShown:null,onComplete:null},o=(m,g)=>{n.setPageScrollingEnabled(!1),i.value.run(m,g)},l=(m,g)=>{s.onShown=m,s.onComplete=g},r=m=>{i.value.setTaskProgress(m)},c=()=>{s.onShown&&s.onShown()},u=()=>{s.onComplete&&s.onComplete()},d=()=>{n.setPageScrollingEnabled(!0),s.onShown=null,s.onComplete=null};return t({setLoader:o,setLoaderListeners:l,updateLoaderProgress:r,showActivitySpinner:m=>{a.value.show(m)},hideActivitySpinner:()=>{a.value.hide()}}),(m,g)=>(me(),Te(Pe,null,[h(FD,{ref_key:"loader",ref:i,onShown:c,onCompleted:u,onWillHide:d},null,512),h(UD,{ref_key:"activitySpinner",ref:a},null,512)],64))}},KD=at(YD,[["__scopeId","data-v-78d8acb8"]]),GD={key:0},XD={__name:"App",setup(e){const t=Oi(),n=To(),i=Ba(),a=Z(null),s=Z(!1);let o=null;_t(()=>{n.setFeedbackView(a),r()});const l=w(()=>t.getSettings().preloaderEnabled),r=async()=>{clearInterval(o),l.value?(a.value.setLoaderListeners(c,d),a.value.setLoader(t.getString("loading"),"images/icons/resume.ico")):await c()},c=async()=>{o=setInterval(()=>{u()},1e3/30),await t.fetchAll(),l.value||(d(),n.setPageScrollingEnabled(!0))},u=()=>{if(!l.value)return;const f=t.getLoadProgress(),v=n.getImageCount();let m=0;v.total>0?m=Math.round(100*v.loaded/v.total):f===100&&(m=100);const g=(f+m*4)/5;a.value.updateLoaderProgress(g)},d=()=>{s.value=!0,clearInterval(o)};return(f,v)=>{const m=we("router-view");return me(),Te(Pe,null,[h(KD,{ref_key:"feedbackView",ref:a},null,512),Je(t).getLoadProgress()>=100?ft((me(),Te("div",GD,[h(m)],512)),[[mn,!Je(i).isTouchDevice()||s.value]]):kt("",!0)],64)}}},qD={badge:"Badge",open:"Open",close:"Close",confirmEdit:{ok:"OK",cancel:"Cancel"},dataIterator:{noResultsText:"No matching records found",loadingText:"Loading items..."},dataTable:{itemsPerPageText:"Rows per page:",ariaLabel:{sortDescending:"Sorted descending.",sortAscending:"Sorted ascending.",sortNone:"Not sorted.",activateNone:"Activate to remove sorting.",activateDescending:"Activate to sort descending.",activateAscending:"Activate to sort ascending."},sortBy:"Sort by"},dataFooter:{itemsPerPageText:"Items per page:",itemsPerPageAll:"All",nextPage:"Next page",prevPage:"Previous page",firstPage:"First page",lastPage:"Last page",pageText:"{0}-{1} of {2}"},dateRangeInput:{divider:"to"},datePicker:{itemsSelected:"{0} selected",range:{title:"Select dates",header:"Enter dates"},title:"Select date",header:"Enter date",input:{placeholder:"Enter date"}},noDataText:"No data available",carousel:{prev:"Previous visual",next:"Next visual",ariaLabel:{delimiter:"Carousel slide {0} of {1}"}},calendar:{moreEvents:"{0} more"},input:{clear:"Clear {0}",prependAction:"{0} prepended action",appendAction:"{0} appended action",otp:"Please enter OTP character {0}"},fileInput:{counter:"{0} files",counterSize:"{0} files ({1} in total)"},timePicker:{am:"AM",pm:"PM"},pagination:{ariaLabel:{root:"Pagination Navigation",next:"Next page",previous:"Previous page",page:"Go to page {0}",currentPage:"Page {0}, Current page",first:"First page",last:"Last page"}},stepper:{next:"Next",prev:"Previous"},rating:{ariaLabel:{item:"Rating {0} of {1}"}},loading:"Loading...",infiniteScroll:{loadMore:"Load more",empty:"No more"}},ZD={af:!1,ar:!0,bg:!1,ca:!1,ckb:!1,cs:!1,de:!1,el:!1,en:!1,es:!1,et:!1,fa:!0,fi:!1,fr:!1,hr:!1,hu:!1,he:!0,id:!1,it:!1,ja:!1,ko:!1,lv:!1,lt:!1,nl:!1,no:!1,pl:!1,pt:!1,ro:!1,ru:!1,sk:!1,sl:!1,srCyrl:!1,srLatn:!1,sv:!1,th:!1,tr:!1,az:!1,uk:!1,vi:!1,zhHans:!1,zhHant:!1};function mi(e,t){let n;function i(){n=Hc(),n.run(()=>t.length?t(()=>{n==null||n.stop(),i()}):t())}_e(e,a=>{a&&!n?i():a||(n==null||n.stop(),n=void 0)},{immediate:!0}),_n(()=>{n==null||n.stop()})}const yt=typeof window<"u",Dh=yt&&"IntersectionObserver"in window,JD=yt&&("ontouchstart"in window||window.navigator.maxTouchPoints>0),tp=yt&&"EyeDropper"in window;function np(e,t,n){QD(e,t),t.set(e,n)}function QD(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function eO(e,t,n){var i=O_(e,t,"set");return tO(e,i,n),n}function tO(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}function ts(e,t){var n=O_(e,t,"get");return nO(e,n)}function O_(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}function nO(e,t){return t.get?t.get.call(e):t.value}function R_(e,t,n){const i=t.length-1;if(i<0)return e===void 0?n:e;for(let a=0;ana(e[i],t[i]))}function Ss(e,t,n){return e==null||!t||typeof t!="string"?n:e[t]!==void 0?e[t]:(t=t.replace(/\[(\w+)\]/g,".$1"),t=t.replace(/^\./,""),R_(e,t.split("."),n))}function rn(e,t,n){if(t===!0)return e===void 0?n:e;if(t==null||typeof t=="boolean")return n;if(e!==Object(e)){if(typeof t!="function")return n;const a=t(e,n);return typeof a>"u"?n:a}if(typeof t=="string")return Ss(e,t,n);if(Array.isArray(t))return R_(e,t,n);if(typeof t!="function")return n;const i=t(e,n);return typeof i>"u"?n:i}function Ti(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return Array.from({length:e},(n,i)=>t+i)}function Ee(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"px";if(!(e==null||e===""))return isNaN(+e)?String(e):isFinite(+e)?`${Number(e)}${t}`:void 0}function Mc(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function $l(e){if(e&&"$el"in e){const t=e.$el;return(t==null?void 0:t.nodeType)===Node.TEXT_NODE?t.nextElementSibling:t}return e}const ip=Object.freeze({enter:13,tab:9,delete:46,esc:27,space:32,up:38,down:40,left:37,right:39,end:35,home:36,del:46,backspace:8,insert:45,pageup:33,pagedown:34,shift:16}),sf=Object.freeze({enter:"Enter",tab:"Tab",delete:"Delete",esc:"Escape",space:"Space",up:"ArrowUp",down:"ArrowDown",left:"ArrowLeft",right:"ArrowRight",end:"End",home:"Home",del:"Delete",backspace:"Backspace",insert:"Insert",pageup:"PageUp",pagedown:"PageDown",shift:"Shift"});function L_(e){return Object.keys(e)}function ls(e,t){return t.every(n=>e.hasOwnProperty(n))}function B_(e,t){const n={},i=new Set(Object.keys(e));for(const a of t)i.has(a)&&(n[a]=e[a]);return n}function of(e,t,n){const i=Object.create(null),a=Object.create(null);for(const s in e)t.some(o=>o instanceof RegExp?o.test(s):o===s)&&!(n!=null&&n.some(o=>o===s))?i[s]=e[s]:a[s]=e[s];return[i,a]}function nn(e,t){const n={...e};return t.forEach(i=>delete n[i]),n}function N_(e,t){const n={};return t.forEach(i=>n[i]=e[i]),n}const F_=/^on[^a-z]/,fu=e=>F_.test(e),iO=["onAfterscriptexecute","onAnimationcancel","onAnimationend","onAnimationiteration","onAnimationstart","onAuxclick","onBeforeinput","onBeforescriptexecute","onChange","onClick","onCompositionend","onCompositionstart","onCompositionupdate","onContextmenu","onCopy","onCut","onDblclick","onFocusin","onFocusout","onFullscreenchange","onFullscreenerror","onGesturechange","onGestureend","onGesturestart","onGotpointercapture","onInput","onKeydown","onKeypress","onKeyup","onLostpointercapture","onMousedown","onMousemove","onMouseout","onMouseover","onMouseup","onMousewheel","onPaste","onPointercancel","onPointerdown","onPointerenter","onPointerleave","onPointermove","onPointerout","onPointerover","onPointerup","onReset","onSelect","onSubmit","onTouchcancel","onTouchend","onTouchmove","onTouchstart","onTransitioncancel","onTransitionend","onTransitionrun","onTransitionstart","onWheel"],aO=["ArrowUp","ArrowDown","ArrowRight","ArrowLeft","Enter","Escape","Tab"," "];function sO(e){return e.isComposing&&aO.includes(e.key)}function Fa(e){const[t,n]=of(e,[F_]),i=nn(t,iO),[a,s]=of(n,["class","style","id",/^data-/]);return Object.assign(a,t),Object.assign(s,i),[a,s]}function Ht(e){return e==null?[]:Array.isArray(e)?e:[e]}function oO(e,t){let n=0;const i=function(){for(var a=arguments.length,s=new Array(a),o=0;oe(...s),Je(t))};return i.clear=()=>{clearTimeout(n)},i.immediate=e,i}function Zt(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1;return Math.max(t,Math.min(n,e))}function ap(e){const t=e.toString().trim();return t.includes(".")?t.length-t.indexOf(".")-1:0}function sp(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"0";return e+n.repeat(Math.max(0,t-e.length))}function op(e,t){return(arguments.length>2&&arguments[2]!==void 0?arguments[2]:"0").repeat(Math.max(0,t-e.length))+e}function lO(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;const n=[];let i=0;for(;i1&&arguments[1]!==void 0?arguments[1]:1e3;if(e=t&&i0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0;const i={};for(const a in e)i[a]=e[a];for(const a in t){const s=e[a],o=t[a];if(Mc(s)&&Mc(o)){i[a]=si(s,o,n);continue}if(Array.isArray(s)&&Array.isArray(o)&&n){i[a]=n(s,o);continue}i[a]=o}return i}function $_(e){return e.map(t=>t.type===Pe?$_(t.children):t).flat()}function ms(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";if(ms.cache.has(e))return ms.cache.get(e);const t=e.replace(/[^a-z]/gi,"-").replace(/\B([A-Z])/g,"-$1").toLowerCase();return ms.cache.set(e,t),t}ms.cache=new Map;function Sl(e,t){if(!t||typeof t!="object")return[];if(Array.isArray(t))return t.map(n=>Sl(e,n)).flat(1);if(Array.isArray(t.children))return t.children.map(n=>Sl(e,n)).flat(1);if(t.component){if(Object.getOwnPropertySymbols(t.component.provides).includes(e))return[t.component];if(t.component.subTree)return Sl(e,t.component.subTree).flat(1)}return[]}var Yr=new WeakMap,qs=new WeakMap;class rO{constructor(t){np(this,Yr,{writable:!0,value:[]}),np(this,qs,{writable:!0,value:0}),this.size=t}push(t){ts(this,Yr)[ts(this,qs)]=t,eO(this,qs,(ts(this,qs)+1)%this.size)}values(){return ts(this,Yr).slice(ts(this,qs)).concat(ts(this,Yr).slice(0,ts(this,qs)))}}function cO(e){return"touches"in e?{clientX:e.touches[0].clientX,clientY:e.touches[0].clientY}:{clientX:e.clientX,clientY:e.clientY}}function Oh(e){const t=Ft({}),n=w(e);return Jt(()=>{for(const i in n.value)t[i]=n.value[i]},{flush:"sync"}),Ql(t)}function Ec(e,t){return e.includes(t)}function z_(e){return e[2].toLowerCase()+e.slice(3)}const Bn=()=>[Function,Array];function rp(e,t){return t="on"+bi(t),!!(e[t]||e[`${t}Once`]||e[`${t}Capture`]||e[`${t}OnceCapture`]||e[`${t}CaptureOnce`])}function Rh(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i1&&arguments[1]!==void 0?arguments[1]:!0;const n=["button","[href]",'input:not([type="hidden"])',"select","textarea","[tabindex]"].map(i=>`${i}${t?':not([tabindex="-1"])':""}:not([disabled])`).join(", ");return[...e.querySelectorAll(n)]}function H_(e,t,n){let i,a=e.indexOf(document.activeElement);const s=t==="next"?1:-1;do a+=s,i=e[a];while((!i||i.offsetParent==null||!((n==null?void 0:n(i))??!0))&&a=0);return i}function _o(e,t){var i,a,s,o;const n=zl(e);if(!t)(e===document.activeElement||!e.contains(document.activeElement))&&((i=n[0])==null||i.focus());else if(t==="first")(a=n[0])==null||a.focus();else if(t==="last")(s=n.at(-1))==null||s.focus();else if(typeof t=="number")(o=n[t])==null||o.focus();else{const l=H_(n,t);l?l.focus():_o(e,t==="next"?"first":"last")}}function Kr(e){return e==null||typeof e=="string"&&e.trim()===""}function j_(){}function xo(e,t){if(!(yt&&typeof CSS<"u"&&typeof CSS.supports<"u"&&CSS.supports(`selector(${t})`)))return null;try{return!!e&&e.matches(t)}catch{return null}}function hu(e){return e.some(t=>qi(t)?t.type===vn?!1:t.type!==Pe||hu(t.children):!0)?e:null}const W_=["top","bottom"],uO=["start","end","left","right"];function lf(e,t){let[n,i]=e.split(" ");return i||(i=Ec(W_,n)?"start":Ec(uO,n)?"top":"center"),{side:rf(n,t),align:rf(i,t)}}function rf(e,t){return e==="start"?t?"right":"left":e==="end"?t?"left":"right":e}function yd(e){return{side:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[e.side],align:e.align}}function bd(e){return{side:e.side,align:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[e.align]}}function cp(e){return{side:e.align,align:e.side}}function up(e){return Ec(W_,e.side)?"y":"x"}class gs{constructor(t){let{x:n,y:i,width:a,height:s}=t;this.x=n,this.y=i,this.width=a,this.height=s}get top(){return this.y}get bottom(){return this.y+this.height}get left(){return this.x}get right(){return this.x+this.width}}function dp(e,t){return{x:{before:Math.max(0,t.left-e.left),after:Math.max(0,e.right-t.right)},y:{before:Math.max(0,t.top-e.top),after:Math.max(0,e.bottom-t.bottom)}}}function U_(e){return Array.isArray(e)?new gs({x:e[0],y:e[1],width:0,height:0}):e.getBoundingClientRect()}function Lh(e){const t=e.getBoundingClientRect(),n=getComputedStyle(e),i=n.transform;if(i){let a,s,o,l,r;if(i.startsWith("matrix3d("))a=i.slice(9,-1).split(/, /),s=+a[0],o=+a[5],l=+a[12],r=+a[13];else if(i.startsWith("matrix("))a=i.slice(7,-1).split(/, /),s=+a[0],o=+a[3],l=+a[4],r=+a[5];else return new gs(t);const c=n.transformOrigin,u=t.x-l-(1-s)*parseFloat(c),d=t.y-r-(1-o)*parseFloat(c.slice(c.indexOf(" ")+1)),f=s?t.width/s:e.offsetWidth+1,v=o?t.height/o:e.offsetHeight+1;return new gs({x:u,y:d,width:f,height:v})}else return new gs(t)}function rs(e,t,n){if(typeof e.animate>"u")return{finished:Promise.resolve()};let i;try{i=e.animate(t,n)}catch{return{finished:Promise.resolve()}}return typeof i.finished>"u"&&(i.finished=new Promise(a=>{i.onfinish=()=>{a(i)}})),i}const ac=new WeakMap;function dO(e,t){Object.keys(t).forEach(n=>{if(fu(n)){const i=z_(n),a=ac.get(e);if(t[n]==null)a==null||a.forEach(s=>{const[o,l]=s;o===i&&(e.removeEventListener(i,l),a.delete(s))});else if(!a||![...a].some(s=>s[0]===i&&s[1]===t[n])){e.addEventListener(i,t[n]);const s=a||new Set;s.add([i,t[n]]),ac.has(e)||ac.set(e,s)}}else t[n]==null?e.removeAttribute(n):e.setAttribute(n,t[n])})}function fO(e,t){Object.keys(t).forEach(n=>{if(fu(n)){const i=z_(n),a=ac.get(e);a==null||a.forEach(s=>{const[o,l]=s;o===i&&(e.removeEventListener(i,l),a.delete(s))})}else e.removeAttribute(n)})}const Zs=2.4,fp=.2126729,hp=.7151522,vp=.072175,hO=.55,vO=.58,mO=.57,gO=.62,Gr=.03,mp=1.45,pO=5e-4,yO=1.25,bO=1.25,gp=.078,pp=12.82051282051282,Xr=.06,yp=.001;function bp(e,t){const n=(e.r/255)**Zs,i=(e.g/255)**Zs,a=(e.b/255)**Zs,s=(t.r/255)**Zs,o=(t.g/255)**Zs,l=(t.b/255)**Zs;let r=n*fp+i*hp+a*vp,c=s*fp+o*hp+l*vp;if(r<=Gr&&(r+=(Gr-r)**mp),c<=Gr&&(c+=(Gr-c)**mp),Math.abs(c-r)r){const d=(c**hO-r**vO)*yO;u=d-yp?0:d>-gp?d-d*pp*Xr:d+Xr}return u*100}function _O(e,t){t=Array.isArray(t)?t.slice(0,-1).map(n=>`'${n}'`).join(", ")+` or '${t.at(-1)}'`:`'${t}'`}const Dc=.20689655172413793,xO=e=>e>Dc**3?Math.cbrt(e):e/(3*Dc**2)+4/29,SO=e=>e>Dc?e**3:3*Dc**2*(e-4/29);function Y_(e){const t=xO,n=t(e[1]);return[116*n-16,500*(t(e[0]/.95047)-n),200*(n-t(e[2]/1.08883))]}function K_(e){const t=SO,n=(e[0]+16)/116;return[t(n+e[1]/500)*.95047,t(n),t(n-e[2]/200)*1.08883]}const wO=[[3.2406,-1.5372,-.4986],[-.9689,1.8758,.0415],[.0557,-.204,1.057]],kO=e=>e<=.0031308?e*12.92:1.055*e**(1/2.4)-.055,CO=[[.4124,.3576,.1805],[.2126,.7152,.0722],[.0193,.1192,.9505]],PO=e=>e<=.04045?e/12.92:((e+.055)/1.055)**2.4;function G_(e){const t=Array(3),n=kO,i=wO;for(let a=0;a<3;++a)t[a]=Math.round(Zt(n(i[a][0]*e[0]+i[a][1]*e[1]+i[a][2]*e[2]))*255);return{r:t[0],g:t[1],b:t[2]}}function Bh(e){let{r:t,g:n,b:i}=e;const a=[0,0,0],s=PO,o=CO;t=s(t/255),n=s(n/255),i=s(i/255);for(let l=0;l<3;++l)a[l]=o[l][0]*t+o[l][1]*n+o[l][2]*i;return a}function cf(e){return!!e&&/^(#|var\(--|(rgb|hsl)a?\()/.test(e)}function IO(e){return cf(e)&&!/^((rgb|hsl)a?\()?var\(--/.test(e)}const _p=/^(?(?:rgb|hsl)a?)\((?.+)\)/,VO={rgb:(e,t,n,i)=>({r:e,g:t,b:n,a:i}),rgba:(e,t,n,i)=>({r:e,g:t,b:n,a:i}),hsl:(e,t,n,i)=>xp({h:e,s:t,l:n,a:i}),hsla:(e,t,n,i)=>xp({h:e,s:t,l:n,a:i}),hsv:(e,t,n,i)=>Zi({h:e,s:t,v:n,a:i}),hsva:(e,t,n,i)=>Zi({h:e,s:t,v:n,a:i})};function oi(e){if(typeof e=="number")return{r:(e&16711680)>>16,g:(e&65280)>>8,b:e&255};if(typeof e=="string"&&_p.test(e)){const{groups:t}=e.match(_p),{fn:n,values:i}=t,a=i.split(/,\s*/).map(s=>s.endsWith("%")&&["hsl","hsla","hsv","hsva"].includes(n)?parseFloat(s)/100:parseFloat(s));return VO[n](...a)}else if(typeof e=="string"){let t=e.startsWith("#")?e.slice(1):e;return[3,4].includes(t.length)?t=t.split("").map(n=>n+n).join(""):[6,8].includes(t.length),Q_(t)}else if(typeof e=="object"){if(ls(e,["r","g","b"]))return e;if(ls(e,["h","s","l"]))return Zi(Nh(e));if(ls(e,["h","s","v"]))return Zi(e)}throw new TypeError(`Invalid color: ${e==null?e:String(e)||e.constructor.name} +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function g(L,k){if(typeof L!="object"||L===null)return L;var T=L[Symbol.toPrimitive];if(T!==void 0){var A=T.call(L,k||"default");if(typeof A!="object")return A;throw new TypeError("@@toPrimitive must return a primitive value.")}return(k==="string"?String:Number)(L)}function p(L){var k=g(L,"string");return typeof k=="symbol"?k:String(k)}var y=typeof window<"u"&&typeof window.document<"u",b=y?window:{},S=y&&b.document.documentElement?"ontouchstart"in b.document.documentElement:!1,_=y?"PointerEvent"in b:!1,x="cropper",P="all",C="crop",V="move",I="zoom",M="e",O="w",D="s",N="n",j="ne",Y="nw",K="se",J="sw",B="".concat(x,"-crop"),G="".concat(x,"-disabled"),ee="".concat(x,"-hidden"),le="".concat(x,"-hide"),ce="".concat(x,"-invisible"),ge="".concat(x,"-modal"),Me="".concat(x,"-move"),Oe="".concat(x,"Action"),te="".concat(x,"Preview"),U="crop",Q="move",ae="none",X="crop",Ie="cropend",E="cropmove",R="cropstart",F="dblclick",q=S?"touchstart":"mousedown",oe=S?"touchmove":"mousemove",he=S?"touchend touchcancel":"mouseup",ke=_?"pointerdown":q,xe=_?"pointermove":oe,Ve=_?"pointerup pointercancel":he,pe="ready",Ne="resize",Le="wheel",Fe="zoom",Ue="image/jpeg",qe=/^e|w|s|n|se|sw|ne|nw|all|crop|move|zoom$/,gt=/^data:/,rt=/^data:image\/jpeg;base64,/,Bt=/^img|canvas$/i,An=200,Li=100,$o={viewMode:0,dragMode:U,initialAspectRatio:NaN,aspectRatio:NaN,data:null,preview:"",responsive:!0,restore:!0,checkCrossOrigin:!0,checkOrientation:!0,modal:!0,guides:!0,center:!0,highlight:!0,background:!0,autoCrop:!0,autoCropArea:.8,movable:!0,rotatable:!0,scalable:!0,zoomable:!0,zoomOnTouch:!0,zoomOnWheel:!0,wheelZoomRatio:.1,cropBoxMovable:!0,cropBoxResizable:!0,toggleDragModeOnDblclick:!0,minCanvasWidth:0,minCanvasHeight:0,minCropBoxWidth:0,minCropBoxHeight:0,minContainerWidth:An,minContainerHeight:Li,ready:null,cropstart:null,cropmove:null,cropend:null,crop:null,zoom:null},Wa='
',gr=Number.isNaN||b.isNaN;function ze(L){return typeof L=="number"&&!gr(L)}var $n=function(k){return k>0&&k<1/0};function $s(L){return typeof L>"u"}function Ua(L){return a(L)==="object"&&L!==null}var RS=Object.prototype.hasOwnProperty;function zs(L){if(!Ua(L))return!1;try{var k=L.constructor,T=k.prototype;return k&&T&&RS.call(T,"isPrototypeOf")}catch{return!1}}function Tn(L){return typeof L=="function"}var LS=Array.prototype.slice;function wv(L){return Array.from?Array.from(L):LS.call(L)}function Gt(L,k){return L&&Tn(k)&&(Array.isArray(L)||ze(L.length)?wv(L).forEach(function(T,A){k.call(L,T,A,L)}):Ua(L)&&Object.keys(L).forEach(function(T){k.call(L,L[T],T,L)})),L}var It=Object.assign||function(k){for(var T=arguments.length,A=new Array(T>1?T-1:0),H=1;H0&&A.forEach(function($){Ua($)&&Object.keys($).forEach(function(z){k[z]=$[z]})}),k},BS=/\.\d*(?:0|9){12}\d*$/;function Hs(L){var k=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1e11;return BS.test(L)?Math.round(L*k)/k:L}var NS=/^width|height|left|top|marginLeft|marginTop$/;function la(L,k){var T=L.style;Gt(k,function(A,H){NS.test(H)&&ze(A)&&(A="".concat(A,"px")),T[H]=A})}function FS(L,k){return L.classList?L.classList.contains(k):L.className.indexOf(k)>-1}function on(L,k){if(k){if(ze(L.length)){Gt(L,function(A){on(A,k)});return}if(L.classList){L.classList.add(k);return}var T=L.className.trim();T?T.indexOf(k)<0&&(L.className="".concat(T," ").concat(k)):L.className=k}}function xi(L,k){if(k){if(ze(L.length)){Gt(L,function(T){xi(T,k)});return}if(L.classList){L.classList.remove(k);return}L.className.indexOf(k)>=0&&(L.className=L.className.replace(k,""))}}function js(L,k,T){if(k){if(ze(L.length)){Gt(L,function(A){js(A,k,T)});return}T?on(L,k):xi(L,k)}}var $S=/([a-z\d])([A-Z])/g;function Uu(L){return L.replace($S,"$1-$2").toLowerCase()}function Yu(L,k){return Ua(L[k])?L[k]:L.dataset?L.dataset[k]:L.getAttribute("data-".concat(Uu(k)))}function zo(L,k,T){Ua(T)?L[k]=T:L.dataset?L.dataset[k]=T:L.setAttribute("data-".concat(Uu(k)),T)}function zS(L,k){if(Ua(L[k]))try{delete L[k]}catch{L[k]=void 0}else if(L.dataset)try{delete L.dataset[k]}catch{L.dataset[k]=void 0}else L.removeAttribute("data-".concat(Uu(k)))}var kv=/\s\s*/,Cv=function(){var L=!1;if(y){var k=!1,T=function(){},A=Object.defineProperty({},"once",{get:function(){return L=!0,k},set:function($){k=$}});b.addEventListener("test",T,A),b.removeEventListener("test",T,A)}return L}();function di(L,k,T){var A=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},H=T;k.trim().split(kv).forEach(function($){if(!Cv){var z=L.listeners;z&&z[$]&&z[$][T]&&(H=z[$][T],delete z[$][T],Object.keys(z[$]).length===0&&delete z[$],Object.keys(z).length===0&&delete L.listeners)}L.removeEventListener($,H,A)})}function Jn(L,k,T){var A=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},H=T;k.trim().split(kv).forEach(function($){if(A.once&&!Cv){var z=L.listeners,re=z===void 0?{}:z;H=function(){delete re[$][T],L.removeEventListener($,H,A);for(var ye=arguments.length,ue=new Array(ye),de=0;deMath.abs(T)&&(T=Ce)})}),T}function pr(L,k){var T=L.pageX,A=L.pageY,H={endX:T,endY:A};return k?H:i({startX:T,startY:A},H)}function WS(L){var k=0,T=0,A=0;return Gt(L,function(H){var $=H.startX,z=H.startY;k+=$,T+=z,A+=1}),k/=A,T/=A,{pageX:k,pageY:T}}function ra(L){var k=L.aspectRatio,T=L.height,A=L.width,H=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"contain",$=$n(A),z=$n(T);if($&&z){var re=T*k;H==="contain"&&re>A||H==="cover"&&re90?{width:Ae,height:re}:{width:re,height:Ae}}function YS(L,k,T,A){var H=k.aspectRatio,$=k.naturalWidth,z=k.naturalHeight,re=k.rotate,Ae=re===void 0?0:re,ye=k.scaleX,ue=ye===void 0?1:ye,de=k.scaleY,Ce=de===void 0?1:de,nt=T.aspectRatio,et=T.naturalWidth,Vt=T.naturalHeight,ct=A.fillColor,en=ct===void 0?"transparent":ct,ln=A.imageSmoothingEnabled,Xt=ln===void 0?!0:ln,Bi=A.imageSmoothingQuality,zn=Bi===void 0?"low":Bi,De=A.maxWidth,ut=De===void 0?1/0:De,tn=A.maxHeight,Qn=tn===void 0?1/0:tn,Ni=A.minWidth,Ya=Ni===void 0?0:Ni,Ka=A.minHeight,ca=Ka===void 0?0:Ka,Si=document.createElement("canvas"),Mn=Si.getContext("2d"),Ga=ra({aspectRatio:nt,width:ut,height:Qn}),yr=ra({aspectRatio:nt,width:Ya,height:ca},"cover"),Gu=Math.min(Ga.width,Math.max(yr.width,et)),Xu=Math.min(Ga.height,Math.max(yr.height,Vt)),Mv=ra({aspectRatio:H,width:ut,height:Qn}),Ev=ra({aspectRatio:H,width:Ya,height:ca},"cover"),Dv=Math.min(Mv.width,Math.max(Ev.width,$)),Ov=Math.min(Mv.height,Math.max(Ev.height,z)),ow=[-Dv/2,-Ov/2,Dv,Ov];return Si.width=Hs(Gu),Si.height=Hs(Xu),Mn.fillStyle=en,Mn.fillRect(0,0,Gu,Xu),Mn.save(),Mn.translate(Gu/2,Xu/2),Mn.rotate(Ae*Math.PI/180),Mn.scale(ue,Ce),Mn.imageSmoothingEnabled=Xt,Mn.imageSmoothingQuality=zn,Mn.drawImage.apply(Mn,[L].concat(c(ow.map(function(lw){return Math.floor(Hs(lw))})))),Mn.restore(),Si}var Av=String.fromCharCode;function KS(L,k,T){var A="";T+=k;for(var H=k;H0;)T.push(Av.apply(null,wv(H.subarray(0,A)))),H=H.subarray(A);return"data:".concat(k,";base64,").concat(btoa(T.join("")))}function ZS(L){var k=new DataView(L),T;try{var A,H,$;if(k.getUint8(0)===255&&k.getUint8(1)===216)for(var z=k.byteLength,re=2;re+1=8&&($=ye+de)}}}if($){var Ce=k.getUint16($,A),nt,et;for(et=0;et=0?$:An),height:Math.max(A.offsetHeight,z>=0?z:Li)};this.containerData=re,la(H,{width:re.width,height:re.height}),on(k,ee),xi(H,ee)},initCanvas:function(){var k=this.containerData,T=this.imageData,A=this.options.viewMode,H=Math.abs(T.rotate)%180===90,$=H?T.naturalHeight:T.naturalWidth,z=H?T.naturalWidth:T.naturalHeight,re=$/z,Ae=k.width,ye=k.height;k.height*re>k.width?A===3?Ae=k.height*re:ye=k.width/re:A===3?ye=k.width/re:Ae=k.height*re;var ue={aspectRatio:re,naturalWidth:$,naturalHeight:z,width:Ae,height:ye};this.canvasData=ue,this.limited=A===1||A===2,this.limitCanvas(!0,!0),ue.width=Math.min(Math.max(ue.width,ue.minWidth),ue.maxWidth),ue.height=Math.min(Math.max(ue.height,ue.minHeight),ue.maxHeight),ue.left=(k.width-ue.width)/2,ue.top=(k.height-ue.height)/2,ue.oldLeft=ue.left,ue.oldTop=ue.top,this.initialCanvasData=It({},ue)},limitCanvas:function(k,T){var A=this.options,H=this.containerData,$=this.canvasData,z=this.cropBoxData,re=A.viewMode,Ae=$.aspectRatio,ye=this.cropped&&z;if(k){var ue=Number(A.minCanvasWidth)||0,de=Number(A.minCanvasHeight)||0;re>1?(ue=Math.max(ue,H.width),de=Math.max(de,H.height),re===3&&(de*Ae>ue?ue=de*Ae:de=ue/Ae)):re>0&&(ue?ue=Math.max(ue,ye?z.width:0):de?de=Math.max(de,ye?z.height:0):ye&&(ue=z.width,de=z.height,de*Ae>ue?ue=de*Ae:de=ue/Ae));var Ce=ra({aspectRatio:Ae,width:ue,height:de});ue=Ce.width,de=Ce.height,$.minWidth=ue,$.minHeight=de,$.maxWidth=1/0,$.maxHeight=1/0}if(T)if(re>(ye?0:1)){var nt=H.width-$.width,et=H.height-$.height;$.minLeft=Math.min(0,nt),$.minTop=Math.min(0,et),$.maxLeft=Math.max(0,nt),$.maxTop=Math.max(0,et),ye&&this.limited&&($.minLeft=Math.min(z.left,z.left+(z.width-$.width)),$.minTop=Math.min(z.top,z.top+(z.height-$.height)),$.maxLeft=z.left,$.maxTop=z.top,re===2&&($.width>=H.width&&($.minLeft=Math.min(0,nt),$.maxLeft=Math.max(0,nt)),$.height>=H.height&&($.minTop=Math.min(0,et),$.maxTop=Math.max(0,et))))}else $.minLeft=-$.width,$.minTop=-$.height,$.maxLeft=H.width,$.maxTop=H.height},renderCanvas:function(k,T){var A=this.canvasData,H=this.imageData;if(T){var $=US({width:H.naturalWidth*Math.abs(H.scaleX||1),height:H.naturalHeight*Math.abs(H.scaleY||1),degree:H.rotate||0}),z=$.width,re=$.height,Ae=A.width*(z/A.naturalWidth),ye=A.height*(re/A.naturalHeight);A.left-=(Ae-A.width)/2,A.top-=(ye-A.height)/2,A.width=Ae,A.height=ye,A.aspectRatio=z/re,A.naturalWidth=z,A.naturalHeight=re,this.limitCanvas(!0,!1)}(A.width>A.maxWidth||A.widthA.maxHeight||A.heightT.width?$.height=$.width/A:$.width=$.height*A),this.cropBoxData=$,this.limitCropBox(!0,!0),$.width=Math.min(Math.max($.width,$.minWidth),$.maxWidth),$.height=Math.min(Math.max($.height,$.minHeight),$.maxHeight),$.width=Math.max($.minWidth,$.width*H),$.height=Math.max($.minHeight,$.height*H),$.left=T.left+(T.width-$.width)/2,$.top=T.top+(T.height-$.height)/2,$.oldLeft=$.left,$.oldTop=$.top,this.initialCropBoxData=It({},$)},limitCropBox:function(k,T){var A=this.options,H=this.containerData,$=this.canvasData,z=this.cropBoxData,re=this.limited,Ae=A.aspectRatio;if(k){var ye=Number(A.minCropBoxWidth)||0,ue=Number(A.minCropBoxHeight)||0,de=re?Math.min(H.width,$.width,$.width+$.left,H.width-$.left):H.width,Ce=re?Math.min(H.height,$.height,$.height+$.top,H.height-$.top):H.height;ye=Math.min(ye,H.width),ue=Math.min(ue,H.height),Ae&&(ye&&ue?ue*Ae>ye?ue=ye/Ae:ye=ue*Ae:ye?ue=ye/Ae:ue&&(ye=ue*Ae),Ce*Ae>de?Ce=de/Ae:de=Ce*Ae),z.minWidth=Math.min(ye,de),z.minHeight=Math.min(ue,Ce),z.maxWidth=de,z.maxHeight=Ce}T&&(re?(z.minLeft=Math.max(0,$.left),z.minTop=Math.max(0,$.top),z.maxLeft=Math.min(H.width,$.left+$.width)-z.width,z.maxTop=Math.min(H.height,$.top+$.height)-z.height):(z.minLeft=0,z.minTop=0,z.maxLeft=H.width-z.width,z.maxTop=H.height-z.height))},renderCropBox:function(){var k=this.options,T=this.containerData,A=this.cropBoxData;(A.width>A.maxWidth||A.widthA.maxHeight||A.height=T.width&&A.height>=T.height?V:P),la(this.cropBox,It({width:A.width,height:A.height},Ho({translateX:A.left,translateY:A.top}))),this.cropped&&this.limited&&this.limitCanvas(!0,!0),this.disabled||this.output()},output:function(){this.preview(),Ws(this.element,X,this.getData())}},ew={initPreview:function(){var k=this.element,T=this.crossOrigin,A=this.options.preview,H=T?this.crossOriginUrl:this.url,$=k.alt||"The image to preview",z=document.createElement("img");if(T&&(z.crossOrigin=T),z.src=H,z.alt=$,this.viewBox.appendChild(z),this.viewBoxImage=z,!!A){var re=A;typeof A=="string"?re=k.ownerDocument.querySelectorAll(A):A.querySelector&&(re=[A]),this.previews=re,Gt(re,function(Ae){var ye=document.createElement("img");zo(Ae,te,{width:Ae.offsetWidth,height:Ae.offsetHeight,html:Ae.innerHTML}),T&&(ye.crossOrigin=T),ye.src=H,ye.alt=$,ye.style.cssText='display:block;width:100%;height:auto;min-width:0!important;min-height:0!important;max-width:none!important;max-height:none!important;image-orientation:0deg!important;"',Ae.innerHTML="",Ae.appendChild(ye)})}},resetPreview:function(){Gt(this.previews,function(k){var T=Yu(k,te);la(k,{width:T.width,height:T.height}),k.innerHTML=T.html,zS(k,te)})},preview:function(){var k=this.imageData,T=this.canvasData,A=this.cropBoxData,H=A.width,$=A.height,z=k.width,re=k.height,Ae=A.left-T.left-k.left,ye=A.top-T.top-k.top;!this.cropped||this.disabled||(la(this.viewBoxImage,It({width:z,height:re},Ho(It({translateX:-Ae,translateY:-ye},k)))),Gt(this.previews,function(ue){var de=Yu(ue,te),Ce=de.width,nt=de.height,et=Ce,Vt=nt,ct=1;H&&(ct=Ce/H,Vt=$*ct),$&&Vt>nt&&(ct=nt/$,et=H*ct,Vt=nt),la(ue,{width:et,height:Vt}),la(ue.getElementsByTagName("img")[0],It({width:z*ct,height:re*ct},Ho(It({translateX:-Ae*ct,translateY:-ye*ct},k))))}))}},tw={bind:function(){var k=this.element,T=this.options,A=this.cropper;Tn(T.cropstart)&&Jn(k,R,T.cropstart),Tn(T.cropmove)&&Jn(k,E,T.cropmove),Tn(T.cropend)&&Jn(k,Ie,T.cropend),Tn(T.crop)&&Jn(k,X,T.crop),Tn(T.zoom)&&Jn(k,Fe,T.zoom),Jn(A,ke,this.onCropStart=this.cropStart.bind(this)),T.zoomable&&T.zoomOnWheel&&Jn(A,Le,this.onWheel=this.wheel.bind(this),{passive:!1,capture:!0}),T.toggleDragModeOnDblclick&&Jn(A,F,this.onDblclick=this.dblclick.bind(this)),Jn(k.ownerDocument,xe,this.onCropMove=this.cropMove.bind(this)),Jn(k.ownerDocument,Ve,this.onCropEnd=this.cropEnd.bind(this)),T.responsive&&Jn(window,Ne,this.onResize=this.resize.bind(this))},unbind:function(){var k=this.element,T=this.options,A=this.cropper;Tn(T.cropstart)&&di(k,R,T.cropstart),Tn(T.cropmove)&&di(k,E,T.cropmove),Tn(T.cropend)&&di(k,Ie,T.cropend),Tn(T.crop)&&di(k,X,T.crop),Tn(T.zoom)&&di(k,Fe,T.zoom),di(A,ke,this.onCropStart),T.zoomable&&T.zoomOnWheel&&di(A,Le,this.onWheel,{passive:!1,capture:!0}),T.toggleDragModeOnDblclick&&di(A,F,this.onDblclick),di(k.ownerDocument,xe,this.onCropMove),di(k.ownerDocument,Ve,this.onCropEnd),T.responsive&&di(window,Ne,this.onResize)}},nw={resize:function(){if(!this.disabled){var k=this.options,T=this.container,A=this.containerData,H=T.offsetWidth/A.width,$=T.offsetHeight/A.height,z=Math.abs(H-1)>Math.abs($-1)?H:$;if(z!==1){var re,Ae;k.restore&&(re=this.getCanvasData(),Ae=this.getCropBoxData()),this.render(),k.restore&&(this.setCanvasData(Gt(re,function(ye,ue){re[ue]=ye*z})),this.setCropBoxData(Gt(Ae,function(ye,ue){Ae[ue]=ye*z})))}}},dblclick:function(){this.disabled||this.options.dragMode===ae||this.setDragMode(FS(this.dragBox,B)?Q:U)},wheel:function(k){var T=this,A=Number(this.options.wheelZoomRatio)||.1,H=1;this.disabled||(k.preventDefault(),!this.wheeling&&(this.wheeling=!0,setTimeout(function(){T.wheeling=!1},50),k.deltaY?H=k.deltaY>0?1:-1:k.wheelDelta?H=-k.wheelDelta/120:k.detail&&(H=k.detail>0?1:-1),this.zoom(-H*A,k)))},cropStart:function(k){var T=k.buttons,A=k.button;if(!(this.disabled||(k.type==="mousedown"||k.type==="pointerdown"&&k.pointerType==="mouse")&&(ze(T)&&T!==1||ze(A)&&A!==0||k.ctrlKey))){var H=this.options,$=this.pointers,z;k.changedTouches?Gt(k.changedTouches,function(re){$[re.identifier]=pr(re)}):$[k.pointerId||0]=pr(k),Object.keys($).length>1&&H.zoomable&&H.zoomOnTouch?z=I:z=Yu(k.target,Oe),qe.test(z)&&Ws(this.element,R,{originalEvent:k,action:z})!==!1&&(k.preventDefault(),this.action=z,this.cropping=!1,z===C&&(this.cropping=!0,on(this.dragBox,ge)))}},cropMove:function(k){var T=this.action;if(!(this.disabled||!T)){var A=this.pointers;k.preventDefault(),Ws(this.element,E,{originalEvent:k,action:T})!==!1&&(k.changedTouches?Gt(k.changedTouches,function(H){It(A[H.identifier]||{},pr(H,!0))}):It(A[k.pointerId||0]||{},pr(k,!0)),this.change(k))}},cropEnd:function(k){if(!this.disabled){var T=this.action,A=this.pointers;k.changedTouches?Gt(k.changedTouches,function(H){delete A[H.identifier]}):delete A[k.pointerId||0],T&&(k.preventDefault(),Object.keys(A).length||(this.action=""),this.cropping&&(this.cropping=!1,js(this.dragBox,ge,this.cropped&&this.options.modal)),Ws(this.element,Ie,{originalEvent:k,action:T}))}}},iw={change:function(k){var T=this.options,A=this.canvasData,H=this.containerData,$=this.cropBoxData,z=this.pointers,re=this.action,Ae=T.aspectRatio,ye=$.left,ue=$.top,de=$.width,Ce=$.height,nt=ye+de,et=ue+Ce,Vt=0,ct=0,en=H.width,ln=H.height,Xt=!0,Bi;!Ae&&k.shiftKey&&(Ae=de&&Ce?de/Ce:1),this.limited&&(Vt=$.minLeft,ct=$.minTop,en=Vt+Math.min(H.width,A.width,A.left+A.width),ln=ct+Math.min(H.height,A.height,A.top+A.height));var zn=z[Object.keys(z)[0]],De={x:zn.endX-zn.startX,y:zn.endY-zn.startY},ut=function(Qn){switch(Qn){case M:nt+De.x>en&&(De.x=en-nt);break;case O:ye+De.xln&&(De.y=ln-et);break}};switch(re){case P:ye+=De.x,ue+=De.y;break;case M:if(De.x>=0&&(nt>=en||Ae&&(ue<=ct||et>=ln))){Xt=!1;break}ut(M),de+=De.x,de<0&&(re=O,de=-de,ye-=de),Ae&&(Ce=de/Ae,ue+=($.height-Ce)/2);break;case N:if(De.y<=0&&(ue<=ct||Ae&&(ye<=Vt||nt>=en))){Xt=!1;break}ut(N),Ce-=De.y,ue+=De.y,Ce<0&&(re=D,Ce=-Ce,ue-=Ce),Ae&&(de=Ce*Ae,ye+=($.width-de)/2);break;case O:if(De.x<=0&&(ye<=Vt||Ae&&(ue<=ct||et>=ln))){Xt=!1;break}ut(O),de-=De.x,ye+=De.x,de<0&&(re=M,de=-de,ye-=de),Ae&&(Ce=de/Ae,ue+=($.height-Ce)/2);break;case D:if(De.y>=0&&(et>=ln||Ae&&(ye<=Vt||nt>=en))){Xt=!1;break}ut(D),Ce+=De.y,Ce<0&&(re=N,Ce=-Ce,ue-=Ce),Ae&&(de=Ce*Ae,ye+=($.width-de)/2);break;case j:if(Ae){if(De.y<=0&&(ue<=ct||nt>=en)){Xt=!1;break}ut(N),Ce-=De.y,ue+=De.y,de=Ce*Ae}else ut(N),ut(M),De.x>=0?ntct&&(Ce-=De.y,ue+=De.y):(Ce-=De.y,ue+=De.y);de<0&&Ce<0?(re=J,Ce=-Ce,de=-de,ue-=Ce,ye-=de):de<0?(re=Y,de=-de,ye-=de):Ce<0&&(re=K,Ce=-Ce,ue-=Ce);break;case Y:if(Ae){if(De.y<=0&&(ue<=ct||ye<=Vt)){Xt=!1;break}ut(N),Ce-=De.y,ue+=De.y,de=Ce*Ae,ye+=$.width-de}else ut(N),ut(O),De.x<=0?ye>Vt?(de-=De.x,ye+=De.x):De.y<=0&&ue<=ct&&(Xt=!1):(de-=De.x,ye+=De.x),De.y<=0?ue>ct&&(Ce-=De.y,ue+=De.y):(Ce-=De.y,ue+=De.y);de<0&&Ce<0?(re=K,Ce=-Ce,de=-de,ue-=Ce,ye-=de):de<0?(re=j,de=-de,ye-=de):Ce<0&&(re=J,Ce=-Ce,ue-=Ce);break;case J:if(Ae){if(De.x<=0&&(ye<=Vt||et>=ln)){Xt=!1;break}ut(O),de-=De.x,ye+=De.x,Ce=de/Ae}else ut(D),ut(O),De.x<=0?ye>Vt?(de-=De.x,ye+=De.x):De.y>=0&&et>=ln&&(Xt=!1):(de-=De.x,ye+=De.x),De.y>=0?et=0&&(nt>=en||et>=ln)){Xt=!1;break}ut(M),de+=De.x,Ce=de/Ae}else ut(D),ut(M),De.x>=0?nt=0&&et>=ln&&(Xt=!1):de+=De.x,De.y>=0?et0?re=De.y>0?K:j:De.x<0&&(ye-=de,re=De.y>0?J:Y),De.y<0&&(ue-=Ce),this.cropped||(xi(this.cropBox,ee),this.cropped=!0,this.limited&&this.limitCropBox(!0,!0));break}Xt&&($.width=de,$.height=Ce,$.left=ye,$.top=ue,this.action=re,this.renderCropBox()),Gt(z,function(tn){tn.startX=tn.endX,tn.startY=tn.endY})}},aw={crop:function(){return this.ready&&!this.cropped&&!this.disabled&&(this.cropped=!0,this.limitCropBox(!0,!0),this.options.modal&&on(this.dragBox,ge),xi(this.cropBox,ee),this.setCropBoxData(this.initialCropBoxData)),this},reset:function(){return this.ready&&!this.disabled&&(this.imageData=It({},this.initialImageData),this.canvasData=It({},this.initialCanvasData),this.cropBoxData=It({},this.initialCropBoxData),this.renderCanvas(),this.cropped&&this.renderCropBox()),this},clear:function(){return this.cropped&&!this.disabled&&(It(this.cropBoxData,{left:0,top:0,width:0,height:0}),this.cropped=!1,this.renderCropBox(),this.limitCanvas(!0,!0),this.renderCanvas(),xi(this.dragBox,ge),on(this.cropBox,ee)),this},replace:function(k){var T=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return!this.disabled&&k&&(this.isImg&&(this.element.src=k),T?(this.url=k,this.image.src=k,this.ready&&(this.viewBoxImage.src=k,Gt(this.previews,function(A){A.getElementsByTagName("img")[0].src=k}))):(this.isImg&&(this.replaced=!0),this.options.data=null,this.uncreate(),this.load(k))),this},enable:function(){return this.ready&&this.disabled&&(this.disabled=!1,xi(this.cropper,G)),this},disable:function(){return this.ready&&!this.disabled&&(this.disabled=!0,on(this.cropper,G)),this},destroy:function(){var k=this.element;return k[x]?(k[x]=void 0,this.isImg&&this.replaced&&(k.src=this.originalUrl),this.uncreate(),this):this},move:function(k){var T=arguments.length>1&&arguments[1]!==void 0?arguments[1]:k,A=this.canvasData,H=A.left,$=A.top;return this.moveTo($s(k)?k:H+Number(k),$s(T)?T:$+Number(T))},moveTo:function(k){var T=arguments.length>1&&arguments[1]!==void 0?arguments[1]:k,A=this.canvasData,H=!1;return k=Number(k),T=Number(T),this.ready&&!this.disabled&&this.options.movable&&(ze(k)&&(A.left=k,H=!0),ze(T)&&(A.top=T,H=!0),H&&this.renderCanvas(!0)),this},zoom:function(k,T){var A=this.canvasData;return k=Number(k),k<0?k=1/(1-k):k=1+k,this.zoomTo(A.width*k/A.naturalWidth,null,T)},zoomTo:function(k,T,A){var H=this.options,$=this.canvasData,z=$.width,re=$.height,Ae=$.naturalWidth,ye=$.naturalHeight;if(k=Number(k),k>=0&&this.ready&&!this.disabled&&H.zoomable){var ue=Ae*k,de=ye*k;if(Ws(this.element,Fe,{ratio:k,oldRatio:z/Ae,originalEvent:A})===!1)return this;if(A){var Ce=this.pointers,nt=Pv(this.cropper),et=Ce&&Object.keys(Ce).length?WS(Ce):{pageX:A.pageX,pageY:A.pageY};$.left-=(ue-z)*((et.pageX-nt.left-$.left)/z),$.top-=(de-re)*((et.pageY-nt.top-$.top)/re)}else zs(T)&&ze(T.x)&&ze(T.y)?($.left-=(ue-z)*((T.x-$.left)/z),$.top-=(de-re)*((T.y-$.top)/re)):($.left-=(ue-z)/2,$.top-=(de-re)/2);$.width=ue,$.height=de,this.renderCanvas(!0)}return this},rotate:function(k){return this.rotateTo((this.imageData.rotate||0)+Number(k))},rotateTo:function(k){return k=Number(k),ze(k)&&this.ready&&!this.disabled&&this.options.rotatable&&(this.imageData.rotate=k%360,this.renderCanvas(!0,!0)),this},scaleX:function(k){var T=this.imageData.scaleY;return this.scale(k,ze(T)?T:1)},scaleY:function(k){var T=this.imageData.scaleX;return this.scale(ze(T)?T:1,k)},scale:function(k){var T=arguments.length>1&&arguments[1]!==void 0?arguments[1]:k,A=this.imageData,H=!1;return k=Number(k),T=Number(T),this.ready&&!this.disabled&&this.options.scalable&&(ze(k)&&(A.scaleX=k,H=!0),ze(T)&&(A.scaleY=T,H=!0),H&&this.renderCanvas(!0,!0)),this},getData:function(){var k=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,T=this.options,A=this.imageData,H=this.canvasData,$=this.cropBoxData,z;if(this.ready&&this.cropped){z={x:$.left-H.left,y:$.top-H.top,width:$.width,height:$.height};var re=A.width/A.naturalWidth;if(Gt(z,function(ue,de){z[de]=ue/re}),k){var Ae=Math.round(z.y+z.height),ye=Math.round(z.x+z.width);z.x=Math.round(z.x),z.y=Math.round(z.y),z.width=ye-z.x,z.height=Ae-z.y}}else z={x:0,y:0,width:0,height:0};return T.rotatable&&(z.rotate=A.rotate||0),T.scalable&&(z.scaleX=A.scaleX||1,z.scaleY=A.scaleY||1),z},setData:function(k){var T=this.options,A=this.imageData,H=this.canvasData,$={};if(this.ready&&!this.disabled&&zs(k)){var z=!1;T.rotatable&&ze(k.rotate)&&k.rotate!==A.rotate&&(A.rotate=k.rotate,z=!0),T.scalable&&(ze(k.scaleX)&&k.scaleX!==A.scaleX&&(A.scaleX=k.scaleX,z=!0),ze(k.scaleY)&&k.scaleY!==A.scaleY&&(A.scaleY=k.scaleY,z=!0)),z&&this.renderCanvas(!0,!0);var re=A.width/A.naturalWidth;ze(k.x)&&($.left=k.x*re+H.left),ze(k.y)&&($.top=k.y*re+H.top),ze(k.width)&&($.width=k.width*re),ze(k.height)&&($.height=k.height*re),this.setCropBoxData($)}return this},getContainerData:function(){return this.ready?It({},this.containerData):{}},getImageData:function(){return this.sized?It({},this.imageData):{}},getCanvasData:function(){var k=this.canvasData,T={};return this.ready&&Gt(["left","top","width","height","naturalWidth","naturalHeight"],function(A){T[A]=k[A]}),T},setCanvasData:function(k){var T=this.canvasData,A=T.aspectRatio;return this.ready&&!this.disabled&&zs(k)&&(ze(k.left)&&(T.left=k.left),ze(k.top)&&(T.top=k.top),ze(k.width)?(T.width=k.width,T.height=k.width/A):ze(k.height)&&(T.height=k.height,T.width=k.height*A),this.renderCanvas(!0)),this},getCropBoxData:function(){var k=this.cropBoxData,T;return this.ready&&this.cropped&&(T={left:k.left,top:k.top,width:k.width,height:k.height}),T||{}},setCropBoxData:function(k){var T=this.cropBoxData,A=this.options.aspectRatio,H,$;return this.ready&&this.cropped&&!this.disabled&&zs(k)&&(ze(k.left)&&(T.left=k.left),ze(k.top)&&(T.top=k.top),ze(k.width)&&k.width!==T.width&&(H=!0,T.width=k.width),ze(k.height)&&k.height!==T.height&&($=!0,T.height=k.height),A&&(H?T.height=T.width/A:$&&(T.width=T.height*A)),this.renderCropBox()),this},getCroppedCanvas:function(){var k=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!this.ready||!window.HTMLCanvasElement)return null;var T=this.canvasData,A=YS(this.image,this.imageData,T,k);if(!this.cropped)return A;var H=this.getData(k.rounded),$=H.x,z=H.y,re=H.width,Ae=H.height,ye=A.width/Math.floor(T.naturalWidth);ye!==1&&($*=ye,z*=ye,re*=ye,Ae*=ye);var ue=re/Ae,de=ra({aspectRatio:ue,width:k.maxWidth||1/0,height:k.maxHeight||1/0}),Ce=ra({aspectRatio:ue,width:k.minWidth||0,height:k.minHeight||0},"cover"),nt=ra({aspectRatio:ue,width:k.width||(ye!==1?A.width:re),height:k.height||(ye!==1?A.height:Ae)}),et=nt.width,Vt=nt.height;et=Math.min(de.width,Math.max(Ce.width,et)),Vt=Math.min(de.height,Math.max(Ce.height,Vt));var ct=document.createElement("canvas"),en=ct.getContext("2d");ct.width=Hs(et),ct.height=Hs(Vt),en.fillStyle=k.fillColor||"transparent",en.fillRect(0,0,et,Vt);var ln=k.imageSmoothingEnabled,Xt=ln===void 0?!0:ln,Bi=k.imageSmoothingQuality;en.imageSmoothingEnabled=Xt,Bi&&(en.imageSmoothingQuality=Bi);var zn=A.width,De=A.height,ut=$,tn=z,Qn,Ni,Ya,Ka,ca,Si;ut<=-re||ut>zn?(ut=0,Qn=0,Ya=0,ca=0):ut<=0?(Ya=-ut,ut=0,Qn=Math.min(zn,re+ut),ca=Qn):ut<=zn&&(Ya=0,Qn=Math.min(re,zn-ut),ca=Qn),Qn<=0||tn<=-Ae||tn>De?(tn=0,Ni=0,Ka=0,Si=0):tn<=0?(Ka=-tn,tn=0,Ni=Math.min(De,Ae+tn),Si=Ni):tn<=De&&(Ka=0,Ni=Math.min(Ae,De-tn),Si=Ni);var Mn=[ut,tn,Qn,Ni];if(ca>0&&Si>0){var Ga=et/re;Mn.push(Ya*Ga,Ka*Ga,ca*Ga,Si*Ga)}return en.drawImage.apply(en,[A].concat(c(Mn.map(function(yr){return Math.floor(Hs(yr))})))),ct},setAspectRatio:function(k){var T=this.options;return!this.disabled&&!$s(k)&&(T.aspectRatio=Math.max(0,k)||NaN,this.ready&&(this.initCropBox(),this.cropped&&this.renderCropBox())),this},setDragMode:function(k){var T=this.options,A=this.dragBox,H=this.face;if(this.ready&&!this.disabled){var $=k===U,z=T.movable&&k===Q;k=$||z?k:ae,T.dragMode=k,zo(A,Oe,k),js(A,B,$),js(A,Me,z),T.cropBoxMovable||(zo(H,Oe,k),js(H,B,$),js(H,Me,z))}return this}},sw=b.Cropper,Tv=function(){function L(k){var T=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(s(this,L),!k||!Bt.test(k.tagName))throw new Error("The first argument is required and must be an or element.");this.element=k,this.options=It({},$o,zs(T)&&T),this.cropped=!1,this.disabled=!1,this.pointers={},this.ready=!1,this.reloading=!1,this.replaced=!1,this.sized=!1,this.sizing=!1,this.init()}return l(L,[{key:"init",value:function(){var T=this.element,A=T.tagName.toLowerCase(),H;if(!T[x]){if(T[x]=this,A==="img"){if(this.isImg=!0,H=T.getAttribute("src")||"",this.originalUrl=H,!H)return;H=T.src}else A==="canvas"&&window.HTMLCanvasElement&&(H=T.toDataURL());this.load(H)}}},{key:"load",value:function(T){var A=this;if(T){this.url=T,this.imageData={};var H=this.element,$=this.options;if(!$.rotatable&&!$.scalable&&($.checkOrientation=!1),!$.checkOrientation||!window.ArrayBuffer){this.clone();return}if(gt.test(T)){rt.test(T)?this.read(XS(T)):this.clone();return}var z=new XMLHttpRequest,re=this.clone.bind(this);this.reloading=!0,this.xhr=z,z.onabort=re,z.onerror=re,z.ontimeout=re,z.onprogress=function(){z.getResponseHeader("content-type")!==Ue&&z.abort()},z.onload=function(){A.read(z.response)},z.onloadend=function(){A.reloading=!1,A.xhr=null},$.checkCrossOrigin&&Iv(T)&&H.crossOrigin&&(T=Vv(T)),z.open("GET",T,!0),z.responseType="arraybuffer",z.withCredentials=H.crossOrigin==="use-credentials",z.send()}}},{key:"read",value:function(T){var A=this.options,H=this.imageData,$=ZS(T),z=0,re=1,Ae=1;if($>1){this.url=qS(T,Ue);var ye=JS($);z=ye.rotate,re=ye.scaleX,Ae=ye.scaleY}A.rotatable&&(H.rotate=z),A.scalable&&(H.scaleX=re,H.scaleY=Ae),this.clone()}},{key:"clone",value:function(){var T=this.element,A=this.url,H=T.crossOrigin,$=A;this.options.checkCrossOrigin&&Iv(A)&&(H||(H="anonymous"),$=Vv(A)),this.crossOrigin=H,this.crossOriginUrl=$;var z=document.createElement("img");H&&(z.crossOrigin=H),z.src=$||A,z.alt=T.alt||"The image to crop",this.image=z,z.onload=this.start.bind(this),z.onerror=this.stop.bind(this),on(z,le),T.parentNode.insertBefore(z,T.nextSibling)}},{key:"start",value:function(){var T=this,A=this.image;A.onload=null,A.onerror=null,this.sizing=!0;var H=b.navigator&&/(?:iPad|iPhone|iPod).*?AppleWebKit/i.test(b.navigator.userAgent),$=function(ye,ue){It(T.imageData,{naturalWidth:ye,naturalHeight:ue,aspectRatio:ye/ue}),T.initialImageData=It({},T.imageData),T.sizing=!1,T.sized=!0,T.build()};if(A.naturalWidth&&!H){$(A.naturalWidth,A.naturalHeight);return}var z=document.createElement("img"),re=document.body||document.documentElement;this.sizingImage=z,z.onload=function(){$(z.width,z.height),H||re.removeChild(z)},z.src=A.src,H||(z.style.cssText="left:0;max-height:none!important;max-width:none!important;min-height:0!important;min-width:0!important;opacity:0;position:absolute;top:0;z-index:-1;",re.appendChild(z))}},{key:"stop",value:function(){var T=this.image;T.onload=null,T.onerror=null,T.parentNode.removeChild(T),this.image=null}},{key:"build",value:function(){if(!(!this.sized||this.ready)){var T=this.element,A=this.options,H=this.image,$=T.parentNode,z=document.createElement("div");z.innerHTML=Wa;var re=z.querySelector(".".concat(x,"-container")),Ae=re.querySelector(".".concat(x,"-canvas")),ye=re.querySelector(".".concat(x,"-drag-box")),ue=re.querySelector(".".concat(x,"-crop-box")),de=ue.querySelector(".".concat(x,"-face"));this.container=$,this.cropper=re,this.canvas=Ae,this.dragBox=ye,this.cropBox=ue,this.viewBox=re.querySelector(".".concat(x,"-view-box")),this.face=de,Ae.appendChild(H),on(T,ee),$.insertBefore(re,T.nextSibling),xi(H,le),this.initPreview(),this.bind(),A.initialAspectRatio=Math.max(0,A.initialAspectRatio)||NaN,A.aspectRatio=Math.max(0,A.aspectRatio)||NaN,A.viewMode=Math.max(0,Math.min(3,Math.round(A.viewMode)))||0,on(ue,ee),A.guides||on(ue.getElementsByClassName("".concat(x,"-dashed")),ee),A.center||on(ue.getElementsByClassName("".concat(x,"-center")),ee),A.background&&on(re,"".concat(x,"-bg")),A.highlight||on(de,ce),A.cropBoxMovable&&(on(de,Me),zo(de,Oe,P)),A.cropBoxResizable||(on(ue.getElementsByClassName("".concat(x,"-line")),ee),on(ue.getElementsByClassName("".concat(x,"-point")),ee)),this.render(),this.ready=!0,this.setDragMode(A.dragMode),A.autoCrop&&this.crop(),this.setData(A.data),Tn(A.ready)&&Jn(T,pe,A.ready,{once:!0}),Ws(T,pe)}}},{key:"unbuild",value:function(){if(this.ready){this.ready=!1,this.unbind(),this.resetPreview();var T=this.cropper.parentNode;T&&T.removeChild(this.cropper),xi(this.element,ee)}}},{key:"uncreate",value:function(){this.ready?(this.unbuild(),this.ready=!1,this.cropped=!1):this.sizing?(this.sizingImage.onload=null,this.sizing=!1,this.sized=!1):this.reloading?(this.xhr.onabort=null,this.xhr.abort()):this.image&&this.stop()}}],[{key:"noConflict",value:function(){return window.Cropper=sw,L}},{key:"setDefaults",value:function(T){It($o,zs(T)&&T)}}]),L}();return It(Tv.prototype,QS,ew,tw,nw,iw,aw),Tv})})(D_);var KE=D_.exports;Object.defineProperty(E_,"__esModule",{value:!0});var Qg=YE,GE=KE,XE=qE(GE);function qE(e){return e&&e.__esModule?e:{default:e}}function ZE(e,t){var n={};for(var i in e)t.indexOf(i)>=0||Object.prototype.hasOwnProperty.call(e,i)&&(n[i]=e[i]);return n}var JE=typeof window>"u"?[String,Array]:[String,Array,Element,NodeList],QE=E_.default={render:function(){var t=this.crossorigin||void 0;return(0,Qg.h)("div",{style:this.containerStyle},[(0,Qg.h)("img",{ref:"img",src:this.src,alt:this.alt||"image",style:[{"max-width":"100%"},this.imgStyle],crossorigin:t})])},props:{containerStyle:Object,src:{type:String,default:""},alt:String,imgStyle:Object,viewMode:Number,dragMode:String,initialAspectRatio:Number,aspectRatio:Number,data:Object,preview:JE,responsive:{type:Boolean,default:!0},restore:{type:Boolean,default:!0},checkCrossOrigin:{type:Boolean,default:!0},checkOrientation:{type:Boolean,default:!0},crossorigin:{type:String},modal:{type:Boolean,default:!0},guides:{type:Boolean,default:!0},center:{type:Boolean,default:!0},highlight:{type:Boolean,default:!0},background:{type:Boolean,default:!0},autoCrop:{type:Boolean,default:!0},autoCropArea:Number,movable:{type:Boolean,default:!0},rotatable:{type:Boolean,default:!0},scalable:{type:Boolean,default:!0},zoomable:{type:Boolean,default:!0},zoomOnTouch:{type:Boolean,default:!0},zoomOnWheel:{type:Boolean,default:!0},wheelZoomRatio:Number,cropBoxMovable:{type:Boolean,default:!0},cropBoxResizable:{type:Boolean,default:!0},toggleDragModeOnDblclick:{type:Boolean,default:!0},minCanvasWidth:Number,minCanvasHeight:Number,minCropBoxWidth:Number,minCropBoxHeight:Number,minContainerWidth:Number,minContainerHeight:Number,ready:Function,cropstart:Function,cropmove:Function,cropend:Function,crop:Function,zoom:Function},mounted:function(){var t=this.$options.props;t.containerStyle,t.src,t.alt,t.imgStyle;var n=ZE(t,["containerStyle","src","alt","imgStyle"]),i={};for(var a in n)this[a]!==void 0&&(i[a]=this[a]);this.cropper=new XE.default(this.$refs.img,i)},methods:{reset:function(){return this.cropper.reset()},clear:function(){return this.cropper.clear()},initCrop:function(){return this.cropper.crop()},replace:function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return this.cropper.replace(t,n)},enable:function(){return this.cropper.enable()},disable:function(){return this.cropper.disable()},destroy:function(){return this.cropper.destroy()},move:function(t,n){return this.cropper.move(t,n)},moveTo:function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:t;return this.cropper.moveTo(t,n)},relativeZoom:function(t,n){return this.cropper.zoom(t,n)},zoomTo:function(t,n){return this.cropper.zoomTo(t,n)},rotate:function(t){return this.cropper.rotate(t)},rotateTo:function(t){return this.cropper.rotateTo(t)},scaleX:function(t){return this.cropper.scaleX(t)},scaleY:function(t){return this.cropper.scaleY(t)},scale:function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:t;return this.cropper.scale(t,n)},getData:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;return this.cropper.getData(t)},setData:function(t){return this.cropper.setData(t)},getContainerData:function(){return this.cropper.getContainerData()},getImageData:function(){return this.cropper.getImageData()},getCanvasData:function(){return this.cropper.getCanvasData()},setCanvasData:function(t){return this.cropper.setCanvasData(t)},getCropBoxData:function(){return this.cropper.getCropBoxData()},setCropBoxData:function(t){return this.cropper.setCropBoxData(t)},getCroppedCanvas:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return this.cropper.getCroppedCanvas(t)},setAspectRatio:function(t){return this.cropper.setAspectRatio(t)},setDragMode:function(t){return this.cropper.setDragMode(t)}}};const eD={props:["about"],components:{VueCropper:QE},setup(e,{emit:t}){const n=Z(null),i=Z(null),a=Z(!1),s=Z(null),o=v=>{const m=v.target.files[0];m&&m.type.includes("image")?(n.value=m,i.value=URL.createObjectURL(m),a.value=!0):alert("Please select an image file.")},l=()=>{if(s.value&&s.value.cropper){const m=s.value.cropper.getCroppedCanvas(),g=n.value&&n.value.type?n.value.type:"image/png";m.toBlob(p=>{const y=URL.createObjectURL(p);i.value=y,n.value=new File([p],".png",{type:g}),a.value=!1},g)}else console.error("Cropper instance is not available")},r=()=>!!e.about.name&&e.about.name.length>=2&&e.about.name.length<=20,c=()=>!!e.about.role&&e.about.role.length>=2&&e.about.role.length<=20,u=()=>!!e.about.description&&e.about.description.length<=250;return{saveAbout:v=>{let m=!0;(!r()||!c()||!u())&&(m=!1),m?(alert("Your About information has been saved!"),t("save-about",v)):confirm("Some fields may be incorrect. Please check!")},isNameValid:r,isPositionValid:c,isDescriptionValid:u,handleFileChange:o,upload:v=>{if(!n.value){alert("Please select a file first.");return}const m=new FormData;m.append("image",n.value),fetch("https://res-a-me-api.resilientdb.com/upload",{method:"POST",headers:{Authorization:"Bearer "+sessionStorage.getItem("access_token")},body:m}).then(g=>g.json()).then(g=>{console.log("Upload successful:",g)}).catch(g=>{console.error("Upload error:",g)})},selectedFile:n,selectedImageUrl:i,cropperDialog:a,cropperRef:s,handleFileChange:o,cropImage:l}}},tD=be("p",{class:"titletext"}," About ",-1),nD={class:"d-flex justify-center"};function iD(e,t,n,i,a,s){const o=we("v-icon"),l=we("v-row"),r=we("v-expansion-panel-title"),c=we("v-text-field"),u=we("v-col"),d=we("v-btn"),f=we("v-card-title"),v=we("vue-cropper"),m=we("v-card-text"),g=we("v-spacer"),p=we("v-card-actions"),y=we("v-card"),b=we("v-dialog"),S=we("v-expansion-panel-text"),_=we("v-expansion-panel");return me(),Tt(_,null,{default:ie(()=>[h(r,{id:"title"},{default:ie(({expanded:x})=>[h(l,{"no-gutters":"",class:"d-flex jusitfy-start"},{default:ie(()=>[tD,h(o,{class:"ml-2",size:"xx-large",icon:"mdi-information-outline"})]),_:1})]),_:1}),h(S,null,{default:ie(()=>[h(l,{"no-gutters":""},{default:ie(()=>[h(u,null,{default:ie(()=>[h(c,{class:"pa-2",modelValue:n.about.name,"onUpdate:modelValue":t[0]||(t[0]=x=>n.about.name=x),rules:[()=>!!n.about.name||"This field is required",()=>i.isNameValid()||"Name must be at least 2 characters and less than 20 characters"],counter:20,label:"Name"},null,8,["modelValue","rules"])]),_:1}),h(u,null,{default:ie(()=>[h(c,{class:"pa-2",modelValue:n.about.role,"onUpdate:modelValue":t[1]||(t[1]=x=>n.about.role=x),rules:[()=>!!n.about.role||"This field is required",()=>i.isPositionValid()||"Position must be at least 2 characters and less than 20 characters"],counter:20,label:"Job Title"},null,8,["modelValue","rules"])]),_:1})]),_:1}),h(l,{"no-gutters":""},{default:ie(()=>[h(c,{class:"pa-2",modelValue:n.about.description,"onUpdate:modelValue":t[2]||(t[2]=x=>n.about.description=x),rules:[()=>!!n.about.description||"This field is required",()=>i.isDescriptionValid()||"Introduction must be less than 250 characters"],counter:250,label:"Introduction"},null,8,["modelValue","rules"])]),_:1}),be("div",nD,[be("form",{onSubmit:t[5]||(t[5]=El((...x)=>e.uploadImage&&e.uploadImage(...x),["prevent"]))},[be("input",{type:"file",onChange:t[3]||(t[3]=(...x)=>i.handleFileChange&&i.handleFileChange(...x)),accept:"image/png"},null,32),h(d,{color:"grey-lighten-1",class:"ml-5",onClick:t[4]||(t[4]=x=>i.upload(n.about))},{default:ie(()=>[Xe("Upload IMG "),h(o,{size:"x-large",icon:"mdi-upload"})]),_:1})],32),h(b,{modelValue:i.cropperDialog,"onUpdate:modelValue":t[7]||(t[7]=x=>i.cropperDialog=x),"max-width":"500px"},{default:ie(()=>[h(y,null,{default:ie(()=>[h(f,null,{default:ie(()=>[Xe("Crop Image")]),_:1}),h(m,null,{default:ie(()=>[h(v,{ref:"cropperRef",src:i.selectedImageUrl,"aspect-ratio":1,style:{width:"100%"}},null,8,["src"])]),_:1}),h(p,null,{default:ie(()=>[h(g),h(d,{color:"primary",onClick:i.cropImage},{default:ie(()=>[Xe("Crop")]),_:1},8,["onClick"]),h(d,{color:"primary",text:"",onClick:t[6]||(t[6]=x=>i.cropperDialog=!1)},{default:ie(()=>[Xe("Cancel")]),_:1})]),_:1})]),_:1})]),_:1},8,["modelValue"]),h(d,{color:"green",class:"ml-5",onClick:t[8]||(t[8]=x=>i.saveAbout(n.about))},{default:ie(()=>[Xe("Save "),h(o,{size:"x-large",icon:"mdi-content-save"})]),_:1})])]),_:1})]),_:1})}const aD=at(eD,[["render",iD]]);const sD={props:["educations"],setup(e,{emit:t}){const n=u=>!!u.schoolName,i=u=>!!u.title,a=u=>!!u.startDate&&/\b\d{4}\/(0[1-9]|1[0-2])\b/.test(u.startDate),s=u=>!!u.endDate&&/\b\d{4}\/(0[1-9]|1[0-2])\b/.test(u.endDate),o=u=>!!u.description;return{deleteEdu:u=>{u!=-1&&t("delete-edu",u)},addNewEdu:()=>{t("add-edu")},saveEdu:u=>{let d=!0;u.forEach((f,v)=>{(!n(f)||!i(f)||!a(f)||!s(f)||!o(f))&&(d=!1)}),d?(alert("Your Education information has been saved!"),t("save-edu",u)):confirm("Some fields may be incorrect. Please check!")},isSchoolnameValid:n,isDiplomaValid:i,isDescriptionValid:o,isStartDateValid:a,isEndDateValid:s}}},oD=be("p",{class:"titletext"},"Educational Background",-1),lD={class:"d-flex justify-center"};function rD(e,t,n,i,a,s){const o=we("v-icon"),l=we("v-row"),r=we("v-expansion-panel-title"),c=we("v-text-field"),u=we("v-col"),d=we("v-btn"),f=we("v-expansion-panel-text"),v=we("v-expansion-panel");return me(),Tt(v,null,{default:ie(()=>[h(r,{id:"title"},{default:ie(({expanded:m})=>[h(l,{"no-gutters":"",class:"d-flex jusitfy-start"},{default:ie(()=>[oD,h(o,{class:"ml-2",size:"xx-large",icon:"mdi-school-outline"})]),_:1})]),_:1}),h(f,null,{default:ie(()=>[(me(!0),Te(Pe,null,At(n.educations,(m,g)=>(me(),Te("div",{key:g,class:"mb-3",style:{border:"2px solid rgb(198, 194, 194)"}},[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"11"},{default:ie(()=>[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"3"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.schoolName,"onUpdate:modelValue":p=>m.schoolName=p,rules:[()=>i.isSchoolnameValid(m)||"This field is required"],counter:20,label:"School"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,{cols:"4"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.title,"onUpdate:modelValue":p=>m.title=p,rules:[()=>i.isDiplomaValid(m)||"This field is required"],counter:20,label:"Diploma"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,null,{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.startDate,"onUpdate:modelValue":p=>m.startDate=p,rules:[()=>!!m.startDate||"This field is required",()=>i.isStartDateValid(m)||"Date must be in YYYY/MM format"],counter:10,label:"Start Date"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,null,{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.endDate,"onUpdate:modelValue":p=>m.endDate=p,rules:[()=>!!m.endDate||"This field is required",()=>i.isEndDateValid(m)||"Date must be in YYYY/MM format"],counter:10,label:"End Date"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024)]),_:2},1024),h(l,{"no-gutters":""},{default:ie(()=>[h(c,{class:"pl-2 pr-2",modelValue:m.description,"onUpdate:modelValue":p=>m.description=p,rules:[()=>i.isDescriptionValid(m)||"This field is required"],counter:200,label:"Description"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024)]),_:2},1024),h(u,{class:"button-container mr-2"},{default:ie(()=>[h(d,{onClick:p=>i.deleteEdu(g),color:"red-lighten-2"},{default:ie(()=>[h(o,{size:"x-large",icon:"mdi-trash-can"})]),_:2},1032,["onClick"])]),_:2},1024)]),_:2},1024)]))),128)),be("div",lD,[h(d,{color:"grey-lighten-1",onClick:t[0]||(t[0]=m=>i.addNewEdu())},{default:ie(()=>[Xe("Add more "),h(o,{size:"x-large",icon:"mdi-plus-thick"})]),_:1}),h(d,{class:"ml-5",color:"green",onClick:t[1]||(t[1]=m=>i.saveEdu(n.educations))},{default:ie(()=>[Xe("Save "),h(o,{size:"x-large",icon:"mdi-content-save"})]),_:1})])]),_:1})]),_:1})}const cD=at(sD,[["render",rD]]);const uD={props:["professions"],setup(e,{emit:t}){const n=u=>!!u.company,i=u=>!!u.title,a=u=>!!u.startDate&&/\b\d{4}\/(0[1-9]|1[0-2])\b/.test(u.startDate),s=u=>!!u.endDate&&/\b\d{4}\/(0[1-9]|1[0-2])\b/.test(u.endDate),o=u=>!!u.description;return{deletePro:u=>{u!=-1&&t("delete-pro",u)},addNewPro:()=>{t("add-pro")},savePro:u=>{let d=!0;u.forEach((f,v)=>{(!n(f)||!i(f)||!a(f)||!s(f)||!o(f))&&(d=!1)}),d?(alert("Your Profession information has been saved!"),t("save-pro",u)):confirm("Some fields may be incorrect. Please check!")},isCompanyValid:n,isPositionValid:i,isDescriptionValid:o,isStartDateValid:a,isEndDateValid:s}}},dD=be("p",{class:"titletext"},"Professional Experience",-1),fD={class:"d-flex justify-center"};function hD(e,t,n,i,a,s){const o=we("v-icon"),l=we("v-row"),r=we("v-expansion-panel-title"),c=we("v-text-field"),u=we("v-col"),d=we("v-btn"),f=we("v-expansion-panel-text"),v=we("v-expansion-panel");return me(),Tt(v,null,{default:ie(()=>[h(r,{id:"title"},{default:ie(({expanded:m})=>[h(l,{"no-gutters":"",class:"d-flex jusitfy-start"},{default:ie(()=>[dD,h(o,{class:"ml-2",size:"xx-large",icon:"mdi-briefcase-outline"})]),_:1})]),_:1}),h(f,null,{default:ie(()=>[(me(!0),Te(Pe,null,At(n.professions,(m,g)=>(me(),Te("div",{key:g,class:"mb-3",style:{border:"2px solid rgb(198, 194, 194)"}},[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"11"},{default:ie(()=>[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"3"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.company,"onUpdate:modelValue":p=>m.company=p,rules:[()=>i.isCompanyValid(m)||"This field is required"],counter:20,label:"Company"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,{cols:"4"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.title,"onUpdate:modelValue":p=>m.title=p,rules:[()=>i.isPositionValid(m)||"This field is required"],counter:30,label:"Position"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,null,{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.startDate,"onUpdate:modelValue":p=>m.startDate=p,rules:[()=>!!m.startDate||"This field is required",()=>i.isStartDateValid(m)||"Date must be in YYYY/MM format"],counter:10,label:"Start Date"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,null,{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.endDate,"onUpdate:modelValue":p=>m.endDate=p,rules:[()=>!!m.endDate||"This field is required",()=>i.isEndDateValid(m)||"Date must be in YYYY/MM format"],counter:10,label:"End Date"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024)]),_:2},1024),h(l,{"no-gutters":""},{default:ie(()=>[h(c,{class:"pl-2 pr-2",modelValue:m.description,"onUpdate:modelValue":p=>m.description=p,rules:[()=>i.isDescriptionValid(m)||"This field is required"],counter:300,label:"Description"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024)]),_:2},1024),h(u,{class:"button-container"},{default:ie(()=>[h(d,{onClick:p=>i.deletePro(g),color:"red-lighten-2"},{default:ie(()=>[h(o,{size:"x-large",icon:"mdi-trash-can"})]),_:2},1032,["onClick"])]),_:2},1024)]),_:2},1024)]))),128)),be("div",fD,[h(d,{color:"grey-lighten-1",onClick:t[0]||(t[0]=m=>i.addNewPro())},{default:ie(()=>[Xe("Add more "),h(o,{size:"x-large",icon:"mdi-plus-thick"})]),_:1}),h(d,{class:"ml-5",color:"green",onClick:t[1]||(t[1]=m=>i.savePro(n.professions))},{default:ie(()=>[Xe("Save "),h(o,{size:"x-large",icon:"mdi-content-save"})]),_:1})])]),_:1})]),_:1})}const vD=at(uD,[["render",hD]]);const mD={props:["certifications"],setup(e,{emit:t}){const n=c=>!!c.title,i=c=>!!c.company_school,a=c=>!!c.date&&/\b\d{4}\/(0[1-9]|1[0-2])\b/.test(c.date),s=c=>!!c.description;return{deleteCer:c=>{c!=-1&&t("delete-cer",c)},addNewCer:()=>{t("add-cer")},saveCer:c=>{let u=!0;c.forEach((d,f)=>{(!n(d)||!i(d)||!a(d)||!s(d))&&(u=!1)}),u?(alert("Your Certificate information has been saved!"),t("save-cer",c)):confirm("Some fields may be incorrect. Please check!")},isTitleValid:n,isCompanySchoolValid:i,isDescriptionValid:s,isDateValid:a}}},gD=be("p",{class:"titletext"},"Certification",-1),pD={class:"d-flex justify-center"};function yD(e,t,n,i,a,s){const o=we("v-icon"),l=we("v-row"),r=we("v-expansion-panel-title"),c=we("v-text-field"),u=we("v-col"),d=we("v-btn"),f=we("v-expansion-panel-text"),v=we("v-expansion-panel");return me(),Tt(v,null,{default:ie(()=>[h(r,{id:"title"},{default:ie(({expanded:m})=>[h(l,{"no-gutters":"",class:"d-flex jusitfy-start"},{default:ie(()=>[gD,h(o,{class:"ml-2",size:"xx-large",icon:"mdi-certificate-outline"})]),_:1})]),_:1}),h(f,null,{default:ie(()=>[(me(!0),Te(Pe,null,At(n.certifications,(m,g)=>(me(),Te("div",{key:g,class:"mb-3",style:{border:"2px solid rgb(198, 194, 194)"}},[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"11"},{default:ie(()=>[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"3"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.title,"onUpdate:modelValue":p=>m.title=p,rules:[()=>i.isTitleValid(m)||"This field is required"],counter:40,label:"Title"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,{cols:"4"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.date,"onUpdate:modelValue":p=>m.date=p,rules:[()=>!!m.date||"This field is required",()=>i.isDateValid(m)||"Date must be in YYYY/MM format"],counter:20,label:"Date"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,null,{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.company_school,"onUpdate:modelValue":p=>m.company_school=p,rules:[()=>i.isCompanySchoolValid(m)||"This field is required"],counter:10,label:"Company/School"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024)]),_:2},1024),h(l,{"no-gutters":""},{default:ie(()=>[h(c,{class:"pl-2 pr-2",modelValue:m.description,"onUpdate:modelValue":p=>m.description=p,rules:[()=>i.isDescriptionValid(m)||"This field is required"],counter:200,label:"Description"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024)]),_:2},1024),h(u,{class:"button-container"},{default:ie(()=>[h(d,{onClick:p=>i.deleteCer(g),color:"red-lighten-2"},{default:ie(()=>[h(o,{size:"x-large",icon:"mdi-trash-can"})]),_:2},1032,["onClick"])]),_:2},1024)]),_:2},1024)]))),128)),be("div",pD,[h(d,{color:"grey-lighten-1",onClick:t[0]||(t[0]=m=>i.addNewCer())},{default:ie(()=>[Xe("Add more "),h(o,{size:"x-large",icon:"mdi-plus-thick"})]),_:1}),h(d,{class:"ml-5",color:"green",onClick:t[1]||(t[1]=m=>i.saveCer(n.certifications))},{default:ie(()=>[Xe("Save "),h(o,{size:"x-large",icon:"mdi-content-save"})]),_:1})])]),_:1})]),_:1})}const bD=at(mD,[["render",yD]]);const _D={props:["awards"],setup(e,{emit:t}){const n=c=>!!c.title,i=c=>!!c.company_school,a=c=>!!c.date&&/\b\d{4}\/(0[1-9]|1[0-2])\b/.test(c.date),s=c=>!!c.description;return{deleteAward:c=>{c!=-1&&t("delete-award",c)},addNewAward:()=>{t("add-award")},saveAward:c=>{let u=!0;c.forEach((d,f)=>{(!n(d)||!i(d)||!s(d))&&(u=!1)}),u?(alert("Your Award information has been saved!"),t("save-award",c)):confirm("Some fields may be incorrect. Please check!")},isTitleValid:n,isCompanySchoolValid:i,isDescriptionValid:s,isDateValid:a}}},xD=be("p",{class:"titletext"},"Award",-1),SD={class:"d-flex justify-center"};function wD(e,t,n,i,a,s){const o=we("v-icon"),l=we("v-row"),r=we("v-expansion-panel-title"),c=we("v-text-field"),u=we("v-col"),d=we("v-btn"),f=we("v-expansion-panel-text"),v=we("v-expansion-panel");return me(),Tt(v,null,{default:ie(()=>[h(r,{id:"title"},{default:ie(({expanded:m})=>[h(l,{"no-gutters":"",class:"d-flex jusitfy-start"},{default:ie(()=>[xD,h(o,{class:"ml-2",size:"xx-large",icon:"mdi-license"})]),_:1})]),_:1}),h(f,null,{default:ie(()=>[(me(!0),Te(Pe,null,At(n.awards,(m,g)=>(me(),Te("div",{key:g,class:"mb-3",style:{border:"2px solid rgb(198, 194, 194)"}},[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"11"},{default:ie(()=>[h(l,{"no-gutters":""},{default:ie(()=>[h(u,{cols:"4"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.title,"onUpdate:modelValue":p=>m.title=p,rules:[()=>i.isTitleValid(m)||"This field is required"],counter:40,label:"Title"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,{cols:"4"},{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.date,"onUpdate:modelValue":p=>m.date=p,rules:[()=>!!m.date||"This field is required",()=>i.isDateValid(m)||"Date must be in YYYY/MM format"],counter:20,label:"Date"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024),h(u,null,{default:ie(()=>[h(c,{class:"pa-2",modelValue:m.company_school,"onUpdate:modelValue":p=>m.company_school=p,rules:[()=>i.isCompanySchoolValid(m)||"This field is required"],counter:10,label:"Company/School"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024)]),_:2},1024),h(l,{"no-gutters":""},{default:ie(()=>[h(c,{class:"pl-2 pr-2",modelValue:m.description,"onUpdate:modelValue":p=>m.description=p,rules:[()=>i.isDescriptionValid(m)||"This field is required"],counter:200,label:"Description"},null,8,["modelValue","onUpdate:modelValue","rules"])]),_:2},1024)]),_:2},1024),h(u,{class:"button-container"},{default:ie(()=>[h(d,{onClick:p=>i.deleteAward(g),color:"red-lighten-2"},{default:ie(()=>[h(o,{size:"x-large",icon:"mdi-trash-can"})]),_:2},1032,["onClick"])]),_:2},1024)]),_:2},1024)]))),128)),be("div",SD,[h(d,{color:"grey-lighten-1",onClick:t[0]||(t[0]=m=>i.addNewAward())},{default:ie(()=>[Xe("Add more "),h(o,{size:"x-large",icon:"mdi-plus-thick"})]),_:1}),h(d,{class:"ml-5",color:"green",onClick:t[1]||(t[1]=m=>i.saveAward(n.awards))},{default:ie(()=>[Xe("Save "),h(o,{size:"x-large",icon:"mdi-content-save"})]),_:1})])]),_:1})]),_:1})}const kD=at(_D,[["render",wD]]);ph();const CD={components:{Skill:jE,About:aD,Education:cD,Profession:vD,Certification:bD,Award:kD},data:()=>({panel:[0],defaultSkill:{id:0,title:"New skill",description:"add your description"},defaultEdu:{id:0,title:"New diploma",schoolName:"New shool name",startDate:"2023/01",endDate:"2023/12",description:"add your description"},defaultPro:{id:0,title:"New position",company:"New company name",startDate:"2023/01",endDate:"2023/12",description:"add your description"},defaultCer:{id:0,title:"New certification",date:"2023/01",company_school:"New company name or school name",description:"add your description"},defaultAward:{id:0,title:"New award",date:"2023/01",company_school:"New company name or school name",description:"add your description"}}),setup(){const e=Z([]),t=Z([]),n=Z([]),i=Z([]),a=Z([]),s=Z([]),o=Z([]),l=Z([]),r=Z([]),c=Z([]),u=Z([]),d=Z([]);return _t(async()=>{try{const v=await(await fetch("https://res-a-me-api.resilientdb.com/loadResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*",Authorization:"Bearer "+sessionStorage.getItem("access_token")},body:JSON.stringify({category:"skills"})})).json();r.value=v;const m=v.items.abilities.map((B,G)=>{const{faIcon:ee,locales:le}=B,{title:ce,description:ge}=le.en;return{id:G,title:ce||"",description:ge||""}});e.value=m;const p=await(await fetch("https://res-a-me-api.resilientdb.com/loadResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*",Authorization:"Bearer "+sessionStorage.getItem("access_token")},body:JSON.stringify({category:"cover"})})).json();o.value=p;const b=await(await fetch("https://res-a-me-api.resilientdb.com/loadResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*",Authorization:"Bearer "+sessionStorage.getItem("access_token")},body:JSON.stringify({category:"profile"})})).json();l.value=b;const S=p.locales.en.bio,_=b.name,x=b.profilePictureUrl,P=b.locales.en.role,C={name:_,profilePictureUrl:x,role:P,description:S};t.value=C;const I=await(await fetch("https://res-a-me-api.resilientdb.com/loadResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*",Authorization:"Bearer "+sessionStorage.getItem("access_token")},body:JSON.stringify({category:"education"})})).json();c.value=I;const M=I.items.map(B=>({title:B.locales.en.title,schoolName:B.place,startDate:B.period[0],endDate:B.period[1],description:B.locales.en.description}));n.value=M;const D=await(await fetch("https://res-a-me-api.resilientdb.com/loadResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*",Authorization:"Bearer "+sessionStorage.getItem("access_token")},body:JSON.stringify({category:"experience"})})).json();u.value=D;const N=D.items.map(B=>({title:B.locales.en.title,company:B.place,startDate:B.period[0],endDate:B.period[1],description:B.locales.en.description}));i.value=N;const Y=await(await fetch("https://res-a-me-api.resilientdb.com/loadResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*",Authorization:"Bearer "+sessionStorage.getItem("access_token")},body:JSON.stringify({category:"achievements"})})).json();d.value=Y;const K=Y.items.certifications.map(B=>({title:B.locales.en.title,date:B.date,company_school:B.place,description:B.locales.en.description})),J=Y.items.awards.map(B=>({title:B.locales.en.title,date:B.date,company_school:B.place,description:B.locales.en.description}));a.value=K,s.value=J}catch(f){console.error("Error fetching data:",f)}}),{skills:e,about:t,educations:n,professions:i,certifications:a,awards:s,cover_data_old:o,profile_data_old:l,skill_data_old:r,edu_data_old:c,pro_data_old:u,achi_data_old:d}},methods:{async returnButton(){if(confirm("Are you sure you want to leave this page? Make sure you have saved your changes!")){let e="";try{const n=await(await fetch("https://res-a-me-api.resilientdb.com/loadUser",{method:"GET",headers:{"Content-type":"application/json; charset=UTF-8",Authorization:"Bearer "+sessionStorage.getItem("access_token")}})).json();n.status===200&&(e=n.logged_in_as)}catch(t){console.error("Error fetching user data:",t)}try{const n=await(await fetch("https://res-a-me-api.resilientdb.com/updateResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8"},body:JSON.stringify({email:e})})).json();n.status!==200&&console.error("Error fetching user resume: ",n.message)}catch{console.error("Error fetching user resume: ",error)}this.$router.push({path:"/home"}).then(()=>window.location.reload(!0)).then(()=>window.location.reload(!0))}},handleDeleteSkill(e){confirm("Are you sure you want to delete this item?")&&(this.skills.splice(e,1),this.skills.forEach((t,n)=>{t.id=n}))},handleAddSkill(){const e={...this.defaultSkill};e.id=this.skills.length,this.skills.push(e),this.skills.forEach((t,n)=>{t.id=n})},handleSaveSkill(e){this.skills=e,this.skill_data_old.items.abilities=[];for(let t=0;t{t.id=n}))},handleAddEdu(){const e={...this.defaultEdu};e.id=this.educations.length,this.educations.push(e),this.educations.forEach((t,n)=>{t.id=n})},handleSaveEdu(e){this.educations=e,this.edu_data_old.items=[];for(let t=0;t{t.id=n}))},handleAddPro(){const e={...this.defaultPro};e.id=this.professions.length,this.professions.push(e),this.professions.forEach((t,n)=>{t.id=n})},handleSavePro(e){this.professions=e,this.pro_data_old.items=[];for(let t=0;t{t.id=n}))},handleAddCer(){const e={...this.defaultCer};e.id=this.certifications.length,this.certifications.push(e),this.certifications.forEach((t,n)=>{t.id=n})},async handleSaveCer(e){this.certifications=e,this.achi_data_old.items.certifications=[];for(let t=0;t{t.id=n}))},handleAddAward(){const e={...this.defaultAward};e.id=this.awards.length,this.awards.push(e),this.awards.forEach((t,n)=>{t.id=n})},async handleSaveAward(e){this.awards=e,this.achi_data_old.items.awards=[];for(let t=0;t[h(r,{align:"center"},{default:ie(()=>[be("p",ID,[Xe(" Edit your information here! "),h(l,{onClick:t[0]||(t[0]=y=>s.returnButton()),class:"ml-5 mb-2"},{default:ie(()=>[h(o,{size:"xx-large",icon:"mdi-file-account"}),Xe(" back to resume ")]),_:1})])]),_:1})]),_:1}),h(p,{modelValue:e.panel,"onUpdate:modelValue":t[1]||(t[1]=y=>e.panel=y)},{default:ie(()=>[h(u,{about:i.about,onSaveAbout:s.handleSaveAbout},null,8,["about","onSaveAbout"]),h(d,{educations:i.educations,onDeleteEdu:s.handleDeleteEdu,onAddEdu:s.handleAddEdu,onSaveEdu:s.handleSaveEdu},null,8,["educations","onDeleteEdu","onAddEdu","onSaveEdu"]),h(f,{professions:i.professions,onDeletePro:s.handleDeletePro,onAddPro:s.handleAddPro,onSavePro:s.handleSavePro},null,8,["professions","onDeletePro","onAddPro","onSavePro"]),h(v,{skills:i.skills,onDeleteSkill:s.handleDeleteSkill,onAddSkill:s.handleAddSkill,onSaveSkill:s.handleSaveSkill},null,8,["skills","onDeleteSkill","onAddSkill","onSaveSkill"]),h(m,{certifications:i.certifications,onDeleteCer:s.handleDeleteCer,onAddCer:s.handleAddCer,onSaveCer:s.handleSaveCer},null,8,["certifications","onDeleteCer","onAddCer","onSaveCer"]),h(g,{awards:i.awards,onDeleteAward:s.handleDeleteAward,onAddAward:s.handleAddAward,onSaveAward:s.handleSaveAward},null,8,["awards","onDeleteAward","onAddAward","onSaveAward"])]),_:1},8,["modelValue"])])}const AD=at(CD,[["render",VD]]);const TD={async mounted(){document.getElementById("signinButton").style.display="none",document.getElementById("profileShortcut").style.display="none",document.getElementById("logoutButton").style.display="none",document.getElementById("userNameDisplay").style.display="none",await fetch("https://res-a-me-api.resilientdb.com/loadUser",{method:"GET",headers:{"Content-type":"application/json; charset=UTF-8",Authorization:"Bearer "+sessionStorage.getItem("access_token")}}).then(e=>e.json()).then(e=>{e.status===200?(this.userEmail=e.logged_in_as,fetch(`https://res-a-me-api.resilientdb.com/static/images/${this.userEmail}.png`).then(t=>{t.ok?this.shortCutIcon=`https://res-a-me-api.resilientdb.com/static/images/${this.userEmail}.png`:this.shortCutIcon="/images/pictures/avatar.png"}),document.getElementById("profileShortcut").style.display="block",document.getElementById("logoutButton").style.display="block"):(this.errorMessage="User are not logged in",document.getElementById("signinButton").style.display="block")}).catch(e=>{console.error("There was an error!",e),this.errorMessage=e.message||"An error occurred. Please try again."}),fetch("https://res-a-me-api.resilientdb.com/userList",{method:"GET",headers:{"Content-type":"application/json; charset=UTF-8"}}).then(e=>e.json()).then(e=>{for(let n in e.user_list){e.user_list[n].email===this.userEmail&&(this.userName=e.user_list[n].name,document.getElementById("userNameDisplay").style.display="block");var t="";fetch(`https://res-a-me-api.resilientdb.com/static/images/${e.user_list[n].email}.png`).then(i=>{i.ok?t=`https://res-a-me-api.resilientdb.com/static/images/${e.user_list[n].email}.png`:t="/images/pictures/avatar.png"}).then(()=>{const i={name:e.user_list[n].name,group:e.user_list[n].position,avatar:t,email:e.user_list[n].email};this.people.push(i)})}})},methods:{logout(){const e="";fetch("https://res-a-me-api.resilientdb.com/logout",{method:"GET",headers:{"Content-type":"application/json; charset=UTF-8"}}).then(t=>{if(!t.ok)throw new Error("Network response was not ok");return t.json()}).then(t=>{t.message==="Logout successful"?(sessionStorage.clear(),document.getElementById("logoutButton").style.display="none",document.getElementById("signinButton").style.display="block",document.getElementById("profileShortcut").style.display="none",document.getElementById("userNameDisplay").style.display="none",alert("Logout Successful")):e.value=t.message||"Logout failed. Please try again."}).catch(t=>{console.error("Logout error:",t),e.value=t.message||"An error occurred. Please try again."})},async profileShortcutAction(){try{const t=await(await fetch("https://res-a-me-api.resilientdb.com/updateResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8"},body:JSON.stringify({email:this.userEmail})})).json();t.status!==200&&console.error("Error fetching user resume: ",t.message),this.$router.push({path:"/home"}).then(()=>window.location.reload(!0))}catch{console.error("profileShortcutAction error ")}},async search(){var e="";this.query.email?e=this.query.email:e=this.userEmail;try{const n=await(await fetch("https://res-a-me-api.resilientdb.com/updateResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8"},body:JSON.stringify({email:e})})).json();n.status!==200&&console.error("Error fetching user resume: ",n.message),this.query.email&&this.$router.push({path:"/home",query:{query:this.query.email}}).then(()=>window.location.reload(!0))}catch{console.error("search error")}},async makeConntections(){for(var e=this.userEmail,t="";e===this.userEmail;)t=this.people[Math.floor(Math.random()*this.people.length)],e=t.email;try{const i=await(await fetch("https://res-a-me-api.resilientdb.com/updateResume",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8"},body:JSON.stringify({email:t.email})})).json();i.status!==200&&console.error("Error fetching user resume: ",i.message),this.$router.push({path:"/home",query:{query:t.email}}).then(()=>window.location.reload(!0))}catch(n){console.error("Error fetching user resume: ",n)}}},data(){return{userName:"",userEmail:"",shortCutIcon:"",autoUpdate:!0,isUpdating:!1,name:"Midnight Crew",query:[],people:[],title:"The summer breeze",timeout:null}}},MD={style:{position:"fixed","z-index":"999",color:"black",right:"140px",top:"28px","text-transform":"none","letter-spacing":"0px","font-size":"13px"},id:"userNameDisplay"},ED=be("div",{class:"text-caption text-truncate"},"My Res-A-Me",-1);function DD(e,t,n,i,a,s){const o=we("v-btn"),l=we("v-hover"),r=we("v-img"),c=we("v-chip"),u=we("v-list-item"),d=we("v-autocomplete"),f=we("v-row"),v=we("v-avatar"),m=we("v-card"),g=we("v-col"),p=we("v-container"),y=we("v-responsive"),b=we("v-app");return me(),Tt(b,{style:{width:"100%",height:"100%"}},{default:ie(()=>[h(l,null,{default:ie(({hover:S})=>[h(o,{variant:"plain",density:"compact",href:"https://tobyyu007.github.io/resame-about-page/",style:Xi({position:"fixed","z-index":"999",color:"black",left:"20px",top:"27px","text-transform":"none","letter-spacing":"0px",opacity:"1","text-decoration":S?"underline":"none"})},{default:ie(()=>[Xe(" About ")]),_:2},1032,["style"])]),_:1}),be("p",MD," Hi, "+wt(a.userName),1),h(o,{variant:"flat",color:"#1a73e8",style:{position:"fixed","z-index":"999",color:"white",right:"40px",top:"20px","text-transform":"none"},id:"signinButton",onClick:t[0]||(t[0]=S=>this.$router.push("/login"))},{default:ie(()=>[Xe(" Sign in ")]),_:1}),h(o,{variant:"flat",color:"#1a73e8",style:{position:"fixed","z-index":"999",color:"white",right:"40px",top:"20px","text-transform":"none"},id:"logoutButton",onClick:t[1]||(t[1]=S=>s.logout())},{default:ie(()=>[Xe(" Logout ")]),_:1}),h(m,{theme:"light",class:"d-flex justify-center align-center flex-wrap",style:{width:"100%",height:"100%"}},{default:ie(()=>[h(y,{"max-width":"550"},{default:ie(()=>[h(r,{class:"mx-auto mt-12 mb-16","max-width":"340",src:"./images/icons/Res-A-Me.png"}),h(d,{modelValue:a.query,"onUpdate:modelValue":t[2]||(t[2]=S=>a.query=S),disabled:a.isUpdating,items:a.people,chips:"",color:"blue-grey-lighten-2","item-title":"name","item-value":"name",label:"Search People","prepend-inner-icon":"mdi-magnify",density:"comfortable","auto-select-first":"","return-object":"",rounded:"",theme:"light",variant:"outlined"},{chip:ie(({props:S,item:_})=>[h(c,ve(S,{"prepend-avatar":_.raw.avatar,text:_.raw.name}),null,16,["prepend-avatar","text"])]),item:ie(({props:S,item:_})=>{var x,P,C;return[h(u,ve(S,{"prepend-avatar":(x=_==null?void 0:_.raw)==null?void 0:x.avatar,title:(P=_==null?void 0:_.raw)==null?void 0:P.name,subtitle:(C=_==null?void 0:_.raw)==null?void 0:C.group}),null,16,["prepend-avatar","title","subtitle"])]}),_:1},8,["modelValue","disabled","items"]),h(f,{dense:"",justify:"center",class:"pt-5 pb-5"},{default:ie(()=>[h(o,{variant:"flat",color:"#ededf0",style:{"text-transform":"none","letter-spacing":"0px"},class:"mr-5",onClick:t[3]||(t[3]=S=>s.search())},{default:ie(()=>[Xe(" Res-A-Me Search ")]),_:1}),h(o,{variant:"flat",color:"#ededf0",style:{"text-transform":"none","letter-spacing":"0px"},onClick:t[4]||(t[4]=S=>s.makeConntections())},{default:ie(()=>[Xe(" Make Connections ")]),_:1})]),_:1}),h(p,{class:"text-center pt-15",id:"profileShortcut"},{default:ie(()=>[h(f,{justify:"center",dense:""},{default:ie(()=>[h(g,{cols:"auto"},{default:ie(()=>[h(m,{class:"pa-4",flat:"",rel:"noopener noreferer",target:"_blank",width:"112",onClick:t[5]||(t[5]=S=>s.profileShortcutAction())},{default:ie(()=>[h(v,{variant:"tonal",class:"mb-2",size:"60"},{default:ie(()=>[h(r,{src:a.shortCutIcon},null,8,["src"])]),_:1}),ED]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})}const OD=at(TD,[["render",DD]]);function RD(){const t=Oi().getSections(),n=t[0]||{id:"home"},i=["edit"],a=[{path:"/",name:"LandingPage",component:OD},{path:"/login",name:"login",component:NE},{path:"/home",name:n.id,component:Jg},{path:"/edit",name:"edit",component:AD}];for(let o=1;o{let c=!1;try{const d=await(await fetch("https://res-a-me-api.resilientdb.com/loadUser",{method:"GET",headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*",Authorization:"Bearer "+sessionStorage.getItem("access_token")}})).json();if(d.status===200)c=!0;else if(d.msg==="Token has expired"){const v=await(await fetch("https://res-a-me-api.resilientdb.com/refresh",{method:"POST",headers:{"Content-type":"application/json; charset=UTF-8","Access-Control-Allow-Origin":"*",Authorization:"Bearer "+sessionStorage.getItem("refresh_token")}})).json();if(v.status===200)sessionStorage.setItem("access_token",v.access_token),c=!0;else throw new Error("Refresh Token Expired!!! Please Log In Again")}}catch(u){console.error("There was an error!",u)}console.log("isAuthenticated = ",c),o.name==="login"&&c?r({name:n.id}):i.includes(o.name)&&!c?r({name:"login"}):r()}),s}const LD={class:"loader-full-screen-content"},BD={class:"mt-2 mb-2 text-2"},ep=1/60,ND={__name:"Loader",emits:["willShow","shown","completed","willHide","hidden"],setup(e,{expose:t,emit:n}){const i=n,a=[{id:0,label:"startingUp",duration:null},{id:1,label:"logoTweenIn",duration:.5},{id:2,label:"progressTweenIn",duration:.3},{id:3,label:"loading",minDuration:.4},{id:4,label:"waiting",duration:.3},{id:5,label:"disappearing",duration:1.2}],s=Z(""),o=Z(""),l=Z(0),r=Z(null),c=Z(0),u=Z(-1);let d=0,f=null;_t(()=>{v()});const v=()=>{clearInterval(f),f=null,u.value=-1,d=0,c.value=0},m=(x,P)=>{s.value=x,o.value=P,u.value=0,f=setInterval(p,ep*1e3)},g=x=>{l.value=x},p=()=>{const x=a[u.value];d+=ep;let P=!1;switch(x.label){case"startingUp":P=r.value.isLoaded();break;case"loading":const C=Math.min(Math.max(100*d/x.minDuration,0),100);c.value=Math.round(Math.min(C,l.value)),P=c.value>=100;break;default:P=d>=x.duration}P&&y()},y=()=>{if(u.value++,d=0,u.value>=a.length){i("hidden"),v();return}switch(a[u.value].label){case"logoTweenIn":i("willShow");break;case"loading":i("shown");break;case"waiting":i("completed");break;case"disappearing":i("willHide");break}},b=x=>{const P=a.find(C=>C.label===x);return P&&u.value>=P.id},S=()=>u.value>=0&&u.valueS()?b("disappearing")?"loader-full-screen-transition":"loader-full-screen-show":"d-none";return t({run:m,setTaskProgress:g}),(x,P)=>S()?(me(),Te("div",{key:0,class:xt(["loader-full-screen",_()])},[ft(be("div",LD,[h(yh,{src:o.value,alt:"Preloader Logo","ignore-on-image-count":!0,ref_key:"logo",ref:r,class:"img-fluid img-logo"},null,8,["src"]),be("div",{class:xt(["progress-display",{"progress-display-expanded":b("progressTweenIn")}])},[be("p",BD,wt(s.value)+"...",1),h(Yb,{ref:"progressBar",percentage:c.value},null,8,["percentage"])],2)],512),[[mn,b("logoTweenIn")]])],2)):kt("",!0)}},FD=at(ND,[["__scopeId","data-v-e789e4ad"]]);const $D=e=>(Oa("data-v-c428fd9e"),e=e(),Ra(),e),zD={class:"activity-spinner-content text-center"},HD=$D(()=>be("img",{alt:"loading...",class:"preloader-gif",src:"data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4KPHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBzdHlsZT0ibWFyZ2luOiBhdXRvOyBiYWNrZ3JvdW5kOiBub25lOyBkaXNwbGF5OiBibG9jazsgc2hhcGUtcmVuZGVyaW5nOiBhdXRvOyIgd2lkdGg9IjIwMHB4IiBoZWlnaHQ9IjIwMHB4IiB2aWV3Qm94PSIwIDAgMTAwIDEwMCIgcHJlc2VydmVBc3BlY3RSYXRpbz0ieE1pZFlNaWQiPgo8Y2lyY2xlIGN4PSI1MCIgY3k9IjUwIiByPSIzMiIgc3Ryb2tlLXdpZHRoPSI4IiBzdHJva2U9IiM1NDUxNTEiIHN0cm9rZS1kYXNoYXJyYXk9IjUwLjI2NTQ4MjQ1NzQzNjY5IDUwLjI2NTQ4MjQ1NzQzNjY5IiBmaWxsPSJub25lIiBzdHJva2UtbGluZWNhcD0icm91bmQiPgogIDxhbmltYXRlVHJhbnNmb3JtIGF0dHJpYnV0ZU5hbWU9InRyYW5zZm9ybSIgdHlwZT0icm90YXRlIiBkdXI9IjFzIiByZXBlYXRDb3VudD0iaW5kZWZpbml0ZSIga2V5VGltZXM9IjA7MSIgdmFsdWVzPSIwIDUwIDUwOzM2MCA1MCA1MCI+PC9hbmltYXRlVHJhbnNmb3JtPgo8L2NpcmNsZT4KPGNpcmNsZSBjeD0iNTAiIGN5PSI1MCIgcj0iMjMiIHN0cm9rZS13aWR0aD0iOCIgc3Ryb2tlPSIjYzNjM2M1IiBzdHJva2UtZGFzaGFycmF5PSIzNi4xMjgzMTU1MTYyODI2MiAzNi4xMjgzMTU1MTYyODI2MiIgc3Ryb2tlLWRhc2hvZmZzZXQ9IjM2LjEyODMxNTUxNjI4MjYyIiBmaWxsPSJub25lIiBzdHJva2UtbGluZWNhcD0icm91bmQiPgogIDxhbmltYXRlVHJhbnNmb3JtIGF0dHJpYnV0ZU5hbWU9InRyYW5zZm9ybSIgdHlwZT0icm90YXRlIiBkdXI9IjFzIiByZXBlYXRDb3VudD0iaW5kZWZpbml0ZSIga2V5VGltZXM9IjA7MSIgdmFsdWVzPSIwIDUwIDUwOy0zNjAgNTAgNTAiPjwvYW5pbWF0ZVRyYW5zZm9ybT4KPC9jaXJjbGU+CjwhLS0gW2xkaW9dIGdlbmVyYXRlZCBieSBodHRwczovL2xvYWRpbmcuaW8vIC0tPjwvc3ZnPg=="},null,-1)),jD={class:"text-light-5"},WD={__name:"ActivitySpinner",setup(e,{expose:t}){const n=Z(""),i=Z(!1);return t({show:o=>{n.value=o,i.value=!0},hide:()=>{i.value=!1}}),(o,l)=>(me(),Te("div",{class:xt(["activity-spinner",{"d-none":!i.value}])},[be("div",zD,[HD,be("h5",jD,wt(n.value),1)])],2))}},UD=at(WD,[["__scopeId","data-v-c428fd9e"]]);const YD={__name:"FeedbackView",setup(e,{expose:t}){const n=To(),i=Z(null),a=Z(null),s={onShown:null,onComplete:null},o=(m,g)=>{n.setPageScrollingEnabled(!1),i.value.run(m,g)},l=(m,g)=>{s.onShown=m,s.onComplete=g},r=m=>{i.value.setTaskProgress(m)},c=()=>{s.onShown&&s.onShown()},u=()=>{s.onComplete&&s.onComplete()},d=()=>{n.setPageScrollingEnabled(!0),s.onShown=null,s.onComplete=null};return t({setLoader:o,setLoaderListeners:l,updateLoaderProgress:r,showActivitySpinner:m=>{a.value.show(m)},hideActivitySpinner:()=>{a.value.hide()}}),(m,g)=>(me(),Te(Pe,null,[h(FD,{ref_key:"loader",ref:i,onShown:c,onCompleted:u,onWillHide:d},null,512),h(UD,{ref_key:"activitySpinner",ref:a},null,512)],64))}},KD=at(YD,[["__scopeId","data-v-78d8acb8"]]),GD={key:0},XD={__name:"App",setup(e){const t=Oi(),n=To(),i=Ba(),a=Z(null),s=Z(!1);let o=null;_t(()=>{n.setFeedbackView(a),r()});const l=w(()=>t.getSettings().preloaderEnabled),r=async()=>{clearInterval(o),l.value?(a.value.setLoaderListeners(c,d),a.value.setLoader(t.getString("loading"),"images/icons/resume.ico")):await c()},c=async()=>{o=setInterval(()=>{u()},1e3/30),await t.fetchAll(),l.value||(d(),n.setPageScrollingEnabled(!0))},u=()=>{if(!l.value)return;const f=t.getLoadProgress(),v=n.getImageCount();let m=0;v.total>0?m=Math.round(100*v.loaded/v.total):f===100&&(m=100);const g=(f+m*4)/5;a.value.updateLoaderProgress(g)},d=()=>{s.value=!0,clearInterval(o)};return(f,v)=>{const m=we("router-view");return me(),Te(Pe,null,[h(KD,{ref_key:"feedbackView",ref:a},null,512),Je(t).getLoadProgress()>=100?ft((me(),Te("div",GD,[h(m)],512)),[[mn,!Je(i).isTouchDevice()||s.value]]):kt("",!0)],64)}}},qD={badge:"Badge",open:"Open",close:"Close",confirmEdit:{ok:"OK",cancel:"Cancel"},dataIterator:{noResultsText:"No matching records found",loadingText:"Loading items..."},dataTable:{itemsPerPageText:"Rows per page:",ariaLabel:{sortDescending:"Sorted descending.",sortAscending:"Sorted ascending.",sortNone:"Not sorted.",activateNone:"Activate to remove sorting.",activateDescending:"Activate to sort descending.",activateAscending:"Activate to sort ascending."},sortBy:"Sort by"},dataFooter:{itemsPerPageText:"Items per page:",itemsPerPageAll:"All",nextPage:"Next page",prevPage:"Previous page",firstPage:"First page",lastPage:"Last page",pageText:"{0}-{1} of {2}"},dateRangeInput:{divider:"to"},datePicker:{itemsSelected:"{0} selected",range:{title:"Select dates",header:"Enter dates"},title:"Select date",header:"Enter date",input:{placeholder:"Enter date"}},noDataText:"No data available",carousel:{prev:"Previous visual",next:"Next visual",ariaLabel:{delimiter:"Carousel slide {0} of {1}"}},calendar:{moreEvents:"{0} more"},input:{clear:"Clear {0}",prependAction:"{0} prepended action",appendAction:"{0} appended action",otp:"Please enter OTP character {0}"},fileInput:{counter:"{0} files",counterSize:"{0} files ({1} in total)"},timePicker:{am:"AM",pm:"PM"},pagination:{ariaLabel:{root:"Pagination Navigation",next:"Next page",previous:"Previous page",page:"Go to page {0}",currentPage:"Page {0}, Current page",first:"First page",last:"Last page"}},stepper:{next:"Next",prev:"Previous"},rating:{ariaLabel:{item:"Rating {0} of {1}"}},loading:"Loading...",infiniteScroll:{loadMore:"Load more",empty:"No more"}},ZD={af:!1,ar:!0,bg:!1,ca:!1,ckb:!1,cs:!1,de:!1,el:!1,en:!1,es:!1,et:!1,fa:!0,fi:!1,fr:!1,hr:!1,hu:!1,he:!0,id:!1,it:!1,ja:!1,ko:!1,lv:!1,lt:!1,nl:!1,no:!1,pl:!1,pt:!1,ro:!1,ru:!1,sk:!1,sl:!1,srCyrl:!1,srLatn:!1,sv:!1,th:!1,tr:!1,az:!1,uk:!1,vi:!1,zhHans:!1,zhHant:!1};function mi(e,t){let n;function i(){n=Hc(),n.run(()=>t.length?t(()=>{n==null||n.stop(),i()}):t())}_e(e,a=>{a&&!n?i():a||(n==null||n.stop(),n=void 0)},{immediate:!0}),_n(()=>{n==null||n.stop()})}const yt=typeof window<"u",Dh=yt&&"IntersectionObserver"in window,JD=yt&&("ontouchstart"in window||window.navigator.maxTouchPoints>0),tp=yt&&"EyeDropper"in window;function np(e,t,n){QD(e,t),t.set(e,n)}function QD(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function eO(e,t,n){var i=O_(e,t,"set");return tO(e,i,n),n}function tO(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}function ts(e,t){var n=O_(e,t,"get");return nO(e,n)}function O_(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}function nO(e,t){return t.get?t.get.call(e):t.value}function R_(e,t,n){const i=t.length-1;if(i<0)return e===void 0?n:e;for(let a=0;ana(e[i],t[i]))}function Ss(e,t,n){return e==null||!t||typeof t!="string"?n:e[t]!==void 0?e[t]:(t=t.replace(/\[(\w+)\]/g,".$1"),t=t.replace(/^\./,""),R_(e,t.split("."),n))}function rn(e,t,n){if(t===!0)return e===void 0?n:e;if(t==null||typeof t=="boolean")return n;if(e!==Object(e)){if(typeof t!="function")return n;const a=t(e,n);return typeof a>"u"?n:a}if(typeof t=="string")return Ss(e,t,n);if(Array.isArray(t))return R_(e,t,n);if(typeof t!="function")return n;const i=t(e,n);return typeof i>"u"?n:i}function Ti(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return Array.from({length:e},(n,i)=>t+i)}function Ee(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"px";if(!(e==null||e===""))return isNaN(+e)?String(e):isFinite(+e)?`${Number(e)}${t}`:void 0}function Mc(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function $l(e){if(e&&"$el"in e){const t=e.$el;return(t==null?void 0:t.nodeType)===Node.TEXT_NODE?t.nextElementSibling:t}return e}const ip=Object.freeze({enter:13,tab:9,delete:46,esc:27,space:32,up:38,down:40,left:37,right:39,end:35,home:36,del:46,backspace:8,insert:45,pageup:33,pagedown:34,shift:16}),sf=Object.freeze({enter:"Enter",tab:"Tab",delete:"Delete",esc:"Escape",space:"Space",up:"ArrowUp",down:"ArrowDown",left:"ArrowLeft",right:"ArrowRight",end:"End",home:"Home",del:"Delete",backspace:"Backspace",insert:"Insert",pageup:"PageUp",pagedown:"PageDown",shift:"Shift"});function L_(e){return Object.keys(e)}function ls(e,t){return t.every(n=>e.hasOwnProperty(n))}function B_(e,t){const n={},i=new Set(Object.keys(e));for(const a of t)i.has(a)&&(n[a]=e[a]);return n}function of(e,t,n){const i=Object.create(null),a=Object.create(null);for(const s in e)t.some(o=>o instanceof RegExp?o.test(s):o===s)&&!(n!=null&&n.some(o=>o===s))?i[s]=e[s]:a[s]=e[s];return[i,a]}function nn(e,t){const n={...e};return t.forEach(i=>delete n[i]),n}function N_(e,t){const n={};return t.forEach(i=>n[i]=e[i]),n}const F_=/^on[^a-z]/,fu=e=>F_.test(e),iO=["onAfterscriptexecute","onAnimationcancel","onAnimationend","onAnimationiteration","onAnimationstart","onAuxclick","onBeforeinput","onBeforescriptexecute","onChange","onClick","onCompositionend","onCompositionstart","onCompositionupdate","onContextmenu","onCopy","onCut","onDblclick","onFocusin","onFocusout","onFullscreenchange","onFullscreenerror","onGesturechange","onGestureend","onGesturestart","onGotpointercapture","onInput","onKeydown","onKeypress","onKeyup","onLostpointercapture","onMousedown","onMousemove","onMouseout","onMouseover","onMouseup","onMousewheel","onPaste","onPointercancel","onPointerdown","onPointerenter","onPointerleave","onPointermove","onPointerout","onPointerover","onPointerup","onReset","onSelect","onSubmit","onTouchcancel","onTouchend","onTouchmove","onTouchstart","onTransitioncancel","onTransitionend","onTransitionrun","onTransitionstart","onWheel"],aO=["ArrowUp","ArrowDown","ArrowRight","ArrowLeft","Enter","Escape","Tab"," "];function sO(e){return e.isComposing&&aO.includes(e.key)}function Fa(e){const[t,n]=of(e,[F_]),i=nn(t,iO),[a,s]=of(n,["class","style","id",/^data-/]);return Object.assign(a,t),Object.assign(s,i),[a,s]}function Ht(e){return e==null?[]:Array.isArray(e)?e:[e]}function oO(e,t){let n=0;const i=function(){for(var a=arguments.length,s=new Array(a),o=0;oe(...s),Je(t))};return i.clear=()=>{clearTimeout(n)},i.immediate=e,i}function Zt(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1;return Math.max(t,Math.min(n,e))}function ap(e){const t=e.toString().trim();return t.includes(".")?t.length-t.indexOf(".")-1:0}function sp(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"0";return e+n.repeat(Math.max(0,t-e.length))}function op(e,t){return(arguments.length>2&&arguments[2]!==void 0?arguments[2]:"0").repeat(Math.max(0,t-e.length))+e}function lO(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;const n=[];let i=0;for(;i1&&arguments[1]!==void 0?arguments[1]:1e3;if(e=t&&i0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0;const i={};for(const a in e)i[a]=e[a];for(const a in t){const s=e[a],o=t[a];if(Mc(s)&&Mc(o)){i[a]=si(s,o,n);continue}if(Array.isArray(s)&&Array.isArray(o)&&n){i[a]=n(s,o);continue}i[a]=o}return i}function $_(e){return e.map(t=>t.type===Pe?$_(t.children):t).flat()}function ms(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";if(ms.cache.has(e))return ms.cache.get(e);const t=e.replace(/[^a-z]/gi,"-").replace(/\B([A-Z])/g,"-$1").toLowerCase();return ms.cache.set(e,t),t}ms.cache=new Map;function Sl(e,t){if(!t||typeof t!="object")return[];if(Array.isArray(t))return t.map(n=>Sl(e,n)).flat(1);if(Array.isArray(t.children))return t.children.map(n=>Sl(e,n)).flat(1);if(t.component){if(Object.getOwnPropertySymbols(t.component.provides).includes(e))return[t.component];if(t.component.subTree)return Sl(e,t.component.subTree).flat(1)}return[]}var Yr=new WeakMap,qs=new WeakMap;class rO{constructor(t){np(this,Yr,{writable:!0,value:[]}),np(this,qs,{writable:!0,value:0}),this.size=t}push(t){ts(this,Yr)[ts(this,qs)]=t,eO(this,qs,(ts(this,qs)+1)%this.size)}values(){return ts(this,Yr).slice(ts(this,qs)).concat(ts(this,Yr).slice(0,ts(this,qs)))}}function cO(e){return"touches"in e?{clientX:e.touches[0].clientX,clientY:e.touches[0].clientY}:{clientX:e.clientX,clientY:e.clientY}}function Oh(e){const t=Ft({}),n=w(e);return Jt(()=>{for(const i in n.value)t[i]=n.value[i]},{flush:"sync"}),Ql(t)}function Ec(e,t){return e.includes(t)}function z_(e){return e[2].toLowerCase()+e.slice(3)}const Bn=()=>[Function,Array];function rp(e,t){return t="on"+bi(t),!!(e[t]||e[`${t}Once`]||e[`${t}Capture`]||e[`${t}OnceCapture`]||e[`${t}CaptureOnce`])}function Rh(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i1&&arguments[1]!==void 0?arguments[1]:!0;const n=["button","[href]",'input:not([type="hidden"])',"select","textarea","[tabindex]"].map(i=>`${i}${t?':not([tabindex="-1"])':""}:not([disabled])`).join(", ");return[...e.querySelectorAll(n)]}function H_(e,t,n){let i,a=e.indexOf(document.activeElement);const s=t==="next"?1:-1;do a+=s,i=e[a];while((!i||i.offsetParent==null||!((n==null?void 0:n(i))??!0))&&a=0);return i}function _o(e,t){var i,a,s,o;const n=zl(e);if(!t)(e===document.activeElement||!e.contains(document.activeElement))&&((i=n[0])==null||i.focus());else if(t==="first")(a=n[0])==null||a.focus();else if(t==="last")(s=n.at(-1))==null||s.focus();else if(typeof t=="number")(o=n[t])==null||o.focus();else{const l=H_(n,t);l?l.focus():_o(e,t==="next"?"first":"last")}}function Kr(e){return e==null||typeof e=="string"&&e.trim()===""}function j_(){}function xo(e,t){if(!(yt&&typeof CSS<"u"&&typeof CSS.supports<"u"&&CSS.supports(`selector(${t})`)))return null;try{return!!e&&e.matches(t)}catch{return null}}function hu(e){return e.some(t=>qi(t)?t.type===vn?!1:t.type!==Pe||hu(t.children):!0)?e:null}const W_=["top","bottom"],uO=["start","end","left","right"];function lf(e,t){let[n,i]=e.split(" ");return i||(i=Ec(W_,n)?"start":Ec(uO,n)?"top":"center"),{side:rf(n,t),align:rf(i,t)}}function rf(e,t){return e==="start"?t?"right":"left":e==="end"?t?"left":"right":e}function yd(e){return{side:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[e.side],align:e.align}}function bd(e){return{side:e.side,align:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[e.align]}}function cp(e){return{side:e.align,align:e.side}}function up(e){return Ec(W_,e.side)?"y":"x"}class gs{constructor(t){let{x:n,y:i,width:a,height:s}=t;this.x=n,this.y=i,this.width=a,this.height=s}get top(){return this.y}get bottom(){return this.y+this.height}get left(){return this.x}get right(){return this.x+this.width}}function dp(e,t){return{x:{before:Math.max(0,t.left-e.left),after:Math.max(0,e.right-t.right)},y:{before:Math.max(0,t.top-e.top),after:Math.max(0,e.bottom-t.bottom)}}}function U_(e){return Array.isArray(e)?new gs({x:e[0],y:e[1],width:0,height:0}):e.getBoundingClientRect()}function Lh(e){const t=e.getBoundingClientRect(),n=getComputedStyle(e),i=n.transform;if(i){let a,s,o,l,r;if(i.startsWith("matrix3d("))a=i.slice(9,-1).split(/, /),s=+a[0],o=+a[5],l=+a[12],r=+a[13];else if(i.startsWith("matrix("))a=i.slice(7,-1).split(/, /),s=+a[0],o=+a[3],l=+a[4],r=+a[5];else return new gs(t);const c=n.transformOrigin,u=t.x-l-(1-s)*parseFloat(c),d=t.y-r-(1-o)*parseFloat(c.slice(c.indexOf(" ")+1)),f=s?t.width/s:e.offsetWidth+1,v=o?t.height/o:e.offsetHeight+1;return new gs({x:u,y:d,width:f,height:v})}else return new gs(t)}function rs(e,t,n){if(typeof e.animate>"u")return{finished:Promise.resolve()};let i;try{i=e.animate(t,n)}catch{return{finished:Promise.resolve()}}return typeof i.finished>"u"&&(i.finished=new Promise(a=>{i.onfinish=()=>{a(i)}})),i}const ac=new WeakMap;function dO(e,t){Object.keys(t).forEach(n=>{if(fu(n)){const i=z_(n),a=ac.get(e);if(t[n]==null)a==null||a.forEach(s=>{const[o,l]=s;o===i&&(e.removeEventListener(i,l),a.delete(s))});else if(!a||![...a].some(s=>s[0]===i&&s[1]===t[n])){e.addEventListener(i,t[n]);const s=a||new Set;s.add([i,t[n]]),ac.has(e)||ac.set(e,s)}}else t[n]==null?e.removeAttribute(n):e.setAttribute(n,t[n])})}function fO(e,t){Object.keys(t).forEach(n=>{if(fu(n)){const i=z_(n),a=ac.get(e);a==null||a.forEach(s=>{const[o,l]=s;o===i&&(e.removeEventListener(i,l),a.delete(s))})}else e.removeAttribute(n)})}const Zs=2.4,fp=.2126729,hp=.7151522,vp=.072175,hO=.55,vO=.58,mO=.57,gO=.62,Gr=.03,mp=1.45,pO=5e-4,yO=1.25,bO=1.25,gp=.078,pp=12.82051282051282,Xr=.06,yp=.001;function bp(e,t){const n=(e.r/255)**Zs,i=(e.g/255)**Zs,a=(e.b/255)**Zs,s=(t.r/255)**Zs,o=(t.g/255)**Zs,l=(t.b/255)**Zs;let r=n*fp+i*hp+a*vp,c=s*fp+o*hp+l*vp;if(r<=Gr&&(r+=(Gr-r)**mp),c<=Gr&&(c+=(Gr-c)**mp),Math.abs(c-r)r){const d=(c**hO-r**vO)*yO;u=d-yp?0:d>-gp?d-d*pp*Xr:d+Xr}return u*100}function _O(e,t){t=Array.isArray(t)?t.slice(0,-1).map(n=>`'${n}'`).join(", ")+` or '${t.at(-1)}'`:`'${t}'`}const Dc=.20689655172413793,xO=e=>e>Dc**3?Math.cbrt(e):e/(3*Dc**2)+4/29,SO=e=>e>Dc?e**3:3*Dc**2*(e-4/29);function Y_(e){const t=xO,n=t(e[1]);return[116*n-16,500*(t(e[0]/.95047)-n),200*(n-t(e[2]/1.08883))]}function K_(e){const t=SO,n=(e[0]+16)/116;return[t(n+e[1]/500)*.95047,t(n),t(n-e[2]/200)*1.08883]}const wO=[[3.2406,-1.5372,-.4986],[-.9689,1.8758,.0415],[.0557,-.204,1.057]],kO=e=>e<=.0031308?e*12.92:1.055*e**(1/2.4)-.055,CO=[[.4124,.3576,.1805],[.2126,.7152,.0722],[.0193,.1192,.9505]],PO=e=>e<=.04045?e/12.92:((e+.055)/1.055)**2.4;function G_(e){const t=Array(3),n=kO,i=wO;for(let a=0;a<3;++a)t[a]=Math.round(Zt(n(i[a][0]*e[0]+i[a][1]*e[1]+i[a][2]*e[2]))*255);return{r:t[0],g:t[1],b:t[2]}}function Bh(e){let{r:t,g:n,b:i}=e;const a=[0,0,0],s=PO,o=CO;t=s(t/255),n=s(n/255),i=s(i/255);for(let l=0;l<3;++l)a[l]=o[l][0]*t+o[l][1]*n+o[l][2]*i;return a}function cf(e){return!!e&&/^(#|var\(--|(rgb|hsl)a?\()/.test(e)}function IO(e){return cf(e)&&!/^((rgb|hsl)a?\()?var\(--/.test(e)}const _p=/^(?(?:rgb|hsl)a?)\((?.+)\)/,VO={rgb:(e,t,n,i)=>({r:e,g:t,b:n,a:i}),rgba:(e,t,n,i)=>({r:e,g:t,b:n,a:i}),hsl:(e,t,n,i)=>xp({h:e,s:t,l:n,a:i}),hsla:(e,t,n,i)=>xp({h:e,s:t,l:n,a:i}),hsv:(e,t,n,i)=>Zi({h:e,s:t,v:n,a:i}),hsva:(e,t,n,i)=>Zi({h:e,s:t,v:n,a:i})};function oi(e){if(typeof e=="number")return{r:(e&16711680)>>16,g:(e&65280)>>8,b:e&255};if(typeof e=="string"&&_p.test(e)){const{groups:t}=e.match(_p),{fn:n,values:i}=t,a=i.split(/,\s*/).map(s=>s.endsWith("%")&&["hsl","hsla","hsv","hsva"].includes(n)?parseFloat(s)/100:parseFloat(s));return VO[n](...a)}else if(typeof e=="string"){let t=e.startsWith("#")?e.slice(1):e;return[3,4].includes(t.length)?t=t.split("").map(n=>n+n).join(""):[6,8].includes(t.length),Q_(t)}else if(typeof e=="object"){if(ls(e,["r","g","b"]))return e;if(ls(e,["h","s","l"]))return Zi(Nh(e));if(ls(e,["h","s","v"]))return Zi(e)}throw new TypeError(`Invalid color: ${e==null?e:String(e)||e.constructor.name} Expected #hex, #hexa, rgb(), rgba(), hsl(), hsla(), object or number`)}function Zi(e){const{h:t,s:n,v:i,a}=e,s=l=>{const r=(l+t/60)%6;return i-i*n*Math.max(Math.min(r,4-r,1),0)},o=[s(5),s(3),s(1)].map(l=>Math.round(l*255));return{r:o[0],g:o[1],b:o[2],a}}function xp(e){return Zi(Nh(e))}function vu(e){if(!e)return{h:0,s:1,v:1,a:1};const t=e.r/255,n=e.g/255,i=e.b/255,a=Math.max(t,n,i),s=Math.min(t,n,i);let o=0;a!==s&&(a===t?o=60*(0+(n-i)/(a-s)):a===n?o=60*(2+(i-t)/(a-s)):a===i&&(o=60*(4+(t-n)/(a-s)))),o<0&&(o=o+360);const l=a===0?0:(a-s)/a,r=[o,l,a];return{h:r[0],s:r[1],v:r[2],a:e.a}}function X_(e){const{h:t,s:n,v:i,a}=e,s=i-i*n/2,o=s===1||s===0?0:(i-s)/Math.min(s,1-s);return{h:t,s:o,l:s,a}}function Nh(e){const{h:t,s:n,l:i,a}=e,s=i+n*Math.min(i,1-i),o=s===0?0:2-2*i/s;return{h:t,s:o,v:s,a}}function q_(e){let{r:t,g:n,b:i,a}=e;return a===void 0?`rgb(${t}, ${n}, ${i})`:`rgba(${t}, ${n}, ${i}, ${a})`}function Z_(e){return q_(Zi(e))}function qr(e){const t=Math.round(e).toString(16);return("00".substr(0,2-t.length)+t).toUpperCase()}function J_(e){let{r:t,g:n,b:i,a}=e;return`#${[qr(t),qr(n),qr(i),a!==void 0?qr(Math.round(a*255)):""].join("")}`}function Q_(e){e=AO(e);let[t,n,i,a]=lO(e,2).map(s=>parseInt(s,16));return a=a===void 0?a:a/255,{r:t,g:n,b:i,a}}function e0(e){const t=Q_(e);return vu(t)}function t0(e){return J_(Zi(e))}function AO(e){return e.startsWith("#")&&(e=e.slice(1)),e=e.replace(/([^0-9a-f])/gi,"F"),(e.length===3||e.length===4)&&(e=e.split("").map(t=>t+t).join("")),e.length!==6&&(e=sp(sp(e,6),8,"F")),e}function TO(e,t){const n=Y_(Bh(e));return n[0]=n[0]+t*10,G_(K_(n))}function MO(e,t){const n=Y_(Bh(e));return n[0]=n[0]-t*10,G_(K_(n))}function uf(e){const t=oi(e);return Bh(t)[1]}function EO(e,t){const n=uf(e),i=uf(t),a=Math.max(n,i),s=Math.min(n,i);return(a+.05)/(s+.05)}function n0(e){const t=Math.abs(bp(oi(0),oi(e)));return Math.abs(bp(oi(16777215),oi(e)))>Math.min(t,50)?"#fff":"#000"}function W(e,t){return n=>Object.keys(e).reduce((i,a)=>{const o=typeof e[a]=="object"&&e[a]!=null&&!Array.isArray(e[a])?e[a]:{type:e[a]};return n&&a in n?i[a]={...o,default:n[a]}:i[a]=o,t&&!i[a].source&&(i[a].source=t),i},{})}const Re=W({class:[String,Array],style:{type:[String,Array,Object],default:null}},"component"),So=Symbol.for("vuetify:defaults");function DO(e){return Z(e)}function Fh(){const e=Ke(So);if(!e)throw new Error("[Vuetify] Could not find defaults instance");return e}function Ct(e,t){const n=Fh(),i=Z(e),a=w(()=>{if(Je(t==null?void 0:t.disabled))return n.value;const o=Je(t==null?void 0:t.scoped),l=Je(t==null?void 0:t.reset),r=Je(t==null?void 0:t.root);if(i.value==null&&!(o||l||r))return n.value;let c=si(i.value,{prev:n.value});if(o)return c;if(l||r){const u=Number(l||1/0);for(let d=0;d<=u&&!(!c||!("prev"in c));d++)c=c.prev;return c&&typeof r=="string"&&r in c&&(c=si(si(c,{prev:c}),c[r])),c}return c.prev?si(c.prev,c):c});return lt(So,a),a}function OO(e,t){var n,i;return typeof((n=e.props)==null?void 0:n[t])<"u"||typeof((i=e.props)==null?void 0:i[ms(t)])<"u"}function RO(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Fh();const i=Yt("useDefaults");if(t=t??i.type.name??i.type.__name,!t)throw new Error("[Vuetify] Could not determine component name");const a=w(()=>{var r;return(r=n.value)==null?void 0:r[e._as??t]}),s=new Proxy(e,{get(r,c){var d,f,v,m;const u=Reflect.get(r,c);return c==="class"||c==="style"?[(d=a.value)==null?void 0:d[c],u].filter(g=>g!=null):typeof c=="string"&&!OO(i.vnode,c)?((f=a.value)==null?void 0:f[c])??((m=(v=n.value)==null?void 0:v.global)==null?void 0:m[c])??u:u}}),o=Se();Jt(()=>{if(a.value){const r=Object.entries(a.value).filter(c=>{let[u]=c;return u.startsWith(u[0].toUpperCase())});o.value=r.length?Object.fromEntries(r):void 0}else o.value=void 0});function l(){const r=$O(So,i);lt(So,w(()=>o.value?si((r==null?void 0:r.value)??{},o.value):r==null?void 0:r.value))}return{props:s,provideSubDefaults:l}}function Gn(e){if(e._setup=e._setup??e.setup,!e.name)return e;if(e._setup){e.props=W(e.props??{},e.name)();const t=Object.keys(e.props).filter(n=>n!=="class"&&n!=="style");e.filterProps=function(i){return B_(i,t)},e.props._as=String,e.setup=function(i,a){const s=Fh();if(!s.value)return e._setup(i,a);const{props:o,provideSubDefaults:l}=RO(i,i._as??e.name,s),r=e._setup(o,a);return l(),r}}return e}function se(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return t=>(e?Gn:La)(t)}function LO(e,t){return t.props=e,t}function Xn(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"div",n=arguments.length>2?arguments[2]:void 0;return se()({name:n??bi(yn(e.replace(/__/g,"-"))),props:{tag:{type:String,default:t},...Re()},setup(i,a){let{slots:s}=a;return()=>{var o;return Fn(i.tag,{class:[e,i.class],style:i.style},(o=s.default)==null?void 0:o.call(s))}}})}function i0(e){if(typeof e.getRootNode!="function"){for(;e.parentNode;)e=e.parentNode;return e!==document?null:document}const t=e.getRootNode();return t!==document&&t.getRootNode({composed:!0})!==document?null:t}const Hl="cubic-bezier(0.4, 0, 0.2, 1)",BO="cubic-bezier(0.0, 0, 0.2, 1)",NO="cubic-bezier(0.4, 0, 1, 1)";function Sp(e,t,n){return Object.keys(e).filter(i=>fu(i)&&i.endsWith(t)).reduce((i,a)=>(i[a.slice(0,-t.length)]=s=>e[a](s,n(s)),i),{})}function Yt(e,t){const n=Di();if(!n)throw new Error(`[Vuetify] ${e} ${t||"must be called from inside a setup function"}`);return n}function Ri(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"composables";const t=Yt(e).type;return ms((t==null?void 0:t.aliasName)||(t==null?void 0:t.name))}let a0=0,sc=new WeakMap;function xn(){const e=Yt("getUid");if(sc.has(e))return sc.get(e);{const t=a0++;return sc.set(e,t),t}}xn.reset=()=>{a0=0,sc=new WeakMap};function $h(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;for(;e;){if(t?FO(e):zh(e))return e;e=e.parentElement}return document.scrollingElement}function Oc(e,t){const n=[];if(t&&e&&!t.contains(e))return n;for(;e&&(zh(e)&&n.push(e),e!==t);)e=e.parentElement;return n}function zh(e){if(!e||e.nodeType!==Node.ELEMENT_NODE)return!1;const t=window.getComputedStyle(e);return t.overflowY==="scroll"||t.overflowY==="auto"&&e.scrollHeight>e.clientHeight}function FO(e){if(!e||e.nodeType!==Node.ELEMENT_NODE)return!1;const t=window.getComputedStyle(e);return["scroll","auto"].includes(t.overflowY)}function $O(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Yt("injectSelf");const{provides:n}=t;if(n&&e in n)return n[e]}function zO(e){for(;e;){if(window.getComputedStyle(e).position==="fixed")return!0;e=e.offsetParent}return!1}function fe(e){const t=Yt("useRender");t.render=e}function $e(e,t,n){let i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:d=>d,a=arguments.length>4&&arguments[4]!==void 0?arguments[4]:d=>d;const s=Yt("useProxiedModel"),o=Z(e[t]!==void 0?e[t]:n),l=ms(t),c=w(l!==t?()=>{var d,f,v,m;return e[t],!!(((d=s.vnode.props)!=null&&d.hasOwnProperty(t)||(f=s.vnode.props)!=null&&f.hasOwnProperty(l))&&((v=s.vnode.props)!=null&&v.hasOwnProperty(`onUpdate:${t}`)||(m=s.vnode.props)!=null&&m.hasOwnProperty(`onUpdate:${l}`)))}:()=>{var d,f;return e[t],!!((d=s.vnode.props)!=null&&d.hasOwnProperty(t)&&((f=s.vnode.props)!=null&&f.hasOwnProperty(`onUpdate:${t}`)))});mi(()=>!c.value,()=>{_e(()=>e[t],d=>{o.value=d})});const u=w({get(){const d=e[t];return i(c.value?d:o.value)},set(d){const f=a(d),v=Ye(c.value?e[t]:o.value);v===f||i(v)===d||(o.value=f,s==null||s.emit(`update:${t}`,f))}});return Object.defineProperty(u,"externalValue",{get:()=>c.value?e[t]:o.value}),u}const wp="$vuetify.",kp=(e,t)=>e.replace(/\{(\d+)\}/g,(n,i)=>String(t[+i])),s0=(e,t,n)=>function(i){for(var a=arguments.length,s=new Array(a>1?a-1:0),o=1;onew Intl.NumberFormat([e.value,t.value],i).format(n)}function _d(e,t,n){const i=$e(e,t,e[t]??n.value);return i.value=e[t]??n.value,_e(n,a=>{e[t]==null&&(i.value=n.value)}),i}function l0(e){return t=>{const n=_d(t,"locale",e.current),i=_d(t,"fallback",e.fallback),a=_d(t,"messages",e.messages);return{name:"vuetify",current:n,fallback:i,messages:a,t:s0(n,i,a),n:o0(n,i),provide:l0({current:n,fallback:i,messages:a})}}}function HO(e){const t=Se((e==null?void 0:e.locale)??"en"),n=Se((e==null?void 0:e.fallback)??"en"),i=Z({en:qD,...e==null?void 0:e.messages});return{name:"vuetify",current:t,fallback:n,messages:i,t:s0(t,n,i),n:o0(t,n),provide:l0({current:t,fallback:n,messages:i})}}const wo=Symbol.for("vuetify:locale");function jO(e){return e.name!=null}function WO(e){const t=e!=null&&e.adapter&&jO(e==null?void 0:e.adapter)?e==null?void 0:e.adapter:HO(e),n=YO(t,e);return{...t,...n}}function Kt(){const e=Ke(wo);if(!e)throw new Error("[Vuetify] Could not find injected locale instance");return e}function UO(e){const t=Ke(wo);if(!t)throw new Error("[Vuetify] Could not find injected locale instance");const n=t.provide(e),i=KO(n,t.rtl,e),a={...n,...i};return lt(wo,a),a}function YO(e,t){const n=Z((t==null?void 0:t.rtl)??ZD),i=w(()=>n.value[e.current.value]??!1);return{isRtl:i,rtl:n,rtlClasses:w(()=>`v-locale--is-${i.value?"rtl":"ltr"}`)}}function KO(e,t,n){const i=w(()=>n.rtl??t.value[e.current.value]??!1);return{isRtl:i,rtl:t,rtlClasses:w(()=>`v-locale--is-${i.value?"rtl":"ltr"}`)}}function dn(){const e=Ke(wo);if(!e)throw new Error("[Vuetify] Could not find injected rtl instance");return{isRtl:e.isRtl,rtlClasses:e.rtlClasses}}const df={"001":1,AD:1,AE:6,AF:6,AG:0,AI:1,AL:1,AM:1,AN:1,AR:1,AS:0,AT:1,AU:1,AX:1,AZ:1,BA:1,BD:0,BE:1,BG:1,BH:6,BM:1,BN:1,BR:0,BS:0,BT:0,BW:0,BY:1,BZ:0,CA:0,CH:1,CL:1,CM:1,CN:1,CO:0,CR:1,CY:1,CZ:1,DE:1,DJ:6,DK:1,DM:0,DO:0,DZ:6,EC:1,EE:1,EG:6,ES:1,ET:0,FI:1,FJ:1,FO:1,FR:1,GB:1,"GB-alt-variant":0,GE:1,GF:1,GP:1,GR:1,GT:0,GU:0,HK:0,HN:0,HR:1,HU:1,ID:0,IE:1,IL:0,IN:0,IQ:6,IR:6,IS:1,IT:1,JM:0,JO:6,JP:0,KE:0,KG:1,KH:0,KR:0,KW:6,KZ:1,LA:0,LB:1,LI:1,LK:1,LT:1,LU:1,LV:1,LY:6,MC:1,MD:1,ME:1,MH:0,MK:1,MM:0,MN:1,MO:0,MQ:1,MT:0,MV:5,MX:0,MY:1,MZ:0,NI:0,NL:1,NO:1,NP:0,NZ:1,OM:6,PA:0,PE:0,PH:0,PK:0,PL:1,PR:0,PT:0,PY:0,QA:6,RE:1,RO:1,RS:1,RU:1,SA:0,SD:6,SE:1,SG:0,SI:1,SK:1,SM:1,SV:0,SY:6,TH:0,TJ:1,TM:1,TR:1,TT:0,TW:0,UA:1,UM:0,US:0,UY:1,UZ:1,VA:1,VE:0,VI:0,VN:1,WS:0,XK:1,YE:0,ZA:0,ZW:0};function GO(e,t){const n=[];let i=[];const a=r0(e),s=c0(e),o=(a.getDay()-df[t.slice(-2).toUpperCase()]+7)%7,l=(s.getDay()-df[t.slice(-2).toUpperCase()]+7)%7;for(let r=0;r0&&n.push(i),n}function r0(e){return new Date(e.getFullYear(),e.getMonth(),1)}function c0(e){return new Date(e.getFullYear(),e.getMonth()+1,0)}function XO(e){const t=e.split("-").map(Number);return new Date(t[0],t[1]-1,t[2])}const qO=/^([12]\d{3}-([1-9]|0[1-9]|1[0-2])-([1-9]|0[1-9]|[12]\d|3[01]))$/;function u0(e){if(e==null)return new Date;if(e instanceof Date)return e;if(typeof e=="string"){let t;if(qO.test(e))return XO(e);if(t=Date.parse(e),!isNaN(t))return new Date(t)}return null}const Cp=new Date(2e3,0,2);function ZO(e){const t=df[e.slice(-2).toUpperCase()];return Ti(7).map(n=>{const i=new Date(Cp);return i.setDate(Cp.getDate()+t+n),new Intl.DateTimeFormat(e,{weekday:"narrow"}).format(i)})}function JO(e,t,n,i){const a=u0(e)??new Date,s=i==null?void 0:i[t];if(typeof s=="function")return s(a,t,n);let o={};switch(t){case"fullDateWithWeekday":o={weekday:"long",day:"numeric",month:"long",year:"numeric"};break;case"normalDateWithWeekday":o={weekday:"short",day:"numeric",month:"short"};break;case"keyboardDate":o={day:"2-digit",month:"2-digit",year:"numeric"};break;case"monthAndDate":o={month:"long",day:"numeric"};break;case"monthAndYear":o={month:"long",year:"numeric"};break;case"month":o={month:"long"};break;case"monthShort":o={month:"short"};break;case"dayOfMonth":o={day:"numeric"};break;case"shortDate":o={year:"2-digit",month:"numeric",day:"numeric"};break;case"year":o={year:"numeric"};break;default:o=s??{timeZone:"UTC",timeZoneName:"short"}}return new Intl.DateTimeFormat(n,o).format(a)}function QO(e,t){const n=e.toJsDate(t),i=n.getFullYear(),a=op(String(n.getMonth()+1),2,"0"),s=op(String(n.getDate()),2,"0");return`${i}-${a}-${s}`}function e2(e){const[t,n,i]=e.split("-").map(Number);return new Date(t,n-1,i)}function t2(e,t){const n=new Date(e);return n.setDate(n.getDate()+t),n}function n2(e,t){const n=new Date(e);return n.setMonth(n.getMonth()+t),n}function i2(e){return e.getFullYear()}function a2(e){return e.getMonth()}function s2(e){return new Date(e.getFullYear(),e.getMonth()+1,1)}function o2(e){return new Date(e.getFullYear(),0,1)}function l2(e){return new Date(e.getFullYear(),11,31)}function r2(e,t){return ff(e,t[0])&&u2(e,t[1])}function c2(e){const t=new Date(e);return t instanceof Date&&!isNaN(t.getTime())}function ff(e,t){return e.getTime()>t.getTime()}function u2(e,t){return e.getTime(){n.locale=e.locale[i]??i??n.locale}),n}function mu(){const e=Ke(d0);if(!e)throw new Error("[Vuetify] Could not find injected date options");const t=Kt();return f0(e,t)}function _2(e,t){const n=e.toJsDate(t);let i=e.getYear(n),a=e.startOfYear(n);if(n=l&&(i=i+1,a=l)}const s=Math.abs(n.getTime()-a.getTime()),o=Math.ceil(s/(1e3*60*60*24));return Math.floor(o/7)+1}const gu=["sm","md","lg","xl","xxl"],hf=Symbol.for("vuetify:display"),Vp={mobileBreakpoint:"lg",thresholds:{xs:0,sm:600,md:960,lg:1280,xl:1920,xxl:2560}},x2=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Vp;return si(Vp,e)};function Ap(e){return yt&&!e?window.innerWidth:typeof e=="object"&&e.clientWidth||0}function Tp(e){return yt&&!e?window.innerHeight:typeof e=="object"&&e.clientHeight||0}function Mp(e){const t=yt&&!e?window.navigator.userAgent:"ssr";function n(m){return!!t.match(m)}const i=n(/android/i),a=n(/iphone|ipad|ipod/i),s=n(/cordova/i),o=n(/electron/i),l=n(/chrome/i),r=n(/edge/i),c=n(/firefox/i),u=n(/opera/i),d=n(/win/i),f=n(/mac/i),v=n(/linux/i);return{android:i,ios:a,cordova:s,electron:o,chrome:l,edge:r,firefox:c,opera:u,win:d,mac:f,linux:v,touch:JD,ssr:t==="ssr"}}function S2(e,t){const{thresholds:n,mobileBreakpoint:i}=x2(e),a=Se(Tp(t)),s=Se(Mp(t)),o=Ft({}),l=Se(Ap(t));function r(){a.value=Tp(),l.value=Ap()}function c(){r(),s.value=Mp()}return Jt(()=>{const u=l.value=n.xxl,p=u?"xs":d?"sm":f?"md":v?"lg":m?"xl":"xxl",y=typeof i=="number"?i:n[i],b=l.value0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Ri();const n=Ke(hf);if(!n)throw new Error("Could not find Vuetify display injection");const i=w(()=>{if(!e.mobileBreakpoint)return n.mobile.value;const s=typeof e.mobileBreakpoint=="number"?e.mobileBreakpoint:n.thresholds.value[e.mobileBreakpoint];return n.width.valuet?{[`${t}--mobile`]:i.value}:{});return{...n,displayClasses:a,mobile:i}}const w2={collapse:"mdi-chevron-up",complete:"mdi-check",cancel:"mdi-close-circle",close:"mdi-close",delete:"mdi-close-circle",clear:"mdi-close-circle",success:"mdi-check-circle",info:"mdi-information",warning:"mdi-alert-circle",error:"mdi-close-circle",prev:"mdi-chevron-left",next:"mdi-chevron-right",checkboxOn:"mdi-checkbox-marked",checkboxOff:"mdi-checkbox-blank-outline",checkboxIndeterminate:"mdi-minus-box",delimiter:"mdi-circle",sortAsc:"mdi-arrow-up",sortDesc:"mdi-arrow-down",expand:"mdi-chevron-down",menu:"mdi-menu",subgroup:"mdi-menu-down",dropdown:"mdi-menu-down",radioOn:"mdi-radiobox-marked",radioOff:"mdi-radiobox-blank",edit:"mdi-pencil",ratingEmpty:"mdi-star-outline",ratingFull:"mdi-star",ratingHalf:"mdi-star-half-full",loading:"mdi-cached",first:"mdi-page-first",last:"mdi-page-last",unfold:"mdi-unfold-more-horizontal",file:"mdi-paperclip",plus:"mdi-plus",minus:"mdi-minus",calendar:"mdi-calendar",eyeDropper:"mdi-eyedropper"},k2={component:e=>Fn(Wh,{...e,class:"mdi"})},We=[String,Function,Object,Array],vf=Symbol.for("vuetify:icons"),pu=W({icon:{type:We},tag:{type:String,required:!0}},"icon"),mf=se()({name:"VComponentIcon",props:pu(),setup(e,t){let{slots:n}=t;return()=>{const i=e.icon;return h(e.tag,null,{default:()=>{var a;return[e.icon?h(i,null,null):(a=n.default)==null?void 0:a.call(n)]}})}}}),jh=Gn({name:"VSvgIcon",inheritAttrs:!1,props:pu(),setup(e,t){let{attrs:n}=t;return()=>h(e.tag,ve(n,{style:null}),{default:()=>[h("svg",{class:"v-icon__svg",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",role:"img","aria-hidden":"true"},[Array.isArray(e.icon)?e.icon.map(i=>Array.isArray(i)?h("path",{d:i[0],"fill-opacity":i[1]},null):h("path",{d:i},null)):h("path",{d:e.icon},null)])]})}}),C2=Gn({name:"VLigatureIcon",props:pu(),setup(e){return()=>h(e.tag,null,{default:()=>[e.icon]})}}),Wh=Gn({name:"VClassIcon",props:pu(),setup(e){return()=>h(e.tag,{class:e.icon},null)}}),P2={svg:{component:jh},class:{component:Wh}};function I2(e){return si({defaultSet:"mdi",sets:{...P2,mdi:k2},aliases:{...w2,vuetify:["M8.2241 14.2009L12 21L22 3H14.4459L8.2241 14.2009Z",["M7.26303 12.4733L7.00113 12L2 3H12.5261C12.5261 3 12.5261 3 12.5261 3L7.26303 12.4733Z",.6]],"vuetify-outline":"svg:M7.26 12.47 12.53 3H2L7.26 12.47ZM14.45 3 8.22 14.2 12 21 22 3H14.45ZM18.6 5 12 16.88 10.51 14.2 15.62 5ZM7.26 8.35 5.4 5H9.13L7.26 8.35Z"}},e)}const V2=e=>{const t=Ke(vf);if(!t)throw new Error("Missing Vuetify Icons provide!");return{iconData:w(()=>{var r;const i=Je(e);if(!i)return{component:mf};let a=i;if(typeof a=="string"&&(a=a.trim(),a.startsWith("$")&&(a=(r=t.aliases)==null?void 0:r[a.slice(1)])),!a)throw new Error(`Could not find aliased icon "${i}"`);if(Array.isArray(a))return{component:jh,icon:a};if(typeof a!="string")return{component:mf,icon:a};const s=Object.keys(t.sets).find(c=>typeof a=="string"&&a.startsWith(`${c}:`)),o=s?a.slice(s.length+1):a;return{component:t.sets[s??t.defaultSet].component,icon:o}})}},jl=Symbol.for("vuetify:theme"),Qe=W({theme:String},"theme");function Ep(){return{defaultTheme:"light",variations:{colors:[],lighten:0,darken:0},themes:{light:{dark:!1,colors:{background:"#FFFFFF",surface:"#FFFFFF","surface-bright":"#FFFFFF","surface-variant":"#424242","on-surface-variant":"#EEEEEE",primary:"#1867C0","primary-darken-1":"#1F5592",secondary:"#48A9A6","secondary-darken-1":"#018786",error:"#B00020",info:"#2196F3",success:"#4CAF50",warning:"#FB8C00"},variables:{"border-color":"#000000","border-opacity":.12,"high-emphasis-opacity":.87,"medium-emphasis-opacity":.6,"disabled-opacity":.38,"idle-opacity":.04,"hover-opacity":.04,"focus-opacity":.12,"selected-opacity":.08,"activated-opacity":.12,"pressed-opacity":.12,"dragged-opacity":.08,"theme-kbd":"#212529","theme-on-kbd":"#FFFFFF","theme-code":"#F5F5F5","theme-on-code":"#000000"}},dark:{dark:!0,colors:{background:"#121212",surface:"#212121","surface-bright":"#ccbfd6","surface-variant":"#a3a3a3","on-surface-variant":"#424242",primary:"#2196F3","primary-darken-1":"#277CC1",secondary:"#54B6B2","secondary-darken-1":"#48A9A6",error:"#CF6679",info:"#2196F3",success:"#4CAF50",warning:"#FB8C00"},variables:{"border-color":"#FFFFFF","border-opacity":.12,"high-emphasis-opacity":1,"medium-emphasis-opacity":.7,"disabled-opacity":.5,"idle-opacity":.1,"hover-opacity":.04,"focus-opacity":.12,"selected-opacity":.08,"activated-opacity":.12,"pressed-opacity":.16,"dragged-opacity":.08,"theme-kbd":"#212529","theme-on-kbd":"#FFFFFF","theme-code":"#343434","theme-on-code":"#CCCCCC"}}}}}function A2(){var i,a;let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Ep();const t=Ep();if(!e)return{...t,isDisabled:!0};const n={};for(const[s,o]of Object.entries(e.themes??{})){const l=o.dark||s==="dark"?(i=t.themes)==null?void 0:i.dark:(a=t.themes)==null?void 0:a.light;n[s]=si(l,o)}return si(t,{...e,themes:n})}function T2(e){const t=A2(e),n=Z(t.defaultTheme),i=Z(t.themes),a=w(()=>{const u={};for(const[d,f]of Object.entries(i.value)){const v=u[d]={...f,colors:{...f.colors}};if(t.variations)for(const m of t.variations.colors){const g=v.colors[m];if(g)for(const p of["lighten","darken"]){const y=p==="lighten"?TO:MO;for(const b of Ti(t.variations[p],1))v.colors[`${m}-${p}-${b}`]=J_(y(oi(g),b))}}for(const m of Object.keys(v.colors)){if(/^on-[a-z]/.test(m)||v.colors[`on-${m}`])continue;const g=`on-${m}`,p=oi(v.colors[m]);v.colors[g]=n0(p)}}return u}),s=w(()=>a.value[n.value]),o=w(()=>{const u=[];s.value.dark&&ns(u,":root",["color-scheme: dark"]),ns(u,":root",Dp(s.value));for(const[m,g]of Object.entries(a.value))ns(u,`.v-theme--${m}`,[`color-scheme: ${g.dark?"dark":"normal"}`,...Dp(g)]);const d=[],f=[],v=new Set(Object.values(a.value).flatMap(m=>Object.keys(m.colors)));for(const m of v)/^on-[a-z]/.test(m)?ns(f,`.${m}`,[`color: rgb(var(--v-theme-${m})) !important`]):(ns(d,`.bg-${m}`,[`--v-theme-overlay-multiplier: var(--v-theme-${m}-overlay-multiplier)`,`background-color: rgb(var(--v-theme-${m})) !important`,`color: rgb(var(--v-theme-on-${m})) !important`]),ns(f,`.text-${m}`,[`color: rgb(var(--v-theme-${m})) !important`]),ns(f,`.border-${m}`,[`--v-border-color: var(--v-theme-${m})`]));return u.push(...d,...f),u.map((m,g)=>g===0?m:` ${m}`).join("")});function l(){return{style:[{children:o.value,id:"vuetify-theme-stylesheet",nonce:t.cspNonce||!1}]}}function r(u){if(t.isDisabled)return;const d=u._context.provides.usehead;if(d)if(d.push){const v=d.push(l);yt&&_e(o,()=>{v.patch(l)})}else yt?(d.addHeadObjs(w(l)),Jt(()=>d.updateDOM())):d.addHeadObjs(l());else{let m=function(){if(typeof document<"u"&&!v){const g=document.createElement("style");g.type="text/css",g.id="vuetify-theme-stylesheet",t.cspNonce&&g.setAttribute("nonce",t.cspNonce),v=g,document.head.appendChild(v)}v&&(v.innerHTML=o.value)};var f=m;let v=yt?document.getElementById("vuetify-theme-stylesheet"):null;yt?_e(o,m,{immediate:!0}):m()}}const c=w(()=>t.isDisabled?void 0:`v-theme--${n.value}`);return{install:r,isDisabled:t.isDisabled,name:n,themes:i,current:s,computedThemes:a,themeClasses:c,styles:o,global:{name:n,current:s}}}function ot(e){Yt("provideTheme");const t=Ke(jl,null);if(!t)throw new Error("Could not find Vuetify theme injection");const n=w(()=>e.theme??t.name.value),i=w(()=>t.themes.value[n.value]),a=w(()=>t.isDisabled?void 0:`v-theme--${n.value}`),s={...t,name:n,current:i,themeClasses:a};return lt(jl,s),s}function h0(){Yt("useTheme");const e=Ke(jl,null);if(!e)throw new Error("Could not find Vuetify theme injection");return e}function ns(e,t,n){e.push(`${t} { `,...n.map(i=>` ${i}; `),`} diff --git a/frontend/src/composables/data.js b/frontend/src/composables/data.js index 857fa11..1796d06 100644 --- a/frontend/src/composables/data.js +++ b/frontend/src/composables/data.js @@ -72,7 +72,7 @@ export function useData() { // const jProfile = await _loadJson('./data/info/profile.json') _jsonData.places = jPlaces - const skill_response = await fetch("https://res-a-me-api.tobywinz.com/loadResume", { + const skill_response = await fetch("https://res-a-me-api.resilientdb.com/loadResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -188,7 +188,7 @@ export function useData() { if(utils.isStringAJSONUrl(jsonPath)) { var jD; if (jsonPath.includes("skills")){ - const skill_response = await fetch("https://res-a-me-api.tobywinz.com/loadResume", { + const skill_response = await fetch("https://res-a-me-api.resilientdb.com/loadResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -203,7 +203,7 @@ export function useData() { } else if (jsonPath.includes("cover")){ - const skill_response = await fetch("https://res-a-me-api.tobywinz.com/loadResume", { + const skill_response = await fetch("https://res-a-me-api.resilientdb.com/loadResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -218,7 +218,7 @@ export function useData() { } else if (jsonPath.includes("profile")){ - const skill_response = await fetch("https://res-a-me-api.tobywinz.com/loadResume", { + const skill_response = await fetch("https://res-a-me-api.resilientdb.com/loadResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -234,7 +234,7 @@ export function useData() { else if (jsonPath.includes("education")){ - const skill_response = await fetch("https://res-a-me-api.tobywinz.com/loadResume", { + const skill_response = await fetch("https://res-a-me-api.resilientdb.com/loadResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -249,7 +249,7 @@ export function useData() { } else if (jsonPath.includes("experience")){ - const skill_response = await fetch("https://res-a-me-api.tobywinz.com/loadResume", { + const skill_response = await fetch("https://res-a-me-api.resilientdb.com/loadResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -264,7 +264,7 @@ export function useData() { } else if (jsonPath.includes("achievements")){ - const skill_response = await fetch("https://res-a-me-api.tobywinz.com/loadResume", { + const skill_response = await fetch("https://res-a-me-api.resilientdb.com/loadResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", diff --git a/frontend/src/router/router.js b/frontend/src/router/router.js index 09eb46f..733bccc 100644 --- a/frontend/src/router/router.js +++ b/frontend/src/router/router.js @@ -60,7 +60,7 @@ export function createAppRouter() { let isAuthenticated = false try { - const response = await fetch("https://res-a-me-api.tobywinz.com/loadUser", { + const response = await fetch("https://res-a-me-api.resilientdb.com/loadUser", { method: "GET", headers: { "Content-type": "application/json; charset=UTF-8", @@ -74,7 +74,7 @@ export function createAppRouter() { if (json.status === 200) { isAuthenticated = true; } else if (json.msg === "Token has expired") { - const refreshResponse = await fetch("https://res-a-me-api.tobywinz.com/refresh", { + const refreshResponse = await fetch("https://res-a-me-api.resilientdb.com/refresh", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", diff --git a/frontend/src/vue/core/Editview.vue b/frontend/src/vue/core/Editview.vue index e15ac4a..59aed2d 100644 --- a/frontend/src/vue/core/Editview.vue +++ b/frontend/src/vue/core/Editview.vue @@ -108,7 +108,7 @@ export default { //skill data // const skill_response = await axios.get('../../../data/sections/skills.json'); // const skill_data = skill_response.data; - const skill_response = await fetch("https://res-a-me-api.tobywinz.com/loadResume", { + const skill_response = await fetch("https://res-a-me-api.resilientdb.com/loadResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -133,7 +133,7 @@ export default { //about data // const cover_response = await axios.get('../../../data/sections/cover.json'); // const cover_data = cover_response.data; - const cover_response = await fetch("https://res-a-me-api.tobywinz.com/loadResume", { + const cover_response = await fetch("https://res-a-me-api.resilientdb.com/loadResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -144,7 +144,7 @@ export default { }); const cover_data = await cover_response.json(); cover_data_old.value = cover_data; //for update JSON file - const profile_response = await fetch("https://res-a-me-api.tobywinz.com/loadResume", { + const profile_response = await fetch("https://res-a-me-api.resilientdb.com/loadResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -171,7 +171,7 @@ export default { //education data // const edu_response = await axios.get('../../../data/sections/education.json'); // const edu_data = edu_response.data; - const edu_response = await fetch("https://res-a-me-api.tobywinz.com/loadResume", { + const edu_response = await fetch("https://res-a-me-api.resilientdb.com/loadResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -196,7 +196,7 @@ export default { //profession data // const pro_response = await axios.get('../../../data/sections/experience.json'); // const pro_data = pro_response.data; - const pro_response = await fetch("https://res-a-me-api.tobywinz.com/loadResume", { + const pro_response = await fetch("https://res-a-me-api.resilientdb.com/loadResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -221,7 +221,7 @@ export default { //achievement and award data // const achi_response = await axios.get('../../../data/sections/achievements.json'); // const achi_data = achi_response.data; - const achi_response = await fetch("https://res-a-me-api.tobywinz.com/loadResume", { + const achi_response = await fetch("https://res-a-me-api.resilientdb.com/loadResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -276,7 +276,7 @@ export default { let userEmail = ""; try { - const response = await fetch("https://res-a-me-api.tobywinz.com/loadUser", { + const response = await fetch("https://res-a-me-api.resilientdb.com/loadUser", { method: "GET", headers: { "Content-type": "application/json; charset=UTF-8", @@ -292,7 +292,7 @@ export default { } try { - const response = await fetch("https://res-a-me-api.tobywinz.com/updateResume", { + const response = await fetch("https://res-a-me-api.resilientdb.com/updateResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -346,7 +346,7 @@ export default { } }); } - fetch("https://res-a-me-api.tobywinz.com/editResume", { + fetch("https://res-a-me-api.resilientdb.com/editResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -365,7 +365,7 @@ export default { this.profile_data_old.locales.en.role = this.about.role; this.profile_data_old.contact.email.value = this.about.email; this.profile_data_old.contact.phone.valueShort = this.about.phone; - await fetch("https://res-a-me-api.tobywinz.com/editResume", { + await fetch("https://res-a-me-api.resilientdb.com/editResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -374,7 +374,7 @@ export default { }, body: JSON.stringify({ "category": "cover", "data": JSON.stringify(this.cover_data_old) }), }); - await fetch("https://res-a-me-api.tobywinz.com/editResume", { + await fetch("https://res-a-me-api.resilientdb.com/editResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -418,7 +418,7 @@ export default { }, }); } - fetch("https://res-a-me-api.tobywinz.com/editResume", { + fetch("https://res-a-me-api.resilientdb.com/editResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -462,7 +462,7 @@ export default { }, }); } - fetch("https://res-a-me-api.tobywinz.com/editResume", { + fetch("https://res-a-me-api.resilientdb.com/editResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -506,7 +506,7 @@ export default { }, }); } - await fetch("https://res-a-me-api.tobywinz.com/editResume", { + await fetch("https://res-a-me-api.resilientdb.com/editResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -550,7 +550,7 @@ export default { }, }); } - await fetch("https://res-a-me-api.tobywinz.com/editResume", { + await fetch("https://res-a-me-api.resilientdb.com/editResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", diff --git a/frontend/src/vue/core/LandingPage.vue b/frontend/src/vue/core/LandingPage.vue index 0feeacc..4779c76 100644 --- a/frontend/src/vue/core/LandingPage.vue +++ b/frontend/src/vue/core/LandingPage.vue @@ -171,7 +171,7 @@ export default { document.getElementById("logoutButton").style.display = "none"; document.getElementById("userNameDisplay").style.display = "none"; - await fetch("https://res-a-me-api.tobywinz.com/loadUser", { + await fetch("https://res-a-me-api.resilientdb.com/loadUser", { // Check if user is logged in method: "GET", headers: { @@ -184,10 +184,10 @@ export default { if (json.status === 200) { // User is logged in this.userEmail = json.logged_in_as; - fetch(`https://res-a-me-api.tobywinz.com/static/images/${this.userEmail}.png`) + fetch(`https://res-a-me-api.resilientdb.com/static/images/${this.userEmail}.png`) .then(response => { if(response.ok) { - this.shortCutIcon = `https://res-a-me-api.tobywinz.com/static/images/${this.userEmail}.png`; + this.shortCutIcon = `https://res-a-me-api.resilientdb.com/static/images/${this.userEmail}.png`; } else { this.shortCutIcon = `/images/pictures/avatar.png`; } @@ -205,7 +205,7 @@ export default { error.message || "An error occurred. Please try again."; }); - fetch("https://res-a-me-api.tobywinz.com/userList", { + fetch("https://res-a-me-api.resilientdb.com/userList", { // Get the user list for the search bar method: "GET", headers: { @@ -220,10 +220,10 @@ export default { document.getElementById("userNameDisplay").style.display = "block"; } var avatar = ""; - fetch(`https://res-a-me-api.tobywinz.com/static/images/${json.user_list[index].email}.png`) + fetch(`https://res-a-me-api.resilientdb.com/static/images/${json.user_list[index].email}.png`) .then(response => { if(response.ok) { - avatar = `https://res-a-me-api.tobywinz.com/static/images/${json.user_list[index].email}.png`; + avatar = `https://res-a-me-api.resilientdb.com/static/images/${json.user_list[index].email}.png`; } else { avatar = `/images/pictures/avatar.png`; } @@ -243,7 +243,7 @@ export default { methods: { logout() { const errorMessage = ""; - fetch("https://res-a-me-api.tobywinz.com/logout", { + fetch("https://res-a-me-api.resilientdb.com/logout", { method: "GET", headers: { "Content-type": "application/json; charset=UTF-8", @@ -278,7 +278,7 @@ export default { }, async profileShortcutAction(){ try { - const response = await fetch("https://res-a-me-api.tobywinz.com/updateResume", { + const response = await fetch("https://res-a-me-api.resilientdb.com/updateResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -311,7 +311,7 @@ export default { } try { - const response = await fetch("https://res-a-me-api.tobywinz.com/updateResume", { + const response = await fetch("https://res-a-me-api.resilientdb.com/updateResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -347,7 +347,7 @@ export default { } try { - const response = await fetch("https://res-a-me-api.tobywinz.com/updateResume", { + const response = await fetch("https://res-a-me-api.resilientdb.com/updateResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", diff --git a/frontend/src/vue/core/LoginView.vue b/frontend/src/vue/core/LoginView.vue index a123a9e..ca82775 100644 --- a/frontend/src/vue/core/LoginView.vue +++ b/frontend/src/vue/core/LoginView.vue @@ -1,58 +1,67 @@ @@ -107,7 +116,7 @@ export default { return } - fetch("https://res-a-me-api.tobywinz.com/login", { + fetch("https://res-a-me-api.resilientdb.com/login", { method: "POST", body: JSON.stringify(userData), headers: { @@ -124,25 +133,25 @@ export default { sessionStorage.setItem("access_token", json['access_token']); sessionStorage.setItem("refresh_token", json['refresh_token']); try { - const updateResponse = await fetch("https://res-a-me-api.tobywinz.com/updateResume", { - method: "POST", - headers: { - "Content-type": "application/json; charset=UTF-8", - }, - body: JSON.stringify({ - email: this.email, - }), + const updateResponse = await fetch("https://res-a-me-api.resilientdb.com/updateResume", { + method: "POST", + headers: { + "Content-type": "application/json; charset=UTF-8", + }, + body: JSON.stringify({ + email: this.email, + }), }); const json = await updateResponse.json(); if (json.status !== 200) { - console.error("Error fetching user resume: ", json.message); + console.error("Error fetching user resume: ", json.message); } this.$router.push({ path: "/home" }) - .then(() => window.location.reload(true)) + .then(() => window.location.reload(true)) } - catch (error){ + catch (error) { console.error("Error fetching user resume: ", error); } } @@ -162,7 +171,7 @@ export default { password: this.password }; - fetch("https://res-a-me-api.tobywinz.com/register", { + fetch("https://res-a-me-api.resilientdb.com/register", { method: "POST", headers: { "Content-Type": "application/json; charset=UTF-8" @@ -208,6 +217,50 @@ export default { diff --git a/frontend/src/vue/navigation/default/NavSidebar.vue b/frontend/src/vue/navigation/default/NavSidebar.vue index c78dba0..030a1ec 100644 --- a/frontend/src/vue/navigation/default/NavSidebar.vue +++ b/frontend/src/vue/navigation/default/NavSidebar.vue @@ -92,7 +92,7 @@ async function fetchProfileData() { } else { // If the user has logged in try { - const response = await fetch("https://res-a-me-api.tobywinz.com/loadUser", { + const response = await fetch("https://res-a-me-api.resilientdb.com/loadUser", { method: "GET", headers: { "Content-type": "application/json; charset=UTF-8", @@ -111,7 +111,7 @@ async function fetchProfileData() { // Update resume to show current user's try { - const response = await fetch("https://res-a-me-api.tobywinz.com/updateResume", { + const response = await fetch("https://res-a-me-api.resilientdb.com/updateResume", { method: "POST", headers: { "Content-type": "application/json; charset=UTF-8", @@ -167,7 +167,7 @@ const checkSession = () => { }; const logout = () => { - fetch("https://res-a-me-api.tobywinz.com/logout", { + fetch("https://res-a-me-api.resilientdb.com/logout", { method: "GET", headers: { "Content-type": "application/json; charset=UTF-8", diff --git a/frontend/src/vue/sections/edit/About.vue b/frontend/src/vue/sections/edit/About.vue index ebb09b1..a4aa639 100644 --- a/frontend/src/vue/sections/edit/About.vue +++ b/frontend/src/vue/sections/edit/About.vue @@ -156,7 +156,7 @@ export default { const formData = new FormData(); formData.append('image', selectedFile.value); - fetch('https://res-a-me-api.tobywinz.com/upload', { + fetch('https://res-a-me-api.resilientdb.com/upload', { method: 'POST', headers: { Authorization: `Bearer ` + sessionStorage.getItem("access_token"),